From 44c97d6d1abd05314d1a06818d59571b174a5b69 Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Tue, 29 Sep 2020 17:31:12 +0200 Subject: [PATCH 01/15] Created ground package structure --- package.json | 23 +- src/agile.ts | 155 ----- src/api/index.ts | 179 ----- src/collection/group.ts | 223 ------ src/collection/index.ts | 632 ------------------ src/collection/item.ts | 24 - src/collection/perstist.ts | 243 ------- src/collection/selector.ts | 130 ---- src/computed/index.ts | 117 ---- src/event/index.ts | 201 ------ src/index.ts | 8 - src/integrations/react/hooks/AgileHOC.ts | 92 --- src/integrations/react/hooks/useAgile.ts | 82 --- src/integrations/react/hooks/useEvent.ts | 27 - src/integrations/react/index.ts | 7 - src/integrations/react/react.integration.ts | 31 - src/integrations/test/hooks/useAgile.ts | 68 -- src/integrations/test/hooks/useEvent.ts | 18 - src/integrations/test/index.ts | 2 - src/integrations/use.ts | 94 --- src/runtime.ts | 286 -------- src/state/dep.ts | 26 - src/state/index.ts | 339 ---------- src/state/persist.ts | 85 --- src/storage.ts | 184 ----- src/sub.ts | 204 ------ src/utils.ts | 178 ----- test/collection/default.spec.ts | 178 ----- .../functions/collect.function.spec.ts | 374 ----------- .../functions/createGroup.function.spec.ts | 49 -- .../functions/createSelector.function.spec.ts | 54 -- .../functions/findById.function.spec.ts | 39 -- .../functions/getGroup.function.spec.ts | 44 -- .../functions/getSelector.function.spec.ts | 42 -- .../functions/getValueById.function.spec.ts | 37 - .../functions/remove.function.spec.ts | 224 ------- .../functions/update.function.spec.ts | 222 ------ test/collection/group/default.spec.ts | 183 ----- .../group/functions/add.function.spec.ts | 256 ------- .../group/functions/has.function.spec.ts | 60 -- .../group/functions/remove.function.spec.ts | 137 ---- test/collection/selector/default.spec.ts | 118 ---- .../functions/select.function.spec.ts | 147 ---- test/computed/default.spec.ts | 152 ----- .../updateComputeFunction.function.spec.ts | 130 ---- test/event/default.spec.ts | 191 ------ test/event/functions/disable.function.spec.ts | 31 - test/event/functions/enable.function.spec.ts | 31 - test/event/functions/on.function.spec.ts | 47 -- test/event/functions/reset.function.spec.ts | 36 - test/event/functions/trigger.function.spec.ts | 70 -- test/framework.spec.ts | 28 - test/state/default.spec.ts | 74 -- test/state/functions/patch.function.spec.ts | 204 ------ test/state/functions/persist.function.spec.ts | 129 ---- test/state/functions/reset.function.spec.ts | 72 -- test/state/functions/set.function.spec.ts | 125 ---- test/state/functions/type.function.spec.ts | 32 - test/state/functions/undo.function.spec.ts | 72 -- test/state/functions/watch.function.spec.ts | 52 -- test/storage.spec.ts | 98 --- tsconfig.json | 71 -- 62 files changed, 8 insertions(+), 7459 deletions(-) delete mode 100644 src/agile.ts delete mode 100644 src/api/index.ts delete mode 100644 src/collection/group.ts delete mode 100644 src/collection/index.ts delete mode 100644 src/collection/item.ts delete mode 100644 src/collection/perstist.ts delete mode 100644 src/collection/selector.ts delete mode 100644 src/computed/index.ts delete mode 100644 src/event/index.ts delete mode 100644 src/index.ts delete mode 100644 src/integrations/react/hooks/AgileHOC.ts delete mode 100644 src/integrations/react/hooks/useAgile.ts delete mode 100644 src/integrations/react/hooks/useEvent.ts delete mode 100644 src/integrations/react/index.ts delete mode 100644 src/integrations/react/react.integration.ts delete mode 100644 src/integrations/test/hooks/useAgile.ts delete mode 100644 src/integrations/test/hooks/useEvent.ts delete mode 100644 src/integrations/test/index.ts delete mode 100644 src/integrations/use.ts delete mode 100644 src/runtime.ts delete mode 100644 src/state/dep.ts delete mode 100644 src/state/index.ts delete mode 100644 src/state/persist.ts delete mode 100644 src/storage.ts delete mode 100644 src/sub.ts delete mode 100644 src/utils.ts delete mode 100644 test/collection/default.spec.ts delete mode 100644 test/collection/functions/collect.function.spec.ts delete mode 100644 test/collection/functions/createGroup.function.spec.ts delete mode 100644 test/collection/functions/createSelector.function.spec.ts delete mode 100644 test/collection/functions/findById.function.spec.ts delete mode 100644 test/collection/functions/getGroup.function.spec.ts delete mode 100644 test/collection/functions/getSelector.function.spec.ts delete mode 100644 test/collection/functions/getValueById.function.spec.ts delete mode 100644 test/collection/functions/remove.function.spec.ts delete mode 100644 test/collection/functions/update.function.spec.ts delete mode 100644 test/collection/group/default.spec.ts delete mode 100644 test/collection/group/functions/add.function.spec.ts delete mode 100644 test/collection/group/functions/has.function.spec.ts delete mode 100644 test/collection/group/functions/remove.function.spec.ts delete mode 100644 test/collection/selector/default.spec.ts delete mode 100644 test/collection/selector/functions/select.function.spec.ts delete mode 100644 test/computed/default.spec.ts delete mode 100644 test/computed/functions/updateComputeFunction.function.spec.ts delete mode 100644 test/event/default.spec.ts delete mode 100644 test/event/functions/disable.function.spec.ts delete mode 100644 test/event/functions/enable.function.spec.ts delete mode 100644 test/event/functions/on.function.spec.ts delete mode 100644 test/event/functions/reset.function.spec.ts delete mode 100644 test/event/functions/trigger.function.spec.ts delete mode 100644 test/framework.spec.ts delete mode 100644 test/state/default.spec.ts delete mode 100644 test/state/functions/patch.function.spec.ts delete mode 100644 test/state/functions/persist.function.spec.ts delete mode 100644 test/state/functions/reset.function.spec.ts delete mode 100644 test/state/functions/set.function.spec.ts delete mode 100644 test/state/functions/type.function.spec.ts delete mode 100644 test/state/functions/undo.function.spec.ts delete mode 100644 test/state/functions/watch.function.spec.ts delete mode 100644 test/storage.spec.ts delete mode 100644 tsconfig.json diff --git a/package.json b/package.json index 3203580b..95b02f34 100644 --- a/package.json +++ b/package.json @@ -1,10 +1,9 @@ { - "name": "agile", - "version": "1.0.2", + "private": true, "description": "Global state and logic framework for reactive React applications.", - "main": "dist/index.js", - "module": "dist/index.js", - "types": "./dist/index.d.ts", + "author": "BennoDev", + "license": "ISC", + "syncDir": "dist", "scripts": { "build": "tsc", "dev": "tsc-watch", @@ -16,15 +15,9 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/agile-architecture/agile.git" + "url": "git+https://github.com/agile-ts/agile.git" }, - "keywords": [ - "React", - "State-Management" - ], - "author": "BennoDev", - "license": "ISC", - "dependencies": { + "devDependencies": { "@types/chai": "^4.2.12", "@types/mocha": "^8.0.2", "@types/node": "^14.6.0", @@ -37,7 +30,7 @@ "tslib": "^2.0.0", "typescript": "^3.9.7" }, - "files": [ - "dist/**/*" + "workspaces": [ + "packages/*" ] } diff --git a/src/agile.ts b/src/agile.ts deleted file mode 100644 index 7d9b0f8a..00000000 --- a/src/agile.ts +++ /dev/null @@ -1,155 +0,0 @@ -import Runtime from "./runtime"; -import use, {Integration} from "./integrations/use"; -import SubController from "./sub"; -import State from "./state"; -import Storage, {StorageConfigInterface} from "./storage"; -import Collection, {CollectionConfig, DefaultDataItem} from "./collection"; -import Computed from "./computed"; -import API, {apiConfig} from "./api"; -import Event, {EventConfig, DefaultEventPayload} from "./event"; - -export interface AgileConfigInterface { - framework?: Integration | any // Integration = for custom frameworks | any = for existing frameworks like react - logJobs?: boolean // If Agile should log some stuff in the console - waitForMount?: boolean // If Agile should wait until the component mounted (note working yet) - storageConfig?: StorageConfigInterface // For custom storage (default: Local Storage) -} - -export default class Agile { - - public runtime: Runtime; - public integration: Integration | null = null; - public subController: SubController; - public storage: Storage; - - constructor(public config: AgileConfigInterface = {}) { - this.subController = new SubController(this); - this.runtime = new Runtime(this); - this.storage = new Storage(this, config.storageConfig || {}); - - // Init Framework - if (config.framework) - this.initFrameworkIntegration(config.framework); - else - console.warn("Agile: Don't forget to init a framework before using Agile") - - // Creates a global agile instance.. - this.globalBind(); - } - - - //========================================================================================================= - // Init Framework - //========================================================================================================= - /** - * Init a Framework like React or a custom one - */ - public initFrameworkIntegration(frameworkConstructor: any) { - use(frameworkConstructor, this); - } - - - //========================================================================================================= - // API - //========================================================================================================= - /** - * Create Agile API - * @param config Object - * @param config.options Object - Typescript default: RequestInit (headers, credentials, mode, etc...) - * @param config.baseURL String - Url to prepend to endpoints (without trailing slash) - * @param config.timeout Number - Time to wait for request before throwing error - */ - public API = (config: apiConfig) => new API(config); - - - //========================================================================================================= - // Storage - //========================================================================================================= - /** - * Create Agile Storage - */ - public Storage = (config: StorageConfigInterface) => new Storage(this, config); - - - //========================================================================================================= - // State - //========================================================================================================= - /** - * Create Agile State - * @param initialState Any - the value to initialize a State instance with - * @key State key/name which identifies the state - */ - public State = (initialState: ValueType, key?: string) => new State(this, initialState, key); - - - //========================================================================================================= - // Collection - //========================================================================================================= - /** - * Create Agile Collection - */ - public Collection = (config?: CollectionConfig) => new Collection(this, config); - - - //========================================================================================================= - // Computed - //========================================================================================================= - /** - * Create a Agile computed function - * @param deps Array - An array of state items to depend on - * @param computeFunction Function - A function where the return value is the state, ran every time a dep changes - */ - public Computed = (computeFunction: () => ComputedValueType, deps?: Array) => new Computed(this, computeFunction, deps); - - - //========================================================================================================= - // Event - //========================================================================================================= - /** - * Create a Pulse Event - */ - public Event = (config?: EventConfig) => new Event(this, config); - - - //========================================================================================================= - // Set Storage - //========================================================================================================= - /** - * Configures the Agile Storage - * @param storageConfig - */ - public setStorage(storageConfig: StorageConfigInterface): void { - // Get States which are already saved into a storage - const persistedStates = this.storage.persistedStates; - - // Define new Storage - this.storage = new Storage(this, storageConfig); - this.storage.persistedStates = persistedStates; - - // Save all already saved states into the new Storage - this.storage.persistedStates.forEach(state => state.persist(state.key)); - - // Save all already saved collections into the new Storage - this.storage.persistedCollections.forEach(collection => collection.persist(collection.key)); - } - - - //========================================================================================================= - // Global Bind - //========================================================================================================= - /** - * @internal - * Creates a global reference to the first pulse instance created this runtime - */ - private globalBind() { - try { - // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/globalThis - // @ts-ignore - if (!globalThis.__agile) globalThis.__agile = this; - } catch (error) { - // fail silently - } - } -} - - diff --git a/src/api/index.ts b/src/api/index.ts deleted file mode 100644 index b40fe166..00000000 --- a/src/api/index.ts +++ /dev/null @@ -1,179 +0,0 @@ -import * as http from 'http'; -import {copy, isValidUrl} from "../utils"; - -export interface AgileResponse { - data: DataType // request body data - timedout?: boolean // if request get timedout - status: number // request status code - raw?: Response // the raw response - type?: string | null // response type (for instance 'application/json') -} - -export interface apiConfig { - options: RequestInit // Request Options - baseURL?: string // baseURL (https://api.mysite.co) - path?: string // path (api) -> combined with baseUrl the url is https://api.mysite.co/api/... - timeout?: number // when the request should timeout -} - -export default class API { - - public config: apiConfig; - - constructor(config: apiConfig = {options: {}}) { - this.config = config; - } - - - //========================================================================================================= - // Get - //========================================================================================================= - /** - * Get request - */ - public get(endpoint: string, options?: RequestInit) { - return this.send('GET', endpoint, options); - } - - - //========================================================================================================= - // Post - //========================================================================================================= - /** - * Post request - */ - public post(endpoint: string, payload?: any, options?: RequestInit) { - return this.send('POST', endpoint, payload, options); - } - - - //========================================================================================================= - // Put - //========================================================================================================= - /** - * Put request - */ - public put(endpoint: string, payload?: any, options?: RequestInit) { - return this.send('PUT', endpoint, payload, options); - } - - - //========================================================================================================= - // Patch - //========================================================================================================= - /** - * Patch request - */ - public patch(endpoint: string, payload?: any, options?: RequestInit) { - return this.send('PATCH', endpoint, payload, options); - } - - //========================================================================================================= - // Delete - //========================================================================================================= - /** - * Delete request - */ - public delete(endpoint: string, payload?: any, options?: RequestInit) { - return this.send('DELETE', endpoint, payload, options); - } - - - //========================================================================================================= - // Send - //========================================================================================================= - /** - * @internal - * Will handle the request - */ - private async send(method: string, endpoint: string, payload?: any, options?: RequestInit): Promise { - let fullUrl: string; - let response: Response | undefined; - let timedout = false; - const config: apiConfig = copy(this.config); // Copying config because it will adapted for every specific request - - // Merge options together - if (options) - config.options = {...config.options, ...options}; - - // Inject method into request options - config.options.method = method; - - // If no header set it to an empty object (because in some conditions we have to add some stuff to this object) - // Haven't found a way by doing it with 'Headers'(https://stackoverflow.com/questions/48798236/const-initialization-error-with-requestinit-in-typescript) - if (!config.options.headers) - config.options.headers = {}; - - // Set Body - if (typeof payload === 'object') { - // Set body to stringyfied object payload - config.options.body = JSON.stringify(payload); - - // Set content type of Header to json - // @ts-ignore - config.options.headers['content-type'] = 'application/json'; - } else { - // Set body to payload - config.options.body = payload; - } - - // Construct endpoint (fullUrl) - let path = this.config.path ? ('/' + this.config.path) : ''; - if (endpoint.startsWith('http')) - fullUrl = endpoint; - else - fullUrl = `${this.config.baseURL ? this.config.baseURL : ''}${path}/${endpoint}`; - - // Warning if fullUrl might not be valid - if (!isValidUrl(fullUrl)) - console.warn("No valid url ", fullUrl); - - // Send Request with timeout - if (this.config.timeout) { - let t: any; - - // Create timeout Promise - const timeout = new Promise(resolve => { - t = setTimeout(() => { - timedout = true; - resolve(undefined); - }, this.config.timeout); - }); - - // Create request Promise - const request = new Promise((resolve, reject) => { - fetch(fullUrl, this.config.options) - .then(data => { - // Clear Timeout - clearTimeout(t); - - // Resolve Response(data) - resolve(data); - }) - .catch(reject); - }); - // @ts-ignore (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/race) - response = await Promise.race([timeout, request]); - } else { - // Send Request without timeout - response = await fetch(fullUrl, this.config.options); - } - - // Create FinalResponse - let finalResponse: AgileResponse = { - status: timedout ? 408 : (response?.status || 404), - raw: response, - data: {}, - type: response?.headers?.get('content-type'), - timedout: timedout - }; - - // Extract response data - if (finalResponse.type?.includes('application/json')) - finalResponse.data = await finalResponse.raw?.json(); - else if (typeof finalResponse.raw?.text === 'function') - finalResponse.data = await finalResponse.raw.text(); - - return finalResponse; - } -} diff --git a/src/collection/group.ts b/src/collection/group.ts deleted file mode 100644 index 0b246e5b..00000000 --- a/src/collection/group.ts +++ /dev/null @@ -1,223 +0,0 @@ -import Collection, {DefaultDataItem, ItemKey} from "./index"; -import State from "../state"; -import Agile from "../agile"; -import {defineConfig, normalizeArray} from "../utils"; -import {updateGroup} from "./perstist"; - -export type GroupKey = string | number; - -export interface GroupAddOptionsInterface { - method?: 'unshift' | 'push' // Method for adding item to group - overwrite?: boolean // Set to false to leave primary key in place if it already exists - background?: boolean // If the action should happen in the background -> no rerender -} - -export interface GroupConfigInterface { - key?: GroupKey // should be a unique key/name which identifies the group -} - -export default class Group extends State> { - collection: () => Collection; - - _output: Array = []; // Output of the group (Note: _value are only the keys of the collection items) - _states: Array<() => State> = []; // States of the Group - notFoundPrimaryKeys: Array = []; // Contains all key which can't be found in the collection - - constructor(agileInstance: Agile, collection: Collection, initialItems?: Array, config?: GroupConfigInterface) { - super(agileInstance, initialItems || [], config?.key); - this.collection = () => collection; - - // Set build() to state sideEffect - this.sideEffects = () => this.build(); - - // Set type of State to array because a group is an array of collection item keys - this.type(Array); - - // Initial Build - this.build(); - } - - public get output(): Array { - // Add state(group) to foundState (for auto tracking used states in computed functions) - if (this.agileInstance().runtime.trackState) - this.agileInstance().runtime.foundStates.add(this); - - return this._output; - } - - public get states(): Array> { - // Add state(group) to foundState (for auto tracking used states in computed functions) - if (this.agileInstance().runtime.trackState) - this.agileInstance().runtime.foundStates.add(this); - - return this._states.map(state => state()); - } - - //========================================================================================================= - // Has - //========================================================================================================= - /** - * Checks if the group contains the primaryKey - */ - public has(primaryKey: ItemKey) { - return this.value.findIndex(key => key === primaryKey) !== -1; - } - - - //========================================================================================================= - // Size - //========================================================================================================= - /** - * Returns the size of the group - */ - public get size(): number { - return this.value.length; - } - - - //========================================================================================================= - // Remove - //========================================================================================================= - /** - * Removes a item at primaryKey from the group - */ - public remove(itemKeys: ItemKey | ItemKey[], options: { background?: boolean } = {}): this { - const _itemKeys = normalizeArray(itemKeys); - const notExistingCollectionItems: Array = []; - - // Merge default values into options - options = defineConfig(options, { - background: false - }); - - _itemKeys.forEach(itemKey => { - // If item doesn't exist in collection add it to notExistingItems - if (!this.collection().findById(itemKey)) - notExistingCollectionItems.push(itemKey); - - // Check if primaryKey exists in group if not, return - if (this.value.findIndex(key => key === itemKey) === -1) { - console.error(`Agile: Couldn't find primaryKey '${itemKey}' in group`, this); - return; - } - - // Remove primaryKey from nextState - this.nextState = this.nextState.filter((i) => i !== itemKey); - - // Storage - if (this.key) - updateGroup(this.key, this.collection()); - }); - - // If all items don't exist in collection.. set background to true because the output won't change -> no rerender necessary - if (notExistingCollectionItems.length >= _itemKeys.length) - options.background = true; - - // Set State to nextState - this.ingest(options); - - return this; - } - - - //========================================================================================================= - // Add - //========================================================================================================= - /** - * Adds a key to a group - */ - public add(itemKeys: ItemKey | ItemKey[], options: GroupAddOptionsInterface = {}): this { - const _itemKeys = normalizeArray(itemKeys); - const notExistingCollectionItems: Array = []; - let newNextState = [...this.nextState]; // Had to create copy array otherwise also 'this.value' would change.. by changing 'this.nextState' directly. - - // Merge default values into options - options = defineConfig(options, { - method: 'push', - overwrite: false, - background: false - }); - - _itemKeys.forEach(itemKey => { - // Check if item already exists in group - const existsInGroup = newNextState.findIndex(key => key === itemKey) !== -1; - - // If item doesn't exist in collection add it to notExistingItems - if (!this.collection().findById(itemKey)) - notExistingCollectionItems.push(itemKey); - - // Removes temporary key from group to overwrite it properly - if (options.overwrite) - newNextState = newNextState.filter((i) => i !== itemKey); - // If we do not want to overwrite and key already exists in group, exit - else if (existsInGroup) - return; - - // Push or unshift into state - newNextState[options.method || 'push'](itemKey); - - // Storage - if (this.key) updateGroup(this.key, this.collection()); - }); - - // If all items don't exist in collection.. set background to true because the output won't change -> no rerender necessary - if (notExistingCollectionItems.length >= _itemKeys.length) - options.background = true; - - // Set nextState to newNextState - this.nextState = newNextState; - - // Set State to nextState - this.ingest({background: options.background}); - - return this; - } - - - //========================================================================================================= - // Build - //========================================================================================================= - /** - * @internal - * Will build the group -> it will set the output to the collection values - */ - public build() { - this.notFoundPrimaryKeys = []; - - // Check if _value is an array if not something went wrong because a group is always an array - if (!Array.isArray(this._value)) { - console.error("Agile: A group state has to be an array!"); - return; - } - - // Map though group _value (collectionKey array) and get their state from collection - const finalStates = this._value - .map((primaryKey) => { - // Get collection data at the primaryKey position - let data = this.collection().data[primaryKey]; - - // If no data found add this key to missing PrimaryKeys - if (!data) { - this.notFoundPrimaryKeys.push(primaryKey); - return; - } - - return data as State; - }).filter(item => item !== undefined); - - // Map though found States and return their publicValue - const finalOutput = finalStates - .map((state) => { - // @ts-ignore - return state.getPublicValue(); - }); - - // Log not found primaryKeys - if (this.notFoundPrimaryKeys.length > 0 && this.agileInstance().config.logJobs) - console.warn(`Agile: Couldn't find states with the primary keys in group '${this.key}'`, this.notFoundPrimaryKeys); - - // @ts-ignore - this._states = finalStates.map(state => (() => state)); - this._output = finalOutput; - } -} diff --git a/src/collection/index.ts b/src/collection/index.ts deleted file mode 100644 index ae61b3d1..00000000 --- a/src/collection/index.ts +++ /dev/null @@ -1,632 +0,0 @@ -import Agile from "../agile"; -import Item from "./item"; -import Group, {GroupConfigInterface, GroupKey} from "./group"; -import Selector, {SelectorKey} from "./selector"; -import {copy, defineConfig, flatMerge, isValidObject, normalizeArray} from "../utils"; -import State, {StateKey} from "../state"; -import {StorageKey} from "../storage"; -import {persistValue, removeItem, setItem} from "./perstist"; - -export type DefaultDataItem = { [key: string]: any }; -export type CollectionKey = string | number; -export type ItemKey = string | number; // The key of an item in a collection - -export interface CollectionConfigInterface { - groups?: { [key: string]: Group } | string[] - selectors?: { [key: string]: Selector } | string[] - key?: CollectionKey // should be a unique key/name which identifies the collection - primaryKey?: string // the primaryKey of an item (default is id) - defaultGroupKey?: ItemKey // The defaultGroupKey(Name).. in which all collected items get stored -} - -export interface CollectOptionsInterface { - patch?: boolean // If the item should be patched into existing item (only useful if Item already exists) - method?: 'push' | 'unshift' // Method for adding item to group - forEachItem?: (item: DataType, key: ItemKey, index: number) => void // To do something with collected items - background?: boolean // If the action should happen in the background -> no rerender -} - -export type CollectionConfig = - | CollectionConfigInterface - | ((collection: Collection) => CollectionConfigInterface); - -export default class Collection { - public agileInstance: () => Agile; - - public config: CollectionConfigInterface; - - public size: number = 0; // The amount of data items stored inside this collection - public data: { [key: string]: Item } = {}; // Collection data is stored here - public _key?: CollectionKey; - public isPersistCollection: boolean = false; // Is saved in storage - - public groups: { [key: string]: Group } = {}; - public selectors: { [key: string]: Selector } = {}; - - constructor(agileInstance: Agile, config: CollectionConfig = {}) { - this.agileInstance = () => agileInstance; - - // If collection config is a function, execute and assign to config - if (typeof config === 'function') - config = config(this); - - // Assign defaults to config - this.config = defineConfig(config, { - primaryKey: 'id', - groups: {}, - selectors: {}, - defaultGroupKey: 'default' - }); - - // Set Key - this._key = this.config.key; - - // Init Groups - this.initSubInstances('groups'); - - // Init Selectors - this.initSubInstances('selectors'); - } - - public set key(value: StateKey | undefined) { - this._key = value; - } - - public get key(): StateKey | undefined { - return this._key; - } - - - //========================================================================================================= - // Init SubInstances - //========================================================================================================= - /** - * @internal - * Init SubInstances like groups or selectors - */ - private initSubInstances(type: 'groups' | 'selectors') { - const subInstance = copy(this.config[type]) || {}; - let subInstanceObject: any = {}; - - // If subInstance is array transform it to an object with the fitting class - if (Array.isArray(subInstance)) { - for (let i = 0; i < subInstance.length; i++) { - let instance; - switch (type) { - case "groups": - instance = new Group(this.agileInstance(), this, [], {key: subInstance[i]}); - break; - case "selectors": - instance = new Selector(this, subInstance[i], {key: subInstance[i]}); - break; - default: - instance = 'unknown'; - } - subInstanceObject[subInstance[i]] = instance; - } - } else { - // If subInstance is Object.. set subInstanceObject to subInstance - subInstanceObject = subInstance; - } - - // If groups.. add default group - if (type === "groups") { - if (!subInstanceObject[this.config.defaultGroupKey || 'default']) - subInstanceObject[this.config.defaultGroupKey || 'default'] = new Group(this.agileInstance(), this, [], {key: this.config.defaultGroupKey || 'default'}); - } - - const keys = Object.keys(subInstanceObject); - for (let key of keys) { - // Set key to property name if it isn't set yet - if (!subInstanceObject[key].key) - subInstanceObject[key].key = key; - } - - // Set Collection instance - this[type] = subInstanceObject; - } - - - //========================================================================================================= - // Collect - //========================================================================================================= - /** - * Collect iterable data into this collection. - * Note: Data items must include a primary key (id) - */ - public collect(items: DataType | Array, groups?: GroupKey | Array, options: CollectOptionsInterface = {}) { - const _items = normalizeArray(items); - const _groups = normalizeArray(groups); - const defaultGroupKey = this.config.defaultGroupKey || 'default'; - const groupsToRebuild: Set = new Set(); - - // Assign defaults to options - options = defineConfig(options, { - method: 'push', - background: false, - patch: false - }); - - // Add default group if it hasn't been added (default group contains all items) - if (_groups.findIndex(groupName => groupName === defaultGroupKey) === -1) - _groups.push(defaultGroupKey); - - // Create not existing Groups - _groups.forEach(groupName => !this.groups[groupName] && this.createGroup(groupName)); - - _items.forEach((item, index) => { - // Check if the item already exists in the Collection - const itemExists = !!this.data[(item as any)[this.config.primaryKey || 'id']]; - - // Save items into Collection - let key = this.saveData(item, {patch: options.patch, background: options.background}); - - // Return if key doesn't exist (something went wrong in saveData, Note: Error will be logged in saveData) - if (!key) return; - - // Call forEachItem method - if (options.forEachItem) - options.forEachItem(item, key, index); - - // If item didn't exist.. check if the itemKey has already been added to a group before -> group need rebuild to has correct output - if (!itemExists) { - const groupKeys = Object.keys(this.groups); - groupKeys.forEach(groupName => { - // Get Group - const group = this.getGroup(groupName); - - // Check if itemKey exists in Group if so push it to groupsToRebuild - if (group.value.findIndex(primaryKey => primaryKey === (item as any)[this.config.primaryKey || 'id']) !== -1) - groupsToRebuild.add(group); - }); - } - - // Add key to groups - _groups.forEach(groupName => { - // @ts-ignore - this.groups[groupName].add(key, {method: options.method, background: options.background}) - }); - }); - - // Rebuild groups - groupsToRebuild.forEach(group => { - // Rebuild Group - group.build(); - - // Force Rerender to get the correct output in components - if (!options.background) group.ingest({forceRerender: true}) - }) - } - - - //========================================================================================================= - // Update - //========================================================================================================= - /** - * * Update data by updateKey(id) in a Agile Collection - */ - public update(updateKey: ItemKey, changes: DefaultDataItem | DataType, options: { addNewProperties?: boolean, background?: boolean } = {}): State | undefined { - // If item does not exist, return - if (!this.data.hasOwnProperty(updateKey)) { - console.error(`Agile: PrimaryKey '${updateKey} doesn't exist in collection `, this); - return undefined; - } - - // Assign defaults to config - options = defineConfig(options, { - addNewProperties: false, - background: false - }); - - const itemState = this.data[updateKey]; - const currentItemValue = copy(itemState.value) as any; - const primaryKey = this.config.primaryKey || ''; - - // Merge current Item value with changes - const finalItemValue = flatMerge(currentItemValue, changes, {addNewProperties: options.addNewProperties}); - - // Check if something has changed (stringifying because of possible object or array) - if (JSON.stringify(finalItemValue) === JSON.stringify(itemState.nextState)) - return this.data[finalItemValue[primaryKey]]; - - // Assign finalItemStateValue to nextState - itemState.nextState = finalItemValue; - - // Set State to nextState - itemState.ingest({background: options.background}); - - // If data key changes update it properly - if (currentItemValue[primaryKey] !== finalItemValue[primaryKey]) - this.updateItemPrimaryKeys(currentItemValue[primaryKey], finalItemValue[primaryKey], {background: options.background}); - - // Rebuild all groups that includes the primaryKey - this.rebuildGroupsThatIncludePrimaryKey(finalItemValue[primaryKey], {background: options.background}); - - // Return data at primaryKey (updated State) - return this.data[finalItemValue[primaryKey]]; - } - - - //========================================================================================================= - // Create Group - //========================================================================================================= - /** - * Create a group instance on this collection - */ - public createGroup(groupName: GroupKey, initialItems?: Array): Group { - // Check if Group already exist - if (this.groups.hasOwnProperty(groupName)) { - console.warn(`Agile: The Group with the name ${groupName} already exists!`); - return this.groups[groupName]; - } - - // Create new Group - const group = new Group(this.agileInstance(), this, initialItems, {key: groupName}); - - // Add new Group to groups - this.groups[groupName] = group; - - // Log Job - if (this.agileInstance().config.logJobs) - console.log(`Agile: Created Group called '${groupName}'`, group); - - return group; - } - - - //========================================================================================================= - // Create Selector - //========================================================================================================= - /** - * Create a selector instance on this collection - */ - public createSelector(selectorName: SelectorKey, id: ItemKey): Selector { - // Check if Selector already exist - if (this.selectors.hasOwnProperty(selectorName)) { - console.warn(`Agile: The Selector with the name ${selectorName} already exists!`); - return this.selectors[selectorName]; - } - - // Create new Selector - const selector = new Selector(this, id, {key: selectorName}); - - // Add new Selector to selectors - this.selectors[selectorName] = selector; - - // Log Job - if (this.agileInstance().config.logJobs) - console.log(`Agile: Created Selector called '${selectorName}'`, selector); - - return selector; - } - - - //========================================================================================================= - // Get Group - //========================================================================================================= - /** - * Return an group from this collection as Group instance (extends State) - */ - public getGroup(groupName: GroupKey): Group { - // Check if group exists - if (this.groups[groupName]) - return this.groups[groupName]; - - console.warn(`Agile: Group with name '${groupName}' doesn't exist!`); - - // Return empty group because it might get annoying to handle with undefined (can check if it exists with group.exists) - const group = new Group(this.agileInstance(), this, [], {key: 'dummy'}); - group.isPlaceholder = true; - return group; - } - - - //========================================================================================================= - // Get Selector - //========================================================================================================= - /** - * Return an selector from this collection as Selector instance (extends State) - */ - public getSelector(selectorName: SelectorKey): Selector | undefined { - // Check if selector exists - if (this.selectors[selectorName]) - return this.selectors[selectorName]; - - console.warn(`Agile: Selector with name '${selectorName}' doesn't exist!`); - - return undefined; - } - - - //========================================================================================================= - // Remove - //========================================================================================================= - /** - * Remove fromGroups or everywhere - */ - public remove(primaryKeys: ItemKey | Array) { - return { - fromGroups: (groups: Array | ItemKey) => this.removeFromGroups(primaryKeys, groups), - everywhere: () => this.removeData(primaryKeys) - }; - } - - - //========================================================================================================= - // Find By Id - //========================================================================================================= - /** - * Return an item from this collection by primaryKey as Item instance (extends State) - */ - public findById(id: ItemKey): Item | undefined { - if (!this.data.hasOwnProperty(id) || !this.data[id].exists) - return undefined; - - // Add state to foundState (for auto tracking used states in computed functions) - if (this.agileInstance().runtime.trackState) - this.agileInstance().runtime.foundStates.add(this.data[id]); - - // Return data by id - return this.data[id]; - } - - - //========================================================================================================= - // Get Value By Id - //========================================================================================================= - /** - * Return a value from this collection by primaryKey - */ - public getValueById(id: ItemKey): DataType | undefined { - let data = this.findById(id); - if (!data) return undefined; - - return data.value; - } - - - //========================================================================================================= - // Persist - //========================================================================================================= - /** - * Saves the collection in the local storage or in a own configured storage - * @param key - the storage key (if no key passed it will take the collection key) - */ - public persist(key?: StorageKey): this { - persistValue(this, key).then((value) => { - this.isPersistCollection = value - }); - return this; - } - - - //========================================================================================================= - // Group - //========================================================================================================= - /** - * Create a group instance under this collection (can be used in function based config) - */ - public Group(initialItems?: Array, config?: GroupConfigInterface): Group { - return new Group(this.agileInstance(), this, initialItems, config); - } - - - //========================================================================================================= - // Selector - //========================================================================================================= - /** - * Create a selector instance under this collection (can be used in function based config) - */ - public Selector(initialSelection: ItemKey, options?: {key?: SelectorKey}): Selector { - return new Selector(this, initialSelection, options); - } - - - //========================================================================================================= - // Update Data Key - //========================================================================================================= - /** - * @internal - * This will properly change the key of a collection item - */ - private updateItemPrimaryKeys(oldKey: ItemKey, newKey: ItemKey, options?: { background?: boolean }): void { - // If oldKey and newKey are the same, return - if (oldKey === newKey) return; - - // Assign defaults to config - options = defineConfig(options, { - background: false - }); - - // Create copy of data - const dataCopy = this.data[oldKey]; - - // Delete old reference - delete this.data[oldKey]; - - // Apply the data into data with new key - this.data[newKey] = dataCopy; - - // Update Groups - for (let groupName in this.groups) { - // Get Group - const group = this.getGroup(groupName); - - // If Group does not contain oldKey, continue - if (group.value.findIndex(key => key === oldKey) === -1) continue; - - // Replace the primaryKey at current index - group.nextState.splice(group.nextState.indexOf(oldKey), 1, newKey); - - // Set State(Group) to nextState - group.ingest({background: options?.background}); - } - - // Update Selector - for (let selectorName in this.selectors) { - // Get Selector - const selector = this.getSelector(selectorName); - if (!selector) continue; - - // If Selector doesn't watch on the oldKey, continue - if (selector.id !== oldKey) continue; - - // Replace the oldKey with the newKey - selector.select(newKey, {background: options?.background}); - } - } - - - //========================================================================================================= - // Remove From Groups - //========================================================================================================= - /** - * @internal - * Deletes Data from Groups - */ - public removeFromGroups(primaryKeys: ItemKey | Array, groups: GroupKey | Array) { - const _primaryKeys = normalizeArray(primaryKeys); - const _groups = normalizeArray(groups); - - _groups.forEach(groupKey => { - // Return if group doesn't exist in collection - if (!this.groups[groupKey]) { - console.error(`Agile: Couldn't find group('${groupKey}) in collection`, this); - return; - } - - // Remove primaryKeys from Group - _primaryKeys.forEach(primaryKey => { - const group = this.getGroup(groupKey); - group.remove(primaryKey); - }); - }); - } - - - //========================================================================================================= - // Delete Data - //========================================================================================================= - /** - * @internal - * Deletes data directly form the collection - */ - public removeData(primaryKeys: ItemKey | Array) { - const _primaryKeys = normalizeArray(primaryKeys); - const groupKeys = Object.keys(this.groups); - const selectorKeys = Object.keys(this.selectors); - const itemKeys = Object.keys(this.data); - - _primaryKeys.forEach(itemKey => { - // Check if primaryKey exists in collection, if not return - if (itemKeys.findIndex(key => itemKey.toString() === key) === -1) { - console.error(`Agile: Couldn't find primaryKey '${itemKey}' in collection`, this); - return; - } - - // Remove primaryKey from Groups (have to be above deleting the data because.. the remove function needs to know if the data exists or not) - groupKeys.forEach(groupKey => { - this.groups[groupKey].remove(itemKey); - }); - - // Remove Selectors with primaryKey - selectorKeys.forEach(selectorKey => { - delete this.selectors[selectorKey]; - }); - - // Remove primaryKey from collection data - delete this.data[itemKey]; - - // Decrease size - this.size--; - - // Storage - removeItem(itemKey, this); - }); - } - - - //========================================================================================================= - // Save Data - //========================================================================================================= - /** - * @internal - * Save data directly into the collection - */ - public saveData(data: DataType, options: { patch?: boolean, background?: boolean } = {}): ItemKey | null { - // Transform data to any because otherwise I have many type errors (because not defined object) - // https://stackoverflow.com/questions/57350092/string-cant-be-used-to-index-type - const _data = data as any; - - // Assign defaults to options - options = defineConfig(options, { - patch: false, - background: false, - }); - - // Get primaryKey (default: 'id') - const primaryKey = this.config.primaryKey || 'id'; - const itemKey = _data[primaryKey]; - - // Check if data is object if not return - if (!isValidObject(_data)) { - console.error("Agile: Collections items has to be an object for now!"); - return null; - } - - // Check if data has primaryKey - if (!_data.hasOwnProperty(primaryKey)) { - console.error("Agile: Collections items need a own primaryKey. Here " + this.config.primaryKey); - return null; - } - - // Create reference of data at the data key - let item: Item = this.data[itemKey]; - - // If the data already exists and config is to patch, patch data - if (item && options.patch) - item.patch(_data, {background: options.background}); - // If the data already exists and no config, overwrite data - else if (item) - item.set(_data, {background: options.background}); - // If data does not exist.. create new Item set and increase the size - else { - item = new Item(this, _data); - this.size++; - } - - // Set item at data itemKey - this.data[itemKey] = item; - - // Storage - setItem(itemKey, this); - - return itemKey; - } - - - //========================================================================================================= - // Rebuild Groups That Includes Primary Key - //========================================================================================================= - /** - * @internal - * Rebuild the Groups which contains the primaryKey - */ - public rebuildGroupsThatIncludePrimaryKey(primaryKey: ItemKey, options?: { background?: boolean, forceRerender?: boolean }): void { - // Assign defaults to config - options = defineConfig(options, { - background: false, - forceRerender: !options?.background // forceRerender false.. because forceRerender has more weight than background in runtime - }); - - // Rebuild groups that includes primaryKey - for (let groupKey in this.groups) { - // Get Group - const group = this.getGroup(groupKey); - - // Check if group contains primaryKey if so rebuild it - if (group.has(primaryKey)) - group.ingest({background: options?.background, forceRerender: options?.forceRerender}); - } - } -} diff --git a/src/collection/item.ts b/src/collection/item.ts deleted file mode 100644 index 72e731bb..00000000 --- a/src/collection/item.ts +++ /dev/null @@ -1,24 +0,0 @@ -import State from '../state'; -import Collection, {DefaultDataItem} from './index'; - -export default class Item extends State { - - private collection: () => Collection; - - // @ts-ignore - public output: DataType; // Defines the type of the output (will be set external) - - constructor(collection: Collection, data: DataType) { - super(collection.agileInstance(), data); - this.collection = () => collection; - - // Setting key of item to the data primaryKey - this.key = data && (data as any)[collection.config?.primaryKey || 'id']; - - // Add rebuildGroupsThatIncludePrimaryKey to sideEffects to rebuild the groups which includes the primaryKey if the state changes - this.sideEffects = () => collection.rebuildGroupsThatIncludePrimaryKey(this.key || ''); - - // Set type of State to object because a collection item is always an object - this.type(Object); - } -} diff --git a/src/collection/perstist.ts b/src/collection/perstist.ts deleted file mode 100644 index 20295918..00000000 --- a/src/collection/perstist.ts +++ /dev/null @@ -1,243 +0,0 @@ -import Collection, {ItemKey} from "./index"; -import Storage, {StorageKey} from "../storage"; -import {GroupKey} from "./group"; - -interface CollectionStorageData { - data: ItemKey[], - groups: GroupKey[] -} - -const storageItemKeyTemplate = '_${collectionKey}_item_${itemKey}'; -const storageGroupKeyTemplate = '_${collectionKey}_group_${groupKey}'; - -//========================================================================================================= -// Persist Value -//========================================================================================================= -/** - * Will persist the 'collection' into the configured storage with the key or if no key passed the state key - */ -export async function persistValue(collection: Collection, key?: StorageKey): Promise { - // Validate Key - const tempKey = validateKey(collection, key); - if (!tempKey) { - console.error("Agile: If your State has no key provided before using persist.. you have to provide a key here!"); - return false; - } - key = tempKey; - - // Get Storage - const storage = collection.agileInstance().storage; - - // Add Collection to persistedCollections in Storage - storage.persistedCollections.add(collection); - - // Call Handle which decides weather it has to add the storage value to the state or save the state into the storage - await handleStorageValue(storage, collection); - - return true; -} - - -//========================================================================================================= -// Set/Update Item -//========================================================================================================= -/** - * Set/Update Item in Storage - */ -export async function setItem(itemKey: ItemKey, collection: Collection) { - const storage = collection.agileInstance().storage; - - if (collection.isPersistCollection && collection.key) { - // Create Item Storage Key - const itemStorageKey = storageItemKeyTemplate - .replace('${collectionKey}', (collection.key || 'unknown').toString()) - .replace('${itemKey}', itemKey.toString()); - - // Get Value - const item = collection.data[itemKey]; - if (!item) return; - - // Log Job - if (collection.agileInstance().config.logJobs) - console.log(`Agile Storage(Set Item): ${itemStorageKey}`, item.getPersistableValue()); - - // Set StorageValue - await storage.set(itemStorageKey, item.getPersistableValue()); - } -} - - -//========================================================================================================= -// Remove Item -//========================================================================================================= -/** - * Removes Item from Storage - */ -export function removeItem(itemKey: ItemKey, collection: Collection) { - const storage = collection.agileInstance().storage; - - if (collection.isPersistCollection && collection.key) { - // Create Item Storage Key - const itemStorageKey = storageItemKeyTemplate - .replace('${collectionKey}', (collection.key || 'unknown').toString()) - .replace('${itemKey}', itemKey.toString()); - - // Log Job - if (collection.agileInstance().config.logJobs) - console.log(`Agile Storage(Remove Item): ${itemStorageKey}`); - - // Remove StorageValue - storage.remove(itemStorageKey); - } -} - - -//========================================================================================================= -// Update Group -//========================================================================================================= -/** - * Updates the Group in the storage - */ -export function updateGroup(groupKey: GroupKey, collection: Collection) { - const storage = collection.agileInstance().storage; - - if (collection.isPersistCollection && collection.key) { - // Create Group Storage Key - const groupStorageKey = storageGroupKeyTemplate - .replace('${collectionKey}', (collection.key || 'unknown').toString()) - .replace('${groupKey}', groupKey.toString()); - - // Get group - const group = collection.groups[groupKey]; - if (!group) return; - - // Log Job - if (collection.agileInstance().config.logJobs) - console.log(`Agile Storage(Update Group): ${groupStorageKey}`, group.value); - - // Set StorageValue - storage.set(groupStorageKey, group.value); - } -} - - -//========================================================================================================= -// Helper -//========================================================================================================= - -function validateKey(collection: Collection, key?: StorageKey): StorageKey | null { - // Get key from State key - if (!key && collection.key) - return collection.key; - - // Return null if no key can be found - if (!key) - return null; - - // Set this storage key as state key - collection.key = key; - return key; -} - -async function handleStorageValue(storage: Storage, collection: Collection) { - // Get Collection Data - const collectionData = await loadCollectionData(collection); - - // Log Job - if (collection.agileInstance().config.logJobs) - console.log("Agile Storage(CollectionData):", collectionData); - - // Load Collection Items - await loadCollectionItems(collectionData, collection); - - // Load Collection Groups - await loadCollectionGroups(collectionData, collection); -} - -async function loadCollectionData(collection: Collection): Promise { - const storage = collection.agileInstance().storage; - - const key = collection.key as StorageKey; - const storageValue = await storage.get(key); - - // If the collectionData doesn't exist in the storage yet.. create it - if (!storageValue) { - const collectionStorageData: CollectionStorageData = { - data: Object.keys(collection.data), - groups: Object.keys(collection.groups) - } - storage.set(key, collectionStorageData); - return collectionStorageData; - } - - return storageValue; -} - -async function loadCollectionItems(collectionStorageData: CollectionStorageData, collection: Collection) { - const storage = collection.agileInstance().storage; - - for (let itemKey of collectionStorageData.data) { - // Create Item Storage Key - const itemStorageKey = storageItemKeyTemplate - .replace('${collectionKey}', (collection.key || 'unknown').toString()) - .replace('${itemKey}', itemKey.toString()); - - // Get StorageValue - const storageValue = await storage.get(itemStorageKey); - - // Log Job - if (collection.agileInstance().config.logJobs) - console.log(`Agile Storage: ${itemStorageKey}`, storageValue); - - // If the value doesn't exist in the storage yet.. create it - if (!storageValue) { - storage.set(itemStorageKey, collection.data[itemKey].getPersistableValue()); - return; - } - - // If the value already exists in the storage.. load it into the collection - collection.collect(storageValue); - } -} - -async function loadCollectionGroups(collectionStorageData: CollectionStorageData, collection: Collection) { - const storage = collection.agileInstance().storage; - - for (let groupKey of collectionStorageData.groups) { - // Create Group Storage Key - const groupStorageKey = storageGroupKeyTemplate - .replace('${collectionKey}', (collection.key || 'unknown').toString()) - .replace('${groupKey}', groupKey.toString()); - - // Get StorageValue - const storageValue = await storage.get(groupStorageKey); - - // Log Job - if (collection.agileInstance().config.logJobs) - console.log(`Agile Storage: ${groupStorageKey}`, storageValue); - - // If the value doesn't exist in the storage yet.. create it - if (!storageValue) { - storage.set(groupStorageKey, collection.groups[groupKey].value); - return; - } - - // - If the value already exists in the storage.. load it into the collection - - // Get Group - const group = collection.groups[groupKey]; - - // If group doesn't exists, Create Group - if (!group) { - collection.createGroup(groupKey, storageValue); - continue; - } - - // If group exists, add items into group - for (let key of storageValue) { - if (!group.has(key)) { - group.add(key); - } - } - } -} diff --git a/src/collection/selector.ts b/src/collection/selector.ts deleted file mode 100644 index 1de76328..00000000 --- a/src/collection/selector.ts +++ /dev/null @@ -1,130 +0,0 @@ -import Collection, {DefaultDataItem, ItemKey} from "./index"; -import Computed from "../computed"; -import Item from "./item"; -import {persistValue} from "../state/persist"; -import {StorageKey} from "../storage"; -import {copy, defineConfig} from "../utils"; - -export type SelectorKey = string | number; - -export interface SelectorConfigInterface { - key?: SelectorKey // should be a unique key/name which identifies the selector -} - -export default class Selector extends Computed { - - public collection: () => Collection; - public _id: ItemKey; - - constructor(collection: Collection, id: ItemKey, config?: SelectorConfigInterface) { - // If no key provided set it to dummy (dummyKey) - if (!id) id = 'dummy'; - - // Instantiate Computed with 'computed' function - super(collection.agileInstance(), () => findData(collection, id)); - - if (config?.key) - this._key = config?.key; - - this.collection = () => collection; - this._id = id; - - // Set type of State to object because a collection item is always an object - this.type(Object); - } - - public set id(val: ItemKey) { - this.select(val); - } - - public get id() { - return this._id; - } - - - //========================================================================================================= - // Select - //========================================================================================================= - /** - * Changes the id on which the selector is watching - */ - public select(id: ItemKey, options?: { background?: boolean, sideEffects?: boolean }) { - // Assign defaults to config - options = defineConfig(options, { - background: false, - sideEffects: true - }); - - // Remove item if its a placeholder because if so it won't be needed without being selected by this selector - if (this.collection().data[this.id]?.isPlaceholder) - delete this.collection().data[this.id]; - - // Set _id to new id - this._id = id; - - // Update Computed Function with new key(id) - this.updateComputeFunction(() => findData(this.collection(), id), [], options); - - return this; - } - - - //========================================================================================================= - // Overwrite Persist - //========================================================================================================= - /** - * Saves the state in the local storage or in a own configured storage - * @param key - the storage key (if no key passed it will take the state key) - */ - public persist(key?: StorageKey): this { - persistValue(this, key); - return this; - } - - - //========================================================================================================= - // Overwrite getPerstiableValue - //========================================================================================================= - /** - * @internal - * Will return the perstiable Value of this state.. - */ - public getPersistableValue() { - return this.id; - } -} - - -//========================================================================================================= -// Find Data -//========================================================================================================= -/** - * Computed function for the Selector - */ -function findData(collection: Collection, id: ItemKey) { - // Find data by id in collection - let item = collection.findById(id); - - // If data is not found, create placeholder item, so that when real data is collected it maintains connection and causes a rerender - if (!item) { - const newItem = new Item(collection, {id: id} as any); - newItem.isPlaceholder = true; - collection.data[id] = newItem; - item = newItem; - } - - // If initial State is still {id: id}.. because of placeholder item and the value isn't {id: id} -> had got real value.. set the initial State to this first real value - if (JSON.stringify(item.initialState) === JSON.stringify({id: id}) && JSON.stringify(item.nextState) !== JSON.stringify({id: id})) { - item.initialState = copy(item.nextState); - item.previousState = copy(item.nextState); - } - - // Have to create the final Value here, to get added to the track states also if the item doesn't exist yet.. (otherwise auto tracking state wouldn't work -> this won't get called if the item changes ) - const finalValue = item.value; - - // If item doesn't exist return undefined.. otherwise it would return {id: id} - if (!item.exists) - return undefined; - - return finalValue; -} diff --git a/src/computed/index.ts b/src/computed/index.ts deleted file mode 100644 index 1b70d2bf..00000000 --- a/src/computed/index.ts +++ /dev/null @@ -1,117 +0,0 @@ -import State from "../state"; -import Agile from "../agile"; -import {defineConfig} from "../utils"; - -export default class Computed extends State { - public agileInstance: () => Agile; - - public computeFunction: () => ComputedValueType; - public deps: Array = []; - public hardCodedDeps: Array = []; - - constructor(agileInstance: Agile, computeFunction: () => ComputedValueType, deps: Array = []) { - super(agileInstance, computeFunction()); - this.agileInstance = () => agileInstance; - this.computeFunction = computeFunction; - this.hardCodedDeps = deps; - - // Recompute for setting initial state value and adding missing dependencies - this.recompute(); - } - - public set value(value: ComputedValueType) { - console.error('Agile: Can not mutate Computed value, please use recompute()'); - } - - public get value(): ComputedValueType { - return super.value; - } - - - //========================================================================================================= - // Recompute - //========================================================================================================= - /** - * Will call the computeFunction and update the dependencies - */ - public recompute(options?: { background?: boolean, sideEffects?: boolean }) { - // Assign defaults to config - options = defineConfig(options, { - background: false, - sideEffects: true - }); - - // Set State to nextState - this.ingest(options); - } - - - //========================================================================================================= - // Updates Compute Function - //========================================================================================================= - /** - * Updates the Compute Function - */ - public updateComputeFunction(computeFunction: () => ComputedValueType, deps: Array = [], options?: { background?: boolean, sideEffects?: boolean }) { - this.computeFunction = computeFunction; - this.hardCodedDeps = deps; - - // Recompute for setting initial state value and adding missing dependencies - this.recompute(options); - } - - - //========================================================================================================= - // Compute Values - //========================================================================================================= - /** - * @internal - * Will add auto tracked dependencies to this and calls the computeFunction - */ - public computeValue(): ComputedValueType { - // Set tracking state to true which will than track all states which for instance call state.value - this.agileInstance().runtime.trackState = true; - - // Call computeFunction - const computedValue = this.computeFunction(); - - // Get tracked states and set trackSate to false - let foundStates = this.agileInstance().runtime.getFoundStates(); - - // Handle foundStates dependencies - const newDeps: Array = []; - foundStates.forEach(state => { - // Add the state to newDeps - newDeps.push(state); - - // Add this as dependency of the state - state.dep.depend(this); - }); - - // Handle hardCoded dependencies - this.hardCodedDeps.forEach(state => { - // Add this as dependency of the state - state.dep.depend(this); - }); - - // Set deps - this.deps = [...this.hardCodedDeps, ...newDeps]; - - return computedValue; - } - - - //========================================================================================================= - // Overwriting some functions which can't be used in computed - //========================================================================================================= - - public patch() { - console.error('Agile: can not use patch method on Computed since the value is dynamic!'); - return this; - } - - public persist(key?: string): this { - console.error('Agile: Computed state can not be persisted since the value is dynamic!', key); - return this; - } -} diff --git a/src/event/index.ts b/src/event/index.ts deleted file mode 100644 index 9ae46658..00000000 --- a/src/event/index.ts +++ /dev/null @@ -1,201 +0,0 @@ -import Agile from "../agile"; -import {defineConfig} from "../utils"; -import {StateKey} from "../state"; - -export type DefaultEventPayload = { [key: string]: any }; -export type EventCallbackFunction = (payload?: PayloadType) => void; -export type EventKey = string | number; - -export interface EventConfig { - key?: EventKey - enabled?: boolean - maxUses?: number - delay?: number -} - -export default class Event { - public agileInstance: () => Agile; - - public config: EventConfig; - - public _key?: StateKey; // should be a unique key/name which identifies the event - public callbacks: Set> = new Set(); // Stores callback functions - public uses: number = 0; // How often the event has been used - private currentTimeout: any; // The current timeout (function) - private queue: Array = []; // Queue if something is currently in timeout - public enabled: boolean = true; - - // @ts-ignore - public payload: PayloadType; // Only holds reference to the PayloadType so that it can be read external (never defined) - - constructor(agileInstance: Agile, config: EventConfig = {}) { - this.agileInstance = () => agileInstance; - - // Assign defaults to config - this.config = defineConfig(config, { - enabled: true - }); - - // Set Key - this._key = this.config.key; - - // Set Enabled - if (this.config.enabled !== undefined) - this.enabled = this.config.enabled; - } - - public set key(value: StateKey | undefined) { - this._key = value; - } - - public get key(): StateKey | undefined { - return this._key; - } - - - //========================================================================================================= - // On - //========================================================================================================= - /** - * Register Callback Function - */ - public on(callback: EventCallbackFunction) { - const cleanUpFunction = () => this.unsub(callback); - - // Add callback to Event Callbacks - this.callbacks.add(callback); - - return cleanUpFunction; - } - - - //========================================================================================================= - // Trigger - //========================================================================================================= - /** - * Run all callback Functions - */ - public trigger(payload?: PayloadType) { - // If event is disabled, return - if (!this.enabled) return this; - - if (this.config.delay) - this.delayedTrigger(payload); - else - this.normalTrigger(payload); - - return this; - } - - - //========================================================================================================= - // Disable - //========================================================================================================= - /** - * Disables the Event - */ - public disable() { - this.enabled = false; - return this; - } - - //========================================================================================================= - // Enable - //========================================================================================================= - /** - * Enables the Event - */ - public enable() { - this.enabled = true; - return this; - } - - - //========================================================================================================= - // Reset - //========================================================================================================= - /** - * Resets the Event - */ - public reset() { - // Set Enabled - this.enabled = this.config.enabled || true; - - // Reset Uses - this.uses = 0; - - // Clear active timeout - clearTimeout(this.currentTimeout); - - return this; - } - - //========================================================================================================= - // Unsub - //========================================================================================================= - /** - * @internal - * Unsubs a callback - */ - private unsub(callback: EventCallbackFunction) { - this.callbacks.delete(callback); - } - - - //========================================================================================================= - // Normal Trigger - //========================================================================================================= - /** - * @internal - * Call event instantly - */ - private normalTrigger(payload?: PayloadType) { - // Call callbacks - this.callbacks.forEach(callback => callback(payload)); - - // Increase uses - this.uses++; - - // Check if maxUses has been reached, if so disable event - if (this.config.maxUses && this.uses >= this.config.maxUses) - // Disable Event - this.disable(); - } - - - //========================================================================================================= - // Delayed Trigger - //========================================================================================================= - /** - * @internal - * Call event after config.delay - */ - private delayedTrigger(payload?: PayloadType) { - // Check if a timeout is currently active if so add the payload to a queue - if (this.currentTimeout !== undefined) { - if (payload) this.queue.push(payload); - return; - } - - // Looper function which loops through the queue(payloads) - const looper = (payload?: PayloadType) => { - this.currentTimeout = setTimeout(() => { - // Reset currentTimeout - this.currentTimeout = undefined; - - // Call normalTrigger - this.normalTrigger(payload); - - // If items are in queue, continue with them - if (this.queue.length > 0) - looper(this.queue.shift()) - }, this.config.delay); - } - - // Call looper with current Payload - looper(payload); - - return; - } - -} diff --git a/src/index.ts b/src/index.ts deleted file mode 100644 index 58cb5d95..00000000 --- a/src/index.ts +++ /dev/null @@ -1,8 +0,0 @@ -import Agile from './agile'; - -export * from './state'; - -// Framework based exports -export * from './integrations/react'; - -export default Agile; diff --git a/src/integrations/react/hooks/AgileHOC.ts b/src/integrations/react/hooks/AgileHOC.ts deleted file mode 100644 index f73e46c8..00000000 --- a/src/integrations/react/hooks/AgileHOC.ts +++ /dev/null @@ -1,92 +0,0 @@ -import State from "../../../state"; -import Agile from "../../../index"; -import {getAgileInstance, normalizeArray} from "../../../utils"; -import {SubscriptionContainer} from "../../../sub"; - -export function AgileHOC(ReactComponent: any, deps?: Array | { [key: string]: State } | State, agileInstance?: Agile) { - let depsArray: Array; - let depsObject: { [key: string]: State }; - - if (deps instanceof State || Array.isArray(deps)) { - // Normalize Dependencies - depsArray = normalizeArray(deps || []); - - // Get Agile Instance - if (!agileInstance) { - if (depsArray.length > 0) { - const tempAgileInstance = getAgileInstance(depsArray[0]); - agileInstance = tempAgileInstance || undefined; - } else { - console.warn("Agile: Please don't pass an empty array!"); - } - } - } else if (typeof deps === "object") { - depsObject = deps; - - // Get Agile Instance - if (!agileInstance) { - const objectKeys = Object.keys(depsObject); - if (objectKeys.length > 0) { - const tempAgileInstance = getAgileInstance(depsObject[objectKeys[0]]); - agileInstance = tempAgileInstance || undefined; - } else { - console.warn("Agile: Please don't pass an empty object!"); - } - } - } else { - console.error("Agile: No Valid AgileHOC properties"); - return ReactComponent; - } - - // Check if agile Instance exists - if (!agileInstance) { - console.error("Agile: Failed to get Agile Instance"); - return ReactComponent; - } - - // Get React constructor - const React = agileInstance.integration?.frameworkConstructor; - if (!React) { - console.error("Agile: Failed to get Framework Constructor"); - return ReactComponent; - } - - return class extends React.Component { - public componentContainer: SubscriptionContainer | null = null; // Will be set in registerSubscription (sub.ts) - - public updatedProps = this.props; - - constructor(props: any) { - super(props); - - // Create HOC based Subscription with Array (Rerenders will here be caused via force Update) - if (depsArray) - agileInstance?.subController.subscribeWithSubsArray(this, depsArray); - - // Create HOC based Subscription with Object - if (depsObject) { - const response = agileInstance?.subController.subscribeWithSubsObject(this, depsObject); - this.updatedProps = { - ...props, - ...response?.props - } - - // Defines State for causing rerender (will be called in updateMethod) - this.state = depsObject; - } - } - - componentDidMount() { - if (agileInstance?.config.waitForMount) - agileInstance?.subController.mount(this); - } - - componentWillUnmount() { - agileInstance?.subController.unsubscribe(this); - } - - render() { - return React.createElement(ReactComponent, this.updatedProps); - } - }; -} diff --git a/src/integrations/react/hooks/useAgile.ts b/src/integrations/react/hooks/useAgile.ts deleted file mode 100644 index 5746fa71..00000000 --- a/src/integrations/react/hooks/useAgile.ts +++ /dev/null @@ -1,82 +0,0 @@ -import Group from "../../../collection/group"; -import State from "../../../state"; -import Collection from "../../../collection"; -import Agile from "../../../index"; -import {getAgileInstance, normalizeArray} from "../../../utils"; - -// Array Type -// https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-1.html -type AgileHookArrayType = { - [K in keyof T]: T[K] extends Group ? U[] - : T[K] extends State ? U - : T[K] extends Collection ? U[] - : T[K] extends undefined ? undefined - : never -}; - -// No Array Type -type AgileHookType = T extends Group ? U[] - : T extends State ? U - : T extends Collection ? U[] - : T extends undefined ? undefined - : never; - -// Array -export function useAgile>(deps: X, agileInstance?: Agile): AgileHookArrayType; - -// No Array -export function useAgile(deps: X, agileInstance?: Agile): AgileHookType; - -export function useAgile, Y extends State | Collection | undefined>(deps: X | Y, agileInstance?: Agile): AgileHookArrayType | AgileHookType { - // Normalize Dependencies - let depsArray = normalizeArray(deps) - .map(item => item instanceof Collection ? item.getGroup(item.config.defaultGroupKey || 'default') : item) - .filter(item => item !== undefined) as State[]; - - // Function which creates the return value - const getReturnValue = (depsArray: State[]): AgileHookArrayType | AgileHookType => { - // Return Public Value of State - if (depsArray.length === 1 && !Array.isArray(deps)) - return depsArray[0]?.getPublicValue() as AgileHookType; - - // Return Public Value of State in Array - return depsArray.map(dep => { - return dep.getPublicValue(); - }) as AgileHookArrayType; - } - - // Get Agile Instance - if (!agileInstance) { - const tempAgileInstance = getAgileInstance(depsArray[0]); - if (!tempAgileInstance) { - console.error("Agile: Failed to get Agile Instance"); - return getReturnValue(depsArray); - } - agileInstance = tempAgileInstance; - } - - // Get React constructor - const React = agileInstance.integration?.frameworkConstructor; - if (!React) { - console.error("Agile: Failed to get Framework Constructor"); - return getReturnValue(depsArray); - } - - // This is a Trigger State used to force the component to Re-render - const [_, set_] = React.useState({}); - - React.useEffect(function () { - // Create a callback base subscription, Callback invokes re-render Trigger - const subscriptionContainer = agileInstance?.subController.subscribeWithSubsArray( - () => { - set_({}); - }, - depsArray - ); - - // Unsubscribe on Unmount - return () => agileInstance?.subController.unsubscribe(subscriptionContainer); - }, []); - - return getReturnValue(depsArray); -} diff --git a/src/integrations/react/hooks/useEvent.ts b/src/integrations/react/hooks/useEvent.ts deleted file mode 100644 index 7bf99370..00000000 --- a/src/integrations/react/hooks/useEvent.ts +++ /dev/null @@ -1,27 +0,0 @@ -import Event, {EventCallbackFunction} from "../../../event"; -import Agile from "../../../index"; -import {getAgileInstance} from "../../../utils"; - -export function useEvent(event: E, callback: EventCallbackFunction, agileInstance?: Agile) { - // Get Agile Instance - if (!agileInstance) { - const tempAgileInstance = getAgileInstance(event); - if (!tempAgileInstance) { - console.error("Agile: Failed to get Agile Instance"); - return; - } - agileInstance = tempAgileInstance; - } - - // Get React constructor - const React = agileInstance.integration?.frameworkConstructor; - if (!React) { - console.error("Agile: Failed to get Framework Constructor"); - return; - } - - React.useEffect(function () { - // Call event on component mount and remove event on component unmount - return event.on(callback); - }, []); -} diff --git a/src/integrations/react/index.ts b/src/integrations/react/index.ts deleted file mode 100644 index e8f35d34..00000000 --- a/src/integrations/react/index.ts +++ /dev/null @@ -1,7 +0,0 @@ -import reactIntegration from "./react.integration"; - -export {useAgile} from './hooks/useAgile'; -export {AgileHOC} from './hooks/AgileHOC'; -export {useEvent} from './hooks/useEvent'; - -export default reactIntegration; diff --git a/src/integrations/react/react.integration.ts b/src/integrations/react/react.integration.ts deleted file mode 100644 index 6fe0e05c..00000000 --- a/src/integrations/react/react.integration.ts +++ /dev/null @@ -1,31 +0,0 @@ -import Agile from "../../index"; -import {Integration} from "../use"; - - -//========================================================================================================= -// Framework Integration -//========================================================================================================= - -const reactIntegration: Integration = { - name: 'react', - bind(agileInstance: Agile) { - // Not sure if usePulse should get into the pulseInstance - // pulseInstance.usePulse = (deps: Array) => usePulse(deps, pulseInstance); - // if (agileInstance.config.logJobs) console.log("Agile: Successfully binded React to Agile") - }, - updateMethod(componentInstance: any, updatedData: Object) { - // UpdatedData will be empty if the AgileHOC doesn't get an object as deps - - if (Object.keys(updatedData).length !== 0) { - // Update Props - componentInstance.updatedProps = {...componentInstance.updatedProps, ...updatedData}; - - // Set State - componentInstance.setState(updatedData); - } else { - componentInstance.forceUpdate(); - } - } -}; - -export default reactIntegration; diff --git a/src/integrations/test/hooks/useAgile.ts b/src/integrations/test/hooks/useAgile.ts deleted file mode 100644 index a2ea0c2e..00000000 --- a/src/integrations/test/hooks/useAgile.ts +++ /dev/null @@ -1,68 +0,0 @@ -import State from "../../../state"; -import Collection from "../../../collection"; -import Agile from "../../../index"; -import {getAgileInstance, normalizeArray} from "../../../utils"; -import Group from "../../../collection/group"; - - -//========================================================================================================= -// Use Test Hook -// NOTE: This is only used for Tests -//========================================================================================================= - -// Array Type -// https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-1.html -type AgileHookArrayType = { - [K in keyof T]: T[K] extends Group ? U[] - : T[K] extends State ? U - : T[K] extends Collection ? U[] - : T[K] extends undefined ? undefined - : never -}; - -// No Array Type -type AgileHookType = T extends Group ? U[] - : T extends State ? U - : T extends Collection ? U[] - : T extends undefined ? undefined - : never; - -// Array -export function useAgile>(deps: X, callBackFunction: Function, agileInstance?: Agile): AgileHookArrayType; - -// No Array -export function useAgile(deps: X, callBackFunction: Function, agileInstance?: Agile): AgileHookType; - -export function useAgile, Y extends State | Collection | undefined>(deps: X | Y, callBackFunction: Function, agileInstance?: Agile): AgileHookArrayType | AgileHookType { - // Normalize Dependencies - let depsArray = normalizeArray(deps) - .map(item => item instanceof Collection ? item.getGroup(item.config.defaultGroupKey || 'default') : item) - .filter(item => item !== undefined) as State[]; - - // Function which creates the return value - const getReturnValue = (depsArray: State[]): AgileHookArrayType | AgileHookType => { - // Return Public Value of State - if (depsArray.length === 1 && !Array.isArray(deps)) - return depsArray[0]?.getPublicValue() as AgileHookType; - - // Return Public Value of State in Array - return depsArray.map(dep => { - return dep.getPublicValue(); - }) as AgileHookArrayType; - } - - // Get Agile Instance - if (!agileInstance) { - const tempAgileInstance = getAgileInstance(depsArray[0]); - if (!tempAgileInstance) { - console.error("Agile: Failed to get Agile Instance"); - return getReturnValue(depsArray); - } - agileInstance = tempAgileInstance; - } - - // Create a callback base subscription, Callback invokes re-render Trigger - agileInstance?.subController.subscribeWithSubsArray(callBackFunction, depsArray); - - return getReturnValue(depsArray); -} diff --git a/src/integrations/test/hooks/useEvent.ts b/src/integrations/test/hooks/useEvent.ts deleted file mode 100644 index 513ea7c7..00000000 --- a/src/integrations/test/hooks/useEvent.ts +++ /dev/null @@ -1,18 +0,0 @@ -import Event, {EventCallbackFunction} from "../../../event"; -import Agile from "../../../index"; -import {getAgileInstance} from "../../../utils"; - -export function useEvent(event: E, callback: EventCallbackFunction, agileInstance?: Agile) { - // Get Agile Instance - if (!agileInstance) { - const tempAgileInstance = getAgileInstance(event); - if (!tempAgileInstance) { - console.error("Agile: Failed to get Agile Instance"); - return; - } - agileInstance = tempAgileInstance; - } - - // Call on Event - event.on(callback); -} diff --git a/src/integrations/test/index.ts b/src/integrations/test/index.ts deleted file mode 100644 index 2f96a5ec..00000000 --- a/src/integrations/test/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export {useAgile} from './hooks/useAgile'; -export {useEvent} from './hooks/useEvent'; diff --git a/src/integrations/use.ts b/src/integrations/use.ts deleted file mode 100644 index c9638021..00000000 --- a/src/integrations/use.ts +++ /dev/null @@ -1,94 +0,0 @@ -import Agile from "../agile"; -import reactIntegration from "./react"; - -export interface Integration { - ready?: boolean; - frameworkConstructor?: any; // The actual framework for instance React - name?: any; // The name of the framework - bind?: (agileInstance: Agile) => void; // Will be called if the framework got successful instantiated - updateMethod?: (componentInstance: any, updatedData: Object) => void; // Will be called if a State changes (Only by Component based Subscription) -} - -// Required Properties of a custom Integration -const requiredIntegrationProperties = ['name', 'bind', 'updateMethod']; - -// This Integration will injected into Agile.integration -const finalIntegration: Integration = { - ready: false -}; - -export default function use(framework: any, agileInstance: Agile) { - const frameworkName = getFrameworkName(framework); - - // Integrate Framework - switch (frameworkName) { - case 'react': - integrate(reactIntegration, 'react'); - break; - - case 'custom': - if (validateCustomFramework(framework as Integration)) - integrate(framework, 'custom'); - break; - - default: - // Should never happen - } - - // Assign Framework Constructor to framework if its not a custom framework - // because custom Frameworks has to set the frameworkConstructor (direct dependency to Framework (React)) on their own - // and have to pass an Integration and not directly a framework - if (frameworkName !== 'custom') - finalIntegration.frameworkConstructor = framework; - - // Inject Integration into Agile - agileInstance.integration = finalIntegration; - - // If the Integration is ready call integration.bind() - if (agileInstance.integration.ready) { - if (agileInstance.integration.bind) - agileInstance.integration.bind(agileInstance); - if (agileInstance.config.logJobs) console.log(`Agile: Successfully integrated '${frameworkName}'`); - } else - console.error('Agile: Failed to integrate with framework! It\'s possible you didn\'t call Pulse.initFrameworkIntegration() before new Pulse.'); -} - - -//========================================================================================================= -// Helper -//========================================================================================================= - -function integrate(frameworkIntegration: Integration, frameworkName: string) { - // Bind all properties from integration to our main Integration Object - Object.keys(frameworkIntegration).forEach(property => { - // @ts-ignore - finalIntegration[property] = frameworkIntegration[property]; - }); - - // Assign Name - finalIntegration.name = frameworkIntegration.name || frameworkName; - - // Set Integration to Ready (can be used) - finalIntegration.ready = true; -} - -function validateCustomFramework(customIntegration: Integration): boolean { - let valid: boolean = true; - - // Check if custom Integration has all required properties - requiredIntegrationProperties.forEach(property => { - if (!customIntegration.hasOwnProperty(property)) valid = false; - }); - - return valid; -} - -function getFrameworkName(frameworkConstructor: any): string { - let name: string = 'custom'; - - // Check if framework is React - if (frameworkConstructor.hasOwnProperty('__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED')) - return 'react'; - - return name; -} diff --git a/src/runtime.ts b/src/runtime.ts deleted file mode 100644 index 4ffd9df4..00000000 --- a/src/runtime.ts +++ /dev/null @@ -1,286 +0,0 @@ -import State from "./state"; -import Agile from "./agile"; -import {copy, defineConfig} from "./utils"; -import {CallbackContainer, SubscriptionContainer} from "./sub"; -import Computed from "./computed"; - -export interface JobInterface { - state: State - newStateValue?: any - options?: { - background?: boolean - sideEffects?: boolean - forceRerender?: boolean - } -} - -export interface JobConfigInterface { - perform?: boolean // Should preform the job instantly - background?: boolean // Shouldn't cause an rerender during the perform process - sideEffects?: boolean // Should perform sideEffects like rebuilding groups - forceRerender?: boolean // Force rerender although for instance the values are the same -} - -export default class Runtime { - public agileInstance: () => Agile; - - // Queue system - private currentJob: JobInterface | null = null; - private jobQueue: Array = []; - private jobsToRerender: Array = []; - - // Used for tracking computed dependencies - public trackState: boolean = false; // Check if agile should track states - public foundStates: Set = new Set(); // States which were tracked during the track time - - public internalIngestKey = "This is an Internal Key for ingesting internal stuff!"; - - constructor(agileInstance: Agile) { - this.agileInstance = () => agileInstance; - } - - - //========================================================================================================= - // Ingest - //========================================================================================================= - /** - * @internal - * Creates a Job out of State and new Value and than add it to a job queue - * Note: its not possible to set a state to undefined because undefined is used for internal activities! - */ - public ingest(state: State, newStateValue?: any, options: JobConfigInterface = {}): void { - // Merge default values into options - options = defineConfig(options, { - perform: true, - background: false, - sideEffects: true, - forceRerender: false - }); - - // Create Job - const job: JobInterface = { - state: state, - newStateValue: newStateValue, - options: { - background: options.background, - sideEffects: options.sideEffects, - forceRerender: options.forceRerender - } - }; - - // Grab nextState if newState not passed or compute if needed - if (newStateValue === this.internalIngestKey) { - if (job.state instanceof Computed) - job.newStateValue = job.state.computeValue(); - else - job.newStateValue = job.state.nextState - } - - // Check if state value und newStateValue are the same.. if so return except force Rerender (stringifying because of possible object or array) - if (JSON.stringify(state.value) === JSON.stringify(job.newStateValue) && !options.forceRerender) { - if (this.agileInstance().config.logJobs) - console.warn("Agile: Doesn't perform job because state values are the same! ", job); - return; - } - - // Logging - if (this.agileInstance().config.logJobs) - console.log(`Agile: Created Job(${job.state.key})`, job); - - // Push the Job to the Queue (safety.. that no Job get forgotten) - this.jobQueue.push(job); - - // Perform the Job - if (options.perform) { - const performJob = this.jobQueue.shift(); - if (performJob) - this.perform(performJob); - else - console.warn("Agile: No Job in queue ", job) - } - } - - - //========================================================================================================= - // Perform - //========================================================================================================= - /** - * @internal - * Perform a State Update - */ - private perform(job: JobInterface): void { - // Set Job to currentJob - this.currentJob = job; - - // Set Previous State - job.state.previousState = copy(job.state.value); - - // Write new value into the State - job.state.privateWrite(job.newStateValue); - - // Set isSet - job.state.isSet = job.newStateValue !== job.state.initialState; - - // Set is placeholder to false, because it has got a value - if (job.state.isPlaceholder) - job.state.isPlaceholder = false; - - // Perform SideEffects like watcher functions or state.sideEffects - this.sideEffects(job); - - // Set Job as completed (The deps and subs of completed jobs will be updated) - if (!job.options?.background || job.options?.forceRerender) - this.jobsToRerender.push(job); - - // Reset Current Job - this.currentJob = null; - - // Logging - if (this.agileInstance().config.logJobs) - console.log(`Agile: Completed Job(${job.state.key})`, job); - - // Continue the Loop and perform the next job.. if no job is left update the Subscribers for each completed job - if (this.jobQueue.length > 0) { - const performJob = this.jobQueue.shift(); - if (performJob) - this.perform(performJob); - else - console.warn("Agile: Failed to perform Job ", job); - } else { - // https://stackoverflow.com/questions/9083594/call-settimeout-without-delay - setTimeout(() => { - // Cause rerender on Subscribers - this.updateSubscribers(); - }) - } - } - - - //========================================================================================================= - // Side Effect - //========================================================================================================= - /** - * @internal - * SideEffects are sideEffects of the perform function.. for instance the watchers - */ - private sideEffects(job: JobInterface) { - const state = job.state; - - // Call Watchers - for (let watcher in state.watchers) - if (typeof state.watchers[watcher] === 'function') - state.watchers[watcher](state.getPublicValue()); - - // Call State SideEffects - if (typeof state.sideEffects === 'function' && job.options?.sideEffects) - state.sideEffects(); - - // Ingest Dependencies of State (Perform is false because it will be performed anyway after this sideEffect) - state.dep.deps.forEach((state) => this.ingest(state, this.internalIngestKey, {perform: false})); - } - - - //========================================================================================================= - // Update Subscribers - //========================================================================================================= - /** - * @internal - * This will be update all Subscribers of complete jobs - */ - private updateSubscribers(): void { - // Check if Agile has an integration because its useless to go trough this process without framework - // It won't happen anything because the state has no subs.. but this check here will maybe improve the performance - if (!this.agileInstance().integration) { - this.jobsToRerender = []; - return; - } - - // Subscriptions that has to be updated (Set = For preventing double subscriptions without further checks) - const subscriptionsToUpdate: Set = new Set(); - - // Map through Jobs to Rerender - this.jobsToRerender.forEach(job => - // Map through subs of the current Job State - job.state.dep.subs.forEach(subscriptionContainer => { - // Check if subscriptionContainer is ready - if (!subscriptionContainer.ready) - console.warn("Agile: SubscriptionContainer isn't ready yet ", subscriptionContainer); - - // For a Container that require props to be passed - if (subscriptionContainer.passProps) { - let localKey: string | null = null; - - // Find the local Key for this update by comparing the State instance from this Job to the State instances in the propStates object - for (let key in subscriptionContainer.propStates) - if (subscriptionContainer.propStates[key] === job.state) - localKey = key; - - // If matching key is found push it into the SubscriptionContainer propKeysChanged where it later will be build to an changed prop object - if (localKey) - subscriptionContainer.propKeysChanged.push(localKey); - } - subscriptionsToUpdate.add(subscriptionContainer); - })); - - // Perform Component or Callback updates - subscriptionsToUpdate.forEach(subscriptionContainer => { - // If Callback based subscription call the Callback Function - if (subscriptionContainer instanceof CallbackContainer) { - subscriptionContainer.callback(); - return; - } - - // If Component based subscription call the updateMethod which every framework has to define - if (this.agileInstance().integration?.updateMethod) - // @ts-ignore - this.agileInstance().integration?.updateMethod(subscriptionContainer.component, this.formatChangedPropKeys(subscriptionContainer)); - else - console.warn("Agile: The framework which you are using doesn't provide an updateMethod so it might be possible that no rerender will be triggered"); - }); - - // Log Job - if (this.agileInstance().config.logJobs && subscriptionsToUpdate.size > 0) - console.log("Agile: Rerendered Components ", subscriptionsToUpdate); - - // Reset Jobs to Rerender - this.jobsToRerender = []; - } - - - //========================================================================================================= - // Format Changed Prop Keys - //========================================================================================================= - /** - * @internal - * Builds an object out of propKeysChanged in the SubscriptionContainer - */ - public formatChangedPropKeys(subscriptionContainer: SubscriptionContainer): { [key: string]: any } { - const finalObject: { [key: string]: any } = {}; - - // Build Object - subscriptionContainer.propKeysChanged.forEach(changedKey => { - if (subscriptionContainer.propStates) - finalObject[changedKey] = subscriptionContainer.propStates[changedKey].value; - }); - - return finalObject; - } - - - //========================================================================================================= - // Get Found State - //========================================================================================================= - /** - * @internal - * Will return all tracked States - */ - public getFoundStates() { - const finalFoundStates = this.foundStates; - - // Reset tracking - this.trackState = false; - this.foundStates = new Set(); - - return finalFoundStates; - } -} diff --git a/src/state/dep.ts b/src/state/dep.ts deleted file mode 100644 index 5a12d81f..00000000 --- a/src/state/dep.ts +++ /dev/null @@ -1,26 +0,0 @@ -import {SubscriptionContainer} from '../sub'; -import State from "./index"; - -export default class Dep { - public deps: Set = new Set(); // Dependencies from the State - public subs: Set = new Set(); // Subscriptions for instance a component subscribes to a state to get rerendered if the state changes - - constructor(initialDeps?: Array) { - if (!initialDeps) return; - - // Add Initial Dependencies to Deps - initialDeps.forEach(dep => this.deps.add(dep)); - } - - - //========================================================================================================= - // Depend - //========================================================================================================= - /** - * Add new State as dependency - */ - public depend(state: State) { - if (state.dep !== this && !this.deps.has(state)) - this.deps.add(state); - } -} diff --git a/src/state/index.ts b/src/state/index.ts deleted file mode 100644 index 89d3be30..00000000 --- a/src/state/index.ts +++ /dev/null @@ -1,339 +0,0 @@ -import Agile from "../agile"; -import {copy, defineConfig, flatMerge, isValidObject} from "../utils"; -import Dep from "./dep"; -import {persistValue, updateValue} from "./persist"; -import {StorageKey} from "../storage"; - -export type StateKey = string | number; - -export interface PersistSettingsInterface { - isPersisted: boolean // Is State persisted - persistKey?: string | number // Current Persist Key.. for handling twice persisted states -} - -export default class State { - public agileInstance: () => Agile; - - public _key?: StateKey; // should be a unique key/name which identifies the state - public valueType?: string; // primitive types for js users - public dep: Dep; // Includes the subscriptions and dependencies of the state - public watchers: { [key: string]: (value: any) => void } = {}; - public sideEffects?: Function; // SideEffects can be set by extended classes, such as Groups to build their output. - public isSet: boolean = false; // Has been changed from initial value - public persistSettings: PersistSettingsInterface; // Includes persist 'settings' (have to rename if I got an better name) - public output?: any; // This contains the public value.. if _value doesn't contain the public value (Used for example by collections) - public isPlaceholder: boolean = false; // Defines if the state is a placeholder or not - - public initialState: ValueType; - public _value: ValueType; // The current value of the state - public previousState: ValueType; // Will be set in runtime - public nextState: ValueType; // The next state is used internal and represents the nextState which can be edited as wished (cleaner than always setting the state) - - // public computeValue?: (newState?: ValueType) => ValueType; - - constructor(agileInstance: Agile, initialState: ValueType, key?: StateKey, deps: Array = []) { - this.agileInstance = () => agileInstance; - this.initialState = initialState; - this.dep = new Dep(deps); - this._key = key; - this._value = initialState; - this.previousState = initialState; - this.nextState = initialState; - this.persistSettings = { - isPersisted: false - } - } - - public set value(value: ValueType) { - this.set(value); - } - - public get value(): ValueType { - // Add state to foundState (for auto tracking used states in computed functions) - if (this.agileInstance().runtime.trackState) - this.agileInstance().runtime.foundStates.add(this); - - return this._value; - } - - public set key(value: StateKey | undefined) { - this._key = value; - } - - public get key(): StateKey | undefined { - return this._key; - } - - - //========================================================================================================= - // Set - //========================================================================================================= - /** - * Directly set state to a new value - */ - public set(value: ValueType, options: { background?: boolean, sideEffects?: boolean } = {}): this { - // Assign defaults to options - options = defineConfig(options, { - sideEffects: true, - background: false - }); - - // Check if Type is Correct - if (this.valueType && !this.isCorrectType(value)) { - console.warn(`Agile: Incorrect type (${typeof value}) was provided. Type fixed to ${this.valueType}`); - return this; - } - - // Check if something has changed (stringifying because of possible object or array) - if (JSON.stringify(this.value) === JSON.stringify(value)) - return this; - - // Ingest updated value - this.agileInstance().runtime.ingest(this, value, { - background: options.background, - sideEffects: options.sideEffects - }); - - return this; - } - - - //========================================================================================================= - // Ingest - //========================================================================================================= - /** - * @internal - * Will ingest the nextState or the computedValue (rebuilds state) - */ - public ingest(options: { background?: boolean, sideEffects?: boolean, forceRerender?: boolean } = {}) { - // Assign defaults to options - options = defineConfig(options, { - sideEffects: true, - background: false, - forceRerender: false - }); - - this.agileInstance().runtime.ingest(this, this.agileInstance().runtime.internalIngestKey, { - background: options.background, - sideEffects: options.sideEffects, - forceRerender: options.forceRerender - }); - } - - - //========================================================================================================= - // Type - //========================================================================================================= - /** - * This is thought for js users.. because ts users can set the type in <> - * @param type - wished type of the state - */ - public type(type: any): this { - // Supported types - const supportedTypes = ['String', 'Boolean', 'Array', 'Object', 'Number']; - - // Check if type is a supported Type - if (supportedTypes.findIndex(supportedType => supportedType === type.name) === -1) { - console.warn(`Agile: '${type}' is not supported! Supported types: String, Boolean, Array, Object, Number`); - return this; - } - - // Set valueType - this.valueType = type.name.toLowerCase(); - return this; - } - - - //========================================================================================================= - // Undo - //========================================================================================================= - /** - * Will set the state to the previous State - */ - public undo() { - this.set(this.previousState); - } - - - //========================================================================================================= - // Reset - //========================================================================================================= - /** - * Will reset the state to the initial value - */ - public reset(): this { - // Remove State from Storage (because it is than the initial State again and there is no need to save it anymore) - if (this.persistSettings.isPersisted && this.persistSettings.persistKey) - this.agileInstance().storage.remove(this.persistSettings.persistKey); - - // Set State to initial State - this.set(this.initialState); - return this; - } - - - //========================================================================================================= - // Patch - //========================================================================================================= - /** - * Will merge the changes into the state - */ - public patch(targetWithChanges: object, options: { addNewProperties?: boolean, background?: boolean } = {}): this { - // Check if state is object.. because only objects can use the patch method - if (!isValidObject(this.nextState)) { - console.warn("Agile: You can't use the patch method on a non object state!"); - return this; - } - - // Check if targetWithChanges is an Object.. because you can only patch objects into the State Object - if (!isValidObject(targetWithChanges)) { - console.warn("Agile: TargetWithChanges has to be an object!"); - return this; - } - - // Assign defaults to options - options = defineConfig(options, { - addNewProperties: true, - background: false - }); - - // Merge targetWithChanges into next State - this.nextState = flatMerge(this.nextState, targetWithChanges, options); - - // Check if something has changed (stringifying because of possible object or array) - if (JSON.stringify(this.value) === JSON.stringify(this.nextState)) - return this; - - // Set State to nextState - this.ingest({background: options.background}); - - this.isSet = this.nextState !== this.initialState; - return this; - } - - //========================================================================================================= - // Watch - //========================================================================================================= - /** - * Will always be called if the state changes - * @param key - The key of the watch method - * @param callback - The callback function - */ - public watch(key: string, callback: (value: ValueType) => void): this { - // Check if callback is a function (js) - if (typeof callback !== 'function') { - console.error('Agile: A watcher callback function has to be an function!'); - return this; - } - - // Add callback with key to watchers - this.watchers[key] = callback; - - return this; - } - - - //========================================================================================================= - // Remove Watcher - //========================================================================================================= - /** - * Removes a watcher called after the key - * @param key - the key of the watcher function - */ - public removeWatcher(key: string): this { - delete this.watchers[key]; - return this; - } - - - //========================================================================================================= - // Persist - //========================================================================================================= - /** - * Saves the state in the local storage or in a own configured storage - * @param key - the storage key (if no key passed it will take the state key) - */ - public persist(key?: StorageKey): this { - persistValue(this, key); - return this; - } - - - //========================================================================================================= - // Copy - //========================================================================================================= - /** - * Returns a fresh copy of the current value - */ - public copy(): ValueType { - return copy(this.value); - } - - - //========================================================================================================= - // Exists - //========================================================================================================= - /** - * Checks if the State exists - */ - public get exists(): boolean { - // Check if the value is not undefined and that the state is no placeholder - return this.getPublicValue() !== undefined && !this.isPlaceholder; - } - - - //========================================================================================================= - // Get Public Value - //========================================================================================================= - /** - * @internal - * Returns 100% the public value of a state because at some points (group) the _value contains only keys - */ - public getPublicValue(): ValueType { - if (this.output !== undefined) - return this.output; - return this._value; - } - - - //========================================================================================================= - // Private Write - //========================================================================================================= - /** - * @internal - * Will set a new _value and handles the stuff around like storage, .. - */ - public privateWrite(value: any) { - this._value = copy(value); - this.nextState = copy(value); - - // Save changes in Storage - updateValue(this); - } - - - //========================================================================================================= - // Get Persistable Value - //========================================================================================================= - /** - * @internal - * Will return the perstiable Value of this state.. - * some classes which extends state might have another peristiableValue than this.value (like the selector) - */ - public getPersistableValue(): any { - return this.value; - } - - - //========================================================================================================= - // Is Correct Type - //========================================================================================================= - /** - * @internal - * Checks if the 'value' has the same type as state.value - */ - private isCorrectType(value: any): boolean { - let type: string = typeof value; - return type === this.valueType; - } -} diff --git a/src/state/persist.ts b/src/state/persist.ts deleted file mode 100644 index d466101c..00000000 --- a/src/state/persist.ts +++ /dev/null @@ -1,85 +0,0 @@ -import State from "./index"; -import Storage, {StorageKey} from "../storage"; - - -//========================================================================================================= -// Persist Value -//========================================================================================================= -/** - * Will persist the 'state' into the configured storage with the key or if no key passed the state key - */ -export async function persistValue(state: State, key?: StorageKey) { - // Validate Key - const tempKey = validateKey(state, key); - if (!tempKey) { - console.error("Agile: If your State has no key provided before using persist.. you have to provide a key here!"); - return; - } - key = tempKey; - - // Get Storage - const storage = state.agileInstance().storage; - - // Check if persist State is already a isPersistState if so remove the old one - if (state.persistSettings.isPersisted && state.persistSettings.persistKey) - storage.remove(state.persistSettings.persistKey); - - // Add State to persistedStates in Storage - storage.persistedStates.add(state); - - // Call Handle which decides weather it has to add the storage value to the state or save the state into the storage - await handleStorageValue(key, storage, state); - - // Set persistSettings - state.persistSettings = { - isPersisted: true, - persistKey: key - } -} - - -//========================================================================================================= -// Update Value -//========================================================================================================= -/** - * Save current _value into storage if isPersistState - */ -export function updateValue(state: State) { - if (state.persistSettings.isPersisted && state.persistSettings.persistKey) - state.agileInstance().storage.set(state.persistSettings.persistKey, state._value); -} - - -//========================================================================================================= -// Helper -//========================================================================================================= - -function validateKey(state: State, key?: StorageKey): StorageKey | null { - // Get key from State key - if (!key && state.key) - return state.key; - - // Return null if no key can be found - if (!key) - return null; - - // Set Storage key as State key if no state key exists - if (!state.key) - state.key = key; - - return key; -} - -async function handleStorageValue(key: StorageKey, storage: Storage, state: State) { - // Get storage Value - const storageValue = await storage.get(key); - - // If the value doesn't exist in the storage yet.. create it - if (!storageValue) { - storage.set(key, state.getPersistableValue()); - return; - } - - // If the value already exists in the storage.. load it into the state - state.set(storageValue); -} diff --git a/src/storage.ts b/src/storage.ts deleted file mode 100644 index 660faf85..00000000 --- a/src/storage.ts +++ /dev/null @@ -1,184 +0,0 @@ -import Agile from "./agile"; -import State from "./state"; -import {isAsyncFunction, isFunction, isJsonString} from "./utils"; -import Collection from "./collection"; - -export type StorageKey = string | number; -export interface StorageConfigInterface { - async?: boolean - prefix?: string - methods?: { - get: (key: string) => any - set: (key: string, value: any) => void - remove: (key: string) => void - } -} - -export default class Storage { - public agileInstance: () => Agile; - - public isAsync: boolean = false; - private storageReady: boolean = false; - private storageType: 'localStorage' | 'custom' = 'localStorage'; - private storagePrefix: string = 'agile'; - private storageConfig: StorageConfigInterface; - - public persistedStates: Set = new Set(); - public persistedCollections: Set = new Set(); - - constructor(agileInstance: Agile, storageConfig: StorageConfigInterface) { - this.agileInstance = () => agileInstance; - this.storageConfig = storageConfig; - - // Set custom Storage prefix - if (storageConfig.prefix) - this.storagePrefix = storageConfig.prefix; - - // Set custom Storage functions - if (storageConfig.methods) - this.storageType = 'custom'; - - if (storageConfig.async) - this.isAsync = true; - - // Instantiate Custom Storage - if (this.storageType === 'custom') - this.instantiateCustomStorage() - - // Instantiate Local Storage - if (this.storageType === 'localStorage') - this.instantiateLocalStorage() - } - - - //========================================================================================================= - // Instantiate Local Storage - //========================================================================================================= - /** - * This instantiate the Local Storage - */ - private instantiateLocalStorage() { - // Check if Local Storage is Available (For instance in ReactNative it doesn't exist) - if (!this.localStorageAvailable()) { - console.warn("Agile: Local Storage is here not available.. to use the Storage functionality please provide a custom Storage!"); - return; - } - - // Set StorageMethods to LocalStorageMethods - this.storageConfig.methods = { - get: localStorage.getItem.bind(localStorage), - set: localStorage.setItem.bind(localStorage), - remove: localStorage.removeItem.bind(localStorage) - } - this.storageReady = true; - } - - - //========================================================================================================= - // Instantiate Custom Storage - //========================================================================================================= - /** - * This instantiate the Custom Storage - */ - private instantiateCustomStorage() { - // Check Get Function - if (!isFunction(this.storageConfig.methods?.get)) { - console.error("Agile: Your GET StorageMethod isn't valid!"); - return; - } - - // Check Set Function - if (!isFunction(this.storageConfig.methods?.set)) { - console.error("Agile: Your SET StorageMethod isn't valid!"); - return; - } - - // Check Remove Function - if (!isFunction(this.storageConfig.methods?.remove)) { - console.error("Agile: Your REMOVE StorageMethod isn't valid!"); - return; - } - - // Check if one function is async if so set is Async to true - if (isAsyncFunction(this.storageConfig.methods?.get) || isAsyncFunction(this.storageConfig.methods?.set) || isAsyncFunction(this.storageConfig.methods?.remove)) - this.isAsync = true; - - this.storageReady = true; - } - - - //========================================================================================================= - // Get - //========================================================================================================= - /** - * Gets the value provided by the key from the storage - */ - public get(key: StorageKey): GetType | Promise | undefined { - if (!this.storageReady || !this.storageConfig.methods?.get) return; - - // Async Get - if (this.isAsync) - return new Promise((resolve, reject) => { - this.storageConfig.methods?.get(this.getStorageKey(key)) - .then((res: any) => { - // If result is no Json - if (!isJsonString(res)) - return resolve(res); - - // Format Json to Object - resolve(JSON.parse(res)); - }) - .catch(reject); - }); - - // Normal Get - const res = this.storageConfig.methods.get(this.getStorageKey(key)); - if (isJsonString(res)) - return JSON.parse(res); - - return res; - } - - - //========================================================================================================= - // Set - //========================================================================================================= - /** - * Sets the value into the storage - */ - public set(key: StorageKey, value: any) { - if (!this.storageReady || !this.storageConfig.methods?.set) return; - this.storageConfig.methods.set(this.getStorageKey(key), JSON.stringify(value)); - } - - - //========================================================================================================= - // Remove - //========================================================================================================= - /** - * Deletes the value that is stored with the key - */ - public remove(key: StorageKey) { - if (!this.storageReady || !this.storageConfig.methods?.remove) return; - this.storageConfig.methods.remove(this.getStorageKey(key)); - } - - - //========================================================================================================= - // Helper - //========================================================================================================= - - private getStorageKey(key: StorageKey) { - return `_${this.storagePrefix}_${key}`; - } - - private localStorageAvailable() { - try { - localStorage.setItem('_', '_'); - localStorage.removeItem('_'); - return true; - } catch (e) { - return false; - } - } -} diff --git a/src/sub.ts b/src/sub.ts deleted file mode 100644 index 684e9d68..00000000 --- a/src/sub.ts +++ /dev/null @@ -1,204 +0,0 @@ -import State from "./state"; -import Agile from "./agile"; - - -//========================================================================================================= -// Subscription Container -//========================================================================================================= - -export type SubscriptionContainer = ComponentContainer | CallbackContainer; - - -//========================================================================================================= -// Component Container -//========================================================================================================= - -export class ComponentContainer { - public component: any; - - // Only needed object orientated subscriptions - public passProps: boolean = false; - public propStates?: { [key: string]: State }; // states which will than be returned as prop object by the integration - public propKeysChanged: Array = []; // Used to preserve local keys to update before update is performed, cleared every update - - public ready: boolean = false; - public subs: Set = new Set([]); // States that are subscribed by this component - - constructor(component: any, subs?: Set) { - this.component = component - if (subs) - this.subs = subs; - } -} - - -//========================================================================================================= -// Callback Container -//========================================================================================================= - -export class CallbackContainer extends ComponentContainer { - public callback: Function; - - constructor(callback: Function, subs?: Set) { - super(null, subs); - - this.callback = callback; - } -} - - -//========================================================================================================= -// Controller -//========================================================================================================= - -export default class SubController { - public agileInstance: () => Agile; - - // Component based Subscription - public components: Set = new Set(); - - // Callback based Subscription - public callbacks: Set = new Set(); - - public constructor(agileInstance: Agile) { - this.agileInstance = () => agileInstance; - } - - - //========================================================================================================= - // Subscribe with Subs Object - //========================================================================================================= - /** - * Subscribe to Agile State with a returned object of props this props can than be returned by the component (See react-integration) - */ - public subscribeWithSubsObject(subscriptionInstance: any, subs: { [key: string]: State } = {}): { subscriptionContainer: SubscriptionContainer, props: { [key: string]: State['value'] } } { - const subscriptionContainer = this.registerSubscription(subscriptionInstance); - - const props: { [key: string]: State } = {}; - subscriptionContainer.passProps = true; - subscriptionContainer.propStates = {...subs}; - - // Go through subs - let localKeys = Object.keys(subs); - localKeys.forEach(key => { - const state = subs[key]; - - // Add State to SubscriptionContainer Subs - subscriptionContainer.subs.add(state); - - // Add SubscriptionContainer to State Subs - state.dep.subs.add(subscriptionContainer); - - // Add state to props - props[key] = state.value; - }); - - return { - subscriptionContainer: subscriptionContainer, - props: props - }; - } - - - //========================================================================================================= - // Subscribe with Subs Array - //========================================================================================================= - /** - * Subscribe to Agile State - */ - public subscribeWithSubsArray(subscriptionInstance: any, subs: Array = []): SubscriptionContainer { - const subscriptionContainer = this.registerSubscription(subscriptionInstance, subs); - - subs.forEach(state => { - // Add State to SubscriptionContainer Subs - subscriptionContainer.subs.add(state); - - // Add SubscriptionContainer to State Dependencies Subs - state.dep.subs.add(subscriptionContainer); - }); - - return subscriptionContainer; - } - - - //========================================================================================================= - // Unsubscribe - //========================================================================================================= - /** - * Unsubscribe a component or callback - */ - public unsubscribe(subscriptionInstance: any) { - const unsub = (subscriptionContainer: CallbackContainer | ComponentContainer) => { - subscriptionContainer.ready = false; - - // Removes SubscriptionContainer from State subs - subscriptionContainer.subs.forEach(state => { - state.dep.subs.delete(subscriptionInstance); - }); - }; - - if (subscriptionInstance instanceof CallbackContainer) - unsub(subscriptionInstance); - else if (subscriptionInstance.componentContainer) - unsub(subscriptionInstance.componentContainer); - } - - - //========================================================================================================= - // Register Subscription - //========================================================================================================= - /** - * Registers the Component/Callback Subscription and returns a SubscriptionContainer - */ - public registerSubscription(integrationInstance: any, subs: Array = []): SubscriptionContainer { - // - Callback based Subscription - if (typeof integrationInstance === 'function') { - // Create CallbackContainer - const callbackContainer = new CallbackContainer(integrationInstance as Function, new Set(subs)); - - // Add to callbacks - this.callbacks.add(callbackContainer); - - // Set Ready - callbackContainer.ready = true; - - if (this.agileInstance().config.logJobs) - console.log("Agile: Registered Callback ", callbackContainer); - - return callbackContainer; - } - - // - Component based Subscription - // Create Component Container - const componentContainer = new ComponentContainer(integrationInstance, new Set(subs)); - - // Instantiate the componentContainer in a Component (for instance see react.integration AgileHOC) - integrationInstance.componentContainer = componentContainer; - - // Add to components - this.components.add(componentContainer); - - // Set Ready - if (!this.agileInstance().config.waitForMount) - componentContainer.ready = true; - - if (this.agileInstance().config.logJobs) - console.log("Agile: Registered Component ", componentContainer); - - return componentContainer; - } - - - //========================================================================================================= - // Mount - //========================================================================================================= - /** - * This will mount the component (Mounts currently only useful in Component based Subscription) - */ - public mount(integrationInstance: any) { - if (!integrationInstance.componentContainer) return; - - // Set Ready to true - integrationInstance.componentContainer.ready = true; - } -} diff --git a/src/utils.ts b/src/utils.ts deleted file mode 100644 index 93725d88..00000000 --- a/src/utils.ts +++ /dev/null @@ -1,178 +0,0 @@ -import State from "./state"; -import Agile from "./agile"; -import Event from "./event"; -import Collection from "./collection"; - - -//========================================================================================================= -// Copy -//========================================================================================================= -/** - * Copy an array or object.. without any dependencies - */ - -export function copy(value: T): T; -export function copy>(value: T): T[]; -export function copy(value: T): T | T[] { - if (Array.isArray(value)) - return [...value]; - - if (isValidObject(value)) - return {...value}; - - return value; -} - - -//========================================================================================================= -// Is Valid Object -//========================================================================================================= -/** - * Checks if an Object is an valid object for Agile - * https://stackoverflow.com/questions/12996871/why-does-typeof-array-with-objects-return-object-and-not-array - */ -export function isValidObject(value: any): boolean { - function isHTMLElement(obj: any) { - try { - return obj instanceof HTMLElement; - } catch (e) { - return typeof obj === 'object' && obj.nodeType === 1 && typeof obj.style === 'object' && typeof obj.ownerDocument === 'object'; - } - } - - return value !== null && typeof value === 'object' && !isHTMLElement(value) && !Array.isArray(value); -} - - -//========================================================================================================= -// Normalize Array -//========================================================================================================= -/** - * Convert item into an array - */ -export function normalizeArray(items?: DataType | Array): Array { - // Return empty array if no items - if (!items) - return []; - - return Array.isArray(items) ? items : [items as DataType]; -} - - -//========================================================================================================= -// Get Instance -//========================================================================================================= -/** - * Tries to get AgileInstance from instance(State, Collection) - */ -export function getAgileInstance(instance: any): Agile | null { - try { - // Return state agileInstance - if (instance instanceof State) - return instance.agileInstance(); - - if(instance instanceof Event) - return instance.agileInstance(); - - if(instance instanceof Collection) - return instance.agileInstance(); - - // Return the globalBind agile instance - // @ts-ignore - return globalThis.__agile; - } catch (e) { - // fail silently - } - - return null -} - - -//========================================================================================================= -// Is Function -//========================================================================================================= -/** - * Checks if func is a function - */ -export function isFunction(func: any) { - return typeof func === 'function'; -} - - -//========================================================================================================= -// Is Async Function -//========================================================================================================= -/** - * Checks if func is a async function - */ -export function isAsyncFunction(func: any) { - return isFunction(func) && func.constructor.name === 'AsyncFunction'; -} - - -//========================================================================================================= -// Is Valid Url -// https://stackoverflow.com/questions/5717093/check-if-a-javascript-string-is-a-url -//========================================================================================================= -/** - * Checks if url is valid - */ -export function isValidUrl(url: string): boolean { - const pattern = new RegExp('^(https?:\\/\\/)?' + // protocol - '((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|' + // domain name - '((\\d{1,3}\\.){3}\\d{1,3}))' + // OR ip (v4) address - '(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*' + // port and path - '(\\?[;&a-z\\d%_.~+=-]*)?' + // query string - '(\\#[-a-z\\d_]*)?$', 'i'); // fragment locator - return pattern.test(url); -} - - -//========================================================================================================= -// Is Json String -//========================================================================================================= -/** - * Checks if value is a valid JsonString - */ -export function isJsonString(value: any) { - try { - JSON.parse(value); - } catch (e) { - return false; - } - return true; -} - -//========================================================================================================= -// Define Config -//========================================================================================================= -/** - * Will create a config (config) and merges default values (default) into this config (config) - */ -export function defineConfig(config: C, defaults: object): C { - return {...defaults, ...config}; -} - - -//========================================================================================================= -// Flat Merge -//========================================================================================================= -/** - * Merged the items flat into the object - */ -export function flatMerge(source: DataType, changes: Object, config: { addNewProperties?: boolean } = {}): DataType { - // Copy Source to avoid reference - const _source = copy(source); - - // Loop through changes object and merge changes into source - let keys = Object.keys(changes); - keys.forEach(property => { - // @ts-ignore https://stackoverflow.com/questions/18452920/continue-in-cursor-foreach - if (!config.addNewProperties && !_source[property]) return; - - // @ts-ignore - _source[property] = changes[property]; - }); - - return _source; -} diff --git a/test/collection/default.spec.ts b/test/collection/default.spec.ts deleted file mode 100644 index 84b1ea07..00000000 --- a/test/collection/default.spec.ts +++ /dev/null @@ -1,178 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../src"; -import Group from "../../src/collection/group"; -import Selector from "../../src/collection/selector"; - -describe('Default Collection Tests', () => { - // Define Agile - const App = new Agile(); - - interface userInterface { - id: number - name: string - } - - describe('Collection', () => { - // Set Collections - const MY_COLLECTION = App.Collection(); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.config.key).to.eq(undefined, 'MY_COLLECTION has correct config.key'); - expect(MY_COLLECTION.config.primaryKey).to.eq('id', 'MY_COLLECTION has correct config.primaryKey'); - expect(MY_COLLECTION.config.defaultGroupKey).to.eq('default', 'MY_COLLECTION has correct config.defaultGroupKey'); - expect(JSON.stringify(MY_COLLECTION.config.groups)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no config.groups'); - expect(JSON.stringify(MY_COLLECTION.config.selectors)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no config.selectors'); - - expect(MY_COLLECTION.key).to.eq(undefined, 'MY_COLLECTION has correct key'); - expect(MY_COLLECTION._key).to.eq(undefined, 'MY_COLLECTION has correct _key'); - expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no data'); - expect(MY_COLLECTION.isPersistCollection).to.eq(false, 'MY_COLLECTION is no persisted Collection'); - expect(Object.keys(MY_COLLECTION.groups).length === 1 && MY_COLLECTION.groups["default"] !== undefined).to.eq(true, 'MY_COLLECTION has only default group'); - expect(JSON.stringify(MY_COLLECTION.selectors)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no selectors'); - expect(MY_COLLECTION.size).to.eq(0, 'MY_COLLECTION has correct size'); - }); - - it('Can change key', () => { - // Update key - MY_COLLECTION.key = 'myKey'; - - expect(MY_COLLECTION.key).to.eq('myKey', 'MY_COLLECTION has correct key'); - expect(MY_COLLECTION._key).to.eq('myKey', 'MY_COLLECTION has correct _key'); - }); - }); - - describe('Collection with Key', () => { - // Set Collection - const MY_COLLECTION = App.Collection({ - key: 'myCollectionKey' - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.key).to.eq('myCollectionKey', 'MY_COLLECTION has correct key'); - expect(MY_COLLECTION._key).to.eq('myCollectionKey', 'MY_COLLECTION has correct _key'); - }); - - it('Can change key', () => { - // Update key - MY_COLLECTION.key = 'withNewKey'; - - expect(MY_COLLECTION.key).to.eq('withNewKey', 'MY_COLLECTION has correct key'); - expect(MY_COLLECTION._key).to.eq('withNewKey', 'MY_COLLECTION has correct _key'); - }); - }); - - describe('Collection with default Groups', () => { - describe('Default Groups in Array shape', () => { - // Set Collection - const MY_COLLECTION = App.Collection({ - groups: ['group1', 'group2'] - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION has group1 in groups'); - expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION has group2 in groups'); - expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 has correct key'); - expect(MY_COLLECTION.groups['group2'].key).to.eq('group2', 'group2 has correct key'); - }); - }); - - describe('Default Groups in Object shape', () => { - interface userInterface { - id: number - name: string - } - - // Set Collection - const MY_COLLECTION = App.Collection((collection) => ({ - groups: { - group1: collection.Group(), - group2: collection.Group() - } - })); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION has group1 in groups'); - expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION has group2 in groups'); - expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 has correct key'); - expect(MY_COLLECTION.groups['group2'].key).to.eq('group2', 'group2 has correct key'); - }); - }); - }); - - describe('Collection with Key', () => { - // Set Collection - const MY_COLLECTION = App.Collection({ - key: 'myCollectionKey' - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.key).to.eq('myCollectionKey', 'MY_COLLECTION has correct key'); - expect(MY_COLLECTION._key).to.eq('myCollectionKey', 'MY_COLLECTION has correct _key'); - }); - - it('Can change key', () => { - // Update key - MY_COLLECTION.key = 'withNewKey'; - - expect(MY_COLLECTION.key).to.eq('withNewKey', 'MY_COLLECTION has correct key'); - expect(MY_COLLECTION._key).to.eq('withNewKey', 'MY_COLLECTION has correct _key'); - }); - }); - - describe('Collection with default Selectors', () => { - describe('Default Selector in Array shape', () => { - // Set Collection - const MY_COLLECTION = App.Collection({ - selectors: ['selector1', 'selector2'] - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector1 in selectors'); - expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector2 in selectors'); - expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 has correct key'); - expect(MY_COLLECTION.selectors['selector2'].key).to.eq('selector2', 'selector2 has correct key'); - }); - }); - - describe('Default Selectors in Object shape', () => { - // Set Collection - const MY_COLLECTION = App.Collection((collection) => ({ - selectors: { - selector1: collection.Selector('3'), - selector2: collection.Selector('2') - } - })); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector1 in selectors'); - expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector2 in selectors'); - expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 has correct key'); - expect(MY_COLLECTION.selectors['selector2'].key).to.eq('selector2', 'selector2 has correct key'); - }); - }); - }); - - describe('Collection with primaryKey', () => { - // Set Collection - const MY_COLLECTION = App.Collection({ - primaryKey: 'key' - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.config.primaryKey).to.eq('key', 'MY_COLLECTION has correct primaryKey'); - }); - }); - - describe('Collection with defaultGroupKey', () => { - // Set Collection - const MY_COLLECTION = App.Collection({ - defaultGroupKey: 'normal' - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.config.defaultGroupKey).to.eq('normal', 'MY_COLLECTION has correct defaultGroupKey'); - expect(MY_COLLECTION.groups['normal'] instanceof Group).to.eq(true, 'MY_COLLECTION has default group in groups') - }); - }); -}); diff --git a/test/collection/functions/collect.function.spec.ts b/test/collection/functions/collect.function.spec.ts deleted file mode 100644 index 6c9d47bc..00000000 --- a/test/collection/functions/collect.function.spec.ts +++ /dev/null @@ -1,374 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; -import Group from "../../../src/collection/group"; - -describe('Collect Function Tests', () => { - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - describe('Collection without primaryKey', () => { - let rerenderCount = 0; - - // Object Interface - interface userInterface { - id: number - name: string - age?: number - } - - // Create Collection - const MY_COLLECTION = App.Collection(); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookCollection] = useAgile([MY_COLLECTION], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has correct data'); - expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created') - expect(MY_COLLECTION.groups['default']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); - - expect(JSON.stringify(myHookCollection)).to.eq(JSON.stringify([]), 'myHookState has correct MY_COLLECTION value'); - expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); - }); - - it('Can collect item', async () => { - // Collect item - MY_COLLECTION.collect({id: 1, name: 'jeff'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION data has collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 1) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size has been increased by 1'); - - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t collect item with no primaryKey', async () => { - // Collect item - // @ts-ignore - MY_COLLECTION.collect({name: 'benno'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); - - expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); - }); - - it('Can\'t collect no object item', async () => { - // Collect item - // @ts-ignore - MY_COLLECTION.collect('franz'); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); - - expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); - }); - - it('Can\'t collect item with wrong primaryKey', async () => { - // Collect item - // @ts-ignore - MY_COLLECTION.collect({key: 2, name: 'hans'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify(undefined), 'MY_COLLECTION data hasn\'t collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(false, 'MY_COLLECTION default group doesn\'t contain collected value'); - expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); - - expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); - }); - - it('Can collect multiple items at the same time', async () => { - // Collect item - MY_COLLECTION.collect([{id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ - id: 2, - name: 'hans' - }), 'MY_COLLECTION data has collected value with id 2'); - expect(JSON.stringify(MY_COLLECTION.data[3]?.value)).to.eq(JSON.stringify({ - id: 3, - name: 'frank' - }), 'MY_COLLECTION data has collected value with id 3'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value with id 2'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 3) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value with id 3'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION size has been increased by 2'); - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can overwrite item if collecting with existing primaryKey', async () => { - MY_COLLECTION.collect({id: 2, name: 'benno'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ - id: 2, - name: 'benno' - }), 'MY_COLLECTION data has overwritten value with id 2'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION size stayed the same'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(true, 'MY_COLLECTION default group still contains collected value'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - describe('Test background option', () => { - it('Does call callBackFunction by collecting Item with background = false', async () => { - // Collect item - MY_COLLECTION.collect({id: 4, name: 'dustin'}, [], {background: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[4]?.value)).to.eq(JSON.stringify({ - id: 4, - name: 'dustin' - }), 'MY_COLLECTION data has collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 4) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.size).to.eq(4, 'MY_COLLECTION size has been increased by 1'); - - expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); - }); - - it('Doesn\'t call callBackFunction by collecting Item with background = true', async () => { - // Collect item - MY_COLLECTION.collect({id: 5, name: 'snipey'}, [], {background: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[5]?.value)).to.eq(JSON.stringify({ - id: 5, - name: 'snipey' - }), 'MY_COLLECTION data has collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 5) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.size).to.eq(5, 'MY_COLLECTION size has been increased by 1'); - - expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); - }); - }); - - describe('Test method option', () => { - it('Does add the item at the end of the group with method = \'push\'', async () => { - // Collect item - MY_COLLECTION.collect({id: 6, name: 'jana'}, [], {method: 'push'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[6]?.value)).to.eq(JSON.stringify({ - id: 6, - name: 'jana' - }), 'MY_COLLECTION data has collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 6) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.groups['default']?.value[MY_COLLECTION.groups['default']?.value.length - 1]).to.eq(6, 'MY_COLLECTION default group collected value is last item in group'); - expect(MY_COLLECTION.size).to.eq(6, 'MY_COLLECTION size has been increased by 1'); - - expect(rerenderCount).to.eq(5, 'rerenderCount has been increased by 1'); - }); - - it('Does add the item at the start of the group with method = \'unshift\'', async () => { - // Collect item - MY_COLLECTION.collect({id: 7, name: 'gina'}, [], {method: 'unshift'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[7]?.value)).to.eq(JSON.stringify({ - id: 7, - name: 'gina' - }), 'MY_COLLECTION data has collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 7) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.groups['default']?.value[0]).to.eq(7, 'MY_COLLECTION default group collected value is first item in group'); - expect(MY_COLLECTION.size).to.eq(7, 'MY_COLLECTION size has been increased by 1'); - - expect(rerenderCount).to.eq(6, 'rerenderCount has been increased by 1'); - }); - }); - - describe('Test patch option', () => { - it('Does patch value into item without overwriting it with patch = true', async () => { - // Collect item - // @ts-ignore - MY_COLLECTION.collect({id: 1, age: 20}, [], {patch: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff', - age: 20 - }), 'MY_COLLECTION data at id 1 has changed'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 1) !== -1).to.eq(true, 'MY_COLLECTION default group still contains collected value'); - expect(MY_COLLECTION.size).to.eq(7, 'MY_COLLECTION size stayed the same'); - - expect(rerenderCount).to.eq(7, 'rerenderCount has been increased by 1'); - }); - - it('Does set value into item by overwriting it with patch = false', async () => { - // Collect item - // @ts-ignore - MY_COLLECTION.collect({id: 2, age: 30}, [], {patch: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ - id: 2, - age: 30 - }), 'MY_COLLECTION data at id 2 has changed'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(true, 'MY_COLLECTION default group still contains collected value'); - expect(MY_COLLECTION.size).to.eq(7, 'MY_COLLECTION size stayed the same'); - - expect(rerenderCount).to.eq(8, 'rerenderCount has been increased by 1'); - }); - }); - - describe('Test forEachItem option', () => { - it('Does call forEachItem', async () => { - const myForEachItems: { item: userInterface, key: string | number, index: number }[] = []; - - // Collect item - MY_COLLECTION.collect([{id: 8, name: 'joshi'}, {id: 9, name: 'paul'}], [], { - forEachItem: (item, key, index) => { - myForEachItems.push({ - item: item, - key: key, - index: index - }) - } - }); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[8]?.value)).to.eq(JSON.stringify({ - id: 8, - name: 'joshi' - }), 'MY_COLLECTION data has collected value'); - expect(JSON.stringify(MY_COLLECTION.data[9]?.value)).to.eq(JSON.stringify({ - id: 9, - name: 'paul' - }), 'MY_COLLECTION data has collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 8) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 9) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.size).to.eq(9, 'MY_COLLECTION size has been increased by 2'); - - expect(JSON.stringify(myForEachItems[0])).to.eq(JSON.stringify({ - item: {id: 8, name: 'joshi'}, - key: 8, - index: 0 - }), 'myForEachItem has contains first collected item'); - expect(JSON.stringify(myForEachItems[1])).to.eq(JSON.stringify({ - item: {id: 9, name: 'paul'}, - key: 9, - index: 1 - }), 'myForEachItem has contains second collected item'); - - expect(rerenderCount).to.eq(9, 'rerenderCount has been increased by 1'); - }); - }); - }); - - describe('Collection with primaryKey and defaultGroupKey', () => { - let rerenderCount = 0; - - // Object Interface - interface userInterface { - key: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection({ - primaryKey: 'key', - }); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookCollection] = useAgile([MY_COLLECTION], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has correct data'); - expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created') - expect(MY_COLLECTION.groups['default']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); - - expect(JSON.stringify(myHookCollection)).to.eq(JSON.stringify([]), 'myHookState has correct MY_COLLECTION value'); - }); - - it('Can collect item', async () => { - // Collect item - MY_COLLECTION.collect({key: 1, name: 'jeff'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ - key: 1, - name: 'jeff' - }), 'MY_COLLECTION data has collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 1) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); - expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size has been increased by 1'); - - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t collect item with no primaryKey', async () => { - // Collect item - // @ts-ignore - MY_COLLECTION.collect({name: 'benno'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); - - expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); - }); - - it('Can\'t collect item with wrong primaryKey', async () => { - // Collect item - // @ts-ignore - MY_COLLECTION.collect({id: 2, name: 'hans'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify(undefined), 'MY_COLLECTION data hasn\'t collected value'); - expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(false, 'MY_COLLECTION default group doesn\'t contain collected value'); - expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); - - expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); - }); - }); -}); diff --git a/test/collection/functions/createGroup.function.spec.ts b/test/collection/functions/createGroup.function.spec.ts deleted file mode 100644 index 13da99f8..00000000 --- a/test/collection/functions/createGroup.function.spec.ts +++ /dev/null @@ -1,49 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import Group from "../../../src/collection/group"; - -describe('createGroup Function Tests', () => { - // Define Agile - const App = new Agile(); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has correct data'); - expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); - }); - - it('Can create Group', () => { - // Create Group - MY_COLLECTION.createGroup('group1'); - - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 has been created'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has no initialItems'); - expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 has correct key'); - }); - - it('Can create Group with initial Items', () => { - // Create Group - MY_COLLECTION.createGroup('group2', ['1', '2']); - - expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION group2 has been created'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify(['1', '2']), 'group2 has initialItems'); - expect(MY_COLLECTION.groups['group2'].key).to.eq('group2', 'group2 has correct key'); - }); - - it('Can\'t overwrite Group which already exists', () => { - // Create Group - MY_COLLECTION.createGroup('group2'); - - expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION group2 is still a group'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify(['1', '2']), 'group2 items stayed the same'); - }); -}); diff --git a/test/collection/functions/createSelector.function.spec.ts b/test/collection/functions/createSelector.function.spec.ts deleted file mode 100644 index d3572684..00000000 --- a/test/collection/functions/createSelector.function.spec.ts +++ /dev/null @@ -1,54 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import Selector from "../../../src/collection/selector"; -import Item from "../../../src/collection/item"; - -describe('createSelector Function Tests', () => { - // Define Agile - const App = new Agile(); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(); - MY_COLLECTION.collect({id: 1, name: 'jeff'}); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'MY_COLLECTION has correct data'); - expect(JSON.stringify(MY_COLLECTION.selectors)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no initial selectors'); - }); - - it('Can create Selector with not existing id', () => { - // Create Selector - MY_COLLECTION.createSelector('selector1', 3); - - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 has been created'); - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(3, 'selector1 is watching right id'); - expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 has correct key'); - - expect(MY_COLLECTION.data[3] instanceof Item).to.eq(true, 'MY_COLLECTION data contains dummy Item with id 3 (created by Selector)'); - expect(MY_COLLECTION.data[3].isPlaceholder).to.eq(true, 'Item at id 3 is placeholder'); - }); - - it('Can create Selector with existing id', () => { - // Create Selector - MY_COLLECTION.createSelector('selector2', 1); - - expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 has been created'); - expect(MY_COLLECTION.selectors['selector2'].id).to.eq(1, 'selector1 is watching right id'); - expect(MY_COLLECTION.selectors['selector2'].key).to.eq('selector2', 'selector1 has correct key'); - }); - - it('Can\'t overwrite Selector which already exists', () => { - // Create Selector - MY_COLLECTION.createSelector('selector1', 2); - - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 is still a selector'); - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(3, 'selector1 id stayed the same (3)'); - }); -}); diff --git a/test/collection/functions/findById.function.spec.ts b/test/collection/functions/findById.function.spec.ts deleted file mode 100644 index e3b8a4f6..00000000 --- a/test/collection/functions/findById.function.spec.ts +++ /dev/null @@ -1,39 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import State from "../../../src/state"; - -describe('FindById Function Tests', () => { - // Define Agile - const App = new Agile(); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(); - MY_COLLECTION.collect({id: 1, name: 'jeff'}); - MY_COLLECTION.collect({id: 2, name: 'hans'}); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'MY_COLLECTION has correct data'); - expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({id: 2, name: 'hans'}), 'MY_COLLECTION has correct data'); - expect(MY_COLLECTION.size).to.eq(2, 'MY_COLLECTION has correct size'); - }); - - it('Can findById', () => { - const item = MY_COLLECTION.findById(1); - - expect(item instanceof State).to.eq(true, 'item is instanceof State') - expect(JSON.stringify(item?.value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'item has correct value'); - }); - - it('Can\'t findById not existing item', () => { - const item = MY_COLLECTION.findById(5); - - expect(item).to.eq(undefined, 'item is undefined') - }); -}); diff --git a/test/collection/functions/getGroup.function.spec.ts b/test/collection/functions/getGroup.function.spec.ts deleted file mode 100644 index a49c5a09..00000000 --- a/test/collection/functions/getGroup.function.spec.ts +++ /dev/null @@ -1,44 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import Group from "../../../src/collection/group"; - -describe('getGroup Function Tests', () => { - // Define Agile - const App = new Agile(); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection({ - groups: ['group1', 'group2'] - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); - expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION group2 Group has been created'); - }); - - it('Can get Group which exists', () => { - // Get Group - const myGroup = MY_COLLECTION.getGroup('group1'); - - expect(myGroup instanceof Group).to.eq(true, 'myGroup is a group'); - expect(myGroup.key).to.eq('group1', 'myGroup has correct key'); - expect(myGroup.exists).to.eq(true, 'myGroup does exist'); - }); - - it('Gets dummy Group, if trying to get a non existing group', () => { - // Get Group - const myGroup = MY_COLLECTION.getGroup('group3'); - - expect(myGroup instanceof Group).to.eq(true, 'myGroup is a group'); - expect(myGroup.key).to.eq('dummy', 'myGroup has correct key'); - expect(myGroup.exists).to.eq(false, 'group3 doesn\'t exist'); - }); -}); diff --git a/test/collection/functions/getSelector.function.spec.ts b/test/collection/functions/getSelector.function.spec.ts deleted file mode 100644 index 4c19ddfd..00000000 --- a/test/collection/functions/getSelector.function.spec.ts +++ /dev/null @@ -1,42 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import Selector from "../../../src/collection/selector"; - -describe('getSelector Function Tests', () => { - // Define Agile - const App = new Agile(); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection({ - selectors: ['selector1', 'selector2'] - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 Selector has been created'); - expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector2 Selector has been created'); - }); - - it('Can get Selector which exists', () => { - // Get Selector - const mySelector = MY_COLLECTION.getSelector('selector1'); - - expect(mySelector instanceof Selector).to.eq(true, 'mySelector is a Selector'); - expect(mySelector?.key).to.eq('selector1', 'mySelector has correct key'); - expect(mySelector?.exists).to.eq(false, 'mySelector doesn\'t exist because it has no value'); - expect(mySelector?.value).to.eq(undefined, 'mySelector has correct value'); - }); - - it('Can\'t get Selector which doesn\'t exist', () => { - // Get Selector - const mySelector = MY_COLLECTION.getSelector('selector3'); - - expect(mySelector instanceof Selector).to.eq(false, 'mySelector is undefined'); - }); -}); diff --git a/test/collection/functions/getValueById.function.spec.ts b/test/collection/functions/getValueById.function.spec.ts deleted file mode 100644 index 0eff6acb..00000000 --- a/test/collection/functions/getValueById.function.spec.ts +++ /dev/null @@ -1,37 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; - -describe('GetValueById Function Tests', () => { - // Define Agile - const App = new Agile(); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(); - MY_COLLECTION.collect({id: 1, name: 'jeff'}); - MY_COLLECTION.collect({id: 2, name: 'hans'}); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'MY_COLLECTION has correct data'); - expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({id: 2, name: 'hans'}), 'MY_COLLECTION has correct data'); - expect(MY_COLLECTION.size).to.eq(2, 'MY_COLLECTION has correct size'); - }); - - it('Can getValueById', () => { - const item = MY_COLLECTION.getValueById(1); - - expect(JSON.stringify(item)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'item has correct value'); - }); - - it('Can\'t getValueById with not existing item id', () => { - const item = MY_COLLECTION.findById(5); - - expect(item).to.eq(undefined, 'item is undefined') - }); -}); diff --git a/test/collection/functions/remove.function.spec.ts b/test/collection/functions/remove.function.spec.ts deleted file mode 100644 index 75e12a70..00000000 --- a/test/collection/functions/remove.function.spec.ts +++ /dev/null @@ -1,224 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; -import Item from "../../../src/collection/item"; - -describe('Remove Function Tests', () => { - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - describe('Remove Function \'removeFromGroups\'', () => { - let rerenderCount = 0; - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group([1, 2, 3]), - group2: collection.Group([1, 2, 3]) - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1, myGroup2] = useAgile([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { - rerenderCount++; - }); - - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group2 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION data contains item with id 1'); - expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ - id: 2, - name: 'hans' - }), 'MY_COLLECTION data contains item with id 2'); - expect(JSON.stringify(MY_COLLECTION.data[3].value)).to.eq(JSON.stringify({ - id: 3, - name: 'frank' - }), 'MY_COLLECTION data contains item with id 3'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); - }); - - it('Can remove item which exist', async () => { - // Remove item - MY_COLLECTION.remove(1).fromGroups('group1'); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 3]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group2 has correct value'); - expect(MY_COLLECTION.data[1] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 1'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can remove items which exist', async () => { - // Remove items - MY_COLLECTION.remove([2, 3]).fromGroups(['group1', 'group2']); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1]), 'group2 has correct value'); - expect(MY_COLLECTION.data[2] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 2'); - expect(MY_COLLECTION.data[3] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 3'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t remove item which doesn\'t exist', async () => { - // Remove item - MY_COLLECTION.remove(5).fromGroups('group1'); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - - it('Can\'t remove item which doesn\'t exist in group', async () => { - // Remove item - MY_COLLECTION.remove(1).fromGroups('group1'); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); - expect(MY_COLLECTION.data[1] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 1'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - - it('Can\'t remove item from not existing group', async () => { - // Remove item - MY_COLLECTION.remove(2).fromGroups('notExisting'); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.data[2] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 2'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - }); - - describe('Remove Function \'everywhere\'', () => { - let rerenderCount = 0; - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group([1, 2, 3]), - group2: collection.Group([1, 2, 3]) - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1, myGroup2] = useAgile([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { - rerenderCount++; - }); - - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group2 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION data contains item with id 1'); - expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ - id: 2, - name: 'hans' - }), 'MY_COLLECTION data contains item with id 2'); - expect(JSON.stringify(MY_COLLECTION.data[3].value)).to.eq(JSON.stringify({ - id: 3, - name: 'frank' - }), 'MY_COLLECTION data contains item with id 3'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); - }); - - it('Can remove item which exist', async () => { - // Remove item - MY_COLLECTION.remove(1).everywhere(); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 3]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([2, 3]), 'group2 has correct value'); - expect(MY_COLLECTION.data[1] instanceof Item).to.eq(false, 'MY_COLLECTION hasn\'t item with id 1'); - expect(MY_COLLECTION.size).to.eq(2, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can remove items which exist', async () => { - // Remove items - MY_COLLECTION.remove([2, 3]).everywhere(); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([]), 'group2 has correct value'); - expect(MY_COLLECTION.data[2] instanceof Item).to.eq(false, 'MY_COLLECTION hasn\'t item with id 2'); - expect(MY_COLLECTION.data[3] instanceof Item).to.eq(false, 'MY_COLLECTION hasn\'t item with id 3'); - expect(MY_COLLECTION.size).to.eq(0, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t remove item which doesn\'t exist', async () => { - // Remove item - MY_COLLECTION.remove(5).everywhere(); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.size).to.eq(0, 'MY_COLLECTION has correct size'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - }); -}); diff --git a/test/collection/functions/update.function.spec.ts b/test/collection/functions/update.function.spec.ts deleted file mode 100644 index a57986c3..00000000 --- a/test/collection/functions/update.function.spec.ts +++ /dev/null @@ -1,222 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; -import Group from "../../../src/collection/group"; - -describe('Update Function Tests', () => { - let rerenderCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - // Object Interface - interface userInterface { - id: number - name: string - age?: number - } - - // Create Collection - const MY_COLLECTION = App.Collection(); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookCollection] = useAgile([MY_COLLECTION], () => { - rerenderCount++; - }); - - // Collect some items - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'jamie'}, {id: 3, name: 'hans'}]) - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created') - expect(MY_COLLECTION.groups['default']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); - expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION item at id 1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ - id: 2, - name: 'jamie' - }), 'MY_COLLECTION item at id 2 has correct value'); - expect(JSON.stringify(MY_COLLECTION.data[3].value)).to.eq(JSON.stringify({ - id: 3, - name: 'hans' - }), 'MY_COLLECTION item at id 3 has correct value'); - - expect(JSON.stringify(myHookCollection)).to.eq(JSON.stringify([]), 'myHookState has correct MY_COLLECTION value'); - expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); - }); - - it('Can update Item', async () => { - // Update Item - MY_COLLECTION.update(1, {name: 'updatedJeff'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ - id: 1, - name: 'updatedJeff' - }), 'MY_COLLECTION data at id 1 has updated'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can update Item and primaryKey', async () => { - // Update Item - MY_COLLECTION.update(3, {id: 4, name: 'updatedHans'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[4]?.value)).to.eq(JSON.stringify({ - id: 4, - name: 'updatedHans' - }), 'MY_COLLECTION data switched from id 3 to id 4 and has updated'); - expect(MY_COLLECTION.data[3]).to.eq(undefined, 'MY_COLLECTION item at id 3 doesn\'t exist anymore'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items'); - expect(MY_COLLECTION.groups["default"].value.findIndex(value => value === 3) !== -1).to.eq(false, 'MY_COLLECTION item with id 3 doesn\'t exist in default group anymore'); - expect(MY_COLLECTION.groups["default"].value.findIndex(value => value === 4) !== -1).to.eq(true, 'MY_COLLECTION item with id 3 does exist in default group'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t update not existing Item', async () => { - // Update Item - MY_COLLECTION.update(5, {name: 'updatedName'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has stayed the same'); - }); - - it('Can\'t update Item with the same value', async () => { - // Update Item - MY_COLLECTION.update(1, {name: 'updatedJeff'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ - id: 1, - name: 'updatedJeff' - }), 'MY_COLLECTION data at id 1 stayed the same'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') - - expect(rerenderCount).to.eq(3, 'rerenderCount has stayed the same'); - }); - - it('Can\'t update Item with non object changes', async () => { - // Update Item - // @ts-ignore - MY_COLLECTION.update(1, 'hi'); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has stayed the same'); - }); - - describe('Test background option', () => { - it('Does call callBackFunction by updating Item with background = false', async () => { - // Update Item - MY_COLLECTION.update(2, {name: 'updatedJamie'}, {background: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ - id: 2, - name: 'updatedJamie' - }), 'MY_COLLECTION data at id 2 has updated'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') - - expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); - }); - - it('Doesn\'t call callBackFunction by updating Item with background = true', async () => { - // Update Item - MY_COLLECTION.update(4, {id: 4, name: 'updatedHans2'}, {background: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[4]?.value)).to.eq(JSON.stringify({ - id: 4, - name: 'updatedHans2' - }), 'MY_COLLECTION data at id 4 has updated'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') - - expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); - }); - - it('Doesn\'t call callBackFunction by updating Item and primaryKey with background = true', async () => { - // Update Item - MY_COLLECTION.update(4, {id: 3, name: 'updatedHans3'}, {background: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[3]?.value)).to.eq(JSON.stringify({ - id: 3, - name: 'updatedHans3' - }), 'MY_COLLECTION data switched from id 4 to id 3 and has updated'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') - - expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); - }); - }); - - describe('Test addNewProperties option', () => { - it('Doesn\'t add property to value with addNewProperties = false', async () => { - // Update Item - MY_COLLECTION.update(2, {name: 'updatedJamie2', age: 10}, {addNewProperties: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ - id: 2, - name: 'updatedJamie2' - }), 'MY_COLLECTION data at id 2 has updated'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') - - expect(rerenderCount).to.eq(5, 'rerenderCount has been increased by 1'); - }); - - - it('Does add property to value with addNewProperties = true', async () => { - // Update Item - MY_COLLECTION.update(2, {name: 'updatedJamie3', age: 20}, {addNewProperties: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ - id: 2, - name: 'updatedJamie3', - age: 20 - }), 'MY_COLLECTION data at id 2 has updated'); - expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') - - expect(rerenderCount).to.eq(6, 'rerenderCount has been increased by 1'); - }); - }); -}); diff --git a/test/collection/group/default.spec.ts b/test/collection/group/default.spec.ts deleted file mode 100644 index 0648464c..00000000 --- a/test/collection/group/default.spec.ts +++ /dev/null @@ -1,183 +0,0 @@ -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; -import {expect} from "chai"; -import Group from "../../../src/collection/group"; - -describe('Default Group Tests', () => { - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); - - describe('Group', () => { - let rerenderCount = 0; - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group() - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); - expect(MY_COLLECTION.groups['default']?.dep.subs.size === 0).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([]), 'default Group has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([]), 'default Group has correct initial output'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([]), 'default Group has correct initial states'); - expect(MY_COLLECTION.groups['default'].key).to.eq('default', 'group1 Group has correct initial key'); - - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); - expect(MY_COLLECTION.groups['group1']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION group1 Group has correct subs size'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 Group has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 Group has correct initial output'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([]), 'group1 Group has correct initial states'); - expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 Group has correct initial key'); - - expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); - expect(rerenderCount).to.eq(0, 'rerenderCount has correct value'); - }); - - it('Has correct values after collecting items', async () => { - // Collect Data - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([1, 2, 3]), 'default Group has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'} - ]), 'default Group has correct output'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([ - MY_COLLECTION.findById(1), - MY_COLLECTION.findById(2), - MY_COLLECTION.findById(3) - ]), 'default Group has correct states'); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 Group has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 Group has correct output'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([]), 'group1 Group has correct states'); - - expect(rerenderCount).to.eq(0, 'rerenderCount stayed the same'); - }); - }); - - describe('Group with initial values', () => { - let rerenderCount = 0; - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group([1, 2, 3]) - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); - expect(MY_COLLECTION.groups['default']?.dep.subs.size === 0).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([]), 'default has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([]), 'default has correct initial output'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([]), 'default has correct initial states'); - expect(MY_COLLECTION.groups['default'].key).to.eq('default', 'default Group has correct initial key'); - - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); - expect(MY_COLLECTION.groups['group1']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION group1 Group has correct subs size'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 Group has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 Group has correct initial output'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([]), 'group1 Group has correct initial states'); - expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 Group has correct initial key'); - - expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); - expect(rerenderCount).to.eq(0, 'rerenderCount has correct value'); - }); - - it('Has correct values after collecting items', async () => { - // Collect Data - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([1, 2, 3]), 'default has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'} - ]), 'default has correct output'); - expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([ - MY_COLLECTION.findById(1), - MY_COLLECTION.findById(2), - MY_COLLECTION.findById(3) - ]), 'default has correct states'); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'} - ]), 'group1 has correct output'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([ - MY_COLLECTION.findById(1), - MY_COLLECTION.findById(2), - MY_COLLECTION.findById(3) - ]), 'group1 has correct states'); - - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - }); - }); - - describe('Group with key', () => { - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group([], {key: 'mywierdgroup'}) - } - }) - ); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); - expect(MY_COLLECTION.groups['group1'].key).to.eq('mywierdgroup', 'group1 has correct key'); - }); - }); -}); diff --git a/test/collection/group/functions/add.function.spec.ts b/test/collection/group/functions/add.function.spec.ts deleted file mode 100644 index 0db013f6..00000000 --- a/test/collection/group/functions/add.function.spec.ts +++ /dev/null @@ -1,256 +0,0 @@ -import Agile from "../../../../src"; -import {useAgile} from "../../../../src/integrations/test"; -import {expect} from "chai"; -import Group from "../../../../src/collection/group"; - -describe('Add function Tests', () => { - let rerenderCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group([2]) - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { - rerenderCount++; - }); - - MY_COLLECTION.collect([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'}, - {id: 6, name: 'livia'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'} - ]); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'} - ]), 'group1 has correct output'); - - expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); - expect(rerenderCount).to.eq(1, 'rerenderCount has been correct value'); - }); - - it('Can add Group', async () => { - MY_COLLECTION.groups['group1'].add(1); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'} - ]), 'group1 has correct output'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].notFoundPrimaryKeys)).to.eq(JSON.stringify([]), 'group1 has correct notFoundPrimaryKeys'); - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can add multiple Groups', async () => { - MY_COLLECTION.groups['group1'].add([7, 8]); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'} - ]), 'group1 has correct output'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].notFoundPrimaryKeys)).to.eq(JSON.stringify([]), 'group1 has correct notFoundPrimaryKeys'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t add item to Group which already exists', async () => { - MY_COLLECTION.groups['group1'].add(1); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - - it('Can add item to Group which doesn\'t exist in collection', async () => { - MY_COLLECTION.groups['group1'].add(100); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'} - ]), 'group1 has correct output'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].notFoundPrimaryKeys)).to.eq(JSON.stringify([100]), 'group1 has correct notFoundPrimaryKeys'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same because output won\'t change -> rerender not necessary'); - }); - - describe('Test background option', () => { - it('Does call callBackFunction by adding Item to group with background = false', async () => { - MY_COLLECTION.groups['group1'].add(3, {background: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100, 3]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'}, - {id: 3, name: 'frank'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); - }); - - it('Doesn\'t call callBackFunction by adding Item to group with background = true', async () => { - MY_COLLECTION.groups['group1'].add(4, {background: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100, 3, 4]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); - }); - }); - - describe('Test method option', () => { - it('Does add the item at the end of the group with method = \'push\'', async () => { - MY_COLLECTION.groups['group1'].add(5, {method: 'push'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100, 3, 4, 5]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(5, 'rerenderCount has been increased by 1'); - }); - - it('Does add the item at the start of the group with method = \'unshift\'', async () => { - MY_COLLECTION.groups['group1'].add(6, {method: 'unshift'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([6, 2, 1, 7, 8, 100, 3, 4, 5]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 6, name: 'livia'}, - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(6, 'rerenderCount has been increased by 1'); - }); - }); - - describe('Test overwrite option', () => { - it('Leave existing item at current position and doesn\'t overwrite it with overwrite = false', async () => { - MY_COLLECTION.groups['group1'].add(3, {overwrite: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([6, 2, 1, 7, 8, 100, 3, 4, 5]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 6, name: 'livia'}, - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(6, 'rerenderCount stayed the same'); - }); - - it('Overwrites existing item and add it at new position with overwrite = true', async () => { - MY_COLLECTION.groups['group1'].add(3, {overwrite: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([6, 2, 1, 7, 8, 100, 4, 5, 3]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 6, name: 'livia'}, - {id: 2, name: 'hans'}, - {id: 1, name: 'jeff'}, - {id: 7, name: 'joshi'}, - {id: 8, name: 'günter'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'}, - {id: 3, name: 'frank'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(7, 'rerenderCount has been increased by 1'); - }); - }); -}); diff --git a/test/collection/group/functions/has.function.spec.ts b/test/collection/group/functions/has.function.spec.ts deleted file mode 100644 index aa0fd782..00000000 --- a/test/collection/group/functions/has.function.spec.ts +++ /dev/null @@ -1,60 +0,0 @@ -import Agile from "../../../../src"; -import {expect} from "chai"; -import Group from "../../../../src/collection/group"; - -describe('Has function Tests', () => { - // Define Agile - const App = new Agile(); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group([1, 2, 3]) - } - }) - ); - - MY_COLLECTION.collect([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'} - ]); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'} - ]), 'group1 has correct output'); - }); - - it('Can use has function', () => { - const has = MY_COLLECTION.groups['group1'].has(1); - - expect(has).to.eq(true); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); - }); - - it('Can use has function with not existing primaryKey in collection and group', () => { - const has = MY_COLLECTION.groups['group1'].has(100); - - expect(has).to.eq(false); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); - }); - - it('Can use has function with not existing primaryKey in group', () => { - const has = MY_COLLECTION.groups['group1'].has(4); - - expect(has).to.eq(false); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); - }); -}); diff --git a/test/collection/group/functions/remove.function.spec.ts b/test/collection/group/functions/remove.function.spec.ts deleted file mode 100644 index b09478b1..00000000 --- a/test/collection/group/functions/remove.function.spec.ts +++ /dev/null @@ -1,137 +0,0 @@ -import Agile from "../../../../src"; -import {useAgile} from "../../../../src/integrations/test"; -import {expect} from "chai"; -import Group from "../../../../src/collection/group"; - -describe('Add function Tests', () => { - let rerenderCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - groups: { - group1: collection.Group([1, 2, 3, 4, 5]) - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { - rerenderCount++; - }); - - MY_COLLECTION.collect([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3, 4, 5]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 1, name: 'jeff'}, - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); - expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); - }); - - it('Can remove item which exists', async () => { - MY_COLLECTION.groups['group1'].remove(1); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 3, 4, 5]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 2, name: 'hans'}, - {id: 3, name: 'frank'}, - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can remove multiple items which exist', async () => { - MY_COLLECTION.groups['group1'].remove([2, 3]); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([4, 5]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t remove item which doesn\'t exist', async () => { - MY_COLLECTION.groups['group1'].remove(100); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([4, 5]), 'group1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 4, name: 'gina'}, - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - - describe('Test background option', () => { - it('Does call callBackFunction by removing Item from group with background = false', async () => { - MY_COLLECTION.groups['group1'].remove(4, {background: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([5]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ - {id: 5, name: 'tabea'} - ]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); - }); - - it('Doesn\'t call callBackFunction by removing Item from group with background = true', async () => { - MY_COLLECTION.groups['group1'].remove(5, {background: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); - expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 has correct output'); - - expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); - }); - }); -}); diff --git a/test/collection/selector/default.spec.ts b/test/collection/selector/default.spec.ts deleted file mode 100644 index 44eceaa8..00000000 --- a/test/collection/selector/default.spec.ts +++ /dev/null @@ -1,118 +0,0 @@ -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; -import {expect} from "chai"; -import Selector from "../../../src/collection/selector"; -import Item from "../../../src/collection/item"; - -describe('Default Selector Tests', () => { - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); - - describe('Selector', () => { - let rerenderCount = 0; - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - selectors: { - selector1: collection.Selector(1) - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [mySelector1] = useAgile([MY_COLLECTION.getSelector('selector1')], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 Selector has been created'); - expect(MY_COLLECTION.selectors['selector1']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION selector1 Selector has correct subs size'); - expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 Selector has correct initial key'); - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(1, 'selector1 Selector has correct initial id'); - expect(MY_COLLECTION.selectors['selector1'].exists).to.eq(false, 'selector1 Selector doesn\'t exist'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify(undefined), 'selector1 Selector has correct initial value'); - - expect(MY_COLLECTION.data[1] instanceof Item).to.eq(true, 'MY_COLLECTION data at id 1 has been created'); - expect(MY_COLLECTION.data[1].exists).to.eq(false, 'MY_COLLECTION data at id 1 doesn\'t exist'); - expect(MY_COLLECTION.data[1].key).to.eq(1, 'MY_COLLECTION data at id 1 has correct initial key'); - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ - id: 1 - }), 'MY_COLLECTION data at id 1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.data[1].initialState)).to.eq(JSON.stringify({ - id: 1 - }), 'MY_COLLECTION data at id 1 has correct initialState'); - expect(JSON.stringify(MY_COLLECTION.data[1].previousState)).to.eq(JSON.stringify({ - id: 1 - }), 'MY_COLLECTION data at id 1 has correct initialState'); - - expect(JSON.stringify(mySelector1)).to.eq(JSON.stringify(undefined), 'mySelector1 has correct MY_COLLECTION selector1 value'); - expect(rerenderCount).to.eq(0, 'rerenderCount has correct value'); - }); - - it('Has correct values after collecting items', async () => { - // Collect Data - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.selectors['selector1'].exists).to.eq(true, 'selector1 Selector exists'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'selector1 Selector has correct initial value'); - - expect(MY_COLLECTION.data[1].exists).to.eq(true, 'MY_COLLECTION data at id 1 exists'); - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION data at id 1 has correct initial value'); - expect(JSON.stringify(MY_COLLECTION.data[1].initialState)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION data at id 1 has correct initialState'); - expect(JSON.stringify(MY_COLLECTION.data[1].previousState)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION data at id 1 has correct initialState'); - - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - }); - }); - - describe('Selector with key', () => { - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - selectors: { - selector1: collection.Selector(1, {key: 'mywierdselector'}) - } - }) - ); - - it('Has correct initial values', () => { - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 Selector has been created'); - expect(MY_COLLECTION.selectors['selector1'].key).to.eq('mywierdselector', 'selector1 has correct key'); - }); - }); -}); diff --git a/test/collection/selector/functions/select.function.spec.ts b/test/collection/selector/functions/select.function.spec.ts deleted file mode 100644 index d572eb22..00000000 --- a/test/collection/selector/functions/select.function.spec.ts +++ /dev/null @@ -1,147 +0,0 @@ -import Agile from "../../../../src"; -import {useAgile} from "../../../../src/integrations/test"; -import {expect} from "chai"; -import Selector from "../../../../src/collection/selector"; -import Item from "../../../../src/collection/item"; - -describe('select Function Tests', () => { - let rerenderCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); - - // Object Interface - interface userInterface { - id: number - name: string - } - - // Create Collection - const MY_COLLECTION = App.Collection(collection => ({ - selectors: { - selector1: collection.Selector(1) - } - }) - ); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [mySelector1] = useAgile([MY_COLLECTION.getSelector('selector1')], () => { - rerenderCount++; - }); - - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); - - it('Has initial value', () => { - expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'selector1 Selector exists'); - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(1, 'selector1 Selector is watching correct id'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'selector1 Selector has correct initial value'); - - expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_COLLECTION at id 1 has correct data'); - expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ - id: 2, - name: 'hans' - }), 'MY_COLLECTION at id 2 has correct data'); - - expect(JSON.stringify(mySelector1)).to.eq(JSON.stringify(undefined), 'mySelector1 has correct MY_COLLECTION selector1 value'); - expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); - }); - - it('Can select another id which doesn\'t exist', async () => { - MY_COLLECTION.selectors['selector1'].select(100); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(100, 'selector1 Selector is watching correct id'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify(undefined), 'selector1 Selector has correct value'); - - expect(MY_COLLECTION.data[100] instanceof Item).to.eq(true, 'MY_COLLECTION at id 100 has been created as placeholder.. to hold connection'); - expect(JSON.stringify(MY_COLLECTION.data[100].value)).to.eq(JSON.stringify({ - id: 100, - }), 'MY_COLLECTION at id 100 has correct value'); - expect(MY_COLLECTION.data[100].exists).to.eq(false, 'MY_COLLECTION at id 100 doesn\'t exist'); - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can select another id', async () => { - MY_COLLECTION.selectors['selector1'].select(2); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(2, 'selector1 Selector is watching correct id'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ - id: 2, - name: 'hans' - }), 'selector1 Selector has correct value'); - - expect(MY_COLLECTION.data[100] instanceof Item).to.eq(false, 'MY_COLLECTION at id 100 has been removed'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t select the same id', async () => { - MY_COLLECTION.selectors['selector1'].select(2); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(2, 'selector1 Selector is watching correct id'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ - id: 2, - name: 'hans' - }), 'selector1 Selector has correct value'); - - expect(MY_COLLECTION.data[100] instanceof Item).to.eq(false, 'MY_COLLECTION at id 100 has been removed'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - - describe('Test background option', () => { - it('Does call callBackFunction by selecting new id with background = false', async () => { - MY_COLLECTION.selectors['selector1'].select(1, {background: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(1, 'selector1 Selector is watching correct id'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'selector1 Selector has correct value'); - - expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); - }); - - it('Doesn\'t call callBackFunction by selecting new id with background = true', async () => { - MY_COLLECTION.selectors['selector1'].select(2, {background: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COLLECTION.selectors['selector1'].id).to.eq(2, 'selector1 Selector is watching correct id'); - expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ - id: 2, - name: 'hans' - }), 'selector1 Selector has correct value'); - - expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); - }); - }); -}); diff --git a/test/computed/default.spec.ts b/test/computed/default.spec.ts deleted file mode 100644 index 66fa7049..00000000 --- a/test/computed/default.spec.ts +++ /dev/null @@ -1,152 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../src"; -import Computed from "../../src/computed"; -import {useAgile} from "../../src/integrations/test"; - -describe('Default Computed Tests', () => { - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - interface userInterface { - id: number - name: string - } - - describe('Computed', () => { - let computedCallCount = 0; - let rerenderCount = 0; - - // Create State - const MY_STATE = App.State('hello'); - const MY_STATE_2 = App.State('bye'); - - // Create Collection - const MY_COLLECTION = App.Collection({ - groups: ['group1', 'group2'], - selectors: ['selector1', 'selector2'] - }); - - // Create Selectors - const MY_SELECTOR = MY_COLLECTION.getSelector('selector1')?.select(1); - - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); - - // Create Computed - const MY_COMPUTED = App.Computed(() => { - computedCallCount++; - return `${MY_STATE.value}_${MY_STATE_2.value}_${MY_SELECTOR?.value?.name}_${MY_COLLECTION.findById(2)?.value.name}` - }); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myComputed] = useAgile([MY_COMPUTED], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_COMPUTED instanceof Computed).to.eq(true, 'MY_COMPUTED is computed'); - expect(MY_COMPUTED.key).to.eq(undefined, 'MY_COMPUTED has correct initial key'); - expect(MY_COMPUTED.value).to.eq('hello_bye_jeff_hans', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE, MY_STATE_2, MY_SELECTOR, MY_COLLECTION.findById(2)]), 'MY_COMPUTED has correct deps'); - expect(computedCallCount).to.eq(2, 'computedCallCount has correct initial value'); - expect(rerenderCount).to.eq(0, 'rerenderCount has correct initial value'); - }); - - it('Does call computed Function if updating item', async () => { - // Update State - MY_STATE_2.set('hehe'); - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('hello_hehe_jeff_hans', 'MY_COMPUTED has correct value'); - expect(computedCallCount).to.eq(3, 'computedCallCount has been increased by 1'); - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - - // Update Collection - MY_COLLECTION.update(2, {name: 'test'}) - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('hello_hehe_jeff_test', 'MY_COMPUTED has correct value'); - expect(computedCallCount).to.eq(4, 'computedCallCount has been increased by 1'); - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - - // Update Collection - MY_COLLECTION.update(1, {name: 'fun'}) - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('hello_hehe_fun_test', 'MY_COMPUTED has correct value'); - expect(computedCallCount).to.eq(5, 'computedCallCount has been increased by 1'); - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - }); - - describe('Computed with initial subs', () => { - let computedCallCount = 0; - let rerenderCount = 0; - - // Create State - const MY_STATE = App.State('hello'); - const MY_STATE_2 = App.State('bye'); - const MY_STATE_3 = App.State('test'); - - // Create Collection - const MY_COLLECTION = App.Collection({ - groups: ['group1', 'group2'], - selectors: ['selector1', 'selector2'] - }); - - // Create Selectors - const MY_SELECTOR = MY_COLLECTION.getSelector('selector1')?.select(1); - - MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); - - // Create Computed - const MY_COMPUTED = App.Computed(() => { - computedCallCount++; - return `${MY_STATE.value}_${MY_STATE_2.value}_${MY_SELECTOR?.value?.name}_${MY_COLLECTION.findById(2)?.value.name}` - }, [MY_STATE_3]); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myComputed] = useAgile([MY_COMPUTED], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_COMPUTED instanceof Computed).to.eq(true, 'MY_COMPUTED is computed'); - expect(MY_COMPUTED.key).to.eq(undefined, 'MY_COMPUTED has correct initial key'); - expect(MY_COMPUTED.value).to.eq('hello_bye_jeff_hans', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([MY_STATE_3]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_3, MY_STATE, MY_STATE_2, MY_SELECTOR, MY_COLLECTION.findById(2)]), 'MY_COMPUTED has correct deps'); - expect(computedCallCount).to.eq(2, 'computedCallCount has correct initial value'); - expect(rerenderCount).to.eq(0, 'rerenderCount has correct initial value'); - }); - - it('Does call computed Function if updating item', async () => { - // Update State - MY_STATE_3.set('changed'); - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE_3.value).to.eq('changed', 'MY_STATE_3 has correct value') - expect(MY_COMPUTED.value).to.eq('hello_bye_jeff_hans', 'MY_COMPUTED has correct value'); - expect(computedCallCount).to.eq(3, 'computedCallCount has been increased by 1'); - expect(rerenderCount).to.eq(0, 'rerenderCount stayed the same because computed hasn\'t changed'); - }); - }); -}); diff --git a/test/computed/functions/updateComputeFunction.function.spec.ts b/test/computed/functions/updateComputeFunction.function.spec.ts deleted file mode 100644 index d8140da3..00000000 --- a/test/computed/functions/updateComputeFunction.function.spec.ts +++ /dev/null @@ -1,130 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import Computed from "../../../src/computed"; -import {useAgile} from "../../../src/integrations/test"; - -describe('updateComputeFunction Function tests', () => { - let rerenderCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - // Create State - const MY_STATE = App.State('hello'); - const MY_STATE_2 = App.State('bye'); - const MY_STATE_3 = App.State('jeff'); - const MY_STATE_4 = App.State('hans'); - - // Create Computed - const MY_COMPUTED = App.Computed(() => { - return `${MY_STATE.value}_${MY_STATE_2.value}` - }); - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myComputed] = useAgile([MY_COMPUTED], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_COMPUTED instanceof Computed).to.eq(true, 'MY_COMPUTED is computed'); - expect(MY_COMPUTED.key).to.eq(undefined, 'MY_COMPUTED has correct initial key'); - expect(MY_COMPUTED.value).to.eq('hello_bye', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE, MY_STATE_2]), 'MY_COMPUTED has correct deps'); - - expect(myComputed).to.eq('hello_bye', 'myComputed has correct initial value'); - expect(rerenderCount).to.eq(0, 'rerenderCount has correct initial value'); - }); - - it('Can update compute Function', async () => { - // Update compute Function - MY_COMPUTED.updateComputeFunction(() => { - return `${MY_STATE_3.value}_${MY_STATE_4.value}` - }); - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('jeff_hans', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_3, MY_STATE_4]), 'MY_COMPUTED has correct deps'); - - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - }); - - it('Can update compute Function with hardCodedDeps', async () => { - // Update compute Function - MY_COMPUTED.updateComputeFunction(() => { - return `${MY_STATE_2.value}_${MY_STATE_3.value}` - }, [MY_STATE_4]); - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('bye_jeff', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([MY_STATE_4]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_4, MY_STATE_2, MY_STATE_3]), 'MY_COMPUTED has correct deps'); - - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t update compute Function with the same value', async () => { - // Update compute Function - MY_COMPUTED.updateComputeFunction(() => { - return `${MY_STATE_2.value}_${MY_STATE_3.value}` - }, []); - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('bye_jeff', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_2, MY_STATE_3]), 'MY_COMPUTED has correct deps'); - - expect(rerenderCount).to.eq(2, 'rerenderCount stayed the same'); - }); - - describe('Test background option', () => { - it('Does call callBackFunction by updating computeFunction with background = false', async () => { - // Update compute Function - MY_COMPUTED.updateComputeFunction(() => { - return `${MY_STATE.value}_${MY_STATE_3.value}` - }, [], {background: false}); - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('hello_jeff', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE, MY_STATE_3]), 'MY_COMPUTED has correct deps'); - - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - - it('Doesn\'t call callBackFunction by updating computeFunction with background = true', async () => { - // Update compute Function - MY_COMPUTED.updateComputeFunction(() => { - return `${MY_STATE_4.value}_${MY_STATE_2.value}` - }, [], {background: true}); - - // Needs some time to call computed - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_COMPUTED.value).to.eq('hans_bye', 'MY_COMPUTED has correct value'); - expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); - expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_4, MY_STATE_2]), 'MY_COMPUTED has correct deps'); - - expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); - }); - }); -}); diff --git a/test/event/default.spec.ts b/test/event/default.spec.ts deleted file mode 100644 index 4154441f..00000000 --- a/test/event/default.spec.ts +++ /dev/null @@ -1,191 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../src"; - -describe('Default Event Tests', () => { - // Define Agile - const App = new Agile(); - - interface EventPayload { - title: string - message: string - } - - describe('Event', () => { - // Create Event - const MY_EVENT = App.Event(); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.callbacks.size).to.eq(0, 'MY_EVENT has correct initial callback size'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - expect(MY_EVENT.key).to.eq(undefined, 'MY_EVENT has correct key'); - expect(MY_EVENT._key).to.eq(undefined, 'MY_EVENT has correct _key'); - }); - - it('Can change key', () => { - // Update key - MY_EVENT.key = 'myKey'; - - expect(MY_EVENT.key).to.eq('myKey', 'MY_EVENT has correct key'); - expect(MY_EVENT._key).to.eq('myKey', 'MY_EVENT has correct _key'); - }); - }); - - describe('Event with key', () => { - // Create Event - const MY_EVENT = App.Event({key: 'myKey'}); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true, key: 'myKey'}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.callbacks.size).to.eq(0, 'MY_EVENT has correct initial callback size'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - expect(MY_EVENT.key).to.eq('myKey', 'MY_EVENT has correct key'); - expect(MY_EVENT._key).to.eq('myKey', 'MY_EVENT has correct _key'); - }); - - it('Can change key', () => { - // Update key - MY_EVENT.key = 'myNewKey'; - - expect(MY_EVENT.key).to.eq('myNewKey', 'MY_EVENT has correct key'); - expect(MY_EVENT._key).to.eq('myNewKey', 'MY_EVENT has correct _key'); - }); - }); - - describe('Event with enabled = false', () => { - let eventCallCount = 0; - let currentEventPayload; - - // Create Event - const MY_EVENT = App.Event({enabled: false}); - - MY_EVENT.on((payload) => { - eventCallCount++; - currentEventPayload = payload; - }); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: false}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct initial callback size'); - expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); - - expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial value'); - expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); - }); - - it('Doesn\'t call event callbacks', () => { - // Trigger Event - MY_EVENT.trigger({title: 'test', message: 'messageTest'}); - - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); - expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); - - expect(eventCallCount).to.eq(0, 'eventCallCount stayed the same'); - expect(currentEventPayload).to.eq(undefined, 'currentEventPayload stayed the same'); - }); - }); - - describe('Event with delay', () => { - let eventCallCount = 0; - let currentEventPayload; - - // Create Event - const MY_EVENT = App.Event({delay: 1000}); - - MY_EVENT.on((payload) => { - eventCallCount++; - currentEventPayload = payload; - }); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true, delay: 1000}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct initial callback size'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - - expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial value'); - expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); - }); - - it('Does call callbacks with delay', async () => { - // Trigger Event - MY_EVENT.trigger({title: 'test', message: 'messageTest'}); - - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - - expect(eventCallCount).to.eq(0, 'eventCallCount stayed the same'); - expect(currentEventPayload).to.eq(undefined, 'currentEventPayload stayed the same'); - - // Wait one second - await new Promise(resolve => setTimeout(resolve, 1000)); - - expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - - expect(eventCallCount).to.eq(1, 'eventCallCount has been increased by 1'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test', message: 'messageTest'}), 'currentEventPayload has the correct value'); - }); - }); - - describe('Event with maxUses', () => { - let eventCallCount = 0; - let currentEventPayload; - - // Create Event - const MY_EVENT = App.Event({maxUses: 3}); - - MY_EVENT.on((payload) => { - eventCallCount++; - currentEventPayload = payload; - }); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true, maxUses: 3}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct initial callback size'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - - expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial value'); - expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); - }); - - it('Get disabled after 3 uses', () => { - // Trigger Event - MY_EVENT.trigger({title: 'test', message: 'messageTest'}); - - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); - expect(eventCallCount).to.eq(1, 'eventCallCount has been increased by 1'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test', message: 'messageTest'}), 'currentEventPayload has correct value'); - - // Trigger Event - MY_EVENT.trigger({title: 'test2', message: 'messageTest2'}); - - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - expect(MY_EVENT.uses).to.eq(2, 'MY_EVENT uses has been increased by 1'); - expect(eventCallCount).to.eq(2, 'eventCallCount has been increased by 1'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test2', message: 'messageTest2'}), 'currentEventPayload has correct value'); - - // Trigger Event - MY_EVENT.trigger({title: 'test3', message: 'messageTest3'}); - - expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT got disabled'); - expect(MY_EVENT.uses).to.eq(3, 'MY_EVENT uses has been increased by 1'); - expect(eventCallCount).to.eq(3, 'eventCallCount has been increased by 1'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test3', message: 'messageTest3'}), 'currentEventPayload has correct value'); - - // Trigger Event - MY_EVENT.trigger({title: 'test4', message: 'messageTest4'}); - - expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); - expect(MY_EVENT.uses).to.eq(3, 'MY_EVENT uses stayed the same'); - expect(eventCallCount).to.eq(3, 'eventCallCount stayed the same'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test3', message: 'messageTest3'}), 'currentEventPayload stayed the same'); - }); - }); -}); diff --git a/test/event/functions/disable.function.spec.ts b/test/event/functions/disable.function.spec.ts deleted file mode 100644 index 96f402d9..00000000 --- a/test/event/functions/disable.function.spec.ts +++ /dev/null @@ -1,31 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; - -describe('Disable Function Tests', () => { - // Define Agile - const App = new Agile(); - - interface EventPayload { - title: string - message: string - } - - // Create Event - const MY_EVENT = App.Event(); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - }); - - it('Can disable Event', () => { - // Disable Event - MY_EVENT.disable(); - - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct config'); - expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); - }); -}); diff --git a/test/event/functions/enable.function.spec.ts b/test/event/functions/enable.function.spec.ts deleted file mode 100644 index 75f68673..00000000 --- a/test/event/functions/enable.function.spec.ts +++ /dev/null @@ -1,31 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; - -describe('Enable Function Tests', () => { - // Define Agile - const App = new Agile(); - - interface EventPayload { - title: string - message: string - } - - // Create Event - const MY_EVENT = App.Event({enabled: false}); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: false}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); - }); - - it('Can enable Event', () => { - // Enable Event - MY_EVENT.enable(); - - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: false}), 'MY_EVENT has correct config'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - }); -}); diff --git a/test/event/functions/on.function.spec.ts b/test/event/functions/on.function.spec.ts deleted file mode 100644 index 6047b2b3..00000000 --- a/test/event/functions/on.function.spec.ts +++ /dev/null @@ -1,47 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; - -describe('On Function Tests', () => { - let eventCallCount = 0; - let currentEventPayload; - - // Define Agile - const App = new Agile(); - - interface EventPayload { - title: string - message: string - } - - // Create Event - const MY_EVENT = App.Event(); - - MY_EVENT.on((payload) => { - eventCallCount++; - currentEventPayload = payload; - }); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct callbacks size'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - - expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial size'); - expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); - }); - - it('Does call on callback by triggering Event', async () => { - // Trigger Event - MY_EVENT.trigger({title: "Hello", message: "There"}); - - expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); - - expect(eventCallCount).to.eq(1, 'eventCallCount has been increased by 2'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({ - title: "Hello", - message: "There" - }), 'currentEventPayload has correct value'); - }); -}); diff --git a/test/event/functions/reset.function.spec.ts b/test/event/functions/reset.function.spec.ts deleted file mode 100644 index 18dead87..00000000 --- a/test/event/functions/reset.function.spec.ts +++ /dev/null @@ -1,36 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; - -describe('Reset Function Tests', () => { - // Define Agile - const App = new Agile(); - - interface EventPayload { - title: string - message: string - } - - // Create Event - const MY_EVENT = App.Event(); - - // Trigger and disable Event - MY_EVENT.trigger(); - MY_EVENT.trigger(); - MY_EVENT.disable(); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(2, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); - }); - - it('Can reset Event', () => { - // Reset Event - MY_EVENT.reset(); - - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has been reset'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct config'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - }); -}); diff --git a/test/event/functions/trigger.function.spec.ts b/test/event/functions/trigger.function.spec.ts deleted file mode 100644 index 78cc23e3..00000000 --- a/test/event/functions/trigger.function.spec.ts +++ /dev/null @@ -1,70 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useEvent} from "../../../src/integrations/test"; - -describe('Trigger Function Tests', () => { - let eventCallCount = 0; - let currentEventPayload; - - // Define Agile - const App = new Agile(); - - interface EventPayload { - title: string - message: string - } - - // Create Event - const MY_EVENT = App.Event(); - - MY_EVENT.on((payload) => { - eventCallCount++; - currentEventPayload = payload; - }); - - // @ts-ignore - useEvent(MY_EVENT, (payload => { - eventCallCount++; - currentEventPayload = payload; - })); - - it('Has correct initial value', () => { - expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); - expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); - expect(MY_EVENT.callbacks.size).to.eq(2, 'MY_EVENT has correct callbacks size'); - expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); - - expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial size'); - expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); - }); - - it('Can trigger enabled Event', async () => { - // Trigger Event - MY_EVENT.trigger({title: "Hello", message: "There"}); - - expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); - - expect(eventCallCount).to.eq(2, 'eventCallCount has been increased by 2'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({ - title: "Hello", - message: "There" - }), 'currentEventPayload has correct value'); - }); - - it('Can\'t trigger disabled Event', async () => { - // Disable Event - MY_EVENT.enabled = false; - - // Trigger Event - MY_EVENT.trigger({title: "Hello", message: "There"}); - - expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses stayed the same'); - - expect(eventCallCount).to.eq(2, 'eventCallCount stayed the same'); - expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({ - title: "Hello", - message: "There" - }), 'currentEventPayload has correct value'); - }); -}); diff --git a/test/framework.spec.ts b/test/framework.spec.ts deleted file mode 100644 index 6f813398..00000000 --- a/test/framework.spec.ts +++ /dev/null @@ -1,28 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../src"; - -describe('Custom Framework Tests', () => { - let boundFramework = false; - - // Define Agile with framework - const App = new Agile({ - framework: { - name: 'test', // The name of the framework - bind: (agileInstance: Agile) => { - boundFramework = true; - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Will be called to force subscribed components to rerender - } - } - }); - - it('Has bound custom Framework', () => { - expect(boundFramework).to.eq(true, 'boundFramework has correct value'); - expect(App.integration?.name).to.eq('test', 'Integration Name has correct value'); - expect(typeof App.integration?.bind === 'function').to.eq(true, 'Integration bind method get set'); - expect(typeof App.integration?.updateMethod === 'function').to.eq(true, 'Integration updateMethod method get set'); - expect(App.integration?.ready).to.eq(true, 'Integration is Ready'); - }); -}); diff --git a/test/state/default.spec.ts b/test/state/default.spec.ts deleted file mode 100644 index f24ffa1d..00000000 --- a/test/state/default.spec.ts +++ /dev/null @@ -1,74 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../src"; - -describe('Default State Tests', () => { - // Define Agile - const App = new Agile(); - - describe('State', () => { - // Create State - const MY_STATE = App.State('hello'); - - it('Has correct initial values', () => { - expect(MY_STATE.value).to.eq('hello', 'MY_STATE has correct value'); - expect(typeof MY_STATE.value === 'string').to.eq(true, 'MY_STATE has correct type'); - expect(MY_STATE._value).to.eq('hello', 'MY_STATE has correct _value') - expect(MY_STATE.previousState).to.eq('hello', 'MY_STATE has correct previousState'); - expect(MY_STATE.key).to.eq(undefined, 'MY_STATE has correct key'); - expect(MY_STATE._key).to.eq(undefined, 'My_STATE has correct _key'); - expect(MY_STATE.sideEffects).to.eq(undefined, 'MY_STATE has no sideEffects'); - expect(MY_STATE.nextState).to.eq('hello', 'MY_STATE has correct nextState'); - expect(MY_STATE.initialState).to.eq('hello', 'MY_STATE has correct initialState'); - expect(MY_STATE.exists).to.eq(true, 'MY_STATE has correct exists'); - expect(MY_STATE.isSet).to.eq(false, 'MY_STATE has correct isSet'); - expect(MY_STATE.persistSettings.isPersisted).to.eq(false, 'MY_STATE has correct isPersistState'); - expect(MY_STATE.isPlaceholder).to.eq(false, 'MY_STATE has correct isPlaceholder'); - expect(MY_STATE.valueType).to.eq(undefined, 'MY_STATE has correct valueType'); - expect(MY_STATE.exists).to.eq(true, 'MY_STATE exists'); - }); - - it('Can change key', () => { - // Update key - MY_STATE.key = 'myNewKey'; - - expect(MY_STATE.key).to.eq('myNewKey', 'MY_STATE has correct key'); - expect(MY_STATE._key).to.eq('myNewKey', 'My_STATE has correct _key'); - }); - - it('Can change value', () => { - // Update value - MY_STATE.value = 'bye'; - - expect(MY_STATE.value).to.eq('bye', 'MY_STATE has correct value'); - expect(MY_STATE._value).to.eq('bye', 'My_STATE has correct _value'); - }); - }); - - describe('State with Key', () => { - // Create State - const MY_STATE_WITH_KEY = App.State(true, 'myKey'); - - it('Has correct initial values', () => { - expect(typeof MY_STATE_WITH_KEY.value === 'boolean').to.eq(true, 'MY_STATE_WITH_KEY has correct type'); - expect(MY_STATE_WITH_KEY.key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct key'); - expect(MY_STATE_WITH_KEY._key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct _key'); - }); - - it('Can change key', () => { - // Update key - MY_STATE_WITH_KEY.key = 'myNewKey'; - - expect(MY_STATE_WITH_KEY.key).to.eq('myNewKey', 'MY_STATE_WITH_KEY has correct key'); - expect(MY_STATE_WITH_KEY._key).to.eq('myNewKey', 'MY_STATE_WITH_KEY has correct _key'); - }); - - it('Can change value', () => { - // Update value - MY_STATE_WITH_KEY.value = false; - - expect(MY_STATE_WITH_KEY.value).to.eq(false, 'MY_STATE_WITH_KEY has correct value'); - expect(MY_STATE_WITH_KEY._value).to.eq(false, 'MY_STATE_WITH_KEY has correct _value'); - }); - }); -}); diff --git a/test/state/functions/patch.function.spec.ts b/test/state/functions/patch.function.spec.ts deleted file mode 100644 index f01eec2f..00000000 --- a/test/state/functions/patch.function.spec.ts +++ /dev/null @@ -1,204 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; - -describe('Patch Function Tests', () => { - let rerenderCount = 0; - let sideEffectCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - // Object Interface - interface userInterface { - id: number, - name: string - } - - // Create State - const MY_STATE = App.State({id: 1, name: 'jeff'}); - - // Set sideEffects for testing the functionality of it - MY_STATE.sideEffects = () => { - sideEffectCount++ - }; - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_STATE has correct value'); - expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); - expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); - - expect(JSON.stringify(myHookState)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'myHookState has correct MY_STATE value'); - expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); - expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); - }); - - describe('Patch State', () => { - it('Can patch value into State', async () => { - // Patch Value - MY_STATE.patch({name: 'hans'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ - id: 1, - name: 'hans' - }), 'MY_STATE has correct value'); - expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_STATE has correct previousState'); - expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ - id: 1, - name: 'hans' - }), 'MY_STATE has correct nextState'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); - - expect(sideEffectCount).to.eq(1, 'sideEffectCount has been increased by 1'); - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t patch value into State if the value is the same', async () => { - // Patch Value - MY_STATE.patch({name: 'hans'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ - id: 1, - name: 'hans' - }), 'MY_STATE value stayed the same'); - expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_STATE previousState stayed the same'); - expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ - id: 1, - name: 'hans' - }), 'MY_STATE nextState stayed the same'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE isSet stayed the same'); - - expect(sideEffectCount).to.eq(1, 'sideEffectCount hasn\'t been increased'); - expect(rerenderCount).to.eq(1, 'rerenderCount hasn\'t been increased'); - }); - - it('Can\'t patch value into State which is no Object', async () => { - // Patch State - // @ts-ignore - MY_STATE.patch('noObject'); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ - id: 1, - name: 'hans' - }), 'MY_STATE value stayed the same'); - expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ - id: 1, - name: 'jeff' - }), 'MY_STATE previousState stayed the same'); - expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ - id: 1, - name: 'hans' - }), 'MY_STATE nextState stayed the same'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE isSet stayed the same'); - - expect(sideEffectCount).to.eq(1, 'sideEffectCount hasn\'t been increased'); - expect(rerenderCount).to.eq(1, 'rerenderCount hasn\'t been increased'); - }); - - it('Can\'t patch value into non Object State', async () => { - // Create State - const MY_NON_OBJECT_STATE = App.State('test'); - - // Patch State - MY_NON_OBJECT_STATE.patch({test: 'test'}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_NON_OBJECT_STATE.value).to.eq('test', 'MY_NON_OBJECT_STATE value stayed the same'); - expect(MY_NON_OBJECT_STATE.previousState).to.eq('test', 'MY_NON_OBJECT_STATE previousState stayed the same'); - expect(MY_NON_OBJECT_STATE.nextState).to.eq('test', 'MY_NON_OBJECT_STATE nextState stayed the same'); - expect(MY_NON_OBJECT_STATE.isSet).to.eq(false, 'MY_NON_OBJECT_STATE isSet stayed the same'); - }); - }); - - describe('Test addNewProperties option', () => { - it('Doesn\'t add property to value with addNewProperties = false', async () => { - // Patch State - MY_STATE.patch({name: 'frank', age: 10}, {addNewProperties: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ - id: 1, - name: 'frank' - }), 'MY_STATE has correct value'); - expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ - id: 1, - name: 'hans' - }), 'MY_STATE has correct previousState'); - expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ - id: 1, - name: 'frank' - }), 'MY_STATE has correct nextState'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); - - expect(sideEffectCount).to.eq(2, 'sideEffectCount has been increased by 1'); - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Does add property to value with addNewProperties = true', async () => { - // Patch State - MY_STATE.patch({name: 'benno', age: 15}, {addNewProperties: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ - id: 1, - name: 'benno', - age: 15 - }), 'MY_STATE has correct value'); - expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ - id: 1, - name: 'frank' - }), 'MY_STATE has correct previousState'); - expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ - id: 1, - name: 'benno', - age: 15 - }), 'MY_STATE has correct nextState'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); - - expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 1'); - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - }); -}); diff --git a/test/state/functions/persist.function.spec.ts b/test/state/functions/persist.function.spec.ts deleted file mode 100644 index ae4d4add..00000000 --- a/test/state/functions/persist.function.spec.ts +++ /dev/null @@ -1,129 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; - - -describe('Persist Function Tests', () => { - const myStorage: any = {} - - // Define Agile with Storage - const App = new Agile({ - storageConfig: { - prefix: 'test', - methods: { - get: ((key) => { - return myStorage[key]; - }), - set: (key, value) => { - myStorage[key] = value; - }, - remove: (key) => { - delete myStorage[key]; - } - } - } - }); - - describe('State', () => { - // Create State - const MY_STATE = App.State(1); - - it('Has correct initial values', () => { - expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); - expect(MY_STATE.persistSettings.isPersisted).to.eq(false, 'MY_STATE has correct isPersistState'); - expect(App.storage.persistedStates.has(MY_STATE)).to.eq(false, 'MY_STATE isn\'t in persistedStates'); - expect(App.storage.persistedStates.has(MY_STATE)).to.eq(false, 'MY_STATE isn\'t in persistedStates'); - }); - - it("Can\'t persist State without persist Key", () => { - // Persist State - MY_STATE.persist(); - - expect(MY_STATE.persistSettings.isPersisted).to.eq(false, 'MY_STATE has correct isPersisted'); - expect(MY_STATE.persistSettings.persistKey).to.eq(undefined, 'MY_STATE has correct persistKey'); - expect(MY_STATE.key).to.eq(undefined, 'MY_STATE has correct key'); - expect(App.storage.persistedStates.has(MY_STATE)).to.eq(false, 'MY_STATE isn\'t in persistedStates'); - expect(App.storage.get('mySecondKey')).to.eq(undefined, 'MY_STATE isn\'t in storage'); - }); - - it("Can persist State with persist Key", async () => { - // Persist State - MY_STATE.persist('mySecondKey'); - - // Needs some time to persist value - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE.persistSettings.isPersisted).to.eq(true, 'MY_STATE has correct isPersisted'); - expect(MY_STATE.persistSettings.persistKey).to.eq('mySecondKey', 'MY_STATE has correct persistKey'); - expect(MY_STATE.key).to.eq('mySecondKey', 'MY_STATE key has been set to persistKey if no key is provided'); - expect(App.storage.persistedStates.has(MY_STATE)).to.eq(true, 'MY_STATE isn\'t in persistedStates'); - expect(App.storage.get('mySecondKey')).to.eq(1, 'MY_STATE is in storage'); - }); - - describe('Test reset method on persist State', () => { - it('Removes the State from the Storage if it get reset', () => { - // Reset State - MY_STATE.reset(); - - expect(MY_STATE.persistSettings.isPersisted).to.eq(true, 'MY_STATE has correct isPersisted'); - expect(MY_STATE.persistSettings.persistKey).to.eq('mySecondKey', 'MY_STATE has correct persistKey'); - expect(MY_STATE.key).to.eq('mySecondKey', 'MY_STATE has correct key'); - expect(App.storage.persistedStates.has(MY_STATE)).to.eq(true, 'MY_STATE is in persistedStates'); - expect(App.storage.get('mySecondKey')).to.eq(undefined, 'MY_STATE isn\'t in storage'); - }); - }); - - describe('Test set method on persist State', () => { - it('Updates the State in the Storage if it get changed', () => { - // Reset State - MY_STATE.set(5); - - expect(MY_STATE.persistSettings.isPersisted).to.eq(true, 'MY_STATE has correct isPersisted'); - expect(MY_STATE.persistSettings.persistKey).to.eq('mySecondKey', 'MY_STATE_WITH_KEY has correct persistKey'); - expect(App.storage.persistedStates.has(MY_STATE)).to.eq(true, 'MY_STATE_WITH_KEY is in persistedStates'); - expect(App.storage.get('mySecondKey')).to.eq(5, 'MY_STATE_WITH_KEY is in storage and has been updated'); - }); - }); - }); - - describe('State with Key', () => { - // Create State - const MY_STATE_WITH_KEY = App.State('hello', 'myKey'); - - it('Has correct initial values', () => { - expect(MY_STATE_WITH_KEY.value).to.eq('hello', 'MY_STATE_WITH_KEY has correct value'); - expect(MY_STATE_WITH_KEY.key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct key'); - expect(MY_STATE_WITH_KEY.persistSettings.isPersisted).to.eq(false, 'MY_STATE_WITH_KEY has correct isPersistState'); - expect(App.storage.persistedStates.has(MY_STATE_WITH_KEY)).to.eq(false, 'MY_STATE_WITH_KEY isn\'t in persistedStates'); - expect(App.storage.get('myKey')).to.eq(undefined, 'MY_STATE_WITH_KEY isn\'t in storage'); - }); - - it("Can persist State without persist Key", async () => { - // Persist State - MY_STATE_WITH_KEY.persist(); - - // Needs some time to persist value - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE_WITH_KEY.persistSettings.isPersisted).to.eq(true, 'MY_STATE_WITH_KEY has correct isPersistState'); - expect(MY_STATE_WITH_KEY.persistSettings.persistKey).to.eq('myKey', 'MY_STATE_WITH_KEY has correct persistKey'); - expect(App.storage.persistedStates.has(MY_STATE_WITH_KEY)).to.eq(true, 'MY_STATE_WITH_KEY is in persistedStates'); - expect(App.storage.get('myKey')).to.eq('hello', 'MY_STATE_WITH_KEY is in storage'); - }); - - it("Can persist State with persist Key", async () => { - // Persist State - MY_STATE_WITH_KEY.persist('myThirdKey'); - - // Needs some time to persist value - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE_WITH_KEY.persistSettings.isPersisted).to.eq(true, 'MY_STATE_WITH_KEY has correct isPersistState'); - expect(MY_STATE_WITH_KEY.persistSettings.persistKey).to.eq('myThirdKey', 'MY_STATE_WITH_KEY has correct persistKey'); - expect(MY_STATE_WITH_KEY.key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct key'); - expect(App.storage.persistedStates.has(MY_STATE_WITH_KEY)).to.eq(true, 'MY_STATE_WITH_KEY is in persistedStates'); - expect(App.storage.get('myThirdKey')).to.eq('hello', 'MY_STATE_WITH_KEY with new key is in storage'); - expect(App.storage.get('myKey')).to.eq(undefined, 'MY_STATE_WITH_KEY with old key isn\'t in storage'); - }); - }); -}); diff --git a/test/state/functions/reset.function.spec.ts b/test/state/functions/reset.function.spec.ts deleted file mode 100644 index 932afe4d..00000000 --- a/test/state/functions/reset.function.spec.ts +++ /dev/null @@ -1,72 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; - -describe('Reset Function Tests', () => { - let rerenderCount = 0; - let sideEffectCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - // Create State - const MY_STATE = App.State(1); - - // Set sideEffects for testing the functionality of it - MY_STATE.sideEffects = () => { - sideEffectCount++ - }; - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); - expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); - expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); - - expect(myHookState).to.eq(1, 'myHookState has correct MY_STATE value'); - expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); - expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); - }); - - it('Can reset State', async () => { - // Change State - MY_STATE.set(2); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - // Change State - MY_STATE.set(5); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - // Reset State - MY_STATE.reset(); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); - expect(MY_STATE.previousState).to.eq(5, 'MY_STATE has correct previousState'); - expect(MY_STATE.nextState).to.eq(1, 'MY_STATE has correct nextState'); - expect(MY_STATE.isSet).to.eq(false, 'MY_STATE has correct isSet'); - - expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 3 (2 by set, 1 by reset)'); - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 3 (2 by set, 1 by reset)'); - }); -}); diff --git a/test/state/functions/set.function.spec.ts b/test/state/functions/set.function.spec.ts deleted file mode 100644 index 4f2bc23e..00000000 --- a/test/state/functions/set.function.spec.ts +++ /dev/null @@ -1,125 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; - -describe('Set Function Tests', () => { - let rerenderCount = 0; - let sideEffectCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - // Create State - const MY_STATE = App.State(1); - - // Set sideEffects for testing the functionality of it - MY_STATE.sideEffects = () => { - sideEffectCount++ - }; - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); - expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); - expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); - - expect(myHookState).to.eq(1, 'myHookState has correct MY_STATE value'); - expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); - expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); - }); - - it('Can change State', async () => { - // Change State - MY_STATE.set(2); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); - expect(MY_STATE.previousState).to.eq(1, 'MY_STATE has correct previousState'); - expect(MY_STATE.nextState).to.eq(2, 'MY_STATE has correct nextState'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); - expect(MY_STATE.exists).to.eq(true, 'MY_STATE exists'); - - expect(sideEffectCount).to.eq(1, 'sideEffectCount has been increased by 1'); - expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); - }); - - it('Can\'t change State with the same value', async () => { - // Change State - MY_STATE.set(2); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); - expect(MY_STATE.previousState).to.eq(1, 'MY_STATE has correct previousState'); - expect(MY_STATE.nextState).to.eq(2, 'MY_STATE has correct nextState'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); - - expect(sideEffectCount).to.eq(1, 'sideEffectCount hasn\'t been increased'); - expect(rerenderCount).to.eq(1, 'rerenderCount hasn\'t been increased'); - }); - - describe('Test sideEffects option', () => { - it('Does call sideEffects by changing State with sideEffects = true', async () => { - // Change State - MY_STATE.set(3, {sideEffects: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(sideEffectCount).to.eq(2, 'sideEffectCount has been increased by 1'); - expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); - }); - - it('Doesn\'t call sideEffects by changing State with sideEffects = false', async () => { - // Change State - MY_STATE.set(4, {sideEffects: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(sideEffectCount).to.eq(2, 'sideEffectCount hasn\'t been increased'); - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); - }); - }); - - describe('Test background option', () => { - it('Doesn\'t call callBackFunction by changing State with background = true', async () => { - // Change State - MY_STATE.set(5, {background: true}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 1'); - expect(rerenderCount).to.eq(3, 'rerenderCount hasn\'t been increased'); - }); - - it('Does call callBackFunction by changing State with background = false', async () => { - // Change State - MY_STATE.set(6, {background: false}); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(sideEffectCount).to.eq(4, 'sideEffectCount has been increased by 1'); - expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); - }); - }); -}); diff --git a/test/state/functions/type.function.spec.ts b/test/state/functions/type.function.spec.ts deleted file mode 100644 index 6810195d..00000000 --- a/test/state/functions/type.function.spec.ts +++ /dev/null @@ -1,32 +0,0 @@ -import 'mocha'; -import {expect} from 'chai' -import Agile from "../../../src"; - -describe('Type Function Tests', () => { - // Define Agile - const App = new Agile(); - - // Create State - const MY_STATE = App.State(1).type(Number); - - it('Has correct initial values', () => { - expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); - expect(typeof MY_STATE.value === 'number').to.eq(true, 'MY_STATE has correct type'); - expect(MY_STATE.valueType).to.eq('number', 'MY_STATE correct valueType'); - }); - - it('Can change State with correct Type', async () => { - // Change State - MY_STATE.set(2); - - expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); - }); - - it('Can\'t change State with wrong Type', async () => { - // Change State - // @ts-ignore - MY_STATE.set('Hello'); - - expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); - }); -}); diff --git a/test/state/functions/undo.function.spec.ts b/test/state/functions/undo.function.spec.ts deleted file mode 100644 index 27ffb3f9..00000000 --- a/test/state/functions/undo.function.spec.ts +++ /dev/null @@ -1,72 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; - -describe('Undo Function Tests', () => { - let rerenderCount = 0; - let sideEffectCount = 0; - - // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); - - // Create State - const MY_STATE = App.State(1); - - // Set sideEffects for testing the functionality of it - MY_STATE.sideEffects = () => { - sideEffectCount++ - }; - - // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { - rerenderCount++; - }); - - it('Has correct initial values', () => { - expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); - expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); - expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); - - expect(myHookState).to.eq(1, 'myHookState has correct MY_STATE value'); - expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); - expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); - }); - - it('Can undo State', async () => { - // Change State - MY_STATE.set(2); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - // Change State - MY_STATE.set(5); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - // Undo State - MY_STATE.undo(); - - // Needs some time to call callbackFunction - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); - expect(MY_STATE.previousState).to.eq(5, 'MY_STATE has correct previousState'); - expect(MY_STATE.nextState).to.eq(2, 'MY_STATE has correct nextState'); - expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); - - expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 3 (2 by set, 1 by undo)'); - expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 3 (2 by set, 1 by undo)'); - }); -}); diff --git a/test/state/functions/watch.function.spec.ts b/test/state/functions/watch.function.spec.ts deleted file mode 100644 index 1b598bea..00000000 --- a/test/state/functions/watch.function.spec.ts +++ /dev/null @@ -1,52 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../../../src"; - -describe('Watcher Tests', () => { - let calledWatcherCount = 0; - let watcherValue = 1; - - // Define Agile - const App = new Agile(); - - // Create State - const MY_STATE = App.State(1); - - // Create Watcher - MY_STATE.watch('firstWatcher', (value) => { - watcherValue = value; - calledWatcherCount++; - }); - - it('Has correct initial values', () => { - expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); - expect(MY_STATE.watchers.firstWatcher !== undefined).to.eq(true, 'MY_STATE has firstWatcher in watchers') - }); - - it('Can Watch State', async () => { - // Update State - MY_STATE.set(2); - - // Needs some time to call watcher - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); - expect(calledWatcherCount).to.eq(1, 'calledWatcherCount has been increased by 1'); - expect(watcherValue).to.eq(2, 'watcherValue has correct value'); - }); - - it('Can Remove Watcher', async () => { - // Remove Watcher - MY_STATE.removeWatcher('firstWatcher'); - - // Update State - MY_STATE.set(3); - - // Needs some time to call watcher - await new Promise(resolve => setTimeout(resolve, 100)); - - expect(MY_STATE.value).to.eq(3, 'MY_STATE has correct value'); - expect(calledWatcherCount).to.eq(1, 'calledWatcherCount hasn\'t been increased'); - expect(watcherValue).to.eq(2, 'watcherValue has\'t change.. because of no update'); - }); -}); diff --git a/test/storage.spec.ts b/test/storage.spec.ts deleted file mode 100644 index 93847963..00000000 --- a/test/storage.spec.ts +++ /dev/null @@ -1,98 +0,0 @@ -import 'mocha'; -import {expect} from 'chai'; -import Agile from "../src"; - -describe('Custom Storage Tests', () => { - const myStorage: any = {} - - // Define Agile - const App = new Agile(); - - // Create Storage - const storage = App.Storage({ - prefix: 'test', - methods: { - get: ((key) => { - return myStorage[key]; - }), - set: (key, value) => { - myStorage[key] = value; - }, - remove: (key) => { - delete myStorage[key]; - } - } - }); - - describe('Can work with numbers', () => { - it('Can set an item into the Storage', async () => { - // Set Item into Storage - storage.set('myKey', 1); - - expect(myStorage['_test_myKey']).to.eq(JSON.stringify(1)); - }); - - it('Can get an item from the Storage', () => { - // Get Item from Storage - const item = storage.get('myKey'); - - expect(item).to.eq(1); - }); - - it('Can remove an item from the Storage', () => { - // Remove Item from Storage - storage.remove('myKey'); - - expect(myStorage['_test_myKey']).to.eq(undefined); - expect(storage.get('myKey')).to.eq(undefined); - }); - }); - - describe('Can work with object', () => { - it('Can set an item into the Storage', () => { - // Set Item into Storage - storage.set('mySecondKey', {id: 1, name: 'jeff'}); - - expect(myStorage['_test_mySecondKey']).to.eq(JSON.stringify({id: 1, name: 'jeff'})); - }); - - it('Can get an item from the Storage', () => { - // Get Item from Storage - const item = storage.get('mySecondKey'); - - expect(JSON.stringify(item)).to.eq(JSON.stringify({id: 1, name: 'jeff'})); - }); - - it('Can remove an item from the Storage', () => { - // Remove Item from Storage - storage.remove('mySecondKey'); - - expect(myStorage['_test_mySecondKey']).to.eq(undefined); - expect(storage.get('mySecondKey')).to.eq(undefined); - }); - }); - - describe('Can work with array', () => { - it('Can set an item into the Storage', () => { - // Set Item into Storage - storage.set('myThirdKey', [1, 2, 3]); - - expect(myStorage['_test_myThirdKey']).to.eq(JSON.stringify([1, 2, 3])); - }); - - it('Can get an item from the Storage', () => { - // Get Item from Storage - const item = storage.get('myThirdKey'); - - expect(JSON.stringify(item)).to.eq(JSON.stringify([1, 2, 3])); - }); - - it('Can remove an item from the Storage', () => { - // Remove Item from Storage - storage.remove('myThirdKey'); - - expect(myStorage['myThirdKey']).to.eq(undefined); - expect(storage.get('myThirdKey')).to.eq(undefined); - }); - }); -}); diff --git a/tsconfig.json b/tsconfig.json deleted file mode 100644 index 61d65510..00000000 --- a/tsconfig.json +++ /dev/null @@ -1,71 +0,0 @@ -{ - "compilerOptions": { - /* Visit https://aka.ms/tsconfig.json to read more about this file */ - - /* Basic Options */ - // "incremental": true, /* Enable incremental compilation */ - "target": "ES2015", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */ - "module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */ - // "lib": [], /* Specify library files to be included in the compilation. */ - // "allowJs": true, /* Allow javascript files to be compiled. */ - // "checkJs": true, /* Report errors in .js files. */ - // "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ - "declaration": true, /* Generates corresponding '.d.ts' file. */ - // "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ - // "sourceMap": true, /* Generates corresponding '.map' file. */ - // "outFile": "./", /* Concatenate and emit output to single file. */ - "outDir": "./dist", /* Redirect output structure to the directory. */ - "rootDir": "./src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */ - // "composite": true, /* Enable project compilation */ - // "tsBuildInfoFile": "./", /* Specify file to store incremental compilation information */ - // "removeComments": true, /* Do not emit comments to output. */ - // "noEmit": true, /* Do not emit outputs. */ - // "importHelpers": true, /* Import emit helpers from 'tslib'. */ - // "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */ - // "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */ - - /* Strict Type-Checking Options */ - "strict": true, /* Enable all strict type-checking options. */ - "noImplicitAny": false, /* Raise error on expressions and declarations with an implied 'any' type. */ - // "strictNullChecks": true, /* Enable strict null checks. */ - // "strictFunctionTypes": true, /* Enable strict checking of function types. */ - // "strictBindCallApply": true, /* Enable strict 'bind', 'call', and 'apply' methods on functions. */ - // "strictPropertyInitialization": true, /* Enable strict checking of property initialization in classes. */ - // "noImplicitThis": true, /* Raise error on 'this' expressions with an implied 'any' type. */ - // "alwaysStrict": true, /* Parse in strict mode and emit "use strict" for each source file. */ - - /* Additional Checks */ - // "noUnusedLocals": true, /* Report errors on unused locals. */ - // "noUnusedParameters": true, /* Report errors on unused parameters. */ - // "noImplicitReturns": true, /* Report error when not all code paths in function return a value. */ - // "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ - - /* Module Resolution Options */ - "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ - // "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ - // "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ - // "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */ - // "typeRoots": [], /* List of folders to include type definitions from. */ - // "types": [], /* Type declaration files to be included in compilation. */ - // "allowSyntheticDefaultImports": true, /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */ - // "esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */ - // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ - // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ - - /* Source Map Options */ - // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ - // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ - // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ - - /* Experimental Options */ - // "experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */ - // "emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */ - - /* Advanced Options */ - "skipLibCheck": true , /* Skip type checking of declaration files. */ - "forceConsistentCasingInFileNames": true /* Disallow inconsistently-cased references to the same file. */ - }, - "include": ["./src/**/*", "next"], - "exclude": ["dist", "node_modules"] -} From bc44828b204e078874b9cd09b9292c38cc2c4fbc Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Tue, 29 Sep 2020 17:32:03 +0200 Subject: [PATCH 02/15] Created ground package structure --- packages/agile-api/package.json | 20 + packages/agile-api/src/index.ts | 179 +++++ packages/agile-api/tsconfig.json | 8 + packages/agile-core/package.json | 20 + packages/agile-core/src/agile.ts | 155 +++++ packages/agile-core/src/collection/group.ts | 228 +++++++ packages/agile-core/src/collection/index.ts | 641 ++++++++++++++++++ packages/agile-core/src/collection/item.ts | 24 + .../agile-core/src/collection/perstist.ts | 243 +++++++ .../agile-core/src/collection/selector.ts | 130 ++++ packages/agile-core/src/computed/index.ts | 117 ++++ packages/agile-core/src/event/index.ts | 201 ++++++ packages/agile-core/src/index.ts | 0 packages/agile-core/src/internal.ts | 28 + packages/agile-core/src/runtime.ts | 286 ++++++++ packages/agile-core/src/state/dep.ts | 26 + packages/agile-core/src/state/index.ts | 339 +++++++++ packages/agile-core/src/state/persist.ts | 85 +++ packages/agile-core/src/storage.ts | 184 +++++ packages/agile-core/src/sub.ts | 204 ++++++ packages/agile-core/src/use.ts | 94 +++ packages/agile-core/src/utils.ts | 178 +++++ .../tests/collection/default.spec.ts | 178 +++++ .../functions/collect.function.spec.ts | 374 ++++++++++ .../functions/createGroup.function.spec.ts | 49 ++ .../functions/createSelector.function.spec.ts | 54 ++ .../functions/findById.function.spec.ts | 39 ++ .../functions/getGroup.function.spec.ts | 44 ++ .../functions/getSelector.function.spec.ts | 42 ++ .../functions/getValueById.function.spec.ts | 37 + .../functions/remove.function.spec.ts | 224 ++++++ .../functions/update.function.spec.ts | 222 ++++++ .../tests/collection/group/default.spec.ts | 183 +++++ .../group/functions/add.function.spec.ts | 256 +++++++ .../group/functions/has.function.spec.ts | 60 ++ .../group/functions/remove.function.spec.ts | 137 ++++ .../tests/collection/selector/default.spec.ts | 118 ++++ .../functions/select.function.spec.ts | 147 ++++ .../agile-core/tests/computed/default.spec.ts | 152 +++++ .../updateComputeFunction.function.spec.ts | 130 ++++ .../agile-core/tests/event/default.spec.ts | 191 ++++++ .../event/functions/disable.function.spec.ts | 31 + .../event/functions/enable.function.spec.ts | 31 + .../tests/event/functions/on.function.spec.ts | 47 ++ .../event/functions/reset.function.spec.ts | 36 + .../event/functions/trigger.function.spec.ts | 70 ++ packages/agile-core/tests/framework.spec.ts | 28 + .../agile-core/tests/state/default.spec.ts | 74 ++ .../state/functions/patch.function.spec.ts | 204 ++++++ .../state/functions/persist.function.spec.ts | 129 ++++ .../state/functions/reset.function.spec.ts | 72 ++ .../state/functions/set.function.spec.ts | 125 ++++ .../state/functions/type.function.spec.ts | 32 + .../state/functions/undo.function.spec.ts | 72 ++ .../state/functions/watch.function.spec.ts | 52 ++ packages/agile-core/tests/storage.spec.ts | 98 +++ packages/agile-core/tsconfig.json | 8 + packages/agile-react/package.json | 27 + packages/agile-react/src/hooks/AgileHOC.ts | 92 +++ packages/agile-react/src/hooks/useAgile.ts | 82 +++ packages/agile-react/src/hooks/useEvent.ts | 27 + packages/agile-react/src/index.ts | 7 + packages/agile-react/src/react.integration.ts | 31 + packages/agile-react/tests/ReadMe.md | 1 + packages/agile-react/tests/hooks/index.ts | 2 + packages/agile-react/tests/hooks/useAgile.ts | 68 ++ packages/agile-react/tests/hooks/useEvent.ts | 18 + packages/agile-react/tsconfig.json | 8 + packages/tsconfig.default.json | 70 ++ 69 files changed, 7569 insertions(+) create mode 100644 packages/agile-api/package.json create mode 100644 packages/agile-api/src/index.ts create mode 100644 packages/agile-api/tsconfig.json create mode 100644 packages/agile-core/package.json create mode 100644 packages/agile-core/src/agile.ts create mode 100644 packages/agile-core/src/collection/group.ts create mode 100644 packages/agile-core/src/collection/index.ts create mode 100644 packages/agile-core/src/collection/item.ts create mode 100644 packages/agile-core/src/collection/perstist.ts create mode 100644 packages/agile-core/src/collection/selector.ts create mode 100644 packages/agile-core/src/computed/index.ts create mode 100644 packages/agile-core/src/event/index.ts create mode 100644 packages/agile-core/src/index.ts create mode 100644 packages/agile-core/src/internal.ts create mode 100644 packages/agile-core/src/runtime.ts create mode 100644 packages/agile-core/src/state/dep.ts create mode 100644 packages/agile-core/src/state/index.ts create mode 100644 packages/agile-core/src/state/persist.ts create mode 100644 packages/agile-core/src/storage.ts create mode 100644 packages/agile-core/src/sub.ts create mode 100644 packages/agile-core/src/use.ts create mode 100644 packages/agile-core/src/utils.ts create mode 100644 packages/agile-core/tests/collection/default.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/collect.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/createGroup.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/createSelector.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/findById.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/getGroup.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/getSelector.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/getValueById.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/remove.function.spec.ts create mode 100644 packages/agile-core/tests/collection/functions/update.function.spec.ts create mode 100644 packages/agile-core/tests/collection/group/default.spec.ts create mode 100644 packages/agile-core/tests/collection/group/functions/add.function.spec.ts create mode 100644 packages/agile-core/tests/collection/group/functions/has.function.spec.ts create mode 100644 packages/agile-core/tests/collection/group/functions/remove.function.spec.ts create mode 100644 packages/agile-core/tests/collection/selector/default.spec.ts create mode 100644 packages/agile-core/tests/collection/selector/functions/select.function.spec.ts create mode 100644 packages/agile-core/tests/computed/default.spec.ts create mode 100644 packages/agile-core/tests/computed/functions/updateComputeFunction.function.spec.ts create mode 100644 packages/agile-core/tests/event/default.spec.ts create mode 100644 packages/agile-core/tests/event/functions/disable.function.spec.ts create mode 100644 packages/agile-core/tests/event/functions/enable.function.spec.ts create mode 100644 packages/agile-core/tests/event/functions/on.function.spec.ts create mode 100644 packages/agile-core/tests/event/functions/reset.function.spec.ts create mode 100644 packages/agile-core/tests/event/functions/trigger.function.spec.ts create mode 100644 packages/agile-core/tests/framework.spec.ts create mode 100644 packages/agile-core/tests/state/default.spec.ts create mode 100644 packages/agile-core/tests/state/functions/patch.function.spec.ts create mode 100644 packages/agile-core/tests/state/functions/persist.function.spec.ts create mode 100644 packages/agile-core/tests/state/functions/reset.function.spec.ts create mode 100644 packages/agile-core/tests/state/functions/set.function.spec.ts create mode 100644 packages/agile-core/tests/state/functions/type.function.spec.ts create mode 100644 packages/agile-core/tests/state/functions/undo.function.spec.ts create mode 100644 packages/agile-core/tests/state/functions/watch.function.spec.ts create mode 100644 packages/agile-core/tests/storage.spec.ts create mode 100644 packages/agile-core/tsconfig.json create mode 100644 packages/agile-react/package.json create mode 100644 packages/agile-react/src/hooks/AgileHOC.ts create mode 100644 packages/agile-react/src/hooks/useAgile.ts create mode 100644 packages/agile-react/src/hooks/useEvent.ts create mode 100644 packages/agile-react/src/index.ts create mode 100644 packages/agile-react/src/react.integration.ts create mode 100644 packages/agile-react/tests/ReadMe.md create mode 100644 packages/agile-react/tests/hooks/index.ts create mode 100644 packages/agile-react/tests/hooks/useAgile.ts create mode 100644 packages/agile-react/tests/hooks/useEvent.ts create mode 100644 packages/agile-react/tsconfig.json create mode 100644 packages/tsconfig.default.json diff --git a/packages/agile-api/package.json b/packages/agile-api/package.json new file mode 100644 index 00000000..fed7a89c --- /dev/null +++ b/packages/agile-api/package.json @@ -0,0 +1,20 @@ +{ + "name": "@agile-ts/core", + "version": "0.0.1", + "author": "BennoDev", + "license": "ISC", + "description": "API extention for AgileTs", + "keywords": [], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "build": "tsc" + }, + "publishConfig": { + "access": "public" + }, + "repository": { + "type": "git", + "url": "https://github.com/agile-ts/agile.git" + } + } \ No newline at end of file diff --git a/packages/agile-api/src/index.ts b/packages/agile-api/src/index.ts new file mode 100644 index 00000000..b40fe166 --- /dev/null +++ b/packages/agile-api/src/index.ts @@ -0,0 +1,179 @@ +import * as http from 'http'; +import {copy, isValidUrl} from "../utils"; + +export interface AgileResponse { + data: DataType // request body data + timedout?: boolean // if request get timedout + status: number // request status code + raw?: Response // the raw response + type?: string | null // response type (for instance 'application/json') +} + +export interface apiConfig { + options: RequestInit // Request Options + baseURL?: string // baseURL (https://api.mysite.co) + path?: string // path (api) -> combined with baseUrl the url is https://api.mysite.co/api/... + timeout?: number // when the request should timeout +} + +export default class API { + + public config: apiConfig; + + constructor(config: apiConfig = {options: {}}) { + this.config = config; + } + + + //========================================================================================================= + // Get + //========================================================================================================= + /** + * Get request + */ + public get(endpoint: string, options?: RequestInit) { + return this.send('GET', endpoint, options); + } + + + //========================================================================================================= + // Post + //========================================================================================================= + /** + * Post request + */ + public post(endpoint: string, payload?: any, options?: RequestInit) { + return this.send('POST', endpoint, payload, options); + } + + + //========================================================================================================= + // Put + //========================================================================================================= + /** + * Put request + */ + public put(endpoint: string, payload?: any, options?: RequestInit) { + return this.send('PUT', endpoint, payload, options); + } + + + //========================================================================================================= + // Patch + //========================================================================================================= + /** + * Patch request + */ + public patch(endpoint: string, payload?: any, options?: RequestInit) { + return this.send('PATCH', endpoint, payload, options); + } + + //========================================================================================================= + // Delete + //========================================================================================================= + /** + * Delete request + */ + public delete(endpoint: string, payload?: any, options?: RequestInit) { + return this.send('DELETE', endpoint, payload, options); + } + + + //========================================================================================================= + // Send + //========================================================================================================= + /** + * @internal + * Will handle the request + */ + private async send(method: string, endpoint: string, payload?: any, options?: RequestInit): Promise { + let fullUrl: string; + let response: Response | undefined; + let timedout = false; + const config: apiConfig = copy(this.config); // Copying config because it will adapted for every specific request + + // Merge options together + if (options) + config.options = {...config.options, ...options}; + + // Inject method into request options + config.options.method = method; + + // If no header set it to an empty object (because in some conditions we have to add some stuff to this object) + // Haven't found a way by doing it with 'Headers'(https://stackoverflow.com/questions/48798236/const-initialization-error-with-requestinit-in-typescript) + if (!config.options.headers) + config.options.headers = {}; + + // Set Body + if (typeof payload === 'object') { + // Set body to stringyfied object payload + config.options.body = JSON.stringify(payload); + + // Set content type of Header to json + // @ts-ignore + config.options.headers['content-type'] = 'application/json'; + } else { + // Set body to payload + config.options.body = payload; + } + + // Construct endpoint (fullUrl) + let path = this.config.path ? ('/' + this.config.path) : ''; + if (endpoint.startsWith('http')) + fullUrl = endpoint; + else + fullUrl = `${this.config.baseURL ? this.config.baseURL : ''}${path}/${endpoint}`; + + // Warning if fullUrl might not be valid + if (!isValidUrl(fullUrl)) + console.warn("No valid url ", fullUrl); + + // Send Request with timeout + if (this.config.timeout) { + let t: any; + + // Create timeout Promise + const timeout = new Promise(resolve => { + t = setTimeout(() => { + timedout = true; + resolve(undefined); + }, this.config.timeout); + }); + + // Create request Promise + const request = new Promise((resolve, reject) => { + fetch(fullUrl, this.config.options) + .then(data => { + // Clear Timeout + clearTimeout(t); + + // Resolve Response(data) + resolve(data); + }) + .catch(reject); + }); + // @ts-ignore (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/race) + response = await Promise.race([timeout, request]); + } else { + // Send Request without timeout + response = await fetch(fullUrl, this.config.options); + } + + // Create FinalResponse + let finalResponse: AgileResponse = { + status: timedout ? 408 : (response?.status || 404), + raw: response, + data: {}, + type: response?.headers?.get('content-type'), + timedout: timedout + }; + + // Extract response data + if (finalResponse.type?.includes('application/json')) + finalResponse.data = await finalResponse.raw?.json(); + else if (typeof finalResponse.raw?.text === 'function') + finalResponse.data = await finalResponse.raw.text(); + + return finalResponse; + } +} diff --git a/packages/agile-api/tsconfig.json b/packages/agile-api/tsconfig.json new file mode 100644 index 00000000..e6529093 --- /dev/null +++ b/packages/agile-api/tsconfig.json @@ -0,0 +1,8 @@ +{ + "extends": "../tsconfig.default.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "dist" + }, + "include": ["./src/**/*"] // Only include what is in src (dist, tests, .. will be excluded) + } \ No newline at end of file diff --git a/packages/agile-core/package.json b/packages/agile-core/package.json new file mode 100644 index 00000000..3a4ab6da --- /dev/null +++ b/packages/agile-core/package.json @@ -0,0 +1,20 @@ +{ + "name": "@agile-ts/core", + "version": "0.0.1", + "author": "BennoDev", + "license": "ISC", + "description": "Global state and logic framework for reactive JavaScript & TypeScript applications.", + "keywords": [], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "build": "tsc" + }, + "publishConfig": { + "access": "public" + }, + "repository": { + "type": "git", + "url": "https://github.com/agile-ts/agile.git" + } + } \ No newline at end of file diff --git a/packages/agile-core/src/agile.ts b/packages/agile-core/src/agile.ts new file mode 100644 index 00000000..489016a8 --- /dev/null +++ b/packages/agile-core/src/agile.ts @@ -0,0 +1,155 @@ +import Runtime from "./runtime"; +import use, {Integration} from "./use"; +import SubController from "./sub"; +import {State} from './internal'; +import Storage, {StorageConfigInterface} from "./storage"; +import Collection, {CollectionConfig, DefaultDataIt../packages/agile-core/src/collectioncollection"; +import Computed from "./computed"; +import API, {apiConfig} from "../../agile-api/src"; +import Event, {EventConfig, DefaultEventPayload} from "./event"; + +export interface AgileConfigInterface { + framework?: Integration | any // Integration = for custom frameworks | any = for existing frameworks like react + logJobs?: boolean // If Agile should log some stuff in the console + waitForMount?: boolean // If Agile should wait until the component mounted (note working yet) + storageConfig?: StorageConfigInterface // For custom storage (default: Local Storage) +} + +export class Agile { + + public runtime: Runtime; + public integration: Integration | null = null; + public subController: SubController; + public storage: Storage; + + constructor(public config: AgileConfigInterface = {}) { + this.subController = new SubController(this); + this.runtime = new Runtime(this); + this.storage = new Storage(this, config.storageConfig || {}); + + // Init Framework + if (config.framework) + this.initFrameworkIntegration(config.framework); + else + console.warn("Agile: Don't forget to init a framework before using Agile") + + // Creates a global agile instance.. + this.globalBind(); + } + + + //========================================================================================================= + // Init Framework + //========================================================================================================= + /** + * Init a Framework like React or a custom one + */ + public initFrameworkIntegration(frameworkConstructor: any) { + use(frameworkConstructor, this); + } + + + //========================================================================================================= + // API + //========================================================================================================= + /** + * Create Agile API + * @param config Object + * @param config.options Object - Typescript default: RequestInit (headers, credentials, mode, etc...) + * @param config.baseURL String - Url to prepend to endpoints (without trailing slash) + * @param config.timeout Number - Time to wait for request before throwing error + */ + public API = (config: apiConfig) => new API(config); + + + //========================================================================================================= + // Storage + //========================================================================================================= + /** + * Create Agile Storage + */ + public Storage = (config: StorageConfigInterface) => new Storage(this, config); + + + //========================================================================================================= + // State + //========================================================================================================= + /** + * Create Agile State + * @param initialState Any - the value to initialize a State instance with + * @key State key/name which identifies the state + */ + public State = (initialState: ValueType, key?: string) => new State(this, initialState, key); + + + //========================================================================================================= + // Collection + //========================================================================================================= + /** + * Create Agile Collection + */ + public Collection = (config?: CollectionConfig) => new Collection(this, config); + + + //========================================================================================================= + // Computed + //========================================================================================================= + /** + * Create a Agile computed function + * @param deps Array - An array of state items to depend on + * @param computeFunction Function - A function where the return value is the state, ran every time a dep changes + */ + public Computed = (computeFunction: () => ComputedValueType, deps?: Array) => new Computed(this, computeFunction, deps); + + + //========================================================================================================= + // Event + //========================================================================================================= + /** + * Create a Pulse Event + */ + public Event = (config?: EventConfig) => new Event(this, config); + + + //========================================================================================================= + // Set Storage + //========================================================================================================= + /** + * Configures the Agile Storage + * @param storageConfig + */ + public setStorage(storageConfig: StorageConfigInterface): void { + // Get States which are already saved into a storage + const persistedStates = this.storage.persistedStates; + + // Define new Storage + this.storage = new Storage(this, storageConfig); + this.storage.persistedStates = persistedStates; + + // Save all already saved states into the new Storage + this.storage.persistedStates.forEach(state => state.persist(state.key)); + + // Save all already saved collections into the new Storage + this.storage.persistedCollections.forEach(collection => collection.persist(collection.key)); + } + + + //========================================================================================================= + // Global Bind + //========================================================================================================= + /** + * @internal + * Creates a global reference to the first pulse instance created this runtime + */ + private globalBind() { + try { + // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/globalThis + // @ts-ignore + if (!globalThis.__agile) globalThis.__agile = this; + } catch (error) { + // fail silently + } + } +} + + diff --git a/packages/agile-core/src/collection/group.ts b/packages/agile-core/src/collection/group.ts new file mode 100644 index 00000000..aa5fa2fe --- /dev/null +++ b/packages/agile-core/src/collection/group.ts @@ -0,0 +1,228 @@ +import { + Collection, + DefaultDataItem, + ItemKey, + State, + Agile, + defineConfig, + normalizeArray +} from '../internal'; +import {updateGroup} from "./perstist"; + +export type GroupKey = string | number; + +export interface GroupAddOptionsInterface { + method?: 'unshift' | 'push' // Method for adding item to group + overwrite?: boolean // Set to false to leave primary key in place if it already exists + background?: boolean // If the action should happen in the background -> no rerender +} + +export interface GroupConfigInterface { + key?: GroupKey // should be a unique key/name which identifies the group +} + +export class Group extends State> { + collection: () => Collection; + + _output: Array = []; // Output of the group (Note: _value are only the keys of the collection items) + _states: Array<() => State> = []; // States of the Group + notFoundPrimaryKeys: Array = []; // Contains all key which can't be found in the collection + + constructor(agileInstance: Agile, collection: Collection, initialItems?: Array, config?: GroupConfigInterface) { + super(agileInstance, initialItems || [], config?.key); + this.collection = () => collection; + + // Set build() to state sideEffect + this.sideEffects = () => this.build(); + + // Set type of State to array because a group is an array of collection item keys + this.type(Array); + + // Initial Build + this.build(); + } + + public get output(): Array { + // Add state(group) to foundState (for auto tracking used states in computed functions) + if (this.agileInstance().runtime.trackState) + this.agileInstance().runtime.foundStates.add(this); + + return this._output; + } + + public get states(): Array> { + // Add state(group) to foundState (for auto tracking used states in computed functions) + if (this.agileInstance().runtime.trackState) + this.agileInstance().runtime.foundStates.add(this); + + return this._states.map(state => state()); + } + + //========================================================================================================= + // Has + //========================================================================================================= + /** + * Checks if the group contains the primaryKey + */ + public has(primaryKey: ItemKey) { + return this.value.findIndex(key => key === primaryKey) !== -1; + } + + + //========================================================================================================= + // Size + //========================================================================================================= + /** + * Returns the size of the group + */ + public get size(): number { + return this.value.length; + } + + + //========================================================================================================= + // Remove + //========================================================================================================= + /** + * Removes a item at primaryKey from the group + */ + public remove(itemKeys: ItemKey | ItemKey[], options: { background?: boolean } = {}): this { + const _itemKeys = normalizeArray(itemKeys); + const notExistingCollectionItems: Array = []; + + // Merge default values into options + options = defineConfig(options, { + background: false + }); + + _itemKeys.forEach(itemKey => { + // If item doesn't exist in collection add it to notExistingItems + if (!this.collection().findById(itemKey)) + notExistingCollectionItems.push(itemKey); + + // Check if primaryKey exists in group if not, return + if (this.value.findIndex(key => key === itemKey) === -1) { + console.error(`Agile: Couldn't find primaryKey '${itemKey}' in group`, this); + return; + } + + // Remove primaryKey from nextState + this.nextState = this.nextState.filter((i) => i !== itemKey); + + // Storage + if (this.key) + updateGroup(this.key, this.collection()); + }); + + // If all items don't exist in collection.. set background to true because the output won't change -> no rerender necessary + if (notExistingCollectionItems.length >= _itemKeys.length) + options.background = true; + + // Set State to nextState + this.ingest(options); + + return this; + } + + + //========================================================================================================= + // Add + //========================================================================================================= + /** + * Adds a key to a group + */ + public add(itemKeys: ItemKey | ItemKey[], options: GroupAddOptionsInterface = {}): this { + const _itemKeys = normalizeArray(itemKeys); + const notExistingCollectionItems: Array = []; + let newNextState = [...this.nextState]; // Had to create copy array otherwise also 'this.value' would change.. by changing 'this.nextState' directly. + + // Merge default values into options + options = defineConfig(options, { + method: 'push', + overwrite: false, + background: false + }); + + _itemKeys.forEach(itemKey => { + // Check if item already exists in group + const existsInGroup = newNextState.findIndex(key => key === itemKey) !== -1; + + // If item doesn't exist in collection add it to notExistingItems + if (!this.collection().findById(itemKey)) + notExistingCollectionItems.push(itemKey); + + // Removes temporary key from group to overwrite it properly + if (options.overwrite) + newNextState = newNextState.filter((i) => i !== itemKey); + // If we do not want to overwrite and key already exists in group, exit + else if (existsInGroup) + return; + + // Push or unshift into state + newNextState[options.method || 'push'](itemKey); + + // Storage + if (this.key) updateGroup(this.key, this.collection()); + }); + + // If all items don't exist in collection.. set background to true because the output won't change -> no rerender necessary + if (notExistingCollectionItems.length >= _itemKeys.length) + options.background = true; + + // Set nextState to newNextState + this.nextState = newNextState; + + // Set State to nextState + this.ingest({background: options.background}); + + return this; + } + + + //========================================================================================================= + // Build + //========================================================================================================= + /** + * @internal + * Will build the group -> it will set the output to the collection values + */ + public build() { + this.notFoundPrimaryKeys = []; + + // Check if _value is an array if not something went wrong because a group is always an array + if (!Array.isArray(this._value)) { + console.error("Agile: A group state has to be an array!"); + return; + } + + // Map though group _value (collectionKey array) and get their state from collection + const finalStates = this._value + .map((primaryKey) => { + // Get collection data at the primaryKey position + let data = this.collection().data[primaryKey]; + + // If no data found add this key to missing PrimaryKeys + if (!data) { + this.notFoundPrimaryKeys.push(primaryKey); + return; + } + + return data as State; + }).filter(item => item !== undefined); + + // Map though found States and return their publicValue + const finalOutput = finalStates + .map((state) => { + // @ts-ignore + return state.getPublicValue(); + }); + + // Log not found primaryKeys + if (this.notFoundPrimaryKeys.length > 0 && this.agileInstance().config.logJobs) + console.warn(`Agile: Couldn't find states with the primary keys in group '${this.key}'`, this.notFoundPrimaryKeys); + + // @ts-ignore + this._states = finalStates.map(state => (() => state)); + this._output = finalOutput; + } +} diff --git a/packages/agile-core/src/collection/index.ts b/packages/agile-core/src/collection/index.ts new file mode 100644 index 00000000..2568bc46 --- /dev/null +++ b/packages/agile-core/src/collection/index.ts @@ -0,0 +1,641 @@ +import { + Agile, + Item, + Group, + GroupKey, + Selector, + SelectorKey, + State, + StateKey, + StorageKey, + copy, + defineConfig, + flatMerge, + isValidObject, + normalizeArray +} from "../internal"; +import {persistValue, removeItem, setItem} from './perstist'; + +export type DefaultDataItem = { [key: string]: any }; +export type CollectionKey = string | number; +export type ItemKey = string | number; // The key of an item in a collection + +export interface CollectionConfigInterface { + groups?: { [key: string]: Group } | string[] + selectors?: { [key: string]: Selector } | string[] + key?: CollectionKey // should be a unique key/name which identifies the collection + primaryKey?: string // the primaryKey of an item (default is id) + defaultGroupKey?: ItemKey // The defaultGroupKey(Name).. in which all collected items get stored +} + +export interface CollectOptionsInterface { + patch?: boolean // If the item should be patched into existing item (only useful if Item already exists) + method?: 'push' | 'unshift' // Method for adding item to group + forEachItem?: (item: DataType, key: ItemKey, index: number) => void // To do something with collected items + background?: boolean // If the action should happen in the background -> no rerender +} + +export type CollectionConfig = + | CollectionConfigInterface + | ((collection: Collection) => CollectionConfigInterface); + +export class Collection { + public agileInstance: () => Agile; + + public config: CollectionConfigInterface; + + public size: number = 0; // The amount of data items stored inside this collection + public data: { [key: string]: Item } = {}; // Collection data is stored here + public _key?: CollectionKey; + public isPersistCollection: boolean = false; // Is saved in storage + + public groups: { [key: string]: Group } = {}; + public selectors: { [key: string]: Selector } = {}; + + constructor(agileInstance: Agile, config: CollectionConfig = {}) { + this.agileInstance = () => agileInstance; + + // If collection config is a function, execute and assign to config + if (typeof config === 'function') + config = config(this); + + // Assign defaults to config + this.config = defineConfig(config, { + primaryKey: 'id', + groups: {}, + selectors: {}, + defaultGroupKey: 'default' + }); + + // Set Key + this._key = this.config.key; + + // Init Groups + this.initSubInstances('groups'); + + // Init Selectors + this.initSubInstances('selectors'); + } + + public set key(value: StateKey | undefined) { + this._key = value; + } + + public get key(): StateKey | undefined { + return this._key; + } + + + //========================================================================================================= + // Init SubInstances + //========================================================================================================= + /** + * @internal + * Init SubInstances like groups or selectors + */ + private initSubInstances(type: 'groups' | 'selectors') { + const subInstance = copy(this.config[type]) || {}; + let subInstanceObject: any = {}; + + // If subInstance is array transform it to an object with the fitting class + if (Array.isArray(subInstance)) { + for (let i = 0; i < subInstance.length; i++) { + let instance; + switch (type) { + case "groups": + instance = new Group(this.agileInstance(), this, [], {key: subInstance[i]}); + break; + case "selectors": + instance = new Selector(this, subInstance[i], {key: subInstance[i]}); + break; + default: + instance = 'unknown'; + } + subInstanceObject[subInstance[i]] = instance; + } + } else { + // If subInstance is Object.. set subInstanceObject to subInstance + subInstanceObject = subInstance; + } + + // If groups.. add default group + if (type === "groups") { + if (!subInstanceObject[this.config.defaultGroupKey || 'default']) + subInstanceObject[this.config.defaultGroupKey || 'default'] = new Group(this.agileInstance(), this, [], {key: this.config.defaultGroupKey || 'default'}); + } + + const keys = Object.keys(subInstanceObject); + for (let key of keys) { + // Set key to property name if it isn't set yet + if (!subInstanceObject[key].key) + subInstanceObject[key].key = key; + } + + // Set Collection instance + this[type] = subInstanceObject; + } + + + //========================================================================================================= + // Collect + //========================================================================================================= + /** + * Collect iterable data into this collection. + * Note: Data items must include a primary key (id) + */ + public collect(items: DataType | Array, groups?: GroupKey | Array, options: CollectOptionsInterface = {}) { + const _items = normalizeArray(items); + const _groups = normalizeArray(groups); + const defaultGroupKey = this.config.defaultGroupKey || 'default'; + const groupsToRebuild: Set = new Set(); + + // Assign defaults to options + options = defineConfig(options, { + method: 'push', + background: false, + patch: false + }); + + // Add default group if it hasn't been added (default group contains all items) + if (_groups.findIndex(groupName => groupName === defaultGroupKey) === -1) + _groups.push(defaultGroupKey); + + // Create not existing Groups + _groups.forEach(groupName => !this.groups[groupName] && this.createGroup(groupName)); + + _items.forEach((item, index) => { + // Check if the item already exists in the Collection + const itemExists = !!this.data[(item as any)[this.config.primaryKey || 'id']]; + + // Save items into Collection + let key = this.saveData(item, {patch: options.patch, background: options.background}); + + // Return if key doesn't exist (something went wrong in saveData, Note: Error will be logged in saveData) + if (!key) return; + + // Call forEachItem method + if (options.forEachItem) + options.forEachItem(item, key, index); + + // If item didn't exist.. check if the itemKey has already been added to a group before -> group need rebuild to has correct output + if (!itemExists) { + const groupKeys = Object.keys(this.groups); + groupKeys.forEach(groupName => { + // Get Group + const group = this.getGroup(groupName); + + // Check if itemKey exists in Group if so push it to groupsToRebuild + if (group.value.findIndex(primaryKey => primaryKey === (item as any)[this.config.primaryKey || 'id']) !== -1) + groupsToRebuild.add(group); + }); + } + + // Add key to groups + _groups.forEach(groupName => { + // @ts-ignore + this.groups[groupName].add(key, {method: options.method, background: options.background}) + }); + }); + + // Rebuild groups + groupsToRebuild.forEach(group => { + // Rebuild Group + group.build(); + + // Force Rerender to get the correct output in components + if (!options.background) group.ingest({forceRerender: true}) + }) + } + + + //========================================================================================================= + // Update + //========================================================================================================= + /** + * * Update data by updateKey(id) in a Agile Collection + */ + public update(updateKey: ItemKey, changes: DefaultDataItem | DataType, options: { addNewProperties?: boolean, background?: boolean } = {}): State | undefined { + // If item does not exist, return + if (!this.data.hasOwnProperty(updateKey)) { + console.error(`Agile: PrimaryKey '${updateKey} doesn't exist in collection `, this); + return undefined; + } + + // Assign defaults to config + options = defineConfig(options, { + addNewProperties: false, + background: false + }); + + const itemState = this.data[updateKey]; + const currentItemValue = copy(itemState.value) as any; + const primaryKey = this.config.primaryKey || ''; + + // Merge current Item value with changes + const finalItemValue = flatMerge(currentItemValue, changes, {addNewProperties: options.addNewProperties}); + + // Check if something has changed (stringifying because of possible object or array) + if (JSON.stringify(finalItemValue) === JSON.stringify(itemState.nextState)) + return this.data[finalItemValue[primaryKey]]; + + // Assign finalItemStateValue to nextState + itemState.nextState = finalItemValue; + + // Set State to nextState + itemState.ingest({background: options.background}); + + // If data key changes update it properly + if (currentItemValue[primaryKey] !== finalItemValue[primaryKey]) + this.updateItemPrimaryKeys(currentItemValue[primaryKey], finalItemValue[primaryKey], {background: options.background}); + + // Rebuild all groups that includes the primaryKey + this.rebuildGroupsThatIncludePrimaryKey(finalItemValue[primaryKey], {background: options.background}); + + // Return data at primaryKey (updated State) + return this.data[finalItemValue[primaryKey]]; + } + + + //========================================================================================================= + // Create Group + //========================================================================================================= + /** + * Create a group instance on this collection + */ + public createGroup(groupName: GroupKey, initialItems?: Array): Group { + // Check if Group already exist + if (this.groups.hasOwnProperty(groupName)) { + console.warn(`Agile: The Group with the name ${groupName} already exists!`); + return this.groups[groupName]; + } + + // Create new Group + const group = new Group(this.agileInstance(), this, initialItems, {key: groupName}); + + // Add new Group to groups + this.groups[groupName] = group; + + // Log Job + if (this.agileInstance().config.logJobs) + console.log(`Agile: Created Group called '${groupName}'`, group); + + return group; + } + + + //========================================================================================================= + // Create Selector + //========================================================================================================= + /** + * Create a selector instance on this collection + */ + public createSelector(selectorName: SelectorKey, id: ItemKey): Selector { + // Check if Selector already exist + if (this.selectors.hasOwnProperty(selectorName)) { + console.warn(`Agile: The Selector with the name ${selectorName} already exists!`); + return this.selectors[selectorName]; + } + + // Create new Selector + const selector = new Selector(this, id, {key: selectorName}); + + // Add new Selector to selectors + this.selectors[selectorName] = selector; + + // Log Job + if (this.agileInstance().config.logJobs) + console.log(`Agile: Created Selector called '${selectorName}'`, selector); + + return selector; + } + + + //========================================================================================================= + // Get Group + //========================================================================================================= + /** + * Return an group from this collection as Group instance (extends State) + */ + public getGroup(groupName: GroupKey): Group { + // Check if group exists + if (this.groups[groupName]) + return this.groups[groupName]; + + console.warn(`Agile: Group with name '${groupName}' doesn't exist!`); + + // Return empty group because it might get annoying to handle with undefined (can check if it exists with group.exists) + const group = new Group(this.agileInstance(), this, [], {key: 'dummy'}); + group.isPlaceholder = true; + return group; + } + + + //========================================================================================================= + // Get Selector + //========================================================================================================= + /** + * Return an selector from this collection as Selector instance (extends State) + */ + public getSelector(selectorName: SelectorKey): Selector | undefined { + // Check if selector exists + if (this.selectors[selectorName]) + return this.selectors[selectorName]; + + console.warn(`Agile: Selector with name '${selectorName}' doesn't exist!`); + + return undefined; + } + + + //========================================================================================================= + // Remove + //========================================================================================================= + /** + * Remove fromGroups or everywhere + */ + public remove(primaryKeys: ItemKey | Array) { + return { + fromGroups: (groups: Array | ItemKey) => this.removeFromGroups(primaryKeys, groups), + everywhere: () => this.removeData(primaryKeys) + }; + } + + + //========================================================================================================= + // Find By Id + //========================================================================================================= + /** + * Return an item from this collection by primaryKey as Item instance (extends State) + */ + public findById(id: ItemKey): Item | undefined { + if (!this.data.hasOwnProperty(id) || !this.data[id].exists) + return undefined; + + // Add state to foundState (for auto tracking used states in computed functions) + if (this.agileInstance().runtime.trackState) + this.agileInstance().runtime.foundStates.add(this.data[id]); + + // Return data by id + return this.data[id]; + } + + + //========================================================================================================= + // Get Value By Id + //========================================================================================================= + /** + * Return a value from this collection by primaryKey + */ + public getValueById(id: ItemKey): DataType | undefined { + let data = this.findById(id); + if (!data) return undefined; + + return data.value; + } + + + //========================================================================================================= + // Persist + //========================================================================================================= + /** + * Saves the collection in the local storage or in a own configured storage + * @param key - the storage key (if no key passed it will take the collection key) + */ + public persist(key?: StorageKey): this { + persistValue(this, key).then((value) => { + this.isPersistCollection = value + }); + return this; + } + + + //========================================================================================================= + // Group + //========================================================================================================= + /** + * Create a group instance under this collection (can be used in function based config) + */ + public Group(initialItems?: Array, config?: GroupConfigInterface): Group { + return new Group(this.agileInstance(), this, initialItems, config); + } + + + //========================================================================================================= + // Selector + //========================================================================================================= + /** + * Create a selector instance under this collection (can be used in function based config) + */ + public Selector(initialSelection: ItemKey, options?: { key?: SelectorKey }): Selector { + return new Selector(this, initialSelection, options); + } + + + //========================================================================================================= + // Update Data Key + //========================================================================================================= + /** + * @internal + * This will properly change the key of a collection item + */ + private updateItemPrimaryKeys(oldKey: ItemKey, newKey: ItemKey, options?: { background?: boolean }): void { + // If oldKey and newKey are the same, return + if (oldKey === newKey) return; + + // Assign defaults to config + options = defineConfig(options, { + background: false + }); + + // Create copy of data + const dataCopy = this.data[oldKey]; + + // Delete old reference + delete this.data[oldKey]; + + // Apply the data into data with new key + this.data[newKey] = dataCopy; + + // Update Groups + for (let groupName in this.groups) { + // Get Group + const group = this.getGroup(groupName); + + // If Group does not contain oldKey, continue + if (group.value.findIndex(key => key === oldKey) === -1) continue; + + // Replace the primaryKey at current index + group.nextState.splice(group.nextState.indexOf(oldKey), 1, newKey); + + // Set State(Group) to nextState + group.ingest({background: options?.background}); + } + + // Update Selector + for (let selectorName in this.selectors) { + // Get Selector + const selector = this.getSelector(selectorName); + if (!selector) continue; + + // If Selector doesn't watch on the oldKey, continue + if (selector.id !== oldKey) continue; + + // Replace the oldKey with the newKey + selector.select(newKey, {background: options?.background}); + } + } + + + //========================================================================================================= + // Remove From Groups + //========================================================================================================= + /** + * @internal + * Deletes Data from Groups + */ + public removeFromGroups(primaryKeys: ItemKey | Array, groups: GroupKey | Array) { + const _primaryKeys = normalizeArray(primaryKeys); + const _groups = normalizeArray(groups); + + _groups.forEach(groupKey => { + // Return if group doesn't exist in collection + if (!this.groups[groupKey]) { + console.error(`Agile: Couldn't find group('${groupKey}) in collection`, this); + return; + } + + // Remove primaryKeys from Group + _primaryKeys.forEach(primaryKey => { + const group = this.getGroup(groupKey); + group.remove(primaryKey); + }); + }); + } + + + //========================================================================================================= + // Delete Data + //========================================================================================================= + /** + * @internal + * Deletes data directly form the collection + */ + public removeData(primaryKeys: ItemKey | Array) { + const _primaryKeys = normalizeArray(primaryKeys); + const groupKeys = Object.keys(this.groups); + const selectorKeys = Object.keys(this.selectors); + const itemKeys = Object.keys(this.data); + + _primaryKeys.forEach(itemKey => { + // Check if primaryKey exists in collection, if not return + if (itemKeys.findIndex(key => itemKey.toString() === key) === -1) { + console.error(`Agile: Couldn't find primaryKey '${itemKey}' in collection`, this); + return; + } + + // Remove primaryKey from Groups (have to be above deleting the data because.. the remove function needs to know if the data exists or not) + groupKeys.forEach(groupKey => { + this.groups[groupKey].remove(itemKey); + }); + + // Remove Selectors with primaryKey + selectorKeys.forEach(selectorKey => { + delete this.selectors[selectorKey]; + }); + + // Remove primaryKey from collection data + delete this.data[itemKey]; + + // Decrease size + this.size--; + + // Storage + removeItem(itemKey, this); + }); + } + + + //========================================================================================================= + // Save Data + //========================================================================================================= + /** + * @internal + * Save data directly into the collection + */ + public saveData(data: DataType, options: { patch?: boolean, background?: boolean } = {}): ItemKey | null { + // Transform data to any because otherwise I have many type errors (because not defined object) + // https://stackoverflow.com/questions/57350092/string-cant-be-used-to-index-type + const _data = data as any; + + // Assign defaults to options + options = defineConfig(options, { + patch: false, + background: false, + }); + + // Get primaryKey (default: 'id') + const primaryKey = this.config.primaryKey || 'id'; + const itemKey = _data[primaryKey]; + + // Check if data is object if not return + if (!isValidObject(_data)) { + console.error("Agile: Collections items has to be an object for now!"); + return null; + } + + // Check if data has primaryKey + if (!_data.hasOwnProperty(primaryKey)) { + console.error("Agile: Collections items need a own primaryKey. Here " + this.config.primaryKey); + return null; + } + + // Create reference of data at the data key + let item: Item = this.data[itemKey]; + + // If the data already exists and config is to patch, patch data + if (item && options.patch) + item.patch(_data, {background: options.background}); + // If the data already exists and no config, overwrite data + else if (item) + item.set(_data, {background: options.background}); + // If data does not exist.. create new Item set and increase the size + else { + item = new Item(this, _data); + this.size++; + } + + // Set item at data itemKey + this.data[itemKey] = item; + + // Storage + setItem(itemKey, this); + + return itemKey; + } + + + //========================================================================================================= + // Rebuild Groups That Includes Primary Key + //========================================================================================================= + /** + * @internal + * Rebuild the Groups which contains the primaryKey + */ + public rebuildGroupsThatIncludePrimaryKey(primaryKey: ItemKey, options?: { background?: boolean, forceRerender?: boolean }): void { + // Assign defaults to config + options = defineConfig(options, { + background: false, + forceRerender: !options?.background // forceRerender false.. because forceRerender has more weight than background in runtime + }); + + // Rebuild groups that includes primaryKey + for (let groupKey in this.groups) { + // Get Group + const group = this.getGroup(groupKey); + + // Check if group contains primaryKey if so rebuild it + if (group.has(primaryKey)) + group.ingest({background: options?.background, forceRerender: options?.forceRerender}); + } + } +} diff --git a/packages/agile-core/src/collection/item.ts b/packages/agile-core/src/collection/item.ts new file mode 100644 index 00000000..a2a862bf --- /dev/null +++ b/packages/agile-core/src/collection/item.ts @@ -0,0 +1,24 @@ +import State from '../state'; +import Collection, {DefaultDataItem} from './index'; + +export class Item extends State { + + private collection: () => Collection; + + // @ts-ignore + public output: DataType; // Defines the type of the output (will be set external) + + constructor(collection: Collection, data: DataType) { + super(collection.agileInstance(), data); + this.collection = () => collection; + + // Setting key of item to the data primaryKey + this.key = data && (data as any)[collection.config?.primaryKey || 'id']; + + // Add rebuildGroupsThatIncludePrimaryKey to sideEffects to rebuild the groups which includes the primaryKey if the state changes + this.sideEffects = () => collection.rebuildGroupsThatIncludePrimaryKey(this.key || ''); + + // Set type of State to object because a collection item is always an object + this.type(Object); + } +} diff --git a/packages/agile-core/src/collection/perstist.ts b/packages/agile-core/src/collection/perstist.ts new file mode 100644 index 00000000..20295918 --- /dev/null +++ b/packages/agile-core/src/collection/perstist.ts @@ -0,0 +1,243 @@ +import Collection, {ItemKey} from "./index"; +import Storage, {StorageKey} from "../storage"; +import {GroupKey} from "./group"; + +interface CollectionStorageData { + data: ItemKey[], + groups: GroupKey[] +} + +const storageItemKeyTemplate = '_${collectionKey}_item_${itemKey}'; +const storageGroupKeyTemplate = '_${collectionKey}_group_${groupKey}'; + +//========================================================================================================= +// Persist Value +//========================================================================================================= +/** + * Will persist the 'collection' into the configured storage with the key or if no key passed the state key + */ +export async function persistValue(collection: Collection, key?: StorageKey): Promise { + // Validate Key + const tempKey = validateKey(collection, key); + if (!tempKey) { + console.error("Agile: If your State has no key provided before using persist.. you have to provide a key here!"); + return false; + } + key = tempKey; + + // Get Storage + const storage = collection.agileInstance().storage; + + // Add Collection to persistedCollections in Storage + storage.persistedCollections.add(collection); + + // Call Handle which decides weather it has to add the storage value to the state or save the state into the storage + await handleStorageValue(storage, collection); + + return true; +} + + +//========================================================================================================= +// Set/Update Item +//========================================================================================================= +/** + * Set/Update Item in Storage + */ +export async function setItem(itemKey: ItemKey, collection: Collection) { + const storage = collection.agileInstance().storage; + + if (collection.isPersistCollection && collection.key) { + // Create Item Storage Key + const itemStorageKey = storageItemKeyTemplate + .replace('${collectionKey}', (collection.key || 'unknown').toString()) + .replace('${itemKey}', itemKey.toString()); + + // Get Value + const item = collection.data[itemKey]; + if (!item) return; + + // Log Job + if (collection.agileInstance().config.logJobs) + console.log(`Agile Storage(Set Item): ${itemStorageKey}`, item.getPersistableValue()); + + // Set StorageValue + await storage.set(itemStorageKey, item.getPersistableValue()); + } +} + + +//========================================================================================================= +// Remove Item +//========================================================================================================= +/** + * Removes Item from Storage + */ +export function removeItem(itemKey: ItemKey, collection: Collection) { + const storage = collection.agileInstance().storage; + + if (collection.isPersistCollection && collection.key) { + // Create Item Storage Key + const itemStorageKey = storageItemKeyTemplate + .replace('${collectionKey}', (collection.key || 'unknown').toString()) + .replace('${itemKey}', itemKey.toString()); + + // Log Job + if (collection.agileInstance().config.logJobs) + console.log(`Agile Storage(Remove Item): ${itemStorageKey}`); + + // Remove StorageValue + storage.remove(itemStorageKey); + } +} + + +//========================================================================================================= +// Update Group +//========================================================================================================= +/** + * Updates the Group in the storage + */ +export function updateGroup(groupKey: GroupKey, collection: Collection) { + const storage = collection.agileInstance().storage; + + if (collection.isPersistCollection && collection.key) { + // Create Group Storage Key + const groupStorageKey = storageGroupKeyTemplate + .replace('${collectionKey}', (collection.key || 'unknown').toString()) + .replace('${groupKey}', groupKey.toString()); + + // Get group + const group = collection.groups[groupKey]; + if (!group) return; + + // Log Job + if (collection.agileInstance().config.logJobs) + console.log(`Agile Storage(Update Group): ${groupStorageKey}`, group.value); + + // Set StorageValue + storage.set(groupStorageKey, group.value); + } +} + + +//========================================================================================================= +// Helper +//========================================================================================================= + +function validateKey(collection: Collection, key?: StorageKey): StorageKey | null { + // Get key from State key + if (!key && collection.key) + return collection.key; + + // Return null if no key can be found + if (!key) + return null; + + // Set this storage key as state key + collection.key = key; + return key; +} + +async function handleStorageValue(storage: Storage, collection: Collection) { + // Get Collection Data + const collectionData = await loadCollectionData(collection); + + // Log Job + if (collection.agileInstance().config.logJobs) + console.log("Agile Storage(CollectionData):", collectionData); + + // Load Collection Items + await loadCollectionItems(collectionData, collection); + + // Load Collection Groups + await loadCollectionGroups(collectionData, collection); +} + +async function loadCollectionData(collection: Collection): Promise { + const storage = collection.agileInstance().storage; + + const key = collection.key as StorageKey; + const storageValue = await storage.get(key); + + // If the collectionData doesn't exist in the storage yet.. create it + if (!storageValue) { + const collectionStorageData: CollectionStorageData = { + data: Object.keys(collection.data), + groups: Object.keys(collection.groups) + } + storage.set(key, collectionStorageData); + return collectionStorageData; + } + + return storageValue; +} + +async function loadCollectionItems(collectionStorageData: CollectionStorageData, collection: Collection) { + const storage = collection.agileInstance().storage; + + for (let itemKey of collectionStorageData.data) { + // Create Item Storage Key + const itemStorageKey = storageItemKeyTemplate + .replace('${collectionKey}', (collection.key || 'unknown').toString()) + .replace('${itemKey}', itemKey.toString()); + + // Get StorageValue + const storageValue = await storage.get(itemStorageKey); + + // Log Job + if (collection.agileInstance().config.logJobs) + console.log(`Agile Storage: ${itemStorageKey}`, storageValue); + + // If the value doesn't exist in the storage yet.. create it + if (!storageValue) { + storage.set(itemStorageKey, collection.data[itemKey].getPersistableValue()); + return; + } + + // If the value already exists in the storage.. load it into the collection + collection.collect(storageValue); + } +} + +async function loadCollectionGroups(collectionStorageData: CollectionStorageData, collection: Collection) { + const storage = collection.agileInstance().storage; + + for (let groupKey of collectionStorageData.groups) { + // Create Group Storage Key + const groupStorageKey = storageGroupKeyTemplate + .replace('${collectionKey}', (collection.key || 'unknown').toString()) + .replace('${groupKey}', groupKey.toString()); + + // Get StorageValue + const storageValue = await storage.get(groupStorageKey); + + // Log Job + if (collection.agileInstance().config.logJobs) + console.log(`Agile Storage: ${groupStorageKey}`, storageValue); + + // If the value doesn't exist in the storage yet.. create it + if (!storageValue) { + storage.set(groupStorageKey, collection.groups[groupKey].value); + return; + } + + // - If the value already exists in the storage.. load it into the collection + + // Get Group + const group = collection.groups[groupKey]; + + // If group doesn't exists, Create Group + if (!group) { + collection.createGroup(groupKey, storageValue); + continue; + } + + // If group exists, add items into group + for (let key of storageValue) { + if (!group.has(key)) { + group.add(key); + } + } + } +} diff --git a/packages/agile-core/src/collection/selector.ts b/packages/agile-core/src/collection/selector.ts new file mode 100644 index 00000000..0a20f3b7 --- /dev/null +++ b/packages/agile-core/src/collection/selector.ts @@ -0,0 +1,130 @@ +import Collection, {DefaultDataItem, ItemKey} from "./index"; +import Computed from "../computed"; +import Item from "./item"; +import {persistValue} from "../state/persist"; +import {StorageKey} from "../storage"; +import {copy, defineConfig} from "../utils"; + +export type SelectorKey = string | number; + +export interface SelectorConfigInterface { + key?: SelectorKey // should be a unique key/name which identifies the selector +} + +export class Selector extends Computed { + + public collection: () => Collection; + public _id: ItemKey; + + constructor(collection: Collection, id: ItemKey, config?: SelectorConfigInterface) { + // If no key provided set it to dummy (dummyKey) + if (!id) id = 'dummy'; + + // Instantiate Computed with 'computed' function + super(collection.agileInstance(), () => findData(collection, id)); + + if (config?.key) + this._key = config?.key; + + this.collection = () => collection; + this._id = id; + + // Set type of State to object because a collection item is always an object + this.type(Object); + } + + public set id(val: ItemKey) { + this.select(val); + } + + public get id() { + return this._id; + } + + + //========================================================================================================= + // Select + //========================================================================================================= + /** + * Changes the id on which the selector is watching + */ + public select(id: ItemKey, options?: { background?: boolean, sideEffects?: boolean }) { + // Assign defaults to config + options = defineConfig(options, { + background: false, + sideEffects: true + }); + + // Remove item if its a placeholder because if so it won't be needed without being selected by this selector + if (this.collection().data[this.id]?.isPlaceholder) + delete this.collection().data[this.id]; + + // Set _id to new id + this._id = id; + + // Update Computed Function with new key(id) + this.updateComputeFunction(() => findData(this.collection(), id), [], options); + + return this; + } + + + //========================================================================================================= + // Overwrite Persist + //========================================================================================================= + /** + * Saves the state in the local storage or in a own configured storage + * @param key - the storage key (if no key passed it will take the state key) + */ + public persist(key?: StorageKey): this { + persistValue(this, key); + return this; + } + + + //========================================================================================================= + // Overwrite getPerstiableValue + //========================================================================================================= + /** + * @internal + * Will return the perstiable Value of this state.. + */ + public getPersistableValue() { + return this.id; + } +} + + +//========================================================================================================= +// Find Data +//========================================================================================================= +/** + * Computed function for the Selector + */ +function findData(collection: Collection, id: ItemKey) { + // Find data by id in collection + let item = collection.findById(id); + + // If data is not found, create placeholder item, so that when real data is collected it maintains connection and causes a rerender + if (!item) { + const newItem = new Item(collection, {id: id} as any); + newItem.isPlaceholder = true; + collection.data[id] = newItem; + item = newItem; + } + + // If initial State is still {id: id}.. because of placeholder item and the value isn't {id: id} -> had got real value.. set the initial State to this first real value + if (JSON.stringify(item.initialState) === JSON.stringify({id: id}) && JSON.stringify(item.nextState) !== JSON.stringify({id: id})) { + item.initialState = copy(item.nextState); + item.previousState = copy(item.nextState); + } + + // Have to create the final Value here, to get added to the track states also if the item doesn't exist yet.. (otherwise auto tracking state wouldn't work -> this won't get called if the item changes ) + const finalValue = item.value; + + // If item doesn't exist return undefined.. otherwise it would return {id: id} + if (!item.exists) + return undefined; + + return finalValue; +} diff --git a/packages/agile-core/src/computed/index.ts b/packages/agile-core/src/computed/index.ts new file mode 100644 index 00000000..ba001c65 --- /dev/null +++ b/packages/agile-core/src/computed/index.ts @@ -0,0 +1,117 @@ +import State from "../state"; +import Agile from "../agile"; +import {defineConfig} from "../utils"; + +export class Computed extends State { + public agileInstance: () => Agile; + + public computeFunction: () => ComputedValueType; + public deps: Array = []; + public hardCodedDeps: Array = []; + + constructor(agileInstance: Agile, computeFunction: () => ComputedValueType, deps: Array = []) { + super(agileInstance, computeFunction()); + this.agileInstance = () => agileInstance; + this.computeFunction = computeFunction; + this.hardCodedDeps = deps; + + // Recompute for setting initial state value and adding missing dependencies + this.recompute(); + } + + public set value(value: ComputedValueType) { + console.error('Agile: Can not mutate Computed value, please use recompute()'); + } + + public get value(): ComputedValueType { + return super.value; + } + + + //========================================================================================================= + // Recompute + //========================================================================================================= + /** + * Will call the computeFunction and update the dependencies + */ + public recompute(options?: { background?: boolean, sideEffects?: boolean }) { + // Assign defaults to config + options = defineConfig(options, { + background: false, + sideEffects: true + }); + + // Set State to nextState + this.ingest(options); + } + + + //========================================================================================================= + // Updates Compute Function + //========================================================================================================= + /** + * Updates the Compute Function + */ + public updateComputeFunction(computeFunction: () => ComputedValueType, deps: Array = [], options?: { background?: boolean, sideEffects?: boolean }) { + this.computeFunction = computeFunction; + this.hardCodedDeps = deps; + + // Recompute for setting initial state value and adding missing dependencies + this.recompute(options); + } + + + //========================================================================================================= + // Compute Values + //========================================================================================================= + /** + * @internal + * Will add auto tracked dependencies to this and calls the computeFunction + */ + public computeValue(): ComputedValueType { + // Set tracking state to true which will than track all states which for instance call state.value + this.agileInstance().runtime.trackState = true; + + // Call computeFunction + const computedValue = this.computeFunction(); + + // Get tracked states and set trackSate to false + let foundStates = this.agileInstance().runtime.getFoundStates(); + + // Handle foundStates dependencies + const newDeps: Array = []; + foundStates.forEach(state => { + // Add the state to newDeps + newDeps.push(state); + + // Add this as dependency of the state + state.dep.depend(this); + }); + + // Handle hardCoded dependencies + this.hardCodedDeps.forEach(state => { + // Add this as dependency of the state + state.dep.depend(this); + }); + + // Set deps + this.deps = [...this.hardCodedDeps, ...newDeps]; + + return computedValue; + } + + + //========================================================================================================= + // Overwriting some functions which can't be used in computed + //========================================================================================================= + + public patch() { + console.error('Agile: can not use patch method on Computed since the value is dynamic!'); + return this; + } + + public persist(key?: string): this { + console.error('Agile: Computed state can not be persisted since the value is dynamic!', key); + return this; + } +} diff --git a/packages/agile-core/src/event/index.ts b/packages/agile-core/src/event/index.ts new file mode 100644 index 00000000..0f862349 --- /dev/null +++ b/packages/agile-core/src/event/index.ts @@ -0,0 +1,201 @@ +import Agile from "../agile"; +import {defineConfig} from "../utils"; +import {StateKey} from "../state"; + +export type DefaultEventPayload = { [key: string]: any }; +export type EventCallbackFunction = (payload?: PayloadType) => void; +export type EventKey = string | number; + +export interface EventConfig { + key?: EventKey + enabled?: boolean + maxUses?: number + delay?: number +} + +export class Event { + public agileInstance: () => Agile; + + public config: EventConfig; + + public _key?: StateKey; // should be a unique key/name which identifies the event + public callbacks: Set> = new Set(); // Stores callback functions + public uses: number = 0; // How often the event has been used + private currentTimeout: any; // The current timeout (function) + private queue: Array = []; // Queue if something is currently in timeout + public enabled: boolean = true; + + // @ts-ignore + public payload: PayloadType; // Only holds reference to the PayloadType so that it can be read external (never defined) + + constructor(agileInstance: Agile, config: EventConfig = {}) { + this.agileInstance = () => agileInstance; + + // Assign defaults to config + this.config = defineConfig(config, { + enabled: true + }); + + // Set Key + this._key = this.config.key; + + // Set Enabled + if (this.config.enabled !== undefined) + this.enabled = this.config.enabled; + } + + public set key(value: StateKey | undefined) { + this._key = value; + } + + public get key(): StateKey | undefined { + return this._key; + } + + + //========================================================================================================= + // On + //========================================================================================================= + /** + * Register Callback Function + */ + public on(callback: EventCallbackFunction) { + const cleanUpFunction = () => this.unsub(callback); + + // Add callback to Event Callbacks + this.callbacks.add(callback); + + return cleanUpFunction; + } + + + //========================================================================================================= + // Trigger + //========================================================================================================= + /** + * Run all callback Functions + */ + public trigger(payload?: PayloadType) { + // If event is disabled, return + if (!this.enabled) return this; + + if (this.config.delay) + this.delayedTrigger(payload); + else + this.normalTrigger(payload); + + return this; + } + + + //========================================================================================================= + // Disable + //========================================================================================================= + /** + * Disables the Event + */ + public disable() { + this.enabled = false; + return this; + } + + //========================================================================================================= + // Enable + //========================================================================================================= + /** + * Enables the Event + */ + public enable() { + this.enabled = true; + return this; + } + + + //========================================================================================================= + // Reset + //========================================================================================================= + /** + * Resets the Event + */ + public reset() { + // Set Enabled + this.enabled = this.config.enabled || true; + + // Reset Uses + this.uses = 0; + + // Clear active timeout + clearTimeout(this.currentTimeout); + + return this; + } + + //========================================================================================================= + // Unsub + //========================================================================================================= + /** + * @internal + * Unsubs a callback + */ + private unsub(callback: EventCallbackFunction) { + this.callbacks.delete(callback); + } + + + //========================================================================================================= + // Normal Trigger + //========================================================================================================= + /** + * @internal + * Call event instantly + */ + private normalTrigger(payload?: PayloadType) { + // Call callbacks + this.callbacks.forEach(callback => callback(payload)); + + // Increase uses + this.uses++; + + // Check if maxUses has been reached, if so disable event + if (this.config.maxUses && this.uses >= this.config.maxUses) + // Disable Event + this.disable(); + } + + + //========================================================================================================= + // Delayed Trigger + //========================================================================================================= + /** + * @internal + * Call event after config.delay + */ + private delayedTrigger(payload?: PayloadType) { + // Check if a timeout is currently active if so add the payload to a queue + if (this.currentTimeout !== undefined) { + if (payload) this.queue.push(payload); + return; + } + + // Looper function which loops through the queue(payloads) + const looper = (payload?: PayloadType) => { + this.currentTimeout = setTimeout(() => { + // Reset currentTimeout + this.currentTimeout = undefined; + + // Call normalTrigger + this.normalTrigger(payload); + + // If items are in queue, continue with them + if (this.queue.length > 0) + looper(this.queue.shift()) + }, this.config.delay); + } + + // Call looper with current Payload + looper(payload); + + return; + } + +} diff --git a/packages/agile-core/src/index.ts b/packages/agile-core/src/index.ts new file mode 100644 index 00000000..e69de29b diff --git a/packages/agile-core/src/internal.ts b/packages/agile-core/src/internal.ts new file mode 100644 index 00000000..63ed72b4 --- /dev/null +++ b/packages/agile-core/src/internal.ts @@ -0,0 +1,28 @@ +// This file exposes Agile functions and types to the outside world. +// It also serves as a cyclic dependency workaround. +// All internal Agile modules must import from here. + +// Agile +export * from './agile'; + +// Collection +export * from './collection'; +export * from './collection/group'; +export * from './collection/item'; +export * from './collection/selector'; + +// Computed +export* from './computed'; + +// Event +export * from './event'; + +// State +export * from './state'; +export {Dep} from './state/dep'; + +// Internal Classes +export * from './runtime'; +export * from './storage'; +export * from './sub'; +export * from './utils'; \ No newline at end of file diff --git a/packages/agile-core/src/runtime.ts b/packages/agile-core/src/runtime.ts new file mode 100644 index 00000000..df841189 --- /dev/null +++ b/packages/agile-core/src/runtime.ts @@ -0,0 +1,286 @@ +import State from "./state"; +import Agile from "./agile"; +import {copy, defineConfig} from "./utils"; +import {CallbackContainer, SubscriptionContainer} from "./sub"; +import Computed from "./computed"; + +export interface JobInterface { + state: State + newStateValue?: any + options?: { + background?: boolean + sideEffects?: boolean + forceRerender?: boolean + } +} + +export interface JobConfigInterface { + perform?: boolean // Should preform the job instantly + background?: boolean // Shouldn't cause an rerender during the perform process + sideEffects?: boolean // Should perform sideEffects like rebuilding groups + forceRerender?: boolean // Force rerender although for instance the values are the same +} + +export class Runtime { + public agileInstance: () => Agile; + + // Queue system + private currentJob: JobInterface | null = null; + private jobQueue: Array = []; + private jobsToRerender: Array = []; + + // Used for tracking computed dependencies + public trackState: boolean = false; // Check if agile should track states + public foundStates: Set = new Set(); // States which were tracked during the track time + + public internalIngestKey = "This is an Internal Key for ingesting internal stuff!"; + + constructor(agileInstance: Agile) { + this.agileInstance = () => agileInstance; + } + + + //========================================================================================================= + // Ingest + //========================================================================================================= + /** + * @internal + * Creates a Job out of State and new Value and than add it to a job queue + * Note: its not possible to set a state to undefined because undefined is used for internal activities! + */ + public ingest(state: State, newStateValue?: any, options: JobConfigInterface = {}): void { + // Merge default values into options + options = defineConfig(options, { + perform: true, + background: false, + sideEffects: true, + forceRerender: false + }); + + // Create Job + const job: JobInterface = { + state: state, + newStateValue: newStateValue, + options: { + background: options.background, + sideEffects: options.sideEffects, + forceRerender: options.forceRerender + } + }; + + // Grab nextState if newState not passed or compute if needed + if (newStateValue === this.internalIngestKey) { + if (job.state instanceof Computed) + job.newStateValue = job.state.computeValue(); + else + job.newStateValue = job.state.nextState + } + + // Check if state value und newStateValue are the same.. if so return except force Rerender (stringifying because of possible object or array) + if (JSON.stringify(state.value) === JSON.stringify(job.newStateValue) && !options.forceRerender) { + if (this.agileInstance().config.logJobs) + console.warn("Agile: Doesn't perform job because state values are the same! ", job); + return; + } + + // Logging + if (this.agileInstance().config.logJobs) + console.log(`Agile: Created Job(${job.state.key})`, job); + + // Push the Job to the Queue (safety.. that no Job get forgotten) + this.jobQueue.push(job); + + // Perform the Job + if (options.perform) { + const performJob = this.jobQueue.shift(); + if (performJob) + this.perform(performJob); + else + console.warn("Agile: No Job in queue ", job) + } + } + + + //========================================================================================================= + // Perform + //========================================================================================================= + /** + * @internal + * Perform a State Update + */ + private perform(job: JobInterface): void { + // Set Job to currentJob + this.currentJob = job; + + // Set Previous State + job.state.previousState = copy(job.state.value); + + // Write new value into the State + job.state.privateWrite(job.newStateValue); + + // Set isSet + job.state.isSet = job.newStateValue !== job.state.initialState; + + // Set is placeholder to false, because it has got a value + if (job.state.isPlaceholder) + job.state.isPlaceholder = false; + + // Perform SideEffects like watcher functions or state.sideEffects + this.sideEffects(job); + + // Set Job as completed (The deps and subs of completed jobs will be updated) + if (!job.options?.background || job.options?.forceRerender) + this.jobsToRerender.push(job); + + // Reset Current Job + this.currentJob = null; + + // Logging + if (this.agileInstance().config.logJobs) + console.log(`Agile: Completed Job(${job.state.key})`, job); + + // Continue the Loop and perform the next job.. if no job is left update the Subscribers for each completed job + if (this.jobQueue.length > 0) { + const performJob = this.jobQueue.shift(); + if (performJob) + this.perform(performJob); + else + console.warn("Agile: Failed to perform Job ", job); + } else { + // https://stackoverflow.com/questions/9083594/call-settimeout-without-delay + setTimeout(() => { + // Cause rerender on Subscribers + this.updateSubscribers(); + }) + } + } + + + //========================================================================================================= + // Side Effect + //========================================================================================================= + /** + * @internal + * SideEffects are sideEffects of the perform function.. for instance the watchers + */ + private sideEffects(job: JobInterface) { + const state = job.state; + + // Call Watchers + for (let watcher in state.watchers) + if (typeof state.watchers[watcher] === 'function') + state.watchers[watcher](state.getPublicValue()); + + // Call State SideEffects + if (typeof state.sideEffects === 'function' && job.options?.sideEffects) + state.sideEffects(); + + // Ingest Dependencies of State (Perform is false because it will be performed anyway after this sideEffect) + state.dep.deps.forEach((state) => this.ingest(state, this.internalIngestKey, {perform: false})); + } + + + //========================================================================================================= + // Update Subscribers + //========================================================================================================= + /** + * @internal + * This will be update all Subscribers of complete jobs + */ + private updateSubscribers(): void { + // Check if Agile has an integration because its useless to go trough this process without framework + // It won't happen anything because the state has no subs.. but this check here will maybe improve the performance + if (!this.agileInstance().integration) { + this.jobsToRerender = []; + return; + } + + // Subscriptions that has to be updated (Set = For preventing double subscriptions without further checks) + const subscriptionsToUpdate: Set = new Set(); + + // Map through Jobs to Rerender + this.jobsToRerender.forEach(job => + // Map through subs of the current Job State + job.state.dep.subs.forEach(subscriptionContainer => { + // Check if subscriptionContainer is ready + if (!subscriptionContainer.ready) + console.warn("Agile: SubscriptionContainer isn't ready yet ", subscriptionContainer); + + // For a Container that require props to be passed + if (subscriptionContainer.passProps) { + let localKey: string | null = null; + + // Find the local Key for this update by comparing the State instance from this Job to the State instances in the propStates object + for (let key in subscriptionContainer.propStates) + if (subscriptionContainer.propStates[key] === job.state) + localKey = key; + + // If matching key is found push it into the SubscriptionContainer propKeysChanged where it later will be build to an changed prop object + if (localKey) + subscriptionContainer.propKeysChanged.push(localKey); + } + subscriptionsToUpdate.add(subscriptionContainer); + })); + + // Perform Component or Callback updates + subscriptionsToUpdate.forEach(subscriptionContainer => { + // If Callback based subscription call the Callback Function + if (subscriptionContainer instanceof CallbackContainer) { + subscriptionContainer.callback(); + return; + } + + // If Component based subscription call the updateMethod which every framework has to define + if (this.agileInstance().integration?.updateMethod) + // @ts-ignore + this.agileInstance().integration?.updateMethod(subscriptionContainer.component, this.formatChangedPropKeys(subscriptionContainer)); + else + console.warn("Agile: The framework which you are using doesn't provide an updateMethod so it might be possible that no rerender will be triggered"); + }); + + // Log Job + if (this.agileInstance().config.logJobs && subscriptionsToUpdate.size > 0) + console.log("Agile: Rerendered Components ", subscriptionsToUpdate); + + // Reset Jobs to Rerender + this.jobsToRerender = []; + } + + + //========================================================================================================= + // Format Changed Prop Keys + //========================================================================================================= + /** + * @internal + * Builds an object out of propKeysChanged in the SubscriptionContainer + */ + public formatChangedPropKeys(subscriptionContainer: SubscriptionContainer): { [key: string]: any } { + const finalObject: { [key: string]: any } = {}; + + // Build Object + subscriptionContainer.propKeysChanged.forEach(changedKey => { + if (subscriptionContainer.propStates) + finalObject[changedKey] = subscriptionContainer.propStates[changedKey].value; + }); + + return finalObject; + } + + + //========================================================================================================= + // Get Found State + //========================================================================================================= + /** + * @internal + * Will return all tracked States + */ + public getFoundStates() { + const finalFoundStates = this.foundStates; + + // Reset tracking + this.trackState = false; + this.foundStates = new Set(); + + return finalFoundStates; + } +} diff --git a/packages/agile-core/src/state/dep.ts b/packages/agile-core/src/state/dep.ts new file mode 100644 index 00000000..eb4e41de --- /dev/null +++ b/packages/agile-core/src/state/dep.ts @@ -0,0 +1,26 @@ +import {SubscriptionContainer} from '../sub'; +import State from "./index"; + +export class Dep { + public deps: Set = new Set(); // Dependencies from the State + public subs: Set = new Set(); // Subscriptions for instance a component subscribes to a state to get rerendered if the state changes + + constructor(initialDeps?: Array) { + if (!initialDeps) return; + + // Add Initial Dependencies to Deps + initialDeps.forEach(dep => this.deps.add(dep)); + } + + + //========================================================================================================= + // Depend + //========================================================================================================= + /** + * Add new State as dependency + */ + public depend(state: State) { + if (state.dep !== this && !this.deps.has(state)) + this.deps.add(state); + } +} diff --git a/packages/agile-core/src/state/index.ts b/packages/agile-core/src/state/index.ts new file mode 100644 index 00000000..9e5f8f2e --- /dev/null +++ b/packages/agile-core/src/state/index.ts @@ -0,0 +1,339 @@ +import Agile from "../agile"; +import {copy, defineConfig, flatMerge, isValidObject} from "../utils"; +import Dep from "./dep"; +import {persistValue, updateValue} from "./persist"; +import {StorageKey} from "../storage"; + +export type StateKey = string | number; + +export interface PersistSettingsInterface { + isPersisted: boolean // Is State persisted + persistKey?: string | number // Current Persist Key.. for handling twice persisted states +} + +export class State { + public agileInstance: () => Agile; + + public _key?: StateKey; // should be a unique key/name which identifies the state + public valueType?: string; // primitive types for js users + public dep: Dep; // Includes the subscriptions and dependencies of the state + public watchers: { [key: string]: (value: any) => void } = {}; + public sideEffects?: Function; // SideEffects can be set by extended classes, such as Groups to build their output. + public isSet: boolean = false; // Has been changed from initial value + public persistSettings: PersistSettingsInterface; // Includes persist 'settings' (have to rename if I got an better name) + public output?: any; // This contains the public value.. if _value doesn't contain the public value (Used for example by collections) + public isPlaceholder: boolean = false; // Defines if the state is a placeholder or not + + public initialState: ValueType; + public _value: ValueType; // The current value of the state + public previousState: ValueType; // Will be set in runtime + public nextState: ValueType; // The next state is used internal and represents the nextState which can be edited as wished (cleaner than always setting the state) + + // public computeValue?: (newState?: ValueType) => ValueType; + + constructor(agileInstance: Agile, initialState: ValueType, key?: StateKey, deps: Array = []) { + this.agileInstance = () => agileInstance; + this.initialState = initialState; + this.dep = new Dep(deps); + this._key = key; + this._value = initialState; + this.previousState = initialState; + this.nextState = initialState; + this.persistSettings = { + isPersisted: false + } + } + + public set value(value: ValueType) { + this.set(value); + } + + public get value(): ValueType { + // Add state to foundState (for auto tracking used states in computed functions) + if (this.agileInstance().runtime.trackState) + this.agileInstance().runtime.foundStates.add(this); + + return this._value; + } + + public set key(value: StateKey | undefined) { + this._key = value; + } + + public get key(): StateKey | undefined { + return this._key; + } + + + //========================================================================================================= + // Set + //========================================================================================================= + /** + * Directly set state to a new value + */ + public set(value: ValueType, options: { background?: boolean, sideEffects?: boolean } = {}): this { + // Assign defaults to options + options = defineConfig(options, { + sideEffects: true, + background: false + }); + + // Check if Type is Correct + if (this.valueType && !this.isCorrectType(value)) { + console.warn(`Agile: Incorrect type (${typeof value}) was provided. Type fixed to ${this.valueType}`); + return this; + } + + // Check if something has changed (stringifying because of possible object or array) + if (JSON.stringify(this.value) === JSON.stringify(value)) + return this; + + // Ingest updated value + this.agileInstance().runtime.ingest(this, value, { + background: options.background, + sideEffects: options.sideEffects + }); + + return this; + } + + + //========================================================================================================= + // Ingest + //========================================================================================================= + /** + * @internal + * Will ingest the nextState or the computedValue (rebuilds state) + */ + public ingest(options: { background?: boolean, sideEffects?: boolean, forceRerender?: boolean } = {}) { + // Assign defaults to options + options = defineConfig(options, { + sideEffects: true, + background: false, + forceRerender: false + }); + + this.agileInstance().runtime.ingest(this, this.agileInstance().runtime.internalIngestKey, { + background: options.background, + sideEffects: options.sideEffects, + forceRerender: options.forceRerender + }); + } + + + //========================================================================================================= + // Type + //========================================================================================================= + /** + * This is thought for js users.. because ts users can set the type in <> + * @param type - wished type of the state + */ + public type(type: any): this { + // Supported types + const supportedTypes = ['String', 'Boolean', 'Array', 'Object', 'Number']; + + // Check if type is a supported Type + if (supportedTypes.findIndex(supportedType => supportedType === type.name) === -1) { + console.warn(`Agile: '${type}' is not supported! Supported types: String, Boolean, Array, Object, Number`); + return this; + } + + // Set valueType + this.valueType = type.name.toLowerCase(); + return this; + } + + + //========================================================================================================= + // Undo + //========================================================================================================= + /** + * Will set the state to the previous State + */ + public undo() { + this.set(this.previousState); + } + + + //========================================================================================================= + // Reset + //========================================================================================================= + /** + * Will reset the state to the initial value + */ + public reset(): this { + // Remove State from Storage (because it is than the initial State again and there is no need to save it anymore) + if (this.persistSettings.isPersisted && this.persistSettings.persistKey) + this.agileInstance().storage.remove(this.persistSettings.persistKey); + + // Set State to initial State + this.set(this.initialState); + return this; + } + + + //========================================================================================================= + // Patch + //========================================================================================================= + /** + * Will merge the changes into the state + */ + public patch(targetWithChanges: object, options: { addNewProperties?: boolean, background?: boolean } = {}): this { + // Check if state is object.. because only objects can use the patch method + if (!isValidObject(this.nextState)) { + console.warn("Agile: You can't use the patch method on a non object state!"); + return this; + } + + // Check if targetWithChanges is an Object.. because you can only patch objects into the State Object + if (!isValidObject(targetWithChanges)) { + console.warn("Agile: TargetWithChanges has to be an object!"); + return this; + } + + // Assign defaults to options + options = defineConfig(options, { + addNewProperties: true, + background: false + }); + + // Merge targetWithChanges into next State + this.nextState = flatMerge(this.nextState, targetWithChanges, options); + + // Check if something has changed (stringifying because of possible object or array) + if (JSON.stringify(this.value) === JSON.stringify(this.nextState)) + return this; + + // Set State to nextState + this.ingest({background: options.background}); + + this.isSet = this.nextState !== this.initialState; + return this; + } + + //========================================================================================================= + // Watch + //========================================================================================================= + /** + * Will always be called if the state changes + * @param key - The key of the watch method + * @param callback - The callback function + */ + public watch(key: string, callback: (value: ValueType) => void): this { + // Check if callback is a function (js) + if (typeof callback !== 'function') { + console.error('Agile: A watcher callback function has to be an function!'); + return this; + } + + // Add callback with key to watchers + this.watchers[key] = callback; + + return this; + } + + + //========================================================================================================= + // Remove Watcher + //========================================================================================================= + /** + * Removes a watcher called after the key + * @param key - the key of the watcher function + */ + public removeWatcher(key: string): this { + delete this.watchers[key]; + return this; + } + + + //========================================================================================================= + // Persist + //========================================================================================================= + /** + * Saves the state in the local storage or in a own configured storage + * @param key - the storage key (if no key passed it will take the state key) + */ + public persist(key?: StorageKey): this { + persistValue(this, key); + return this; + } + + + //========================================================================================================= + // Copy + //========================================================================================================= + /** + * Returns a fresh copy of the current value + */ + public copy(): ValueType { + return copy(this.value); + } + + + //========================================================================================================= + // Exists + //========================================================================================================= + /** + * Checks if the State exists + */ + public get exists(): boolean { + // Check if the value is not undefined and that the state is no placeholder + return this.getPublicValue() !== undefined && !this.isPlaceholder; + } + + + //========================================================================================================= + // Get Public Value + //========================================================================================================= + /** + * @internal + * Returns 100% the public value of a state because at some points (group) the _value contains only keys + */ + public getPublicValue(): ValueType { + if (this.output !== undefined) + return this.output; + return this._value; + } + + + //========================================================================================================= + // Private Write + //========================================================================================================= + /** + * @internal + * Will set a new _value and handles the stuff around like storage, .. + */ + public privateWrite(value: any) { + this._value = copy(value); + this.nextState = copy(value); + + // Save changes in Storage + updateValue(this); + } + + + //========================================================================================================= + // Get Persistable Value + //========================================================================================================= + /** + * @internal + * Will return the perstiable Value of this state.. + * some classes which extends state might have another peristiableValue than this.value (like the selector) + */ + public getPersistableValue(): any { + return this.value; + } + + + //========================================================================================================= + // Is Correct Type + //========================================================================================================= + /** + * @internal + * Checks if the 'value' has the same type as state.value + */ + private isCorrectType(value: any): boolean { + let type: string = typeof value; + return type === this.valueType; + } +} diff --git a/packages/agile-core/src/state/persist.ts b/packages/agile-core/src/state/persist.ts new file mode 100644 index 00000000..d466101c --- /dev/null +++ b/packages/agile-core/src/state/persist.ts @@ -0,0 +1,85 @@ +import State from "./index"; +import Storage, {StorageKey} from "../storage"; + + +//========================================================================================================= +// Persist Value +//========================================================================================================= +/** + * Will persist the 'state' into the configured storage with the key or if no key passed the state key + */ +export async function persistValue(state: State, key?: StorageKey) { + // Validate Key + const tempKey = validateKey(state, key); + if (!tempKey) { + console.error("Agile: If your State has no key provided before using persist.. you have to provide a key here!"); + return; + } + key = tempKey; + + // Get Storage + const storage = state.agileInstance().storage; + + // Check if persist State is already a isPersistState if so remove the old one + if (state.persistSettings.isPersisted && state.persistSettings.persistKey) + storage.remove(state.persistSettings.persistKey); + + // Add State to persistedStates in Storage + storage.persistedStates.add(state); + + // Call Handle which decides weather it has to add the storage value to the state or save the state into the storage + await handleStorageValue(key, storage, state); + + // Set persistSettings + state.persistSettings = { + isPersisted: true, + persistKey: key + } +} + + +//========================================================================================================= +// Update Value +//========================================================================================================= +/** + * Save current _value into storage if isPersistState + */ +export function updateValue(state: State) { + if (state.persistSettings.isPersisted && state.persistSettings.persistKey) + state.agileInstance().storage.set(state.persistSettings.persistKey, state._value); +} + + +//========================================================================================================= +// Helper +//========================================================================================================= + +function validateKey(state: State, key?: StorageKey): StorageKey | null { + // Get key from State key + if (!key && state.key) + return state.key; + + // Return null if no key can be found + if (!key) + return null; + + // Set Storage key as State key if no state key exists + if (!state.key) + state.key = key; + + return key; +} + +async function handleStorageValue(key: StorageKey, storage: Storage, state: State) { + // Get storage Value + const storageValue = await storage.get(key); + + // If the value doesn't exist in the storage yet.. create it + if (!storageValue) { + storage.set(key, state.getPersistableValue()); + return; + } + + // If the value already exists in the storage.. load it into the state + state.set(storageValue); +} diff --git a/packages/agile-core/src/storage.ts b/packages/agile-core/src/storage.ts new file mode 100644 index 00000000..406c5e3a --- /dev/null +++ b/packages/agile-core/src/storage.ts @@ -0,0 +1,184 @@ +import Agile from "./agile"; +import State from "./state"; +import {isAsyncFunction, isFunction, isJsonString} from "./utils"; +import Collection from "./collection"; + +export type StorageKey = string | number; +export interface StorageConfigInterface { + async?: boolean + prefix?: string + methods?: { + get: (key: string) => any + set: (key: string, value: any) => void + remove: (key: string) => void + } +} + +export class Storage { + public agileInstance: () => Agile; + + public isAsync: boolean = false; + private storageReady: boolean = false; + private storageType: 'localStorage' | 'custom' = 'localStorage'; + private storagePrefix: string = 'agile'; + private storageConfig: StorageConfigInterface; + + public persistedStates: Set = new Set(); + public persistedCollections: Set = new Set(); + + constructor(agileInstance: Agile, storageConfig: StorageConfigInterface) { + this.agileInstance = () => agileInstance; + this.storageConfig = storageConfig; + + // Set custom Storage prefix + if (storageConfig.prefix) + this.storagePrefix = storageConfig.prefix; + + // Set custom Storage functions + if (storageConfig.methods) + this.storageType = 'custom'; + + if (storageConfig.async) + this.isAsync = true; + + // Instantiate Custom Storage + if (this.storageType === 'custom') + this.instantiateCustomStorage() + + // Instantiate Local Storage + if (this.storageType === 'localStorage') + this.instantiateLocalStorage() + } + + + //========================================================================================================= + // Instantiate Local Storage + //========================================================================================================= + /** + * This instantiate the Local Storage + */ + private instantiateLocalStorage() { + // Check if Local Storage is Available (For instance in ReactNative it doesn't exist) + if (!this.localStorageAvailable()) { + console.warn("Agile: Local Storage is here not available.. to use the Storage functionality please provide a custom Storage!"); + return; + } + + // Set StorageMethods to LocalStorageMethods + this.storageConfig.methods = { + get: localStorage.getItem.bind(localStorage), + set: localStorage.setItem.bind(localStorage), + remove: localStorage.removeItem.bind(localStorage) + } + this.storageReady = true; + } + + + //========================================================================================================= + // Instantiate Custom Storage + //========================================================================================================= + /** + * This instantiate the Custom Storage + */ + private instantiateCustomStorage() { + // Check Get Function + if (!isFunction(this.storageConfig.methods?.get)) { + console.error("Agile: Your GET StorageMethod isn't valid!"); + return; + } + + // Check Set Function + if (!isFunction(this.storageConfig.methods?.set)) { + console.error("Agile: Your SET StorageMethod isn't valid!"); + return; + } + + // Check Remove Function + if (!isFunction(this.storageConfig.methods?.remove)) { + console.error("Agile: Your REMOVE StorageMethod isn't valid!"); + return; + } + + // Check if one function is async if so set is Async to true + if (isAsyncFunction(this.storageConfig.methods?.get) || isAsyncFunction(this.storageConfig.methods?.set) || isAsyncFunction(this.storageConfig.methods?.remove)) + this.isAsync = true; + + this.storageReady = true; + } + + + //========================================================================================================= + // Get + //========================================================================================================= + /** + * Gets the value provided by the key from the storage + */ + public get(key: StorageKey): GetType | Promise | undefined { + if (!this.storageReady || !this.storageConfig.methods?.get) return; + + // Async Get + if (this.isAsync) + return new Promise((resolve, reject) => { + this.storageConfig.methods?.get(this.getStorageKey(key)) + .then((res: any) => { + // If result is no Json + if (!isJsonString(res)) + return resolve(res); + + // Format Json to Object + resolve(JSON.parse(res)); + }) + .catch(reject); + }); + + // Normal Get + const res = this.storageConfig.methods.get(this.getStorageKey(key)); + if (isJsonString(res)) + return JSON.parse(res); + + return res; + } + + + //========================================================================================================= + // Set + //========================================================================================================= + /** + * Sets the value into the storage + */ + public set(key: StorageKey, value: any) { + if (!this.storageReady || !this.storageConfig.methods?.set) return; + this.storageConfig.methods.set(this.getStorageKey(key), JSON.stringify(value)); + } + + + //========================================================================================================= + // Remove + //========================================================================================================= + /** + * Deletes the value that is stored with the key + */ + public remove(key: StorageKey) { + if (!this.storageReady || !this.storageConfig.methods?.remove) return; + this.storageConfig.methods.remove(this.getStorageKey(key)); + } + + + //========================================================================================================= + // Helper + //========================================================================================================= + + private getStorageKey(key: StorageKey) { + return `_${this.storagePrefix}_${key}`; + } + + private localStorageAvailable() { + try { + localStorage.setItem('_', '_'); + localStorage.removeItem('_'); + return true; + } catch (e) { + return false; + } + } +} diff --git a/packages/agile-core/src/sub.ts b/packages/agile-core/src/sub.ts new file mode 100644 index 00000000..bd168770 --- /dev/null +++ b/packages/agile-core/src/sub.ts @@ -0,0 +1,204 @@ +import State from "./state"; +import Agile from "./agile"; + + +//========================================================================================================= +// Subscription Container +//========================================================================================================= + +export type SubscriptionContainer = ComponentContainer | CallbackContainer; + + +//========================================================================================================= +// Component Container +//========================================================================================================= + +export class ComponentContainer { + public component: any; + + // Only needed object orientated subscriptions + public passProps: boolean = false; + public propStates?: { [key: string]: State }; // states which will than be returned as prop object by the integration + public propKeysChanged: Array = []; // Used to preserve local keys to update before update is performed, cleared every update + + public ready: boolean = false; + public subs: Set = new Set([]); // States that are subscribed by this component + + constructor(component: any, subs?: Set) { + this.component = component + if (subs) + this.subs = subs; + } +} + + +//========================================================================================================= +// Callback Container +//========================================================================================================= + +export class CallbackContainer extends ComponentContainer { + public callback: Function; + + constructor(callback: Function, subs?: Set) { + super(null, subs); + + this.callback = callback; + } +} + + +//========================================================================================================= +// Controller +//========================================================================================================= + +export class SubController { + public agileInstance: () => Agile; + + // Component based Subscription + public components: Set = new Set(); + + // Callback based Subscription + public callbacks: Set = new Set(); + + public constructor(agileInstance: Agile) { + this.agileInstance = () => agileInstance; + } + + + //========================================================================================================= + // Subscribe with Subs Object + //========================================================================================================= + /** + * Subscribe to Agile State with a returned object of props this props can than be returned by the component (See react-integration) + */ + public subscribeWithSubsObject(subscriptionInstance: any, subs: { [key: string]: State } = {}): { subscriptionContainer: SubscriptionContainer, props: { [key: string]: State['value'] } } { + const subscriptionContainer = this.registerSubscription(subscriptionInstance); + + const props: { [key: string]: State } = {}; + subscriptionContainer.passProps = true; + subscriptionContainer.propStates = {...subs}; + + // Go through subs + let localKeys = Object.keys(subs); + localKeys.forEach(key => { + const state = subs[key]; + + // Add State to SubscriptionContainer Subs + subscriptionContainer.subs.add(state); + + // Add SubscriptionContainer to State Subs + state.dep.subs.add(subscriptionContainer); + + // Add state to props + props[key] = state.value; + }); + + return { + subscriptionContainer: subscriptionContainer, + props: props + }; + } + + + //========================================================================================================= + // Subscribe with Subs Array + //========================================================================================================= + /** + * Subscribe to Agile State + */ + public subscribeWithSubsArray(subscriptionInstance: any, subs: Array = []): SubscriptionContainer { + const subscriptionContainer = this.registerSubscription(subscriptionInstance, subs); + + subs.forEach(state => { + // Add State to SubscriptionContainer Subs + subscriptionContainer.subs.add(state); + + // Add SubscriptionContainer to State Dependencies Subs + state.dep.subs.add(subscriptionContainer); + }); + + return subscriptionContainer; + } + + + //========================================================================================================= + // Unsubscribe + //========================================================================================================= + /** + * Unsubscribe a component or callback + */ + public unsubscribe(subscriptionInstance: any) { + const unsub = (subscriptionContainer: CallbackContainer | ComponentContainer) => { + subscriptionContainer.ready = false; + + // Removes SubscriptionContainer from State subs + subscriptionContainer.subs.forEach(state => { + state.dep.subs.delete(subscriptionInstance); + }); + }; + + if (subscriptionInstance instanceof CallbackContainer) + unsub(subscriptionInstance); + else if (subscriptionInstance.componentContainer) + unsub(subscriptionInstance.componentContainer); + } + + + //========================================================================================================= + // Register Subscription + //========================================================================================================= + /** + * Registers the Component/Callback Subscription and returns a SubscriptionContainer + */ + public registerSubscription(integrationInstance: any, subs: Array = []): SubscriptionContainer { + // - Callback based Subscription + if (typeof integrationInstance === 'function') { + // Create CallbackContainer + const callbackContainer = new CallbackContainer(integrationInstance as Function, new Set(subs)); + + // Add to callbacks + this.callbacks.add(callbackContainer); + + // Set Ready + callbackContainer.ready = true; + + if (this.agileInstance().config.logJobs) + console.log("Agile: Registered Callback ", callbackContainer); + + return callbackContainer; + } + + // - Component based Subscription + // Create Component Container + const componentContainer = new ComponentContainer(integrationInstance, new Set(subs)); + + // Instantiate the componentContainer in a Component (for instance see react.integration AgileHOC) + integrationInstance.componentContainer = componentContainer; + + // Add to components + this.components.add(componentContainer); + + // Set Ready + if (!this.agileInstance().config.waitForMount) + componentContainer.ready = true; + + if (this.agileInstance().config.logJobs) + console.log("Agile: Registered Component ", componentContainer); + + return componentContainer; + } + + + //========================================================================================================= + // Mount + //========================================================================================================= + /** + * This will mount the component (Mounts currently only useful in Component based Subscription) + */ + public mount(integrationInstance: any) { + if (!integrationInstance.componentContainer) return; + + // Set Ready to true + integrationInstance.componentContainer.ready = true; + } +} diff --git a/packages/agile-core/src/use.ts b/packages/agile-core/src/use.ts new file mode 100644 index 00000000..c9638021 --- /dev/null +++ b/packages/agile-core/src/use.ts @@ -0,0 +1,94 @@ +import Agile from "../agile"; +import reactIntegration from "./react"; + +export interface Integration { + ready?: boolean; + frameworkConstructor?: any; // The actual framework for instance React + name?: any; // The name of the framework + bind?: (agileInstance: Agile) => void; // Will be called if the framework got successful instantiated + updateMethod?: (componentInstance: any, updatedData: Object) => void; // Will be called if a State changes (Only by Component based Subscription) +} + +// Required Properties of a custom Integration +const requiredIntegrationProperties = ['name', 'bind', 'updateMethod']; + +// This Integration will injected into Agile.integration +const finalIntegration: Integration = { + ready: false +}; + +export default function use(framework: any, agileInstance: Agile) { + const frameworkName = getFrameworkName(framework); + + // Integrate Framework + switch (frameworkName) { + case 'react': + integrate(reactIntegration, 'react'); + break; + + case 'custom': + if (validateCustomFramework(framework as Integration)) + integrate(framework, 'custom'); + break; + + default: + // Should never happen + } + + // Assign Framework Constructor to framework if its not a custom framework + // because custom Frameworks has to set the frameworkConstructor (direct dependency to Framework (React)) on their own + // and have to pass an Integration and not directly a framework + if (frameworkName !== 'custom') + finalIntegration.frameworkConstructor = framework; + + // Inject Integration into Agile + agileInstance.integration = finalIntegration; + + // If the Integration is ready call integration.bind() + if (agileInstance.integration.ready) { + if (agileInstance.integration.bind) + agileInstance.integration.bind(agileInstance); + if (agileInstance.config.logJobs) console.log(`Agile: Successfully integrated '${frameworkName}'`); + } else + console.error('Agile: Failed to integrate with framework! It\'s possible you didn\'t call Pulse.initFrameworkIntegration() before new Pulse.'); +} + + +//========================================================================================================= +// Helper +//========================================================================================================= + +function integrate(frameworkIntegration: Integration, frameworkName: string) { + // Bind all properties from integration to our main Integration Object + Object.keys(frameworkIntegration).forEach(property => { + // @ts-ignore + finalIntegration[property] = frameworkIntegration[property]; + }); + + // Assign Name + finalIntegration.name = frameworkIntegration.name || frameworkName; + + // Set Integration to Ready (can be used) + finalIntegration.ready = true; +} + +function validateCustomFramework(customIntegration: Integration): boolean { + let valid: boolean = true; + + // Check if custom Integration has all required properties + requiredIntegrationProperties.forEach(property => { + if (!customIntegration.hasOwnProperty(property)) valid = false; + }); + + return valid; +} + +function getFrameworkName(frameworkConstructor: any): string { + let name: string = 'custom'; + + // Check if framework is React + if (frameworkConstructor.hasOwnProperty('__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED')) + return 'react'; + + return name; +} diff --git a/packages/agile-core/src/utils.ts b/packages/agile-core/src/utils.ts new file mode 100644 index 00000000..93725d88 --- /dev/null +++ b/packages/agile-core/src/utils.ts @@ -0,0 +1,178 @@ +import State from "./state"; +import Agile from "./agile"; +import Event from "./event"; +import Collection from "./collection"; + + +//========================================================================================================= +// Copy +//========================================================================================================= +/** + * Copy an array or object.. without any dependencies + */ + +export function copy(value: T): T; +export function copy>(value: T): T[]; +export function copy(value: T): T | T[] { + if (Array.isArray(value)) + return [...value]; + + if (isValidObject(value)) + return {...value}; + + return value; +} + + +//========================================================================================================= +// Is Valid Object +//========================================================================================================= +/** + * Checks if an Object is an valid object for Agile + * https://stackoverflow.com/questions/12996871/why-does-typeof-array-with-objects-return-object-and-not-array + */ +export function isValidObject(value: any): boolean { + function isHTMLElement(obj: any) { + try { + return obj instanceof HTMLElement; + } catch (e) { + return typeof obj === 'object' && obj.nodeType === 1 && typeof obj.style === 'object' && typeof obj.ownerDocument === 'object'; + } + } + + return value !== null && typeof value === 'object' && !isHTMLElement(value) && !Array.isArray(value); +} + + +//========================================================================================================= +// Normalize Array +//========================================================================================================= +/** + * Convert item into an array + */ +export function normalizeArray(items?: DataType | Array): Array { + // Return empty array if no items + if (!items) + return []; + + return Array.isArray(items) ? items : [items as DataType]; +} + + +//========================================================================================================= +// Get Instance +//========================================================================================================= +/** + * Tries to get AgileInstance from instance(State, Collection) + */ +export function getAgileInstance(instance: any): Agile | null { + try { + // Return state agileInstance + if (instance instanceof State) + return instance.agileInstance(); + + if(instance instanceof Event) + return instance.agileInstance(); + + if(instance instanceof Collection) + return instance.agileInstance(); + + // Return the globalBind agile instance + // @ts-ignore + return globalThis.__agile; + } catch (e) { + // fail silently + } + + return null +} + + +//========================================================================================================= +// Is Function +//========================================================================================================= +/** + * Checks if func is a function + */ +export function isFunction(func: any) { + return typeof func === 'function'; +} + + +//========================================================================================================= +// Is Async Function +//========================================================================================================= +/** + * Checks if func is a async function + */ +export function isAsyncFunction(func: any) { + return isFunction(func) && func.constructor.name === 'AsyncFunction'; +} + + +//========================================================================================================= +// Is Valid Url +// https://stackoverflow.com/questions/5717093/check-if-a-javascript-string-is-a-url +//========================================================================================================= +/** + * Checks if url is valid + */ +export function isValidUrl(url: string): boolean { + const pattern = new RegExp('^(https?:\\/\\/)?' + // protocol + '((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|' + // domain name + '((\\d{1,3}\\.){3}\\d{1,3}))' + // OR ip (v4) address + '(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*' + // port and path + '(\\?[;&a-z\\d%_.~+=-]*)?' + // query string + '(\\#[-a-z\\d_]*)?$', 'i'); // fragment locator + return pattern.test(url); +} + + +//========================================================================================================= +// Is Json String +//========================================================================================================= +/** + * Checks if value is a valid JsonString + */ +export function isJsonString(value: any) { + try { + JSON.parse(value); + } catch (e) { + return false; + } + return true; +} + +//========================================================================================================= +// Define Config +//========================================================================================================= +/** + * Will create a config (config) and merges default values (default) into this config (config) + */ +export function defineConfig(config: C, defaults: object): C { + return {...defaults, ...config}; +} + + +//========================================================================================================= +// Flat Merge +//========================================================================================================= +/** + * Merged the items flat into the object + */ +export function flatMerge(source: DataType, changes: Object, config: { addNewProperties?: boolean } = {}): DataType { + // Copy Source to avoid reference + const _source = copy(source); + + // Loop through changes object and merge changes into source + let keys = Object.keys(changes); + keys.forEach(property => { + // @ts-ignore https://stackoverflow.com/questions/18452920/continue-in-cursor-foreach + if (!config.addNewProperties && !_source[property]) return; + + // @ts-ignore + _source[property] = changes[property]; + }); + + return _source; +} diff --git a/packages/agile-core/tests/collection/default.spec.ts b/packages/agile-core/tests/collection/default.spec.ts new file mode 100644 index 00000000..84b1ea07 --- /dev/null +++ b/packages/agile-core/tests/collection/default.spec.ts @@ -0,0 +1,178 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../src"; +import Group from "../../src/collection/group"; +import Selector from "../../src/collection/selector"; + +describe('Default Collection Tests', () => { + // Define Agile + const App = new Agile(); + + interface userInterface { + id: number + name: string + } + + describe('Collection', () => { + // Set Collections + const MY_COLLECTION = App.Collection(); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.config.key).to.eq(undefined, 'MY_COLLECTION has correct config.key'); + expect(MY_COLLECTION.config.primaryKey).to.eq('id', 'MY_COLLECTION has correct config.primaryKey'); + expect(MY_COLLECTION.config.defaultGroupKey).to.eq('default', 'MY_COLLECTION has correct config.defaultGroupKey'); + expect(JSON.stringify(MY_COLLECTION.config.groups)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no config.groups'); + expect(JSON.stringify(MY_COLLECTION.config.selectors)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no config.selectors'); + + expect(MY_COLLECTION.key).to.eq(undefined, 'MY_COLLECTION has correct key'); + expect(MY_COLLECTION._key).to.eq(undefined, 'MY_COLLECTION has correct _key'); + expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no data'); + expect(MY_COLLECTION.isPersistCollection).to.eq(false, 'MY_COLLECTION is no persisted Collection'); + expect(Object.keys(MY_COLLECTION.groups).length === 1 && MY_COLLECTION.groups["default"] !== undefined).to.eq(true, 'MY_COLLECTION has only default group'); + expect(JSON.stringify(MY_COLLECTION.selectors)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no selectors'); + expect(MY_COLLECTION.size).to.eq(0, 'MY_COLLECTION has correct size'); + }); + + it('Can change key', () => { + // Update key + MY_COLLECTION.key = 'myKey'; + + expect(MY_COLLECTION.key).to.eq('myKey', 'MY_COLLECTION has correct key'); + expect(MY_COLLECTION._key).to.eq('myKey', 'MY_COLLECTION has correct _key'); + }); + }); + + describe('Collection with Key', () => { + // Set Collection + const MY_COLLECTION = App.Collection({ + key: 'myCollectionKey' + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.key).to.eq('myCollectionKey', 'MY_COLLECTION has correct key'); + expect(MY_COLLECTION._key).to.eq('myCollectionKey', 'MY_COLLECTION has correct _key'); + }); + + it('Can change key', () => { + // Update key + MY_COLLECTION.key = 'withNewKey'; + + expect(MY_COLLECTION.key).to.eq('withNewKey', 'MY_COLLECTION has correct key'); + expect(MY_COLLECTION._key).to.eq('withNewKey', 'MY_COLLECTION has correct _key'); + }); + }); + + describe('Collection with default Groups', () => { + describe('Default Groups in Array shape', () => { + // Set Collection + const MY_COLLECTION = App.Collection({ + groups: ['group1', 'group2'] + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION has group1 in groups'); + expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION has group2 in groups'); + expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 has correct key'); + expect(MY_COLLECTION.groups['group2'].key).to.eq('group2', 'group2 has correct key'); + }); + }); + + describe('Default Groups in Object shape', () => { + interface userInterface { + id: number + name: string + } + + // Set Collection + const MY_COLLECTION = App.Collection((collection) => ({ + groups: { + group1: collection.Group(), + group2: collection.Group() + } + })); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION has group1 in groups'); + expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION has group2 in groups'); + expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 has correct key'); + expect(MY_COLLECTION.groups['group2'].key).to.eq('group2', 'group2 has correct key'); + }); + }); + }); + + describe('Collection with Key', () => { + // Set Collection + const MY_COLLECTION = App.Collection({ + key: 'myCollectionKey' + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.key).to.eq('myCollectionKey', 'MY_COLLECTION has correct key'); + expect(MY_COLLECTION._key).to.eq('myCollectionKey', 'MY_COLLECTION has correct _key'); + }); + + it('Can change key', () => { + // Update key + MY_COLLECTION.key = 'withNewKey'; + + expect(MY_COLLECTION.key).to.eq('withNewKey', 'MY_COLLECTION has correct key'); + expect(MY_COLLECTION._key).to.eq('withNewKey', 'MY_COLLECTION has correct _key'); + }); + }); + + describe('Collection with default Selectors', () => { + describe('Default Selector in Array shape', () => { + // Set Collection + const MY_COLLECTION = App.Collection({ + selectors: ['selector1', 'selector2'] + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector1 in selectors'); + expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector2 in selectors'); + expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 has correct key'); + expect(MY_COLLECTION.selectors['selector2'].key).to.eq('selector2', 'selector2 has correct key'); + }); + }); + + describe('Default Selectors in Object shape', () => { + // Set Collection + const MY_COLLECTION = App.Collection((collection) => ({ + selectors: { + selector1: collection.Selector('3'), + selector2: collection.Selector('2') + } + })); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector1 in selectors'); + expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION has selector2 in selectors'); + expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 has correct key'); + expect(MY_COLLECTION.selectors['selector2'].key).to.eq('selector2', 'selector2 has correct key'); + }); + }); + }); + + describe('Collection with primaryKey', () => { + // Set Collection + const MY_COLLECTION = App.Collection({ + primaryKey: 'key' + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.config.primaryKey).to.eq('key', 'MY_COLLECTION has correct primaryKey'); + }); + }); + + describe('Collection with defaultGroupKey', () => { + // Set Collection + const MY_COLLECTION = App.Collection({ + defaultGroupKey: 'normal' + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.config.defaultGroupKey).to.eq('normal', 'MY_COLLECTION has correct defaultGroupKey'); + expect(MY_COLLECTION.groups['normal'] instanceof Group).to.eq(true, 'MY_COLLECTION has default group in groups') + }); + }); +}); diff --git a/packages/agile-core/tests/collection/functions/collect.function.spec.ts b/packages/agile-core/tests/collection/functions/collect.function.spec.ts new file mode 100644 index 00000000..6c9d47bc --- /dev/null +++ b/packages/agile-core/tests/collection/functions/collect.function.spec.ts @@ -0,0 +1,374 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; +import Group from "../../../src/collection/group"; + +describe('Collect Function Tests', () => { + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + describe('Collection without primaryKey', () => { + let rerenderCount = 0; + + // Object Interface + interface userInterface { + id: number + name: string + age?: number + } + + // Create Collection + const MY_COLLECTION = App.Collection(); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myHookCollection] = useAgile([MY_COLLECTION], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has correct data'); + expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created') + expect(MY_COLLECTION.groups['default']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); + + expect(JSON.stringify(myHookCollection)).to.eq(JSON.stringify([]), 'myHookState has correct MY_COLLECTION value'); + expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); + }); + + it('Can collect item', async () => { + // Collect item + MY_COLLECTION.collect({id: 1, name: 'jeff'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION data has collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 1) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size has been increased by 1'); + + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t collect item with no primaryKey', async () => { + // Collect item + // @ts-ignore + MY_COLLECTION.collect({name: 'benno'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); + + expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); + }); + + it('Can\'t collect no object item', async () => { + // Collect item + // @ts-ignore + MY_COLLECTION.collect('franz'); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); + + expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); + }); + + it('Can\'t collect item with wrong primaryKey', async () => { + // Collect item + // @ts-ignore + MY_COLLECTION.collect({key: 2, name: 'hans'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify(undefined), 'MY_COLLECTION data hasn\'t collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(false, 'MY_COLLECTION default group doesn\'t contain collected value'); + expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); + + expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); + }); + + it('Can collect multiple items at the same time', async () => { + // Collect item + MY_COLLECTION.collect([{id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ + id: 2, + name: 'hans' + }), 'MY_COLLECTION data has collected value with id 2'); + expect(JSON.stringify(MY_COLLECTION.data[3]?.value)).to.eq(JSON.stringify({ + id: 3, + name: 'frank' + }), 'MY_COLLECTION data has collected value with id 3'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value with id 2'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 3) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value with id 3'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION size has been increased by 2'); + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can overwrite item if collecting with existing primaryKey', async () => { + MY_COLLECTION.collect({id: 2, name: 'benno'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ + id: 2, + name: 'benno' + }), 'MY_COLLECTION data has overwritten value with id 2'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION size stayed the same'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(true, 'MY_COLLECTION default group still contains collected value'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + describe('Test background option', () => { + it('Does call callBackFunction by collecting Item with background = false', async () => { + // Collect item + MY_COLLECTION.collect({id: 4, name: 'dustin'}, [], {background: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[4]?.value)).to.eq(JSON.stringify({ + id: 4, + name: 'dustin' + }), 'MY_COLLECTION data has collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 4) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.size).to.eq(4, 'MY_COLLECTION size has been increased by 1'); + + expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); + }); + + it('Doesn\'t call callBackFunction by collecting Item with background = true', async () => { + // Collect item + MY_COLLECTION.collect({id: 5, name: 'snipey'}, [], {background: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[5]?.value)).to.eq(JSON.stringify({ + id: 5, + name: 'snipey' + }), 'MY_COLLECTION data has collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 5) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.size).to.eq(5, 'MY_COLLECTION size has been increased by 1'); + + expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); + }); + }); + + describe('Test method option', () => { + it('Does add the item at the end of the group with method = \'push\'', async () => { + // Collect item + MY_COLLECTION.collect({id: 6, name: 'jana'}, [], {method: 'push'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[6]?.value)).to.eq(JSON.stringify({ + id: 6, + name: 'jana' + }), 'MY_COLLECTION data has collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 6) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.groups['default']?.value[MY_COLLECTION.groups['default']?.value.length - 1]).to.eq(6, 'MY_COLLECTION default group collected value is last item in group'); + expect(MY_COLLECTION.size).to.eq(6, 'MY_COLLECTION size has been increased by 1'); + + expect(rerenderCount).to.eq(5, 'rerenderCount has been increased by 1'); + }); + + it('Does add the item at the start of the group with method = \'unshift\'', async () => { + // Collect item + MY_COLLECTION.collect({id: 7, name: 'gina'}, [], {method: 'unshift'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[7]?.value)).to.eq(JSON.stringify({ + id: 7, + name: 'gina' + }), 'MY_COLLECTION data has collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 7) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.groups['default']?.value[0]).to.eq(7, 'MY_COLLECTION default group collected value is first item in group'); + expect(MY_COLLECTION.size).to.eq(7, 'MY_COLLECTION size has been increased by 1'); + + expect(rerenderCount).to.eq(6, 'rerenderCount has been increased by 1'); + }); + }); + + describe('Test patch option', () => { + it('Does patch value into item without overwriting it with patch = true', async () => { + // Collect item + // @ts-ignore + MY_COLLECTION.collect({id: 1, age: 20}, [], {patch: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff', + age: 20 + }), 'MY_COLLECTION data at id 1 has changed'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 1) !== -1).to.eq(true, 'MY_COLLECTION default group still contains collected value'); + expect(MY_COLLECTION.size).to.eq(7, 'MY_COLLECTION size stayed the same'); + + expect(rerenderCount).to.eq(7, 'rerenderCount has been increased by 1'); + }); + + it('Does set value into item by overwriting it with patch = false', async () => { + // Collect item + // @ts-ignore + MY_COLLECTION.collect({id: 2, age: 30}, [], {patch: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ + id: 2, + age: 30 + }), 'MY_COLLECTION data at id 2 has changed'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(true, 'MY_COLLECTION default group still contains collected value'); + expect(MY_COLLECTION.size).to.eq(7, 'MY_COLLECTION size stayed the same'); + + expect(rerenderCount).to.eq(8, 'rerenderCount has been increased by 1'); + }); + }); + + describe('Test forEachItem option', () => { + it('Does call forEachItem', async () => { + const myForEachItems: { item: userInterface, key: string | number, index: number }[] = []; + + // Collect item + MY_COLLECTION.collect([{id: 8, name: 'joshi'}, {id: 9, name: 'paul'}], [], { + forEachItem: (item, key, index) => { + myForEachItems.push({ + item: item, + key: key, + index: index + }) + } + }); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[8]?.value)).to.eq(JSON.stringify({ + id: 8, + name: 'joshi' + }), 'MY_COLLECTION data has collected value'); + expect(JSON.stringify(MY_COLLECTION.data[9]?.value)).to.eq(JSON.stringify({ + id: 9, + name: 'paul' + }), 'MY_COLLECTION data has collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 8) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 9) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.size).to.eq(9, 'MY_COLLECTION size has been increased by 2'); + + expect(JSON.stringify(myForEachItems[0])).to.eq(JSON.stringify({ + item: {id: 8, name: 'joshi'}, + key: 8, + index: 0 + }), 'myForEachItem has contains first collected item'); + expect(JSON.stringify(myForEachItems[1])).to.eq(JSON.stringify({ + item: {id: 9, name: 'paul'}, + key: 9, + index: 1 + }), 'myForEachItem has contains second collected item'); + + expect(rerenderCount).to.eq(9, 'rerenderCount has been increased by 1'); + }); + }); + }); + + describe('Collection with primaryKey and defaultGroupKey', () => { + let rerenderCount = 0; + + // Object Interface + interface userInterface { + key: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection({ + primaryKey: 'key', + }); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myHookCollection] = useAgile([MY_COLLECTION], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has correct data'); + expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created') + expect(MY_COLLECTION.groups['default']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); + + expect(JSON.stringify(myHookCollection)).to.eq(JSON.stringify([]), 'myHookState has correct MY_COLLECTION value'); + }); + + it('Can collect item', async () => { + // Collect item + MY_COLLECTION.collect({key: 1, name: 'jeff'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ + key: 1, + name: 'jeff' + }), 'MY_COLLECTION data has collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 1) !== -1).to.eq(true, 'MY_COLLECTION default group contains collected value'); + expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size has been increased by 1'); + + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t collect item with no primaryKey', async () => { + // Collect item + // @ts-ignore + MY_COLLECTION.collect({name: 'benno'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); + + expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); + }); + + it('Can\'t collect item with wrong primaryKey', async () => { + // Collect item + // @ts-ignore + MY_COLLECTION.collect({id: 2, name: 'hans'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify(undefined), 'MY_COLLECTION data hasn\'t collected value'); + expect(MY_COLLECTION.groups['default']?.value.findIndex(value => value === 2) !== -1).to.eq(false, 'MY_COLLECTION default group doesn\'t contain collected value'); + expect(MY_COLLECTION.size).to.eq(1, 'MY_COLLECTION size stayed the same'); + + expect(rerenderCount).to.eq(1, 'rerenderCount stayed the same'); + }); + }); +}); diff --git a/packages/agile-core/tests/collection/functions/createGroup.function.spec.ts b/packages/agile-core/tests/collection/functions/createGroup.function.spec.ts new file mode 100644 index 00000000..13da99f8 --- /dev/null +++ b/packages/agile-core/tests/collection/functions/createGroup.function.spec.ts @@ -0,0 +1,49 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import Group from "../../../src/collection/group"; + +describe('createGroup Function Tests', () => { + // Define Agile + const App = new Agile(); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.data)).to.eq(JSON.stringify({}), 'MY_COLLECTION has correct data'); + expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); + }); + + it('Can create Group', () => { + // Create Group + MY_COLLECTION.createGroup('group1'); + + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 has been created'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has no initialItems'); + expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 has correct key'); + }); + + it('Can create Group with initial Items', () => { + // Create Group + MY_COLLECTION.createGroup('group2', ['1', '2']); + + expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION group2 has been created'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify(['1', '2']), 'group2 has initialItems'); + expect(MY_COLLECTION.groups['group2'].key).to.eq('group2', 'group2 has correct key'); + }); + + it('Can\'t overwrite Group which already exists', () => { + // Create Group + MY_COLLECTION.createGroup('group2'); + + expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION group2 is still a group'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify(['1', '2']), 'group2 items stayed the same'); + }); +}); diff --git a/packages/agile-core/tests/collection/functions/createSelector.function.spec.ts b/packages/agile-core/tests/collection/functions/createSelector.function.spec.ts new file mode 100644 index 00000000..d3572684 --- /dev/null +++ b/packages/agile-core/tests/collection/functions/createSelector.function.spec.ts @@ -0,0 +1,54 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import Selector from "../../../src/collection/selector"; +import Item from "../../../src/collection/item"; + +describe('createSelector Function Tests', () => { + // Define Agile + const App = new Agile(); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(); + MY_COLLECTION.collect({id: 1, name: 'jeff'}); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'MY_COLLECTION has correct data'); + expect(JSON.stringify(MY_COLLECTION.selectors)).to.eq(JSON.stringify({}), 'MY_COLLECTION has no initial selectors'); + }); + + it('Can create Selector with not existing id', () => { + // Create Selector + MY_COLLECTION.createSelector('selector1', 3); + + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 has been created'); + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(3, 'selector1 is watching right id'); + expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 has correct key'); + + expect(MY_COLLECTION.data[3] instanceof Item).to.eq(true, 'MY_COLLECTION data contains dummy Item with id 3 (created by Selector)'); + expect(MY_COLLECTION.data[3].isPlaceholder).to.eq(true, 'Item at id 3 is placeholder'); + }); + + it('Can create Selector with existing id', () => { + // Create Selector + MY_COLLECTION.createSelector('selector2', 1); + + expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 has been created'); + expect(MY_COLLECTION.selectors['selector2'].id).to.eq(1, 'selector1 is watching right id'); + expect(MY_COLLECTION.selectors['selector2'].key).to.eq('selector2', 'selector1 has correct key'); + }); + + it('Can\'t overwrite Selector which already exists', () => { + // Create Selector + MY_COLLECTION.createSelector('selector1', 2); + + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 is still a selector'); + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(3, 'selector1 id stayed the same (3)'); + }); +}); diff --git a/packages/agile-core/tests/collection/functions/findById.function.spec.ts b/packages/agile-core/tests/collection/functions/findById.function.spec.ts new file mode 100644 index 00000000..e3b8a4f6 --- /dev/null +++ b/packages/agile-core/tests/collection/functions/findById.function.spec.ts @@ -0,0 +1,39 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import State from "../../../src/state"; + +describe('FindById Function Tests', () => { + // Define Agile + const App = new Agile(); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(); + MY_COLLECTION.collect({id: 1, name: 'jeff'}); + MY_COLLECTION.collect({id: 2, name: 'hans'}); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'MY_COLLECTION has correct data'); + expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({id: 2, name: 'hans'}), 'MY_COLLECTION has correct data'); + expect(MY_COLLECTION.size).to.eq(2, 'MY_COLLECTION has correct size'); + }); + + it('Can findById', () => { + const item = MY_COLLECTION.findById(1); + + expect(item instanceof State).to.eq(true, 'item is instanceof State') + expect(JSON.stringify(item?.value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'item has correct value'); + }); + + it('Can\'t findById not existing item', () => { + const item = MY_COLLECTION.findById(5); + + expect(item).to.eq(undefined, 'item is undefined') + }); +}); diff --git a/packages/agile-core/tests/collection/functions/getGroup.function.spec.ts b/packages/agile-core/tests/collection/functions/getGroup.function.spec.ts new file mode 100644 index 00000000..a49c5a09 --- /dev/null +++ b/packages/agile-core/tests/collection/functions/getGroup.function.spec.ts @@ -0,0 +1,44 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import Group from "../../../src/collection/group"; + +describe('getGroup Function Tests', () => { + // Define Agile + const App = new Agile(); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection({ + groups: ['group1', 'group2'] + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); + expect(MY_COLLECTION.groups['group2'] instanceof Group).to.eq(true, 'MY_COLLECTION group2 Group has been created'); + }); + + it('Can get Group which exists', () => { + // Get Group + const myGroup = MY_COLLECTION.getGroup('group1'); + + expect(myGroup instanceof Group).to.eq(true, 'myGroup is a group'); + expect(myGroup.key).to.eq('group1', 'myGroup has correct key'); + expect(myGroup.exists).to.eq(true, 'myGroup does exist'); + }); + + it('Gets dummy Group, if trying to get a non existing group', () => { + // Get Group + const myGroup = MY_COLLECTION.getGroup('group3'); + + expect(myGroup instanceof Group).to.eq(true, 'myGroup is a group'); + expect(myGroup.key).to.eq('dummy', 'myGroup has correct key'); + expect(myGroup.exists).to.eq(false, 'group3 doesn\'t exist'); + }); +}); diff --git a/packages/agile-core/tests/collection/functions/getSelector.function.spec.ts b/packages/agile-core/tests/collection/functions/getSelector.function.spec.ts new file mode 100644 index 00000000..4c19ddfd --- /dev/null +++ b/packages/agile-core/tests/collection/functions/getSelector.function.spec.ts @@ -0,0 +1,42 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import Selector from "../../../src/collection/selector"; + +describe('getSelector Function Tests', () => { + // Define Agile + const App = new Agile(); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection({ + selectors: ['selector1', 'selector2'] + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 Selector has been created'); + expect(MY_COLLECTION.selectors['selector2'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector2 Selector has been created'); + }); + + it('Can get Selector which exists', () => { + // Get Selector + const mySelector = MY_COLLECTION.getSelector('selector1'); + + expect(mySelector instanceof Selector).to.eq(true, 'mySelector is a Selector'); + expect(mySelector?.key).to.eq('selector1', 'mySelector has correct key'); + expect(mySelector?.exists).to.eq(false, 'mySelector doesn\'t exist because it has no value'); + expect(mySelector?.value).to.eq(undefined, 'mySelector has correct value'); + }); + + it('Can\'t get Selector which doesn\'t exist', () => { + // Get Selector + const mySelector = MY_COLLECTION.getSelector('selector3'); + + expect(mySelector instanceof Selector).to.eq(false, 'mySelector is undefined'); + }); +}); diff --git a/packages/agile-core/tests/collection/functions/getValueById.function.spec.ts b/packages/agile-core/tests/collection/functions/getValueById.function.spec.ts new file mode 100644 index 00000000..0eff6acb --- /dev/null +++ b/packages/agile-core/tests/collection/functions/getValueById.function.spec.ts @@ -0,0 +1,37 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; + +describe('GetValueById Function Tests', () => { + // Define Agile + const App = new Agile(); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(); + MY_COLLECTION.collect({id: 1, name: 'jeff'}); + MY_COLLECTION.collect({id: 2, name: 'hans'}); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'MY_COLLECTION has correct data'); + expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({id: 2, name: 'hans'}), 'MY_COLLECTION has correct data'); + expect(MY_COLLECTION.size).to.eq(2, 'MY_COLLECTION has correct size'); + }); + + it('Can getValueById', () => { + const item = MY_COLLECTION.getValueById(1); + + expect(JSON.stringify(item)).to.eq(JSON.stringify({id: 1, name: 'jeff'}), 'item has correct value'); + }); + + it('Can\'t getValueById with not existing item id', () => { + const item = MY_COLLECTION.findById(5); + + expect(item).to.eq(undefined, 'item is undefined') + }); +}); diff --git a/packages/agile-core/tests/collection/functions/remove.function.spec.ts b/packages/agile-core/tests/collection/functions/remove.function.spec.ts new file mode 100644 index 00000000..75e12a70 --- /dev/null +++ b/packages/agile-core/tests/collection/functions/remove.function.spec.ts @@ -0,0 +1,224 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; +import Item from "../../../src/collection/item"; + +describe('Remove Function Tests', () => { + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + describe('Remove Function \'removeFromGroups\'', () => { + let rerenderCount = 0; + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group([1, 2, 3]), + group2: collection.Group([1, 2, 3]) + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myGroup1, myGroup2] = useAgile([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { + rerenderCount++; + }); + + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group2 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION data contains item with id 1'); + expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ + id: 2, + name: 'hans' + }), 'MY_COLLECTION data contains item with id 2'); + expect(JSON.stringify(MY_COLLECTION.data[3].value)).to.eq(JSON.stringify({ + id: 3, + name: 'frank' + }), 'MY_COLLECTION data contains item with id 3'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); + }); + + it('Can remove item which exist', async () => { + // Remove item + MY_COLLECTION.remove(1).fromGroups('group1'); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 3]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group2 has correct value'); + expect(MY_COLLECTION.data[1] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 1'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can remove items which exist', async () => { + // Remove items + MY_COLLECTION.remove([2, 3]).fromGroups(['group1', 'group2']); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1]), 'group2 has correct value'); + expect(MY_COLLECTION.data[2] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 2'); + expect(MY_COLLECTION.data[3] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 3'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t remove item which doesn\'t exist', async () => { + // Remove item + MY_COLLECTION.remove(5).fromGroups('group1'); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + + it('Can\'t remove item which doesn\'t exist in group', async () => { + // Remove item + MY_COLLECTION.remove(1).fromGroups('group1'); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); + expect(MY_COLLECTION.data[1] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 1'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + + it('Can\'t remove item from not existing group', async () => { + // Remove item + MY_COLLECTION.remove(2).fromGroups('notExisting'); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.data[2] instanceof Item).to.eq(true, 'MY_COLLECTION has item with id 2'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + }); + + describe('Remove Function \'everywhere\'', () => { + let rerenderCount = 0; + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group([1, 2, 3]), + group2: collection.Group([1, 2, 3]) + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myGroup1, myGroup2] = useAgile([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { + rerenderCount++; + }); + + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group2 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION data contains item with id 1'); + expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ + id: 2, + name: 'hans' + }), 'MY_COLLECTION data contains item with id 2'); + expect(JSON.stringify(MY_COLLECTION.data[3].value)).to.eq(JSON.stringify({ + id: 3, + name: 'frank' + }), 'MY_COLLECTION data contains item with id 3'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); + }); + + it('Can remove item which exist', async () => { + // Remove item + MY_COLLECTION.remove(1).everywhere(); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 3]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([2, 3]), 'group2 has correct value'); + expect(MY_COLLECTION.data[1] instanceof Item).to.eq(false, 'MY_COLLECTION hasn\'t item with id 1'); + expect(MY_COLLECTION.size).to.eq(2, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can remove items which exist', async () => { + // Remove items + MY_COLLECTION.remove([2, 3]).everywhere(); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group2'].value)).to.eq(JSON.stringify([]), 'group2 has correct value'); + expect(MY_COLLECTION.data[2] instanceof Item).to.eq(false, 'MY_COLLECTION hasn\'t item with id 2'); + expect(MY_COLLECTION.data[3] instanceof Item).to.eq(false, 'MY_COLLECTION hasn\'t item with id 3'); + expect(MY_COLLECTION.size).to.eq(0, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t remove item which doesn\'t exist', async () => { + // Remove item + MY_COLLECTION.remove(5).everywhere(); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.size).to.eq(0, 'MY_COLLECTION has correct size'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + }); +}); diff --git a/packages/agile-core/tests/collection/functions/update.function.spec.ts b/packages/agile-core/tests/collection/functions/update.function.spec.ts new file mode 100644 index 00000000..a57986c3 --- /dev/null +++ b/packages/agile-core/tests/collection/functions/update.function.spec.ts @@ -0,0 +1,222 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; +import Group from "../../../src/collection/group"; + +describe('Update Function Tests', () => { + let rerenderCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + // Object Interface + interface userInterface { + id: number + name: string + age?: number + } + + // Create Collection + const MY_COLLECTION = App.Collection(); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myHookCollection] = useAgile([MY_COLLECTION], () => { + rerenderCount++; + }); + + // Collect some items + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'jamie'}, {id: 3, name: 'hans'}]) + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created') + expect(MY_COLLECTION.groups['default']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); + expect(MY_COLLECTION.size).to.eq(3, 'MY_COLLECTION has correct size'); + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION item at id 1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ + id: 2, + name: 'jamie' + }), 'MY_COLLECTION item at id 2 has correct value'); + expect(JSON.stringify(MY_COLLECTION.data[3].value)).to.eq(JSON.stringify({ + id: 3, + name: 'hans' + }), 'MY_COLLECTION item at id 3 has correct value'); + + expect(JSON.stringify(myHookCollection)).to.eq(JSON.stringify([]), 'myHookState has correct MY_COLLECTION value'); + expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); + }); + + it('Can update Item', async () => { + // Update Item + MY_COLLECTION.update(1, {name: 'updatedJeff'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ + id: 1, + name: 'updatedJeff' + }), 'MY_COLLECTION data at id 1 has updated'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can update Item and primaryKey', async () => { + // Update Item + MY_COLLECTION.update(3, {id: 4, name: 'updatedHans'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[4]?.value)).to.eq(JSON.stringify({ + id: 4, + name: 'updatedHans' + }), 'MY_COLLECTION data switched from id 3 to id 4 and has updated'); + expect(MY_COLLECTION.data[3]).to.eq(undefined, 'MY_COLLECTION item at id 3 doesn\'t exist anymore'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items'); + expect(MY_COLLECTION.groups["default"].value.findIndex(value => value === 3) !== -1).to.eq(false, 'MY_COLLECTION item with id 3 doesn\'t exist in default group anymore'); + expect(MY_COLLECTION.groups["default"].value.findIndex(value => value === 4) !== -1).to.eq(true, 'MY_COLLECTION item with id 3 does exist in default group'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t update not existing Item', async () => { + // Update Item + MY_COLLECTION.update(5, {name: 'updatedName'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has stayed the same'); + }); + + it('Can\'t update Item with the same value', async () => { + // Update Item + MY_COLLECTION.update(1, {name: 'updatedJeff'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[1]?.value)).to.eq(JSON.stringify({ + id: 1, + name: 'updatedJeff' + }), 'MY_COLLECTION data at id 1 stayed the same'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') + + expect(rerenderCount).to.eq(3, 'rerenderCount has stayed the same'); + }); + + it('Can\'t update Item with non object changes', async () => { + // Update Item + // @ts-ignore + MY_COLLECTION.update(1, 'hi'); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has stayed the same'); + }); + + describe('Test background option', () => { + it('Does call callBackFunction by updating Item with background = false', async () => { + // Update Item + MY_COLLECTION.update(2, {name: 'updatedJamie'}, {background: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ + id: 2, + name: 'updatedJamie' + }), 'MY_COLLECTION data at id 2 has updated'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') + + expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); + }); + + it('Doesn\'t call callBackFunction by updating Item with background = true', async () => { + // Update Item + MY_COLLECTION.update(4, {id: 4, name: 'updatedHans2'}, {background: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[4]?.value)).to.eq(JSON.stringify({ + id: 4, + name: 'updatedHans2' + }), 'MY_COLLECTION data at id 4 has updated'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') + + expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); + }); + + it('Doesn\'t call callBackFunction by updating Item and primaryKey with background = true', async () => { + // Update Item + MY_COLLECTION.update(4, {id: 3, name: 'updatedHans3'}, {background: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[3]?.value)).to.eq(JSON.stringify({ + id: 3, + name: 'updatedHans3' + }), 'MY_COLLECTION data switched from id 4 to id 3 and has updated'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') + + expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); + }); + }); + + describe('Test addNewProperties option', () => { + it('Doesn\'t add property to value with addNewProperties = false', async () => { + // Update Item + MY_COLLECTION.update(2, {name: 'updatedJamie2', age: 10}, {addNewProperties: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ + id: 2, + name: 'updatedJamie2' + }), 'MY_COLLECTION data at id 2 has updated'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') + + expect(rerenderCount).to.eq(5, 'rerenderCount has been increased by 1'); + }); + + + it('Does add property to value with addNewProperties = true', async () => { + // Update Item + MY_COLLECTION.update(2, {name: 'updatedJamie3', age: 20}, {addNewProperties: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.data[2]?.value)).to.eq(JSON.stringify({ + id: 2, + name: 'updatedJamie3', + age: 20 + }), 'MY_COLLECTION data at id 2 has updated'); + expect(Object.keys(MY_COLLECTION.data).length).to.eq(3, 'MY_COLLECTION has still all items') + + expect(rerenderCount).to.eq(6, 'rerenderCount has been increased by 1'); + }); + }); +}); diff --git a/packages/agile-core/tests/collection/group/default.spec.ts b/packages/agile-core/tests/collection/group/default.spec.ts new file mode 100644 index 00000000..0648464c --- /dev/null +++ b/packages/agile-core/tests/collection/group/default.spec.ts @@ -0,0 +1,183 @@ +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; +import {expect} from "chai"; +import Group from "../../../src/collection/group"; + +describe('Default Group Tests', () => { + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + } + }); + + describe('Group', () => { + let rerenderCount = 0; + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group() + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); + expect(MY_COLLECTION.groups['default']?.dep.subs.size === 0).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([]), 'default Group has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([]), 'default Group has correct initial output'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([]), 'default Group has correct initial states'); + expect(MY_COLLECTION.groups['default'].key).to.eq('default', 'group1 Group has correct initial key'); + + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); + expect(MY_COLLECTION.groups['group1']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION group1 Group has correct subs size'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 Group has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 Group has correct initial output'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([]), 'group1 Group has correct initial states'); + expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 Group has correct initial key'); + + expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); + expect(rerenderCount).to.eq(0, 'rerenderCount has correct value'); + }); + + it('Has correct values after collecting items', async () => { + // Collect Data + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([1, 2, 3]), 'default Group has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'} + ]), 'default Group has correct output'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([ + MY_COLLECTION.findById(1), + MY_COLLECTION.findById(2), + MY_COLLECTION.findById(3) + ]), 'default Group has correct states'); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 Group has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 Group has correct output'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([]), 'group1 Group has correct states'); + + expect(rerenderCount).to.eq(0, 'rerenderCount stayed the same'); + }); + }); + + describe('Group with initial values', () => { + let rerenderCount = 0; + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group([1, 2, 3]) + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['default'] instanceof Group).to.eq(true, 'MY_COLLECTION default Group has been created'); + expect(MY_COLLECTION.groups['default']?.dep.subs.size === 0).to.eq(true, 'MY_COLLECTION default Group has correct subs size'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([]), 'default has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([]), 'default has correct initial output'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([]), 'default has correct initial states'); + expect(MY_COLLECTION.groups['default'].key).to.eq('default', 'default Group has correct initial key'); + + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); + expect(MY_COLLECTION.groups['group1']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION group1 Group has correct subs size'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 Group has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 Group has correct initial output'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([]), 'group1 Group has correct initial states'); + expect(MY_COLLECTION.groups['group1'].key).to.eq('group1', 'group1 Group has correct initial key'); + + expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); + expect(rerenderCount).to.eq(0, 'rerenderCount has correct value'); + }); + + it('Has correct values after collecting items', async () => { + // Collect Data + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}, {id: 3, name: 'frank'}]); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['default'].value)).to.eq(JSON.stringify([1, 2, 3]), 'default has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].output)).to.eq(JSON.stringify([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'} + ]), 'default has correct output'); + expect(JSON.stringify(MY_COLLECTION.groups['default'].states)).to.eq(JSON.stringify([ + MY_COLLECTION.findById(1), + MY_COLLECTION.findById(2), + MY_COLLECTION.findById(3) + ]), 'default has correct states'); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'} + ]), 'group1 has correct output'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].states)).to.eq(JSON.stringify([ + MY_COLLECTION.findById(1), + MY_COLLECTION.findById(2), + MY_COLLECTION.findById(3) + ]), 'group1 has correct states'); + + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + }); + }); + + describe('Group with key', () => { + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group([], {key: 'mywierdgroup'}) + } + }) + ); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); + expect(MY_COLLECTION.groups['group1'].key).to.eq('mywierdgroup', 'group1 has correct key'); + }); + }); +}); diff --git a/packages/agile-core/tests/collection/group/functions/add.function.spec.ts b/packages/agile-core/tests/collection/group/functions/add.function.spec.ts new file mode 100644 index 00000000..0db013f6 --- /dev/null +++ b/packages/agile-core/tests/collection/group/functions/add.function.spec.ts @@ -0,0 +1,256 @@ +import Agile from "../../../../src"; +import {useAgile} from "../../../../src/integrations/test"; +import {expect} from "chai"; +import Group from "../../../../src/collection/group"; + +describe('Add function Tests', () => { + let rerenderCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + } + }); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group([2]) + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + rerenderCount++; + }); + + MY_COLLECTION.collect([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'}, + {id: 6, name: 'livia'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'} + ]); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'} + ]), 'group1 has correct output'); + + expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); + expect(rerenderCount).to.eq(1, 'rerenderCount has been correct value'); + }); + + it('Can add Group', async () => { + MY_COLLECTION.groups['group1'].add(1); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'} + ]), 'group1 has correct output'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].notFoundPrimaryKeys)).to.eq(JSON.stringify([]), 'group1 has correct notFoundPrimaryKeys'); + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can add multiple Groups', async () => { + MY_COLLECTION.groups['group1'].add([7, 8]); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'} + ]), 'group1 has correct output'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].notFoundPrimaryKeys)).to.eq(JSON.stringify([]), 'group1 has correct notFoundPrimaryKeys'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t add item to Group which already exists', async () => { + MY_COLLECTION.groups['group1'].add(1); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + + it('Can add item to Group which doesn\'t exist in collection', async () => { + MY_COLLECTION.groups['group1'].add(100); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'} + ]), 'group1 has correct output'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].notFoundPrimaryKeys)).to.eq(JSON.stringify([100]), 'group1 has correct notFoundPrimaryKeys'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same because output won\'t change -> rerender not necessary'); + }); + + describe('Test background option', () => { + it('Does call callBackFunction by adding Item to group with background = false', async () => { + MY_COLLECTION.groups['group1'].add(3, {background: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100, 3]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'}, + {id: 3, name: 'frank'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); + }); + + it('Doesn\'t call callBackFunction by adding Item to group with background = true', async () => { + MY_COLLECTION.groups['group1'].add(4, {background: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100, 3, 4]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); + }); + }); + + describe('Test method option', () => { + it('Does add the item at the end of the group with method = \'push\'', async () => { + MY_COLLECTION.groups['group1'].add(5, {method: 'push'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 1, 7, 8, 100, 3, 4, 5]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(5, 'rerenderCount has been increased by 1'); + }); + + it('Does add the item at the start of the group with method = \'unshift\'', async () => { + MY_COLLECTION.groups['group1'].add(6, {method: 'unshift'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([6, 2, 1, 7, 8, 100, 3, 4, 5]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 6, name: 'livia'}, + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(6, 'rerenderCount has been increased by 1'); + }); + }); + + describe('Test overwrite option', () => { + it('Leave existing item at current position and doesn\'t overwrite it with overwrite = false', async () => { + MY_COLLECTION.groups['group1'].add(3, {overwrite: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([6, 2, 1, 7, 8, 100, 3, 4, 5]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 6, name: 'livia'}, + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(6, 'rerenderCount stayed the same'); + }); + + it('Overwrites existing item and add it at new position with overwrite = true', async () => { + MY_COLLECTION.groups['group1'].add(3, {overwrite: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([6, 2, 1, 7, 8, 100, 4, 5, 3]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 6, name: 'livia'}, + {id: 2, name: 'hans'}, + {id: 1, name: 'jeff'}, + {id: 7, name: 'joshi'}, + {id: 8, name: 'günter'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'}, + {id: 3, name: 'frank'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(7, 'rerenderCount has been increased by 1'); + }); + }); +}); diff --git a/packages/agile-core/tests/collection/group/functions/has.function.spec.ts b/packages/agile-core/tests/collection/group/functions/has.function.spec.ts new file mode 100644 index 00000000..aa0fd782 --- /dev/null +++ b/packages/agile-core/tests/collection/group/functions/has.function.spec.ts @@ -0,0 +1,60 @@ +import Agile from "../../../../src"; +import {expect} from "chai"; +import Group from "../../../../src/collection/group"; + +describe('Has function Tests', () => { + // Define Agile + const App = new Agile(); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group([1, 2, 3]) + } + }) + ); + + MY_COLLECTION.collect([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'} + ]); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'} + ]), 'group1 has correct output'); + }); + + it('Can use has function', () => { + const has = MY_COLLECTION.groups['group1'].has(1); + + expect(has).to.eq(true); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); + }); + + it('Can use has function with not existing primaryKey in collection and group', () => { + const has = MY_COLLECTION.groups['group1'].has(100); + + expect(has).to.eq(false); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); + }); + + it('Can use has function with not existing primaryKey in group', () => { + const has = MY_COLLECTION.groups['group1'].has(4); + + expect(has).to.eq(false); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3]), 'group1 has correct initial value'); + }); +}); diff --git a/packages/agile-core/tests/collection/group/functions/remove.function.spec.ts b/packages/agile-core/tests/collection/group/functions/remove.function.spec.ts new file mode 100644 index 00000000..b09478b1 --- /dev/null +++ b/packages/agile-core/tests/collection/group/functions/remove.function.spec.ts @@ -0,0 +1,137 @@ +import Agile from "../../../../src"; +import {useAgile} from "../../../../src/integrations/test"; +import {expect} from "chai"; +import Group from "../../../../src/collection/group"; + +describe('Add function Tests', () => { + let rerenderCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + } + }); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + groups: { + group1: collection.Group([1, 2, 3, 4, 5]) + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + rerenderCount++; + }); + + MY_COLLECTION.collect([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.groups['group1'] instanceof Group).to.eq(true, 'MY_COLLECTION group1 Group has been created'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([1, 2, 3, 4, 5]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 1, name: 'jeff'}, + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(JSON.stringify(myGroup1)).to.eq(JSON.stringify([]), 'myGroup1 has correct MY_COLLECTION group1 value'); + expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); + }); + + it('Can remove item which exists', async () => { + MY_COLLECTION.groups['group1'].remove(1); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([2, 3, 4, 5]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 2, name: 'hans'}, + {id: 3, name: 'frank'}, + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can remove multiple items which exist', async () => { + MY_COLLECTION.groups['group1'].remove([2, 3]); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([4, 5]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t remove item which doesn\'t exist', async () => { + MY_COLLECTION.groups['group1'].remove(100); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([4, 5]), 'group1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 4, name: 'gina'}, + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + + describe('Test background option', () => { + it('Does call callBackFunction by removing Item from group with background = false', async () => { + MY_COLLECTION.groups['group1'].remove(4, {background: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([5]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([ + {id: 5, name: 'tabea'} + ]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); + }); + + it('Doesn\'t call callBackFunction by removing Item from group with background = true', async () => { + MY_COLLECTION.groups['group1'].remove(5, {background: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_COLLECTION.groups['group1'].value)).to.eq(JSON.stringify([]), 'group1 has correct value'); + expect(JSON.stringify(MY_COLLECTION.groups['group1'].output)).to.eq(JSON.stringify([]), 'group1 has correct output'); + + expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); + }); + }); +}); diff --git a/packages/agile-core/tests/collection/selector/default.spec.ts b/packages/agile-core/tests/collection/selector/default.spec.ts new file mode 100644 index 00000000..44eceaa8 --- /dev/null +++ b/packages/agile-core/tests/collection/selector/default.spec.ts @@ -0,0 +1,118 @@ +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; +import {expect} from "chai"; +import Selector from "../../../src/collection/selector"; +import Item from "../../../src/collection/item"; + +describe('Default Selector Tests', () => { + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + } + }); + + describe('Selector', () => { + let rerenderCount = 0; + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + selectors: { + selector1: collection.Selector(1) + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [mySelector1] = useAgile([MY_COLLECTION.getSelector('selector1')], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 Selector has been created'); + expect(MY_COLLECTION.selectors['selector1']?.dep.subs.size === 1).to.eq(true, 'MY_COLLECTION selector1 Selector has correct subs size'); + expect(MY_COLLECTION.selectors['selector1'].key).to.eq('selector1', 'selector1 Selector has correct initial key'); + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(1, 'selector1 Selector has correct initial id'); + expect(MY_COLLECTION.selectors['selector1'].exists).to.eq(false, 'selector1 Selector doesn\'t exist'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify(undefined), 'selector1 Selector has correct initial value'); + + expect(MY_COLLECTION.data[1] instanceof Item).to.eq(true, 'MY_COLLECTION data at id 1 has been created'); + expect(MY_COLLECTION.data[1].exists).to.eq(false, 'MY_COLLECTION data at id 1 doesn\'t exist'); + expect(MY_COLLECTION.data[1].key).to.eq(1, 'MY_COLLECTION data at id 1 has correct initial key'); + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ + id: 1 + }), 'MY_COLLECTION data at id 1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.data[1].initialState)).to.eq(JSON.stringify({ + id: 1 + }), 'MY_COLLECTION data at id 1 has correct initialState'); + expect(JSON.stringify(MY_COLLECTION.data[1].previousState)).to.eq(JSON.stringify({ + id: 1 + }), 'MY_COLLECTION data at id 1 has correct initialState'); + + expect(JSON.stringify(mySelector1)).to.eq(JSON.stringify(undefined), 'mySelector1 has correct MY_COLLECTION selector1 value'); + expect(rerenderCount).to.eq(0, 'rerenderCount has correct value'); + }); + + it('Has correct values after collecting items', async () => { + // Collect Data + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.selectors['selector1'].exists).to.eq(true, 'selector1 Selector exists'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'selector1 Selector has correct initial value'); + + expect(MY_COLLECTION.data[1].exists).to.eq(true, 'MY_COLLECTION data at id 1 exists'); + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION data at id 1 has correct initial value'); + expect(JSON.stringify(MY_COLLECTION.data[1].initialState)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION data at id 1 has correct initialState'); + expect(JSON.stringify(MY_COLLECTION.data[1].previousState)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION data at id 1 has correct initialState'); + + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + }); + }); + + describe('Selector with key', () => { + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + selectors: { + selector1: collection.Selector(1, {key: 'mywierdselector'}) + } + }) + ); + + it('Has correct initial values', () => { + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'MY_COLLECTION selector1 Selector has been created'); + expect(MY_COLLECTION.selectors['selector1'].key).to.eq('mywierdselector', 'selector1 has correct key'); + }); + }); +}); diff --git a/packages/agile-core/tests/collection/selector/functions/select.function.spec.ts b/packages/agile-core/tests/collection/selector/functions/select.function.spec.ts new file mode 100644 index 00000000..d572eb22 --- /dev/null +++ b/packages/agile-core/tests/collection/selector/functions/select.function.spec.ts @@ -0,0 +1,147 @@ +import Agile from "../../../../src"; +import {useAgile} from "../../../../src/integrations/test"; +import {expect} from "chai"; +import Selector from "../../../../src/collection/selector"; +import Item from "../../../../src/collection/item"; + +describe('select Function Tests', () => { + let rerenderCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + } + }); + + // Object Interface + interface userInterface { + id: number + name: string + } + + // Create Collection + const MY_COLLECTION = App.Collection(collection => ({ + selectors: { + selector1: collection.Selector(1) + } + }) + ); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [mySelector1] = useAgile([MY_COLLECTION.getSelector('selector1')], () => { + rerenderCount++; + }); + + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); + + it('Has initial value', () => { + expect(MY_COLLECTION.selectors['selector1'] instanceof Selector).to.eq(true, 'selector1 Selector exists'); + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(1, 'selector1 Selector is watching correct id'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'selector1 Selector has correct initial value'); + + expect(JSON.stringify(MY_COLLECTION.data[1].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_COLLECTION at id 1 has correct data'); + expect(JSON.stringify(MY_COLLECTION.data[2].value)).to.eq(JSON.stringify({ + id: 2, + name: 'hans' + }), 'MY_COLLECTION at id 2 has correct data'); + + expect(JSON.stringify(mySelector1)).to.eq(JSON.stringify(undefined), 'mySelector1 has correct MY_COLLECTION selector1 value'); + expect(rerenderCount).to.eq(1, 'rerenderCount has correct value'); + }); + + it('Can select another id which doesn\'t exist', async () => { + MY_COLLECTION.selectors['selector1'].select(100); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(100, 'selector1 Selector is watching correct id'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify(undefined), 'selector1 Selector has correct value'); + + expect(MY_COLLECTION.data[100] instanceof Item).to.eq(true, 'MY_COLLECTION at id 100 has been created as placeholder.. to hold connection'); + expect(JSON.stringify(MY_COLLECTION.data[100].value)).to.eq(JSON.stringify({ + id: 100, + }), 'MY_COLLECTION at id 100 has correct value'); + expect(MY_COLLECTION.data[100].exists).to.eq(false, 'MY_COLLECTION at id 100 doesn\'t exist'); + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can select another id', async () => { + MY_COLLECTION.selectors['selector1'].select(2); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(2, 'selector1 Selector is watching correct id'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ + id: 2, + name: 'hans' + }), 'selector1 Selector has correct value'); + + expect(MY_COLLECTION.data[100] instanceof Item).to.eq(false, 'MY_COLLECTION at id 100 has been removed'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t select the same id', async () => { + MY_COLLECTION.selectors['selector1'].select(2); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(2, 'selector1 Selector is watching correct id'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ + id: 2, + name: 'hans' + }), 'selector1 Selector has correct value'); + + expect(MY_COLLECTION.data[100] instanceof Item).to.eq(false, 'MY_COLLECTION at id 100 has been removed'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + + describe('Test background option', () => { + it('Does call callBackFunction by selecting new id with background = false', async () => { + MY_COLLECTION.selectors['selector1'].select(1, {background: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(1, 'selector1 Selector is watching correct id'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'selector1 Selector has correct value'); + + expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); + }); + + it('Doesn\'t call callBackFunction by selecting new id with background = true', async () => { + MY_COLLECTION.selectors['selector1'].select(2, {background: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COLLECTION.selectors['selector1'].id).to.eq(2, 'selector1 Selector is watching correct id'); + expect(JSON.stringify(MY_COLLECTION.selectors['selector1'].value)).to.eq(JSON.stringify({ + id: 2, + name: 'hans' + }), 'selector1 Selector has correct value'); + + expect(rerenderCount).to.eq(4, 'rerenderCount stayed the same'); + }); + }); +}); diff --git a/packages/agile-core/tests/computed/default.spec.ts b/packages/agile-core/tests/computed/default.spec.ts new file mode 100644 index 00000000..66fa7049 --- /dev/null +++ b/packages/agile-core/tests/computed/default.spec.ts @@ -0,0 +1,152 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../src"; +import Computed from "../../src/computed"; +import {useAgile} from "../../src/integrations/test"; + +describe('Default Computed Tests', () => { + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + interface userInterface { + id: number + name: string + } + + describe('Computed', () => { + let computedCallCount = 0; + let rerenderCount = 0; + + // Create State + const MY_STATE = App.State('hello'); + const MY_STATE_2 = App.State('bye'); + + // Create Collection + const MY_COLLECTION = App.Collection({ + groups: ['group1', 'group2'], + selectors: ['selector1', 'selector2'] + }); + + // Create Selectors + const MY_SELECTOR = MY_COLLECTION.getSelector('selector1')?.select(1); + + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); + + // Create Computed + const MY_COMPUTED = App.Computed(() => { + computedCallCount++; + return `${MY_STATE.value}_${MY_STATE_2.value}_${MY_SELECTOR?.value?.name}_${MY_COLLECTION.findById(2)?.value.name}` + }); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myComputed] = useAgile([MY_COMPUTED], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_COMPUTED instanceof Computed).to.eq(true, 'MY_COMPUTED is computed'); + expect(MY_COMPUTED.key).to.eq(undefined, 'MY_COMPUTED has correct initial key'); + expect(MY_COMPUTED.value).to.eq('hello_bye_jeff_hans', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE, MY_STATE_2, MY_SELECTOR, MY_COLLECTION.findById(2)]), 'MY_COMPUTED has correct deps'); + expect(computedCallCount).to.eq(2, 'computedCallCount has correct initial value'); + expect(rerenderCount).to.eq(0, 'rerenderCount has correct initial value'); + }); + + it('Does call computed Function if updating item', async () => { + // Update State + MY_STATE_2.set('hehe'); + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('hello_hehe_jeff_hans', 'MY_COMPUTED has correct value'); + expect(computedCallCount).to.eq(3, 'computedCallCount has been increased by 1'); + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + + // Update Collection + MY_COLLECTION.update(2, {name: 'test'}) + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('hello_hehe_jeff_test', 'MY_COMPUTED has correct value'); + expect(computedCallCount).to.eq(4, 'computedCallCount has been increased by 1'); + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + + // Update Collection + MY_COLLECTION.update(1, {name: 'fun'}) + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('hello_hehe_fun_test', 'MY_COMPUTED has correct value'); + expect(computedCallCount).to.eq(5, 'computedCallCount has been increased by 1'); + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + }); + + describe('Computed with initial subs', () => { + let computedCallCount = 0; + let rerenderCount = 0; + + // Create State + const MY_STATE = App.State('hello'); + const MY_STATE_2 = App.State('bye'); + const MY_STATE_3 = App.State('test'); + + // Create Collection + const MY_COLLECTION = App.Collection({ + groups: ['group1', 'group2'], + selectors: ['selector1', 'selector2'] + }); + + // Create Selectors + const MY_SELECTOR = MY_COLLECTION.getSelector('selector1')?.select(1); + + MY_COLLECTION.collect([{id: 1, name: 'jeff'}, {id: 2, name: 'hans'}]); + + // Create Computed + const MY_COMPUTED = App.Computed(() => { + computedCallCount++; + return `${MY_STATE.value}_${MY_STATE_2.value}_${MY_SELECTOR?.value?.name}_${MY_COLLECTION.findById(2)?.value.name}` + }, [MY_STATE_3]); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myComputed] = useAgile([MY_COMPUTED], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_COMPUTED instanceof Computed).to.eq(true, 'MY_COMPUTED is computed'); + expect(MY_COMPUTED.key).to.eq(undefined, 'MY_COMPUTED has correct initial key'); + expect(MY_COMPUTED.value).to.eq('hello_bye_jeff_hans', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([MY_STATE_3]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_3, MY_STATE, MY_STATE_2, MY_SELECTOR, MY_COLLECTION.findById(2)]), 'MY_COMPUTED has correct deps'); + expect(computedCallCount).to.eq(2, 'computedCallCount has correct initial value'); + expect(rerenderCount).to.eq(0, 'rerenderCount has correct initial value'); + }); + + it('Does call computed Function if updating item', async () => { + // Update State + MY_STATE_3.set('changed'); + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE_3.value).to.eq('changed', 'MY_STATE_3 has correct value') + expect(MY_COMPUTED.value).to.eq('hello_bye_jeff_hans', 'MY_COMPUTED has correct value'); + expect(computedCallCount).to.eq(3, 'computedCallCount has been increased by 1'); + expect(rerenderCount).to.eq(0, 'rerenderCount stayed the same because computed hasn\'t changed'); + }); + }); +}); diff --git a/packages/agile-core/tests/computed/functions/updateComputeFunction.function.spec.ts b/packages/agile-core/tests/computed/functions/updateComputeFunction.function.spec.ts new file mode 100644 index 00000000..d8140da3 --- /dev/null +++ b/packages/agile-core/tests/computed/functions/updateComputeFunction.function.spec.ts @@ -0,0 +1,130 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import Computed from "../../../src/computed"; +import {useAgile} from "../../../src/integrations/test"; + +describe('updateComputeFunction Function tests', () => { + let rerenderCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + // Create State + const MY_STATE = App.State('hello'); + const MY_STATE_2 = App.State('bye'); + const MY_STATE_3 = App.State('jeff'); + const MY_STATE_4 = App.State('hans'); + + // Create Computed + const MY_COMPUTED = App.Computed(() => { + return `${MY_STATE.value}_${MY_STATE_2.value}` + }); + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myComputed] = useAgile([MY_COMPUTED], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_COMPUTED instanceof Computed).to.eq(true, 'MY_COMPUTED is computed'); + expect(MY_COMPUTED.key).to.eq(undefined, 'MY_COMPUTED has correct initial key'); + expect(MY_COMPUTED.value).to.eq('hello_bye', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE, MY_STATE_2]), 'MY_COMPUTED has correct deps'); + + expect(myComputed).to.eq('hello_bye', 'myComputed has correct initial value'); + expect(rerenderCount).to.eq(0, 'rerenderCount has correct initial value'); + }); + + it('Can update compute Function', async () => { + // Update compute Function + MY_COMPUTED.updateComputeFunction(() => { + return `${MY_STATE_3.value}_${MY_STATE_4.value}` + }); + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('jeff_hans', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_3, MY_STATE_4]), 'MY_COMPUTED has correct deps'); + + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + }); + + it('Can update compute Function with hardCodedDeps', async () => { + // Update compute Function + MY_COMPUTED.updateComputeFunction(() => { + return `${MY_STATE_2.value}_${MY_STATE_3.value}` + }, [MY_STATE_4]); + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('bye_jeff', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([MY_STATE_4]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_4, MY_STATE_2, MY_STATE_3]), 'MY_COMPUTED has correct deps'); + + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t update compute Function with the same value', async () => { + // Update compute Function + MY_COMPUTED.updateComputeFunction(() => { + return `${MY_STATE_2.value}_${MY_STATE_3.value}` + }, []); + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('bye_jeff', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_2, MY_STATE_3]), 'MY_COMPUTED has correct deps'); + + expect(rerenderCount).to.eq(2, 'rerenderCount stayed the same'); + }); + + describe('Test background option', () => { + it('Does call callBackFunction by updating computeFunction with background = false', async () => { + // Update compute Function + MY_COMPUTED.updateComputeFunction(() => { + return `${MY_STATE.value}_${MY_STATE_3.value}` + }, [], {background: false}); + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('hello_jeff', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE, MY_STATE_3]), 'MY_COMPUTED has correct deps'); + + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + + it('Doesn\'t call callBackFunction by updating computeFunction with background = true', async () => { + // Update compute Function + MY_COMPUTED.updateComputeFunction(() => { + return `${MY_STATE_4.value}_${MY_STATE_2.value}` + }, [], {background: true}); + + // Needs some time to call computed + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_COMPUTED.value).to.eq('hans_bye', 'MY_COMPUTED has correct value'); + expect(JSON.stringify(MY_COMPUTED.hardCodedDeps)).to.eq(JSON.stringify([]), 'MY_COMPUTED has correct hardCodedDeps'); + expect(JSON.stringify(MY_COMPUTED.deps)).to.eq(JSON.stringify([MY_STATE_4, MY_STATE_2]), 'MY_COMPUTED has correct deps'); + + expect(rerenderCount).to.eq(3, 'rerenderCount stayed the same'); + }); + }); +}); diff --git a/packages/agile-core/tests/event/default.spec.ts b/packages/agile-core/tests/event/default.spec.ts new file mode 100644 index 00000000..4154441f --- /dev/null +++ b/packages/agile-core/tests/event/default.spec.ts @@ -0,0 +1,191 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../src"; + +describe('Default Event Tests', () => { + // Define Agile + const App = new Agile(); + + interface EventPayload { + title: string + message: string + } + + describe('Event', () => { + // Create Event + const MY_EVENT = App.Event(); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.callbacks.size).to.eq(0, 'MY_EVENT has correct initial callback size'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + expect(MY_EVENT.key).to.eq(undefined, 'MY_EVENT has correct key'); + expect(MY_EVENT._key).to.eq(undefined, 'MY_EVENT has correct _key'); + }); + + it('Can change key', () => { + // Update key + MY_EVENT.key = 'myKey'; + + expect(MY_EVENT.key).to.eq('myKey', 'MY_EVENT has correct key'); + expect(MY_EVENT._key).to.eq('myKey', 'MY_EVENT has correct _key'); + }); + }); + + describe('Event with key', () => { + // Create Event + const MY_EVENT = App.Event({key: 'myKey'}); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true, key: 'myKey'}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.callbacks.size).to.eq(0, 'MY_EVENT has correct initial callback size'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + expect(MY_EVENT.key).to.eq('myKey', 'MY_EVENT has correct key'); + expect(MY_EVENT._key).to.eq('myKey', 'MY_EVENT has correct _key'); + }); + + it('Can change key', () => { + // Update key + MY_EVENT.key = 'myNewKey'; + + expect(MY_EVENT.key).to.eq('myNewKey', 'MY_EVENT has correct key'); + expect(MY_EVENT._key).to.eq('myNewKey', 'MY_EVENT has correct _key'); + }); + }); + + describe('Event with enabled = false', () => { + let eventCallCount = 0; + let currentEventPayload; + + // Create Event + const MY_EVENT = App.Event({enabled: false}); + + MY_EVENT.on((payload) => { + eventCallCount++; + currentEventPayload = payload; + }); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: false}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct initial callback size'); + expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); + + expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial value'); + expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); + }); + + it('Doesn\'t call event callbacks', () => { + // Trigger Event + MY_EVENT.trigger({title: 'test', message: 'messageTest'}); + + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); + expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); + + expect(eventCallCount).to.eq(0, 'eventCallCount stayed the same'); + expect(currentEventPayload).to.eq(undefined, 'currentEventPayload stayed the same'); + }); + }); + + describe('Event with delay', () => { + let eventCallCount = 0; + let currentEventPayload; + + // Create Event + const MY_EVENT = App.Event({delay: 1000}); + + MY_EVENT.on((payload) => { + eventCallCount++; + currentEventPayload = payload; + }); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true, delay: 1000}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct initial callback size'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + + expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial value'); + expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); + }); + + it('Does call callbacks with delay', async () => { + // Trigger Event + MY_EVENT.trigger({title: 'test', message: 'messageTest'}); + + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + + expect(eventCallCount).to.eq(0, 'eventCallCount stayed the same'); + expect(currentEventPayload).to.eq(undefined, 'currentEventPayload stayed the same'); + + // Wait one second + await new Promise(resolve => setTimeout(resolve, 1000)); + + expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + + expect(eventCallCount).to.eq(1, 'eventCallCount has been increased by 1'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test', message: 'messageTest'}), 'currentEventPayload has the correct value'); + }); + }); + + describe('Event with maxUses', () => { + let eventCallCount = 0; + let currentEventPayload; + + // Create Event + const MY_EVENT = App.Event({maxUses: 3}); + + MY_EVENT.on((payload) => { + eventCallCount++; + currentEventPayload = payload; + }); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true, maxUses: 3}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct initial callback size'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + + expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial value'); + expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); + }); + + it('Get disabled after 3 uses', () => { + // Trigger Event + MY_EVENT.trigger({title: 'test', message: 'messageTest'}); + + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); + expect(eventCallCount).to.eq(1, 'eventCallCount has been increased by 1'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test', message: 'messageTest'}), 'currentEventPayload has correct value'); + + // Trigger Event + MY_EVENT.trigger({title: 'test2', message: 'messageTest2'}); + + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + expect(MY_EVENT.uses).to.eq(2, 'MY_EVENT uses has been increased by 1'); + expect(eventCallCount).to.eq(2, 'eventCallCount has been increased by 1'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test2', message: 'messageTest2'}), 'currentEventPayload has correct value'); + + // Trigger Event + MY_EVENT.trigger({title: 'test3', message: 'messageTest3'}); + + expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT got disabled'); + expect(MY_EVENT.uses).to.eq(3, 'MY_EVENT uses has been increased by 1'); + expect(eventCallCount).to.eq(3, 'eventCallCount has been increased by 1'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test3', message: 'messageTest3'}), 'currentEventPayload has correct value'); + + // Trigger Event + MY_EVENT.trigger({title: 'test4', message: 'messageTest4'}); + + expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); + expect(MY_EVENT.uses).to.eq(3, 'MY_EVENT uses stayed the same'); + expect(eventCallCount).to.eq(3, 'eventCallCount stayed the same'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({title: 'test3', message: 'messageTest3'}), 'currentEventPayload stayed the same'); + }); + }); +}); diff --git a/packages/agile-core/tests/event/functions/disable.function.spec.ts b/packages/agile-core/tests/event/functions/disable.function.spec.ts new file mode 100644 index 00000000..96f402d9 --- /dev/null +++ b/packages/agile-core/tests/event/functions/disable.function.spec.ts @@ -0,0 +1,31 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; + +describe('Disable Function Tests', () => { + // Define Agile + const App = new Agile(); + + interface EventPayload { + title: string + message: string + } + + // Create Event + const MY_EVENT = App.Event(); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + }); + + it('Can disable Event', () => { + // Disable Event + MY_EVENT.disable(); + + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct config'); + expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); + }); +}); diff --git a/packages/agile-core/tests/event/functions/enable.function.spec.ts b/packages/agile-core/tests/event/functions/enable.function.spec.ts new file mode 100644 index 00000000..75f68673 --- /dev/null +++ b/packages/agile-core/tests/event/functions/enable.function.spec.ts @@ -0,0 +1,31 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; + +describe('Enable Function Tests', () => { + // Define Agile + const App = new Agile(); + + interface EventPayload { + title: string + message: string + } + + // Create Event + const MY_EVENT = App.Event({enabled: false}); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: false}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); + }); + + it('Can enable Event', () => { + // Enable Event + MY_EVENT.enable(); + + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses stayed the same'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: false}), 'MY_EVENT has correct config'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + }); +}); diff --git a/packages/agile-core/tests/event/functions/on.function.spec.ts b/packages/agile-core/tests/event/functions/on.function.spec.ts new file mode 100644 index 00000000..6047b2b3 --- /dev/null +++ b/packages/agile-core/tests/event/functions/on.function.spec.ts @@ -0,0 +1,47 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; + +describe('On Function Tests', () => { + let eventCallCount = 0; + let currentEventPayload; + + // Define Agile + const App = new Agile(); + + interface EventPayload { + title: string + message: string + } + + // Create Event + const MY_EVENT = App.Event(); + + MY_EVENT.on((payload) => { + eventCallCount++; + currentEventPayload = payload; + }); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.callbacks.size).to.eq(1, 'MY_EVENT has correct callbacks size'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + + expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial size'); + expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); + }); + + it('Does call on callback by triggering Event', async () => { + // Trigger Event + MY_EVENT.trigger({title: "Hello", message: "There"}); + + expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); + + expect(eventCallCount).to.eq(1, 'eventCallCount has been increased by 2'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({ + title: "Hello", + message: "There" + }), 'currentEventPayload has correct value'); + }); +}); diff --git a/packages/agile-core/tests/event/functions/reset.function.spec.ts b/packages/agile-core/tests/event/functions/reset.function.spec.ts new file mode 100644 index 00000000..18dead87 --- /dev/null +++ b/packages/agile-core/tests/event/functions/reset.function.spec.ts @@ -0,0 +1,36 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; + +describe('Reset Function Tests', () => { + // Define Agile + const App = new Agile(); + + interface EventPayload { + title: string + message: string + } + + // Create Event + const MY_EVENT = App.Event(); + + // Trigger and disable Event + MY_EVENT.trigger(); + MY_EVENT.trigger(); + MY_EVENT.disable(); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(2, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.enabled).to.eq(false, 'MY_EVENT is disabled'); + }); + + it('Can reset Event', () => { + // Reset Event + MY_EVENT.reset(); + + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has been reset'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct config'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + }); +}); diff --git a/packages/agile-core/tests/event/functions/trigger.function.spec.ts b/packages/agile-core/tests/event/functions/trigger.function.spec.ts new file mode 100644 index 00000000..78cc23e3 --- /dev/null +++ b/packages/agile-core/tests/event/functions/trigger.function.spec.ts @@ -0,0 +1,70 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useEvent} from "../../../src/integrations/test"; + +describe('Trigger Function Tests', () => { + let eventCallCount = 0; + let currentEventPayload; + + // Define Agile + const App = new Agile(); + + interface EventPayload { + title: string + message: string + } + + // Create Event + const MY_EVENT = App.Event(); + + MY_EVENT.on((payload) => { + eventCallCount++; + currentEventPayload = payload; + }); + + // @ts-ignore + useEvent(MY_EVENT, (payload => { + eventCallCount++; + currentEventPayload = payload; + })); + + it('Has correct initial value', () => { + expect(MY_EVENT.uses).to.eq(0, 'MY_EVENT uses has correct initial value'); + expect(JSON.stringify(MY_EVENT.config)).to.eq(JSON.stringify({enabled: true}), 'MY_EVENT has correct initial config'); + expect(MY_EVENT.callbacks.size).to.eq(2, 'MY_EVENT has correct callbacks size'); + expect(MY_EVENT.enabled).to.eq(true, 'MY_EVENT is enabled'); + + expect(eventCallCount).to.eq(0, 'eventCallCount has correct initial size'); + expect(currentEventPayload).to.eq(undefined, 'currentEventPayload has correct initial value'); + }); + + it('Can trigger enabled Event', async () => { + // Trigger Event + MY_EVENT.trigger({title: "Hello", message: "There"}); + + expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses has been increased by 1'); + + expect(eventCallCount).to.eq(2, 'eventCallCount has been increased by 2'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({ + title: "Hello", + message: "There" + }), 'currentEventPayload has correct value'); + }); + + it('Can\'t trigger disabled Event', async () => { + // Disable Event + MY_EVENT.enabled = false; + + // Trigger Event + MY_EVENT.trigger({title: "Hello", message: "There"}); + + expect(MY_EVENT.uses).to.eq(1, 'MY_EVENT uses stayed the same'); + + expect(eventCallCount).to.eq(2, 'eventCallCount stayed the same'); + expect(JSON.stringify(currentEventPayload)).to.eq(JSON.stringify({ + title: "Hello", + message: "There" + }), 'currentEventPayload has correct value'); + }); +}); diff --git a/packages/agile-core/tests/framework.spec.ts b/packages/agile-core/tests/framework.spec.ts new file mode 100644 index 00000000..6f813398 --- /dev/null +++ b/packages/agile-core/tests/framework.spec.ts @@ -0,0 +1,28 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../src"; + +describe('Custom Framework Tests', () => { + let boundFramework = false; + + // Define Agile with framework + const App = new Agile({ + framework: { + name: 'test', // The name of the framework + bind: (agileInstance: Agile) => { + boundFramework = true; + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Will be called to force subscribed components to rerender + } + } + }); + + it('Has bound custom Framework', () => { + expect(boundFramework).to.eq(true, 'boundFramework has correct value'); + expect(App.integration?.name).to.eq('test', 'Integration Name has correct value'); + expect(typeof App.integration?.bind === 'function').to.eq(true, 'Integration bind method get set'); + expect(typeof App.integration?.updateMethod === 'function').to.eq(true, 'Integration updateMethod method get set'); + expect(App.integration?.ready).to.eq(true, 'Integration is Ready'); + }); +}); diff --git a/packages/agile-core/tests/state/default.spec.ts b/packages/agile-core/tests/state/default.spec.ts new file mode 100644 index 00000000..f24ffa1d --- /dev/null +++ b/packages/agile-core/tests/state/default.spec.ts @@ -0,0 +1,74 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../src"; + +describe('Default State Tests', () => { + // Define Agile + const App = new Agile(); + + describe('State', () => { + // Create State + const MY_STATE = App.State('hello'); + + it('Has correct initial values', () => { + expect(MY_STATE.value).to.eq('hello', 'MY_STATE has correct value'); + expect(typeof MY_STATE.value === 'string').to.eq(true, 'MY_STATE has correct type'); + expect(MY_STATE._value).to.eq('hello', 'MY_STATE has correct _value') + expect(MY_STATE.previousState).to.eq('hello', 'MY_STATE has correct previousState'); + expect(MY_STATE.key).to.eq(undefined, 'MY_STATE has correct key'); + expect(MY_STATE._key).to.eq(undefined, 'My_STATE has correct _key'); + expect(MY_STATE.sideEffects).to.eq(undefined, 'MY_STATE has no sideEffects'); + expect(MY_STATE.nextState).to.eq('hello', 'MY_STATE has correct nextState'); + expect(MY_STATE.initialState).to.eq('hello', 'MY_STATE has correct initialState'); + expect(MY_STATE.exists).to.eq(true, 'MY_STATE has correct exists'); + expect(MY_STATE.isSet).to.eq(false, 'MY_STATE has correct isSet'); + expect(MY_STATE.persistSettings.isPersisted).to.eq(false, 'MY_STATE has correct isPersistState'); + expect(MY_STATE.isPlaceholder).to.eq(false, 'MY_STATE has correct isPlaceholder'); + expect(MY_STATE.valueType).to.eq(undefined, 'MY_STATE has correct valueType'); + expect(MY_STATE.exists).to.eq(true, 'MY_STATE exists'); + }); + + it('Can change key', () => { + // Update key + MY_STATE.key = 'myNewKey'; + + expect(MY_STATE.key).to.eq('myNewKey', 'MY_STATE has correct key'); + expect(MY_STATE._key).to.eq('myNewKey', 'My_STATE has correct _key'); + }); + + it('Can change value', () => { + // Update value + MY_STATE.value = 'bye'; + + expect(MY_STATE.value).to.eq('bye', 'MY_STATE has correct value'); + expect(MY_STATE._value).to.eq('bye', 'My_STATE has correct _value'); + }); + }); + + describe('State with Key', () => { + // Create State + const MY_STATE_WITH_KEY = App.State(true, 'myKey'); + + it('Has correct initial values', () => { + expect(typeof MY_STATE_WITH_KEY.value === 'boolean').to.eq(true, 'MY_STATE_WITH_KEY has correct type'); + expect(MY_STATE_WITH_KEY.key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct key'); + expect(MY_STATE_WITH_KEY._key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct _key'); + }); + + it('Can change key', () => { + // Update key + MY_STATE_WITH_KEY.key = 'myNewKey'; + + expect(MY_STATE_WITH_KEY.key).to.eq('myNewKey', 'MY_STATE_WITH_KEY has correct key'); + expect(MY_STATE_WITH_KEY._key).to.eq('myNewKey', 'MY_STATE_WITH_KEY has correct _key'); + }); + + it('Can change value', () => { + // Update value + MY_STATE_WITH_KEY.value = false; + + expect(MY_STATE_WITH_KEY.value).to.eq(false, 'MY_STATE_WITH_KEY has correct value'); + expect(MY_STATE_WITH_KEY._value).to.eq(false, 'MY_STATE_WITH_KEY has correct _value'); + }); + }); +}); diff --git a/packages/agile-core/tests/state/functions/patch.function.spec.ts b/packages/agile-core/tests/state/functions/patch.function.spec.ts new file mode 100644 index 00000000..f01eec2f --- /dev/null +++ b/packages/agile-core/tests/state/functions/patch.function.spec.ts @@ -0,0 +1,204 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; + +describe('Patch Function Tests', () => { + let rerenderCount = 0; + let sideEffectCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + // Object Interface + interface userInterface { + id: number, + name: string + } + + // Create State + const MY_STATE = App.State({id: 1, name: 'jeff'}); + + // Set sideEffects for testing the functionality of it + MY_STATE.sideEffects = () => { + sideEffectCount++ + }; + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myHookState] = useAgile([MY_STATE], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_STATE has correct value'); + expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); + expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); + + expect(JSON.stringify(myHookState)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'myHookState has correct MY_STATE value'); + expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); + expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); + }); + + describe('Patch State', () => { + it('Can patch value into State', async () => { + // Patch Value + MY_STATE.patch({name: 'hans'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ + id: 1, + name: 'hans' + }), 'MY_STATE has correct value'); + expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_STATE has correct previousState'); + expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ + id: 1, + name: 'hans' + }), 'MY_STATE has correct nextState'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); + + expect(sideEffectCount).to.eq(1, 'sideEffectCount has been increased by 1'); + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t patch value into State if the value is the same', async () => { + // Patch Value + MY_STATE.patch({name: 'hans'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ + id: 1, + name: 'hans' + }), 'MY_STATE value stayed the same'); + expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_STATE previousState stayed the same'); + expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ + id: 1, + name: 'hans' + }), 'MY_STATE nextState stayed the same'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE isSet stayed the same'); + + expect(sideEffectCount).to.eq(1, 'sideEffectCount hasn\'t been increased'); + expect(rerenderCount).to.eq(1, 'rerenderCount hasn\'t been increased'); + }); + + it('Can\'t patch value into State which is no Object', async () => { + // Patch State + // @ts-ignore + MY_STATE.patch('noObject'); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ + id: 1, + name: 'hans' + }), 'MY_STATE value stayed the same'); + expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ + id: 1, + name: 'jeff' + }), 'MY_STATE previousState stayed the same'); + expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ + id: 1, + name: 'hans' + }), 'MY_STATE nextState stayed the same'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE isSet stayed the same'); + + expect(sideEffectCount).to.eq(1, 'sideEffectCount hasn\'t been increased'); + expect(rerenderCount).to.eq(1, 'rerenderCount hasn\'t been increased'); + }); + + it('Can\'t patch value into non Object State', async () => { + // Create State + const MY_NON_OBJECT_STATE = App.State('test'); + + // Patch State + MY_NON_OBJECT_STATE.patch({test: 'test'}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_NON_OBJECT_STATE.value).to.eq('test', 'MY_NON_OBJECT_STATE value stayed the same'); + expect(MY_NON_OBJECT_STATE.previousState).to.eq('test', 'MY_NON_OBJECT_STATE previousState stayed the same'); + expect(MY_NON_OBJECT_STATE.nextState).to.eq('test', 'MY_NON_OBJECT_STATE nextState stayed the same'); + expect(MY_NON_OBJECT_STATE.isSet).to.eq(false, 'MY_NON_OBJECT_STATE isSet stayed the same'); + }); + }); + + describe('Test addNewProperties option', () => { + it('Doesn\'t add property to value with addNewProperties = false', async () => { + // Patch State + MY_STATE.patch({name: 'frank', age: 10}, {addNewProperties: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ + id: 1, + name: 'frank' + }), 'MY_STATE has correct value'); + expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ + id: 1, + name: 'hans' + }), 'MY_STATE has correct previousState'); + expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ + id: 1, + name: 'frank' + }), 'MY_STATE has correct nextState'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); + + expect(sideEffectCount).to.eq(2, 'sideEffectCount has been increased by 1'); + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Does add property to value with addNewProperties = true', async () => { + // Patch State + MY_STATE.patch({name: 'benno', age: 15}, {addNewProperties: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(JSON.stringify(MY_STATE.value)).to.eq(JSON.stringify({ + id: 1, + name: 'benno', + age: 15 + }), 'MY_STATE has correct value'); + expect(JSON.stringify(MY_STATE.previousState)).to.eq(JSON.stringify({ + id: 1, + name: 'frank' + }), 'MY_STATE has correct previousState'); + expect(JSON.stringify(MY_STATE.nextState)).to.eq(JSON.stringify({ + id: 1, + name: 'benno', + age: 15 + }), 'MY_STATE has correct nextState'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); + + expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 1'); + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + }); +}); diff --git a/packages/agile-core/tests/state/functions/persist.function.spec.ts b/packages/agile-core/tests/state/functions/persist.function.spec.ts new file mode 100644 index 00000000..ae4d4add --- /dev/null +++ b/packages/agile-core/tests/state/functions/persist.function.spec.ts @@ -0,0 +1,129 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; + + +describe('Persist Function Tests', () => { + const myStorage: any = {} + + // Define Agile with Storage + const App = new Agile({ + storageConfig: { + prefix: 'test', + methods: { + get: ((key) => { + return myStorage[key]; + }), + set: (key, value) => { + myStorage[key] = value; + }, + remove: (key) => { + delete myStorage[key]; + } + } + } + }); + + describe('State', () => { + // Create State + const MY_STATE = App.State(1); + + it('Has correct initial values', () => { + expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); + expect(MY_STATE.persistSettings.isPersisted).to.eq(false, 'MY_STATE has correct isPersistState'); + expect(App.storage.persistedStates.has(MY_STATE)).to.eq(false, 'MY_STATE isn\'t in persistedStates'); + expect(App.storage.persistedStates.has(MY_STATE)).to.eq(false, 'MY_STATE isn\'t in persistedStates'); + }); + + it("Can\'t persist State without persist Key", () => { + // Persist State + MY_STATE.persist(); + + expect(MY_STATE.persistSettings.isPersisted).to.eq(false, 'MY_STATE has correct isPersisted'); + expect(MY_STATE.persistSettings.persistKey).to.eq(undefined, 'MY_STATE has correct persistKey'); + expect(MY_STATE.key).to.eq(undefined, 'MY_STATE has correct key'); + expect(App.storage.persistedStates.has(MY_STATE)).to.eq(false, 'MY_STATE isn\'t in persistedStates'); + expect(App.storage.get('mySecondKey')).to.eq(undefined, 'MY_STATE isn\'t in storage'); + }); + + it("Can persist State with persist Key", async () => { + // Persist State + MY_STATE.persist('mySecondKey'); + + // Needs some time to persist value + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE.persistSettings.isPersisted).to.eq(true, 'MY_STATE has correct isPersisted'); + expect(MY_STATE.persistSettings.persistKey).to.eq('mySecondKey', 'MY_STATE has correct persistKey'); + expect(MY_STATE.key).to.eq('mySecondKey', 'MY_STATE key has been set to persistKey if no key is provided'); + expect(App.storage.persistedStates.has(MY_STATE)).to.eq(true, 'MY_STATE isn\'t in persistedStates'); + expect(App.storage.get('mySecondKey')).to.eq(1, 'MY_STATE is in storage'); + }); + + describe('Test reset method on persist State', () => { + it('Removes the State from the Storage if it get reset', () => { + // Reset State + MY_STATE.reset(); + + expect(MY_STATE.persistSettings.isPersisted).to.eq(true, 'MY_STATE has correct isPersisted'); + expect(MY_STATE.persistSettings.persistKey).to.eq('mySecondKey', 'MY_STATE has correct persistKey'); + expect(MY_STATE.key).to.eq('mySecondKey', 'MY_STATE has correct key'); + expect(App.storage.persistedStates.has(MY_STATE)).to.eq(true, 'MY_STATE is in persistedStates'); + expect(App.storage.get('mySecondKey')).to.eq(undefined, 'MY_STATE isn\'t in storage'); + }); + }); + + describe('Test set method on persist State', () => { + it('Updates the State in the Storage if it get changed', () => { + // Reset State + MY_STATE.set(5); + + expect(MY_STATE.persistSettings.isPersisted).to.eq(true, 'MY_STATE has correct isPersisted'); + expect(MY_STATE.persistSettings.persistKey).to.eq('mySecondKey', 'MY_STATE_WITH_KEY has correct persistKey'); + expect(App.storage.persistedStates.has(MY_STATE)).to.eq(true, 'MY_STATE_WITH_KEY is in persistedStates'); + expect(App.storage.get('mySecondKey')).to.eq(5, 'MY_STATE_WITH_KEY is in storage and has been updated'); + }); + }); + }); + + describe('State with Key', () => { + // Create State + const MY_STATE_WITH_KEY = App.State('hello', 'myKey'); + + it('Has correct initial values', () => { + expect(MY_STATE_WITH_KEY.value).to.eq('hello', 'MY_STATE_WITH_KEY has correct value'); + expect(MY_STATE_WITH_KEY.key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct key'); + expect(MY_STATE_WITH_KEY.persistSettings.isPersisted).to.eq(false, 'MY_STATE_WITH_KEY has correct isPersistState'); + expect(App.storage.persistedStates.has(MY_STATE_WITH_KEY)).to.eq(false, 'MY_STATE_WITH_KEY isn\'t in persistedStates'); + expect(App.storage.get('myKey')).to.eq(undefined, 'MY_STATE_WITH_KEY isn\'t in storage'); + }); + + it("Can persist State without persist Key", async () => { + // Persist State + MY_STATE_WITH_KEY.persist(); + + // Needs some time to persist value + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE_WITH_KEY.persistSettings.isPersisted).to.eq(true, 'MY_STATE_WITH_KEY has correct isPersistState'); + expect(MY_STATE_WITH_KEY.persistSettings.persistKey).to.eq('myKey', 'MY_STATE_WITH_KEY has correct persistKey'); + expect(App.storage.persistedStates.has(MY_STATE_WITH_KEY)).to.eq(true, 'MY_STATE_WITH_KEY is in persistedStates'); + expect(App.storage.get('myKey')).to.eq('hello', 'MY_STATE_WITH_KEY is in storage'); + }); + + it("Can persist State with persist Key", async () => { + // Persist State + MY_STATE_WITH_KEY.persist('myThirdKey'); + + // Needs some time to persist value + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE_WITH_KEY.persistSettings.isPersisted).to.eq(true, 'MY_STATE_WITH_KEY has correct isPersistState'); + expect(MY_STATE_WITH_KEY.persistSettings.persistKey).to.eq('myThirdKey', 'MY_STATE_WITH_KEY has correct persistKey'); + expect(MY_STATE_WITH_KEY.key).to.eq('myKey', 'MY_STATE_WITH_KEY has correct key'); + expect(App.storage.persistedStates.has(MY_STATE_WITH_KEY)).to.eq(true, 'MY_STATE_WITH_KEY is in persistedStates'); + expect(App.storage.get('myThirdKey')).to.eq('hello', 'MY_STATE_WITH_KEY with new key is in storage'); + expect(App.storage.get('myKey')).to.eq(undefined, 'MY_STATE_WITH_KEY with old key isn\'t in storage'); + }); + }); +}); diff --git a/packages/agile-core/tests/state/functions/reset.function.spec.ts b/packages/agile-core/tests/state/functions/reset.function.spec.ts new file mode 100644 index 00000000..932afe4d --- /dev/null +++ b/packages/agile-core/tests/state/functions/reset.function.spec.ts @@ -0,0 +1,72 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; + +describe('Reset Function Tests', () => { + let rerenderCount = 0; + let sideEffectCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + // Create State + const MY_STATE = App.State(1); + + // Set sideEffects for testing the functionality of it + MY_STATE.sideEffects = () => { + sideEffectCount++ + }; + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myHookState] = useAgile([MY_STATE], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); + expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); + expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); + + expect(myHookState).to.eq(1, 'myHookState has correct MY_STATE value'); + expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); + expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); + }); + + it('Can reset State', async () => { + // Change State + MY_STATE.set(2); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + // Change State + MY_STATE.set(5); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + // Reset State + MY_STATE.reset(); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); + expect(MY_STATE.previousState).to.eq(5, 'MY_STATE has correct previousState'); + expect(MY_STATE.nextState).to.eq(1, 'MY_STATE has correct nextState'); + expect(MY_STATE.isSet).to.eq(false, 'MY_STATE has correct isSet'); + + expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 3 (2 by set, 1 by reset)'); + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 3 (2 by set, 1 by reset)'); + }); +}); diff --git a/packages/agile-core/tests/state/functions/set.function.spec.ts b/packages/agile-core/tests/state/functions/set.function.spec.ts new file mode 100644 index 00000000..4f2bc23e --- /dev/null +++ b/packages/agile-core/tests/state/functions/set.function.spec.ts @@ -0,0 +1,125 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; + +describe('Set Function Tests', () => { + let rerenderCount = 0; + let sideEffectCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + // Create State + const MY_STATE = App.State(1); + + // Set sideEffects for testing the functionality of it + MY_STATE.sideEffects = () => { + sideEffectCount++ + }; + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myHookState] = useAgile([MY_STATE], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); + expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); + expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); + + expect(myHookState).to.eq(1, 'myHookState has correct MY_STATE value'); + expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); + expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); + }); + + it('Can change State', async () => { + // Change State + MY_STATE.set(2); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); + expect(MY_STATE.previousState).to.eq(1, 'MY_STATE has correct previousState'); + expect(MY_STATE.nextState).to.eq(2, 'MY_STATE has correct nextState'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); + expect(MY_STATE.exists).to.eq(true, 'MY_STATE exists'); + + expect(sideEffectCount).to.eq(1, 'sideEffectCount has been increased by 1'); + expect(rerenderCount).to.eq(1, 'rerenderCount has been increased by 1'); + }); + + it('Can\'t change State with the same value', async () => { + // Change State + MY_STATE.set(2); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); + expect(MY_STATE.previousState).to.eq(1, 'MY_STATE has correct previousState'); + expect(MY_STATE.nextState).to.eq(2, 'MY_STATE has correct nextState'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); + + expect(sideEffectCount).to.eq(1, 'sideEffectCount hasn\'t been increased'); + expect(rerenderCount).to.eq(1, 'rerenderCount hasn\'t been increased'); + }); + + describe('Test sideEffects option', () => { + it('Does call sideEffects by changing State with sideEffects = true', async () => { + // Change State + MY_STATE.set(3, {sideEffects: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(sideEffectCount).to.eq(2, 'sideEffectCount has been increased by 1'); + expect(rerenderCount).to.eq(2, 'rerenderCount has been increased by 1'); + }); + + it('Doesn\'t call sideEffects by changing State with sideEffects = false', async () => { + // Change State + MY_STATE.set(4, {sideEffects: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(sideEffectCount).to.eq(2, 'sideEffectCount hasn\'t been increased'); + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 1'); + }); + }); + + describe('Test background option', () => { + it('Doesn\'t call callBackFunction by changing State with background = true', async () => { + // Change State + MY_STATE.set(5, {background: true}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 1'); + expect(rerenderCount).to.eq(3, 'rerenderCount hasn\'t been increased'); + }); + + it('Does call callBackFunction by changing State with background = false', async () => { + // Change State + MY_STATE.set(6, {background: false}); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(sideEffectCount).to.eq(4, 'sideEffectCount has been increased by 1'); + expect(rerenderCount).to.eq(4, 'rerenderCount has been increased by 1'); + }); + }); +}); diff --git a/packages/agile-core/tests/state/functions/type.function.spec.ts b/packages/agile-core/tests/state/functions/type.function.spec.ts new file mode 100644 index 00000000..6810195d --- /dev/null +++ b/packages/agile-core/tests/state/functions/type.function.spec.ts @@ -0,0 +1,32 @@ +import 'mocha'; +import {expect} from 'chai' +import Agile from "../../../src"; + +describe('Type Function Tests', () => { + // Define Agile + const App = new Agile(); + + // Create State + const MY_STATE = App.State(1).type(Number); + + it('Has correct initial values', () => { + expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); + expect(typeof MY_STATE.value === 'number').to.eq(true, 'MY_STATE has correct type'); + expect(MY_STATE.valueType).to.eq('number', 'MY_STATE correct valueType'); + }); + + it('Can change State with correct Type', async () => { + // Change State + MY_STATE.set(2); + + expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); + }); + + it('Can\'t change State with wrong Type', async () => { + // Change State + // @ts-ignore + MY_STATE.set('Hello'); + + expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); + }); +}); diff --git a/packages/agile-core/tests/state/functions/undo.function.spec.ts b/packages/agile-core/tests/state/functions/undo.function.spec.ts new file mode 100644 index 00000000..27ffb3f9 --- /dev/null +++ b/packages/agile-core/tests/state/functions/undo.function.spec.ts @@ -0,0 +1,72 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; +import {useAgile} from "../../../src/integrations/test"; + +describe('Undo Function Tests', () => { + let rerenderCount = 0; + let sideEffectCount = 0; + + // Define Agile + const App = new Agile({ + framework: { + name: 'test', + bind: (agileInstance: Agile) => { + }, + updateMethod: (componentInstance: any, updatedData: Object) => { + // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) + } + }, + }); + + // Create State + const MY_STATE = App.State(1); + + // Set sideEffects for testing the functionality of it + MY_STATE.sideEffects = () => { + sideEffectCount++ + }; + + // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) + const [myHookState] = useAgile([MY_STATE], () => { + rerenderCount++; + }); + + it('Has correct initial values', () => { + expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); + expect(MY_STATE.dep.subs.size === 1).to.eq(true, 'MY_STATE has correct subs size (Subs are components/callbackFunctions which causes rerender)'); + expect(typeof MY_STATE.sideEffects === 'function').to.eq(true, 'MY_STATE has sideEffect function'); + + expect(myHookState).to.eq(1, 'myHookState has correct MY_STATE value'); + expect(rerenderCount).to.eq(0, 'rerenderCount is 0'); + expect(sideEffectCount).to.eq(0, 'sideEffectCount is 0'); + }); + + it('Can undo State', async () => { + // Change State + MY_STATE.set(2); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + // Change State + MY_STATE.set(5); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + // Undo State + MY_STATE.undo(); + + // Needs some time to call callbackFunction + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); + expect(MY_STATE.previousState).to.eq(5, 'MY_STATE has correct previousState'); + expect(MY_STATE.nextState).to.eq(2, 'MY_STATE has correct nextState'); + expect(MY_STATE.isSet).to.eq(true, 'MY_STATE has correct isSet'); + + expect(sideEffectCount).to.eq(3, 'sideEffectCount has been increased by 3 (2 by set, 1 by undo)'); + expect(rerenderCount).to.eq(3, 'rerenderCount has been increased by 3 (2 by set, 1 by undo)'); + }); +}); diff --git a/packages/agile-core/tests/state/functions/watch.function.spec.ts b/packages/agile-core/tests/state/functions/watch.function.spec.ts new file mode 100644 index 00000000..1b598bea --- /dev/null +++ b/packages/agile-core/tests/state/functions/watch.function.spec.ts @@ -0,0 +1,52 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../../../src"; + +describe('Watcher Tests', () => { + let calledWatcherCount = 0; + let watcherValue = 1; + + // Define Agile + const App = new Agile(); + + // Create State + const MY_STATE = App.State(1); + + // Create Watcher + MY_STATE.watch('firstWatcher', (value) => { + watcherValue = value; + calledWatcherCount++; + }); + + it('Has correct initial values', () => { + expect(MY_STATE.value).to.eq(1, 'MY_STATE has correct value'); + expect(MY_STATE.watchers.firstWatcher !== undefined).to.eq(true, 'MY_STATE has firstWatcher in watchers') + }); + + it('Can Watch State', async () => { + // Update State + MY_STATE.set(2); + + // Needs some time to call watcher + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE.value).to.eq(2, 'MY_STATE has correct value'); + expect(calledWatcherCount).to.eq(1, 'calledWatcherCount has been increased by 1'); + expect(watcherValue).to.eq(2, 'watcherValue has correct value'); + }); + + it('Can Remove Watcher', async () => { + // Remove Watcher + MY_STATE.removeWatcher('firstWatcher'); + + // Update State + MY_STATE.set(3); + + // Needs some time to call watcher + await new Promise(resolve => setTimeout(resolve, 100)); + + expect(MY_STATE.value).to.eq(3, 'MY_STATE has correct value'); + expect(calledWatcherCount).to.eq(1, 'calledWatcherCount hasn\'t been increased'); + expect(watcherValue).to.eq(2, 'watcherValue has\'t change.. because of no update'); + }); +}); diff --git a/packages/agile-core/tests/storage.spec.ts b/packages/agile-core/tests/storage.spec.ts new file mode 100644 index 00000000..93847963 --- /dev/null +++ b/packages/agile-core/tests/storage.spec.ts @@ -0,0 +1,98 @@ +import 'mocha'; +import {expect} from 'chai'; +import Agile from "../src"; + +describe('Custom Storage Tests', () => { + const myStorage: any = {} + + // Define Agile + const App = new Agile(); + + // Create Storage + const storage = App.Storage({ + prefix: 'test', + methods: { + get: ((key) => { + return myStorage[key]; + }), + set: (key, value) => { + myStorage[key] = value; + }, + remove: (key) => { + delete myStorage[key]; + } + } + }); + + describe('Can work with numbers', () => { + it('Can set an item into the Storage', async () => { + // Set Item into Storage + storage.set('myKey', 1); + + expect(myStorage['_test_myKey']).to.eq(JSON.stringify(1)); + }); + + it('Can get an item from the Storage', () => { + // Get Item from Storage + const item = storage.get('myKey'); + + expect(item).to.eq(1); + }); + + it('Can remove an item from the Storage', () => { + // Remove Item from Storage + storage.remove('myKey'); + + expect(myStorage['_test_myKey']).to.eq(undefined); + expect(storage.get('myKey')).to.eq(undefined); + }); + }); + + describe('Can work with object', () => { + it('Can set an item into the Storage', () => { + // Set Item into Storage + storage.set('mySecondKey', {id: 1, name: 'jeff'}); + + expect(myStorage['_test_mySecondKey']).to.eq(JSON.stringify({id: 1, name: 'jeff'})); + }); + + it('Can get an item from the Storage', () => { + // Get Item from Storage + const item = storage.get('mySecondKey'); + + expect(JSON.stringify(item)).to.eq(JSON.stringify({id: 1, name: 'jeff'})); + }); + + it('Can remove an item from the Storage', () => { + // Remove Item from Storage + storage.remove('mySecondKey'); + + expect(myStorage['_test_mySecondKey']).to.eq(undefined); + expect(storage.get('mySecondKey')).to.eq(undefined); + }); + }); + + describe('Can work with array', () => { + it('Can set an item into the Storage', () => { + // Set Item into Storage + storage.set('myThirdKey', [1, 2, 3]); + + expect(myStorage['_test_myThirdKey']).to.eq(JSON.stringify([1, 2, 3])); + }); + + it('Can get an item from the Storage', () => { + // Get Item from Storage + const item = storage.get('myThirdKey'); + + expect(JSON.stringify(item)).to.eq(JSON.stringify([1, 2, 3])); + }); + + it('Can remove an item from the Storage', () => { + // Remove Item from Storage + storage.remove('myThirdKey'); + + expect(myStorage['myThirdKey']).to.eq(undefined); + expect(storage.get('myThirdKey')).to.eq(undefined); + }); + }); +}); diff --git a/packages/agile-core/tsconfig.json b/packages/agile-core/tsconfig.json new file mode 100644 index 00000000..e6529093 --- /dev/null +++ b/packages/agile-core/tsconfig.json @@ -0,0 +1,8 @@ +{ + "extends": "../tsconfig.default.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "dist" + }, + "include": ["./src/**/*"] // Only include what is in src (dist, tests, .. will be excluded) + } \ No newline at end of file diff --git a/packages/agile-react/package.json b/packages/agile-react/package.json new file mode 100644 index 00000000..fa5d6cf0 --- /dev/null +++ b/packages/agile-react/package.json @@ -0,0 +1,27 @@ +{ + "name": "@agile-ts/core", + "version": "0.0.1", + "author": "BennoDev", + "license": "ISC", + "description": "React extention for AgileTs", + "keywords": [], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "build": "tsc" + }, + "peerDependencies": { + "@agile-ts/core": "^0.0.2", + "react": "^16.13.1" + }, + "devDependencies": { + "@types/react": "^16.9.49" + }, + "publishConfig": { + "access": "public" + }, + "repository": { + "type": "git", + "url": "https://github.com/agile-ts/agile.git" + } + } \ No newline at end of file diff --git a/packages/agile-react/src/hooks/AgileHOC.ts b/packages/agile-react/src/hooks/AgileHOC.ts new file mode 100644 index 00000000..f73e46c8 --- /dev/null +++ b/packages/agile-react/src/hooks/AgileHOC.ts @@ -0,0 +1,92 @@ +import State from "../../../state"; +import Agile from "../../../index"; +import {getAgileInstance, normalizeArray} from "../../../utils"; +import {SubscriptionContainer} from "../../../sub"; + +export function AgileHOC(ReactComponent: any, deps?: Array | { [key: string]: State } | State, agileInstance?: Agile) { + let depsArray: Array; + let depsObject: { [key: string]: State }; + + if (deps instanceof State || Array.isArray(deps)) { + // Normalize Dependencies + depsArray = normalizeArray(deps || []); + + // Get Agile Instance + if (!agileInstance) { + if (depsArray.length > 0) { + const tempAgileInstance = getAgileInstance(depsArray[0]); + agileInstance = tempAgileInstance || undefined; + } else { + console.warn("Agile: Please don't pass an empty array!"); + } + } + } else if (typeof deps === "object") { + depsObject = deps; + + // Get Agile Instance + if (!agileInstance) { + const objectKeys = Object.keys(depsObject); + if (objectKeys.length > 0) { + const tempAgileInstance = getAgileInstance(depsObject[objectKeys[0]]); + agileInstance = tempAgileInstance || undefined; + } else { + console.warn("Agile: Please don't pass an empty object!"); + } + } + } else { + console.error("Agile: No Valid AgileHOC properties"); + return ReactComponent; + } + + // Check if agile Instance exists + if (!agileInstance) { + console.error("Agile: Failed to get Agile Instance"); + return ReactComponent; + } + + // Get React constructor + const React = agileInstance.integration?.frameworkConstructor; + if (!React) { + console.error("Agile: Failed to get Framework Constructor"); + return ReactComponent; + } + + return class extends React.Component { + public componentContainer: SubscriptionContainer | null = null; // Will be set in registerSubscription (sub.ts) + + public updatedProps = this.props; + + constructor(props: any) { + super(props); + + // Create HOC based Subscription with Array (Rerenders will here be caused via force Update) + if (depsArray) + agileInstance?.subController.subscribeWithSubsArray(this, depsArray); + + // Create HOC based Subscription with Object + if (depsObject) { + const response = agileInstance?.subController.subscribeWithSubsObject(this, depsObject); + this.updatedProps = { + ...props, + ...response?.props + } + + // Defines State for causing rerender (will be called in updateMethod) + this.state = depsObject; + } + } + + componentDidMount() { + if (agileInstance?.config.waitForMount) + agileInstance?.subController.mount(this); + } + + componentWillUnmount() { + agileInstance?.subController.unsubscribe(this); + } + + render() { + return React.createElement(ReactComponent, this.updatedProps); + } + }; +} diff --git a/packages/agile-react/src/hooks/useAgile.ts b/packages/agile-react/src/hooks/useAgile.ts new file mode 100644 index 00000000..5746fa71 --- /dev/null +++ b/packages/agile-react/src/hooks/useAgile.ts @@ -0,0 +1,82 @@ +import Group from "../../../collection/group"; +import State from "../../../state"; +import Collection from "../../../collection"; +import Agile from "../../../index"; +import {getAgileInstance, normalizeArray} from "../../../utils"; + +// Array Type +// https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-1.html +type AgileHookArrayType = { + [K in keyof T]: T[K] extends Group ? U[] + : T[K] extends State ? U + : T[K] extends Collection ? U[] + : T[K] extends undefined ? undefined + : never +}; + +// No Array Type +type AgileHookType = T extends Group ? U[] + : T extends State ? U + : T extends Collection ? U[] + : T extends undefined ? undefined + : never; + +// Array +export function useAgile>(deps: X, agileInstance?: Agile): AgileHookArrayType; + +// No Array +export function useAgile(deps: X, agileInstance?: Agile): AgileHookType; + +export function useAgile, Y extends State | Collection | undefined>(deps: X | Y, agileInstance?: Agile): AgileHookArrayType | AgileHookType { + // Normalize Dependencies + let depsArray = normalizeArray(deps) + .map(item => item instanceof Collection ? item.getGroup(item.config.defaultGroupKey || 'default') : item) + .filter(item => item !== undefined) as State[]; + + // Function which creates the return value + const getReturnValue = (depsArray: State[]): AgileHookArrayType | AgileHookType => { + // Return Public Value of State + if (depsArray.length === 1 && !Array.isArray(deps)) + return depsArray[0]?.getPublicValue() as AgileHookType; + + // Return Public Value of State in Array + return depsArray.map(dep => { + return dep.getPublicValue(); + }) as AgileHookArrayType; + } + + // Get Agile Instance + if (!agileInstance) { + const tempAgileInstance = getAgileInstance(depsArray[0]); + if (!tempAgileInstance) { + console.error("Agile: Failed to get Agile Instance"); + return getReturnValue(depsArray); + } + agileInstance = tempAgileInstance; + } + + // Get React constructor + const React = agileInstance.integration?.frameworkConstructor; + if (!React) { + console.error("Agile: Failed to get Framework Constructor"); + return getReturnValue(depsArray); + } + + // This is a Trigger State used to force the component to Re-render + const [_, set_] = React.useState({}); + + React.useEffect(function () { + // Create a callback base subscription, Callback invokes re-render Trigger + const subscriptionContainer = agileInstance?.subController.subscribeWithSubsArray( + () => { + set_({}); + }, + depsArray + ); + + // Unsubscribe on Unmount + return () => agileInstance?.subController.unsubscribe(subscriptionContainer); + }, []); + + return getReturnValue(depsArray); +} diff --git a/packages/agile-react/src/hooks/useEvent.ts b/packages/agile-react/src/hooks/useEvent.ts new file mode 100644 index 00000000..7bf99370 --- /dev/null +++ b/packages/agile-react/src/hooks/useEvent.ts @@ -0,0 +1,27 @@ +import Event, {EventCallbackFunction} from "../../../event"; +import Agile from "../../../index"; +import {getAgileInstance} from "../../../utils"; + +export function useEvent(event: E, callback: EventCallbackFunction, agileInstance?: Agile) { + // Get Agile Instance + if (!agileInstance) { + const tempAgileInstance = getAgileInstance(event); + if (!tempAgileInstance) { + console.error("Agile: Failed to get Agile Instance"); + return; + } + agileInstance = tempAgileInstance; + } + + // Get React constructor + const React = agileInstance.integration?.frameworkConstructor; + if (!React) { + console.error("Agile: Failed to get Framework Constructor"); + return; + } + + React.useEffect(function () { + // Call event on component mount and remove event on component unmount + return event.on(callback); + }, []); +} diff --git a/packages/agile-react/src/index.ts b/packages/agile-react/src/index.ts new file mode 100644 index 00000000..e8f35d34 --- /dev/null +++ b/packages/agile-react/src/index.ts @@ -0,0 +1,7 @@ +import reactIntegration from "./react.integration"; + +export {useAgile} from './hooks/useAgile'; +export {AgileHOC} from './hooks/AgileHOC'; +export {useEvent} from './hooks/useEvent'; + +export default reactIntegration; diff --git a/packages/agile-react/src/react.integration.ts b/packages/agile-react/src/react.integration.ts new file mode 100644 index 00000000..6fe0e05c --- /dev/null +++ b/packages/agile-react/src/react.integration.ts @@ -0,0 +1,31 @@ +import Agile from "../../index"; +import {Integration} from "../use"; + + +//========================================================================================================= +// Framework Integration +//========================================================================================================= + +const reactIntegration: Integration = { + name: 'react', + bind(agileInstance: Agile) { + // Not sure if usePulse should get into the pulseInstance + // pulseInstance.usePulse = (deps: Array) => usePulse(deps, pulseInstance); + // if (agileInstance.config.logJobs) console.log("Agile: Successfully binded React to Agile") + }, + updateMethod(componentInstance: any, updatedData: Object) { + // UpdatedData will be empty if the AgileHOC doesn't get an object as deps + + if (Object.keys(updatedData).length !== 0) { + // Update Props + componentInstance.updatedProps = {...componentInstance.updatedProps, ...updatedData}; + + // Set State + componentInstance.setState(updatedData); + } else { + componentInstance.forceUpdate(); + } + } +}; + +export default reactIntegration; diff --git a/packages/agile-react/tests/ReadMe.md b/packages/agile-react/tests/ReadMe.md new file mode 100644 index 00000000..914afcb5 --- /dev/null +++ b/packages/agile-react/tests/ReadMe.md @@ -0,0 +1 @@ +Note: the react hook will be tested in the agile-core tests \ No newline at end of file diff --git a/packages/agile-react/tests/hooks/index.ts b/packages/agile-react/tests/hooks/index.ts new file mode 100644 index 00000000..2f96a5ec --- /dev/null +++ b/packages/agile-react/tests/hooks/index.ts @@ -0,0 +1,2 @@ +export {useAgile} from './hooks/useAgile'; +export {useEvent} from './hooks/useEvent'; diff --git a/packages/agile-react/tests/hooks/useAgile.ts b/packages/agile-react/tests/hooks/useAgile.ts new file mode 100644 index 00000000..a2ea0c2e --- /dev/null +++ b/packages/agile-react/tests/hooks/useAgile.ts @@ -0,0 +1,68 @@ +import State from "../../../state"; +import Collection from "../../../collection"; +import Agile from "../../../index"; +import {getAgileInstance, normalizeArray} from "../../../utils"; +import Group from "../../../collection/group"; + + +//========================================================================================================= +// Use Test Hook +// NOTE: This is only used for Tests +//========================================================================================================= + +// Array Type +// https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-1.html +type AgileHookArrayType = { + [K in keyof T]: T[K] extends Group ? U[] + : T[K] extends State ? U + : T[K] extends Collection ? U[] + : T[K] extends undefined ? undefined + : never +}; + +// No Array Type +type AgileHookType = T extends Group ? U[] + : T extends State ? U + : T extends Collection ? U[] + : T extends undefined ? undefined + : never; + +// Array +export function useAgile>(deps: X, callBackFunction: Function, agileInstance?: Agile): AgileHookArrayType; + +// No Array +export function useAgile(deps: X, callBackFunction: Function, agileInstance?: Agile): AgileHookType; + +export function useAgile, Y extends State | Collection | undefined>(deps: X | Y, callBackFunction: Function, agileInstance?: Agile): AgileHookArrayType | AgileHookType { + // Normalize Dependencies + let depsArray = normalizeArray(deps) + .map(item => item instanceof Collection ? item.getGroup(item.config.defaultGroupKey || 'default') : item) + .filter(item => item !== undefined) as State[]; + + // Function which creates the return value + const getReturnValue = (depsArray: State[]): AgileHookArrayType | AgileHookType => { + // Return Public Value of State + if (depsArray.length === 1 && !Array.isArray(deps)) + return depsArray[0]?.getPublicValue() as AgileHookType; + + // Return Public Value of State in Array + return depsArray.map(dep => { + return dep.getPublicValue(); + }) as AgileHookArrayType; + } + + // Get Agile Instance + if (!agileInstance) { + const tempAgileInstance = getAgileInstance(depsArray[0]); + if (!tempAgileInstance) { + console.error("Agile: Failed to get Agile Instance"); + return getReturnValue(depsArray); + } + agileInstance = tempAgileInstance; + } + + // Create a callback base subscription, Callback invokes re-render Trigger + agileInstance?.subController.subscribeWithSubsArray(callBackFunction, depsArray); + + return getReturnValue(depsArray); +} diff --git a/packages/agile-react/tests/hooks/useEvent.ts b/packages/agile-react/tests/hooks/useEvent.ts new file mode 100644 index 00000000..513ea7c7 --- /dev/null +++ b/packages/agile-react/tests/hooks/useEvent.ts @@ -0,0 +1,18 @@ +import Event, {EventCallbackFunction} from "../../../event"; +import Agile from "../../../index"; +import {getAgileInstance} from "../../../utils"; + +export function useEvent(event: E, callback: EventCallbackFunction, agileInstance?: Agile) { + // Get Agile Instance + if (!agileInstance) { + const tempAgileInstance = getAgileInstance(event); + if (!tempAgileInstance) { + console.error("Agile: Failed to get Agile Instance"); + return; + } + agileInstance = tempAgileInstance; + } + + // Call on Event + event.on(callback); +} diff --git a/packages/agile-react/tsconfig.json b/packages/agile-react/tsconfig.json new file mode 100644 index 00000000..e6529093 --- /dev/null +++ b/packages/agile-react/tsconfig.json @@ -0,0 +1,8 @@ +{ + "extends": "../tsconfig.default.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "dist" + }, + "include": ["./src/**/*"] // Only include what is in src (dist, tests, .. will be excluded) + } \ No newline at end of file diff --git a/packages/tsconfig.default.json b/packages/tsconfig.default.json new file mode 100644 index 00000000..b4397a10 --- /dev/null +++ b/packages/tsconfig.default.json @@ -0,0 +1,70 @@ +{ + "compilerOptions": { + /* Visit https://aka.ms/tsconfig.json to read more about this file */ + + /* Basic Options */ + // "incremental": true, /* Enable incremental compilation */ + "target": "ES2015", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */ + "module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */ + // "lib": [], /* Specify library files to be included in the compilation. */ + // "allowJs": true, /* Allow javascript files to be compiled. */ + // "checkJs": true, /* Report errors in .js files. */ + // "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ + "declaration": true, /* Generates corresponding '.d.ts' file. */ + // "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ + // "sourceMap": true, /* Generates corresponding '.map' file. */ + // "outFile": "./", /* Concatenate and emit output to single file. */ + "outDir": "./dist", /* Redirect output structure to the directory. */ + "rootDir": "./src", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */ + // "composite": true, /* Enable project compilation */ + // "tsBuildInfoFile": "./", /* Specify file to store incremental compilation information */ + // "removeComments": true, /* Do not emit comments to output. */ + // "noEmit": true, /* Do not emit outputs. */ + // "importHelpers": true, /* Import emit helpers from 'tslib'. */ + // "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */ + // "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */ + + /* Strict Type-Checking Options */ + "strict": true, /* Enable all strict type-checking options. */ + "noImplicitAny": false, /* Raise error on expressions and declarations with an implied 'any' type. */ + // "strictNullChecks": true, /* Enable strict null checks. */ + // "strictFunctionTypes": true, /* Enable strict checking of function types. */ + // "strictBindCallApply": true, /* Enable strict 'bind', 'call', and 'apply' methods on functions. */ + // "strictPropertyInitialization": true, /* Enable strict checking of property initialization in classes. */ + // "noImplicitThis": true, /* Raise error on 'this' expressions with an implied 'any' type. */ + // "alwaysStrict": true, /* Parse in strict mode and emit "use strict" for each source file. */ + + /* Additional Checks */ + // "noUnusedLocals": true, /* Report errors on unused locals. */ + // "noUnusedParameters": true, /* Report errors on unused parameters. */ + // "noImplicitReturns": true, /* Report error when not all code paths in function return a value. */ + // "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ + + /* Module Resolution Options */ + "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ + // "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ + // "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ + // "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */ + // "typeRoots": [], /* List of folders to include type definitions from. */ + // "types": [], /* Type declaration files to be included in compilation. */ + // "allowSyntheticDefaultImports": true, /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */ + // "esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */ + // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ + // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ + + /* Source Map Options */ + // "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ + // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ + + /* Experimental Options */ + // "experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */ + // "emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */ + + /* Advanced Options */ + "skipLibCheck": true , /* Skip type checking of declaration files. */ + "forceConsistentCasingInFileNames": true /* Disallow inconsistently-cased references to the same file. */ + } + } + \ No newline at end of file From 63edbf6b6289b3b459a08415492e60d72f849c74 Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Tue, 29 Sep 2020 19:36:25 +0200 Subject: [PATCH 03/15] Updated Imports --- packages/agile-core/src/agile.ts | 28 ++++++++++++------- packages/agile-core/src/collection/index.ts | 1 + packages/agile-core/src/collection/item.ts | 7 +++-- .../agile-core/src/collection/perstist.ts | 11 ++++++-- .../agile-core/src/collection/selector.ts | 17 +++++++---- packages/agile-core/src/computed/index.ts | 8 ++++-- packages/agile-core/src/index.ts | 4 +++ packages/agile-core/src/runtime.ts | 14 ++++++---- packages/agile-core/src/state/dep.ts | 6 ++-- packages/agile-core/src/state/index.ts | 18 +++++++----- packages/agile-core/src/state/persist.ts | 7 +++-- .../src/{storage.ts => storage/index.ts} | 12 +++++--- packages/agile-core/src/sub.ts | 3 +- packages/agile-core/src/use.ts | 3 +- packages/agile-core/src/utils.ts | 15 +++++----- 15 files changed, 99 insertions(+), 55 deletions(-) rename packages/agile-core/src/{storage.ts => storage/index.ts} (97%) diff --git a/packages/agile-core/src/agile.ts b/packages/agile-core/src/agile.ts index 489016a8..14b6a840 100644 --- a/packages/agile-core/src/agile.ts +++ b/packages/agile-core/src/agile.ts @@ -1,12 +1,19 @@ -import Runtime from "./runtime"; -import use, {Integration} from "./use"; -import SubController from "./sub"; -import {State} from './internal'; -import Storage, {StorageConfigInterface} from "./storage"; -import Collection, {CollectionConfig, DefaultDataIt../packages/agile-core/src/collectioncollection"; -import Computed from "./computed"; -import API, {apiConfig} from "../../agile-api/src"; -import Event, {EventConfig, DefaultEventPayload} from "./event"; +import { + Runtime, + Integration, + SubController, + State, + Storage, + StorageConfigInterface, + Collection, + CollectionConfig, + DefaultDataItem, + Computed, + Event, + EventConfig, + DefaultEventPayload, + use +} from './internal' export interface AgileConfigInterface { framework?: Integration | any // Integration = for custom frameworks | any = for existing frameworks like react @@ -59,7 +66,8 @@ export class Agile { * @param config.baseURL String - Url to prepend to endpoints (without trailing slash) * @param config.timeout Number - Time to wait for request before throwing error */ - public API = (config: apiConfig) => new API(config); + // public API = (config: apiConfig) => new API(config); + //========================================================================================================= diff --git a/packages/agile-core/src/collection/index.ts b/packages/agile-core/src/collection/index.ts index 2568bc46..f53b6472 100644 --- a/packages/agile-core/src/collection/index.ts +++ b/packages/agile-core/src/collection/index.ts @@ -8,6 +8,7 @@ import { State, StateKey, StorageKey, + GroupConfigInterface, copy, defineConfig, flatMerge, diff --git a/packages/agile-core/src/collection/item.ts b/packages/agile-core/src/collection/item.ts index a2a862bf..7cb77505 100644 --- a/packages/agile-core/src/collection/item.ts +++ b/packages/agile-core/src/collection/item.ts @@ -1,5 +1,8 @@ -import State from '../state'; -import Collection, {DefaultDataItem} from './index'; +import { + State, + Collection, + DefaultDataItem +} from '../internal'; export class Item extends State { diff --git a/packages/agile-core/src/collection/perstist.ts b/packages/agile-core/src/collection/perstist.ts index 20295918..92835e04 100644 --- a/packages/agile-core/src/collection/perstist.ts +++ b/packages/agile-core/src/collection/perstist.ts @@ -1,6 +1,10 @@ -import Collection, {ItemKey} from "./index"; -import Storage, {StorageKey} from "../storage"; -import {GroupKey} from "./group"; +import { + Collection, + ItemKey, + Storage, + StorageKey, + GroupKey +} from '../internal'; interface CollectionStorageData { data: ItemKey[], @@ -10,6 +14,7 @@ interface CollectionStorageData { const storageItemKeyTemplate = '_${collectionKey}_item_${itemKey}'; const storageGroupKeyTemplate = '_${collectionKey}_group_${groupKey}'; + //========================================================================================================= // Persist Value //========================================================================================================= diff --git a/packages/agile-core/src/collection/selector.ts b/packages/agile-core/src/collection/selector.ts index 0a20f3b7..31fd3329 100644 --- a/packages/agile-core/src/collection/selector.ts +++ b/packages/agile-core/src/collection/selector.ts @@ -1,9 +1,14 @@ -import Collection, {DefaultDataItem, ItemKey} from "./index"; -import Computed from "../computed"; -import Item from "./item"; -import {persistValue} from "../state/persist"; -import {StorageKey} from "../storage"; -import {copy, defineConfig} from "../utils"; +import { + Collection, + DefaultDataItem, + ItemKey, + Computed, + Item, + StorageKey, + copy, + defineConfig +} from '../internal'; +import {persistValue} from '../state/persist'; export type SelectorKey = string | number; diff --git a/packages/agile-core/src/computed/index.ts b/packages/agile-core/src/computed/index.ts index ba001c65..841631bb 100644 --- a/packages/agile-core/src/computed/index.ts +++ b/packages/agile-core/src/computed/index.ts @@ -1,6 +1,8 @@ -import State from "../state"; -import Agile from "../agile"; -import {defineConfig} from "../utils"; +import { + State, + Agile, + defineConfig +} from '../internal'; export class Computed extends State { public agileInstance: () => Agile; diff --git a/packages/agile-core/src/index.ts b/packages/agile-core/src/index.ts index e69de29b..a0748ac6 100644 --- a/packages/agile-core/src/index.ts +++ b/packages/agile-core/src/index.ts @@ -0,0 +1,4 @@ +import {Agile} from './internal'; + +export * from './internal'; +export default Agile; \ No newline at end of file diff --git a/packages/agile-core/src/runtime.ts b/packages/agile-core/src/runtime.ts index df841189..1403f3be 100644 --- a/packages/agile-core/src/runtime.ts +++ b/packages/agile-core/src/runtime.ts @@ -1,8 +1,12 @@ -import State from "./state"; -import Agile from "./agile"; -import {copy, defineConfig} from "./utils"; -import {CallbackContainer, SubscriptionContainer} from "./sub"; -import Computed from "./computed"; +import { + State, + Agile, + CallbackContainer, + SubscriptionContainer, + Computed, + copy, + defineConfig +} from './internal'; export interface JobInterface { state: State diff --git a/packages/agile-core/src/state/dep.ts b/packages/agile-core/src/state/dep.ts index eb4e41de..ccf0b619 100644 --- a/packages/agile-core/src/state/dep.ts +++ b/packages/agile-core/src/state/dep.ts @@ -1,5 +1,7 @@ -import {SubscriptionContainer} from '../sub'; -import State from "./index"; +import { + State, + SubscriptionContainer +} from '../internal'; export class Dep { public deps: Set = new Set(); // Dependencies from the State diff --git a/packages/agile-core/src/state/index.ts b/packages/agile-core/src/state/index.ts index 9e5f8f2e..cf0d860d 100644 --- a/packages/agile-core/src/state/index.ts +++ b/packages/agile-core/src/state/index.ts @@ -1,8 +1,14 @@ -import Agile from "../agile"; -import {copy, defineConfig, flatMerge, isValidObject} from "../utils"; -import Dep from "./dep"; -import {persistValue, updateValue} from "./persist"; -import {StorageKey} from "../storage"; +import { + Agile, + Dep, + StorageKey, + copy, + defineConfig, + flatMerge, + isValidObject +} from '../internal'; +import {persistValue, updateValue} from './persist'; + export type StateKey = string | number; @@ -29,8 +35,6 @@ export class State { public previousState: ValueType; // Will be set in runtime public nextState: ValueType; // The next state is used internal and represents the nextState which can be edited as wished (cleaner than always setting the state) - // public computeValue?: (newState?: ValueType) => ValueType; - constructor(agileInstance: Agile, initialState: ValueType, key?: StateKey, deps: Array = []) { this.agileInstance = () => agileInstance; this.initialState = initialState; diff --git a/packages/agile-core/src/state/persist.ts b/packages/agile-core/src/state/persist.ts index d466101c..bbd23ba2 100644 --- a/packages/agile-core/src/state/persist.ts +++ b/packages/agile-core/src/state/persist.ts @@ -1,5 +1,8 @@ -import State from "./index"; -import Storage, {StorageKey} from "../storage"; +import { + State, + Storage, + StorageKey +} from '../internal'; //========================================================================================================= diff --git a/packages/agile-core/src/storage.ts b/packages/agile-core/src/storage/index.ts similarity index 97% rename from packages/agile-core/src/storage.ts rename to packages/agile-core/src/storage/index.ts index 406c5e3a..8b453291 100644 --- a/packages/agile-core/src/storage.ts +++ b/packages/agile-core/src/storage/index.ts @@ -1,7 +1,11 @@ -import Agile from "./agile"; -import State from "./state"; -import {isAsyncFunction, isFunction, isJsonString} from "./utils"; -import Collection from "./collection"; +import { + Agile, + State, + Collection, + isAsyncFunction, + isFunction, + isJsonString +} from '../internal'; export type StorageKey = string | number; export interface StorageConfigInterface { diff --git a/packages/agile-core/src/sub.ts b/packages/agile-core/src/sub.ts index bd168770..9f33eb30 100644 --- a/packages/agile-core/src/sub.ts +++ b/packages/agile-core/src/sub.ts @@ -1,5 +1,4 @@ -import State from "./state"; -import Agile from "./agile"; +import {Agile, State} from './internal'; //========================================================================================================= diff --git a/packages/agile-core/src/use.ts b/packages/agile-core/src/use.ts index c9638021..d0c7aea5 100644 --- a/packages/agile-core/src/use.ts +++ b/packages/agile-core/src/use.ts @@ -1,5 +1,4 @@ -import Agile from "../agile"; -import reactIntegration from "./react"; +import {Agile} from './internal'; export interface Integration { ready?: boolean; diff --git a/packages/agile-core/src/utils.ts b/packages/agile-core/src/utils.ts index 93725d88..6b38af8f 100644 --- a/packages/agile-core/src/utils.ts +++ b/packages/agile-core/src/utils.ts @@ -1,7 +1,9 @@ -import State from "./state"; -import Agile from "./agile"; -import Event from "./event"; -import Collection from "./collection"; +import { + State, + Agile, + Event, + Collection +} from './internal'; //========================================================================================================= @@ -10,7 +12,6 @@ import Collection from "./collection"; /** * Copy an array or object.. without any dependencies */ - export function copy(value: T): T; export function copy>(value: T): T[]; export function copy(value: T): T | T[] { @@ -71,10 +72,10 @@ export function getAgileInstance(instance: any): Agile | null { if (instance instanceof State) return instance.agileInstance(); - if(instance instanceof Event) + if (instance instanceof Event) return instance.agileInstance(); - if(instance instanceof Collection) + if (instance instanceof Collection) return instance.agileInstance(); // Return the globalBind agile instance From ede794650286848bcfd658779b54163440c2e5fa Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Wed, 30 Sep 2020 17:17:22 +0200 Subject: [PATCH 04/15] x --- package-lock.json | 1267 ----------------- package.json | 6 +- packages/agile-api/package.json | 20 - packages/agile-api/tsconfig.json | 8 - packages/agile-core/package.json | 20 - packages/agile-core/src/state/dep.ts | 28 - packages/agile-core/src/use.ts | 93 -- packages/agile-core/tsconfig.json | 8 - packages/agile-react/package.json | 27 - packages/agile-react/src/hooks/useEvent.ts | 27 - packages/agile-react/src/react.integration.ts | 31 - packages/agile-react/tests/ReadMe.md | 1 - packages/agile-react/tests/hooks/useEvent.ts | 18 - packages/agile-react/tsconfig.json | 8 - packages/api/package.json | 23 + packages/{agile-api => api}/src/index.ts | 0 packages/api/tsconfig.json | 10 + packages/core/package-lock.json | 5 + packages/core/package.json | 20 + packages/{agile-core => core}/src/agile.ts | 29 +- .../src/collection/group.ts | 0 .../src/collection/index.ts | 0 .../src/collection/item.ts | 0 .../src/collection/perstist.ts | 0 .../src/collection/selector.ts | 0 .../src/computed/index.ts | 2 +- .../{agile-core => core}/src/event/index.ts | 4 +- packages/{agile-core => core}/src/index.ts | 0 packages/core/src/integrations.ts | 82 ++ packages/{agile-core => core}/src/internal.ts | 7 +- .../runtime.ts => core/src/runtime/index.ts} | 21 +- .../CallbackSubscriptionContainer.ts | 12 + .../ComponentSubscriptionContainer.ts | 19 + .../src/runtime/subscription}/sub.ts | 133 +- packages/core/src/state/dep.ts | 52 + .../{agile-core => core}/src/state/index.ts | 0 .../{agile-core => core}/src/state/persist.ts | 0 .../{agile-core => core}/src/storage/index.ts | 0 packages/{agile-core => core}/src/utils.ts | 0 .../tests/collection/default.spec.ts | 0 .../functions/collect.function.spec.ts | 15 +- .../functions/createGroup.function.spec.ts | 0 .../functions/createSelector.function.spec.ts | 0 .../functions/findById.function.spec.ts | 0 .../functions/getGroup.function.spec.ts | 0 .../functions/getSelector.function.spec.ts | 0 .../functions/getValueById.function.spec.ts | 0 .../functions/remove.function.spec.ts | 13 +- .../functions/update.function.spec.ts | 13 +- .../tests/collection/group/default.spec.ts | 13 +- .../group/functions/add.function.spec.ts | 13 +- .../group/functions/has.function.spec.ts | 0 .../group/functions/remove.function.spec.ts | 13 +- .../tests/collection/selector/default.spec.ts | 13 +- .../functions/select.function.spec.ts | 13 +- .../tests/computed/default.spec.ts | 13 +- .../updateComputeFunction.function.spec.ts | 13 +- .../tests/event/default.spec.ts | 0 .../event/functions/disable.function.spec.ts | 0 .../event/functions/enable.function.spec.ts | 0 .../tests/event/functions/on.function.spec.ts | 0 .../event/functions/reset.function.spec.ts | 0 .../event/functions/trigger.function.spec.ts | 3 +- .../tests/framework.spec.ts | 12 +- .../tests/state/default.spec.ts | 0 .../state/functions/patch.function.spec.ts | 13 +- .../state/functions/persist.function.spec.ts | 0 .../state/functions/reset.function.spec.ts | 13 +- .../state/functions/set.function.spec.ts | 13 +- .../state/functions/type.function.spec.ts | 0 .../state/functions/undo.function.spec.ts | 13 +- .../state/functions/watch.function.spec.ts | 0 .../tests/storage.spec.ts | 0 packages/core/tsconfig.json | 10 + packages/react/package.json | 30 + .../src/hooks/AgileHOC.ts | 15 +- .../src/hooks/useAgile.ts | 14 +- packages/react/src/hooks/useEvent.ts | 9 + packages/{agile-react => react}/src/index.ts | 0 packages/react/src/react.integration.ts | 26 + .../tests/hooks/useAgile.ts | 6 +- packages/react/tests/hooks/useEvent.ts | 5 + .../tests/hooks => react/tests}/index.ts | 4 + packages/react/tests/test.integration.ts | 15 + packages/react/tsconfig.json | 11 + packages/tsconfig.default.json | 4 +- 86 files changed, 469 insertions(+), 1860 deletions(-) delete mode 100644 package-lock.json delete mode 100644 packages/agile-api/package.json delete mode 100644 packages/agile-api/tsconfig.json delete mode 100644 packages/agile-core/package.json delete mode 100644 packages/agile-core/src/state/dep.ts delete mode 100644 packages/agile-core/src/use.ts delete mode 100644 packages/agile-core/tsconfig.json delete mode 100644 packages/agile-react/package.json delete mode 100644 packages/agile-react/src/hooks/useEvent.ts delete mode 100644 packages/agile-react/src/react.integration.ts delete mode 100644 packages/agile-react/tests/ReadMe.md delete mode 100644 packages/agile-react/tests/hooks/useEvent.ts delete mode 100644 packages/agile-react/tsconfig.json create mode 100644 packages/api/package.json rename packages/{agile-api => api}/src/index.ts (100%) create mode 100644 packages/api/tsconfig.json create mode 100644 packages/core/package-lock.json create mode 100644 packages/core/package.json rename packages/{agile-core => core}/src/agile.ts (90%) rename packages/{agile-core => core}/src/collection/group.ts (100%) rename packages/{agile-core => core}/src/collection/index.ts (100%) rename packages/{agile-core => core}/src/collection/item.ts (100%) rename packages/{agile-core => core}/src/collection/perstist.ts (100%) rename packages/{agile-core => core}/src/collection/selector.ts (100%) rename packages/{agile-core => core}/src/computed/index.ts (98%) rename packages/{agile-core => core}/src/event/index.ts (98%) rename packages/{agile-core => core}/src/index.ts (100%) create mode 100644 packages/core/src/integrations.ts rename packages/{agile-core => core}/src/internal.ts (70%) rename packages/{agile-core/src/runtime.ts => core/src/runtime/index.ts} (94%) create mode 100644 packages/core/src/runtime/subscription/CallbackSubscriptionContainer.ts create mode 100644 packages/core/src/runtime/subscription/ComponentSubscriptionContainer.ts rename packages/{agile-core/src => core/src/runtime/subscription}/sub.ts (60%) create mode 100644 packages/core/src/state/dep.ts rename packages/{agile-core => core}/src/state/index.ts (100%) rename packages/{agile-core => core}/src/state/persist.ts (100%) rename packages/{agile-core => core}/src/storage/index.ts (100%) rename packages/{agile-core => core}/src/utils.ts (100%) rename packages/{agile-core => core}/tests/collection/default.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/functions/collect.function.spec.ts (97%) rename packages/{agile-core => core}/tests/collection/functions/createGroup.function.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/functions/createSelector.function.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/functions/findById.function.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/functions/getGroup.function.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/functions/getSelector.function.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/functions/getValueById.function.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/functions/remove.function.spec.ts (95%) rename packages/{agile-core => core}/tests/collection/functions/update.function.spec.ts (95%) rename packages/{agile-core => core}/tests/collection/group/default.spec.ts (95%) rename packages/{agile-core => core}/tests/collection/group/functions/add.function.spec.ts (96%) rename packages/{agile-core => core}/tests/collection/group/functions/has.function.spec.ts (100%) rename packages/{agile-core => core}/tests/collection/group/functions/remove.function.spec.ts (92%) rename packages/{agile-core => core}/tests/collection/selector/default.spec.ts (92%) rename packages/{agile-core => core}/tests/collection/selector/functions/select.function.spec.ts (93%) rename packages/{agile-core => core}/tests/computed/default.spec.ts (93%) rename packages/{agile-core => core}/tests/computed/functions/updateComputeFunction.function.spec.ts (92%) rename packages/{agile-core => core}/tests/event/default.spec.ts (100%) rename packages/{agile-core => core}/tests/event/functions/disable.function.spec.ts (100%) rename packages/{agile-core => core}/tests/event/functions/enable.function.spec.ts (100%) rename packages/{agile-core => core}/tests/event/functions/on.function.spec.ts (100%) rename packages/{agile-core => core}/tests/event/functions/reset.function.spec.ts (100%) rename packages/{agile-core => core}/tests/event/functions/trigger.function.spec.ts (97%) rename packages/{agile-core => core}/tests/framework.spec.ts (64%) rename packages/{agile-core => core}/tests/state/default.spec.ts (100%) rename packages/{agile-core => core}/tests/state/functions/patch.function.spec.ts (94%) rename packages/{agile-core => core}/tests/state/functions/persist.function.spec.ts (100%) rename packages/{agile-core => core}/tests/state/functions/reset.function.spec.ts (84%) rename packages/{agile-core => core}/tests/state/functions/set.function.spec.ts (91%) rename packages/{agile-core => core}/tests/state/functions/type.function.spec.ts (100%) rename packages/{agile-core => core}/tests/state/functions/undo.function.spec.ts (84%) rename packages/{agile-core => core}/tests/state/functions/watch.function.spec.ts (100%) rename packages/{agile-core => core}/tests/storage.spec.ts (100%) create mode 100644 packages/core/tsconfig.json create mode 100644 packages/react/package.json rename packages/{agile-react => react}/src/hooks/AgileHOC.ts (83%) rename packages/{agile-react => react}/src/hooks/useAgile.ts (85%) create mode 100644 packages/react/src/hooks/useEvent.ts rename packages/{agile-react => react}/src/index.ts (100%) create mode 100644 packages/react/src/react.integration.ts rename packages/{agile-react => react}/tests/hooks/useAgile.ts (92%) create mode 100644 packages/react/tests/hooks/useEvent.ts rename packages/{agile-react/tests/hooks => react/tests}/index.ts (50%) create mode 100644 packages/react/tests/test.integration.ts create mode 100644 packages/react/tsconfig.json diff --git a/package-lock.json b/package-lock.json deleted file mode 100644 index 2ebbfae5..00000000 --- a/package-lock.json +++ /dev/null @@ -1,1267 +0,0 @@ -{ - "name": "agile", - "version": "1.0.2", - "lockfileVersion": 1, - "requires": true, - "dependencies": { - "@types/chai": { - "version": "4.2.12", - "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", - "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==" - }, - "@types/mocha": { - "version": "8.0.2", - "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.2.tgz", - "integrity": "sha512-5cv8rmqT3KX9XtWDvSgGYfS4OwrKM2eei90GWLnTYz+AXRiBv5uYcKBjnkQ4katNvfYk3+o2bHGZUsDhdcoUyg==" - }, - "@types/node": { - "version": "14.6.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-14.6.0.tgz", - "integrity": "sha512-mikldZQitV94akrc4sCcSjtJfsTKt4p+e/s0AGscVA6XArQ9kFclP+ZiYUMnq987rc6QlYxXv/EivqlfSLxpKA==" - }, - "ansi-colors": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", - "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==" - }, - "ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" - }, - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "requires": { - "color-convert": "^1.9.0" - } - }, - "arg": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" - }, - "argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "requires": { - "sprintf-js": "~1.0.2" - } - }, - "array.prototype.map": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", - "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", - "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.0-next.1", - "es-array-method-boxes-properly": "^1.0.0", - "is-string": "^1.0.4" - } - }, - "assertion-error": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", - "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" - }, - "balanced-match": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" - }, - "brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "browser-stdout": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", - "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==" - }, - "buffer-from": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", - "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==" - }, - "camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" - }, - "chai": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", - "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", - "requires": { - "assertion-error": "^1.1.0", - "check-error": "^1.0.2", - "deep-eql": "^3.0.1", - "get-func-name": "^2.0.0", - "pathval": "^1.1.0", - "type-detect": "^4.0.5" - } - }, - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - }, - "check-error": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", - "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=" - }, - "cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "requires": { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" - }, - "concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" - }, - "cross-spawn": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", - "requires": { - "path-key": "^3.1.0", - "shebang-command": "^2.0.0", - "which": "^2.0.1" - } - }, - "decamelize": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" - }, - "deep-eql": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", - "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", - "requires": { - "type-detect": "^4.0.0" - } - }, - "define-properties": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", - "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", - "requires": { - "object-keys": "^1.0.12" - } - }, - "diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" - }, - "duplexer": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", - "integrity": "sha1-rOb/gIwc5mtX0ev5eXessCM0z8E=" - }, - "emoji-regex": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", - "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" - }, - "es-abstract": { - "version": "1.17.6", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", - "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", - "requires": { - "es-to-primitive": "^1.2.1", - "function-bind": "^1.1.1", - "has": "^1.0.3", - "has-symbols": "^1.0.1", - "is-callable": "^1.2.0", - "is-regex": "^1.1.0", - "object-inspect": "^1.7.0", - "object-keys": "^1.1.1", - "object.assign": "^4.1.0", - "string.prototype.trimend": "^1.0.1", - "string.prototype.trimstart": "^1.0.1" - } - }, - "es-array-method-boxes-properly": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", - "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==" - }, - "es-get-iterator": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", - "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", - "requires": { - "es-abstract": "^1.17.4", - "has-symbols": "^1.0.1", - "is-arguments": "^1.0.4", - "is-map": "^2.0.1", - "is-set": "^2.0.1", - "is-string": "^1.0.5", - "isarray": "^2.0.5" - }, - "dependencies": { - "isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" - } - } - }, - "es-to-primitive": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", - "requires": { - "is-callable": "^1.1.4", - "is-date-object": "^1.0.1", - "is-symbol": "^1.0.2" - } - }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=" - }, - "eslint-config-prettier": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.11.0.tgz", - "integrity": "sha512-oB8cpLWSAjOVFEJhhyMZh6NOEOtBVziaqdDQ86+qhDHFbZXoRTM7pNSvFRfW/W/L/LrQ38C99J5CGuRBBzBsdA==", - "requires": { - "get-stdin": "^6.0.0" - } - }, - "esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" - }, - "event-stream": { - "version": "3.3.4", - "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", - "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", - "requires": { - "duplexer": "~0.1.1", - "from": "~0", - "map-stream": "~0.1.0", - "pause-stream": "0.0.11", - "split": "0.3", - "stream-combiner": "~0.0.4", - "through": "~2.3.1" - } - }, - "find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", - "requires": { - "locate-path": "^5.0.0", - "path-exists": "^4.0.0" - } - }, - "flat": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", - "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", - "requires": { - "is-buffer": "~2.0.3" - }, - "dependencies": { - "is-buffer": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", - "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==" - } - } - }, - "from": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", - "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=" - }, - "fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" - }, - "function-bind": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" - }, - "get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" - }, - "get-func-name": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", - "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=" - }, - "get-stdin": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", - "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==" - }, - "glob": { - "version": "7.1.6", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", - "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "growl": { - "version": "1.10.5", - "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", - "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==" - }, - "has": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", - "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", - "requires": { - "function-bind": "^1.1.1" - } - }, - "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=" - }, - "has-symbols": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", - "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==" - }, - "he": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", - "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==" - }, - "inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "requires": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" - }, - "is-arguments": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", - "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==" - }, - "is-callable": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.0.tgz", - "integrity": "sha512-pyVD9AaGLxtg6srb2Ng6ynWJqkHU9bEM087AKck0w8QwDarTfNcpIYoU8x8Hv2Icm8u6kFJM18Dag8lyqGkviw==" - }, - "is-date-object": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", - "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==" - }, - "is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" - }, - "is-glob": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", - "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", - "requires": { - "is-extglob": "^2.1.1" - } - }, - "is-map": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", - "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==" - }, - "is-plain-obj": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", - "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=" - }, - "is-regex": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", - "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", - "requires": { - "has-symbols": "^1.0.1" - } - }, - "is-set": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", - "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==" - }, - "is-string": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", - "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==" - }, - "is-symbol": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", - "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", - "requires": { - "has-symbols": "^1.0.1" - } - }, - "isexe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" - }, - "iterate-iterator": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", - "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==" - }, - "iterate-value": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", - "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", - "requires": { - "es-get-iterator": "^1.0.2", - "iterate-iterator": "^1.0.1" - } - }, - "js-yaml": { - "version": "3.13.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", - "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", - "requires": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - } - }, - "locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "requires": { - "p-locate": "^4.1.0" - } - }, - "log-symbols": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", - "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", - "requires": { - "chalk": "^2.4.2" - } - }, - "make-error": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" - }, - "map-stream": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", - "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=" - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "mocha": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.1.tgz", - "integrity": "sha512-p7FuGlYH8t7gaiodlFreseLxEmxTgvyG9RgPHODFPySNhwUehu8NIb0vdSt3WFckSneswZ0Un5typYcWElk7HQ==", - "requires": { - "ansi-colors": "4.1.1", - "browser-stdout": "1.3.1", - "chokidar": "3.3.1", - "debug": "3.2.6", - "diff": "4.0.2", - "escape-string-regexp": "1.0.5", - "find-up": "4.1.0", - "glob": "7.1.6", - "growl": "1.10.5", - "he": "1.2.0", - "js-yaml": "3.13.1", - "log-symbols": "3.0.0", - "minimatch": "3.0.4", - "ms": "2.1.2", - "object.assign": "4.1.0", - "promise.allsettled": "1.0.2", - "serialize-javascript": "4.0.0", - "strip-json-comments": "3.0.1", - "supports-color": "7.1.0", - "which": "2.0.2", - "wide-align": "1.1.3", - "workerpool": "6.0.0", - "yargs": "13.3.2", - "yargs-parser": "13.1.2", - "yargs-unparser": "1.6.1" - }, - "dependencies": { - "anymatch": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", - "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", - "requires": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - } - }, - "binary-extensions": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", - "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==" - }, - "braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "requires": { - "fill-range": "^7.0.1" - } - }, - "chokidar": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.1.tgz", - "integrity": "sha512-4QYCEWOcK3OJrxwvyyAOxFuhpvOVCYkr33LPfFNBjAD/w3sEzWsp2BUOkI4l9bHvWioAd0rc6NlHUOEaWkTeqg==", - "requires": { - "anymatch": "~3.1.1", - "braces": "~3.0.2", - "fsevents": "~2.1.2", - "glob-parent": "~5.1.0", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.3.0" - } - }, - "debug": { - "version": "3.2.6", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", - "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", - "requires": { - "ms": "^2.1.1" - } - }, - "fill-range": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "requires": { - "to-regex-range": "^5.0.1" - } - }, - "fsevents": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", - "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", - "optional": true - }, - "glob-parent": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", - "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", - "requires": { - "is-glob": "^4.0.1" - } - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" - }, - "is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "requires": { - "binary-extensions": "^2.0.0" - } - }, - "is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" - }, - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" - }, - "readdirp": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.3.0.tgz", - "integrity": "sha512-zz0pAkSPOXXm1viEwygWIPSPkcBYjW1xU5j/JBh5t9bGCJwa6f9+BJa6VaB2g+b55yVrmXzqkyLf4xaWYM0IkQ==", - "requires": { - "picomatch": "^2.0.7" - } - }, - "supports-color": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", - "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", - "requires": { - "has-flag": "^4.0.0" - } - }, - "to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "requires": { - "is-number": "^7.0.0" - } - } - } - }, - "node-cleanup": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", - "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=" - }, - "normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" - }, - "object-inspect": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", - "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==" - }, - "object-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" - }, - "object.assign": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", - "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", - "requires": { - "define-properties": "^1.1.2", - "function-bind": "^1.1.1", - "has-symbols": "^1.0.0", - "object-keys": "^1.0.11" - } - }, - "once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "requires": { - "wrappy": "1" - } - }, - "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", - "requires": { - "p-limit": "^2.2.0" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==" - }, - "path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==" - }, - "path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" - }, - "path-key": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", - "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==" - }, - "pathval": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", - "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=" - }, - "pause-stream": { - "version": "0.0.11", - "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", - "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", - "requires": { - "through": "~2.3" - } - }, - "picomatch": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", - "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==" - }, - "prettier": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", - "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==" - }, - "promise.allsettled": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", - "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", - "requires": { - "array.prototype.map": "^1.0.1", - "define-properties": "^1.1.3", - "es-abstract": "^1.17.0-next.1", - "function-bind": "^1.1.1", - "iterate-value": "^1.0.0" - } - }, - "ps-tree": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", - "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", - "requires": { - "event-stream": "=3.3.4" - } - }, - "randombytes": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", - "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", - "requires": { - "safe-buffer": "^5.1.0" - } - }, - "require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" - }, - "require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" - }, - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" - }, - "serialize-javascript": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", - "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", - "requires": { - "randombytes": "^2.1.0" - } - }, - "set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" - }, - "shebang-command": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "requires": { - "shebang-regex": "^3.0.0" - } - }, - "shebang-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" - }, - "source-map-support": { - "version": "0.5.19", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", - "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", - "requires": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" - } - } - }, - "split": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", - "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", - "requires": { - "through": "2" - } - }, - "sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" - }, - "stream-combiner": { - "version": "0.0.4", - "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", - "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", - "requires": { - "duplexer": "~0.1.1" - } - }, - "string-argv": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", - "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==" - }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "requires": { - "ansi-regex": "^3.0.0" - } - } - } - }, - "string.prototype.trimend": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", - "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", - "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.5" - } - }, - "string.prototype.trimstart": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", - "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", - "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.5" - } - }, - "strip-ansi": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", - "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", - "requires": { - "ansi-regex": "^5.0.0" - } - }, - "strip-json-comments": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", - "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==" - }, - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "requires": { - "has-flag": "^3.0.0" - } - }, - "through": { - "version": "2.3.8", - "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", - "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=" - }, - "ts-node": { - "version": "8.10.2", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", - "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", - "requires": { - "arg": "^4.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.17", - "yn": "3.1.1" - } - }, - "tsc-watch": { - "version": "4.2.9", - "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", - "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", - "requires": { - "cross-spawn": "^7.0.3", - "node-cleanup": "^2.1.2", - "ps-tree": "^1.2.0", - "string-argv": "^0.1.1", - "strip-ansi": "^6.0.0" - } - }, - "tslib": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", - "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==" - }, - "type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" - }, - "typescript": { - "version": "3.9.7", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", - "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==" - }, - "which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "requires": { - "isexe": "^2.0.0" - } - }, - "which-module": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" - }, - "wide-align": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", - "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", - "requires": { - "string-width": "^1.0.2 || 2" - } - }, - "workerpool": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", - "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==" - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - }, - "y18n": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", - "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" - }, - "yargs": { - "version": "13.3.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", - "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.2" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "requires": { - "locate-path": "^3.0.0" - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "requires": { - "p-limit": "^2.0.0" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "yargs-parser": { - "version": "13.1.2", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", - "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - }, - "yargs-unparser": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", - "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", - "requires": { - "camelcase": "^5.3.1", - "decamelize": "^1.2.0", - "flat": "^4.1.0", - "is-plain-obj": "^1.1.0", - "yargs": "^14.2.3" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "requires": { - "locate-path": "^3.0.0" - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "requires": { - "p-limit": "^2.0.0" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "yargs": { - "version": "14.2.3", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", - "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", - "requires": { - "cliui": "^5.0.0", - "decamelize": "^1.2.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^15.0.1" - } - }, - "yargs-parser": { - "version": "15.0.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", - "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - } - } - }, - "yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" - } - } -} diff --git a/package.json b/package.json index 95b02f34..c295c39a 100644 --- a/package.json +++ b/package.json @@ -5,9 +5,9 @@ "license": "ISC", "syncDir": "dist", "scripts": { - "build": "tsc", - "dev": "tsc-watch", - "test": "mocha -r ts-node/register --exit test/**/*.spec.ts", + "build": "tsc -b packages/core packages/react packages/api", + "dev": "tsc-watch -b packages/core packages/react packages/api", + "test": "mocha -r ts-node/register --exit packages/**/*.spec.ts", "prepare": "npm run build", "prepublishOnly": "npm test", "version": "npm run format && git add -A src", diff --git a/packages/agile-api/package.json b/packages/agile-api/package.json deleted file mode 100644 index fed7a89c..00000000 --- a/packages/agile-api/package.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "name": "@agile-ts/core", - "version": "0.0.1", - "author": "BennoDev", - "license": "ISC", - "description": "API extention for AgileTs", - "keywords": [], - "main": "dist/index.js", - "types": "dist/index.d.ts", - "scripts": { - "build": "tsc" - }, - "publishConfig": { - "access": "public" - }, - "repository": { - "type": "git", - "url": "https://github.com/agile-ts/agile.git" - } - } \ No newline at end of file diff --git a/packages/agile-api/tsconfig.json b/packages/agile-api/tsconfig.json deleted file mode 100644 index e6529093..00000000 --- a/packages/agile-api/tsconfig.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "extends": "../tsconfig.default.json", - "compilerOptions": { - "rootDir": "src", - "outDir": "dist" - }, - "include": ["./src/**/*"] // Only include what is in src (dist, tests, .. will be excluded) - } \ No newline at end of file diff --git a/packages/agile-core/package.json b/packages/agile-core/package.json deleted file mode 100644 index 3a4ab6da..00000000 --- a/packages/agile-core/package.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "name": "@agile-ts/core", - "version": "0.0.1", - "author": "BennoDev", - "license": "ISC", - "description": "Global state and logic framework for reactive JavaScript & TypeScript applications.", - "keywords": [], - "main": "dist/index.js", - "types": "dist/index.d.ts", - "scripts": { - "build": "tsc" - }, - "publishConfig": { - "access": "public" - }, - "repository": { - "type": "git", - "url": "https://github.com/agile-ts/agile.git" - } - } \ No newline at end of file diff --git a/packages/agile-core/src/state/dep.ts b/packages/agile-core/src/state/dep.ts deleted file mode 100644 index ccf0b619..00000000 --- a/packages/agile-core/src/state/dep.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { - State, - SubscriptionContainer -} from '../internal'; - -export class Dep { - public deps: Set = new Set(); // Dependencies from the State - public subs: Set = new Set(); // Subscriptions for instance a component subscribes to a state to get rerendered if the state changes - - constructor(initialDeps?: Array) { - if (!initialDeps) return; - - // Add Initial Dependencies to Deps - initialDeps.forEach(dep => this.deps.add(dep)); - } - - - //========================================================================================================= - // Depend - //========================================================================================================= - /** - * Add new State as dependency - */ - public depend(state: State) { - if (state.dep !== this && !this.deps.has(state)) - this.deps.add(state); - } -} diff --git a/packages/agile-core/src/use.ts b/packages/agile-core/src/use.ts deleted file mode 100644 index d0c7aea5..00000000 --- a/packages/agile-core/src/use.ts +++ /dev/null @@ -1,93 +0,0 @@ -import {Agile} from './internal'; - -export interface Integration { - ready?: boolean; - frameworkConstructor?: any; // The actual framework for instance React - name?: any; // The name of the framework - bind?: (agileInstance: Agile) => void; // Will be called if the framework got successful instantiated - updateMethod?: (componentInstance: any, updatedData: Object) => void; // Will be called if a State changes (Only by Component based Subscription) -} - -// Required Properties of a custom Integration -const requiredIntegrationProperties = ['name', 'bind', 'updateMethod']; - -// This Integration will injected into Agile.integration -const finalIntegration: Integration = { - ready: false -}; - -export default function use(framework: any, agileInstance: Agile) { - const frameworkName = getFrameworkName(framework); - - // Integrate Framework - switch (frameworkName) { - case 'react': - integrate(reactIntegration, 'react'); - break; - - case 'custom': - if (validateCustomFramework(framework as Integration)) - integrate(framework, 'custom'); - break; - - default: - // Should never happen - } - - // Assign Framework Constructor to framework if its not a custom framework - // because custom Frameworks has to set the frameworkConstructor (direct dependency to Framework (React)) on their own - // and have to pass an Integration and not directly a framework - if (frameworkName !== 'custom') - finalIntegration.frameworkConstructor = framework; - - // Inject Integration into Agile - agileInstance.integration = finalIntegration; - - // If the Integration is ready call integration.bind() - if (agileInstance.integration.ready) { - if (agileInstance.integration.bind) - agileInstance.integration.bind(agileInstance); - if (agileInstance.config.logJobs) console.log(`Agile: Successfully integrated '${frameworkName}'`); - } else - console.error('Agile: Failed to integrate with framework! It\'s possible you didn\'t call Pulse.initFrameworkIntegration() before new Pulse.'); -} - - -//========================================================================================================= -// Helper -//========================================================================================================= - -function integrate(frameworkIntegration: Integration, frameworkName: string) { - // Bind all properties from integration to our main Integration Object - Object.keys(frameworkIntegration).forEach(property => { - // @ts-ignore - finalIntegration[property] = frameworkIntegration[property]; - }); - - // Assign Name - finalIntegration.name = frameworkIntegration.name || frameworkName; - - // Set Integration to Ready (can be used) - finalIntegration.ready = true; -} - -function validateCustomFramework(customIntegration: Integration): boolean { - let valid: boolean = true; - - // Check if custom Integration has all required properties - requiredIntegrationProperties.forEach(property => { - if (!customIntegration.hasOwnProperty(property)) valid = false; - }); - - return valid; -} - -function getFrameworkName(frameworkConstructor: any): string { - let name: string = 'custom'; - - // Check if framework is React - if (frameworkConstructor.hasOwnProperty('__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED')) - return 'react'; - - return name; -} diff --git a/packages/agile-core/tsconfig.json b/packages/agile-core/tsconfig.json deleted file mode 100644 index e6529093..00000000 --- a/packages/agile-core/tsconfig.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "extends": "../tsconfig.default.json", - "compilerOptions": { - "rootDir": "src", - "outDir": "dist" - }, - "include": ["./src/**/*"] // Only include what is in src (dist, tests, .. will be excluded) - } \ No newline at end of file diff --git a/packages/agile-react/package.json b/packages/agile-react/package.json deleted file mode 100644 index fa5d6cf0..00000000 --- a/packages/agile-react/package.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "name": "@agile-ts/core", - "version": "0.0.1", - "author": "BennoDev", - "license": "ISC", - "description": "React extention for AgileTs", - "keywords": [], - "main": "dist/index.js", - "types": "dist/index.d.ts", - "scripts": { - "build": "tsc" - }, - "peerDependencies": { - "@agile-ts/core": "^0.0.2", - "react": "^16.13.1" - }, - "devDependencies": { - "@types/react": "^16.9.49" - }, - "publishConfig": { - "access": "public" - }, - "repository": { - "type": "git", - "url": "https://github.com/agile-ts/agile.git" - } - } \ No newline at end of file diff --git a/packages/agile-react/src/hooks/useEvent.ts b/packages/agile-react/src/hooks/useEvent.ts deleted file mode 100644 index 7bf99370..00000000 --- a/packages/agile-react/src/hooks/useEvent.ts +++ /dev/null @@ -1,27 +0,0 @@ -import Event, {EventCallbackFunction} from "../../../event"; -import Agile from "../../../index"; -import {getAgileInstance} from "../../../utils"; - -export function useEvent(event: E, callback: EventCallbackFunction, agileInstance?: Agile) { - // Get Agile Instance - if (!agileInstance) { - const tempAgileInstance = getAgileInstance(event); - if (!tempAgileInstance) { - console.error("Agile: Failed to get Agile Instance"); - return; - } - agileInstance = tempAgileInstance; - } - - // Get React constructor - const React = agileInstance.integration?.frameworkConstructor; - if (!React) { - console.error("Agile: Failed to get Framework Constructor"); - return; - } - - React.useEffect(function () { - // Call event on component mount and remove event on component unmount - return event.on(callback); - }, []); -} diff --git a/packages/agile-react/src/react.integration.ts b/packages/agile-react/src/react.integration.ts deleted file mode 100644 index 6fe0e05c..00000000 --- a/packages/agile-react/src/react.integration.ts +++ /dev/null @@ -1,31 +0,0 @@ -import Agile from "../../index"; -import {Integration} from "../use"; - - -//========================================================================================================= -// Framework Integration -//========================================================================================================= - -const reactIntegration: Integration = { - name: 'react', - bind(agileInstance: Agile) { - // Not sure if usePulse should get into the pulseInstance - // pulseInstance.usePulse = (deps: Array) => usePulse(deps, pulseInstance); - // if (agileInstance.config.logJobs) console.log("Agile: Successfully binded React to Agile") - }, - updateMethod(componentInstance: any, updatedData: Object) { - // UpdatedData will be empty if the AgileHOC doesn't get an object as deps - - if (Object.keys(updatedData).length !== 0) { - // Update Props - componentInstance.updatedProps = {...componentInstance.updatedProps, ...updatedData}; - - // Set State - componentInstance.setState(updatedData); - } else { - componentInstance.forceUpdate(); - } - } -}; - -export default reactIntegration; diff --git a/packages/agile-react/tests/ReadMe.md b/packages/agile-react/tests/ReadMe.md deleted file mode 100644 index 914afcb5..00000000 --- a/packages/agile-react/tests/ReadMe.md +++ /dev/null @@ -1 +0,0 @@ -Note: the react hook will be tested in the agile-core tests \ No newline at end of file diff --git a/packages/agile-react/tests/hooks/useEvent.ts b/packages/agile-react/tests/hooks/useEvent.ts deleted file mode 100644 index 513ea7c7..00000000 --- a/packages/agile-react/tests/hooks/useEvent.ts +++ /dev/null @@ -1,18 +0,0 @@ -import Event, {EventCallbackFunction} from "../../../event"; -import Agile from "../../../index"; -import {getAgileInstance} from "../../../utils"; - -export function useEvent(event: E, callback: EventCallbackFunction, agileInstance?: Agile) { - // Get Agile Instance - if (!agileInstance) { - const tempAgileInstance = getAgileInstance(event); - if (!tempAgileInstance) { - console.error("Agile: Failed to get Agile Instance"); - return; - } - agileInstance = tempAgileInstance; - } - - // Call on Event - event.on(callback); -} diff --git a/packages/agile-react/tsconfig.json b/packages/agile-react/tsconfig.json deleted file mode 100644 index e6529093..00000000 --- a/packages/agile-react/tsconfig.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "extends": "../tsconfig.default.json", - "compilerOptions": { - "rootDir": "src", - "outDir": "dist" - }, - "include": ["./src/**/*"] // Only include what is in src (dist, tests, .. will be excluded) - } \ No newline at end of file diff --git a/packages/api/package.json b/packages/api/package.json new file mode 100644 index 00000000..5cccf276 --- /dev/null +++ b/packages/api/package.json @@ -0,0 +1,23 @@ +{ + "name": "@agile/api", + "version": "0.0.1", + "author": "BennoDev", + "license": "ISC", + "description": "API extention for AgileTs", + "keywords": [], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "build": "tsc" + }, + "dependencies": { + "@agile/core": "link:../core" + }, + "publishConfig": { + "access": "public" + }, + "repository": { + "type": "git", + "url": "https://github.com/agile-ts/agile.git" + } +} \ No newline at end of file diff --git a/packages/agile-api/src/index.ts b/packages/api/src/index.ts similarity index 100% rename from packages/agile-api/src/index.ts rename to packages/api/src/index.ts diff --git a/packages/api/tsconfig.json b/packages/api/tsconfig.json new file mode 100644 index 00000000..600cd205 --- /dev/null +++ b/packages/api/tsconfig.json @@ -0,0 +1,10 @@ +{ + "extends": "../tsconfig.default.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "dist" + }, + "include": [ + "./src/**/*" // Only include what is in src (-> dist, tests, .. will be excluded) + ] +} \ No newline at end of file diff --git a/packages/core/package-lock.json b/packages/core/package-lock.json new file mode 100644 index 00000000..84d5ac9d --- /dev/null +++ b/packages/core/package-lock.json @@ -0,0 +1,5 @@ +{ + "name": "@agile/core", + "version": "0.0.1", + "lockfileVersion": 1 +} diff --git a/packages/core/package.json b/packages/core/package.json new file mode 100644 index 00000000..1909ff39 --- /dev/null +++ b/packages/core/package.json @@ -0,0 +1,20 @@ +{ + "name": "@agile/core", + "version": "0.0.1", + "author": "BennoDev", + "license": "ISC", + "description": "Global state and logic framework for reactive JavaScript & TypeScript applications.", + "keywords": [], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "build": "tsc" + }, + "publishConfig": { + "access": "public" + }, + "repository": { + "type": "git", + "url": "https://github.com/agile-ts/agile.git" + } +} diff --git a/packages/agile-core/src/agile.ts b/packages/core/src/agile.ts similarity index 90% rename from packages/agile-core/src/agile.ts rename to packages/core/src/agile.ts index 14b6a840..596b576d 100644 --- a/packages/agile-core/src/agile.ts +++ b/packages/core/src/agile.ts @@ -11,12 +11,10 @@ import { Computed, Event, EventConfig, - DefaultEventPayload, - use + DefaultEventPayload, Integrations } from './internal' export interface AgileConfigInterface { - framework?: Integration | any // Integration = for custom frameworks | any = for existing frameworks like react logJobs?: boolean // If Agile should log some stuff in the console waitForMount?: boolean // If Agile should wait until the component mounted (note working yet) storageConfig?: StorageConfigInterface // For custom storage (default: Local Storage) @@ -25,20 +23,21 @@ export interface AgileConfigInterface { export class Agile { public runtime: Runtime; - public integration: Integration | null = null; public subController: SubController; public storage: Storage; + // Integrations + public integrations: Integrations; + static initialIntegrations: Integration[] = []; + constructor(public config: AgileConfigInterface = {}) { + this.integrations = new Integrations(this); this.subController = new SubController(this); this.runtime = new Runtime(this); this.storage = new Storage(this, config.storageConfig || {}); - // Init Framework - if (config.framework) - this.initFrameworkIntegration(config.framework); - else - console.warn("Agile: Don't forget to init a framework before using Agile") + // Bind Frameworks to Agile + this.integrations.bind(); // Creates a global agile instance.. this.globalBind(); @@ -46,13 +45,14 @@ export class Agile { //========================================================================================================= - // Init Framework + // Use //========================================================================================================= /** - * Init a Framework like React or a custom one + * Use custom Integration */ - public initFrameworkIntegration(frameworkConstructor: any) { - use(frameworkConstructor, this); + public use(integration: Integration) { + this.integrations.integrate(integration); + return this; } @@ -95,6 +95,9 @@ export class Agile { //========================================================================================================= /** * Create Agile Collection + * @param config object | function returning object + * @param config.primaryKey string - The primary key for the collection. + * @param config.groups object - Define groups for this collection. */ public Collection = (config?: CollectionConfig) => new Collection(this, config); diff --git a/packages/agile-core/src/collection/group.ts b/packages/core/src/collection/group.ts similarity index 100% rename from packages/agile-core/src/collection/group.ts rename to packages/core/src/collection/group.ts diff --git a/packages/agile-core/src/collection/index.ts b/packages/core/src/collection/index.ts similarity index 100% rename from packages/agile-core/src/collection/index.ts rename to packages/core/src/collection/index.ts diff --git a/packages/agile-core/src/collection/item.ts b/packages/core/src/collection/item.ts similarity index 100% rename from packages/agile-core/src/collection/item.ts rename to packages/core/src/collection/item.ts diff --git a/packages/agile-core/src/collection/perstist.ts b/packages/core/src/collection/perstist.ts similarity index 100% rename from packages/agile-core/src/collection/perstist.ts rename to packages/core/src/collection/perstist.ts diff --git a/packages/agile-core/src/collection/selector.ts b/packages/core/src/collection/selector.ts similarity index 100% rename from packages/agile-core/src/collection/selector.ts rename to packages/core/src/collection/selector.ts diff --git a/packages/agile-core/src/computed/index.ts b/packages/core/src/computed/index.ts similarity index 98% rename from packages/agile-core/src/computed/index.ts rename to packages/core/src/computed/index.ts index 841631bb..f4da511c 100644 --- a/packages/agile-core/src/computed/index.ts +++ b/packages/core/src/computed/index.ts @@ -78,7 +78,7 @@ export class Computed extends State const computedValue = this.computeFunction(); // Get tracked states and set trackSate to false - let foundStates = this.agileInstance().runtime.getFoundStates(); + let foundStates = this.agileInstance().runtime.getTrackedStates(); // Handle foundStates dependencies const newDeps: Array = []; diff --git a/packages/agile-core/src/event/index.ts b/packages/core/src/event/index.ts similarity index 98% rename from packages/agile-core/src/event/index.ts rename to packages/core/src/event/index.ts index 0f862349..1a4435ea 100644 --- a/packages/agile-core/src/event/index.ts +++ b/packages/core/src/event/index.ts @@ -1,6 +1,4 @@ -import Agile from "../agile"; -import {defineConfig} from "../utils"; -import {StateKey} from "../state"; +import {Agile, StateKey, defineConfig} from '../internal'; export type DefaultEventPayload = { [key: string]: any }; export type EventCallbackFunction = (payload?: PayloadType) => void; diff --git a/packages/agile-core/src/index.ts b/packages/core/src/index.ts similarity index 100% rename from packages/agile-core/src/index.ts rename to packages/core/src/index.ts diff --git a/packages/core/src/integrations.ts b/packages/core/src/integrations.ts new file mode 100644 index 00000000..5e3a2ad5 --- /dev/null +++ b/packages/core/src/integrations.ts @@ -0,0 +1,82 @@ +import {Agile} from './internal'; + +export interface IntegrationConfig { + name?: any; // The name of the framework + frameworkInstance?: F // The actual framework for instance React + bind?: (agileInstance: Agile) => void // Will be called if the framework got successful instantiated + updateMethod?: (componentInstance: any, updatedData: Object) => void // Will be called if a State changes (Only by Component based Subscription) +} + +export class Integration { + public ready?: boolean; + public config: IntegrationConfig; + + constructor(config: IntegrationConfig) { + this.config = config; + } +} + +export class Integrations { + public agileInstance: () => Agile; + + public loadedIntegrations: Set = new Set(); + + constructor(agileInstance: Agile) { + this.agileInstance = () => agileInstance; + + // Integrate initial Integrations + if (Agile.initialIntegrations) + Agile.initialIntegrations.forEach(integration => this.integrate(integration)); + } + + + //========================================================================================================= + // Integrate + //========================================================================================================= + /** + * Integrates a framework into Agile + */ + public integrate(integration: Integration) { + if (!(integration instanceof Integration) || !integration.config.name) { + console.error('Agile: Failed to integrate framework!'); + return; + } + + this.loadedIntegrations.add(integration); + if (this.agileInstance().config.logJobs) + console.log(`Agile: Successfully integrated '${integration.config.name}'`); + } + + + //========================================================================================================= + // Bind + //========================================================================================================= + /** + * Binds the Framework to Agile + */ + public bind() { + this.loadedIntegrations.forEach(integration => integration.config.bind && integration.config.bind(this.agileInstance())); + } + + + //========================================================================================================= + // Update + //========================================================================================================= + /** + * Updates Framework States + */ + public update(componentInstance: any, updatedData: Object) { + this.loadedIntegrations.forEach(integration => integration.config.updateMethod && integration.config.updateMethod(componentInstance, updatedData)); + } + + + //========================================================================================================= + // Has Integration + //========================================================================================================= + /** + * Checks weather integrations are registered + */ + public hasIntegration() { + return this.loadedIntegrations.size > 0; + } +} \ No newline at end of file diff --git a/packages/agile-core/src/internal.ts b/packages/core/src/internal.ts similarity index 70% rename from packages/agile-core/src/internal.ts rename to packages/core/src/internal.ts index 63ed72b4..6b4a6da2 100644 --- a/packages/agile-core/src/internal.ts +++ b/packages/core/src/internal.ts @@ -24,5 +24,8 @@ export {Dep} from './state/dep'; // Internal Classes export * from './runtime'; export * from './storage'; -export * from './sub'; -export * from './utils'; \ No newline at end of file +export * from './runtime/subscription/sub'; +export * from './utils'; +export * from './integrations'; +export * from './runtime/subscription/CallbackSubscriptionContainer'; +export * from './runtime/subscription/ComponentSubscriptionContainer'; \ No newline at end of file diff --git a/packages/agile-core/src/runtime.ts b/packages/core/src/runtime/index.ts similarity index 94% rename from packages/agile-core/src/runtime.ts rename to packages/core/src/runtime/index.ts index 1403f3be..13d82622 100644 --- a/packages/agile-core/src/runtime.ts +++ b/packages/core/src/runtime/index.ts @@ -1,12 +1,13 @@ import { State, Agile, - CallbackContainer, - SubscriptionContainer, Computed, + SubscriptionContainer, copy, defineConfig -} from './internal'; +} from '../internal'; +import {ComponentSubscriptionContainer} from "./subscription/ComponentSubscriptionContainer"; +import {CallbackSubscriptionContainer} from "./subscription/CallbackSubscriptionContainer"; export interface JobInterface { state: State @@ -194,7 +195,7 @@ export class Runtime { private updateSubscribers(): void { // Check if Agile has an integration because its useless to go trough this process without framework // It won't happen anything because the state has no subs.. but this check here will maybe improve the performance - if (!this.agileInstance().integration) { + if (!this.agileInstance().integrations.hasIntegration()) { this.jobsToRerender = []; return; } @@ -229,17 +230,13 @@ export class Runtime { // Perform Component or Callback updates subscriptionsToUpdate.forEach(subscriptionContainer => { // If Callback based subscription call the Callback Function - if (subscriptionContainer instanceof CallbackContainer) { + if (subscriptionContainer instanceof CallbackSubscriptionContainer) { subscriptionContainer.callback(); return; } - // If Component based subscription call the updateMethod which every framework has to define - if (this.agileInstance().integration?.updateMethod) - // @ts-ignore - this.agileInstance().integration?.updateMethod(subscriptionContainer.component, this.formatChangedPropKeys(subscriptionContainer)); - else - console.warn("Agile: The framework which you are using doesn't provide an updateMethod so it might be possible that no rerender will be triggered"); + // If Component based subscription call the updateMethod + this.agileInstance().integrations.update(subscriptionContainer.component, this.formatChangedPropKeys(subscriptionContainer)); }); // Log Job @@ -278,7 +275,7 @@ export class Runtime { * @internal * Will return all tracked States */ - public getFoundStates() { + public getTrackedStates() { const finalFoundStates = this.foundStates; // Reset tracking diff --git a/packages/core/src/runtime/subscription/CallbackSubscriptionContainer.ts b/packages/core/src/runtime/subscription/CallbackSubscriptionContainer.ts new file mode 100644 index 00000000..4f2868bf --- /dev/null +++ b/packages/core/src/runtime/subscription/CallbackSubscriptionContainer.ts @@ -0,0 +1,12 @@ +import {State} from "../../internal"; +import {ComponentSubscriptionContainer} from "./ComponentSubscriptionContainer"; + +export class CallbackSubscriptionContainer extends ComponentSubscriptionContainer { + public callback: Function; + + constructor(callback: Function, subs?: Set) { + super(null, subs); + + this.callback = callback; + } +} \ No newline at end of file diff --git a/packages/core/src/runtime/subscription/ComponentSubscriptionContainer.ts b/packages/core/src/runtime/subscription/ComponentSubscriptionContainer.ts new file mode 100644 index 00000000..36e1fc74 --- /dev/null +++ b/packages/core/src/runtime/subscription/ComponentSubscriptionContainer.ts @@ -0,0 +1,19 @@ +import {State} from "../../internal"; + +export class ComponentSubscriptionContainer { + public component: any; + + // Only needed by object orientated subscriptions + public passProps: boolean = false; + public propStates?: { [key: string]: State }; // states which will than be returned as prop object by the integration + public propKeysChanged: Array = []; // Used to preserve local keys to update before update is performed, cleared every update + + public ready: boolean = false; + public subs: Set = new Set([]); // States that are subscribed by this component + + constructor(component: any, subs?: Set) { + this.component = component + if (subs) + this.subs = subs; + } +} \ No newline at end of file diff --git a/packages/agile-core/src/sub.ts b/packages/core/src/runtime/subscription/sub.ts similarity index 60% rename from packages/agile-core/src/sub.ts rename to packages/core/src/runtime/subscription/sub.ts index 9f33eb30..7cb8137a 100644 --- a/packages/agile-core/src/sub.ts +++ b/packages/core/src/runtime/subscription/sub.ts @@ -1,49 +1,13 @@ -import {Agile, State} from './internal'; +import {Agile, State} from '../../internal'; +import {ComponentSubscriptionContainer} from "./ComponentSubscriptionContainer"; +import {CallbackSubscriptionContainer} from "./CallbackSubscriptionContainer"; //========================================================================================================= // Subscription Container //========================================================================================================= -export type SubscriptionContainer = ComponentContainer | CallbackContainer; - - -//========================================================================================================= -// Component Container -//========================================================================================================= - -export class ComponentContainer { - public component: any; - - // Only needed object orientated subscriptions - public passProps: boolean = false; - public propStates?: { [key: string]: State }; // states which will than be returned as prop object by the integration - public propKeysChanged: Array = []; // Used to preserve local keys to update before update is performed, cleared every update - - public ready: boolean = false; - public subs: Set = new Set([]); // States that are subscribed by this component - - constructor(component: any, subs?: Set) { - this.component = component - if (subs) - this.subs = subs; - } -} - - -//========================================================================================================= -// Callback Container -//========================================================================================================= - -export class CallbackContainer extends ComponentContainer { - public callback: Function; - - constructor(callback: Function, subs?: Set) { - super(null, subs); - - this.callback = callback; - } -} +export type SubscriptionContainer = ComponentSubscriptionContainer | CallbackSubscriptionContainer; //========================================================================================================= @@ -54,10 +18,10 @@ export class SubController { public agileInstance: () => Agile; // Component based Subscription - public components: Set = new Set(); + public components: Set = new Set(); // Callback based Subscription - public callbacks: Set = new Set(); + public callbacks: Set = new Set(); public constructor(agileInstance: Agile) { this.agileInstance = () => agileInstance; @@ -86,7 +50,7 @@ export class SubController { subscriptionContainer.subs.add(state); // Add SubscriptionContainer to State Subs - state.dep.subs.add(subscriptionContainer); + state.dep.subscribe(subscriptionContainer); // Add state to props props[key] = state.value; @@ -113,7 +77,7 @@ export class SubController { subscriptionContainer.subs.add(state); // Add SubscriptionContainer to State Dependencies Subs - state.dep.subs.add(subscriptionContainer); + state.dep.subscribe(subscriptionContainer); }); return subscriptionContainer; @@ -127,19 +91,22 @@ export class SubController { * Unsubscribe a component or callback */ public unsubscribe(subscriptionInstance: any) { - const unsub = (subscriptionContainer: CallbackContainer | ComponentContainer) => { + const unsub = (subscriptionContainer: SubscriptionContainer) => { subscriptionContainer.ready = false; // Removes SubscriptionContainer from State subs subscriptionContainer.subs.forEach(state => { - state.dep.subs.delete(subscriptionInstance); + state.dep.unsubscribe(subscriptionContainer); }); }; - if (subscriptionInstance instanceof CallbackContainer) + // Check if subscriptionInstance is CallbackSubscriptionContainer + if (subscriptionInstance instanceof CallbackSubscriptionContainer) unsub(subscriptionInstance); - else if (subscriptionInstance.componentContainer) - unsub(subscriptionInstance.componentContainer); + + // Check if subscriptionInstance has componentSubscriptionContainer.. which holds an instance of a ComponentSubscriptionContainer + if (subscriptionInstance.componentSubscriptionContainer) + unsub(subscriptionInstance.componentSubscriptionContainer as ComponentSubscriptionContainer); } @@ -150,29 +117,41 @@ export class SubController { * Registers the Component/Callback Subscription and returns a SubscriptionContainer */ public registerSubscription(integrationInstance: any, subs: Array = []): SubscriptionContainer { - // - Callback based Subscription - if (typeof integrationInstance === 'function') { - // Create CallbackContainer - const callbackContainer = new CallbackContainer(integrationInstance as Function, new Set(subs)); + if (typeof integrationInstance === 'function') + return this.registerCallbackSubscription(integrationInstance, subs); + + return this.registerComponentSubscription(integrationInstance, subs); + } - // Add to callbacks - this.callbacks.add(callbackContainer); - // Set Ready - callbackContainer.ready = true; + //========================================================================================================= + // Mount + //========================================================================================================= + /** + * This will mount the component (Mounts currently only useful in Component based Subscription) + */ + public mount(integrationInstance: any) { + if (!integrationInstance.componentContainer) return; - if (this.agileInstance().config.logJobs) - console.log("Agile: Registered Callback ", callbackContainer); + // Set Ready to true + integrationInstance.componentContainer.ready = true; + } - return callbackContainer; - } - // - Component based Subscription - // Create Component Container - const componentContainer = new ComponentContainer(integrationInstance, new Set(subs)); + //========================================================================================================= + // Register Component Subscription + //========================================================================================================= + /** + * Registers Component Subscription + * Note: Helper Function + */ + private registerComponentSubscription(componentInstance: any, subs: Array = []): ComponentSubscriptionContainer { + // Create ComponentSubscriptionContainer + const componentContainer = new ComponentSubscriptionContainer(componentInstance, new Set(subs)); - // Instantiate the componentContainer in a Component (for instance see react.integration AgileHOC) - integrationInstance.componentContainer = componentContainer; + // Create an instance of the componentSubscriptionContainer in the Component.. to be able to unsubscribe it later (see unsubscribe) + if (componentInstance.componentSubscriptionContainer) + componentInstance.componentSubscriptionContainer = componentContainer; // Add to components this.components.add(componentContainer); @@ -189,15 +168,25 @@ export class SubController { //========================================================================================================= - // Mount + // Register Callback Subscription //========================================================================================================= /** - * This will mount the component (Mounts currently only useful in Component based Subscription) + * Registers Callback Subscription + * Note: Helper Function */ - public mount(integrationInstance: any) { - if (!integrationInstance.componentContainer) return; + private registerCallbackSubscription(callbackFunction: () => void, subs: Array = []): CallbackSubscriptionContainer { + // Create CallbackSubscriptionContainer + const callbackContainer = new CallbackSubscriptionContainer(callbackFunction as Function, new Set(subs)); - // Set Ready to true - integrationInstance.componentContainer.ready = true; + // Add to callbacks + this.callbacks.add(callbackContainer); + + // Set Ready + callbackContainer.ready = true; + + if (this.agileInstance().config.logJobs) + console.log("Agile: Registered Callback ", callbackContainer); + + return callbackContainer; } } diff --git a/packages/core/src/state/dep.ts b/packages/core/src/state/dep.ts new file mode 100644 index 00000000..29abe323 --- /dev/null +++ b/packages/core/src/state/dep.ts @@ -0,0 +1,52 @@ +import { + State, + SubscriptionContainer +} from '../internal'; + +export class Dep { + public deps: Set = new Set(); // Dependencies from the State + public subs: Set = new Set(); // Subscriptions (for instance a component subscribes to a state to get rerendered if the state changes) + + constructor(initialDeps?: Array) { + if (!initialDeps) return; + + // Add Initial Dependencies to Deps + initialDeps.forEach(dep => this.deps.add(dep)); + } + + + //========================================================================================================= + // Depend + //========================================================================================================= + /** + * Add new Dependency to the State + */ + public depend(state: State) { + if (state.dep !== this && !this.deps.has(state)) + this.deps.add(state); + } + + + //========================================================================================================= + // Subscribe + //========================================================================================================= + /** + * Add new Subscription to the State + */ + public subscribe(subscriptionContainer: SubscriptionContainer){ + if(!this.subs.has(subscriptionContainer)) + this.subs.add(subscriptionContainer); + } + + + //========================================================================================================= + // Unsubscribe + //========================================================================================================= + /** + * Delete Subscription from the State + */ + public unsubscribe(subscriptionContainer: SubscriptionContainer){ + if(!this.subs.has(subscriptionContainer)) + this.subs.delete(subscriptionContainer); + } +} diff --git a/packages/agile-core/src/state/index.ts b/packages/core/src/state/index.ts similarity index 100% rename from packages/agile-core/src/state/index.ts rename to packages/core/src/state/index.ts diff --git a/packages/agile-core/src/state/persist.ts b/packages/core/src/state/persist.ts similarity index 100% rename from packages/agile-core/src/state/persist.ts rename to packages/core/src/state/persist.ts diff --git a/packages/agile-core/src/storage/index.ts b/packages/core/src/storage/index.ts similarity index 100% rename from packages/agile-core/src/storage/index.ts rename to packages/core/src/storage/index.ts diff --git a/packages/agile-core/src/utils.ts b/packages/core/src/utils.ts similarity index 100% rename from packages/agile-core/src/utils.ts rename to packages/core/src/utils.ts diff --git a/packages/agile-core/tests/collection/default.spec.ts b/packages/core/tests/collection/default.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/default.spec.ts rename to packages/core/tests/collection/default.spec.ts diff --git a/packages/agile-core/tests/collection/functions/collect.function.spec.ts b/packages/core/tests/collection/functions/collect.function.spec.ts similarity index 97% rename from packages/agile-core/tests/collection/functions/collect.function.spec.ts rename to packages/core/tests/collection/functions/collect.function.spec.ts index 6c9d47bc..57afddab 100644 --- a/packages/agile-core/tests/collection/functions/collect.function.spec.ts +++ b/packages/core/tests/collection/functions/collect.function.spec.ts @@ -1,21 +1,12 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; -import Group from "../../../src/collection/group"; +import {useAgile} from "../../../../react/tests"; +import {Group} from "../../../src"; describe('Collect Function Tests', () => { // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); describe('Collection without primaryKey', () => { let rerenderCount = 0; diff --git a/packages/agile-core/tests/collection/functions/createGroup.function.spec.ts b/packages/core/tests/collection/functions/createGroup.function.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/functions/createGroup.function.spec.ts rename to packages/core/tests/collection/functions/createGroup.function.spec.ts diff --git a/packages/agile-core/tests/collection/functions/createSelector.function.spec.ts b/packages/core/tests/collection/functions/createSelector.function.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/functions/createSelector.function.spec.ts rename to packages/core/tests/collection/functions/createSelector.function.spec.ts diff --git a/packages/agile-core/tests/collection/functions/findById.function.spec.ts b/packages/core/tests/collection/functions/findById.function.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/functions/findById.function.spec.ts rename to packages/core/tests/collection/functions/findById.function.spec.ts diff --git a/packages/agile-core/tests/collection/functions/getGroup.function.spec.ts b/packages/core/tests/collection/functions/getGroup.function.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/functions/getGroup.function.spec.ts rename to packages/core/tests/collection/functions/getGroup.function.spec.ts diff --git a/packages/agile-core/tests/collection/functions/getSelector.function.spec.ts b/packages/core/tests/collection/functions/getSelector.function.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/functions/getSelector.function.spec.ts rename to packages/core/tests/collection/functions/getSelector.function.spec.ts diff --git a/packages/agile-core/tests/collection/functions/getValueById.function.spec.ts b/packages/core/tests/collection/functions/getValueById.function.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/functions/getValueById.function.spec.ts rename to packages/core/tests/collection/functions/getValueById.function.spec.ts diff --git a/packages/agile-core/tests/collection/functions/remove.function.spec.ts b/packages/core/tests/collection/functions/remove.function.spec.ts similarity index 95% rename from packages/agile-core/tests/collection/functions/remove.function.spec.ts rename to packages/core/tests/collection/functions/remove.function.spec.ts index 75e12a70..4cec7fee 100644 --- a/packages/agile-core/tests/collection/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/functions/remove.function.spec.ts @@ -1,21 +1,12 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; import Item from "../../../src/collection/item"; describe('Remove Function Tests', () => { // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); describe('Remove Function \'removeFromGroups\'', () => { let rerenderCount = 0; diff --git a/packages/agile-core/tests/collection/functions/update.function.spec.ts b/packages/core/tests/collection/functions/update.function.spec.ts similarity index 95% rename from packages/agile-core/tests/collection/functions/update.function.spec.ts rename to packages/core/tests/collection/functions/update.function.spec.ts index a57986c3..d2d3ce47 100644 --- a/packages/agile-core/tests/collection/functions/update.function.spec.ts +++ b/packages/core/tests/collection/functions/update.function.spec.ts @@ -1,23 +1,14 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; import Group from "../../../src/collection/group"; describe('Update Function Tests', () => { let rerenderCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); // Object Interface interface userInterface { diff --git a/packages/agile-core/tests/collection/group/default.spec.ts b/packages/core/tests/collection/group/default.spec.ts similarity index 95% rename from packages/agile-core/tests/collection/group/default.spec.ts rename to packages/core/tests/collection/group/default.spec.ts index 0648464c..6b74926b 100644 --- a/packages/agile-core/tests/collection/group/default.spec.ts +++ b/packages/core/tests/collection/group/default.spec.ts @@ -1,20 +1,11 @@ import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; import {expect} from "chai"; import Group from "../../../src/collection/group"; describe('Default Group Tests', () => { // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); + const App = new Agile(); describe('Group', () => { let rerenderCount = 0; diff --git a/packages/agile-core/tests/collection/group/functions/add.function.spec.ts b/packages/core/tests/collection/group/functions/add.function.spec.ts similarity index 96% rename from packages/agile-core/tests/collection/group/functions/add.function.spec.ts rename to packages/core/tests/collection/group/functions/add.function.spec.ts index 0db013f6..4754d9ac 100644 --- a/packages/agile-core/tests/collection/group/functions/add.function.spec.ts +++ b/packages/core/tests/collection/group/functions/add.function.spec.ts @@ -1,5 +1,5 @@ import Agile from "../../../../src"; -import {useAgile} from "../../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; import {expect} from "chai"; import Group from "../../../../src/collection/group"; @@ -7,16 +7,7 @@ describe('Add function Tests', () => { let rerenderCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); + const App = new Agile(); // Object Interface interface userInterface { diff --git a/packages/agile-core/tests/collection/group/functions/has.function.spec.ts b/packages/core/tests/collection/group/functions/has.function.spec.ts similarity index 100% rename from packages/agile-core/tests/collection/group/functions/has.function.spec.ts rename to packages/core/tests/collection/group/functions/has.function.spec.ts diff --git a/packages/agile-core/tests/collection/group/functions/remove.function.spec.ts b/packages/core/tests/collection/group/functions/remove.function.spec.ts similarity index 92% rename from packages/agile-core/tests/collection/group/functions/remove.function.spec.ts rename to packages/core/tests/collection/group/functions/remove.function.spec.ts index b09478b1..657459e7 100644 --- a/packages/agile-core/tests/collection/group/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/group/functions/remove.function.spec.ts @@ -1,5 +1,5 @@ import Agile from "../../../../src"; -import {useAgile} from "../../../../src/integrations/test"; +import {useAgile} from "../../../../../react/tests"; import {expect} from "chai"; import Group from "../../../../src/collection/group"; @@ -7,16 +7,7 @@ describe('Add function Tests', () => { let rerenderCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); + const App = new Agile(); // Object Interface interface userInterface { diff --git a/packages/agile-core/tests/collection/selector/default.spec.ts b/packages/core/tests/collection/selector/default.spec.ts similarity index 92% rename from packages/agile-core/tests/collection/selector/default.spec.ts rename to packages/core/tests/collection/selector/default.spec.ts index 44eceaa8..4be0de3d 100644 --- a/packages/agile-core/tests/collection/selector/default.spec.ts +++ b/packages/core/tests/collection/selector/default.spec.ts @@ -1,21 +1,12 @@ import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; import {expect} from "chai"; import Selector from "../../../src/collection/selector"; import Item from "../../../src/collection/item"; describe('Default Selector Tests', () => { // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); + const App = new Agile(); describe('Selector', () => { let rerenderCount = 0; diff --git a/packages/agile-core/tests/collection/selector/functions/select.function.spec.ts b/packages/core/tests/collection/selector/functions/select.function.spec.ts similarity index 93% rename from packages/agile-core/tests/collection/selector/functions/select.function.spec.ts rename to packages/core/tests/collection/selector/functions/select.function.spec.ts index d572eb22..ca64ac84 100644 --- a/packages/agile-core/tests/collection/selector/functions/select.function.spec.ts +++ b/packages/core/tests/collection/selector/functions/select.function.spec.ts @@ -1,5 +1,5 @@ import Agile from "../../../../src"; -import {useAgile} from "../../../../src/integrations/test"; +import {useAgile} from "../../../../../react/tests"; import {expect} from "chai"; import Selector from "../../../../src/collection/selector"; import Item from "../../../../src/collection/item"; @@ -8,16 +8,7 @@ describe('select Function Tests', () => { let rerenderCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - } - }); + const App = new Agile(); // Object Interface interface userInterface { diff --git a/packages/agile-core/tests/computed/default.spec.ts b/packages/core/tests/computed/default.spec.ts similarity index 93% rename from packages/agile-core/tests/computed/default.spec.ts rename to packages/core/tests/computed/default.spec.ts index 66fa7049..9c00f235 100644 --- a/packages/agile-core/tests/computed/default.spec.ts +++ b/packages/core/tests/computed/default.spec.ts @@ -2,20 +2,11 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../src"; import Computed from "../../src/computed"; -import {useAgile} from "../../src/integrations/test"; +import {useAgile} from "../../../react/tests"; describe('Default Computed Tests', () => { // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); interface userInterface { id: number diff --git a/packages/agile-core/tests/computed/functions/updateComputeFunction.function.spec.ts b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts similarity index 92% rename from packages/agile-core/tests/computed/functions/updateComputeFunction.function.spec.ts rename to packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts index d8140da3..b1a05d24 100644 --- a/packages/agile-core/tests/computed/functions/updateComputeFunction.function.spec.ts +++ b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts @@ -2,22 +2,13 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; import Computed from "../../../src/computed"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; describe('updateComputeFunction Function tests', () => { let rerenderCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); // Create State const MY_STATE = App.State('hello'); diff --git a/packages/agile-core/tests/event/default.spec.ts b/packages/core/tests/event/default.spec.ts similarity index 100% rename from packages/agile-core/tests/event/default.spec.ts rename to packages/core/tests/event/default.spec.ts diff --git a/packages/agile-core/tests/event/functions/disable.function.spec.ts b/packages/core/tests/event/functions/disable.function.spec.ts similarity index 100% rename from packages/agile-core/tests/event/functions/disable.function.spec.ts rename to packages/core/tests/event/functions/disable.function.spec.ts diff --git a/packages/agile-core/tests/event/functions/enable.function.spec.ts b/packages/core/tests/event/functions/enable.function.spec.ts similarity index 100% rename from packages/agile-core/tests/event/functions/enable.function.spec.ts rename to packages/core/tests/event/functions/enable.function.spec.ts diff --git a/packages/agile-core/tests/event/functions/on.function.spec.ts b/packages/core/tests/event/functions/on.function.spec.ts similarity index 100% rename from packages/agile-core/tests/event/functions/on.function.spec.ts rename to packages/core/tests/event/functions/on.function.spec.ts diff --git a/packages/agile-core/tests/event/functions/reset.function.spec.ts b/packages/core/tests/event/functions/reset.function.spec.ts similarity index 100% rename from packages/agile-core/tests/event/functions/reset.function.spec.ts rename to packages/core/tests/event/functions/reset.function.spec.ts diff --git a/packages/agile-core/tests/event/functions/trigger.function.spec.ts b/packages/core/tests/event/functions/trigger.function.spec.ts similarity index 97% rename from packages/agile-core/tests/event/functions/trigger.function.spec.ts rename to packages/core/tests/event/functions/trigger.function.spec.ts index 78cc23e3..13539820 100644 --- a/packages/agile-core/tests/event/functions/trigger.function.spec.ts +++ b/packages/core/tests/event/functions/trigger.function.spec.ts @@ -1,7 +1,8 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useEvent} from "../../../src/integrations/test"; +import {useEvent} from "../../../../react/tests"; + describe('Trigger Function Tests', () => { let eventCallCount = 0; diff --git a/packages/agile-core/tests/framework.spec.ts b/packages/core/tests/framework.spec.ts similarity index 64% rename from packages/agile-core/tests/framework.spec.ts rename to packages/core/tests/framework.spec.ts index 6f813398..d17ac99e 100644 --- a/packages/agile-core/tests/framework.spec.ts +++ b/packages/core/tests/framework.spec.ts @@ -6,17 +6,7 @@ describe('Custom Framework Tests', () => { let boundFramework = false; // Define Agile with framework - const App = new Agile({ - framework: { - name: 'test', // The name of the framework - bind: (agileInstance: Agile) => { - boundFramework = true; - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Will be called to force subscribed components to rerender - } - } - }); + const App = new Agile(); it('Has bound custom Framework', () => { expect(boundFramework).to.eq(true, 'boundFramework has correct value'); diff --git a/packages/agile-core/tests/state/default.spec.ts b/packages/core/tests/state/default.spec.ts similarity index 100% rename from packages/agile-core/tests/state/default.spec.ts rename to packages/core/tests/state/default.spec.ts diff --git a/packages/agile-core/tests/state/functions/patch.function.spec.ts b/packages/core/tests/state/functions/patch.function.spec.ts similarity index 94% rename from packages/agile-core/tests/state/functions/patch.function.spec.ts rename to packages/core/tests/state/functions/patch.function.spec.ts index f01eec2f..28c3c1e9 100644 --- a/packages/agile-core/tests/state/functions/patch.function.spec.ts +++ b/packages/core/tests/state/functions/patch.function.spec.ts @@ -1,23 +1,14 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; describe('Patch Function Tests', () => { let rerenderCount = 0; let sideEffectCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); // Object Interface interface userInterface { diff --git a/packages/agile-core/tests/state/functions/persist.function.spec.ts b/packages/core/tests/state/functions/persist.function.spec.ts similarity index 100% rename from packages/agile-core/tests/state/functions/persist.function.spec.ts rename to packages/core/tests/state/functions/persist.function.spec.ts diff --git a/packages/agile-core/tests/state/functions/reset.function.spec.ts b/packages/core/tests/state/functions/reset.function.spec.ts similarity index 84% rename from packages/agile-core/tests/state/functions/reset.function.spec.ts rename to packages/core/tests/state/functions/reset.function.spec.ts index 932afe4d..1039b2d0 100644 --- a/packages/agile-core/tests/state/functions/reset.function.spec.ts +++ b/packages/core/tests/state/functions/reset.function.spec.ts @@ -1,23 +1,14 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; describe('Reset Function Tests', () => { let rerenderCount = 0; let sideEffectCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); // Create State const MY_STATE = App.State(1); diff --git a/packages/agile-core/tests/state/functions/set.function.spec.ts b/packages/core/tests/state/functions/set.function.spec.ts similarity index 91% rename from packages/agile-core/tests/state/functions/set.function.spec.ts rename to packages/core/tests/state/functions/set.function.spec.ts index 4f2bc23e..dd7e9e0f 100644 --- a/packages/agile-core/tests/state/functions/set.function.spec.ts +++ b/packages/core/tests/state/functions/set.function.spec.ts @@ -1,23 +1,14 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; describe('Set Function Tests', () => { let rerenderCount = 0; let sideEffectCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); // Create State const MY_STATE = App.State(1); diff --git a/packages/agile-core/tests/state/functions/type.function.spec.ts b/packages/core/tests/state/functions/type.function.spec.ts similarity index 100% rename from packages/agile-core/tests/state/functions/type.function.spec.ts rename to packages/core/tests/state/functions/type.function.spec.ts diff --git a/packages/agile-core/tests/state/functions/undo.function.spec.ts b/packages/core/tests/state/functions/undo.function.spec.ts similarity index 84% rename from packages/agile-core/tests/state/functions/undo.function.spec.ts rename to packages/core/tests/state/functions/undo.function.spec.ts index 27ffb3f9..5fcc80d0 100644 --- a/packages/agile-core/tests/state/functions/undo.function.spec.ts +++ b/packages/core/tests/state/functions/undo.function.spec.ts @@ -1,23 +1,14 @@ import 'mocha'; import {expect} from 'chai'; import Agile from "../../../src"; -import {useAgile} from "../../../src/integrations/test"; +import {useAgile} from "../../../../react/tests"; describe('Undo Function Tests', () => { let rerenderCount = 0; let sideEffectCount = 0; // Define Agile - const App = new Agile({ - framework: { - name: 'test', - bind: (agileInstance: Agile) => { - }, - updateMethod: (componentInstance: any, updatedData: Object) => { - // Note can't test updateMethod because for that we need a component (Rerenders will be tested with a callbackFunction) - } - }, - }); + const App = new Agile(); // Create State const MY_STATE = App.State(1); diff --git a/packages/agile-core/tests/state/functions/watch.function.spec.ts b/packages/core/tests/state/functions/watch.function.spec.ts similarity index 100% rename from packages/agile-core/tests/state/functions/watch.function.spec.ts rename to packages/core/tests/state/functions/watch.function.spec.ts diff --git a/packages/agile-core/tests/storage.spec.ts b/packages/core/tests/storage.spec.ts similarity index 100% rename from packages/agile-core/tests/storage.spec.ts rename to packages/core/tests/storage.spec.ts diff --git a/packages/core/tsconfig.json b/packages/core/tsconfig.json new file mode 100644 index 00000000..600cd205 --- /dev/null +++ b/packages/core/tsconfig.json @@ -0,0 +1,10 @@ +{ + "extends": "../tsconfig.default.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "dist" + }, + "include": [ + "./src/**/*" // Only include what is in src (-> dist, tests, .. will be excluded) + ] +} \ No newline at end of file diff --git a/packages/react/package.json b/packages/react/package.json new file mode 100644 index 00000000..65934e40 --- /dev/null +++ b/packages/react/package.json @@ -0,0 +1,30 @@ +{ + "name": "@agile/react", + "version": "0.0.1", + "author": "BennoDev", + "license": "ISC", + "description": "React extension for AgileTs", + "keywords": [], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "build": "tsc" + }, + "dependencies": { + "@agile/core": "link:../core" + }, + "peerDependencies": { + "react": "^16.13.1" + }, + "devDependencies": { + "@types/react": "^16.9.49", + "react": "^16.13.1" + }, + "publishConfig": { + "access": "public" + }, + "repository": { + "type": "git", + "url": "https://github.com/agile-ts/agile.git" + } +} diff --git a/packages/agile-react/src/hooks/AgileHOC.ts b/packages/react/src/hooks/AgileHOC.ts similarity index 83% rename from packages/agile-react/src/hooks/AgileHOC.ts rename to packages/react/src/hooks/AgileHOC.ts index f73e46c8..ca451103 100644 --- a/packages/agile-react/src/hooks/AgileHOC.ts +++ b/packages/react/src/hooks/AgileHOC.ts @@ -1,7 +1,5 @@ -import State from "../../../state"; -import Agile from "../../../index"; -import {getAgileInstance, normalizeArray} from "../../../utils"; -import {SubscriptionContainer} from "../../../sub"; +import React from "react"; +import {State, Agile, ComponentSubscriptionContainer, getAgileInstance, normalizeArray} from "@agile/core"; export function AgileHOC(ReactComponent: any, deps?: Array | { [key: string]: State } | State, agileInstance?: Agile) { let depsArray: Array; @@ -44,15 +42,8 @@ export function AgileHOC(ReactComponent: any, deps?: Array | { [key: stri return ReactComponent; } - // Get React constructor - const React = agileInstance.integration?.frameworkConstructor; - if (!React) { - console.error("Agile: Failed to get Framework Constructor"); - return ReactComponent; - } - return class extends React.Component { - public componentContainer: SubscriptionContainer | null = null; // Will be set in registerSubscription (sub.ts) + public componentSubscriptionContainer: ComponentSubscriptionContainer | null = null; // Will be set and used in sub.ts public updatedProps = this.props; diff --git a/packages/agile-react/src/hooks/useAgile.ts b/packages/react/src/hooks/useAgile.ts similarity index 85% rename from packages/agile-react/src/hooks/useAgile.ts rename to packages/react/src/hooks/useAgile.ts index 5746fa71..65e451a6 100644 --- a/packages/agile-react/src/hooks/useAgile.ts +++ b/packages/react/src/hooks/useAgile.ts @@ -1,8 +1,5 @@ -import Group from "../../../collection/group"; -import State from "../../../state"; -import Collection from "../../../collection"; -import Agile from "../../../index"; -import {getAgileInstance, normalizeArray} from "../../../utils"; +import React from "react"; +import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '@agile/core'; // Array Type // https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-1.html @@ -55,13 +52,6 @@ export function useAgile, Y exte agileInstance = tempAgileInstance; } - // Get React constructor - const React = agileInstance.integration?.frameworkConstructor; - if (!React) { - console.error("Agile: Failed to get Framework Constructor"); - return getReturnValue(depsArray); - } - // This is a Trigger State used to force the component to Re-render const [_, set_] = React.useState({}); diff --git a/packages/react/src/hooks/useEvent.ts b/packages/react/src/hooks/useEvent.ts new file mode 100644 index 00000000..7722d689 --- /dev/null +++ b/packages/react/src/hooks/useEvent.ts @@ -0,0 +1,9 @@ +import React from "react"; +import {Event, EventCallbackFunction} from '@agile/core'; + +export function useEvent(event: E, callback: EventCallbackFunction) { + // Call event on component mount and remove event on component unmount + React.useEffect(function () { + return event.on(callback); + }, []); +} diff --git a/packages/agile-react/src/index.ts b/packages/react/src/index.ts similarity index 100% rename from packages/agile-react/src/index.ts rename to packages/react/src/index.ts diff --git a/packages/react/src/react.integration.ts b/packages/react/src/react.integration.ts new file mode 100644 index 00000000..bcbb36f4 --- /dev/null +++ b/packages/react/src/react.integration.ts @@ -0,0 +1,26 @@ +import {Agile, Integration} from '@agile/core' +import React from 'react'; + +const reactIntegration = new Integration({ + name: 'react', + frameworkInstance: React, + bind(agileInstance: Agile) { + // Nothing to bind ;D + }, + updateMethod(componentInstance: any, updatedData: Object) { + // UpdatedData will be empty if the AgileHOC doesn't get an object as deps + + if (Object.keys(updatedData).length !== 0) { + // Update Props + componentInstance.updatedProps = {...componentInstance.updatedProps, ...updatedData}; + + // Set State + componentInstance.setState(updatedData); + } else { + componentInstance.forceUpdate(); + } + } +}); +Agile.initialIntegrations.push(reactIntegration); + +export default reactIntegration; diff --git a/packages/agile-react/tests/hooks/useAgile.ts b/packages/react/tests/hooks/useAgile.ts similarity index 92% rename from packages/agile-react/tests/hooks/useAgile.ts rename to packages/react/tests/hooks/useAgile.ts index a2ea0c2e..9386e3b1 100644 --- a/packages/agile-react/tests/hooks/useAgile.ts +++ b/packages/react/tests/hooks/useAgile.ts @@ -1,8 +1,4 @@ -import State from "../../../state"; -import Collection from "../../../collection"; -import Agile from "../../../index"; -import {getAgileInstance, normalizeArray} from "../../../utils"; -import Group from "../../../collection/group"; +import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '@agile/core'; //========================================================================================================= diff --git a/packages/react/tests/hooks/useEvent.ts b/packages/react/tests/hooks/useEvent.ts new file mode 100644 index 00000000..20991f84 --- /dev/null +++ b/packages/react/tests/hooks/useEvent.ts @@ -0,0 +1,5 @@ +import {Event, EventCallbackFunction} from '@agile/core'; + +export function useEvent(event: E, callback: EventCallbackFunction) { + event.on(callback); +} diff --git a/packages/agile-react/tests/hooks/index.ts b/packages/react/tests/index.ts similarity index 50% rename from packages/agile-react/tests/hooks/index.ts rename to packages/react/tests/index.ts index 2f96a5ec..b7161b3b 100644 --- a/packages/agile-react/tests/hooks/index.ts +++ b/packages/react/tests/index.ts @@ -1,2 +1,6 @@ +import testIntegration from "./test.integration"; + export {useAgile} from './hooks/useAgile'; export {useEvent} from './hooks/useEvent'; + +export default testIntegration; diff --git a/packages/react/tests/test.integration.ts b/packages/react/tests/test.integration.ts new file mode 100644 index 00000000..a8b15434 --- /dev/null +++ b/packages/react/tests/test.integration.ts @@ -0,0 +1,15 @@ +import {Agile, Integration} from '@agile/core' + +const testIntegration = new Integration({ + name: 'test', + frameworkInstance: null, + bind(agileInstance: Agile) { + // Nothing to bind ;D + }, + updateMethod(componentInstance: any, updatedData: Object) { + // Nothing + } +}); +Agile.initialIntegrations.push(testIntegration); + +export default testIntegration; \ No newline at end of file diff --git a/packages/react/tsconfig.json b/packages/react/tsconfig.json new file mode 100644 index 00000000..8ecfe483 --- /dev/null +++ b/packages/react/tsconfig.json @@ -0,0 +1,11 @@ +{ + "extends": "../tsconfig.default.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "dist" + }, + "include": [ + "./src/**/*" // Only include what is in src (-> dist, tests, .. will be excluded) + ] + +} \ No newline at end of file diff --git a/packages/tsconfig.default.json b/packages/tsconfig.default.json index b4397a10..3983ee02 100644 --- a/packages/tsconfig.default.json +++ b/packages/tsconfig.default.json @@ -47,8 +47,8 @@ // "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */ // "typeRoots": [], /* List of folders to include type definitions from. */ // "types": [], /* Type declaration files to be included in compilation. */ - // "allowSyntheticDefaultImports": true, /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */ - // "esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */ + "allowSyntheticDefaultImports": true, /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */ + "esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */ // "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */ // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ From fea1ef4ea6075e2bf90d2b3704b2eaf66dca6e76 Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Wed, 30 Sep 2020 17:30:08 +0200 Subject: [PATCH 05/15] Changed import in api module --- packages/api/package.json | 2 +- packages/api/src/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/api/package.json b/packages/api/package.json index 5cccf276..5fad0bc1 100644 --- a/packages/api/package.json +++ b/packages/api/package.json @@ -3,7 +3,7 @@ "version": "0.0.1", "author": "BennoDev", "license": "ISC", - "description": "API extention for AgileTs", + "description": "API extension for AgileTs", "keywords": [], "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/packages/api/src/index.ts b/packages/api/src/index.ts index b40fe166..d867dea5 100644 --- a/packages/api/src/index.ts +++ b/packages/api/src/index.ts @@ -1,5 +1,5 @@ import * as http from 'http'; -import {copy, isValidUrl} from "../utils"; +import {copy, isValidUrl} from '@agile/core'; export interface AgileResponse { data: DataType // request body data From b9c368442a295ae42a1b67606af613fad8958aed Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Wed, 30 Sep 2020 17:32:55 +0200 Subject: [PATCH 06/15] generated package-lock.json --- package-lock.json | 1436 +++++++++++++++++++++++++++++++++++++++++++++ package.json | 2 +- 2 files changed, 1437 insertions(+), 1 deletion(-) create mode 100644 package-lock.json diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 00000000..23f23772 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,1436 @@ +{ + "requires": true, + "lockfileVersion": 1, + "dependencies": { + "@types/chai": { + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", + "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==", + "dev": true + }, + "@types/mocha": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.2.tgz", + "integrity": "sha512-5cv8rmqT3KX9XtWDvSgGYfS4OwrKM2eei90GWLnTYz+AXRiBv5uYcKBjnkQ4katNvfYk3+o2bHGZUsDhdcoUyg==", + "dev": true + }, + "@types/node": { + "version": "14.6.0", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.6.0.tgz", + "integrity": "sha512-mikldZQitV94akrc4sCcSjtJfsTKt4p+e/s0AGscVA6XArQ9kFclP+ZiYUMnq987rc6QlYxXv/EivqlfSLxpKA==", + "dev": true + }, + "ansi-colors": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", + "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", + "dev": true + }, + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "array.prototype.map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", + "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.4" + } + }, + "assertion-error": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", + "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", + "dev": true + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "browser-stdout": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", + "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", + "dev": true + }, + "buffer-from": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", + "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", + "dev": true + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true + }, + "chai": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", + "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", + "dev": true, + "requires": { + "assertion-error": "^1.1.0", + "check-error": "^1.0.2", + "deep-eql": "^3.0.1", + "get-func-name": "^2.0.0", + "pathval": "^1.1.0", + "type-detect": "^4.0.5" + } + }, + "chalk": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + } + }, + "check-error": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", + "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", + "dev": true + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "requires": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", + "dev": true + }, + "deep-eql": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", + "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", + "dev": true, + "requires": { + "type-detect": "^4.0.0" + } + }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "requires": { + "object-keys": "^1.0.12" + } + }, + "diff": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true + }, + "duplexer": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", + "integrity": "sha1-rOb/gIwc5mtX0ev5eXessCM0z8E=", + "dev": true + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "es-abstract": { + "version": "1.17.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", + "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", + "dev": true, + "requires": { + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.2.0", + "is-regex": "^1.1.0", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimend": "^1.0.1", + "string.prototype.trimstart": "^1.0.1" + } + }, + "es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==", + "dev": true + }, + "es-get-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", + "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", + "dev": true, + "requires": { + "es-abstract": "^1.17.4", + "has-symbols": "^1.0.1", + "is-arguments": "^1.0.4", + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-string": "^1.0.5", + "isarray": "^2.0.5" + }, + "dependencies": { + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "dev": true + } + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dev": true, + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "dev": true + }, + "eslint-config-prettier": { + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.11.0.tgz", + "integrity": "sha512-oB8cpLWSAjOVFEJhhyMZh6NOEOtBVziaqdDQ86+qhDHFbZXoRTM7pNSvFRfW/W/L/LrQ38C99J5CGuRBBzBsdA==", + "dev": true, + "requires": { + "get-stdin": "^6.0.0" + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, + "event-stream": { + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", + "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", + "dev": true, + "requires": { + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", + "pause-stream": "0.0.11", + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" + } + }, + "find-up": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", + "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "dev": true, + "requires": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + } + }, + "flat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", + "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", + "dev": true, + "requires": { + "is-buffer": "~2.0.3" + }, + "dependencies": { + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", + "dev": true + } + } + }, + "from": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", + "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=", + "dev": true + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fsevents": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", + "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true + }, + "get-func-name": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", + "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=", + "dev": true + }, + "get-stdin": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", + "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==", + "dev": true + }, + "glob": { + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "dev": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "growl": { + "version": "1.10.5", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", + "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", + "dev": true + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", + "dev": true + }, + "has-symbols": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", + "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", + "dev": true + }, + "he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", + "dev": true + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "is-arguments": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==", + "dev": true + }, + "is-callable": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.0.tgz", + "integrity": "sha512-pyVD9AaGLxtg6srb2Ng6ynWJqkHU9bEM087AKck0w8QwDarTfNcpIYoU8x8Hv2Icm8u6kFJM18Dag8lyqGkviw==", + "dev": true + }, + "is-date-object": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", + "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", + "dev": true + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "dev": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", + "dev": true, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", + "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==", + "dev": true + }, + "is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=", + "dev": true + }, + "is-regex": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", + "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "is-set": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", + "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==", + "dev": true + }, + "is-string": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", + "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==", + "dev": true + }, + "is-symbol": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", + "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "iterate-iterator": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", + "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==", + "dev": true + }, + "iterate-value": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", + "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", + "dev": true, + "requires": { + "es-get-iterator": "^1.0.2", + "iterate-iterator": "^1.0.1" + } + }, + "js-yaml": { + "version": "3.13.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", + "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "requires": { + "p-locate": "^4.1.0" + } + }, + "log-symbols": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", + "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", + "dev": true, + "requires": { + "chalk": "^2.4.2" + } + }, + "make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true + }, + "map-stream": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=", + "dev": true + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "mocha": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.1.tgz", + "integrity": "sha512-p7FuGlYH8t7gaiodlFreseLxEmxTgvyG9RgPHODFPySNhwUehu8NIb0vdSt3WFckSneswZ0Un5typYcWElk7HQ==", + "dev": true, + "requires": { + "ansi-colors": "4.1.1", + "browser-stdout": "1.3.1", + "chokidar": "3.3.1", + "debug": "3.2.6", + "diff": "4.0.2", + "escape-string-regexp": "1.0.5", + "find-up": "4.1.0", + "glob": "7.1.6", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.13.1", + "log-symbols": "3.0.0", + "minimatch": "3.0.4", + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "4.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.1" + }, + "dependencies": { + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "dev": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "binary-extensions": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==", + "dev": true + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "requires": { + "fill-range": "^7.0.1" + } + }, + "chokidar": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.1.tgz", + "integrity": "sha512-4QYCEWOcK3OJrxwvyyAOxFuhpvOVCYkr33LPfFNBjAD/w3sEzWsp2BUOkI4l9bHvWioAd0rc6NlHUOEaWkTeqg==", + "dev": true, + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "fsevents": "~2.1.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.3.0" + } + }, + "debug": { + "version": "3.2.6", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", + "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "dev": true, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", + "dev": true, + "requires": { + "is-glob": "^4.0.1" + } + }, + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "readdirp": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.3.0.tgz", + "integrity": "sha512-zz0pAkSPOXXm1viEwygWIPSPkcBYjW1xU5j/JBh5t9bGCJwa6f9+BJa6VaB2g+b55yVrmXzqkyLf4xaWYM0IkQ==", + "dev": true, + "requires": { + "picomatch": "^2.0.7" + } + }, + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "dev": true, + "requires": { + "has-flag": "^4.0.0" + } + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "requires": { + "is-number": "^7.0.0" + } + } + } + }, + "node-cleanup": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", + "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=", + "dev": true + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true + }, + "object-inspect": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", + "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==", + "dev": true + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true + }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "dev": true, + "requires": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", + "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "dev": true, + "requires": { + "p-limit": "^2.2.0" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true + }, + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true + }, + "pathval": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", + "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=", + "dev": true + }, + "pause-stream": { + "version": "0.0.11", + "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", + "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", + "dev": true, + "requires": { + "through": "~2.3" + } + }, + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", + "dev": true + }, + "prettier": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", + "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==", + "dev": true + }, + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "dev": true, + "requires": { + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" + } + }, + "ps-tree": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", + "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", + "dev": true, + "requires": { + "event-stream": "=3.3.4" + } + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dev": true, + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "dev": true + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", + "dev": true + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "serialize-javascript": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", + "dev": true, + "requires": { + "randombytes": "^2.1.0" + } + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true + }, + "source-map-support": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", + "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", + "dev": true, + "requires": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + }, + "dependencies": { + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + } + } + }, + "split": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", + "dev": true, + "requires": { + "through": "2" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "stream-combiner": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "dev": true, + "requires": { + "duplexer": "~0.1.1" + } + }, + "string-argv": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", + "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==", + "dev": true + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "^3.0.0" + } + } + } + }, + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "dev": true, + "requires": { + "ansi-regex": "^5.0.0" + } + }, + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==", + "dev": true + }, + "supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "requires": { + "has-flag": "^3.0.0" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "ts-node": { + "version": "8.10.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", + "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", + "dev": true, + "requires": { + "arg": "^4.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "source-map-support": "^0.5.17", + "yn": "3.1.1" + } + }, + "tsc-watch": { + "version": "4.2.9", + "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", + "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", + "dev": true, + "requires": { + "cross-spawn": "^7.0.3", + "node-cleanup": "^2.1.2", + "ps-tree": "^1.2.0", + "string-argv": "^0.1.1", + "strip-ansi": "^6.0.0" + } + }, + "tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==", + "dev": true + }, + "type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true + }, + "typescript": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", + "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==", + "dev": true + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "dev": true + }, + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "dev": true, + "requires": { + "string-width": "^1.0.2 || 2" + } + }, + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==", + "dev": true + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", + "dev": true + }, + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "yargs-unparser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", + "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", + "dev": true, + "requires": { + "camelcase": "^5.3.1", + "decamelize": "^1.2.0", + "flat": "^4.1.0", + "is-plain-obj": "^1.1.0", + "yargs": "^14.2.3" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "yargs": { + "version": "14.2.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", + "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + } + }, + "yargs-parser": { + "version": "15.0.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", + "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + } + } + }, + "yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", + "dev": true + } + } +} diff --git a/package.json b/package.json index c295c39a..63c49f39 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "private": true, + "private": true, "description": "Global state and logic framework for reactive React applications.", "author": "BennoDev", "license": "ISC", From 50c710e464ab4f3c6e1cc5d6455678b8d7a1e792 Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Wed, 30 Sep 2020 21:22:14 +0200 Subject: [PATCH 07/15] Fixed test files --- packages/api/package-lock.json | 1466 ++++++++++++++++ packages/api/package.json | 26 +- packages/api/src/index.ts | 2 +- packages/core/package-lock.json | 1464 +++++++++++++++- packages/core/package.json | 22 +- packages/core/src/integrations.ts | 15 +- .../core/tests/collection/default.spec.ts | 4 +- .../functions/collect.function.spec.ts | 3 +- .../functions/createGroup.function.spec.ts | 3 +- .../functions/createSelector.function.spec.ts | 4 +- .../functions/findById.function.spec.ts | 3 +- .../functions/getGroup.function.spec.ts | 3 +- .../functions/getSelector.function.spec.ts | 3 +- .../functions/getValueById.function.spec.ts | 2 +- .../functions/remove.function.spec.ts | 3 +- .../functions/update.function.spec.ts | 3 +- .../tests/collection/group/default.spec.ts | 6 +- .../group/functions/add.function.spec.ts | 6 +- .../group/functions/has.function.spec.ts | 3 +- .../group/functions/remove.function.spec.ts | 6 +- .../tests/collection/selector/default.spec.ts | 7 +- .../functions/select.function.spec.ts | 7 +- packages/core/tests/computed/default.spec.ts | 3 +- .../updateComputeFunction.function.spec.ts | 3 +- packages/core/tests/event/default.spec.ts | 2 +- .../event/functions/disable.function.spec.ts | 2 +- .../event/functions/enable.function.spec.ts | 2 +- .../tests/event/functions/on.function.spec.ts | 2 +- .../event/functions/reset.function.spec.ts | 2 +- .../event/functions/trigger.function.spec.ts | 2 +- packages/core/tests/framework.spec.ts | 14 +- packages/core/tests/state/default.spec.ts | 2 +- .../state/functions/patch.function.spec.ts | 2 +- .../state/functions/persist.function.spec.ts | 2 +- .../state/functions/reset.function.spec.ts | 2 +- .../state/functions/set.function.spec.ts | 2 +- .../state/functions/type.function.spec.ts | 2 +- .../state/functions/undo.function.spec.ts | 2 +- .../state/functions/watch.function.spec.ts | 2 +- packages/core/tests/storage.spec.ts | 2 +- packages/react/package-lock.json | 1537 +++++++++++++++++ packages/react/package.json | 24 +- packages/react/src/hooks/AgileHOC.ts | 2 +- packages/react/src/hooks/useAgile.ts | 2 +- packages/react/src/hooks/useEvent.ts | 2 +- packages/react/src/react.integration.ts | 2 +- packages/react/tests/hooks/useAgile.ts | 2 +- packages/react/tests/hooks/useEvent.ts | 2 +- packages/react/tests/test.integration.ts | 2 +- 49 files changed, 4595 insertions(+), 91 deletions(-) create mode 100644 packages/api/package-lock.json create mode 100644 packages/react/package-lock.json diff --git a/packages/api/package-lock.json b/packages/api/package-lock.json new file mode 100644 index 00000000..894ab536 --- /dev/null +++ b/packages/api/package-lock.json @@ -0,0 +1,1466 @@ +{ + "name": "@agile-ts/api", + "version": "0.0.2", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@agile-ts/core": { + "version": "file:../core" + }, + "@types/chai": { + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", + "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==", + "dev": true + }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", + "dev": true + }, + "@types/mocha": { + "version": "8.0.3", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.3.tgz", + "integrity": "sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==", + "dev": true + }, + "@types/node": { + "version": "14.11.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.11.2.tgz", + "integrity": "sha512-jiE3QIxJ8JLNcb1Ps6rDbysDhN4xa8DJJvuC9prr6w+1tIh+QAbYyNF3tyiZNLDBIuBCf4KEcV2UvQm/V60xfA==", + "dev": true + }, + "ansi-colors": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", + "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", + "dev": true + }, + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", + "dev": true, + "requires": { + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" + } + }, + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "dev": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "array.prototype.map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", + "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.4" + } + }, + "assertion-error": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", + "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", + "dev": true + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "binary-extensions": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==", + "dev": true + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "requires": { + "fill-range": "^7.0.1" + } + }, + "browser-stdout": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", + "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", + "dev": true + }, + "buffer-from": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", + "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", + "dev": true + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true + }, + "chai": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", + "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", + "dev": true, + "requires": { + "assertion-error": "^1.1.0", + "check-error": "^1.0.2", + "deep-eql": "^3.0.1", + "get-func-name": "^2.0.0", + "pathval": "^1.1.0", + "type-detect": "^4.0.5" + } + }, + "chalk": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", + "dev": true, + "requires": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + } + }, + "check-error": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", + "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", + "dev": true + }, + "chokidar": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", + "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", + "dev": true, + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "fsevents": "~2.1.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.4.0" + } + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "requires": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + } + }, + "debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", + "dev": true + }, + "deep-eql": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", + "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", + "dev": true, + "requires": { + "type-detect": "^4.0.0" + } + }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "requires": { + "object-keys": "^1.0.12" + } + }, + "diff": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==", + "dev": true + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "es-abstract": { + "version": "1.17.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", + "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", + "dev": true, + "requires": { + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.2.0", + "is-regex": "^1.1.0", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimend": "^1.0.1", + "string.prototype.trimstart": "^1.0.1" + } + }, + "es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==", + "dev": true + }, + "es-get-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", + "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", + "dev": true, + "requires": { + "es-abstract": "^1.17.4", + "has-symbols": "^1.0.1", + "is-arguments": "^1.0.4", + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-string": "^1.0.5", + "isarray": "^2.0.5" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dev": true, + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "dev": true + }, + "eslint-config-prettier": { + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.12.0.tgz", + "integrity": "sha512-9jWPlFlgNwRUYVoujvWTQ1aMO8o6648r+K7qU7K5Jmkbyqav1fuEZC0COYpGBxyiAJb65Ra9hrmFx19xRGwXWw==", + "dev": true, + "requires": { + "get-stdin": "^6.0.0" + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, + "event-stream": { + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", + "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", + "dev": true, + "requires": { + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", + "pause-stream": "0.0.11", + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" + } + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "dev": true, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "dev": true, + "requires": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + } + }, + "flat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", + "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", + "dev": true, + "requires": { + "is-buffer": "~2.0.3" + } + }, + "from": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", + "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=", + "dev": true + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fsevents": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", + "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true + }, + "get-func-name": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", + "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=", + "dev": true + }, + "get-stdin": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", + "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==", + "dev": true + }, + "glob": { + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "dev": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", + "dev": true, + "requires": { + "is-glob": "^4.0.1" + } + }, + "growl": { + "version": "1.10.5", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", + "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", + "dev": true + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "has-symbols": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", + "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", + "dev": true + }, + "he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", + "dev": true + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "is-arguments": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==", + "dev": true + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", + "dev": true + }, + "is-callable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz", + "integrity": "sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA==", + "dev": true + }, + "is-date-object": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", + "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", + "dev": true + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "dev": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", + "dev": true, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", + "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==", + "dev": true + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true + }, + "is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=", + "dev": true + }, + "is-regex": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", + "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "is-set": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", + "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==", + "dev": true + }, + "is-string": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", + "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==", + "dev": true + }, + "is-symbol": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", + "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "dev": true + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "iterate-iterator": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", + "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==", + "dev": true + }, + "iterate-value": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", + "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", + "dev": true, + "requires": { + "es-get-iterator": "^1.0.2", + "iterate-iterator": "^1.0.1" + } + }, + "js-yaml": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", + "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, + "requires": { + "p-locate": "^5.0.0" + } + }, + "log-symbols": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.0.0.tgz", + "integrity": "sha512-FN8JBzLx6CzeMrB0tg6pqlGU1wCrXW+ZXGH481kfsBqer0hToTIiHdjH4Mq8xJUbvATujKCvaREGWpGUionraA==", + "dev": true, + "requires": { + "chalk": "^4.0.0" + } + }, + "make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true + }, + "map-stream": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=", + "dev": true + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "mocha": { + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.3.tgz", + "integrity": "sha512-ZbaYib4hT4PpF4bdSO2DohooKXIn4lDeiYqB+vTmCdr6l2woW0b6H3pf5x4sM5nwQMru9RvjjHYWVGltR50ZBw==", + "dev": true, + "requires": { + "ansi-colors": "4.1.1", + "browser-stdout": "1.3.1", + "chokidar": "3.4.2", + "debug": "4.1.1", + "diff": "4.0.2", + "escape-string-regexp": "4.0.0", + "find-up": "5.0.0", + "glob": "7.1.6", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.14.0", + "log-symbols": "4.0.0", + "minimatch": "3.0.4", + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "4.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.1" + } + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node-cleanup": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", + "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=", + "dev": true + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true + }, + "object-inspect": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", + "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==", + "dev": true + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true + }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "dev": true, + "requires": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "p-limit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", + "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, + "requires": { + "p-limit": "^3.0.2" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true + }, + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true + }, + "pathval": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", + "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=", + "dev": true + }, + "pause-stream": { + "version": "0.0.11", + "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", + "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", + "dev": true, + "requires": { + "through": "~2.3" + } + }, + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", + "dev": true + }, + "prettier": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", + "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==", + "dev": true + }, + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "dev": true, + "requires": { + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" + } + }, + "ps-tree": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", + "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", + "dev": true, + "requires": { + "event-stream": "=3.3.4" + } + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dev": true, + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "readdirp": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", + "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", + "dev": true, + "requires": { + "picomatch": "^2.2.1" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "dev": true + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", + "dev": true + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true + }, + "serialize-javascript": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", + "dev": true, + "requires": { + "randombytes": "^2.1.0" + } + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true + }, + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + }, + "source-map-support": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", + "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", + "dev": true, + "requires": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "split": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", + "dev": true, + "requires": { + "through": "2" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "stream-combiner": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "dev": true, + "requires": { + "duplexer": "~0.1.1" + } + }, + "string-argv": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", + "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==", + "dev": true + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + } + }, + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "^3.0.0" + } + }, + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==", + "dev": true + }, + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "dev": true, + "requires": { + "has-flag": "^4.0.0" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "requires": { + "is-number": "^7.0.0" + } + }, + "ts-node": { + "version": "8.10.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", + "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", + "dev": true, + "requires": { + "arg": "^4.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "source-map-support": "^0.5.17", + "yn": "3.1.1" + } + }, + "tsc-watch": { + "version": "4.2.9", + "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", + "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", + "dev": true, + "requires": { + "cross-spawn": "^7.0.3", + "node-cleanup": "^2.1.2", + "ps-tree": "^1.2.0", + "string-argv": "^0.1.1", + "strip-ansi": "^6.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", + "dev": true + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "dev": true, + "requires": { + "ansi-regex": "^5.0.0" + } + } + } + }, + "tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==", + "dev": true + }, + "type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true + }, + "typescript": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", + "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==", + "dev": true + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "dev": true + }, + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "dev": true, + "requires": { + "string-width": "^1.0.2 || 2" + } + }, + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==", + "dev": true + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", + "dev": true + }, + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "yargs-unparser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", + "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", + "dev": true, + "requires": { + "camelcase": "^5.3.1", + "decamelize": "^1.2.0", + "flat": "^4.1.0", + "is-plain-obj": "^1.1.0", + "yargs": "^14.2.3" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "yargs": { + "version": "14.2.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", + "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + } + }, + "yargs-parser": { + "version": "15.0.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", + "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + } + } + }, + "yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", + "dev": true + } + } +} diff --git a/packages/api/package.json b/packages/api/package.json index 5fad0bc1..895151f7 100644 --- a/packages/api/package.json +++ b/packages/api/package.json @@ -1,6 +1,6 @@ { - "name": "@agile/api", - "version": "0.0.1", + "name": "@agile-ts/api", + "version": "0.0.2", "author": "BennoDev", "license": "ISC", "description": "API extension for AgileTs", @@ -10,8 +10,21 @@ "scripts": { "build": "tsc" }, + "devDependencies": { + "@types/chai": "^4.2.12", + "@types/mocha": "^8.0.2", + "@types/node": "^14.6.0", + "chai": "^4.2.0", + "eslint-config-prettier": "^6.11.0", + "mocha": "^8.1.1", + "prettier": "2.0.5", + "ts-node": "^8.10.2", + "tsc-watch": "^4.1.0", + "tslib": "^2.0.0", + "typescript": "^3.9.7" + }, "dependencies": { - "@agile/core": "link:../core" + "@agile-ts/core": "file:../core" }, "publishConfig": { "access": "public" @@ -19,5 +32,8 @@ "repository": { "type": "git", "url": "https://github.com/agile-ts/agile.git" - } -} \ No newline at end of file + }, + "files": [ + "dist/**/*" + ] +} diff --git a/packages/api/src/index.ts b/packages/api/src/index.ts index d867dea5..8b9a3635 100644 --- a/packages/api/src/index.ts +++ b/packages/api/src/index.ts @@ -1,5 +1,5 @@ import * as http from 'http'; -import {copy, isValidUrl} from '@agile/core'; +import {copy, isValidUrl} from '@agile-ts/core'; export interface AgileResponse { data: DataType // request body data diff --git a/packages/core/package-lock.json b/packages/core/package-lock.json index 84d5ac9d..9928f2e0 100644 --- a/packages/core/package-lock.json +++ b/packages/core/package-lock.json @@ -1,5 +1,1463 @@ { - "name": "@agile/core", - "version": "0.0.1", - "lockfileVersion": 1 + "name": "@agile-ts/core", + "version": "0.0.2", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@types/chai": { + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", + "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==", + "dev": true + }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", + "dev": true + }, + "@types/mocha": { + "version": "8.0.3", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.3.tgz", + "integrity": "sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==", + "dev": true + }, + "@types/node": { + "version": "14.11.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.11.2.tgz", + "integrity": "sha512-jiE3QIxJ8JLNcb1Ps6rDbysDhN4xa8DJJvuC9prr6w+1tIh+QAbYyNF3tyiZNLDBIuBCf4KEcV2UvQm/V60xfA==", + "dev": true + }, + "ansi-colors": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", + "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", + "dev": true + }, + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", + "dev": true, + "requires": { + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" + } + }, + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "dev": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "array.prototype.map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", + "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.4" + } + }, + "assertion-error": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", + "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", + "dev": true + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "binary-extensions": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==", + "dev": true + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "requires": { + "fill-range": "^7.0.1" + } + }, + "browser-stdout": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", + "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", + "dev": true + }, + "buffer-from": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", + "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", + "dev": true + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true + }, + "chai": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", + "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", + "dev": true, + "requires": { + "assertion-error": "^1.1.0", + "check-error": "^1.0.2", + "deep-eql": "^3.0.1", + "get-func-name": "^2.0.0", + "pathval": "^1.1.0", + "type-detect": "^4.0.5" + } + }, + "chalk": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", + "dev": true, + "requires": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + } + }, + "check-error": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", + "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", + "dev": true + }, + "chokidar": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", + "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", + "dev": true, + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "fsevents": "~2.1.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.4.0" + } + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "requires": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + } + }, + "debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", + "dev": true + }, + "deep-eql": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", + "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", + "dev": true, + "requires": { + "type-detect": "^4.0.0" + } + }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "requires": { + "object-keys": "^1.0.12" + } + }, + "diff": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==", + "dev": true + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "es-abstract": { + "version": "1.17.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", + "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", + "dev": true, + "requires": { + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.2.0", + "is-regex": "^1.1.0", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimend": "^1.0.1", + "string.prototype.trimstart": "^1.0.1" + } + }, + "es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==", + "dev": true + }, + "es-get-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", + "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", + "dev": true, + "requires": { + "es-abstract": "^1.17.4", + "has-symbols": "^1.0.1", + "is-arguments": "^1.0.4", + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-string": "^1.0.5", + "isarray": "^2.0.5" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dev": true, + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "dev": true + }, + "eslint-config-prettier": { + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.12.0.tgz", + "integrity": "sha512-9jWPlFlgNwRUYVoujvWTQ1aMO8o6648r+K7qU7K5Jmkbyqav1fuEZC0COYpGBxyiAJb65Ra9hrmFx19xRGwXWw==", + "dev": true, + "requires": { + "get-stdin": "^6.0.0" + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, + "event-stream": { + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", + "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", + "dev": true, + "requires": { + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", + "pause-stream": "0.0.11", + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" + } + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "dev": true, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "dev": true, + "requires": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + } + }, + "flat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", + "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", + "dev": true, + "requires": { + "is-buffer": "~2.0.3" + } + }, + "from": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", + "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=", + "dev": true + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fsevents": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", + "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true + }, + "get-func-name": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", + "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=", + "dev": true + }, + "get-stdin": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", + "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==", + "dev": true + }, + "glob": { + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "dev": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", + "dev": true, + "requires": { + "is-glob": "^4.0.1" + } + }, + "growl": { + "version": "1.10.5", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", + "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", + "dev": true + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "has-symbols": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", + "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", + "dev": true + }, + "he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", + "dev": true + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "is-arguments": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==", + "dev": true + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", + "dev": true + }, + "is-callable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz", + "integrity": "sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA==", + "dev": true + }, + "is-date-object": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", + "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", + "dev": true + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "dev": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", + "dev": true, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", + "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==", + "dev": true + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true + }, + "is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=", + "dev": true + }, + "is-regex": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", + "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "is-set": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", + "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==", + "dev": true + }, + "is-string": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", + "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==", + "dev": true + }, + "is-symbol": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", + "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "dev": true + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "iterate-iterator": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", + "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==", + "dev": true + }, + "iterate-value": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", + "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", + "dev": true, + "requires": { + "es-get-iterator": "^1.0.2", + "iterate-iterator": "^1.0.1" + } + }, + "js-yaml": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", + "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, + "requires": { + "p-locate": "^5.0.0" + } + }, + "log-symbols": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.0.0.tgz", + "integrity": "sha512-FN8JBzLx6CzeMrB0tg6pqlGU1wCrXW+ZXGH481kfsBqer0hToTIiHdjH4Mq8xJUbvATujKCvaREGWpGUionraA==", + "dev": true, + "requires": { + "chalk": "^4.0.0" + } + }, + "make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true + }, + "map-stream": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=", + "dev": true + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "mocha": { + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.3.tgz", + "integrity": "sha512-ZbaYib4hT4PpF4bdSO2DohooKXIn4lDeiYqB+vTmCdr6l2woW0b6H3pf5x4sM5nwQMru9RvjjHYWVGltR50ZBw==", + "dev": true, + "requires": { + "ansi-colors": "4.1.1", + "browser-stdout": "1.3.1", + "chokidar": "3.4.2", + "debug": "4.1.1", + "diff": "4.0.2", + "escape-string-regexp": "4.0.0", + "find-up": "5.0.0", + "glob": "7.1.6", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.14.0", + "log-symbols": "4.0.0", + "minimatch": "3.0.4", + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "4.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.1" + } + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node-cleanup": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", + "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=", + "dev": true + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true + }, + "object-inspect": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", + "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==", + "dev": true + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true + }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "dev": true, + "requires": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "p-limit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", + "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, + "requires": { + "p-limit": "^3.0.2" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true + }, + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true + }, + "pathval": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", + "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=", + "dev": true + }, + "pause-stream": { + "version": "0.0.11", + "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", + "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", + "dev": true, + "requires": { + "through": "~2.3" + } + }, + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", + "dev": true + }, + "prettier": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", + "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==", + "dev": true + }, + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "dev": true, + "requires": { + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" + } + }, + "ps-tree": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", + "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", + "dev": true, + "requires": { + "event-stream": "=3.3.4" + } + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dev": true, + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "readdirp": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", + "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", + "dev": true, + "requires": { + "picomatch": "^2.2.1" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "dev": true + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", + "dev": true + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true + }, + "serialize-javascript": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", + "dev": true, + "requires": { + "randombytes": "^2.1.0" + } + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true + }, + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + }, + "source-map-support": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", + "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", + "dev": true, + "requires": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "split": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", + "dev": true, + "requires": { + "through": "2" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "stream-combiner": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "dev": true, + "requires": { + "duplexer": "~0.1.1" + } + }, + "string-argv": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", + "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==", + "dev": true + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + } + }, + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "^3.0.0" + } + }, + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==", + "dev": true + }, + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "dev": true, + "requires": { + "has-flag": "^4.0.0" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "requires": { + "is-number": "^7.0.0" + } + }, + "ts-node": { + "version": "8.10.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", + "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", + "dev": true, + "requires": { + "arg": "^4.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "source-map-support": "^0.5.17", + "yn": "3.1.1" + } + }, + "tsc-watch": { + "version": "4.2.9", + "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", + "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", + "dev": true, + "requires": { + "cross-spawn": "^7.0.3", + "node-cleanup": "^2.1.2", + "ps-tree": "^1.2.0", + "string-argv": "^0.1.1", + "strip-ansi": "^6.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", + "dev": true + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "dev": true, + "requires": { + "ansi-regex": "^5.0.0" + } + } + } + }, + "tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==", + "dev": true + }, + "type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true + }, + "typescript": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", + "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==", + "dev": true + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "dev": true + }, + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "dev": true, + "requires": { + "string-width": "^1.0.2 || 2" + } + }, + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==", + "dev": true + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", + "dev": true + }, + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "yargs-unparser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", + "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", + "dev": true, + "requires": { + "camelcase": "^5.3.1", + "decamelize": "^1.2.0", + "flat": "^4.1.0", + "is-plain-obj": "^1.1.0", + "yargs": "^14.2.3" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "yargs": { + "version": "14.2.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", + "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + } + }, + "yargs-parser": { + "version": "15.0.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", + "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + } + } + }, + "yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", + "dev": true + } + } } diff --git a/packages/core/package.json b/packages/core/package.json index 1909ff39..0d44bee3 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { - "name": "@agile/core", - "version": "0.0.1", + "name": "@agile-ts/core", + "version": "0.0.2", "author": "BennoDev", "license": "ISC", "description": "Global state and logic framework for reactive JavaScript & TypeScript applications.", @@ -10,11 +10,27 @@ "scripts": { "build": "tsc" }, + "devDependencies": { + "@types/chai": "^4.2.12", + "@types/mocha": "^8.0.2", + "@types/node": "^14.6.0", + "chai": "^4.2.0", + "eslint-config-prettier": "^6.11.0", + "mocha": "^8.1.1", + "prettier": "2.0.5", + "ts-node": "^8.10.2", + "tsc-watch": "^4.1.0", + "tslib": "^2.0.0", + "typescript": "^3.9.7" + }, "publishConfig": { "access": "public" }, "repository": { "type": "git", "url": "https://github.com/agile-ts/agile.git" - } + }, + "files": [ + "dist/**/*" + ] } diff --git a/packages/core/src/integrations.ts b/packages/core/src/integrations.ts index 5e3a2ad5..c2605b94 100644 --- a/packages/core/src/integrations.ts +++ b/packages/core/src/integrations.ts @@ -8,7 +8,7 @@ export interface IntegrationConfig { } export class Integration { - public ready?: boolean; + public ready: boolean = false; public config: IntegrationConfig; constructor(config: IntegrationConfig) { @@ -19,7 +19,7 @@ export class Integration { export class Integrations { public agileInstance: () => Agile; - public loadedIntegrations: Set = new Set(); + public integrations: Set = new Set(); constructor(agileInstance: Agile) { this.agileInstance = () => agileInstance; @@ -42,7 +42,7 @@ export class Integrations { return; } - this.loadedIntegrations.add(integration); + this.integrations.add(integration); if (this.agileInstance().config.logJobs) console.log(`Agile: Successfully integrated '${integration.config.name}'`); } @@ -55,7 +55,10 @@ export class Integrations { * Binds the Framework to Agile */ public bind() { - this.loadedIntegrations.forEach(integration => integration.config.bind && integration.config.bind(this.agileInstance())); + this.integrations.forEach(integration => { + integration.config.bind && integration.config.bind(this.agileInstance()); + integration.ready = true; + }); } @@ -66,7 +69,7 @@ export class Integrations { * Updates Framework States */ public update(componentInstance: any, updatedData: Object) { - this.loadedIntegrations.forEach(integration => integration.config.updateMethod && integration.config.updateMethod(componentInstance, updatedData)); + this.integrations.forEach(integration => integration.config.updateMethod && integration.config.updateMethod(componentInstance, updatedData)); } @@ -77,6 +80,6 @@ export class Integrations { * Checks weather integrations are registered */ public hasIntegration() { - return this.loadedIntegrations.size > 0; + return this.integrations.size > 0; } } \ No newline at end of file diff --git a/packages/core/tests/collection/default.spec.ts b/packages/core/tests/collection/default.spec.ts index 84b1ea07..c4e8d095 100644 --- a/packages/core/tests/collection/default.spec.ts +++ b/packages/core/tests/collection/default.spec.ts @@ -1,8 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../src"; -import Group from "../../src/collection/group"; -import Selector from "../../src/collection/selector"; +import {Agile, Group, Selector} from "../../src"; describe('Default Collection Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/collect.function.spec.ts b/packages/core/tests/collection/functions/collect.function.spec.ts index 57afddab..7632673b 100644 --- a/packages/core/tests/collection/functions/collect.function.spec.ts +++ b/packages/core/tests/collection/functions/collect.function.spec.ts @@ -1,8 +1,7 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Group, Agile} from "../../../src"; import {useAgile} from "../../../../react/tests"; -import {Group} from "../../../src"; describe('Collect Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/createGroup.function.spec.ts b/packages/core/tests/collection/functions/createGroup.function.spec.ts index 13da99f8..d714b9d9 100644 --- a/packages/core/tests/collection/functions/createGroup.function.spec.ts +++ b/packages/core/tests/collection/functions/createGroup.function.spec.ts @@ -1,7 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; -import Group from "../../../src/collection/group"; +import {Agile, Group} from "../../../src"; describe('createGroup Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/createSelector.function.spec.ts b/packages/core/tests/collection/functions/createSelector.function.spec.ts index d3572684..12df39d3 100644 --- a/packages/core/tests/collection/functions/createSelector.function.spec.ts +++ b/packages/core/tests/collection/functions/createSelector.function.spec.ts @@ -1,8 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; -import Selector from "../../../src/collection/selector"; -import Item from "../../../src/collection/item"; +import {Agile, Selector, Item} from "../../../src"; describe('createSelector Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/findById.function.spec.ts b/packages/core/tests/collection/functions/findById.function.spec.ts index e3b8a4f6..319e7ce6 100644 --- a/packages/core/tests/collection/functions/findById.function.spec.ts +++ b/packages/core/tests/collection/functions/findById.function.spec.ts @@ -1,7 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; -import State from "../../../src/state"; +import {State, Agile} from "../../../src"; describe('FindById Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/getGroup.function.spec.ts b/packages/core/tests/collection/functions/getGroup.function.spec.ts index a49c5a09..fa406378 100644 --- a/packages/core/tests/collection/functions/getGroup.function.spec.ts +++ b/packages/core/tests/collection/functions/getGroup.function.spec.ts @@ -1,7 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; -import Group from "../../../src/collection/group"; +import {Agile, Group} from "../../../src"; describe('getGroup Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/getSelector.function.spec.ts b/packages/core/tests/collection/functions/getSelector.function.spec.ts index 4c19ddfd..6b2dc61f 100644 --- a/packages/core/tests/collection/functions/getSelector.function.spec.ts +++ b/packages/core/tests/collection/functions/getSelector.function.spec.ts @@ -1,7 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; -import Selector from "../../../src/collection/selector"; +import {Agile, Selector} from "../../../src"; describe('getSelector Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/getValueById.function.spec.ts b/packages/core/tests/collection/functions/getValueById.function.spec.ts index 0eff6acb..a339801f 100644 --- a/packages/core/tests/collection/functions/getValueById.function.spec.ts +++ b/packages/core/tests/collection/functions/getValueById.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('GetValueById Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/remove.function.spec.ts b/packages/core/tests/collection/functions/remove.function.spec.ts index 4cec7fee..d1124afa 100644 --- a/packages/core/tests/collection/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/functions/remove.function.spec.ts @@ -1,8 +1,7 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile, Item} from "../../../src"; import {useAgile} from "../../../../react/tests"; -import Item from "../../../src/collection/item"; describe('Remove Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/update.function.spec.ts b/packages/core/tests/collection/functions/update.function.spec.ts index d2d3ce47..746e0809 100644 --- a/packages/core/tests/collection/functions/update.function.spec.ts +++ b/packages/core/tests/collection/functions/update.function.spec.ts @@ -1,8 +1,7 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile, Group} from "../../../src"; import {useAgile} from "../../../../react/tests"; -import Group from "../../../src/collection/group"; describe('Update Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/collection/group/default.spec.ts b/packages/core/tests/collection/group/default.spec.ts index 6b74926b..c2d05101 100644 --- a/packages/core/tests/collection/group/default.spec.ts +++ b/packages/core/tests/collection/group/default.spec.ts @@ -1,7 +1,7 @@ -import Agile from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import 'mocha'; import {expect} from "chai"; -import Group from "../../../src/collection/group"; +import {useAgile} from "../../../../react/tests"; +import {Agile, Group} from "../../../src"; describe('Default Group Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/group/functions/add.function.spec.ts b/packages/core/tests/collection/group/functions/add.function.spec.ts index 4754d9ac..1a9a0e84 100644 --- a/packages/core/tests/collection/group/functions/add.function.spec.ts +++ b/packages/core/tests/collection/group/functions/add.function.spec.ts @@ -1,7 +1,7 @@ -import Agile from "../../../../src"; -import {useAgile} from "../../../../react/tests"; +import 'mocha'; import {expect} from "chai"; -import Group from "../../../../src/collection/group"; +import {useAgile} from "../../../../../react/tests"; +import {Agile, Group} from "../../../../src"; describe('Add function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/collection/group/functions/has.function.spec.ts b/packages/core/tests/collection/group/functions/has.function.spec.ts index aa0fd782..cfb668e8 100644 --- a/packages/core/tests/collection/group/functions/has.function.spec.ts +++ b/packages/core/tests/collection/group/functions/has.function.spec.ts @@ -1,6 +1,5 @@ -import Agile from "../../../../src"; import {expect} from "chai"; -import Group from "../../../../src/collection/group"; +import {Agile, Group} from "../../../../src"; describe('Has function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/group/functions/remove.function.spec.ts b/packages/core/tests/collection/group/functions/remove.function.spec.ts index 657459e7..3d1ee96a 100644 --- a/packages/core/tests/collection/group/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/group/functions/remove.function.spec.ts @@ -1,7 +1,7 @@ -import Agile from "../../../../src"; -import {useAgile} from "../../../../../react/tests"; +import 'mocha'; import {expect} from "chai"; -import Group from "../../../../src/collection/group"; +import {Agile, Group} from "../../../../src"; +import {useAgile} from "../../../../../react/tests"; describe('Add function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/collection/selector/default.spec.ts b/packages/core/tests/collection/selector/default.spec.ts index 4be0de3d..20876990 100644 --- a/packages/core/tests/collection/selector/default.spec.ts +++ b/packages/core/tests/collection/selector/default.spec.ts @@ -1,8 +1,7 @@ -import Agile from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import 'mocha'; import {expect} from "chai"; -import Selector from "../../../src/collection/selector"; -import Item from "../../../src/collection/item"; +import {useAgile} from "../../../../react/tests"; +import {Agile, Selector, Item} from "../../../src"; describe('Default Selector Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/selector/functions/select.function.spec.ts b/packages/core/tests/collection/selector/functions/select.function.spec.ts index ca64ac84..eb9b6204 100644 --- a/packages/core/tests/collection/selector/functions/select.function.spec.ts +++ b/packages/core/tests/collection/selector/functions/select.function.spec.ts @@ -1,8 +1,7 @@ -import Agile from "../../../../src"; -import {useAgile} from "../../../../../react/tests"; +import 'mocha'; import {expect} from "chai"; -import Selector from "../../../../src/collection/selector"; -import Item from "../../../../src/collection/item"; +import {Agile, Selector, Item} from "../../../../src"; +import {useAgile} from "../../../../../react/tests"; describe('select Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/computed/default.spec.ts b/packages/core/tests/computed/default.spec.ts index 9c00f235..54c3be7a 100644 --- a/packages/core/tests/computed/default.spec.ts +++ b/packages/core/tests/computed/default.spec.ts @@ -1,7 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../src"; -import Computed from "../../src/computed"; +import {Agile, Computed} from "../../src"; import {useAgile} from "../../../react/tests"; describe('Default Computed Tests', () => { diff --git a/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts index b1a05d24..eb03a0e0 100644 --- a/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts +++ b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts @@ -1,7 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; -import Computed from "../../../src/computed"; +import {Agile, Computed} from "../../../src"; import {useAgile} from "../../../../react/tests"; describe('updateComputeFunction Function tests', () => { diff --git a/packages/core/tests/event/default.spec.ts b/packages/core/tests/event/default.spec.ts index 4154441f..5f81f4e5 100644 --- a/packages/core/tests/event/default.spec.ts +++ b/packages/core/tests/event/default.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../src"; +import {Agile} from "../../src"; describe('Default Event Tests', () => { // Define Agile diff --git a/packages/core/tests/event/functions/disable.function.spec.ts b/packages/core/tests/event/functions/disable.function.spec.ts index 96f402d9..a3e39b42 100644 --- a/packages/core/tests/event/functions/disable.function.spec.ts +++ b/packages/core/tests/event/functions/disable.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('Disable Function Tests', () => { // Define Agile diff --git a/packages/core/tests/event/functions/enable.function.spec.ts b/packages/core/tests/event/functions/enable.function.spec.ts index 75f68673..3d29defb 100644 --- a/packages/core/tests/event/functions/enable.function.spec.ts +++ b/packages/core/tests/event/functions/enable.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('Enable Function Tests', () => { // Define Agile diff --git a/packages/core/tests/event/functions/on.function.spec.ts b/packages/core/tests/event/functions/on.function.spec.ts index 6047b2b3..603b5baa 100644 --- a/packages/core/tests/event/functions/on.function.spec.ts +++ b/packages/core/tests/event/functions/on.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('On Function Tests', () => { let eventCallCount = 0; diff --git a/packages/core/tests/event/functions/reset.function.spec.ts b/packages/core/tests/event/functions/reset.function.spec.ts index 18dead87..65138de5 100644 --- a/packages/core/tests/event/functions/reset.function.spec.ts +++ b/packages/core/tests/event/functions/reset.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('Reset Function Tests', () => { // Define Agile diff --git a/packages/core/tests/event/functions/trigger.function.spec.ts b/packages/core/tests/event/functions/trigger.function.spec.ts index 13539820..d5735ccc 100644 --- a/packages/core/tests/event/functions/trigger.function.spec.ts +++ b/packages/core/tests/event/functions/trigger.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; import {useEvent} from "../../../../react/tests"; diff --git a/packages/core/tests/framework.spec.ts b/packages/core/tests/framework.spec.ts index d17ac99e..3fc983fb 100644 --- a/packages/core/tests/framework.spec.ts +++ b/packages/core/tests/framework.spec.ts @@ -1,18 +1,28 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../src"; +import {Agile, Integration} from "../src"; describe('Custom Framework Tests', () => { let boundFramework = false; + const customIntegration = new Integration({ + name: 'test2', + updateMethod: () => { + }, + bind: () => { + } + }) + // Define Agile with framework const App = new Agile(); + /* it('Has bound custom Framework', () => { expect(boundFramework).to.eq(true, 'boundFramework has correct value'); - expect(App.integration?.name).to.eq('test', 'Integration Name has correct value'); + expect(App.integrations.integrations.size).to.eq(2, 'Integrations has correct size'); expect(typeof App.integration?.bind === 'function').to.eq(true, 'Integration bind method get set'); expect(typeof App.integration?.updateMethod === 'function').to.eq(true, 'Integration updateMethod method get set'); expect(App.integration?.ready).to.eq(true, 'Integration is Ready'); }); + */ }); diff --git a/packages/core/tests/state/default.spec.ts b/packages/core/tests/state/default.spec.ts index f24ffa1d..eac9f38e 100644 --- a/packages/core/tests/state/default.spec.ts +++ b/packages/core/tests/state/default.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../src"; +import {Agile} from "../../src"; describe('Default State Tests', () => { // Define Agile diff --git a/packages/core/tests/state/functions/patch.function.spec.ts b/packages/core/tests/state/functions/patch.function.spec.ts index 28c3c1e9..681d8d78 100644 --- a/packages/core/tests/state/functions/patch.function.spec.ts +++ b/packages/core/tests/state/functions/patch.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; import {useAgile} from "../../../../react/tests"; describe('Patch Function Tests', () => { diff --git a/packages/core/tests/state/functions/persist.function.spec.ts b/packages/core/tests/state/functions/persist.function.spec.ts index ae4d4add..a0c892be 100644 --- a/packages/core/tests/state/functions/persist.function.spec.ts +++ b/packages/core/tests/state/functions/persist.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('Persist Function Tests', () => { diff --git a/packages/core/tests/state/functions/reset.function.spec.ts b/packages/core/tests/state/functions/reset.function.spec.ts index 1039b2d0..998cd3b2 100644 --- a/packages/core/tests/state/functions/reset.function.spec.ts +++ b/packages/core/tests/state/functions/reset.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; import {useAgile} from "../../../../react/tests"; describe('Reset Function Tests', () => { diff --git a/packages/core/tests/state/functions/set.function.spec.ts b/packages/core/tests/state/functions/set.function.spec.ts index dd7e9e0f..24e4d161 100644 --- a/packages/core/tests/state/functions/set.function.spec.ts +++ b/packages/core/tests/state/functions/set.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; import {useAgile} from "../../../../react/tests"; describe('Set Function Tests', () => { diff --git a/packages/core/tests/state/functions/type.function.spec.ts b/packages/core/tests/state/functions/type.function.spec.ts index 6810195d..6ef4480a 100644 --- a/packages/core/tests/state/functions/type.function.spec.ts +++ b/packages/core/tests/state/functions/type.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai' -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('Type Function Tests', () => { // Define Agile diff --git a/packages/core/tests/state/functions/undo.function.spec.ts b/packages/core/tests/state/functions/undo.function.spec.ts index 5fcc80d0..0e63fc12 100644 --- a/packages/core/tests/state/functions/undo.function.spec.ts +++ b/packages/core/tests/state/functions/undo.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; import {useAgile} from "../../../../react/tests"; describe('Undo Function Tests', () => { diff --git a/packages/core/tests/state/functions/watch.function.spec.ts b/packages/core/tests/state/functions/watch.function.spec.ts index 1b598bea..0879b2fc 100644 --- a/packages/core/tests/state/functions/watch.function.spec.ts +++ b/packages/core/tests/state/functions/watch.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../../../src"; +import {Agile} from "../../../src"; describe('Watcher Tests', () => { let calledWatcherCount = 0; diff --git a/packages/core/tests/storage.spec.ts b/packages/core/tests/storage.spec.ts index 93847963..ad1c40fb 100644 --- a/packages/core/tests/storage.spec.ts +++ b/packages/core/tests/storage.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from 'chai'; -import Agile from "../src"; +import {Agile} from "../src"; describe('Custom Storage Tests', () => { const myStorage: any = {} diff --git a/packages/react/package-lock.json b/packages/react/package-lock.json new file mode 100644 index 00000000..2fa8cad3 --- /dev/null +++ b/packages/react/package-lock.json @@ -0,0 +1,1537 @@ +{ + "name": "@agile-ts/react", + "version": "0.0.2", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@agile-ts/core": { + "version": "file:../core" + }, + "@types/chai": { + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", + "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==", + "dev": true + }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", + "dev": true + }, + "@types/mocha": { + "version": "8.0.3", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.3.tgz", + "integrity": "sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==", + "dev": true + }, + "@types/node": { + "version": "14.11.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.11.2.tgz", + "integrity": "sha512-jiE3QIxJ8JLNcb1Ps6rDbysDhN4xa8DJJvuC9prr6w+1tIh+QAbYyNF3tyiZNLDBIuBCf4KEcV2UvQm/V60xfA==", + "dev": true + }, + "@types/prop-types": { + "version": "15.7.3", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.3.tgz", + "integrity": "sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw==", + "dev": true + }, + "@types/react": { + "version": "16.9.49", + "resolved": "https://registry.npmjs.org/@types/react/-/react-16.9.49.tgz", + "integrity": "sha512-DtLFjSj0OYAdVLBbyjhuV9CdGVHCkHn2R+xr3XkBvK2rS1Y1tkc14XSGjYgm5Fjjr90AxH9tiSzc1pCFMGO06g==", + "dev": true, + "requires": { + "@types/prop-types": "*", + "csstype": "^3.0.2" + } + }, + "ansi-colors": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", + "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", + "dev": true + }, + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", + "dev": true + }, + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", + "dev": true, + "requires": { + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" + } + }, + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "dev": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "array.prototype.map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", + "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.4" + } + }, + "assertion-error": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", + "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", + "dev": true + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "binary-extensions": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==", + "dev": true + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "requires": { + "fill-range": "^7.0.1" + } + }, + "browser-stdout": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", + "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", + "dev": true + }, + "buffer-from": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", + "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", + "dev": true + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true + }, + "chai": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", + "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", + "dev": true, + "requires": { + "assertion-error": "^1.1.0", + "check-error": "^1.0.2", + "deep-eql": "^3.0.1", + "get-func-name": "^2.0.0", + "pathval": "^1.1.0", + "type-detect": "^4.0.5" + } + }, + "chalk": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", + "dev": true, + "requires": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + } + }, + "check-error": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", + "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", + "dev": true + }, + "chokidar": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", + "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", + "dev": true, + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "fsevents": "~2.1.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.4.0" + } + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "requires": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + } + }, + "csstype": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.0.3.tgz", + "integrity": "sha512-jPl+wbWPOWJ7SXsWyqGRk3lGecbar0Cb0OvZF/r/ZU011R4YqiRehgkQ9p4eQfo9DSDLqLL3wHwfxeJiuIsNag==", + "dev": true + }, + "debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", + "dev": true + }, + "deep-eql": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", + "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", + "dev": true, + "requires": { + "type-detect": "^4.0.0" + } + }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "dev": true, + "requires": { + "object-keys": "^1.0.12" + } + }, + "diff": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==", + "dev": true + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "es-abstract": { + "version": "1.17.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", + "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", + "dev": true, + "requires": { + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.2.0", + "is-regex": "^1.1.0", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimend": "^1.0.1", + "string.prototype.trimstart": "^1.0.1" + } + }, + "es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==", + "dev": true + }, + "es-get-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", + "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", + "dev": true, + "requires": { + "es-abstract": "^1.17.4", + "has-symbols": "^1.0.1", + "is-arguments": "^1.0.4", + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-string": "^1.0.5", + "isarray": "^2.0.5" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dev": true, + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "dev": true + }, + "eslint-config-prettier": { + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.12.0.tgz", + "integrity": "sha512-9jWPlFlgNwRUYVoujvWTQ1aMO8o6648r+K7qU7K5Jmkbyqav1fuEZC0COYpGBxyiAJb65Ra9hrmFx19xRGwXWw==", + "dev": true, + "requires": { + "get-stdin": "^6.0.0" + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, + "event-stream": { + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", + "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", + "dev": true, + "requires": { + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", + "pause-stream": "0.0.11", + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" + } + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "dev": true, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "dev": true, + "requires": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + } + }, + "flat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", + "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", + "dev": true, + "requires": { + "is-buffer": "~2.0.3" + } + }, + "from": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", + "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=", + "dev": true + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fsevents": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", + "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", + "dev": true + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true + }, + "get-func-name": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", + "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=", + "dev": true + }, + "get-stdin": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", + "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==", + "dev": true + }, + "glob": { + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "dev": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", + "dev": true, + "requires": { + "is-glob": "^4.0.1" + } + }, + "growl": { + "version": "1.10.5", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", + "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", + "dev": true + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "has-symbols": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", + "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", + "dev": true + }, + "he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", + "dev": true + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "is-arguments": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==", + "dev": true + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", + "dev": true + }, + "is-callable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz", + "integrity": "sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA==", + "dev": true + }, + "is-date-object": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", + "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", + "dev": true + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", + "dev": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", + "dev": true, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", + "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==", + "dev": true + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true + }, + "is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=", + "dev": true + }, + "is-regex": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", + "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "is-set": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", + "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==", + "dev": true + }, + "is-string": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", + "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==", + "dev": true + }, + "is-symbol": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", + "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", + "dev": true, + "requires": { + "has-symbols": "^1.0.1" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "dev": true + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "iterate-iterator": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", + "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==", + "dev": true + }, + "iterate-value": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", + "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", + "dev": true, + "requires": { + "es-get-iterator": "^1.0.2", + "iterate-iterator": "^1.0.1" + } + }, + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true + }, + "js-yaml": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", + "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", + "dev": true, + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "dev": true, + "requires": { + "p-locate": "^5.0.0" + } + }, + "log-symbols": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.0.0.tgz", + "integrity": "sha512-FN8JBzLx6CzeMrB0tg6pqlGU1wCrXW+ZXGH481kfsBqer0hToTIiHdjH4Mq8xJUbvATujKCvaREGWpGUionraA==", + "dev": true, + "requires": { + "chalk": "^4.0.0" + } + }, + "loose-envify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", + "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "dev": true, + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } + }, + "make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true + }, + "map-stream": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=", + "dev": true + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "mocha": { + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.3.tgz", + "integrity": "sha512-ZbaYib4hT4PpF4bdSO2DohooKXIn4lDeiYqB+vTmCdr6l2woW0b6H3pf5x4sM5nwQMru9RvjjHYWVGltR50ZBw==", + "dev": true, + "requires": { + "ansi-colors": "4.1.1", + "browser-stdout": "1.3.1", + "chokidar": "3.4.2", + "debug": "4.1.1", + "diff": "4.0.2", + "escape-string-regexp": "4.0.0", + "find-up": "5.0.0", + "glob": "7.1.6", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.14.0", + "log-symbols": "4.0.0", + "minimatch": "3.0.4", + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "4.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.1" + } + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node-cleanup": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", + "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=", + "dev": true + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", + "dev": true + }, + "object-inspect": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", + "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==", + "dev": true + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "dev": true + }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "dev": true, + "requires": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "p-limit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", + "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "dev": true, + "requires": { + "p-limit": "^3.0.2" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true + }, + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", + "dev": true + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true + }, + "pathval": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", + "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=", + "dev": true + }, + "pause-stream": { + "version": "0.0.11", + "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", + "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", + "dev": true, + "requires": { + "through": "~2.3" + } + }, + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", + "dev": true + }, + "prettier": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", + "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==", + "dev": true + }, + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "dev": true, + "requires": { + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" + } + }, + "prop-types": { + "version": "15.7.2", + "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz", + "integrity": "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==", + "dev": true, + "requires": { + "loose-envify": "^1.4.0", + "object-assign": "^4.1.1", + "react-is": "^16.8.1" + } + }, + "ps-tree": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", + "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", + "dev": true, + "requires": { + "event-stream": "=3.3.4" + } + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dev": true, + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "react": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react/-/react-16.13.1.tgz", + "integrity": "sha512-YMZQQq32xHLX0bz5Mnibv1/LHb3Sqzngu7xstSM+vrkE5Kzr9xE0yMByK5kMoTK30YVJE61WfbxIFFvfeDKT1w==", + "dev": true, + "requires": { + "loose-envify": "^1.1.0", + "object-assign": "^4.1.1", + "prop-types": "^15.6.2" + } + }, + "react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", + "dev": true + }, + "readdirp": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", + "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", + "dev": true, + "requires": { + "picomatch": "^2.2.1" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "dev": true + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", + "dev": true + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true + }, + "serialize-javascript": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", + "dev": true, + "requires": { + "randombytes": "^2.1.0" + } + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true + }, + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + }, + "source-map-support": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", + "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", + "dev": true, + "requires": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "split": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", + "dev": true, + "requires": { + "through": "2" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", + "dev": true + }, + "stream-combiner": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "dev": true, + "requires": { + "duplexer": "~0.1.1" + } + }, + "string-argv": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", + "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==", + "dev": true + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + } + }, + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "dev": true, + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "dev": true, + "requires": { + "ansi-regex": "^3.0.0" + } + }, + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==", + "dev": true + }, + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "dev": true, + "requires": { + "has-flag": "^4.0.0" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "requires": { + "is-number": "^7.0.0" + } + }, + "ts-node": { + "version": "8.10.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", + "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", + "dev": true, + "requires": { + "arg": "^4.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "source-map-support": "^0.5.17", + "yn": "3.1.1" + } + }, + "tsc-watch": { + "version": "4.2.9", + "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", + "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", + "dev": true, + "requires": { + "cross-spawn": "^7.0.3", + "node-cleanup": "^2.1.2", + "ps-tree": "^1.2.0", + "string-argv": "^0.1.1", + "strip-ansi": "^6.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==", + "dev": true + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "dev": true, + "requires": { + "ansi-regex": "^5.0.0" + } + } + } + }, + "tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==", + "dev": true + }, + "type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true + }, + "typescript": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", + "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==", + "dev": true + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "dev": true + }, + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "dev": true, + "requires": { + "string-width": "^1.0.2 || 2" + } + }, + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==", + "dev": true + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", + "dev": true + }, + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "yargs-unparser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", + "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", + "dev": true, + "requires": { + "camelcase": "^5.3.1", + "decamelize": "^1.2.0", + "flat": "^4.1.0", + "is-plain-obj": "^1.1.0", + "yargs": "^14.2.3" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "yargs": { + "version": "14.2.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", + "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + } + }, + "yargs-parser": { + "version": "15.0.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", + "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + } + } + }, + "yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", + "dev": true + } + } +} diff --git a/packages/react/package.json b/packages/react/package.json index 65934e40..46b471d8 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { - "name": "@agile/react", - "version": "0.0.1", + "name": "@agile-ts/react", + "version": "0.0.2", "author": "BennoDev", "license": "ISC", "description": "React extension for AgileTs", @@ -11,14 +11,25 @@ "build": "tsc" }, "dependencies": { - "@agile/core": "link:../core" + "@agile-ts/core": "file:../core" }, "peerDependencies": { "react": "^16.13.1" }, "devDependencies": { "@types/react": "^16.9.49", - "react": "^16.13.1" + "react": "^16.13.1", + "@types/chai": "^4.2.12", + "@types/mocha": "^8.0.2", + "@types/node": "^14.6.0", + "chai": "^4.2.0", + "eslint-config-prettier": "^6.11.0", + "mocha": "^8.1.1", + "prettier": "2.0.5", + "ts-node": "^8.10.2", + "tsc-watch": "^4.1.0", + "tslib": "^2.0.0", + "typescript": "^3.9.7" }, "publishConfig": { "access": "public" @@ -26,5 +37,8 @@ "repository": { "type": "git", "url": "https://github.com/agile-ts/agile.git" - } + }, + "files": [ + "dist/**/*" + ] } diff --git a/packages/react/src/hooks/AgileHOC.ts b/packages/react/src/hooks/AgileHOC.ts index ca451103..5bfbded6 100644 --- a/packages/react/src/hooks/AgileHOC.ts +++ b/packages/react/src/hooks/AgileHOC.ts @@ -1,5 +1,5 @@ import React from "react"; -import {State, Agile, ComponentSubscriptionContainer, getAgileInstance, normalizeArray} from "@agile/core"; +import {State, Agile, ComponentSubscriptionContainer, getAgileInstance, normalizeArray} from "@agile-ts/core"; export function AgileHOC(ReactComponent: any, deps?: Array | { [key: string]: State } | State, agileInstance?: Agile) { let depsArray: Array; diff --git a/packages/react/src/hooks/useAgile.ts b/packages/react/src/hooks/useAgile.ts index 65e451a6..8cc80a26 100644 --- a/packages/react/src/hooks/useAgile.ts +++ b/packages/react/src/hooks/useAgile.ts @@ -1,5 +1,5 @@ import React from "react"; -import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '@agile/core'; +import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '@agile-ts/core'; // Array Type // https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-1.html diff --git a/packages/react/src/hooks/useEvent.ts b/packages/react/src/hooks/useEvent.ts index 7722d689..28a6220b 100644 --- a/packages/react/src/hooks/useEvent.ts +++ b/packages/react/src/hooks/useEvent.ts @@ -1,5 +1,5 @@ import React from "react"; -import {Event, EventCallbackFunction} from '@agile/core'; +import {Event, EventCallbackFunction} from '@agile-ts/core'; export function useEvent(event: E, callback: EventCallbackFunction) { // Call event on component mount and remove event on component unmount diff --git a/packages/react/src/react.integration.ts b/packages/react/src/react.integration.ts index bcbb36f4..c98f65cb 100644 --- a/packages/react/src/react.integration.ts +++ b/packages/react/src/react.integration.ts @@ -1,4 +1,4 @@ -import {Agile, Integration} from '@agile/core' +import {Agile, Integration} from '@agile-ts/core' import React from 'react'; const reactIntegration = new Integration({ diff --git a/packages/react/tests/hooks/useAgile.ts b/packages/react/tests/hooks/useAgile.ts index 9386e3b1..be74f212 100644 --- a/packages/react/tests/hooks/useAgile.ts +++ b/packages/react/tests/hooks/useAgile.ts @@ -1,4 +1,4 @@ -import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '@agile/core'; +import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '@agile-ts/core'; //========================================================================================================= diff --git a/packages/react/tests/hooks/useEvent.ts b/packages/react/tests/hooks/useEvent.ts index 20991f84..e480be88 100644 --- a/packages/react/tests/hooks/useEvent.ts +++ b/packages/react/tests/hooks/useEvent.ts @@ -1,4 +1,4 @@ -import {Event, EventCallbackFunction} from '@agile/core'; +import {Event, EventCallbackFunction} from '@agile-ts/core'; export function useEvent(event: E, callback: EventCallbackFunction) { event.on(callback); diff --git a/packages/react/tests/test.integration.ts b/packages/react/tests/test.integration.ts index a8b15434..b2e68b18 100644 --- a/packages/react/tests/test.integration.ts +++ b/packages/react/tests/test.integration.ts @@ -1,4 +1,4 @@ -import {Agile, Integration} from '@agile/core' +import {Agile, Integration} from '@agile-ts/core' const testIntegration = new Integration({ name: 'test', From 33b1c00635cb60084cb6275d0b4c79d71904dffb Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Thu, 1 Oct 2020 14:18:58 +0200 Subject: [PATCH 08/15] Fixed cycle dependency bug and imported right modules into example --- examples/react-typescript/package-lock.json | 10051 +++++++++--------- examples/react-typescript/package.json | 3 +- examples/react-typescript/src/App.tsx | 3 +- examples/react-typescript/src/core/index.ts | 4 +- packages/core/src/collection/group.ts | 4 +- packages/core/src/internal.ts | 29 +- 6 files changed, 4997 insertions(+), 5097 deletions(-) diff --git a/examples/react-typescript/package-lock.json b/examples/react-typescript/package-lock.json index d23e1ec2..16d4e3c9 100644 --- a/examples/react-typescript/package-lock.json +++ b/examples/react-typescript/package-lock.json @@ -4,3214 +4,2367 @@ "lockfileVersion": 1, "requires": true, "dependencies": { - "@babel/code-frame": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", - "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", - "requires": { - "@babel/highlight": "^7.10.4" - } - }, - "@babel/compat-data": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.11.0.tgz", - "integrity": "sha512-TPSvJfv73ng0pfnEOh17bYMPQbI95+nGWc71Ss4vZdRBHTDqmM9Z8ZV4rYz8Ks7sfzc95n30k6ODIq5UGnXcYQ==", - "requires": { - "browserslist": "^4.12.0", - "invariant": "^2.2.4", - "semver": "^5.5.0" - }, - "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" - } - } - }, - "@babel/core": { - "version": "7.9.0", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.9.0.tgz", - "integrity": "sha512-kWc7L0fw1xwvI0zi8OKVBuxRVefwGOrKSQMvrQ3dW+bIIavBY3/NpXmpjMy7bQnLgwgzWQZ8TlM57YHpHNHz4w==", - "requires": { - "@babel/code-frame": "^7.8.3", - "@babel/generator": "^7.9.0", - "@babel/helper-module-transforms": "^7.9.0", - "@babel/helpers": "^7.9.0", - "@babel/parser": "^7.9.0", - "@babel/template": "^7.8.6", - "@babel/traverse": "^7.9.0", - "@babel/types": "^7.9.0", - "convert-source-map": "^1.7.0", - "debug": "^4.1.0", - "gensync": "^1.0.0-beta.1", - "json5": "^2.1.2", - "lodash": "^4.17.13", - "resolve": "^1.3.2", - "semver": "^5.4.1", - "source-map": "^0.5.0" - }, + "@agile-ts/core": { + "version": "file:../../packages/core", "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + "@types/chai": { + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", + "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==" }, - "source-map": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" - } - } - }, - "@babel/generator": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.11.0.tgz", - "integrity": "sha512-fEm3Uzw7Mc9Xi//qU20cBKatTfs2aOtKqmvy/Vm7RkJEGFQ4xc9myCfbXxqK//ZS8MR/ciOHw6meGASJuKmDfQ==", - "requires": { - "@babel/types": "^7.11.0", - "jsesc": "^2.5.1", - "source-map": "^0.5.0" - }, - "dependencies": { - "source-map": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" - } - } - }, - "@babel/helper-annotate-as-pure": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.10.4.tgz", - "integrity": "sha512-XQlqKQP4vXFB7BN8fEEerrmYvHp3fK/rBkRFz9jaJbzK0B1DSfej9Kc7ZzE8Z/OnId1jpJdNAZ3BFQjWG68rcA==", - "requires": { - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-builder-binary-assignment-operator-visitor": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.10.4.tgz", - "integrity": "sha512-L0zGlFrGWZK4PbT8AszSfLTM5sDU1+Az/En9VrdT8/LmEiJt4zXt+Jve9DCAnQcbqDhCI+29y/L93mrDzddCcg==", - "requires": { - "@babel/helper-explode-assignable-expression": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-builder-react-jsx": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-builder-react-jsx/-/helper-builder-react-jsx-7.10.4.tgz", - "integrity": "sha512-5nPcIZ7+KKDxT1427oBivl9V9YTal7qk0diccnh7RrcgrT/pGFOjgGw1dgryyx1GvHEpXVfoDF6Ak3rTiWh8Rg==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-builder-react-jsx-experimental": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/helper-builder-react-jsx-experimental/-/helper-builder-react-jsx-experimental-7.10.5.tgz", - "integrity": "sha512-Buewnx6M4ttG+NLkKyt7baQn7ScC/Td+e99G914fRU8fGIUivDDgVIQeDHFa5e4CRSJQt58WpNHhsAZgtzVhsg==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-module-imports": "^7.10.4", - "@babel/types": "^7.10.5" - } - }, - "@babel/helper-compilation-targets": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.10.4.tgz", - "integrity": "sha512-a3rYhlsGV0UHNDvrtOXBg8/OpfV0OKTkxKPzIplS1zpx7CygDcWWxckxZeDd3gzPzC4kUT0A4nVFDK0wGMh4MQ==", - "requires": { - "@babel/compat-data": "^7.10.4", - "browserslist": "^4.12.0", - "invariant": "^2.2.4", - "levenary": "^1.1.1", - "semver": "^5.5.0" - }, - "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" - } - } - }, - "@babel/helper-create-class-features-plugin": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.10.5.tgz", - "integrity": "sha512-0nkdeijB7VlZoLT3r/mY3bUkw3T8WG/hNw+FATs/6+pG2039IJWjTYL0VTISqsNHMUTEnwbVnc89WIJX9Qed0A==", - "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-member-expression-to-functions": "^7.10.5", - "@babel/helper-optimise-call-expression": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.10.4" - } - }, - "@babel/helper-create-regexp-features-plugin": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.10.4.tgz", - "integrity": "sha512-2/hu58IEPKeoLF45DBwx3XFqsbCXmkdAay4spVr2x0jYgRxrSNp+ePwvSsy9g6YSaNDcKIQVPXk1Ov8S2edk2g==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-regex": "^7.10.4", - "regexpu-core": "^4.7.0" - } - }, - "@babel/helper-define-map": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/helper-define-map/-/helper-define-map-7.10.5.tgz", - "integrity": "sha512-fMw4kgFB720aQFXSVaXr79pjjcW5puTCM16+rECJ/plGS+zByelE8l9nCpV1GibxTnFVmUuYG9U8wYfQHdzOEQ==", - "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/types": "^7.10.5", - "lodash": "^4.17.19" - } - }, - "@babel/helper-explode-assignable-expression": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.10.4.tgz", - "integrity": "sha512-4K71RyRQNPRrR85sr5QY4X3VwG4wtVoXZB9+L3r1Gp38DhELyHCtovqydRi7c1Ovb17eRGiQ/FD5s8JdU0Uy5A==", - "requires": { - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-function-name": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.10.4.tgz", - "integrity": "sha512-YdaSyz1n8gY44EmN7x44zBn9zQ1Ry2Y+3GTA+3vH6Mizke1Vw0aWDM66FOYEPw8//qKkmqOckrGgTYa+6sceqQ==", - "requires": { - "@babel/helper-get-function-arity": "^7.10.4", - "@babel/template": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-get-function-arity": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.10.4.tgz", - "integrity": "sha512-EkN3YDB+SRDgiIUnNgcmiD361ti+AVbL3f3Henf6dqqUyr5dMsorno0lJWJuLhDhkI5sYEpgj6y9kB8AOU1I2A==", - "requires": { - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-hoist-variables": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.10.4.tgz", - "integrity": "sha512-wljroF5PgCk2juF69kanHVs6vrLwIPNp6DLD+Lrl3hoQ3PpPPikaDRNFA+0t81NOoMt2DL6WW/mdU8k4k6ZzuA==", - "requires": { - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-member-expression-to-functions": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.11.0.tgz", - "integrity": "sha512-JbFlKHFntRV5qKw3YC0CvQnDZ4XMwgzzBbld7Ly4Mj4cbFy3KywcR8NtNctRToMWJOVvLINJv525Gd6wwVEx/Q==", - "requires": { - "@babel/types": "^7.11.0" - } - }, - "@babel/helper-module-imports": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.10.4.tgz", - "integrity": "sha512-nEQJHqYavI217oD9+s5MUBzk6x1IlvoS9WTPfgG43CbMEeStE0v+r+TucWdx8KFGowPGvyOkDT9+7DHedIDnVw==", - "requires": { - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-module-transforms": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.11.0.tgz", - "integrity": "sha512-02EVu8COMuTRO1TAzdMtpBPbe6aQ1w/8fePD2YgQmxZU4gpNWaL9gK3Jp7dxlkUlUCJOTaSeA+Hrm1BRQwqIhg==", - "requires": { - "@babel/helper-module-imports": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4", - "@babel/helper-simple-access": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.11.0", - "@babel/template": "^7.10.4", - "@babel/types": "^7.11.0", - "lodash": "^4.17.19" - } - }, - "@babel/helper-optimise-call-expression": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.10.4.tgz", - "integrity": "sha512-n3UGKY4VXwXThEiKrgRAoVPBMqeoPgHVqiHZOanAJCG9nQUL2pLRQirUzl0ioKclHGpGqRgIOkgcIJaIWLpygg==", - "requires": { - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==" - }, - "@babel/helper-regex": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.10.5.tgz", - "integrity": "sha512-68kdUAzDrljqBrio7DYAEgCoJHxppJOERHOgOrDN7WjOzP0ZQ1LsSDRXcemzVZaLvjaJsJEESb6qt+znNuENDg==", - "requires": { - "lodash": "^4.17.19" - } - }, - "@babel/helper-remap-async-to-generator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.10.4.tgz", - "integrity": "sha512-86Lsr6NNw3qTNl+TBcF1oRZMaVzJtbWTyTko+CQL/tvNvcGYEFKbLXDPxtW0HKk3McNOk4KzY55itGWCAGK5tg==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-wrap-function": "^7.10.4", - "@babel/template": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-replace-supers": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.10.4.tgz", - "integrity": "sha512-sPxZfFXocEymYTdVK1UNmFPBN+Hv5mJkLPsYWwGBxZAxaWfFu+xqp7b6qWD0yjNuNL2VKc6L5M18tOXUP7NU0A==", - "requires": { - "@babel/helper-member-expression-to-functions": "^7.10.4", - "@babel/helper-optimise-call-expression": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-simple-access": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.10.4.tgz", - "integrity": "sha512-0fMy72ej/VEvF8ULmX6yb5MtHG4uH4Dbd6I/aHDb/JVg0bbivwt9Wg+h3uMvX+QSFtwr5MeItvazbrc4jtRAXw==", - "requires": { - "@babel/template": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helper-skip-transparent-expression-wrappers": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.11.0.tgz", - "integrity": "sha512-0XIdiQln4Elglgjbwo9wuJpL/K7AGCY26kmEt0+pRP0TAj4jjyNq1MjoRvikrTVqKcx4Gysxt4cXvVFXP/JO2Q==", - "requires": { - "@babel/types": "^7.11.0" - } - }, - "@babel/helper-split-export-declaration": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.11.0.tgz", - "integrity": "sha512-74Vejvp6mHkGE+m+k5vHY93FX2cAtrw1zXrZXRlG4l410Nm9PxfEiVTn1PjDPV5SnmieiueY4AFg2xqhNFuuZg==", - "requires": { - "@babel/types": "^7.11.0" - } - }, - "@babel/helper-validator-identifier": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", - "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==" - }, - "@babel/helper-wrap-function": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.10.4.tgz", - "integrity": "sha512-6py45WvEF0MhiLrdxtRjKjufwLL1/ob2qDJgg5JgNdojBAZSAKnAjkyOCNug6n+OBl4VW76XjvgSFTdaMcW0Ug==", - "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/template": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/helpers": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.10.4.tgz", - "integrity": "sha512-L2gX/XeUONeEbI78dXSrJzGdz4GQ+ZTA/aazfUsFaWjSe95kiCuOZ5HsXvkiw3iwF+mFHSRUfJU8t6YavocdXA==", - "requires": { - "@babel/template": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/highlight": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", - "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", - "requires": { - "@babel/helper-validator-identifier": "^7.10.4", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, - "@babel/parser": { - "version": "7.11.3", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.11.3.tgz", - "integrity": "sha512-REo8xv7+sDxkKvoxEywIdsNFiZLybwdI7hcT5uEPyQrSMB4YQ973BfC9OOrD/81MaIjh6UxdulIQXkjmiH3PcA==" - }, - "@babel/plugin-proposal-async-generator-functions": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.10.5.tgz", - "integrity": "sha512-cNMCVezQbrRGvXJwm9fu/1sJj9bHdGAgKodZdLqOQIpfoH3raqmRPBM17+lh7CzhiKRRBrGtZL9WcjxSoGYUSg==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-remap-async-to-generator": "^7.10.4", - "@babel/plugin-syntax-async-generators": "^7.8.0" - } - }, - "@babel/plugin-proposal-class-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.10.4.tgz", - "integrity": "sha512-vhwkEROxzcHGNu2mzUC0OFFNXdZ4M23ib8aRRcJSsW8BZK9pQMD7QB7csl97NBbgGZO7ZyHUyKDnxzOaP4IrCg==", - "requires": { - "@babel/helper-create-class-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-proposal-decorators": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-decorators/-/plugin-proposal-decorators-7.8.3.tgz", - "integrity": "sha512-e3RvdvS4qPJVTe288DlXjwKflpfy1hr0j5dz5WpIYYeP7vQZg2WfAEIp8k5/Lwis/m5REXEteIz6rrcDtXXG7w==", - "requires": { - "@babel/helper-create-class-features-plugin": "^7.8.3", - "@babel/helper-plugin-utils": "^7.8.3", - "@babel/plugin-syntax-decorators": "^7.8.3" - } - }, - "@babel/plugin-proposal-dynamic-import": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.10.4.tgz", - "integrity": "sha512-up6oID1LeidOOASNXgv/CFbgBqTuKJ0cJjz6An5tWD+NVBNlp3VNSBxv2ZdU7SYl3NxJC7agAQDApZusV6uFwQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-dynamic-import": "^7.8.0" - } - }, - "@babel/plugin-proposal-export-namespace-from": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.10.4.tgz", - "integrity": "sha512-aNdf0LY6/3WXkhh0Fdb6Zk9j1NMD8ovj3F6r0+3j837Pn1S1PdNtcwJ5EG9WkVPNHPxyJDaxMaAOVq4eki0qbg==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-export-namespace-from": "^7.8.3" - } - }, - "@babel/plugin-proposal-json-strings": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.10.4.tgz", - "integrity": "sha512-fCL7QF0Jo83uy1K0P2YXrfX11tj3lkpN7l4dMv9Y9VkowkhkQDwFHFd8IiwyK5MZjE8UpbgokkgtcReH88Abaw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-json-strings": "^7.8.0" - } - }, - "@babel/plugin-proposal-logical-assignment-operators": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.11.0.tgz", - "integrity": "sha512-/f8p4z+Auz0Uaf+i8Ekf1iM7wUNLcViFUGiPxKeXvxTSl63B875YPiVdUDdem7hREcI0E0kSpEhS8tF5RphK7Q==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4" - } - }, - "@babel/plugin-proposal-nullish-coalescing-operator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.10.4.tgz", - "integrity": "sha512-wq5n1M3ZUlHl9sqT2ok1T2/MTt6AXE0e1Lz4WzWBr95LsAZ5qDXe4KnFuauYyEyLiohvXFMdbsOTMyLZs91Zlw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0" - } - }, - "@babel/plugin-proposal-numeric-separator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.10.4.tgz", - "integrity": "sha512-73/G7QoRoeNkLZFxsoCCvlg4ezE4eM+57PnOqgaPOozd5myfj7p0muD1mRVJvbUWbOzD+q3No2bWbaKy+DJ8DA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-numeric-separator": "^7.10.4" - } - }, - "@babel/plugin-proposal-object-rest-spread": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.11.0.tgz", - "integrity": "sha512-wzch41N4yztwoRw0ak+37wxwJM2oiIiy6huGCoqkvSTA9acYWcPfn9Y4aJqmFFJ70KTJUu29f3DQ43uJ9HXzEA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-object-rest-spread": "^7.8.0", - "@babel/plugin-transform-parameters": "^7.10.4" - } - }, - "@babel/plugin-proposal-optional-catch-binding": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.10.4.tgz", - "integrity": "sha512-LflT6nPh+GK2MnFiKDyLiqSqVHkQnVf7hdoAvyTnnKj9xB3docGRsdPuxp6qqqW19ifK3xgc9U5/FwrSaCNX5g==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-optional-catch-binding": "^7.8.0" - } - }, - "@babel/plugin-proposal-optional-chaining": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.11.0.tgz", - "integrity": "sha512-v9fZIu3Y8562RRwhm1BbMRxtqZNFmFA2EG+pT2diuU8PT3H6T/KXoZ54KgYisfOFZHV6PfvAiBIZ9Rcz+/JCxA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-skip-transparent-expression-wrappers": "^7.11.0", - "@babel/plugin-syntax-optional-chaining": "^7.8.0" - } - }, - "@babel/plugin-proposal-private-methods": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.10.4.tgz", - "integrity": "sha512-wh5GJleuI8k3emgTg5KkJK6kHNsGEr0uBTDBuQUBJwckk9xs1ez79ioheEVVxMLyPscB0LfkbVHslQqIzWV6Bw==", - "requires": { - "@babel/helper-create-class-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-proposal-unicode-property-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.10.4.tgz", - "integrity": "sha512-H+3fOgPnEXFL9zGYtKQe4IDOPKYlZdF1kqFDQRRb8PK4B8af1vAGK04tF5iQAAsui+mHNBQSAtd2/ndEDe9wuA==", - "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-async-generators": { - "version": "7.8.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", - "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-syntax-class-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.10.4.tgz", - "integrity": "sha512-GCSBF7iUle6rNugfURwNmCGG3Z/2+opxAMLs1nND4bhEG5PuxTIggDBoeYYSujAlLtsupzOHYJQgPS3pivwXIA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-decorators": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-decorators/-/plugin-syntax-decorators-7.10.4.tgz", - "integrity": "sha512-2NaoC6fAk2VMdhY1eerkfHV+lVYC1u8b+jmRJISqANCJlTxYy19HGdIkkQtix2UtkcPuPu+IlDgrVseZnU03bw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-dynamic-import": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", - "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-syntax-export-namespace-from": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz", - "integrity": "sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.3" - } - }, - "@babel/plugin-syntax-flow": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-flow/-/plugin-syntax-flow-7.10.4.tgz", - "integrity": "sha512-yxQsX1dJixF4qEEdzVbst3SZQ58Nrooz8NV9Z9GL4byTE25BvJgl5lf0RECUf0fh28rZBb/RYTWn/eeKwCMrZQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-json-strings": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", - "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-syntax-jsx": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.10.4.tgz", - "integrity": "sha512-KCg9mio9jwiARCB7WAcQ7Y1q+qicILjoK8LP/VkPkEKaf5dkaZZK1EcTe91a3JJlZ3qy6L5s9X52boEYi8DM9g==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-logical-assignment-operators": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", - "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-nullish-coalescing-operator": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", - "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-syntax-numeric-separator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", - "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-object-rest-spread": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", - "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-syntax-optional-catch-binding": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", - "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-syntax-optional-chaining": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", - "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } - }, - "@babel/plugin-syntax-top-level-await": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.10.4.tgz", - "integrity": "sha512-ni1brg4lXEmWyafKr0ccFWkJG0CeMt4WV1oyeBW6EFObF4oOHclbkj5cARxAPQyAQ2UTuplJyK4nfkXIMMFvsQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-syntax-typescript": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.10.4.tgz", - "integrity": "sha512-oSAEz1YkBCAKr5Yiq8/BNtvSAPwkp/IyUnwZogd8p+F0RuYQQrLeRUzIQhueQTTBy/F+a40uS7OFKxnkRvmvFQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-arrow-functions": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.10.4.tgz", - "integrity": "sha512-9J/oD1jV0ZCBcgnoFWFq1vJd4msoKb/TCpGNFyyLt0zABdcvgK3aYikZ8HjzB14c26bc7E3Q1yugpwGy2aTPNA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-async-to-generator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.10.4.tgz", - "integrity": "sha512-F6nREOan7J5UXTLsDsZG3DXmZSVofr2tGNwfdrVwkDWHfQckbQXnXSPfD7iO+c/2HGqycwyLST3DnZ16n+cBJQ==", - "requires": { - "@babel/helper-module-imports": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-remap-async-to-generator": "^7.10.4" - } - }, - "@babel/plugin-transform-block-scoped-functions": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.10.4.tgz", - "integrity": "sha512-WzXDarQXYYfjaV1szJvN3AD7rZgZzC1JtjJZ8dMHUyiK8mxPRahynp14zzNjU3VkPqPsO38CzxiWO1c9ARZ8JA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-block-scoping": { - "version": "7.11.1", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.11.1.tgz", - "integrity": "sha512-00dYeDE0EVEHuuM+26+0w/SCL0BH2Qy7LwHuI4Hi4MH5gkC8/AqMN5uWFJIsoXZrAphiMm1iXzBw6L2T+eA0ew==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-classes": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.10.4.tgz", - "integrity": "sha512-2oZ9qLjt161dn1ZE0Ms66xBncQH4In8Sqw1YWgBUZuGVJJS5c0OFZXL6dP2MRHrkU/eKhWg8CzFJhRQl50rQxA==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-define-map": "^7.10.4", - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-optimise-call-expression": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.10.4", - "globals": "^11.1.0" - } - }, - "@babel/plugin-transform-computed-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.10.4.tgz", - "integrity": "sha512-JFwVDXcP/hM/TbyzGq3l/XWGut7p46Z3QvqFMXTfk6/09m7xZHJUN9xHfsv7vqqD4YnfI5ueYdSJtXqqBLyjBw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-destructuring": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.10.4.tgz", - "integrity": "sha512-+WmfvyfsyF603iPa6825mq6Qrb7uLjTOsa3XOFzlYcYDHSS4QmpOWOL0NNBY5qMbvrcf3tq0Cw+v4lxswOBpgA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-dotall-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.10.4.tgz", - "integrity": "sha512-ZEAVvUTCMlMFAbASYSVQoxIbHm2OkG2MseW6bV2JjIygOjdVv8tuxrCTzj1+Rynh7ODb8GivUy7dzEXzEhuPaA==", - "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-duplicate-keys": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.10.4.tgz", - "integrity": "sha512-GL0/fJnmgMclHiBTTWXNlYjYsA7rDrtsazHG6mglaGSTh0KsrW04qml+Bbz9FL0LcJIRwBWL5ZqlNHKTkU3xAA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-exponentiation-operator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.10.4.tgz", - "integrity": "sha512-S5HgLVgkBcRdyQAHbKj+7KyuWx8C6t5oETmUuwz1pt3WTWJhsUV0WIIXuVvfXMxl/QQyHKlSCNNtaIamG8fysw==", - "requires": { - "@babel/helper-builder-binary-assignment-operator-visitor": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-flow-strip-types": { - "version": "7.9.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-flow-strip-types/-/plugin-transform-flow-strip-types-7.9.0.tgz", - "integrity": "sha512-7Qfg0lKQhEHs93FChxVLAvhBshOPQDtJUTVHr/ZwQNRccCm4O9D79r9tVSoV8iNwjP1YgfD+e/fgHcPkN1qEQg==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.3", - "@babel/plugin-syntax-flow": "^7.8.3" - } - }, - "@babel/plugin-transform-for-of": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.10.4.tgz", - "integrity": "sha512-ItdQfAzu9AlEqmusA/65TqJ79eRcgGmpPPFvBnGILXZH975G0LNjP1yjHvGgfuCxqrPPueXOPe+FsvxmxKiHHQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-function-name": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.10.4.tgz", - "integrity": "sha512-OcDCq2y5+E0dVD5MagT5X+yTRbcvFjDI2ZVAottGH6tzqjx/LKpgkUepu3hp/u4tZBzxxpNGwLsAvGBvQ2mJzg==", - "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-literals": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.10.4.tgz", - "integrity": "sha512-Xd/dFSTEVuUWnyZiMu76/InZxLTYilOSr1UlHV+p115Z/Le2Fi1KXkJUYz0b42DfndostYlPub3m8ZTQlMaiqQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-member-expression-literals": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.10.4.tgz", - "integrity": "sha512-0bFOvPyAoTBhtcJLr9VcwZqKmSjFml1iVxvPL0ReomGU53CX53HsM4h2SzckNdkQcHox1bpAqzxBI1Y09LlBSw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-modules-amd": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.10.5.tgz", - "integrity": "sha512-elm5uruNio7CTLFItVC/rIzKLfQ17+fX7EVz5W0TMgIHFo1zY0Ozzx+lgwhL4plzl8OzVn6Qasx5DeEFyoNiRw==", - "requires": { - "@babel/helper-module-transforms": "^7.10.5", - "@babel/helper-plugin-utils": "^7.10.4", - "babel-plugin-dynamic-import-node": "^2.3.3" - } - }, - "@babel/plugin-transform-modules-commonjs": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.10.4.tgz", - "integrity": "sha512-Xj7Uq5o80HDLlW64rVfDBhao6OX89HKUmb+9vWYaLXBZOma4gA6tw4Ni1O5qVDoZWUV0fxMYA0aYzOawz0l+1w==", - "requires": { - "@babel/helper-module-transforms": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-simple-access": "^7.10.4", - "babel-plugin-dynamic-import-node": "^2.3.3" - } - }, - "@babel/plugin-transform-modules-systemjs": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.10.5.tgz", - "integrity": "sha512-f4RLO/OL14/FP1AEbcsWMzpbUz6tssRaeQg11RH1BP/XnPpRoVwgeYViMFacnkaw4k4wjRSjn3ip1Uw9TaXuMw==", - "requires": { - "@babel/helper-hoist-variables": "^7.10.4", - "@babel/helper-module-transforms": "^7.10.5", - "@babel/helper-plugin-utils": "^7.10.4", - "babel-plugin-dynamic-import-node": "^2.3.3" - } - }, - "@babel/plugin-transform-modules-umd": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.10.4.tgz", - "integrity": "sha512-mohW5q3uAEt8T45YT7Qc5ws6mWgJAaL/8BfWD9Dodo1A3RKWli8wTS+WiQ/knF+tXlPirW/1/MqzzGfCExKECA==", - "requires": { - "@babel/helper-module-transforms": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-named-capturing-groups-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.10.4.tgz", - "integrity": "sha512-V6LuOnD31kTkxQPhKiVYzYC/Jgdq53irJC/xBSmqcNcqFGV+PER4l6rU5SH2Vl7bH9mLDHcc0+l9HUOe4RNGKA==", - "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4" - } - }, - "@babel/plugin-transform-new-target": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.10.4.tgz", - "integrity": "sha512-YXwWUDAH/J6dlfwqlWsztI2Puz1NtUAubXhOPLQ5gjR/qmQ5U96DY4FQO8At33JN4XPBhrjB8I4eMmLROjjLjw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-object-super": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.10.4.tgz", - "integrity": "sha512-5iTw0JkdRdJvr7sY0vHqTpnruUpTea32JHmq/atIWqsnNussbRzjEDyWep8UNztt1B5IusBYg8Irb0bLbiEBCQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4" - } - }, - "@babel/plugin-transform-parameters": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.10.5.tgz", - "integrity": "sha512-xPHwUj5RdFV8l1wuYiu5S9fqWGM2DrYc24TMvUiRrPVm+SM3XeqU9BcokQX/kEUe+p2RBwy+yoiR1w/Blq6ubw==", - "requires": { - "@babel/helper-get-function-arity": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-property-literals": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.10.4.tgz", - "integrity": "sha512-ofsAcKiUxQ8TY4sScgsGeR2vJIsfrzqvFb9GvJ5UdXDzl+MyYCaBj/FGzXuv7qE0aJcjWMILny1epqelnFlz8g==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-react-constant-elements": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.10.4.tgz", - "integrity": "sha512-cYmQBW1pXrqBte1raMkAulXmi7rjg3VI6ZLg9QIic8Hq7BtYXaWuZSxsr2siOMI6SWwpxjWfnwhTUrd7JlAV7g==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-react-display-name": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-display-name/-/plugin-transform-react-display-name-7.10.4.tgz", - "integrity": "sha512-Zd4X54Mu9SBfPGnEcaGcOrVAYOtjT2on8QZkLKEq1S/tHexG39d9XXGZv19VfRrDjPJzFmPfTAqOQS1pfFOujw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-react-jsx": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.10.4.tgz", - "integrity": "sha512-L+MfRhWjX0eI7Js093MM6MacKU4M6dnCRa/QPDwYMxjljzSCzzlzKzj9Pk4P3OtrPcxr2N3znR419nr3Xw+65A==", - "requires": { - "@babel/helper-builder-react-jsx": "^7.10.4", - "@babel/helper-builder-react-jsx-experimental": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-jsx": "^7.10.4" - } - }, - "@babel/plugin-transform-react-jsx-development": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-development/-/plugin-transform-react-jsx-development-7.10.4.tgz", - "integrity": "sha512-RM3ZAd1sU1iQ7rI2dhrZRZGv0aqzNQMbkIUCS1txYpi9wHQ2ZHNjo5TwX+UD6pvFW4AbWqLVYvKy5qJSAyRGjQ==", - "requires": { - "@babel/helper-builder-react-jsx-experimental": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-jsx": "^7.10.4" - } - }, - "@babel/plugin-transform-react-jsx-self": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.10.4.tgz", - "integrity": "sha512-yOvxY2pDiVJi0axdTWHSMi5T0DILN+H+SaeJeACHKjQLezEzhLx9nEF9xgpBLPtkZsks9cnb5P9iBEi21En3gg==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-jsx": "^7.10.4" - } - }, - "@babel/plugin-transform-react-jsx-source": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.10.5.tgz", - "integrity": "sha512-wTeqHVkN1lfPLubRiZH3o73f4rfon42HpgxUSs86Nc+8QIcm/B9s8NNVXu/gwGcOyd7yDib9ikxoDLxJP0UiDA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-jsx": "^7.10.4" - } - }, - "@babel/plugin-transform-react-pure-annotations": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-pure-annotations/-/plugin-transform-react-pure-annotations-7.10.4.tgz", - "integrity": "sha512-+njZkqcOuS8RaPakrnR9KvxjoG1ASJWpoIv/doyWngId88JoFlPlISenGXjrVacZUIALGUr6eodRs1vmPnF23A==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-regenerator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.10.4.tgz", - "integrity": "sha512-3thAHwtor39A7C04XucbMg17RcZ3Qppfxr22wYzZNcVIkPHfpM9J0SO8zuCV6SZa265kxBJSrfKTvDCYqBFXGw==", - "requires": { - "regenerator-transform": "^0.14.2" - } - }, - "@babel/plugin-transform-reserved-words": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.10.4.tgz", - "integrity": "sha512-hGsw1O6Rew1fkFbDImZIEqA8GoidwTAilwCyWqLBM9f+e/u/sQMQu7uX6dyokfOayRuuVfKOW4O7HvaBWM+JlQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-runtime": { - "version": "7.9.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.9.0.tgz", - "integrity": "sha512-pUu9VSf3kI1OqbWINQ7MaugnitRss1z533436waNXp+0N3ur3zfut37sXiQMxkuCF4VUjwZucen/quskCh7NHw==", - "requires": { - "@babel/helper-module-imports": "^7.8.3", - "@babel/helper-plugin-utils": "^7.8.3", - "resolve": "^1.8.1", - "semver": "^5.5.1" - }, - "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" - } - } - }, - "@babel/plugin-transform-shorthand-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.10.4.tgz", - "integrity": "sha512-AC2K/t7o07KeTIxMoHneyX90v3zkm5cjHJEokrPEAGEy3UCp8sLKfnfOIGdZ194fyN4wfX/zZUWT9trJZ0qc+Q==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-spread": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.11.0.tgz", - "integrity": "sha512-UwQYGOqIdQJe4aWNyS7noqAnN2VbaczPLiEtln+zPowRNlD+79w3oi2TWfYe0eZgd+gjZCbsydN7lzWysDt+gw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-skip-transparent-expression-wrappers": "^7.11.0" - } - }, - "@babel/plugin-transform-sticky-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.10.4.tgz", - "integrity": "sha512-Ddy3QZfIbEV0VYcVtFDCjeE4xwVTJWTmUtorAJkn6u/92Z/nWJNV+mILyqHKrUxXYKA2EoCilgoPePymKL4DvQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-regex": "^7.10.4" - } - }, - "@babel/plugin-transform-template-literals": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.10.5.tgz", - "integrity": "sha512-V/lnPGIb+KT12OQikDvgSuesRX14ck5FfJXt6+tXhdkJ+Vsd0lDCVtF6jcB4rNClYFzaB2jusZ+lNISDk2mMMw==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-typeof-symbol": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.10.4.tgz", - "integrity": "sha512-QqNgYwuuW0y0H+kUE/GWSR45t/ccRhe14Fs/4ZRouNNQsyd4o3PG4OtHiIrepbM2WKUBDAXKCAK/Lk4VhzTaGA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-typescript": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.11.0.tgz", - "integrity": "sha512-edJsNzTtvb3MaXQwj8403B7mZoGu9ElDJQZOKjGUnvilquxBA3IQoEIOvkX/1O8xfAsnHS/oQhe2w/IXrr+w0w==", - "requires": { - "@babel/helper-create-class-features-plugin": "^7.10.5", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-typescript": "^7.10.4" - } - }, - "@babel/plugin-transform-unicode-escapes": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.10.4.tgz", - "integrity": "sha512-y5XJ9waMti2J+e7ij20e+aH+fho7Wb7W8rNuu72aKRwCHFqQdhkdU2lo3uZ9tQuboEJcUFayXdARhcxLQ3+6Fg==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/plugin-transform-unicode-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.10.4.tgz", - "integrity": "sha512-wNfsc4s8N2qnIwpO/WP2ZiSyjfpTamT2C9V9FDH/Ljub9zw6P3SjkXcFmc0RQUt96k2fmIvtla2MMjgTwIAC+A==", - "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } - }, - "@babel/preset-env": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.11.0.tgz", - "integrity": "sha512-2u1/k7rG/gTh02dylX2kL3S0IJNF+J6bfDSp4DI2Ma8QN6Y9x9pmAax59fsCk6QUQG0yqH47yJWA+u1I1LccAg==", - "requires": { - "@babel/compat-data": "^7.11.0", - "@babel/helper-compilation-targets": "^7.10.4", - "@babel/helper-module-imports": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-proposal-async-generator-functions": "^7.10.4", - "@babel/plugin-proposal-class-properties": "^7.10.4", - "@babel/plugin-proposal-dynamic-import": "^7.10.4", - "@babel/plugin-proposal-export-namespace-from": "^7.10.4", - "@babel/plugin-proposal-json-strings": "^7.10.4", - "@babel/plugin-proposal-logical-assignment-operators": "^7.11.0", - "@babel/plugin-proposal-nullish-coalescing-operator": "^7.10.4", - "@babel/plugin-proposal-numeric-separator": "^7.10.4", - "@babel/plugin-proposal-object-rest-spread": "^7.11.0", - "@babel/plugin-proposal-optional-catch-binding": "^7.10.4", - "@babel/plugin-proposal-optional-chaining": "^7.11.0", - "@babel/plugin-proposal-private-methods": "^7.10.4", - "@babel/plugin-proposal-unicode-property-regex": "^7.10.4", - "@babel/plugin-syntax-async-generators": "^7.8.0", - "@babel/plugin-syntax-class-properties": "^7.10.4", - "@babel/plugin-syntax-dynamic-import": "^7.8.0", - "@babel/plugin-syntax-export-namespace-from": "^7.8.3", - "@babel/plugin-syntax-json-strings": "^7.8.0", - "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", - "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0", - "@babel/plugin-syntax-numeric-separator": "^7.10.4", - "@babel/plugin-syntax-object-rest-spread": "^7.8.0", - "@babel/plugin-syntax-optional-catch-binding": "^7.8.0", - "@babel/plugin-syntax-optional-chaining": "^7.8.0", - "@babel/plugin-syntax-top-level-await": "^7.10.4", - "@babel/plugin-transform-arrow-functions": "^7.10.4", - "@babel/plugin-transform-async-to-generator": "^7.10.4", - "@babel/plugin-transform-block-scoped-functions": "^7.10.4", - "@babel/plugin-transform-block-scoping": "^7.10.4", - "@babel/plugin-transform-classes": "^7.10.4", - "@babel/plugin-transform-computed-properties": "^7.10.4", - "@babel/plugin-transform-destructuring": "^7.10.4", - "@babel/plugin-transform-dotall-regex": "^7.10.4", - "@babel/plugin-transform-duplicate-keys": "^7.10.4", - "@babel/plugin-transform-exponentiation-operator": "^7.10.4", - "@babel/plugin-transform-for-of": "^7.10.4", - "@babel/plugin-transform-function-name": "^7.10.4", - "@babel/plugin-transform-literals": "^7.10.4", - "@babel/plugin-transform-member-expression-literals": "^7.10.4", - "@babel/plugin-transform-modules-amd": "^7.10.4", - "@babel/plugin-transform-modules-commonjs": "^7.10.4", - "@babel/plugin-transform-modules-systemjs": "^7.10.4", - "@babel/plugin-transform-modules-umd": "^7.10.4", - "@babel/plugin-transform-named-capturing-groups-regex": "^7.10.4", - "@babel/plugin-transform-new-target": "^7.10.4", - "@babel/plugin-transform-object-super": "^7.10.4", - "@babel/plugin-transform-parameters": "^7.10.4", - "@babel/plugin-transform-property-literals": "^7.10.4", - "@babel/plugin-transform-regenerator": "^7.10.4", - "@babel/plugin-transform-reserved-words": "^7.10.4", - "@babel/plugin-transform-shorthand-properties": "^7.10.4", - "@babel/plugin-transform-spread": "^7.11.0", - "@babel/plugin-transform-sticky-regex": "^7.10.4", - "@babel/plugin-transform-template-literals": "^7.10.4", - "@babel/plugin-transform-typeof-symbol": "^7.10.4", - "@babel/plugin-transform-unicode-escapes": "^7.10.4", - "@babel/plugin-transform-unicode-regex": "^7.10.4", - "@babel/preset-modules": "^0.1.3", - "@babel/types": "^7.11.0", - "browserslist": "^4.12.0", - "core-js-compat": "^3.6.2", - "invariant": "^2.2.2", - "levenary": "^1.1.1", - "semver": "^5.5.0" - }, - "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" - } - } - }, - "@babel/preset-modules": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.3.tgz", - "integrity": "sha512-Ra3JXOHBq2xd56xSF7lMKXdjBn3T772Y1Wet3yWnkDly9zHvJki029tAFzvAAK5cf4YV3yoxuP61crYRol6SVg==", - "requires": { - "@babel/helper-plugin-utils": "^7.0.0", - "@babel/plugin-proposal-unicode-property-regex": "^7.4.4", - "@babel/plugin-transform-dotall-regex": "^7.4.4", - "@babel/types": "^7.4.4", - "esutils": "^2.0.2" - } - }, - "@babel/preset-react": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/preset-react/-/preset-react-7.10.4.tgz", - "integrity": "sha512-BrHp4TgOIy4M19JAfO1LhycVXOPWdDbTRep7eVyatf174Hff+6Uk53sDyajqZPu8W1qXRBiYOfIamek6jA7YVw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-transform-react-display-name": "^7.10.4", - "@babel/plugin-transform-react-jsx": "^7.10.4", - "@babel/plugin-transform-react-jsx-development": "^7.10.4", - "@babel/plugin-transform-react-jsx-self": "^7.10.4", - "@babel/plugin-transform-react-jsx-source": "^7.10.4", - "@babel/plugin-transform-react-pure-annotations": "^7.10.4" - } - }, - "@babel/preset-typescript": { - "version": "7.9.0", - "resolved": "https://registry.npmjs.org/@babel/preset-typescript/-/preset-typescript-7.9.0.tgz", - "integrity": "sha512-S4cueFnGrIbvYJgwsVFKdvOmpiL0XGw9MFW9D0vgRys5g36PBhZRL8NX8Gr2akz8XRtzq6HuDXPD/1nniagNUg==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.3", - "@babel/plugin-transform-typescript": "^7.9.0" - } - }, - "@babel/runtime": { - "version": "7.11.2", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.11.2.tgz", - "integrity": "sha512-TeWkU52so0mPtDcaCTxNBI/IHiz0pZgr8VEFqXFtZWpYD08ZB6FaSwVAS8MKRQAP3bYKiVjwysOJgMFY28o6Tw==", - "requires": { - "regenerator-runtime": "^0.13.4" - } - }, - "@babel/runtime-corejs3": { - "version": "7.11.2", - "resolved": "https://registry.npmjs.org/@babel/runtime-corejs3/-/runtime-corejs3-7.11.2.tgz", - "integrity": "sha512-qh5IR+8VgFz83VBa6OkaET6uN/mJOhHONuy3m1sgF0CV6mXdPSEBdA7e1eUbVvyNtANjMbg22JUv71BaDXLY6A==", - "requires": { - "core-js-pure": "^3.0.0", - "regenerator-runtime": "^0.13.4" - } - }, - "@babel/template": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.10.4.tgz", - "integrity": "sha512-ZCjD27cGJFUB6nmCB1Enki3r+L5kJveX9pq1SvAUKoICy6CZ9yD8xO086YXdYhvNjBdnekm4ZnaP5yC8Cs/1tA==", - "requires": { - "@babel/code-frame": "^7.10.4", - "@babel/parser": "^7.10.4", - "@babel/types": "^7.10.4" - } - }, - "@babel/traverse": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.11.0.tgz", - "integrity": "sha512-ZB2V+LskoWKNpMq6E5UUCrjtDUh5IOTAyIl0dTjIEoXum/iKWkoIEKIRDnUucO6f+2FzNkE0oD4RLKoPIufDtg==", - "requires": { - "@babel/code-frame": "^7.10.4", - "@babel/generator": "^7.11.0", - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.11.0", - "@babel/parser": "^7.11.0", - "@babel/types": "^7.11.0", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.19" - } - }, - "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", - "requires": { - "@babel/helper-validator-identifier": "^7.10.4", - "lodash": "^4.17.19", - "to-fast-properties": "^2.0.0" - } - }, - "@cnakazawa/watch": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@cnakazawa/watch/-/watch-1.0.4.tgz", - "integrity": "sha512-v9kIhKwjeZThiWrLmj0y17CWoyddASLj9O2yvbZkbvw/N3rWOYy9zkV66ursAoVr0mV15bL8g0c4QZUE6cdDoQ==", - "requires": { - "exec-sh": "^0.3.2", - "minimist": "^1.2.0" - } - }, - "@csstools/convert-colors": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/@csstools/convert-colors/-/convert-colors-1.4.0.tgz", - "integrity": "sha512-5a6wqoJV/xEdbRNKVo6I4hO3VjyDq//8q2f9I6PBAvMesJHFauXDorcNCsr9RzvsZnaWi5NYCcfyqP1QeFHFbw==" - }, - "@csstools/normalize.css": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/@csstools/normalize.css/-/normalize.css-10.1.0.tgz", - "integrity": "sha512-ij4wRiunFfaJxjB0BdrYHIH8FxBJpOwNPhhAcunlmPdXudL1WQV1qoP9un6JsEBAgQH+7UXyyjh0g7jTxXK6tg==" - }, - "@hapi/address": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@hapi/address/-/address-2.1.4.tgz", - "integrity": "sha512-QD1PhQk+s31P1ixsX0H0Suoupp3VMXzIVMSwobR3F3MSUO2YCV0B7xqLcUw/Bh8yuvd3LhpyqLQWTNcRmp6IdQ==" - }, - "@hapi/bourne": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/@hapi/bourne/-/bourne-1.3.2.tgz", - "integrity": "sha512-1dVNHT76Uu5N3eJNTYcvxee+jzX4Z9lfciqRRHCU27ihbUcYi+iSc2iml5Ke1LXe1SyJCLA0+14Jh4tXJgOppA==" - }, - "@hapi/hoek": { - "version": "8.5.1", - "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-8.5.1.tgz", - "integrity": "sha512-yN7kbciD87WzLGc5539Tn0sApjyiGHAJgKvG9W8C7O+6c7qmoQMfVs0W4bX17eqz6C78QJqqFrtgdK5EWf6Qow==" - }, - "@hapi/joi": { - "version": "15.1.1", - "resolved": "https://registry.npmjs.org/@hapi/joi/-/joi-15.1.1.tgz", - "integrity": "sha512-entf8ZMOK8sc+8YfeOlM8pCfg3b5+WZIKBfUaaJT8UsjAAPjartzxIYm3TIbjvA4u+u++KbcXD38k682nVHDAQ==", - "requires": { - "@hapi/address": "2.x.x", - "@hapi/bourne": "1.x.x", - "@hapi/hoek": "8.x.x", - "@hapi/topo": "3.x.x" - } - }, - "@hapi/topo": { - "version": "3.1.6", - "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-3.1.6.tgz", - "integrity": "sha512-tAag0jEcjwH+P2quUfipd7liWCNX2F8NvYjQp2wtInsZxnMlypdw0FtAOLxtvvkO+GSRRbmNi8m/5y42PQJYCQ==", - "requires": { - "@hapi/hoek": "^8.3.0" - } - }, - "@jest/console": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/console/-/console-24.9.0.tgz", - "integrity": "sha512-Zuj6b8TnKXi3q4ymac8EQfc3ea/uhLeCGThFqXeC8H9/raaH8ARPUTdId+XyGd03Z4In0/VjD2OYFcBF09fNLQ==", - "requires": { - "@jest/source-map": "^24.9.0", - "chalk": "^2.0.1", - "slash": "^2.0.0" - } - }, - "@jest/core": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/core/-/core-24.9.0.tgz", - "integrity": "sha512-Fogg3s4wlAr1VX7q+rhV9RVnUv5tD7VuWfYy1+whMiWUrvl7U3QJSJyWcDio9Lq2prqYsZaeTv2Rz24pWGkJ2A==", - "requires": { - "@jest/console": "^24.7.1", - "@jest/reporters": "^24.9.0", - "@jest/test-result": "^24.9.0", - "@jest/transform": "^24.9.0", - "@jest/types": "^24.9.0", - "ansi-escapes": "^3.0.0", - "chalk": "^2.0.1", - "exit": "^0.1.2", - "graceful-fs": "^4.1.15", - "jest-changed-files": "^24.9.0", - "jest-config": "^24.9.0", - "jest-haste-map": "^24.9.0", - "jest-message-util": "^24.9.0", - "jest-regex-util": "^24.3.0", - "jest-resolve": "^24.9.0", - "jest-resolve-dependencies": "^24.9.0", - "jest-runner": "^24.9.0", - "jest-runtime": "^24.9.0", - "jest-snapshot": "^24.9.0", - "jest-util": "^24.9.0", - "jest-validate": "^24.9.0", - "jest-watcher": "^24.9.0", - "micromatch": "^3.1.10", - "p-each-series": "^1.0.0", - "realpath-native": "^1.1.0", - "rimraf": "^2.5.4", - "slash": "^2.0.0", - "strip-ansi": "^5.0.0" - }, - "dependencies": { - "ansi-escapes": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.2.0.tgz", - "integrity": "sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==" - } - } - }, - "@jest/environment": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-24.9.0.tgz", - "integrity": "sha512-5A1QluTPhvdIPFYnO3sZC3smkNeXPVELz7ikPbhUj0bQjB07EoE9qtLrem14ZUYWdVayYbsjVwIiL4WBIMV4aQ==", - "requires": { - "@jest/fake-timers": "^24.9.0", - "@jest/transform": "^24.9.0", - "@jest/types": "^24.9.0", - "jest-mock": "^24.9.0" - } - }, - "@jest/fake-timers": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-24.9.0.tgz", - "integrity": "sha512-eWQcNa2YSwzXWIMC5KufBh3oWRIijrQFROsIqt6v/NS9Io/gknw1jsAC9c+ih/RQX4A3O7SeWAhQeN0goKhT9A==", - "requires": { - "@jest/types": "^24.9.0", - "jest-message-util": "^24.9.0", - "jest-mock": "^24.9.0" - } - }, - "@jest/reporters": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-24.9.0.tgz", - "integrity": "sha512-mu4X0yjaHrffOsWmVLzitKmmmWSQ3GGuefgNscUSWNiUNcEOSEQk9k3pERKEQVBb0Cnn88+UESIsZEMH3o88Gw==", - "requires": { - "@jest/environment": "^24.9.0", - "@jest/test-result": "^24.9.0", - "@jest/transform": "^24.9.0", - "@jest/types": "^24.9.0", - "chalk": "^2.0.1", - "exit": "^0.1.2", - "glob": "^7.1.2", - "istanbul-lib-coverage": "^2.0.2", - "istanbul-lib-instrument": "^3.0.1", - "istanbul-lib-report": "^2.0.4", - "istanbul-lib-source-maps": "^3.0.1", - "istanbul-reports": "^2.2.6", - "jest-haste-map": "^24.9.0", - "jest-resolve": "^24.9.0", - "jest-runtime": "^24.9.0", - "jest-util": "^24.9.0", - "jest-worker": "^24.6.0", - "node-notifier": "^5.4.2", - "slash": "^2.0.0", - "source-map": "^0.6.0", - "string-length": "^2.0.0" - } - }, - "@jest/source-map": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-24.9.0.tgz", - "integrity": "sha512-/Xw7xGlsZb4MJzNDgB7PW5crou5JqWiBQaz6xyPd3ArOg2nfn/PunV8+olXbbEZzNl591o5rWKE9BRDaFAuIBg==", - "requires": { - "callsites": "^3.0.0", - "graceful-fs": "^4.1.15", - "source-map": "^0.6.0" - }, - "dependencies": { - "callsites": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", - "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==" - } - } - }, - "@jest/test-result": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-24.9.0.tgz", - "integrity": "sha512-XEFrHbBonBJ8dGp2JmF8kP/nQI/ImPpygKHwQ/SY+es59Z3L5PI4Qb9TQQMAEeYsThG1xF0k6tmG0tIKATNiiA==", - "requires": { - "@jest/console": "^24.9.0", - "@jest/types": "^24.9.0", - "@types/istanbul-lib-coverage": "^2.0.0" - } - }, - "@jest/test-sequencer": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-24.9.0.tgz", - "integrity": "sha512-6qqsU4o0kW1dvA95qfNog8v8gkRN9ph6Lz7r96IvZpHdNipP2cBcb07J1Z45mz/VIS01OHJ3pY8T5fUY38tg4A==", - "requires": { - "@jest/test-result": "^24.9.0", - "jest-haste-map": "^24.9.0", - "jest-runner": "^24.9.0", - "jest-runtime": "^24.9.0" - } - }, - "@jest/transform": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-24.9.0.tgz", - "integrity": "sha512-TcQUmyNRxV94S0QpMOnZl0++6RMiqpbH/ZMccFB/amku6Uwvyb1cjYX7xkp5nGNkbX4QPH/FcB6q1HBTHynLmQ==", - "requires": { - "@babel/core": "^7.1.0", - "@jest/types": "^24.9.0", - "babel-plugin-istanbul": "^5.1.0", - "chalk": "^2.0.1", - "convert-source-map": "^1.4.0", - "fast-json-stable-stringify": "^2.0.0", - "graceful-fs": "^4.1.15", - "jest-haste-map": "^24.9.0", - "jest-regex-util": "^24.9.0", - "jest-util": "^24.9.0", - "micromatch": "^3.1.10", - "pirates": "^4.0.1", - "realpath-native": "^1.1.0", - "slash": "^2.0.0", - "source-map": "^0.6.1", - "write-file-atomic": "2.4.1" - } - }, - "@jest/types": { - "version": "24.9.0", - "resolved": "https://registry.npmjs.org/@jest/types/-/types-24.9.0.tgz", - "integrity": "sha512-XKK7ze1apu5JWQ5eZjHITP66AX+QsLlbaJRBGYr8pNzwcAE2JVkwnf0yqjHTsDRcjR0mujy/NmZMXw5kl+kGBw==", - "requires": { - "@types/istanbul-lib-coverage": "^2.0.0", - "@types/istanbul-reports": "^1.1.1", - "@types/yargs": "^13.0.0" - } - }, - "@mrmlnc/readdir-enhanced": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz", - "integrity": "sha512-bPHp6Ji8b41szTOcaP63VlnbbO5Ny6dwAATtY6JTjh5N2OLrb5Qk/Th5cRkRQhkWCt+EJsYrNB0MiL+Gpn6e3g==", - "requires": { - "call-me-maybe": "^1.0.1", - "glob-to-regexp": "^0.3.0" - } - }, - "@nodelib/fs.stat": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-1.1.3.tgz", - "integrity": "sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw==" - }, - "@sheerun/mutationobserver-shim": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@sheerun/mutationobserver-shim/-/mutationobserver-shim-0.3.3.tgz", - "integrity": "sha512-DetpxZw1fzPD5xUBrIAoplLChO2VB8DlL5Gg+I1IR9b2wPqYIca2WSUxL5g1vLeR4MsQq1NeWriXAVffV+U1Fw==" - }, - "@svgr/babel-plugin-add-jsx-attribute": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-add-jsx-attribute/-/babel-plugin-add-jsx-attribute-4.2.0.tgz", - "integrity": "sha512-j7KnilGyZzYr/jhcrSYS3FGWMZVaqyCG0vzMCwzvei0coIkczuYMcniK07nI0aHJINciujjH11T72ICW5eL5Ig==" - }, - "@svgr/babel-plugin-remove-jsx-attribute": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-attribute/-/babel-plugin-remove-jsx-attribute-4.2.0.tgz", - "integrity": "sha512-3XHLtJ+HbRCH4n28S7y/yZoEQnRpl0tvTZQsHqvaeNXPra+6vE5tbRliH3ox1yZYPCxrlqaJT/Mg+75GpDKlvQ==" - }, - "@svgr/babel-plugin-remove-jsx-empty-expression": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-empty-expression/-/babel-plugin-remove-jsx-empty-expression-4.2.0.tgz", - "integrity": "sha512-yTr2iLdf6oEuUE9MsRdvt0NmdpMBAkgK8Bjhl6epb+eQWk6abBaX3d65UZ3E3FWaOwePyUgNyNCMVG61gGCQ7w==" - }, - "@svgr/babel-plugin-replace-jsx-attribute-value": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-replace-jsx-attribute-value/-/babel-plugin-replace-jsx-attribute-value-4.2.0.tgz", - "integrity": "sha512-U9m870Kqm0ko8beHawRXLGLvSi/ZMrl89gJ5BNcT452fAjtF2p4uRzXkdzvGJJJYBgx7BmqlDjBN/eCp5AAX2w==" - }, - "@svgr/babel-plugin-svg-dynamic-title": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-dynamic-title/-/babel-plugin-svg-dynamic-title-4.3.3.tgz", - "integrity": "sha512-w3Be6xUNdwgParsvxkkeZb545VhXEwjGMwExMVBIdPQJeyMQHqm9Msnb2a1teHBqUYL66qtwfhNkbj1iarCG7w==" - }, - "@svgr/babel-plugin-svg-em-dimensions": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-em-dimensions/-/babel-plugin-svg-em-dimensions-4.2.0.tgz", - "integrity": "sha512-C0Uy+BHolCHGOZ8Dnr1zXy/KgpBOkEUYY9kI/HseHVPeMbluaX3CijJr7D4C5uR8zrc1T64nnq/k63ydQuGt4w==" - }, - "@svgr/babel-plugin-transform-react-native-svg": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-react-native-svg/-/babel-plugin-transform-react-native-svg-4.2.0.tgz", - "integrity": "sha512-7YvynOpZDpCOUoIVlaaOUU87J4Z6RdD6spYN4eUb5tfPoKGSF9OG2NuhgYnq4jSkAxcpMaXWPf1cePkzmqTPNw==" - }, - "@svgr/babel-plugin-transform-svg-component": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-svg-component/-/babel-plugin-transform-svg-component-4.2.0.tgz", - "integrity": "sha512-hYfYuZhQPCBVotABsXKSCfel2slf/yvJY8heTVX1PCTaq/IgASq1IyxPPKJ0chWREEKewIU/JMSsIGBtK1KKxw==" - }, - "@svgr/babel-preset": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/@svgr/babel-preset/-/babel-preset-4.3.3.tgz", - "integrity": "sha512-6PG80tdz4eAlYUN3g5GZiUjg2FMcp+Wn6rtnz5WJG9ITGEF1pmFdzq02597Hn0OmnQuCVaBYQE1OVFAnwOl+0A==", - "requires": { - "@svgr/babel-plugin-add-jsx-attribute": "^4.2.0", - "@svgr/babel-plugin-remove-jsx-attribute": "^4.2.0", - "@svgr/babel-plugin-remove-jsx-empty-expression": "^4.2.0", - "@svgr/babel-plugin-replace-jsx-attribute-value": "^4.2.0", - "@svgr/babel-plugin-svg-dynamic-title": "^4.3.3", - "@svgr/babel-plugin-svg-em-dimensions": "^4.2.0", - "@svgr/babel-plugin-transform-react-native-svg": "^4.2.0", - "@svgr/babel-plugin-transform-svg-component": "^4.2.0" - } - }, - "@svgr/core": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/@svgr/core/-/core-4.3.3.tgz", - "integrity": "sha512-qNuGF1QON1626UCaZamWt5yedpgOytvLj5BQZe2j1k1B8DUG4OyugZyfEwBeXozCUwhLEpsrgPrE+eCu4fY17w==", - "requires": { - "@svgr/plugin-jsx": "^4.3.3", - "camelcase": "^5.3.1", - "cosmiconfig": "^5.2.1" - } - }, - "@svgr/hast-util-to-babel-ast": { - "version": "4.3.2", - "resolved": "https://registry.npmjs.org/@svgr/hast-util-to-babel-ast/-/hast-util-to-babel-ast-4.3.2.tgz", - "integrity": "sha512-JioXclZGhFIDL3ddn4Kiq8qEqYM2PyDKV0aYno8+IXTLuYt6TOgHUbUAAFvqtb0Xn37NwP0BTHglejFoYr8RZg==", - "requires": { - "@babel/types": "^7.4.4" - } - }, - "@svgr/plugin-jsx": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/@svgr/plugin-jsx/-/plugin-jsx-4.3.3.tgz", - "integrity": "sha512-cLOCSpNWQnDB1/v+SUENHH7a0XY09bfuMKdq9+gYvtuwzC2rU4I0wKGFEp1i24holdQdwodCtDQdFtJiTCWc+w==", - "requires": { - "@babel/core": "^7.4.5", - "@svgr/babel-preset": "^4.3.3", - "@svgr/hast-util-to-babel-ast": "^4.3.2", - "svg-parser": "^2.0.0" - } - }, - "@svgr/plugin-svgo": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@svgr/plugin-svgo/-/plugin-svgo-4.3.1.tgz", - "integrity": "sha512-PrMtEDUWjX3Ea65JsVCwTIXuSqa3CG9px+DluF1/eo9mlDrgrtFE7NE/DjdhjJgSM9wenlVBzkzneSIUgfUI/w==", - "requires": { - "cosmiconfig": "^5.2.1", - "merge-deep": "^3.0.2", - "svgo": "^1.2.2" - } - }, - "@svgr/webpack": { - "version": "4.3.3", - "resolved": "https://registry.npmjs.org/@svgr/webpack/-/webpack-4.3.3.tgz", - "integrity": "sha512-bjnWolZ6KVsHhgyCoYRFmbd26p8XVbulCzSG53BDQqAr+JOAderYK7CuYrB3bDjHJuF6LJ7Wrr42+goLRV9qIg==", - "requires": { - "@babel/core": "^7.4.5", - "@babel/plugin-transform-react-constant-elements": "^7.0.0", - "@babel/preset-env": "^7.4.5", - "@babel/preset-react": "^7.0.0", - "@svgr/core": "^4.3.3", - "@svgr/plugin-jsx": "^4.3.3", - "@svgr/plugin-svgo": "^4.3.1", - "loader-utils": "^1.2.3" - } - }, - "@testing-library/dom": { - "version": "6.16.0", - "resolved": "https://registry.npmjs.org/@testing-library/dom/-/dom-6.16.0.tgz", - "integrity": "sha512-lBD88ssxqEfz0wFL6MeUyyWZfV/2cjEZZV3YRpb2IoJRej/4f1jB0TzqIOznTpfR1r34CNesrubxwIlAQ8zgPA==", - "requires": { - "@babel/runtime": "^7.8.4", - "@sheerun/mutationobserver-shim": "^0.3.2", - "@types/testing-library__dom": "^6.12.1", - "aria-query": "^4.0.2", - "dom-accessibility-api": "^0.3.0", - "pretty-format": "^25.1.0", - "wait-for-expect": "^3.0.2" - }, - "dependencies": { - "@jest/types": { - "version": "25.5.0", - "resolved": "https://registry.npmjs.org/@jest/types/-/types-25.5.0.tgz", - "integrity": "sha512-OXD0RgQ86Tu3MazKo8bnrkDRaDXXMGUqd+kTtLtK1Zb7CRzQcaSRPPPV37SvYTdevXEBVxe0HXylEjs8ibkmCw==", - "requires": { - "@types/istanbul-lib-coverage": "^2.0.0", - "@types/istanbul-reports": "^1.1.1", - "@types/yargs": "^15.0.0", - "chalk": "^3.0.0" - } - }, - "@types/yargs": { - "version": "15.0.5", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-15.0.5.tgz", - "integrity": "sha512-Dk/IDOPtOgubt/IaevIUbTgV7doaKkoorvOyYM2CMwuDyP89bekI7H4xLIwunNYiK9jhCkmc6pUrJk3cj2AB9w==", - "requires": { - "@types/yargs-parser": "*" - } - }, - "ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" - }, - "ansi-styles": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", - "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", - "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" - }, - "pretty-format": { - "version": "25.5.0", - "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-25.5.0.tgz", - "integrity": "sha512-kbo/kq2LQ/A/is0PQwsEHM7Ca6//bGPPvU6UnsdDRSKTWxT/ru/xb88v4BJf6a69H+uTytOEsTusT9ksd/1iWQ==", - "requires": { - "@jest/types": "^25.5.0", - "ansi-regex": "^5.0.0", - "ansi-styles": "^4.0.0", - "react-is": "^16.12.0" - } - }, - "supports-color": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", - "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", - "requires": { - "has-flag": "^4.0.0" - } - } - } - }, - "@testing-library/jest-dom": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/@testing-library/jest-dom/-/jest-dom-4.2.4.tgz", - "integrity": "sha512-j31Bn0rQo12fhCWOUWy9fl7wtqkp7In/YP2p5ZFyRuiiB9Qs3g+hS4gAmDWONbAHcRmVooNJ5eOHQDCOmUFXHg==", - "requires": { - "@babel/runtime": "^7.5.1", - "chalk": "^2.4.1", - "css": "^2.2.3", - "css.escape": "^1.5.1", - "jest-diff": "^24.0.0", - "jest-matcher-utils": "^24.0.0", - "lodash": "^4.17.11", - "pretty-format": "^24.0.0", - "redent": "^3.0.0" - } - }, - "@testing-library/react": { - "version": "9.5.0", - "resolved": "https://registry.npmjs.org/@testing-library/react/-/react-9.5.0.tgz", - "integrity": "sha512-di1b+D0p+rfeboHO5W7gTVeZDIK5+maEgstrZbWZSSvxDyfDRkkyBE1AJR5Psd6doNldluXlCWqXriUfqu/9Qg==", - "requires": { - "@babel/runtime": "^7.8.4", - "@testing-library/dom": "^6.15.0", - "@types/testing-library__react": "^9.1.2" - } - }, - "@testing-library/user-event": { - "version": "7.2.1", - "resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-7.2.1.tgz", - "integrity": "sha512-oZ0Ib5I4Z2pUEcoo95cT1cr6slco9WY7yiPpG+RGNkj8YcYgJnM7pXmYmorNOReh8MIGcKSqXyeGjxnr8YiZbA==" - }, - "@types/babel__core": { - "version": "7.1.9", - "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.1.9.tgz", - "integrity": "sha512-sY2RsIJ5rpER1u3/aQ8OFSI7qGIy8o1NEEbgb2UaJcvOtXOMpd39ko723NBpjQFg9SIX7TXtjejZVGeIMLhoOw==", - "requires": { - "@babel/parser": "^7.1.0", - "@babel/types": "^7.0.0", - "@types/babel__generator": "*", - "@types/babel__template": "*", - "@types/babel__traverse": "*" - } - }, - "@types/babel__generator": { - "version": "7.6.1", - "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.6.1.tgz", - "integrity": "sha512-bBKm+2VPJcMRVwNhxKu8W+5/zT7pwNEqeokFOmbvVSqGzFneNxYcEBro9Ac7/N9tlsaPYnZLK8J1LWKkMsLAew==", - "requires": { - "@babel/types": "^7.0.0" - } - }, - "@types/babel__template": { - "version": "7.0.2", - "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.0.2.tgz", - "integrity": "sha512-/K6zCpeW7Imzgab2bLkLEbz0+1JlFSrUMdw7KoIIu+IUdu51GWaBZpd3y1VXGVXzynvGa4DaIaxNZHiON3GXUg==", - "requires": { - "@babel/parser": "^7.1.0", - "@babel/types": "^7.0.0" - } - }, - "@types/babel__traverse": { - "version": "7.0.13", - "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.0.13.tgz", - "integrity": "sha512-i+zS7t6/s9cdQvbqKDARrcbrPvtJGlbYsMkazo03nTAK3RX9FNrLllXys22uiTGJapPOTZTQ35nHh4ISph4SLQ==", - "requires": { - "@babel/types": "^7.3.0" - } - }, - "@types/color-name": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", - "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==" - }, - "@types/eslint-visitor-keys": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/@types/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz", - "integrity": "sha512-OCutwjDZ4aFS6PB1UZ988C4YgwlBHJd6wCeQqaLdmadZ/7e+w79+hbMUFC1QXDNCmdyoRfAFdm0RypzwR+Qpag==" - }, - "@types/glob": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/@types/glob/-/glob-7.1.3.tgz", - "integrity": "sha512-SEYeGAIQIQX8NN6LDKprLjbrd5dARM5EXsd8GI/A5l0apYI1fGMWgPHSe4ZKL4eozlAyI+doUE9XbYS4xCkQ1w==", - "requires": { - "@types/minimatch": "*", - "@types/node": "*" - } - }, - "@types/istanbul-lib-coverage": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.3.tgz", - "integrity": "sha512-sz7iLqvVUg1gIedBOvlkxPlc8/uVzyS5OwGz1cKjXzkl3FpL3al0crU8YGU1WoHkxn0Wxbw5tyi6hvzJKNzFsw==" - }, - "@types/istanbul-lib-report": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz", - "integrity": "sha512-plGgXAPfVKFoYfa9NpYDAkseG+g6Jr294RqeqcqDixSbU34MZVJRi/P+7Y8GDpzkEwLaGZZOpKIEmeVZNtKsrg==", - "requires": { - "@types/istanbul-lib-coverage": "*" - } - }, - "@types/istanbul-reports": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-1.1.2.tgz", - "integrity": "sha512-P/W9yOX/3oPZSpaYOCQzGqgCQRXn0FFO/V8bWrCQs+wLmvVVxk6CRBXALEvNs9OHIatlnlFokfhuDo2ug01ciw==", - "requires": { - "@types/istanbul-lib-coverage": "*", - "@types/istanbul-lib-report": "*" - } - }, - "@types/jest": { - "version": "24.9.1", - "resolved": "https://registry.npmjs.org/@types/jest/-/jest-24.9.1.tgz", - "integrity": "sha512-Fb38HkXSVA4L8fGKEZ6le5bB8r6MRWlOCZbVuWZcmOMSCd2wCYOwN1ibj8daIoV9naq7aaOZjrLCoCMptKU/4Q==", - "requires": { - "jest-diff": "^24.3.0" - } - }, - "@types/json-schema": { - "version": "7.0.5", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.5.tgz", - "integrity": "sha512-7+2BITlgjgDhH0vvwZU/HZJVyk+2XUlvxXe8dFMedNX/aMkaOq++rMAFXc0tM7ij15QaWlbdQASBR9dihi+bDQ==" - }, - "@types/minimatch": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.3.tgz", - "integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==" - }, - "@types/node": { - "version": "12.12.54", - "resolved": "https://registry.npmjs.org/@types/node/-/node-12.12.54.tgz", - "integrity": "sha512-ge4xZ3vSBornVYlDnk7yZ0gK6ChHf/CHB7Gl1I0Jhah8DDnEQqBzgohYG4FX4p81TNirSETOiSyn+y1r9/IR6w==" - }, - "@types/parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==" - }, - "@types/prop-types": { - "version": "15.7.3", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.3.tgz", - "integrity": "sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw==" - }, - "@types/q": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/@types/q/-/q-1.5.4.tgz", - "integrity": "sha512-1HcDas8SEj4z1Wc696tH56G8OlRaH/sqZOynNNB+HF0WOeXPaxTtbYzJY2oEfiUxjSKjhCKr+MvR7dCHcEelug==" - }, - "@types/react": { - "version": "16.9.46", - "resolved": "https://registry.npmjs.org/@types/react/-/react-16.9.46.tgz", - "integrity": "sha512-dbHzO3aAq1lB3jRQuNpuZ/mnu+CdD3H0WVaaBQA8LTT3S33xhVBUj232T8M3tAhSWJs/D/UqORYUlJNl/8VQZg==", - "requires": { - "@types/prop-types": "*", - "csstype": "^3.0.2" - } - }, - "@types/react-dom": { - "version": "16.9.8", - "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-16.9.8.tgz", - "integrity": "sha512-ykkPQ+5nFknnlU6lDd947WbQ6TE3NNzbQAkInC2EKY1qeYdTKp7onFusmYZb+ityzx2YviqT6BXSu+LyWWJwcA==", - "requires": { - "@types/react": "*" - } - }, - "@types/stack-utils": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-1.0.1.tgz", - "integrity": "sha512-l42BggppR6zLmpfU6fq9HEa2oGPEI8yrSPL3GITjfRInppYFahObbIQOQK3UGxEnyQpltZLaPe75046NOZQikw==" - }, - "@types/testing-library__dom": { - "version": "6.14.0", - "resolved": "https://registry.npmjs.org/@types/testing-library__dom/-/testing-library__dom-6.14.0.tgz", - "integrity": "sha512-sMl7OSv0AvMOqn1UJ6j1unPMIHRXen0Ita1ujnMX912rrOcawe4f7wu0Zt9GIQhBhJvH2BaibqFgQ3lP+Pj2hA==", - "requires": { - "pretty-format": "^24.3.0" - } - }, - "@types/testing-library__react": { - "version": "9.1.3", - "resolved": "https://registry.npmjs.org/@types/testing-library__react/-/testing-library__react-9.1.3.tgz", - "integrity": "sha512-iCdNPKU3IsYwRK9JieSYAiX0+aYDXOGAmrC/3/M7AqqSDKnWWVv07X+Zk1uFSL7cMTUYzv4lQRfohucEocn5/w==", - "requires": { - "@types/react-dom": "*", - "@types/testing-library__dom": "*", - "pretty-format": "^25.1.0" - }, - "dependencies": { - "@jest/types": { - "version": "25.5.0", - "resolved": "https://registry.npmjs.org/@jest/types/-/types-25.5.0.tgz", - "integrity": "sha512-OXD0RgQ86Tu3MazKo8bnrkDRaDXXMGUqd+kTtLtK1Zb7CRzQcaSRPPPV37SvYTdevXEBVxe0HXylEjs8ibkmCw==", - "requires": { - "@types/istanbul-lib-coverage": "^2.0.0", - "@types/istanbul-reports": "^1.1.1", - "@types/yargs": "^15.0.0", - "chalk": "^3.0.0" - } - }, - "@types/yargs": { - "version": "15.0.5", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-15.0.5.tgz", - "integrity": "sha512-Dk/IDOPtOgubt/IaevIUbTgV7doaKkoorvOyYM2CMwuDyP89bekI7H4xLIwunNYiK9jhCkmc6pUrJk3cj2AB9w==", - "requires": { - "@types/yargs-parser": "*" - } - }, - "ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" - }, - "ansi-styles": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", - "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", - "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" - }, - "pretty-format": { - "version": "25.5.0", - "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-25.5.0.tgz", - "integrity": "sha512-kbo/kq2LQ/A/is0PQwsEHM7Ca6//bGPPvU6UnsdDRSKTWxT/ru/xb88v4BJf6a69H+uTytOEsTusT9ksd/1iWQ==", - "requires": { - "@jest/types": "^25.5.0", - "ansi-regex": "^5.0.0", - "ansi-styles": "^4.0.0", - "react-is": "^16.12.0" - } - }, - "supports-color": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", - "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", - "requires": { - "has-flag": "^4.0.0" - } - } - } - }, - "@types/yargs": { - "version": "13.0.10", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-13.0.10.tgz", - "integrity": "sha512-MU10TSgzNABgdzKvQVW1nuuT+sgBMWeXNc3XOs5YXV5SDAK+PPja2eUuBNB9iqElu03xyEDqlnGw0jgl4nbqGQ==", - "requires": { - "@types/yargs-parser": "*" - } - }, - "@types/yargs-parser": { - "version": "15.0.0", - "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-15.0.0.tgz", - "integrity": "sha512-FA/BWv8t8ZWJ+gEOnLLd8ygxH/2UFbAvgEonyfN6yWGLKc7zVjbpl2Y4CTjid9h2RfgPP6SEt6uHwEOply00yw==" - }, - "@typescript-eslint/eslint-plugin": { - "version": "2.34.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-2.34.0.tgz", - "integrity": "sha512-4zY3Z88rEE99+CNvTbXSyovv2z9PNOVffTWD2W8QF5s2prBQtwN2zadqERcrHpcR7O/+KMI3fcTAmUUhK/iQcQ==", - "requires": { - "@typescript-eslint/experimental-utils": "2.34.0", - "functional-red-black-tree": "^1.0.1", - "regexpp": "^3.0.0", - "tsutils": "^3.17.1" - } - }, - "@typescript-eslint/experimental-utils": { - "version": "2.34.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-2.34.0.tgz", - "integrity": "sha512-eS6FTkq+wuMJ+sgtuNTtcqavWXqsflWcfBnlYhg/nS4aZ1leewkXGbvBhaapn1q6qf4M71bsR1tez5JTRMuqwA==", - "requires": { - "@types/json-schema": "^7.0.3", - "@typescript-eslint/typescript-estree": "2.34.0", - "eslint-scope": "^5.0.0", - "eslint-utils": "^2.0.0" - } - }, - "@typescript-eslint/parser": { - "version": "2.34.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-2.34.0.tgz", - "integrity": "sha512-03ilO0ucSD0EPTw2X4PntSIRFtDPWjrVq7C3/Z3VQHRC7+13YB55rcJI3Jt+YgeHbjUdJPcPa7b23rXCBokuyA==", - "requires": { - "@types/eslint-visitor-keys": "^1.0.0", - "@typescript-eslint/experimental-utils": "2.34.0", - "@typescript-eslint/typescript-estree": "2.34.0", - "eslint-visitor-keys": "^1.1.0" - } - }, - "@typescript-eslint/typescript-estree": { - "version": "2.34.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-2.34.0.tgz", - "integrity": "sha512-OMAr+nJWKdlVM9LOqCqh3pQQPwxHAN7Du8DR6dmwCrAmxtiXQnhHJ6tBNtf+cggqfo51SG/FCwnKhXCIM7hnVg==", - "requires": { - "debug": "^4.1.1", - "eslint-visitor-keys": "^1.1.0", - "glob": "^7.1.6", - "is-glob": "^4.0.1", - "lodash": "^4.17.15", - "semver": "^7.3.2", - "tsutils": "^3.17.1" - }, - "dependencies": { - "semver": { - "version": "7.3.2", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.2.tgz", - "integrity": "sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==" - } - } - }, - "@webassemblyjs/ast": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.8.5.tgz", - "integrity": "sha512-aJMfngIZ65+t71C3y2nBBg5FFG0Okt9m0XEgWZ7Ywgn1oMAT8cNwx00Uv1cQyHtidq0Xn94R4TAywO+LCQ+ZAQ==", - "requires": { - "@webassemblyjs/helper-module-context": "1.8.5", - "@webassemblyjs/helper-wasm-bytecode": "1.8.5", - "@webassemblyjs/wast-parser": "1.8.5" - } - }, - "@webassemblyjs/floating-point-hex-parser": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.8.5.tgz", - "integrity": "sha512-9p+79WHru1oqBh9ewP9zW95E3XAo+90oth7S5Re3eQnECGq59ly1Ri5tsIipKGpiStHsUYmY3zMLqtk3gTcOtQ==" - }, - "@webassemblyjs/helper-api-error": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.8.5.tgz", - "integrity": "sha512-Za/tnzsvnqdaSPOUXHyKJ2XI7PDX64kWtURyGiJJZKVEdFOsdKUCPTNEVFZq3zJ2R0G5wc2PZ5gvdTRFgm81zA==" - }, - "@webassemblyjs/helper-buffer": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.8.5.tgz", - "integrity": "sha512-Ri2R8nOS0U6G49Q86goFIPNgjyl6+oE1abW1pS84BuhP1Qcr5JqMwRFT3Ah3ADDDYGEgGs1iyb1DGX+kAi/c/Q==" - }, - "@webassemblyjs/helper-code-frame": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.8.5.tgz", - "integrity": "sha512-VQAadSubZIhNpH46IR3yWO4kZZjMxN1opDrzePLdVKAZ+DFjkGD/rf4v1jap744uPVU6yjL/smZbRIIJTOUnKQ==", - "requires": { - "@webassemblyjs/wast-printer": "1.8.5" - } - }, - "@webassemblyjs/helper-fsm": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-fsm/-/helper-fsm-1.8.5.tgz", - "integrity": "sha512-kRuX/saORcg8se/ft6Q2UbRpZwP4y7YrWsLXPbbmtepKr22i8Z4O3V5QE9DbZK908dh5Xya4Un57SDIKwB9eow==" - }, - "@webassemblyjs/helper-module-context": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-module-context/-/helper-module-context-1.8.5.tgz", - "integrity": "sha512-/O1B236mN7UNEU4t9X7Pj38i4VoU8CcMHyy3l2cV/kIF4U5KoHXDVqcDuOs1ltkac90IM4vZdHc52t1x8Yfs3g==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "mamacro": "^0.0.3" - } - }, - "@webassemblyjs/helper-wasm-bytecode": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.8.5.tgz", - "integrity": "sha512-Cu4YMYG3Ddl72CbmpjU/wbP6SACcOPVbHN1dI4VJNJVgFwaKf1ppeFJrwydOG3NDHxVGuCfPlLZNyEdIYlQ6QQ==" - }, - "@webassemblyjs/helper-wasm-section": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.8.5.tgz", - "integrity": "sha512-VV083zwR+VTrIWWtgIUpqfvVdK4ff38loRmrdDBgBT8ADXYsEZ5mPQ4Nde90N3UYatHdYoDIFb7oHzMncI02tA==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "@webassemblyjs/helper-buffer": "1.8.5", - "@webassemblyjs/helper-wasm-bytecode": "1.8.5", - "@webassemblyjs/wasm-gen": "1.8.5" - } - }, - "@webassemblyjs/ieee754": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.8.5.tgz", - "integrity": "sha512-aaCvQYrvKbY/n6wKHb/ylAJr27GglahUO89CcGXMItrOBqRarUMxWLJgxm9PJNuKULwN5n1csT9bYoMeZOGF3g==", - "requires": { - "@xtuc/ieee754": "^1.2.0" - } - }, - "@webassemblyjs/leb128": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.8.5.tgz", - "integrity": "sha512-plYUuUwleLIziknvlP8VpTgO4kqNaH57Y3JnNa6DLpu/sGcP6hbVdfdX5aHAV716pQBKrfuU26BJK29qY37J7A==", - "requires": { - "@xtuc/long": "4.2.2" - } - }, - "@webassemblyjs/utf8": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.8.5.tgz", - "integrity": "sha512-U7zgftmQriw37tfD934UNInokz6yTmn29inT2cAetAsaU9YeVCveWEwhKL1Mg4yS7q//NGdzy79nlXh3bT8Kjw==" - }, - "@webassemblyjs/wasm-edit": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.8.5.tgz", - "integrity": "sha512-A41EMy8MWw5yvqj7MQzkDjU29K7UJq1VrX2vWLzfpRHt3ISftOXqrtojn7nlPsZ9Ijhp5NwuODuycSvfAO/26Q==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "@webassemblyjs/helper-buffer": "1.8.5", - "@webassemblyjs/helper-wasm-bytecode": "1.8.5", - "@webassemblyjs/helper-wasm-section": "1.8.5", - "@webassemblyjs/wasm-gen": "1.8.5", - "@webassemblyjs/wasm-opt": "1.8.5", - "@webassemblyjs/wasm-parser": "1.8.5", - "@webassemblyjs/wast-printer": "1.8.5" - } - }, - "@webassemblyjs/wasm-gen": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.8.5.tgz", - "integrity": "sha512-BCZBT0LURC0CXDzj5FXSc2FPTsxwp3nWcqXQdOZE4U7h7i8FqtFK5Egia6f9raQLpEKT1VL7zr4r3+QX6zArWg==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "@webassemblyjs/helper-wasm-bytecode": "1.8.5", - "@webassemblyjs/ieee754": "1.8.5", - "@webassemblyjs/leb128": "1.8.5", - "@webassemblyjs/utf8": "1.8.5" - } - }, - "@webassemblyjs/wasm-opt": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.8.5.tgz", - "integrity": "sha512-HKo2mO/Uh9A6ojzu7cjslGaHaUU14LdLbGEKqTR7PBKwT6LdPtLLh9fPY33rmr5wcOMrsWDbbdCHq4hQUdd37Q==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "@webassemblyjs/helper-buffer": "1.8.5", - "@webassemblyjs/wasm-gen": "1.8.5", - "@webassemblyjs/wasm-parser": "1.8.5" - } - }, - "@webassemblyjs/wasm-parser": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.8.5.tgz", - "integrity": "sha512-pi0SYE9T6tfcMkthwcgCpL0cM9nRYr6/6fjgDtL6q/ZqKHdMWvxitRi5JcZ7RI4SNJJYnYNaWy5UUrHQy998lw==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "@webassemblyjs/helper-api-error": "1.8.5", - "@webassemblyjs/helper-wasm-bytecode": "1.8.5", - "@webassemblyjs/ieee754": "1.8.5", - "@webassemblyjs/leb128": "1.8.5", - "@webassemblyjs/utf8": "1.8.5" - } - }, - "@webassemblyjs/wast-parser": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-parser/-/wast-parser-1.8.5.tgz", - "integrity": "sha512-daXC1FyKWHF1i11obK086QRlsMsY4+tIOKgBqI1lxAnkp9xe9YMcgOxm9kLe+ttjs5aWV2KKE1TWJCN57/Btsg==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "@webassemblyjs/floating-point-hex-parser": "1.8.5", - "@webassemblyjs/helper-api-error": "1.8.5", - "@webassemblyjs/helper-code-frame": "1.8.5", - "@webassemblyjs/helper-fsm": "1.8.5", - "@xtuc/long": "4.2.2" - } - }, - "@webassemblyjs/wast-printer": { - "version": "1.8.5", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.8.5.tgz", - "integrity": "sha512-w0U0pD4EhlnvRyeJzBqaVSJAo9w/ce7/WPogeXLzGkO6hzhr4GnQIZ4W4uUt5b9ooAaXPtnXlj0gzsXEOUNYMg==", - "requires": { - "@webassemblyjs/ast": "1.8.5", - "@webassemblyjs/wast-parser": "1.8.5", - "@xtuc/long": "4.2.2" - } - }, - "@xtuc/ieee754": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", - "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==" - }, - "@xtuc/long": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", - "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==" - }, - "abab": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/abab/-/abab-2.0.4.tgz", - "integrity": "sha512-Eu9ELJWCz/c1e9gTiCY+FceWxcqzjYEbqMgtndnuSqZSUCOL73TWNK2mHfIj4Cw2E/ongOp+JISVNCmovt2KYQ==" - }, - "accepts": { - "version": "1.3.7", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", - "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", - "requires": { - "mime-types": "~2.1.24", - "negotiator": "0.6.2" - } - }, - "acorn": { - "version": "7.4.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.4.0.tgz", - "integrity": "sha512-+G7P8jJmCHr+S+cLfQxygbWhXy+8YTVGzAkpEbcLo2mLoL7tij/VG41QSHACSf5QgYRhMZYHuNc6drJaO0Da+w==" - }, - "acorn-globals": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-4.3.4.tgz", - "integrity": "sha512-clfQEh21R+D0leSbUdWf3OcfqyaCSAQ8Ryq00bofSekfr9W8u1jyYZo6ir0xu9Gtcf7BjcHJpnbZH7JOCpP60A==", - "requires": { - "acorn": "^6.0.1", - "acorn-walk": "^6.0.1" - }, - "dependencies": { - "acorn": { - "version": "6.4.1", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-6.4.1.tgz", - "integrity": "sha512-ZVA9k326Nwrj3Cj9jlh3wGFutC2ZornPNARZwsNYqQYgN0EsV2d53w5RN/co65Ohn4sUAUtb1rSUAOD6XN9idA==" - } - } - }, - "acorn-jsx": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.2.0.tgz", - "integrity": "sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==" - }, - "acorn-walk": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-6.2.0.tgz", - "integrity": "sha512-7evsyfH1cLOCdAzZAd43Cic04yKydNx0cF+7tiA19p1XnLLPU4dpCQOqpjqwokFe//vS0QqfqqjCS2JkiIs0cA==" - }, - "address": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/address/-/address-1.1.2.tgz", - "integrity": "sha512-aT6camzM4xEA54YVJYSqxz1kv4IHnQZRtThJJHhUMRExaU5spC7jX5ugSwTaTgJliIgs4VhZOk7htClvQ/LmRA==" - }, - "adjust-sourcemap-loader": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/adjust-sourcemap-loader/-/adjust-sourcemap-loader-2.0.0.tgz", - "integrity": "sha512-4hFsTsn58+YjrU9qKzML2JSSDqKvN8mUGQ0nNIrfPi8hmIONT4L3uUaT6MKdMsZ9AjsU6D2xDkZxCkbQPxChrA==", - "requires": { - "assert": "1.4.1", - "camelcase": "5.0.0", - "loader-utils": "1.2.3", - "object-path": "0.11.4", - "regex-parser": "2.2.10" - }, - "dependencies": { - "camelcase": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.0.0.tgz", - "integrity": "sha512-faqwZqnWxbxn+F1d399ygeamQNy3lPp/H9H6rNrqYh4FSVCtcY+3cub1MxA8o9mDd55mM8Aghuu/kuyYA6VTsA==" + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==" }, - "emojis-list": { + "@types/mocha": { + "version": "8.0.3", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.3.tgz", + "integrity": "sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==" + }, + "@types/node": { + "version": "14.11.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.11.2.tgz", + "integrity": "sha512-jiE3QIxJ8JLNcb1Ps6rDbysDhN4xa8DJJvuC9prr6w+1tIh+QAbYyNF3tyiZNLDBIuBCf4KEcV2UvQm/V60xfA==" + }, + "ansi-colors": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", + "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==" + }, + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" + }, + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", + "requires": { + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" + } + }, + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "array.prototype.map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", + "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.4" + } + }, + "assertion-error": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", + "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" + }, + "binary-extensions": { "version": "2.1.0", - "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-2.1.0.tgz", - "integrity": "sha1-TapNnbAPmBmIDHn6RXrlsJof04k=" + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==" }, - "json5": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", - "integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "requires": { - "minimist": "^1.2.0" + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" } }, - "loader-utils": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.2.3.tgz", - "integrity": "sha512-fkpz8ejdnEMG3s37wGL07iSBDg99O9D5yflE9RGNH3hRdx9SOwYfnGYdZOUIZitN8E+E2vkq3MUMYMvPYl5ZZA==", + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", "requires": { - "big.js": "^5.2.2", - "emojis-list": "^2.0.0", - "json5": "^1.0.1" + "fill-range": "^7.0.1" } - } - } - }, - "aggregate-error": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.0.1.tgz", - "integrity": "sha512-quoaXsZ9/BLNae5yiNoUz+Nhkwz83GhWwtYFglcjEQB2NDHCIpApbqXxIFnm4Pq/Nvhrsq5sYJFyohrrxnTGAA==", - "requires": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - } - }, - "agile-framework": { - "version": "file:../..", - "requires": { - "@babel/cli": "^7.10.5", - "@babel/core": "^7.11.1", - "@babel/plugin-transform-runtime": "^7.11.0", - "@babel/preset-env": "^7.11.0", - "@types/chai": "^4.2.12", - "@types/mocha": "^8.0.2", - "babel-eslint": "^10.0.1", - "chai": "^4.2.0", - "eslint-config-prettier": "^6.11.0", - "mocha": "^8.1.1", - "prettier": "2.0.5", - "ts-node": "^8.10.2", - "tsc-watch": "^4.1.0", - "tslib": "^2.0.0", - "typescript": "^3.9.7" - }, - "dependencies": { - "@babel/cli": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/cli/-/cli-7.10.5.tgz", - "integrity": "sha512-j9H9qSf3kLdM0Ao3aGPbGZ73mEA9XazuupcS6cDGWuiyAcANoguhP0r2Lx32H5JGw4sSSoHG3x/mxVnHgvOoyA==", - "requires": { - "chokidar": "^2.1.8", - "commander": "^4.0.1", - "convert-source-map": "^1.1.0", - "fs-readdir-recursive": "^1.1.0", - "glob": "^7.0.0", - "lodash": "^4.17.19", - "make-dir": "^2.1.0", - "slash": "^2.0.0", - "source-map": "^0.5.0" + }, + "browser-stdout": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", + "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==" + }, + "buffer-from": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", + "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==" + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" + }, + "chai": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", + "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", + "requires": { + "assertion-error": "^1.1.0", + "check-error": "^1.0.2", + "deep-eql": "^3.0.1", + "get-func-name": "^2.0.0", + "pathval": "^1.1.0", + "type-detect": "^4.0.5" } }, - "@babel/code-frame": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", - "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", + "chalk": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", + "requires": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + } + }, + "check-error": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", + "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=" + }, + "chokidar": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", + "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.4.0" + } + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" + }, + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", "requires": { - "@babel/highlight": "^7.10.4" + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" } }, - "@babel/compat-data": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.11.0.tgz", - "integrity": "sha512-TPSvJfv73ng0pfnEOh17bYMPQbI95+nGWc71Ss4vZdRBHTDqmM9Z8ZV4rYz8Ks7sfzc95n30k6ODIq5UGnXcYQ==", + "debug": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", "requires": { - "browserslist": "^4.12.0", - "invariant": "^2.2.4", - "semver": "^5.5.0" + "ms": "^2.1.1" } }, - "@babel/core": { - "version": "7.11.1", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.11.1.tgz", - "integrity": "sha512-XqF7F6FWQdKGGWAzGELL+aCO1p+lRY5Tj5/tbT3St1G8NaH70jhhDIKknIZaDans0OQBG5wRAldROLHSt44BgQ==", - "requires": { - "@babel/code-frame": "^7.10.4", - "@babel/generator": "^7.11.0", - "@babel/helper-module-transforms": "^7.11.0", - "@babel/helpers": "^7.10.4", - "@babel/parser": "^7.11.1", - "@babel/template": "^7.10.4", - "@babel/traverse": "^7.11.0", - "@babel/types": "^7.11.0", - "convert-source-map": "^1.7.0", - "debug": "^4.1.0", - "gensync": "^1.0.0-beta.1", - "json5": "^2.1.2", - "lodash": "^4.17.19", - "resolve": "^1.3.2", - "semver": "^5.4.1", - "source-map": "^0.5.0" - }, - "dependencies": { - "debug": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", - "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", - "requires": { - "ms": "^2.1.1" - } - }, - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" - } + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" + }, + "deep-eql": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", + "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", + "requires": { + "type-detect": "^4.0.0" } }, - "@babel/generator": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.11.0.tgz", - "integrity": "sha512-fEm3Uzw7Mc9Xi//qU20cBKatTfs2aOtKqmvy/Vm7RkJEGFQ4xc9myCfbXxqK//ZS8MR/ciOHw6meGASJuKmDfQ==", + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", "requires": { - "@babel/types": "^7.11.0", - "jsesc": "^2.5.1", - "source-map": "^0.5.0" + "object-keys": "^1.0.12" } }, - "@babel/helper-annotate-as-pure": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.10.4.tgz", - "integrity": "sha512-XQlqKQP4vXFB7BN8fEEerrmYvHp3fK/rBkRFz9jaJbzK0B1DSfej9Kc7ZzE8Z/OnId1jpJdNAZ3BFQjWG68rcA==", + "diff": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" + }, + "es-abstract": { + "version": "1.17.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", + "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", "requires": { - "@babel/types": "^7.10.4" + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.2.0", + "is-regex": "^1.1.0", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimend": "^1.0.1", + "string.prototype.trimstart": "^1.0.1" } }, - "@babel/helper-builder-binary-assignment-operator-visitor": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.10.4.tgz", - "integrity": "sha512-L0zGlFrGWZK4PbT8AszSfLTM5sDU1+Az/En9VrdT8/LmEiJt4zXt+Jve9DCAnQcbqDhCI+29y/L93mrDzddCcg==", + "es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==" + }, + "es-get-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", + "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", "requires": { - "@babel/helper-explode-assignable-expression": "^7.10.4", - "@babel/types": "^7.10.4" + "es-abstract": "^1.17.4", + "has-symbols": "^1.0.1", + "is-arguments": "^1.0.4", + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-string": "^1.0.5", + "isarray": "^2.0.5" } }, - "@babel/helper-compilation-targets": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.10.4.tgz", - "integrity": "sha512-a3rYhlsGV0UHNDvrtOXBg8/OpfV0OKTkxKPzIplS1zpx7CygDcWWxckxZeDd3gzPzC4kUT0A4nVFDK0wGMh4MQ==", + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", "requires": { - "@babel/compat-data": "^7.10.4", - "browserslist": "^4.12.0", - "invariant": "^2.2.4", - "levenary": "^1.1.1", - "semver": "^5.5.0" + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" } }, - "@babel/helper-create-class-features-plugin": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.10.5.tgz", - "integrity": "sha512-0nkdeijB7VlZoLT3r/mY3bUkw3T8WG/hNw+FATs/6+pG2039IJWjTYL0VTISqsNHMUTEnwbVnc89WIJX9Qed0A==", + "escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" + }, + "eslint-config-prettier": { + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.12.0.tgz", + "integrity": "sha512-9jWPlFlgNwRUYVoujvWTQ1aMO8o6648r+K7qU7K5Jmkbyqav1fuEZC0COYpGBxyiAJb65Ra9hrmFx19xRGwXWw==", "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-member-expression-to-functions": "^7.10.5", - "@babel/helper-optimise-call-expression": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.10.4" + "get-stdin": "^6.0.0" } }, - "@babel/helper-create-regexp-features-plugin": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.10.4.tgz", - "integrity": "sha512-2/hu58IEPKeoLF45DBwx3XFqsbCXmkdAay4spVr2x0jYgRxrSNp+ePwvSsy9g6YSaNDcKIQVPXk1Ov8S2edk2g==", + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" + }, + "event-stream": { + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", + "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-regex": "^7.10.4", - "regexpu-core": "^4.7.0" + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", + "pause-stream": "0.0.11", + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" } }, - "@babel/helper-define-map": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/helper-define-map/-/helper-define-map-7.10.5.tgz", - "integrity": "sha512-fMw4kgFB720aQFXSVaXr79pjjcW5puTCM16+rECJ/plGS+zByelE8l9nCpV1GibxTnFVmUuYG9U8wYfQHdzOEQ==", + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/types": "^7.10.5", - "lodash": "^4.17.19" + "to-regex-range": "^5.0.1" } }, - "@babel/helper-explode-assignable-expression": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.10.4.tgz", - "integrity": "sha512-4K71RyRQNPRrR85sr5QY4X3VwG4wtVoXZB9+L3r1Gp38DhELyHCtovqydRi7c1Ovb17eRGiQ/FD5s8JdU0Uy5A==", + "find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", "requires": { - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" } }, - "@babel/helper-function-name": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.10.4.tgz", - "integrity": "sha512-YdaSyz1n8gY44EmN7x44zBn9zQ1Ry2Y+3GTA+3vH6Mizke1Vw0aWDM66FOYEPw8//qKkmqOckrGgTYa+6sceqQ==", + "flat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", + "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", "requires": { - "@babel/helper-get-function-arity": "^7.10.4", - "@babel/template": "^7.10.4", - "@babel/types": "^7.10.4" + "is-buffer": "~2.0.3" } }, - "@babel/helper-get-function-arity": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.10.4.tgz", - "integrity": "sha512-EkN3YDB+SRDgiIUnNgcmiD361ti+AVbL3f3Henf6dqqUyr5dMsorno0lJWJuLhDhkI5sYEpgj6y9kB8AOU1I2A==", + "from": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", + "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=" + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" + }, + "get-func-name": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", + "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=" + }, + "get-stdin": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", + "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==" + }, + "glob": { + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", "requires": { - "@babel/types": "^7.10.4" + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" } }, - "@babel/helper-hoist-variables": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.10.4.tgz", - "integrity": "sha512-wljroF5PgCk2juF69kanHVs6vrLwIPNp6DLD+Lrl3hoQ3PpPPikaDRNFA+0t81NOoMt2DL6WW/mdU8k4k6ZzuA==", + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", "requires": { - "@babel/types": "^7.10.4" + "is-glob": "^4.0.1" } }, - "@babel/helper-member-expression-to-functions": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.11.0.tgz", - "integrity": "sha512-JbFlKHFntRV5qKw3YC0CvQnDZ4XMwgzzBbld7Ly4Mj4cbFy3KywcR8NtNctRToMWJOVvLINJv525Gd6wwVEx/Q==", + "growl": { + "version": "1.10.5", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", + "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==" + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", "requires": { - "@babel/types": "^7.11.0" + "function-bind": "^1.1.1" } }, - "@babel/helper-module-imports": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.10.4.tgz", - "integrity": "sha512-nEQJHqYavI217oD9+s5MUBzk6x1IlvoS9WTPfgG43CbMEeStE0v+r+TucWdx8KFGowPGvyOkDT9+7DHedIDnVw==", + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" + }, + "has-symbols": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", + "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==" + }, + "he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "requires": { - "@babel/types": "^7.10.4" + "once": "^1.3.0", + "wrappy": "1" } }, - "@babel/helper-module-transforms": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.11.0.tgz", - "integrity": "sha512-02EVu8COMuTRO1TAzdMtpBPbe6aQ1w/8fePD2YgQmxZU4gpNWaL9gK3Jp7dxlkUlUCJOTaSeA+Hrm1BRQwqIhg==", + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "is-arguments": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==" + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", "requires": { - "@babel/helper-module-imports": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4", - "@babel/helper-simple-access": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.11.0", - "@babel/template": "^7.10.4", - "@babel/types": "^7.11.0", - "lodash": "^4.17.19" + "binary-extensions": "^2.0.0" } }, - "@babel/helper-optimise-call-expression": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.10.4.tgz", - "integrity": "sha512-n3UGKY4VXwXThEiKrgRAoVPBMqeoPgHVqiHZOanAJCG9nQUL2pLRQirUzl0ioKclHGpGqRgIOkgcIJaIWLpygg==", + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==" + }, + "is-callable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz", + "integrity": "sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA==" + }, + "is-date-object": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", + "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==" + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", "requires": { - "@babel/types": "^7.10.4" + "is-extglob": "^2.1.1" } }, - "@babel/helper-plugin-utils": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", - "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==" + "is-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", + "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==" + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" + }, + "is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=" }, - "@babel/helper-regex": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.10.5.tgz", - "integrity": "sha512-68kdUAzDrljqBrio7DYAEgCoJHxppJOERHOgOrDN7WjOzP0ZQ1LsSDRXcemzVZaLvjaJsJEESb6qt+znNuENDg==", + "is-regex": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", + "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", "requires": { - "lodash": "^4.17.19" + "has-symbols": "^1.0.1" } }, - "@babel/helper-remap-async-to-generator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.10.4.tgz", - "integrity": "sha512-86Lsr6NNw3qTNl+TBcF1oRZMaVzJtbWTyTko+CQL/tvNvcGYEFKbLXDPxtW0HKk3McNOk4KzY55itGWCAGK5tg==", - "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-wrap-function": "^7.10.4", - "@babel/template": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" - } + "is-set": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", + "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==" }, - "@babel/helper-replace-supers": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.10.4.tgz", - "integrity": "sha512-sPxZfFXocEymYTdVK1UNmFPBN+Hv5mJkLPsYWwGBxZAxaWfFu+xqp7b6qWD0yjNuNL2VKc6L5M18tOXUP7NU0A==", - "requires": { - "@babel/helper-member-expression-to-functions": "^7.10.4", - "@babel/helper-optimise-call-expression": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" - } + "is-string": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", + "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==" }, - "@babel/helper-simple-access": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.10.4.tgz", - "integrity": "sha512-0fMy72ej/VEvF8ULmX6yb5MtHG4uH4Dbd6I/aHDb/JVg0bbivwt9Wg+h3uMvX+QSFtwr5MeItvazbrc4jtRAXw==", + "is-symbol": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", + "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", "requires": { - "@babel/template": "^7.10.4", - "@babel/types": "^7.10.4" + "has-symbols": "^1.0.1" } }, - "@babel/helper-skip-transparent-expression-wrappers": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.11.0.tgz", - "integrity": "sha512-0XIdiQln4Elglgjbwo9wuJpL/K7AGCY26kmEt0+pRP0TAj4jjyNq1MjoRvikrTVqKcx4Gysxt4cXvVFXP/JO2Q==", - "requires": { - "@babel/types": "^7.11.0" - } + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" }, - "@babel/helper-split-export-declaration": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.11.0.tgz", - "integrity": "sha512-74Vejvp6mHkGE+m+k5vHY93FX2cAtrw1zXrZXRlG4l410Nm9PxfEiVTn1PjDPV5SnmieiueY4AFg2xqhNFuuZg==", - "requires": { - "@babel/types": "^7.11.0" - } + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" }, - "@babel/helper-validator-identifier": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", - "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==" + "iterate-iterator": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", + "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==" }, - "@babel/helper-wrap-function": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.10.4.tgz", - "integrity": "sha512-6py45WvEF0MhiLrdxtRjKjufwLL1/ob2qDJgg5JgNdojBAZSAKnAjkyOCNug6n+OBl4VW76XjvgSFTdaMcW0Ug==", + "iterate-value": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", + "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/template": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" + "es-get-iterator": "^1.0.2", + "iterate-iterator": "^1.0.1" } }, - "@babel/helpers": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.10.4.tgz", - "integrity": "sha512-L2gX/XeUONeEbI78dXSrJzGdz4GQ+ZTA/aazfUsFaWjSe95kiCuOZ5HsXvkiw3iwF+mFHSRUfJU8t6YavocdXA==", + "js-yaml": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", + "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", "requires": { - "@babel/template": "^7.10.4", - "@babel/traverse": "^7.10.4", - "@babel/types": "^7.10.4" + "argparse": "^1.0.7", + "esprima": "^4.0.0" } }, - "@babel/highlight": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", - "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", + "locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", "requires": { - "@babel/helper-validator-identifier": "^7.10.4", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" + "p-locate": "^5.0.0" } }, - "@babel/parser": { - "version": "7.11.3", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.11.3.tgz", - "integrity": "sha512-REo8xv7+sDxkKvoxEywIdsNFiZLybwdI7hcT5uEPyQrSMB4YQ973BfC9OOrD/81MaIjh6UxdulIQXkjmiH3PcA==" - }, - "@babel/plugin-proposal-async-generator-functions": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.10.5.tgz", - "integrity": "sha512-cNMCVezQbrRGvXJwm9fu/1sJj9bHdGAgKodZdLqOQIpfoH3raqmRPBM17+lh7CzhiKRRBrGtZL9WcjxSoGYUSg==", + "log-symbols": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.0.0.tgz", + "integrity": "sha512-FN8JBzLx6CzeMrB0tg6pqlGU1wCrXW+ZXGH481kfsBqer0hToTIiHdjH4Mq8xJUbvATujKCvaREGWpGUionraA==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-remap-async-to-generator": "^7.10.4", - "@babel/plugin-syntax-async-generators": "^7.8.0" + "chalk": "^4.0.0" } }, - "@babel/plugin-proposal-class-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.10.4.tgz", - "integrity": "sha512-vhwkEROxzcHGNu2mzUC0OFFNXdZ4M23ib8aRRcJSsW8BZK9pQMD7QB7csl97NBbgGZO7ZyHUyKDnxzOaP4IrCg==", - "requires": { - "@babel/helper-create-class-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } + "make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" }, - "@babel/plugin-proposal-dynamic-import": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.10.4.tgz", - "integrity": "sha512-up6oID1LeidOOASNXgv/CFbgBqTuKJ0cJjz6An5tWD+NVBNlp3VNSBxv2ZdU7SYl3NxJC7agAQDApZusV6uFwQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-dynamic-import": "^7.8.0" - } + "map-stream": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=" }, - "@babel/plugin-proposal-export-namespace-from": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.10.4.tgz", - "integrity": "sha512-aNdf0LY6/3WXkhh0Fdb6Zk9j1NMD8ovj3F6r0+3j837Pn1S1PdNtcwJ5EG9WkVPNHPxyJDaxMaAOVq4eki0qbg==", + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-export-namespace-from": "^7.8.3" + "brace-expansion": "^1.1.7" } }, - "@babel/plugin-proposal-json-strings": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.10.4.tgz", - "integrity": "sha512-fCL7QF0Jo83uy1K0P2YXrfX11tj3lkpN7l4dMv9Y9VkowkhkQDwFHFd8IiwyK5MZjE8UpbgokkgtcReH88Abaw==", + "mocha": { + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.3.tgz", + "integrity": "sha512-ZbaYib4hT4PpF4bdSO2DohooKXIn4lDeiYqB+vTmCdr6l2woW0b6H3pf5x4sM5nwQMru9RvjjHYWVGltR50ZBw==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-json-strings": "^7.8.0" + "ansi-colors": "4.1.1", + "browser-stdout": "1.3.1", + "chokidar": "3.4.2", + "debug": "4.1.1", + "diff": "4.0.2", + "escape-string-regexp": "4.0.0", + "find-up": "5.0.0", + "glob": "7.1.6", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.14.0", + "log-symbols": "4.0.0", + "minimatch": "3.0.4", + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "4.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.1" } }, - "@babel/plugin-proposal-logical-assignment-operators": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.11.0.tgz", - "integrity": "sha512-/f8p4z+Auz0Uaf+i8Ekf1iM7wUNLcViFUGiPxKeXvxTSl63B875YPiVdUDdem7hREcI0E0kSpEhS8tF5RphK7Q==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4" - } + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" }, - "@babel/plugin-proposal-nullish-coalescing-operator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.10.4.tgz", - "integrity": "sha512-wq5n1M3ZUlHl9sqT2ok1T2/MTt6AXE0e1Lz4WzWBr95LsAZ5qDXe4KnFuauYyEyLiohvXFMdbsOTMyLZs91Zlw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0" - } + "node-cleanup": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", + "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=" }, - "@babel/plugin-proposal-numeric-separator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.10.4.tgz", - "integrity": "sha512-73/G7QoRoeNkLZFxsoCCvlg4ezE4eM+57PnOqgaPOozd5myfj7p0muD1mRVJvbUWbOzD+q3No2bWbaKy+DJ8DA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-numeric-separator": "^7.10.4" - } + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" }, - "@babel/plugin-proposal-object-rest-spread": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.11.0.tgz", - "integrity": "sha512-wzch41N4yztwoRw0ak+37wxwJM2oiIiy6huGCoqkvSTA9acYWcPfn9Y4aJqmFFJ70KTJUu29f3DQ43uJ9HXzEA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-object-rest-spread": "^7.8.0", - "@babel/plugin-transform-parameters": "^7.10.4" - } + "object-inspect": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", + "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==" }, - "@babel/plugin-proposal-optional-catch-binding": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.10.4.tgz", - "integrity": "sha512-LflT6nPh+GK2MnFiKDyLiqSqVHkQnVf7hdoAvyTnnKj9xB3docGRsdPuxp6qqqW19ifK3xgc9U5/FwrSaCNX5g==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-syntax-optional-catch-binding": "^7.8.0" - } + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" }, - "@babel/plugin-proposal-optional-chaining": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.11.0.tgz", - "integrity": "sha512-v9fZIu3Y8562RRwhm1BbMRxtqZNFmFA2EG+pT2diuU8PT3H6T/KXoZ54KgYisfOFZHV6PfvAiBIZ9Rcz+/JCxA==", + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-skip-transparent-expression-wrappers": "^7.11.0", - "@babel/plugin-syntax-optional-chaining": "^7.8.0" + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" } }, - "@babel/plugin-proposal-private-methods": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.10.4.tgz", - "integrity": "sha512-wh5GJleuI8k3emgTg5KkJK6kHNsGEr0uBTDBuQUBJwckk9xs1ez79ioheEVVxMLyPscB0LfkbVHslQqIzWV6Bw==", + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "requires": { - "@babel/helper-create-class-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" + "wrappy": "1" } }, - "@babel/plugin-proposal-unicode-property-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.10.4.tgz", - "integrity": "sha512-H+3fOgPnEXFL9zGYtKQe4IDOPKYlZdF1kqFDQRRb8PK4B8af1vAGK04tF5iQAAsui+mHNBQSAtd2/ndEDe9wuA==", + "p-limit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", + "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" + "p-try": "^2.0.0" } }, - "@babel/plugin-syntax-async-generators": { - "version": "7.8.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", - "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", "requires": { - "@babel/helper-plugin-utils": "^7.8.0" + "p-limit": "^3.0.2" } }, - "@babel/plugin-syntax-class-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.10.4.tgz", - "integrity": "sha512-GCSBF7iUle6rNugfURwNmCGG3Z/2+opxAMLs1nND4bhEG5PuxTIggDBoeYYSujAlLtsupzOHYJQgPS3pivwXIA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==" }, - "@babel/plugin-syntax-dynamic-import": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", - "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==" }, - "@babel/plugin-syntax-export-namespace-from": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz", - "integrity": "sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.3" - } + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" }, - "@babel/plugin-syntax-json-strings": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", - "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } + "path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==" }, - "@babel/plugin-syntax-logical-assignment-operators": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", - "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "pathval": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", + "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=" }, - "@babel/plugin-syntax-nullish-coalescing-operator": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", - "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "pause-stream": { + "version": "0.0.11", + "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", + "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", "requires": { - "@babel/helper-plugin-utils": "^7.8.0" + "through": "~2.3" } }, - "@babel/plugin-syntax-numeric-separator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", - "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==" }, - "@babel/plugin-syntax-object-rest-spread": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", - "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", - "requires": { - "@babel/helper-plugin-utils": "^7.8.0" - } + "prettier": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", + "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==" }, - "@babel/plugin-syntax-optional-catch-binding": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", - "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", "requires": { - "@babel/helper-plugin-utils": "^7.8.0" + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" } }, - "@babel/plugin-syntax-optional-chaining": { - "version": "7.8.3", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", - "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "ps-tree": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", + "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", "requires": { - "@babel/helper-plugin-utils": "^7.8.0" + "event-stream": "=3.3.4" } }, - "@babel/plugin-syntax-top-level-await": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.10.4.tgz", - "integrity": "sha512-ni1brg4lXEmWyafKr0ccFWkJG0CeMt4WV1oyeBW6EFObF4oOHclbkj5cARxAPQyAQ2UTuplJyK4nfkXIMMFvsQ==", + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "safe-buffer": "^5.1.0" } }, - "@babel/plugin-transform-arrow-functions": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.10.4.tgz", - "integrity": "sha512-9J/oD1jV0ZCBcgnoFWFq1vJd4msoKb/TCpGNFyyLt0zABdcvgK3aYikZ8HjzB14c26bc7E3Q1yugpwGy2aTPNA==", + "readdirp": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", + "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "picomatch": "^2.2.1" } }, - "@babel/plugin-transform-async-to-generator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.10.4.tgz", - "integrity": "sha512-F6nREOan7J5UXTLsDsZG3DXmZSVofr2tGNwfdrVwkDWHfQckbQXnXSPfD7iO+c/2HGqycwyLST3DnZ16n+cBJQ==", - "requires": { - "@babel/helper-module-imports": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-remap-async-to-generator": "^7.10.4" - } + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" }, - "@babel/plugin-transform-block-scoped-functions": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.10.4.tgz", - "integrity": "sha512-WzXDarQXYYfjaV1szJvN3AD7rZgZzC1JtjJZ8dMHUyiK8mxPRahynp14zzNjU3VkPqPsO38CzxiWO1c9ARZ8JA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" }, - "@babel/plugin-transform-block-scoping": { - "version": "7.11.1", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.11.1.tgz", - "integrity": "sha512-00dYeDE0EVEHuuM+26+0w/SCL0BH2Qy7LwHuI4Hi4MH5gkC8/AqMN5uWFJIsoXZrAphiMm1iXzBw6L2T+eA0ew==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" }, - "@babel/plugin-transform-classes": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.10.4.tgz", - "integrity": "sha512-2oZ9qLjt161dn1ZE0Ms66xBncQH4In8Sqw1YWgBUZuGVJJS5c0OFZXL6dP2MRHrkU/eKhWg8CzFJhRQl50rQxA==", + "serialize-javascript": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-define-map": "^7.10.4", - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-optimise-call-expression": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.10.4", - "globals": "^11.1.0" + "randombytes": "^2.1.0" } }, - "@babel/plugin-transform-computed-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.10.4.tgz", - "integrity": "sha512-JFwVDXcP/hM/TbyzGq3l/XWGut7p46Z3QvqFMXTfk6/09m7xZHJUN9xHfsv7vqqD4YnfI5ueYdSJtXqqBLyjBw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" }, - "@babel/plugin-transform-destructuring": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.10.4.tgz", - "integrity": "sha512-+WmfvyfsyF603iPa6825mq6Qrb7uLjTOsa3XOFzlYcYDHSS4QmpOWOL0NNBY5qMbvrcf3tq0Cw+v4lxswOBpgA==", + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "shebang-regex": "^3.0.0" } }, - "@babel/plugin-transform-dotall-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.10.4.tgz", - "integrity": "sha512-ZEAVvUTCMlMFAbASYSVQoxIbHm2OkG2MseW6bV2JjIygOjdVv8tuxrCTzj1+Rynh7ODb8GivUy7dzEXzEhuPaA==", - "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" }, - "@babel/plugin-transform-duplicate-keys": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.10.4.tgz", - "integrity": "sha512-GL0/fJnmgMclHiBTTWXNlYjYsA7rDrtsazHG6mglaGSTh0KsrW04qml+Bbz9FL0LcJIRwBWL5ZqlNHKTkU3xAA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" }, - "@babel/plugin-transform-exponentiation-operator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.10.4.tgz", - "integrity": "sha512-S5HgLVgkBcRdyQAHbKj+7KyuWx8C6t5oETmUuwz1pt3WTWJhsUV0WIIXuVvfXMxl/QQyHKlSCNNtaIamG8fysw==", + "source-map-support": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", + "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", "requires": { - "@babel/helper-builder-binary-assignment-operator-visitor": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" } }, - "@babel/plugin-transform-for-of": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.10.4.tgz", - "integrity": "sha512-ItdQfAzu9AlEqmusA/65TqJ79eRcgGmpPPFvBnGILXZH975G0LNjP1yjHvGgfuCxqrPPueXOPe+FsvxmxKiHHQ==", + "split": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "through": "2" } }, - "@babel/plugin-transform-function-name": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.10.4.tgz", - "integrity": "sha512-OcDCq2y5+E0dVD5MagT5X+yTRbcvFjDI2ZVAottGH6tzqjx/LKpgkUepu3hp/u4tZBzxxpNGwLsAvGBvQ2mJzg==", - "requires": { - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" }, - "@babel/plugin-transform-literals": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.10.4.tgz", - "integrity": "sha512-Xd/dFSTEVuUWnyZiMu76/InZxLTYilOSr1UlHV+p115Z/Le2Fi1KXkJUYz0b42DfndostYlPub3m8ZTQlMaiqQ==", + "stream-combiner": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "duplexer": "~0.1.1" } }, - "@babel/plugin-transform-member-expression-literals": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.10.4.tgz", - "integrity": "sha512-0bFOvPyAoTBhtcJLr9VcwZqKmSjFml1iVxvPL0ReomGU53CX53HsM4h2SzckNdkQcHox1bpAqzxBI1Y09LlBSw==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "string-argv": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", + "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==" }, - "@babel/plugin-transform-modules-amd": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.10.5.tgz", - "integrity": "sha512-elm5uruNio7CTLFItVC/rIzKLfQ17+fX7EVz5W0TMgIHFo1zY0Ozzx+lgwhL4plzl8OzVn6Qasx5DeEFyoNiRw==", + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", "requires": { - "@babel/helper-module-transforms": "^7.10.5", - "@babel/helper-plugin-utils": "^7.10.4", - "babel-plugin-dynamic-import-node": "^2.3.3" + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" } }, - "@babel/plugin-transform-modules-commonjs": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.10.4.tgz", - "integrity": "sha512-Xj7Uq5o80HDLlW64rVfDBhao6OX89HKUmb+9vWYaLXBZOma4gA6tw4Ni1O5qVDoZWUV0fxMYA0aYzOawz0l+1w==", + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", "requires": { - "@babel/helper-module-transforms": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-simple-access": "^7.10.4", - "babel-plugin-dynamic-import-node": "^2.3.3" + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" } }, - "@babel/plugin-transform-modules-systemjs": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.10.5.tgz", - "integrity": "sha512-f4RLO/OL14/FP1AEbcsWMzpbUz6tssRaeQg11RH1BP/XnPpRoVwgeYViMFacnkaw4k4wjRSjn3ip1Uw9TaXuMw==", + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", "requires": { - "@babel/helper-hoist-variables": "^7.10.4", - "@babel/helper-module-transforms": "^7.10.5", - "@babel/helper-plugin-utils": "^7.10.4", - "babel-plugin-dynamic-import-node": "^2.3.3" + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" } }, - "@babel/plugin-transform-modules-umd": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.10.4.tgz", - "integrity": "sha512-mohW5q3uAEt8T45YT7Qc5ws6mWgJAaL/8BfWD9Dodo1A3RKWli8wTS+WiQ/knF+tXlPirW/1/MqzzGfCExKECA==", + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", "requires": { - "@babel/helper-module-transforms": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" + "ansi-regex": "^3.0.0" } }, - "@babel/plugin-transform-named-capturing-groups-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.10.4.tgz", - "integrity": "sha512-V6LuOnD31kTkxQPhKiVYzYC/Jgdq53irJC/xBSmqcNcqFGV+PER4l6rU5SH2Vl7bH9mLDHcc0+l9HUOe4RNGKA==", - "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4" - } + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==" }, - "@babel/plugin-transform-new-target": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.10.4.tgz", - "integrity": "sha512-YXwWUDAH/J6dlfwqlWsztI2Puz1NtUAubXhOPLQ5gjR/qmQ5U96DY4FQO8At33JN4XPBhrjB8I4eMmLROjjLjw==", + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "has-flag": "^4.0.0" } }, - "@babel/plugin-transform-object-super": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.10.4.tgz", - "integrity": "sha512-5iTw0JkdRdJvr7sY0vHqTpnruUpTea32JHmq/atIWqsnNussbRzjEDyWep8UNztt1B5IusBYg8Irb0bLbiEBCQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-replace-supers": "^7.10.4" - } + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=" }, - "@babel/plugin-transform-parameters": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.10.5.tgz", - "integrity": "sha512-xPHwUj5RdFV8l1wuYiu5S9fqWGM2DrYc24TMvUiRrPVm+SM3XeqU9BcokQX/kEUe+p2RBwy+yoiR1w/Blq6ubw==", + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "requires": { - "@babel/helper-get-function-arity": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" + "is-number": "^7.0.0" } }, - "@babel/plugin-transform-property-literals": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.10.4.tgz", - "integrity": "sha512-ofsAcKiUxQ8TY4sScgsGeR2vJIsfrzqvFb9GvJ5UdXDzl+MyYCaBj/FGzXuv7qE0aJcjWMILny1epqelnFlz8g==", + "ts-node": { + "version": "8.10.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", + "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "arg": "^4.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "source-map-support": "^0.5.17", + "yn": "3.1.1" } }, - "@babel/plugin-transform-regenerator": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.10.4.tgz", - "integrity": "sha512-3thAHwtor39A7C04XucbMg17RcZ3Qppfxr22wYzZNcVIkPHfpM9J0SO8zuCV6SZa265kxBJSrfKTvDCYqBFXGw==", + "tsc-watch": { + "version": "4.2.9", + "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", + "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", "requires": { - "regenerator-transform": "^0.14.2" + "cross-spawn": "^7.0.3", + "node-cleanup": "^2.1.2", + "ps-tree": "^1.2.0", + "string-argv": "^0.1.1", + "strip-ansi": "^6.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "requires": { + "ansi-regex": "^5.0.0" + } + } } }, - "@babel/plugin-transform-reserved-words": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.10.4.tgz", - "integrity": "sha512-hGsw1O6Rew1fkFbDImZIEqA8GoidwTAilwCyWqLBM9f+e/u/sQMQu7uX6dyokfOayRuuVfKOW4O7HvaBWM+JlQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==" }, - "@babel/plugin-transform-runtime": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.11.0.tgz", - "integrity": "sha512-LFEsP+t3wkYBlis8w6/kmnd6Kb1dxTd+wGJ8MlxTGzQo//ehtqlVL4S9DNUa53+dtPSQobN2CXx4d81FqC58cw==", - "requires": { - "@babel/helper-module-imports": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "resolve": "^1.8.1", - "semver": "^5.5.1" - } + "type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" }, - "@babel/plugin-transform-shorthand-properties": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.10.4.tgz", - "integrity": "sha512-AC2K/t7o07KeTIxMoHneyX90v3zkm5cjHJEokrPEAGEy3UCp8sLKfnfOIGdZ194fyN4wfX/zZUWT9trJZ0qc+Q==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "typescript": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", + "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==" }, - "@babel/plugin-transform-spread": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.11.0.tgz", - "integrity": "sha512-UwQYGOqIdQJe4aWNyS7noqAnN2VbaczPLiEtln+zPowRNlD+79w3oi2TWfYe0eZgd+gjZCbsydN7lzWysDt+gw==", + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-skip-transparent-expression-wrappers": "^7.11.0" + "isexe": "^2.0.0" } }, - "@babel/plugin-transform-sticky-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.10.4.tgz", - "integrity": "sha512-Ddy3QZfIbEV0VYcVtFDCjeE4xwVTJWTmUtorAJkn6u/92Z/nWJNV+mILyqHKrUxXYKA2EoCilgoPePymKL4DvQ==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/helper-regex": "^7.10.4" - } + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" }, - "@babel/plugin-transform-template-literals": { - "version": "7.10.5", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.10.5.tgz", - "integrity": "sha512-V/lnPGIb+KT12OQikDvgSuesRX14ck5FfJXt6+tXhdkJ+Vsd0lDCVtF6jcB4rNClYFzaB2jusZ+lNISDk2mMMw==", + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", "requires": { - "@babel/helper-annotate-as-pure": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" + "string-width": "^1.0.2 || 2" } }, - "@babel/plugin-transform-typeof-symbol": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.10.4.tgz", - "integrity": "sha512-QqNgYwuuW0y0H+kUE/GWSR45t/ccRhe14Fs/4ZRouNNQsyd4o3PG4OtHiIrepbM2WKUBDAXKCAK/Lk4VhzTaGA==", - "requires": { - "@babel/helper-plugin-utils": "^7.10.4" - } + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==" }, - "@babel/plugin-transform-unicode-escapes": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.10.4.tgz", - "integrity": "sha512-y5XJ9waMti2J+e7ij20e+aH+fho7Wb7W8rNuu72aKRwCHFqQdhkdU2lo3uZ9tQuboEJcUFayXdARhcxLQ3+6Fg==", + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", "requires": { - "@babel/helper-plugin-utils": "^7.10.4" + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "requires": { + "color-convert": "^1.9.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + } } }, - "@babel/plugin-transform-unicode-regex": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.10.4.tgz", - "integrity": "sha512-wNfsc4s8N2qnIwpO/WP2ZiSyjfpTamT2C9V9FDH/Ljub9zw6P3SjkXcFmc0RQUt96k2fmIvtla2MMjgTwIAC+A==", - "requires": { - "@babel/helper-create-regexp-features-plugin": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4" - } + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" }, - "@babel/preset-env": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.11.0.tgz", - "integrity": "sha512-2u1/k7rG/gTh02dylX2kL3S0IJNF+J6bfDSp4DI2Ma8QN6Y9x9pmAax59fsCk6QUQG0yqH47yJWA+u1I1LccAg==", - "requires": { - "@babel/compat-data": "^7.11.0", - "@babel/helper-compilation-targets": "^7.10.4", - "@babel/helper-module-imports": "^7.10.4", - "@babel/helper-plugin-utils": "^7.10.4", - "@babel/plugin-proposal-async-generator-functions": "^7.10.4", - "@babel/plugin-proposal-class-properties": "^7.10.4", - "@babel/plugin-proposal-dynamic-import": "^7.10.4", - "@babel/plugin-proposal-export-namespace-from": "^7.10.4", - "@babel/plugin-proposal-json-strings": "^7.10.4", - "@babel/plugin-proposal-logical-assignment-operators": "^7.11.0", - "@babel/plugin-proposal-nullish-coalescing-operator": "^7.10.4", - "@babel/plugin-proposal-numeric-separator": "^7.10.4", - "@babel/plugin-proposal-object-rest-spread": "^7.11.0", - "@babel/plugin-proposal-optional-catch-binding": "^7.10.4", - "@babel/plugin-proposal-optional-chaining": "^7.11.0", - "@babel/plugin-proposal-private-methods": "^7.10.4", - "@babel/plugin-proposal-unicode-property-regex": "^7.10.4", - "@babel/plugin-syntax-async-generators": "^7.8.0", - "@babel/plugin-syntax-class-properties": "^7.10.4", - "@babel/plugin-syntax-dynamic-import": "^7.8.0", - "@babel/plugin-syntax-export-namespace-from": "^7.8.3", - "@babel/plugin-syntax-json-strings": "^7.8.0", - "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", - "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0", - "@babel/plugin-syntax-numeric-separator": "^7.10.4", - "@babel/plugin-syntax-object-rest-spread": "^7.8.0", - "@babel/plugin-syntax-optional-catch-binding": "^7.8.0", - "@babel/plugin-syntax-optional-chaining": "^7.8.0", - "@babel/plugin-syntax-top-level-await": "^7.10.4", - "@babel/plugin-transform-arrow-functions": "^7.10.4", - "@babel/plugin-transform-async-to-generator": "^7.10.4", - "@babel/plugin-transform-block-scoped-functions": "^7.10.4", - "@babel/plugin-transform-block-scoping": "^7.10.4", - "@babel/plugin-transform-classes": "^7.10.4", - "@babel/plugin-transform-computed-properties": "^7.10.4", - "@babel/plugin-transform-destructuring": "^7.10.4", - "@babel/plugin-transform-dotall-regex": "^7.10.4", - "@babel/plugin-transform-duplicate-keys": "^7.10.4", - "@babel/plugin-transform-exponentiation-operator": "^7.10.4", - "@babel/plugin-transform-for-of": "^7.10.4", - "@babel/plugin-transform-function-name": "^7.10.4", - "@babel/plugin-transform-literals": "^7.10.4", - "@babel/plugin-transform-member-expression-literals": "^7.10.4", - "@babel/plugin-transform-modules-amd": "^7.10.4", - "@babel/plugin-transform-modules-commonjs": "^7.10.4", - "@babel/plugin-transform-modules-systemjs": "^7.10.4", - "@babel/plugin-transform-modules-umd": "^7.10.4", - "@babel/plugin-transform-named-capturing-groups-regex": "^7.10.4", - "@babel/plugin-transform-new-target": "^7.10.4", - "@babel/plugin-transform-object-super": "^7.10.4", - "@babel/plugin-transform-parameters": "^7.10.4", - "@babel/plugin-transform-property-literals": "^7.10.4", - "@babel/plugin-transform-regenerator": "^7.10.4", - "@babel/plugin-transform-reserved-words": "^7.10.4", - "@babel/plugin-transform-shorthand-properties": "^7.10.4", - "@babel/plugin-transform-spread": "^7.11.0", - "@babel/plugin-transform-sticky-regex": "^7.10.4", - "@babel/plugin-transform-template-literals": "^7.10.4", - "@babel/plugin-transform-typeof-symbol": "^7.10.4", - "@babel/plugin-transform-unicode-escapes": "^7.10.4", - "@babel/plugin-transform-unicode-regex": "^7.10.4", - "@babel/preset-modules": "^0.1.3", - "@babel/types": "^7.11.0", - "browserslist": "^4.12.0", - "core-js-compat": "^3.6.2", - "invariant": "^2.2.2", - "levenary": "^1.1.1", - "semver": "^5.5.0" - } + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" }, - "@babel/preset-modules": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.3.tgz", - "integrity": "sha512-Ra3JXOHBq2xd56xSF7lMKXdjBn3T772Y1Wet3yWnkDly9zHvJki029tAFzvAAK5cf4YV3yoxuP61crYRol6SVg==", + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", "requires": { - "@babel/helper-plugin-utils": "^7.0.0", - "@babel/plugin-proposal-unicode-property-regex": "^7.4.4", - "@babel/plugin-transform-dotall-regex": "^7.4.4", - "@babel/types": "^7.4.4", - "esutils": "^2.0.2" + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + } } }, - "@babel/runtime": { - "version": "7.11.2", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.11.2.tgz", - "integrity": "sha512-TeWkU52so0mPtDcaCTxNBI/IHiz0pZgr8VEFqXFtZWpYD08ZB6FaSwVAS8MKRQAP3bYKiVjwysOJgMFY28o6Tw==", + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", "requires": { - "regenerator-runtime": "^0.13.4" + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" } }, - "@babel/template": { - "version": "7.10.4", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.10.4.tgz", - "integrity": "sha512-ZCjD27cGJFUB6nmCB1Enki3r+L5kJveX9pq1SvAUKoICy6CZ9yD8xO086YXdYhvNjBdnekm4ZnaP5yC8Cs/1tA==", + "yargs-unparser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", + "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", "requires": { - "@babel/code-frame": "^7.10.4", - "@babel/parser": "^7.10.4", - "@babel/types": "^7.10.4" + "camelcase": "^5.3.1", + "decamelize": "^1.2.0", + "flat": "^4.1.0", + "is-plain-obj": "^1.1.0", + "yargs": "^14.2.3" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "yargs": { + "version": "14.2.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", + "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + } + }, + "yargs-parser": { + "version": "15.0.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", + "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + } } }, - "@babel/traverse": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.11.0.tgz", - "integrity": "sha512-ZB2V+LskoWKNpMq6E5UUCrjtDUh5IOTAyIl0dTjIEoXum/iKWkoIEKIRDnUucO6f+2FzNkE0oD4RLKoPIufDtg==", - "requires": { - "@babel/code-frame": "^7.10.4", - "@babel/generator": "^7.11.0", - "@babel/helper-function-name": "^7.10.4", - "@babel/helper-split-export-declaration": "^7.11.0", - "@babel/parser": "^7.11.0", - "@babel/types": "^7.11.0", - "debug": "^4.1.0", - "globals": "^11.1.0", - "lodash": "^4.17.19" - }, + "yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" + } + } + }, + "@agile-ts/react": { + "version": "file:../../packages/react", + "requires": { + "@agile-ts/core": "file:../../packages/core" + }, + "dependencies": { + "@agile-ts/core": { + "version": "file:../../packages/core", "dependencies": { + "@types/chai": { + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", + "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==" + }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==" + }, + "@types/mocha": { + "version": "8.0.3", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.3.tgz", + "integrity": "sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==" + }, + "@types/node": { + "version": "14.11.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.11.2.tgz", + "integrity": "sha512-jiE3QIxJ8JLNcb1Ps6rDbysDhN4xa8DJJvuC9prr6w+1tIh+QAbYyNF3tyiZNLDBIuBCf4KEcV2UvQm/V60xfA==" + }, + "ansi-colors": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", + "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==" + }, + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" + }, + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", + "requires": { + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" + } + }, + "anymatch": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "arg": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" + }, + "argparse": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", + "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "requires": { + "sprintf-js": "~1.0.2" + } + }, + "array.prototype.map": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", + "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "es-array-method-boxes-properly": "^1.0.0", + "is-string": "^1.0.4" + } + }, + "assertion-error": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", + "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" + }, + "binary-extensions": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==" + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "requires": { + "fill-range": "^7.0.1" + } + }, + "browser-stdout": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", + "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==" + }, + "buffer-from": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", + "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==" + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" + }, + "chai": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", + "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", + "requires": { + "assertion-error": "^1.1.0", + "check-error": "^1.0.2", + "deep-eql": "^3.0.1", + "get-func-name": "^2.0.0", + "pathval": "^1.1.0", + "type-detect": "^4.0.5" + } + }, + "chalk": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", + "requires": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + } + }, + "check-error": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", + "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=" + }, + "chokidar": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", + "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", + "requires": { + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.4.0" + } + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": {} + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" + }, + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "requires": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + } + }, "debug": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", "requires": { - "ms": "^2.1.1" + "ms": "^2.1.1" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" + }, + "deep-eql": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", + "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", + "requires": { + "type-detect": "^4.0.0" + } + }, + "define-properties": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", + "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", + "requires": { + "object-keys": "^1.0.12" + } + }, + "diff": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" + }, + "es-abstract": { + "version": "1.17.6", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", + "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", + "requires": { + "es-to-primitive": "^1.2.1", + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-symbols": "^1.0.1", + "is-callable": "^1.2.0", + "is-regex": "^1.1.0", + "object-inspect": "^1.7.0", + "object-keys": "^1.1.1", + "object.assign": "^4.1.0", + "string.prototype.trimend": "^1.0.1", + "string.prototype.trimstart": "^1.0.1" + } + }, + "es-array-method-boxes-properly": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", + "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==" + }, + "es-get-iterator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", + "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", + "requires": { + "es-abstract": "^1.17.4", + "has-symbols": "^1.0.1", + "is-arguments": "^1.0.4", + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-string": "^1.0.5", + "isarray": "^2.0.5" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" + }, + "eslint-config-prettier": { + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.12.0.tgz", + "integrity": "sha512-9jWPlFlgNwRUYVoujvWTQ1aMO8o6648r+K7qU7K5Jmkbyqav1fuEZC0COYpGBxyiAJb65Ra9hrmFx19xRGwXWw==", + "requires": { + "get-stdin": "^6.0.0" + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" + }, + "event-stream": { + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", + "integrity": "sha1-SrTJoPWlTbkzi0w02Gv86PSzVXE=", + "requires": { + "duplexer": "~0.1.1", + "from": "~0", + "map-stream": "~0.1.0", + "pause-stream": "0.0.11", + "split": "0.3", + "stream-combiner": "~0.0.4", + "through": "~2.3.1" + } + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "requires": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + } + }, + "flat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", + "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", + "requires": { + "is-buffer": "~2.0.3" + } + }, + "from": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", + "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=" + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" + }, + "get-func-name": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", + "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=" + }, + "get-stdin": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", + "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==" + }, + "glob": { + "version": "7.1.6", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", + "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "glob-parent": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", + "requires": { + "is-glob": "^4.0.1" + } + }, + "growl": { + "version": "1.10.5", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", + "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==" + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" + }, + "has-symbols": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", + "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==" + }, + "he": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", + "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "is-arguments": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", + "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==" + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==" + }, + "is-callable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz", + "integrity": "sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA==" + }, + "is-date-object": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", + "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==" + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" + }, + "is-glob": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", + "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-map": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", + "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==" + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" + }, + "is-plain-obj": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", + "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=" + }, + "is-regex": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", + "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", + "requires": { + "has-symbols": "^1.0.1" + } + }, + "is-set": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", + "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==" + }, + "is-string": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", + "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==" + }, + "is-symbol": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", + "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", + "requires": { + "has-symbols": "^1.0.1" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" + }, + "iterate-iterator": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", + "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==" + }, + "iterate-value": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", + "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", + "requires": { + "es-get-iterator": "^1.0.2", + "iterate-iterator": "^1.0.1" + } + }, + "js-yaml": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", + "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", + "requires": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + } + }, + "locate-path": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "requires": { + "p-locate": "^5.0.0" + } + }, + "log-symbols": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.0.0.tgz", + "integrity": "sha512-FN8JBzLx6CzeMrB0tg6pqlGU1wCrXW+ZXGH481kfsBqer0hToTIiHdjH4Mq8xJUbvATujKCvaREGWpGUionraA==", + "requires": { + "chalk": "^4.0.0" + } + }, + "make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" + }, + "map-stream": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=" + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "mocha": { + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.3.tgz", + "integrity": "sha512-ZbaYib4hT4PpF4bdSO2DohooKXIn4lDeiYqB+vTmCdr6l2woW0b6H3pf5x4sM5nwQMru9RvjjHYWVGltR50ZBw==", + "requires": { + "ansi-colors": "4.1.1", + "browser-stdout": "1.3.1", + "chokidar": "3.4.2", + "debug": "4.1.1", + "diff": "4.0.2", + "escape-string-regexp": "4.0.0", + "find-up": "5.0.0", + "glob": "7.1.6", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.14.0", + "log-symbols": "4.0.0", + "minimatch": "3.0.4", + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "4.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.1" + } + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + }, + "node-cleanup": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", + "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=" + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" + }, + "object-inspect": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", + "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==" + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" + }, + "object.assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", + "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", + "requires": { + "define-properties": "^1.1.2", + "function-bind": "^1.1.1", + "has-symbols": "^1.0.0", + "object-keys": "^1.0.11" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "requires": { + "wrappy": "1" + } + }, + "p-limit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", + "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", + "requires": { + "p-limit": "^3.0.2" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==" + }, + "path-exists": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", + "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==" + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" + }, + "path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==" + }, + "pathval": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", + "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=" + }, + "pause-stream": { + "version": "0.0.11", + "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", + "integrity": "sha1-/lo0sMvOErWqaitAPuLnO2AvFEU=", + "requires": { + "through": "~2.3" + } + }, + "picomatch": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", + "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==" + }, + "prettier": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", + "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==" + }, + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "requires": { + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" + } + }, + "ps-tree": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", + "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", + "requires": { + "event-stream": "=3.3.4" + } + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "readdirp": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", + "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", + "requires": { + "picomatch": "^2.2.1" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, + "serialize-javascript": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", + "requires": { + "randombytes": "^2.1.0" + } + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" + }, + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" + }, + "source-map-support": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", + "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", + "requires": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "split": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", + "requires": { + "through": "2" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" + }, + "stream-combiner": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "requires": { + "duplexer": "~0.1.1" + } + }, + "string-argv": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", + "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==" + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + } + }, + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "requires": { + "ansi-regex": "^3.0.0" + } + }, + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==" + }, + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "requires": { + "has-flag": "^4.0.0" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=" + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "requires": { + "is-number": "^7.0.0" } }, - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + "ts-node": { + "version": "8.10.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", + "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", + "requires": { + "arg": "^4.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "source-map-support": "^0.5.17", + "yn": "3.1.1" + } + }, + "tsc-watch": { + "version": "4.2.9", + "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", + "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", + "requires": { + "cross-spawn": "^7.0.3", + "node-cleanup": "^2.1.2", + "ps-tree": "^1.2.0", + "string-argv": "^0.1.1", + "strip-ansi": "^6.0.0" + }, + "dependencies": {} + }, + "tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==" + }, + "type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" + }, + "typescript": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", + "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==" + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" + }, + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "requires": { + "string-width": "^1.0.2 || 2" + } + }, + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==" + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": {} + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" + }, + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", + "requires": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": {} + }, + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + }, + "yargs-unparser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", + "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", + "requires": { + "camelcase": "^5.3.1", + "decamelize": "^1.2.0", + "flat": "^4.1.0", + "is-plain-obj": "^1.1.0", + "yargs": "^14.2.3" + }, + "dependencies": {} + }, + "yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" } } }, - "@babel/types": { - "version": "7.11.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", - "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", - "requires": { - "@babel/helper-validator-identifier": "^7.10.4", - "lodash": "^4.17.19", - "to-fast-properties": "^2.0.0" - } - }, "@types/chai": { "version": "4.2.12", "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==" }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==" + }, "@types/mocha": { - "version": "8.0.2", - "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.2.tgz", - "integrity": "sha512-5cv8rmqT3KX9XtWDvSgGYfS4OwrKM2eei90GWLnTYz+AXRiBv5uYcKBjnkQ4katNvfYk3+o2bHGZUsDhdcoUyg==" + "version": "8.0.3", + "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.3.tgz", + "integrity": "sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==" + }, + "@types/node": { + "version": "14.11.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-14.11.2.tgz", + "integrity": "sha512-jiE3QIxJ8JLNcb1Ps6rDbysDhN4xa8DJJvuC9prr6w+1tIh+QAbYyNF3tyiZNLDBIuBCf4KEcV2UvQm/V60xfA==" + }, + "@types/prop-types": { + "version": "15.7.3", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.3.tgz", + "integrity": "sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw==" + }, + "@types/react": { + "version": "16.9.49", + "resolved": "https://registry.npmjs.org/@types/react/-/react-16.9.49.tgz", + "integrity": "sha512-DtLFjSj0OYAdVLBbyjhuV9CdGVHCkHn2R+xr3XkBvK2rS1Y1tkc14XSGjYgm5Fjjr90AxH9tiSzc1pCFMGO06g==", + "requires": { + "@types/prop-types": "*", + "csstype": "^3.0.2" + } }, "ansi-colors": { "version": "4.1.1", @@ -3219,37 +2372,26 @@ "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==" }, "ansi-regex": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", - "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" }, "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", "requires": { - "color-convert": "^1.9.0" + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" } }, "anymatch": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-2.0.0.tgz", - "integrity": "sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw==", - "optional": true, + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", + "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", "requires": { - "micromatch": "^3.1.4", - "normalize-path": "^2.1.1" - }, - "dependencies": { - "normalize-path": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.1.1.tgz", - "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", - "optional": true, - "requires": { - "remove-trailing-separator": "^1.0.1" - } - } + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" } }, "arg": { @@ -3265,30 +2407,6 @@ "sprintf-js": "~1.0.2" } }, - "arr-diff": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", - "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=", - "optional": true - }, - "arr-flatten": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/arr-flatten/-/arr-flatten-1.1.0.tgz", - "integrity": "sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg==", - "optional": true - }, - "arr-union": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/arr-union/-/arr-union-3.1.0.tgz", - "integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=", - "optional": true - }, - "array-unique": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", - "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", - "optional": true - }, "array.prototype.map": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", @@ -3305,119 +2423,15 @@ "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" }, - "assign-symbols": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assign-symbols/-/assign-symbols-1.0.0.tgz", - "integrity": "sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c=", - "optional": true - }, - "async-each": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.3.tgz", - "integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ==", - "optional": true - }, - "atob": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", - "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==", - "optional": true - }, - "babel-eslint": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/babel-eslint/-/babel-eslint-10.1.0.tgz", - "integrity": "sha512-ifWaTHQ0ce+448CYop8AdrQiBsGrnC+bMgfyKFdi6EsPLTAWG+QfyDeM6OH+FmWnKvEq5NnBMLvlBUPKQZoDSg==", - "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.7.0", - "@babel/traverse": "^7.7.0", - "@babel/types": "^7.7.0", - "eslint-visitor-keys": "^1.0.0", - "resolve": "^1.12.0" - } - }, - "babel-plugin-dynamic-import-node": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz", - "integrity": "sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ==", - "requires": { - "object.assign": "^4.1.0" - } - }, "balanced-match": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" }, - "base": { - "version": "0.11.2", - "resolved": "https://registry.npmjs.org/base/-/base-0.11.2.tgz", - "integrity": "sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==", - "optional": true, - "requires": { - "cache-base": "^1.0.1", - "class-utils": "^0.3.5", - "component-emitter": "^1.2.1", - "define-property": "^1.0.0", - "isobject": "^3.0.1", - "mixin-deep": "^1.2.0", - "pascalcase": "^0.1.1" - }, - "dependencies": { - "define-property": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", - "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", - "optional": true, - "requires": { - "is-descriptor": "^1.0.0" - } - }, - "is-accessor-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-descriptor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", - "optional": true, - "requires": { - "is-accessor-descriptor": "^1.0.0", - "is-data-descriptor": "^1.0.0", - "kind-of": "^6.0.2" - } - } - } - }, "binary-extensions": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.13.1.tgz", - "integrity": "sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw==", - "optional": true - }, - "bindings": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", - "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", - "optional": true, - "requires": { - "file-uri-to-path": "1.0.0" - } + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", + "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==" }, "brace-expansion": { "version": "1.1.11", @@ -3429,32 +2443,11 @@ } }, "braces": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", - "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", - "optional": true, + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", "requires": { - "arr-flatten": "^1.1.0", - "array-unique": "^0.3.2", - "extend-shallow": "^2.0.1", - "fill-range": "^4.0.0", - "isobject": "^3.0.1", - "repeat-element": "^1.1.2", - "snapdragon": "^0.8.1", - "snapdragon-node": "^2.0.1", - "split-string": "^3.0.2", - "to-regex": "^3.0.1" - }, - "dependencies": { - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "optional": true, - "requires": { - "is-extendable": "^0.1.0" - } - } + "fill-range": "^7.0.1" } }, "browser-stdout": { @@ -3462,49 +2455,16 @@ "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==" }, - "browserslist": { - "version": "4.14.0", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.14.0.tgz", - "integrity": "sha512-pUsXKAF2lVwhmtpeA3LJrZ76jXuusrNyhduuQs7CDFf9foT4Y38aQOserd2lMe5DSSrjf3fx34oHwryuvxAUgQ==", - "requires": { - "caniuse-lite": "^1.0.30001111", - "electron-to-chromium": "^1.3.523", - "escalade": "^3.0.2", - "node-releases": "^1.1.60" - } - }, "buffer-from": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==" }, - "cache-base": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/cache-base/-/cache-base-1.0.1.tgz", - "integrity": "sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ==", - "optional": true, - "requires": { - "collection-visit": "^1.0.0", - "component-emitter": "^1.2.1", - "get-value": "^2.0.6", - "has-value": "^1.0.0", - "isobject": "^3.0.1", - "set-value": "^2.0.0", - "to-object-path": "^0.3.0", - "union-value": "^1.0.0", - "unset-value": "^1.0.0" - } - }, "camelcase": { "version": "5.3.1", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==" }, - "caniuse-lite": { - "version": "1.0.30001113", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001113.tgz", - "integrity": "sha512-qMvjHiKH21zzM/VDZr6oosO6Ri3U0V2tC015jRXjOecwQCJtsU5zklTNTk31jQbIOP8gha0h1ccM/g0ECP+4BA==" - }, "chai": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", @@ -3519,13 +2479,12 @@ } }, "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", + "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, "check-error": { @@ -3534,46 +2493,17 @@ "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=" }, "chokidar": { - "version": "2.1.8", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-2.1.8.tgz", - "integrity": "sha512-ZmZUazfOzf0Nve7duiCKD23PFSCs4JPoYyccjUFF3aQkQadqBhfzhjkwBH2mNOG9cTBwhamM37EIsIkZw3nRgg==", - "optional": true, - "requires": { - "anymatch": "^2.0.0", - "async-each": "^1.0.1", - "braces": "^2.3.2", - "fsevents": "^1.2.7", - "glob-parent": "^3.1.0", - "inherits": "^2.0.3", - "is-binary-path": "^1.0.0", - "is-glob": "^4.0.0", - "normalize-path": "^3.0.0", - "path-is-absolute": "^1.0.0", - "readdirp": "^2.2.1", - "upath": "^1.1.1" - } - }, - "class-utils": { - "version": "0.3.6", - "resolved": "https://registry.npmjs.org/class-utils/-/class-utils-0.3.6.tgz", - "integrity": "sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg==", - "optional": true, + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", + "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", "requires": { - "arr-union": "^3.1.0", - "define-property": "^0.2.5", - "isobject": "^3.0.0", - "static-extend": "^0.1.1" - }, - "dependencies": { - "define-property": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", - "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", - "optional": true, - "requires": { - "is-descriptor": "^0.1.0" - } - } + "anymatch": "~3.1.1", + "braces": "~3.0.2", + "glob-parent": "~5.1.0", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.4.0" } }, "cliui": { @@ -3611,85 +2541,23 @@ } } }, - "collection-visit": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/collection-visit/-/collection-visit-1.0.0.tgz", - "integrity": "sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA=", - "optional": true, - "requires": { - "map-visit": "^1.0.0", - "object-visit": "^1.0.0" - } - }, "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "requires": { - "color-name": "1.1.3" + "color-name": "~1.1.4" } }, "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" - }, - "colorette": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.2.0.tgz", - "integrity": "sha512-soRSroY+OF/8OdA3PTQXwaDJeMc7TfknKKrxeSCencL2a4+Tx5zhxmmv7hdpCjhKBjehzp8+bwe/T68K0hpIjw==" - }, - "commander": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", - "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==" - }, - "component-emitter": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz", - "integrity": "sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==", - "optional": true - }, - "concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" - }, - "convert-source-map": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.7.0.tgz", - "integrity": "sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA==", - "requires": { - "safe-buffer": "~5.1.1" - } - }, - "copy-descriptor": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/copy-descriptor/-/copy-descriptor-0.1.1.tgz", - "integrity": "sha1-Z29us8OZl8LuGsOpJP1hJHSPV40=", - "optional": true - }, - "core-js-compat": { - "version": "3.6.5", - "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.6.5.tgz", - "integrity": "sha512-7ItTKOhOZbznhXAQ2g/slGg1PJV5zDO/WdkTwi7UEOJmkvsE32PWvx6mKtDjiMpjnR2CNf6BAD6sSxIlv7ptng==", - "requires": { - "browserslist": "^4.8.5", - "semver": "7.0.0" - }, - "dependencies": { - "semver": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.0.0.tgz", - "integrity": "sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A==" - } - } + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" }, - "core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", - "optional": true + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, "cross-spawn": { "version": "7.0.3", @@ -3701,13 +2569,17 @@ "which": "^2.0.1" } }, + "csstype": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.0.3.tgz", + "integrity": "sha512-jPl+wbWPOWJ7SXsWyqGRk3lGecbar0Cb0OvZF/r/ZU011R4YqiRehgkQ9p4eQfo9DSDLqLL3wHwfxeJiuIsNag==" + }, "debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "optional": true, + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", + "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", "requires": { - "ms": "2.0.0" + "ms": "^2.1.1" } }, "decamelize": { @@ -3715,12 +2587,6 @@ "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" }, - "decode-uri-component": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.0.tgz", - "integrity": "sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU=", - "optional": true - }, "deep-eql": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", @@ -3737,61 +2603,15 @@ "object-keys": "^1.0.12" } }, - "define-property": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-2.0.2.tgz", - "integrity": "sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ==", - "optional": true, - "requires": { - "is-descriptor": "^1.0.2", - "isobject": "^3.0.1" - }, - "dependencies": { - "is-accessor-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-descriptor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", - "optional": true, - "requires": { - "is-accessor-descriptor": "^1.0.0", - "is-data-descriptor": "^1.0.0", - "kind-of": "^6.0.2" - } - } - } - }, "diff": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" }, "duplexer": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", - "integrity": "sha1-rOb/gIwc5mtX0ev5eXessCM0z8E=" - }, - "electron-to-chromium": { - "version": "1.3.533", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.533.tgz", - "integrity": "sha512-YqAL+NXOzjBnpY+dcOKDlZybJDCOzgsq4koW3fvyty/ldTmsb4QazZpOWmVvZ2m0t5jbBf7L0lIGU3BUipwG+A==" + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" }, "emoji-regex": { "version": "7.0.3", @@ -3833,13 +2653,6 @@ "is-set": "^2.0.1", "is-string": "^1.0.5", "isarray": "^2.0.5" - }, - "dependencies": { - "isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" - } } }, "es-to-primitive": { @@ -3852,39 +2665,24 @@ "is-symbol": "^1.0.2" } }, - "escalade": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.0.2.tgz", - "integrity": "sha512-gPYAU37hYCUhW5euPeR+Y74F7BL+IBsV93j5cvGriSaD1aG6MGsqsV1yamRdrWrb2j3aiZvb0X+UBOWpx3JWtQ==" - }, "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=" + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" }, "eslint-config-prettier": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.11.0.tgz", - "integrity": "sha512-oB8cpLWSAjOVFEJhhyMZh6NOEOtBVziaqdDQ86+qhDHFbZXoRTM7pNSvFRfW/W/L/LrQ38C99J5CGuRBBzBsdA==", + "version": "6.12.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.12.0.tgz", + "integrity": "sha512-9jWPlFlgNwRUYVoujvWTQ1aMO8o6648r+K7qU7K5Jmkbyqav1fuEZC0COYpGBxyiAJb65Ra9hrmFx19xRGwXWw==", "requires": { "get-stdin": "^6.0.0" } }, - "eslint-visitor-keys": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", - "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==" - }, "esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==" }, - "esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==" - }, "event-stream": { "version": "3.3.4", "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", @@ -3899,162 +2697,20 @@ "through": "~2.3.1" } }, - "expand-brackets": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", - "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", - "optional": true, - "requires": { - "debug": "^2.3.3", - "define-property": "^0.2.5", - "extend-shallow": "^2.0.1", - "posix-character-classes": "^0.1.0", - "regex-not": "^1.0.0", - "snapdragon": "^0.8.1", - "to-regex": "^3.0.1" - }, - "dependencies": { - "define-property": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", - "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", - "optional": true, - "requires": { - "is-descriptor": "^0.1.0" - } - }, - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "optional": true, - "requires": { - "is-extendable": "^0.1.0" - } - } - } - }, - "extend-shallow": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-3.0.2.tgz", - "integrity": "sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg=", - "optional": true, - "requires": { - "assign-symbols": "^1.0.0", - "is-extendable": "^1.0.1" - }, - "dependencies": { - "is-extendable": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", - "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", - "optional": true, - "requires": { - "is-plain-object": "^2.0.4" - } - } - } - }, - "extglob": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.4.tgz", - "integrity": "sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==", - "optional": true, - "requires": { - "array-unique": "^0.3.2", - "define-property": "^1.0.0", - "expand-brackets": "^2.1.4", - "extend-shallow": "^2.0.1", - "fragment-cache": "^0.2.1", - "regex-not": "^1.0.0", - "snapdragon": "^0.8.1", - "to-regex": "^3.0.1" - }, - "dependencies": { - "define-property": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", - "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", - "optional": true, - "requires": { - "is-descriptor": "^1.0.0" - } - }, - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "optional": true, - "requires": { - "is-extendable": "^0.1.0" - } - }, - "is-accessor-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-descriptor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", - "optional": true, - "requires": { - "is-accessor-descriptor": "^1.0.0", - "is-data-descriptor": "^1.0.0", - "kind-of": "^6.0.2" - } - } - } - }, - "file-uri-to-path": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", - "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", - "optional": true - }, "fill-range": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", - "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", - "optional": true, + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", "requires": { - "extend-shallow": "^2.0.1", - "is-number": "^3.0.0", - "repeat-string": "^1.6.1", - "to-regex-range": "^2.1.0" - }, - "dependencies": { - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "optional": true, - "requires": { - "is-extendable": "^0.1.0" - } - } + "to-regex-range": "^5.0.1" } }, "find-up": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-4.1.0.tgz", - "integrity": "sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==", + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", "requires": { - "locate-path": "^5.0.0", + "locate-path": "^6.0.0", "path-exists": "^4.0.0" } }, @@ -4064,28 +2720,6 @@ "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", "requires": { "is-buffer": "~2.0.3" - }, - "dependencies": { - "is-buffer": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", - "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==" - } - } - }, - "for-in": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", - "integrity": "sha1-gQaNKVqBQuwKxybG4iAMMPttXoA=", - "optional": true - }, - "fragment-cache": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/fragment-cache/-/fragment-cache-0.2.1.tgz", - "integrity": "sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk=", - "optional": true, - "requires": { - "map-cache": "^0.2.2" } }, "from": { @@ -4093,36 +2727,16 @@ "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=" }, - "fs-readdir-recursive": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/fs-readdir-recursive/-/fs-readdir-recursive-1.1.0.tgz", - "integrity": "sha512-GNanXlVr2pf02+sPN40XN8HG+ePaNcvM0q5mZBd668Obwb0yD5GiUbZOFgwn8kGMY6I3mdyDJzieUy3PTYyTRA==" - }, "fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" }, - "fsevents": { - "version": "1.2.13", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.2.13.tgz", - "integrity": "sha512-oWb1Z6mkHIskLzEJ/XWX0srkpkTQ7vaopMQkyaEIoq0fmtFVxOthb8cCxeT+p3ynTdkk/RZwbgG4brR5BeWECw==", - "optional": true, - "requires": { - "bindings": "^1.5.0", - "nan": "^2.12.1" - } - }, "function-bind": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" }, - "gensync": { - "version": "1.0.0-beta.1", - "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.1.tgz", - "integrity": "sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg==" - }, "get-caller-file": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", @@ -4138,12 +2752,6 @@ "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==" }, - "get-value": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz", - "integrity": "sha1-3BXKHGcjh8p2vTesCjlbogQqLCg=", - "optional": true - }, "glob": { "version": "7.1.6", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", @@ -4158,37 +2766,13 @@ } }, "glob-parent": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-3.1.0.tgz", - "integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=", - "optional": true, + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", + "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", "requires": { - "is-glob": "^3.1.0", - "path-dirname": "^1.0.0" - }, - "dependencies": { - "is-glob": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz", - "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", - "optional": true, - "requires": { - "is-extglob": "^2.1.0" - } - } + "is-glob": "^4.0.1" } }, - "globals": { - "version": "11.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==" - }, - "graceful-fs": { - "version": "4.2.4", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.4.tgz", - "integrity": "sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw==", - "optional": true - }, "growl": { "version": "1.10.5", "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", @@ -4203,47 +2787,15 @@ } }, "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=" + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" }, "has-symbols": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==" }, - "has-value": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-value/-/has-value-1.0.0.tgz", - "integrity": "sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc=", - "optional": true, - "requires": { - "get-value": "^2.0.6", - "has-values": "^1.0.0", - "isobject": "^3.0.0" - } - }, - "has-values": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-values/-/has-values-1.0.0.tgz", - "integrity": "sha1-lbC2P+whRmGab+V/51Yo1aOe/k8=", - "optional": true, - "requires": { - "is-number": "^3.0.0", - "kind-of": "^4.0.0" - }, - "dependencies": { - "kind-of": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-4.0.0.tgz", - "integrity": "sha1-IIE989cSkosgc3hpGkUGb65y3Vc=", - "optional": true, - "requires": { - "is-buffer": "^1.1.5" - } - } - } - }, "he": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", @@ -4263,109 +2815,34 @@ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, - "invariant": { - "version": "2.2.4", - "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", - "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", - "requires": { - "loose-envify": "^1.0.0" - } - }, - "is-accessor-descriptor": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", - "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", - "optional": true, - "requires": { - "kind-of": "^3.0.2" - }, - "dependencies": { - "kind-of": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", - "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", - "optional": true, - "requires": { - "is-buffer": "^1.1.5" - } - } - } - }, "is-arguments": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==" - }, - "is-binary-path": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-1.0.1.tgz", - "integrity": "sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg=", - "optional": true, - "requires": { - "binary-extensions": "^1.0.0" - } - }, - "is-buffer": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", - "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", - "optional": true - }, - "is-callable": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.0.tgz", - "integrity": "sha512-pyVD9AaGLxtg6srb2Ng6ynWJqkHU9bEM087AKck0w8QwDarTfNcpIYoU8x8Hv2Icm8u6kFJM18Dag8lyqGkviw==" - }, - "is-data-descriptor": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", - "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", - "optional": true, - "requires": { - "kind-of": "^3.0.2" - }, - "dependencies": { - "kind-of": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", - "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", - "optional": true, - "requires": { - "is-buffer": "^1.1.5" - } - } + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "requires": { + "binary-extensions": "^2.0.0" } }, + "is-buffer": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", + "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==" + }, + "is-callable": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz", + "integrity": "sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA==" + }, "is-date-object": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==" }, - "is-descriptor": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", - "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", - "optional": true, - "requires": { - "is-accessor-descriptor": "^0.1.6", - "is-data-descriptor": "^0.1.4", - "kind-of": "^5.0.0" - }, - "dependencies": { - "kind-of": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", - "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==", - "optional": true - } - } - }, - "is-extendable": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", - "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=", - "optional": true - }, "is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", @@ -4390,39 +2867,15 @@ "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==" }, "is-number": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", - "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", - "optional": true, - "requires": { - "kind-of": "^3.0.2" - }, - "dependencies": { - "kind-of": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", - "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", - "optional": true, - "requires": { - "is-buffer": "^1.1.5" - } - } - } + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" }, "is-plain-obj": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=" }, - "is-plain-object": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", - "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", - "optional": true, - "requires": { - "isobject": "^3.0.1" - } - }, "is-regex": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", @@ -4449,29 +2902,16 @@ "has-symbols": "^1.0.1" } }, - "is-windows": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", - "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==", - "optional": true - }, "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", - "optional": true + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" }, "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" }, - "isobject": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", - "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", - "optional": true - }, "iterate-iterator": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", @@ -4492,388 +2932,107 @@ "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==" }, "js-yaml": { - "version": "3.13.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz", - "integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==", + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", + "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", "requires": { "argparse": "^1.0.7", "esprima": "^4.0.0" } }, - "jsesc": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==" - }, - "json5": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.1.3.tgz", - "integrity": "sha512-KXPvOm8K9IJKFM0bmdn8QXh7udDh1g/giieX0NLCaMnb4hEiVFqnop2ImTXCc5e0/oHz3LTqmHGtExn5hfMkOA==", - "requires": { - "minimist": "^1.2.5" - } - }, - "kind-of": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", - "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==", - "optional": true - }, - "leven": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", - "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==" - }, - "levenary": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/levenary/-/levenary-1.1.1.tgz", - "integrity": "sha512-mkAdOIt79FD6irqjYSs4rdbnlT5vRonMEvBVPVb3XmevfS8kgRXwfes0dhPdEtzTWD/1eNE/Bm/G1iRt6DcnQQ==", - "requires": { - "leven": "^3.1.0" - } - }, "locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", - "requires": { - "p-locate": "^4.1.0" - } - }, - "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==" - }, - "log-symbols": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", - "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", - "requires": { - "chalk": "^2.4.2" - } - }, - "loose-envify": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", - "requires": { - "js-tokens": "^3.0.0 || ^4.0.0" - } - }, - "make-dir": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz", - "integrity": "sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA==", - "requires": { - "pify": "^4.0.1", - "semver": "^5.6.0" - } - }, - "make-error": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" - }, - "map-cache": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/map-cache/-/map-cache-0.2.2.tgz", - "integrity": "sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8=", - "optional": true - }, - "map-stream": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", - "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=" - }, - "map-visit": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/map-visit/-/map-visit-1.0.0.tgz", - "integrity": "sha1-7Nyo8TFE5mDxtb1B8S80edmN+48=", - "optional": true, - "requires": { - "object-visit": "^1.0.0" - } - }, - "micromatch": { - "version": "3.1.10", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", - "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", - "optional": true, - "requires": { - "arr-diff": "^4.0.0", - "array-unique": "^0.3.2", - "braces": "^2.3.1", - "define-property": "^2.0.2", - "extend-shallow": "^3.0.2", - "extglob": "^2.0.4", - "fragment-cache": "^0.2.1", - "kind-of": "^6.0.2", - "nanomatch": "^1.2.9", - "object.pick": "^1.3.0", - "regex-not": "^1.0.0", - "snapdragon": "^0.8.1", - "to-regex": "^3.0.2" - } - }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "minimist": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==" - }, - "mixin-deep": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/mixin-deep/-/mixin-deep-1.3.2.tgz", - "integrity": "sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA==", - "optional": true, - "requires": { - "for-in": "^1.0.2", - "is-extendable": "^1.0.1" - }, - "dependencies": { - "is-extendable": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", - "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", - "optional": true, - "requires": { - "is-plain-object": "^2.0.4" - } - } - } - }, - "mocha": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.1.tgz", - "integrity": "sha512-p7FuGlYH8t7gaiodlFreseLxEmxTgvyG9RgPHODFPySNhwUehu8NIb0vdSt3WFckSneswZ0Un5typYcWElk7HQ==", - "requires": { - "ansi-colors": "4.1.1", - "browser-stdout": "1.3.1", - "chokidar": "3.3.1", - "debug": "3.2.6", - "diff": "4.0.2", - "escape-string-regexp": "1.0.5", - "find-up": "4.1.0", - "glob": "7.1.6", - "growl": "1.10.5", - "he": "1.2.0", - "js-yaml": "3.13.1", - "log-symbols": "3.0.0", - "minimatch": "3.0.4", - "ms": "2.1.2", - "object.assign": "4.1.0", - "promise.allsettled": "1.0.2", - "serialize-javascript": "4.0.0", - "strip-json-comments": "3.0.1", - "supports-color": "7.1.0", - "which": "2.0.2", - "wide-align": "1.1.3", - "workerpool": "6.0.0", - "yargs": "13.3.2", - "yargs-parser": "13.1.2", - "yargs-unparser": "1.6.1" - }, - "dependencies": { - "anymatch": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", - "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", - "requires": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - } - }, - "binary-extensions": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", - "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==" - }, - "braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "requires": { - "fill-range": "^7.0.1" - } - }, - "chokidar": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.3.1.tgz", - "integrity": "sha512-4QYCEWOcK3OJrxwvyyAOxFuhpvOVCYkr33LPfFNBjAD/w3sEzWsp2BUOkI4l9bHvWioAd0rc6NlHUOEaWkTeqg==", - "requires": { - "anymatch": "~3.1.1", - "braces": "~3.0.2", - "fsevents": "~2.1.2", - "glob-parent": "~5.1.0", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.3.0" - } - }, - "debug": { - "version": "3.2.6", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", - "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", - "requires": { - "ms": "^2.1.1" - } - }, - "fill-range": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "requires": { - "to-regex-range": "^5.0.1" - } - }, - "fsevents": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", - "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", - "optional": true - }, - "glob-parent": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", - "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", - "requires": { - "is-glob": "^4.0.1" - } - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" - }, - "is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "requires": { - "binary-extensions": "^2.0.0" - } - }, - "is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" - }, - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" - }, - "readdirp": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.3.0.tgz", - "integrity": "sha512-zz0pAkSPOXXm1viEwygWIPSPkcBYjW1xU5j/JBh5t9bGCJwa6f9+BJa6VaB2g+b55yVrmXzqkyLf4xaWYM0IkQ==", - "requires": { - "picomatch": "^2.0.7" - } - }, - "supports-color": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", - "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", - "requires": { - "has-flag": "^4.0.0" - } - }, - "to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "requires": { - "is-number": "^7.0.0" - } - } + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", + "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", + "requires": { + "p-locate": "^5.0.0" } }, - "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", - "optional": true + "log-symbols": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.0.0.tgz", + "integrity": "sha512-FN8JBzLx6CzeMrB0tg6pqlGU1wCrXW+ZXGH481kfsBqer0hToTIiHdjH4Mq8xJUbvATujKCvaREGWpGUionraA==", + "requires": { + "chalk": "^4.0.0" + } }, - "nan": { - "version": "2.14.1", - "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.1.tgz", - "integrity": "sha512-isWHgVjnFjh2x2yuJ/tj3JbwoHu3UC2dX5G/88Cm24yB6YopVgxvBObDY7n5xW6ExmFhJpSEQqFPvq9zaXc8Jw==", - "optional": true + "loose-envify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", + "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } }, - "nanomatch": { - "version": "1.2.13", - "resolved": "https://registry.npmjs.org/nanomatch/-/nanomatch-1.2.13.tgz", - "integrity": "sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==", - "optional": true, + "make-error": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" + }, + "map-stream": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/map-stream/-/map-stream-0.1.0.tgz", + "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=" + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "requires": { - "arr-diff": "^4.0.0", - "array-unique": "^0.3.2", - "define-property": "^2.0.2", - "extend-shallow": "^3.0.2", - "fragment-cache": "^0.2.1", - "is-windows": "^1.0.2", - "kind-of": "^6.0.2", - "object.pick": "^1.3.0", - "regex-not": "^1.0.0", - "snapdragon": "^0.8.1", - "to-regex": "^3.0.1" + "brace-expansion": "^1.1.7" + } + }, + "mocha": { + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.3.tgz", + "integrity": "sha512-ZbaYib4hT4PpF4bdSO2DohooKXIn4lDeiYqB+vTmCdr6l2woW0b6H3pf5x4sM5nwQMru9RvjjHYWVGltR50ZBw==", + "requires": { + "ansi-colors": "4.1.1", + "browser-stdout": "1.3.1", + "chokidar": "3.4.2", + "debug": "4.1.1", + "diff": "4.0.2", + "escape-string-regexp": "4.0.0", + "find-up": "5.0.0", + "glob": "7.1.6", + "growl": "1.10.5", + "he": "1.2.0", + "js-yaml": "3.14.0", + "log-symbols": "4.0.0", + "minimatch": "3.0.4", + "ms": "2.1.2", + "object.assign": "4.1.0", + "promise.allsettled": "1.0.2", + "serialize-javascript": "4.0.0", + "strip-json-comments": "3.0.1", + "supports-color": "7.1.0", + "which": "2.0.2", + "wide-align": "1.1.3", + "workerpool": "6.0.0", + "yargs": "13.3.2", + "yargs-parser": "13.1.2", + "yargs-unparser": "1.6.1" } }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + }, "node-cleanup": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=" }, - "node-releases": { - "version": "1.1.60", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.60.tgz", - "integrity": "sha512-gsO4vjEdQaTusZAEebUWp2a5d7dF5DYoIpDG7WySnk7BuZDW+GPpHXoXXuYawRBr/9t5q54tirPz79kFIWg4dA==" - }, "normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" }, - "object-copy": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/object-copy/-/object-copy-0.1.0.tgz", - "integrity": "sha1-fn2Fi3gb18mRpBupde04EnVOmYw=", - "optional": true, - "requires": { - "copy-descriptor": "^0.1.0", - "define-property": "^0.2.5", - "kind-of": "^3.0.3" - }, - "dependencies": { - "define-property": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", - "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", - "optional": true, - "requires": { - "is-descriptor": "^0.1.0" - } - }, - "kind-of": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", - "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", - "optional": true, - "requires": { - "is-buffer": "^1.1.5" - } - } - } + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" }, "object-inspect": { "version": "1.8.0", @@ -4885,15 +3044,6 @@ "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" }, - "object-visit": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/object-visit/-/object-visit-1.0.1.tgz", - "integrity": "sha1-95xEk68MU3e1n+OdOV5BBC3QRbs=", - "optional": true, - "requires": { - "isobject": "^3.0.0" - } - }, "object.assign": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", @@ -4905,15 +3055,6 @@ "object-keys": "^1.0.11" } }, - "object.pick": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/object.pick/-/object.pick-1.3.0.tgz", - "integrity": "sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c=", - "optional": true, - "requires": { - "isobject": "^3.0.1" - } - }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -4923,19 +3064,19 @@ } }, "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", + "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", "requires": { "p-try": "^2.0.0" } }, "p-locate": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-4.1.0.tgz", - "integrity": "sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==", + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", + "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", "requires": { - "p-limit": "^2.2.0" + "p-limit": "^3.0.2" } }, "p-try": { @@ -4943,18 +3084,6 @@ "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==" }, - "pascalcase": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/pascalcase/-/pascalcase-0.1.1.tgz", - "integrity": "sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ=", - "optional": true - }, - "path-dirname": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/path-dirname/-/path-dirname-1.0.2.tgz", - "integrity": "sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA=", - "optional": true - }, "path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -4970,11 +3099,6 @@ "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==" }, - "path-parse": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", - "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==" - }, "pathval": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", @@ -4993,991 +3117,2762 @@ "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==" }, - "pify": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz", - "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==" - }, - "posix-character-classes": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/posix-character-classes/-/posix-character-classes-0.1.1.tgz", - "integrity": "sha1-AerA/jta9xoqbAL+q7jB/vfgDqs=", - "optional": true - }, "prettier": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==" }, - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "optional": true + "promise.allsettled": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", + "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "requires": { + "array.prototype.map": "^1.0.1", + "define-properties": "^1.1.3", + "es-abstract": "^1.17.0-next.1", + "function-bind": "^1.1.1", + "iterate-value": "^1.0.0" + } + }, + "prop-types": { + "version": "15.7.2", + "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz", + "integrity": "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==", + "requires": { + "loose-envify": "^1.4.0", + "object-assign": "^4.1.1", + "react-is": "^16.8.1" + } + }, + "ps-tree": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", + "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", + "requires": { + "event-stream": "=3.3.4" + } + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "react": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react/-/react-16.13.1.tgz", + "integrity": "sha512-YMZQQq32xHLX0bz5Mnibv1/LHb3Sqzngu7xstSM+vrkE5Kzr9xE0yMByK5kMoTK30YVJE61WfbxIFFvfeDKT1w==", + "requires": { + "loose-envify": "^1.1.0", + "object-assign": "^4.1.1", + "prop-types": "^15.6.2" + } + }, + "react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==" + }, + "readdirp": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", + "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", + "requires": { + "picomatch": "^2.2.1" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, + "serialize-javascript": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", + "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", + "requires": { + "randombytes": "^2.1.0" + } + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" + }, + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" + }, + "source-map-support": { + "version": "0.5.19", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", + "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", + "requires": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "split": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", + "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", + "requires": { + "through": "2" + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" + }, + "stream-combiner": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", + "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "requires": { + "duplexer": "~0.1.1" + } + }, + "string-argv": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", + "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==" + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + } + }, + "string.prototype.trimend": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", + "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "string.prototype.trimstart": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", + "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "requires": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.5" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "requires": { + "ansi-regex": "^3.0.0" + } + }, + "strip-json-comments": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", + "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==" }, - "promise.allsettled": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", - "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", "requires": { - "array.prototype.map": "^1.0.1", - "define-properties": "^1.1.3", - "es-abstract": "^1.17.0-next.1", - "function-bind": "^1.1.1", - "iterate-value": "^1.0.0" + "has-flag": "^4.0.0" } }, - "ps-tree": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", - "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=" + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "requires": { - "event-stream": "=3.3.4" + "is-number": "^7.0.0" } }, - "randombytes": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", - "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "ts-node": { + "version": "8.10.2", + "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", + "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", "requires": { - "safe-buffer": "^5.1.0" + "arg": "^4.1.0", + "diff": "^4.0.1", + "make-error": "^1.1.1", + "source-map-support": "^0.5.17", + "yn": "3.1.1" } }, - "readable-stream": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", - "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", - "optional": true, + "tsc-watch": { + "version": "4.2.9", + "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", + "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" + "cross-spawn": "^7.0.3", + "node-cleanup": "^2.1.2", + "ps-tree": "^1.2.0", + "string-argv": "^0.1.1", + "strip-ansi": "^6.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" + }, + "strip-ansi": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", + "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "requires": { + "ansi-regex": "^5.0.0" + } + } } }, - "readdirp": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.2.1.tgz", - "integrity": "sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ==", - "optional": true, + "tslib": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", + "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==" + }, + "type-detect": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" + }, + "typescript": { + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", + "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==" + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", "requires": { - "graceful-fs": "^4.1.11", - "micromatch": "^3.1.10", - "readable-stream": "^2.0.2" + "isexe": "^2.0.0" } }, - "regenerate": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.1.tgz", - "integrity": "sha512-j2+C8+NtXQgEKWk49MMP5P/u2GhnahTtVkRIHr5R5lVRlbKvmQ+oS+A5aLKWp2ma5VkT8sh6v+v4hbH0YHR66A==" + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" }, - "regenerate-unicode-properties": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz", - "integrity": "sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA==", + "wide-align": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", + "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", "requires": { - "regenerate": "^1.4.0" + "string-width": "^1.0.2 || 2" } }, - "regenerator-runtime": { - "version": "0.13.7", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz", - "integrity": "sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew==" + "workerpool": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", + "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==" }, - "regenerator-transform": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.14.5.tgz", - "integrity": "sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw==", + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", "requires": { - "@babel/runtime": "^7.8.4" + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "requires": { + "color-convert": "^1.9.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + } } }, - "regex-not": { + "wrappy": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/regex-not/-/regex-not-1.0.2.tgz", - "integrity": "sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A==", - "optional": true, + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" + }, + "yargs": { + "version": "13.3.2", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", + "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", "requires": { - "extend-shallow": "^3.0.2", - "safe-regex": "^1.1.0" + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.2" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + } } }, - "regexpu-core": { - "version": "4.7.0", - "resolved": "https://registry.npmjs.org/regexpu-core/-/regexpu-core-4.7.0.tgz", - "integrity": "sha512-TQ4KXRnIn6tz6tjnrXEkD/sshygKH/j5KzK86X8MkeHyZ8qst/LZ89j3X4/8HEIfHANTFIP/AbXakeRhWIl5YQ==", + "yargs-parser": { + "version": "13.1.2", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", + "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", "requires": { - "regenerate": "^1.4.0", - "regenerate-unicode-properties": "^8.2.0", - "regjsgen": "^0.5.1", - "regjsparser": "^0.6.4", - "unicode-match-property-ecmascript": "^1.0.4", - "unicode-match-property-value-ecmascript": "^1.2.0" + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" } }, - "regjsgen": { - "version": "0.5.2", - "resolved": "https://registry.npmjs.org/regjsgen/-/regjsgen-0.5.2.tgz", - "integrity": "sha512-OFFT3MfrH90xIW8OOSyUrk6QHD5E9JOTeGodiJeBS3J6IwlgzJMNE/1bZklWz5oTg+9dCMyEetclvCVXOPoN3A==" - }, - "regjsparser": { - "version": "0.6.4", - "resolved": "https://registry.npmjs.org/regjsparser/-/regjsparser-0.6.4.tgz", - "integrity": "sha512-64O87/dPDgfk8/RQqC4gkZoGyyWFIEUTTh80CU6CWuK5vkCGyekIx+oKcEIYtP/RAxSQltCZHCNu/mdd7fqlJw==", + "yargs-unparser": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", + "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", "requires": { - "jsesc": "~0.5.0" + "camelcase": "^5.3.1", + "decamelize": "^1.2.0", + "flat": "^4.1.0", + "is-plain-obj": "^1.1.0", + "yargs": "^14.2.3" }, "dependencies": { - "jsesc": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-0.5.0.tgz", - "integrity": "sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0=" + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", + "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "requires": { + "p-limit": "^2.0.0" + } + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "yargs": { + "version": "14.2.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", + "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + } + }, + "yargs-parser": { + "version": "15.0.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", + "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } } } }, - "remove-trailing-separator": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz", - "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=", - "optional": true - }, - "repeat-element": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.3.tgz", - "integrity": "sha512-ahGq0ZnV5m5XtZLMb+vP76kcAM5nkLqk0lpqAuojSKGgQtn4eRi4ZZGm2olo2zKFH+sMsWaqOCW1dqAnOru72g==", - "optional": true - }, - "repeat-string": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", - "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=", - "optional": true - }, - "require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" - }, - "require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==" - }, - "resolve": { - "version": "1.17.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.17.0.tgz", - "integrity": "sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==", - "requires": { - "path-parse": "^1.0.6" - } - }, - "resolve-url": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/resolve-url/-/resolve-url-0.2.1.tgz", - "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=", - "optional": true - }, - "ret": { - "version": "0.1.15", - "resolved": "https://registry.npmjs.org/ret/-/ret-0.1.15.tgz", - "integrity": "sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==", - "optional": true - }, - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" - }, - "safe-regex": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/safe-regex/-/safe-regex-1.1.0.tgz", - "integrity": "sha1-QKNmnzsHfR6UPURinhV91IAjvy4=", - "optional": true, - "requires": { - "ret": "~0.1.10" - } + "yn": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" + } + } + }, + "@babel/code-frame": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.10.4.tgz", + "integrity": "sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==", + "requires": { + "@babel/highlight": "^7.10.4" + } + }, + "@babel/compat-data": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.11.0.tgz", + "integrity": "sha512-TPSvJfv73ng0pfnEOh17bYMPQbI95+nGWc71Ss4vZdRBHTDqmM9Z8ZV4rYz8Ks7sfzc95n30k6ODIq5UGnXcYQ==", + "requires": { + "browserslist": "^4.12.0", + "invariant": "^2.2.4", + "semver": "^5.5.0" + }, + "dependencies": { + "semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + } + } + }, + "@babel/core": { + "version": "7.9.0", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.9.0.tgz", + "integrity": "sha512-kWc7L0fw1xwvI0zi8OKVBuxRVefwGOrKSQMvrQ3dW+bIIavBY3/NpXmpjMy7bQnLgwgzWQZ8TlM57YHpHNHz4w==", + "requires": { + "@babel/code-frame": "^7.8.3", + "@babel/generator": "^7.9.0", + "@babel/helper-module-transforms": "^7.9.0", + "@babel/helpers": "^7.9.0", + "@babel/parser": "^7.9.0", + "@babel/template": "^7.8.6", + "@babel/traverse": "^7.9.0", + "@babel/types": "^7.9.0", + "convert-source-map": "^1.7.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.1", + "json5": "^2.1.2", + "lodash": "^4.17.13", + "resolve": "^1.3.2", + "semver": "^5.4.1", + "source-map": "^0.5.0" + }, + "dependencies": { + "semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" }, + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" + } + } + }, + "@babel/generator": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.11.0.tgz", + "integrity": "sha512-fEm3Uzw7Mc9Xi//qU20cBKatTfs2aOtKqmvy/Vm7RkJEGFQ4xc9myCfbXxqK//ZS8MR/ciOHw6meGASJuKmDfQ==", + "requires": { + "@babel/types": "^7.11.0", + "jsesc": "^2.5.1", + "source-map": "^0.5.0" + }, + "dependencies": { + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" + } + } + }, + "@babel/helper-annotate-as-pure": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.10.4.tgz", + "integrity": "sha512-XQlqKQP4vXFB7BN8fEEerrmYvHp3fK/rBkRFz9jaJbzK0B1DSfej9Kc7ZzE8Z/OnId1jpJdNAZ3BFQjWG68rcA==", + "requires": { + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-builder-binary-assignment-operator-visitor": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.10.4.tgz", + "integrity": "sha512-L0zGlFrGWZK4PbT8AszSfLTM5sDU1+Az/En9VrdT8/LmEiJt4zXt+Jve9DCAnQcbqDhCI+29y/L93mrDzddCcg==", + "requires": { + "@babel/helper-explode-assignable-expression": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-builder-react-jsx": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-builder-react-jsx/-/helper-builder-react-jsx-7.10.4.tgz", + "integrity": "sha512-5nPcIZ7+KKDxT1427oBivl9V9YTal7qk0diccnh7RrcgrT/pGFOjgGw1dgryyx1GvHEpXVfoDF6Ak3rTiWh8Rg==", + "requires": { + "@babel/helper-annotate-as-pure": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-builder-react-jsx-experimental": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/helper-builder-react-jsx-experimental/-/helper-builder-react-jsx-experimental-7.10.5.tgz", + "integrity": "sha512-Buewnx6M4ttG+NLkKyt7baQn7ScC/Td+e99G914fRU8fGIUivDDgVIQeDHFa5e4CRSJQt58WpNHhsAZgtzVhsg==", + "requires": { + "@babel/helper-annotate-as-pure": "^7.10.4", + "@babel/helper-module-imports": "^7.10.4", + "@babel/types": "^7.10.5" + } + }, + "@babel/helper-compilation-targets": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.10.4.tgz", + "integrity": "sha512-a3rYhlsGV0UHNDvrtOXBg8/OpfV0OKTkxKPzIplS1zpx7CygDcWWxckxZeDd3gzPzC4kUT0A4nVFDK0wGMh4MQ==", + "requires": { + "@babel/compat-data": "^7.10.4", + "browserslist": "^4.12.0", + "invariant": "^2.2.4", + "levenary": "^1.1.1", + "semver": "^5.5.0" + }, + "dependencies": { + "semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + } + } + }, + "@babel/helper-create-class-features-plugin": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.10.5.tgz", + "integrity": "sha512-0nkdeijB7VlZoLT3r/mY3bUkw3T8WG/hNw+FATs/6+pG2039IJWjTYL0VTISqsNHMUTEnwbVnc89WIJX9Qed0A==", + "requires": { + "@babel/helper-function-name": "^7.10.4", + "@babel/helper-member-expression-to-functions": "^7.10.5", + "@babel/helper-optimise-call-expression": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-replace-supers": "^7.10.4", + "@babel/helper-split-export-declaration": "^7.10.4" + } + }, + "@babel/helper-create-regexp-features-plugin": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.10.4.tgz", + "integrity": "sha512-2/hu58IEPKeoLF45DBwx3XFqsbCXmkdAay4spVr2x0jYgRxrSNp+ePwvSsy9g6YSaNDcKIQVPXk1Ov8S2edk2g==", + "requires": { + "@babel/helper-annotate-as-pure": "^7.10.4", + "@babel/helper-regex": "^7.10.4", + "regexpu-core": "^4.7.0" + } + }, + "@babel/helper-define-map": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/helper-define-map/-/helper-define-map-7.10.5.tgz", + "integrity": "sha512-fMw4kgFB720aQFXSVaXr79pjjcW5puTCM16+rECJ/plGS+zByelE8l9nCpV1GibxTnFVmUuYG9U8wYfQHdzOEQ==", + "requires": { + "@babel/helper-function-name": "^7.10.4", + "@babel/types": "^7.10.5", + "lodash": "^4.17.19" + } + }, + "@babel/helper-explode-assignable-expression": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.10.4.tgz", + "integrity": "sha512-4K71RyRQNPRrR85sr5QY4X3VwG4wtVoXZB9+L3r1Gp38DhELyHCtovqydRi7c1Ovb17eRGiQ/FD5s8JdU0Uy5A==", + "requires": { + "@babel/traverse": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-function-name": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.10.4.tgz", + "integrity": "sha512-YdaSyz1n8gY44EmN7x44zBn9zQ1Ry2Y+3GTA+3vH6Mizke1Vw0aWDM66FOYEPw8//qKkmqOckrGgTYa+6sceqQ==", + "requires": { + "@babel/helper-get-function-arity": "^7.10.4", + "@babel/template": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-get-function-arity": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-get-function-arity/-/helper-get-function-arity-7.10.4.tgz", + "integrity": "sha512-EkN3YDB+SRDgiIUnNgcmiD361ti+AVbL3f3Henf6dqqUyr5dMsorno0lJWJuLhDhkI5sYEpgj6y9kB8AOU1I2A==", + "requires": { + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-hoist-variables": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.10.4.tgz", + "integrity": "sha512-wljroF5PgCk2juF69kanHVs6vrLwIPNp6DLD+Lrl3hoQ3PpPPikaDRNFA+0t81NOoMt2DL6WW/mdU8k4k6ZzuA==", + "requires": { + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-member-expression-to-functions": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.11.0.tgz", + "integrity": "sha512-JbFlKHFntRV5qKw3YC0CvQnDZ4XMwgzzBbld7Ly4Mj4cbFy3KywcR8NtNctRToMWJOVvLINJv525Gd6wwVEx/Q==", + "requires": { + "@babel/types": "^7.11.0" + } + }, + "@babel/helper-module-imports": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.10.4.tgz", + "integrity": "sha512-nEQJHqYavI217oD9+s5MUBzk6x1IlvoS9WTPfgG43CbMEeStE0v+r+TucWdx8KFGowPGvyOkDT9+7DHedIDnVw==", + "requires": { + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-module-transforms": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.11.0.tgz", + "integrity": "sha512-02EVu8COMuTRO1TAzdMtpBPbe6aQ1w/8fePD2YgQmxZU4gpNWaL9gK3Jp7dxlkUlUCJOTaSeA+Hrm1BRQwqIhg==", + "requires": { + "@babel/helper-module-imports": "^7.10.4", + "@babel/helper-replace-supers": "^7.10.4", + "@babel/helper-simple-access": "^7.10.4", + "@babel/helper-split-export-declaration": "^7.11.0", + "@babel/template": "^7.10.4", + "@babel/types": "^7.11.0", + "lodash": "^4.17.19" + } + }, + "@babel/helper-optimise-call-expression": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.10.4.tgz", + "integrity": "sha512-n3UGKY4VXwXThEiKrgRAoVPBMqeoPgHVqiHZOanAJCG9nQUL2pLRQirUzl0ioKclHGpGqRgIOkgcIJaIWLpygg==", + "requires": { + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-plugin-utils": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz", + "integrity": "sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==" + }, + "@babel/helper-regex": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/helper-regex/-/helper-regex-7.10.5.tgz", + "integrity": "sha512-68kdUAzDrljqBrio7DYAEgCoJHxppJOERHOgOrDN7WjOzP0ZQ1LsSDRXcemzVZaLvjaJsJEESb6qt+znNuENDg==", + "requires": { + "lodash": "^4.17.19" + } + }, + "@babel/helper-remap-async-to-generator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.10.4.tgz", + "integrity": "sha512-86Lsr6NNw3qTNl+TBcF1oRZMaVzJtbWTyTko+CQL/tvNvcGYEFKbLXDPxtW0HKk3McNOk4KzY55itGWCAGK5tg==", + "requires": { + "@babel/helper-annotate-as-pure": "^7.10.4", + "@babel/helper-wrap-function": "^7.10.4", + "@babel/template": "^7.10.4", + "@babel/traverse": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-replace-supers": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-replace-supers/-/helper-replace-supers-7.10.4.tgz", + "integrity": "sha512-sPxZfFXocEymYTdVK1UNmFPBN+Hv5mJkLPsYWwGBxZAxaWfFu+xqp7b6qWD0yjNuNL2VKc6L5M18tOXUP7NU0A==", + "requires": { + "@babel/helper-member-expression-to-functions": "^7.10.4", + "@babel/helper-optimise-call-expression": "^7.10.4", + "@babel/traverse": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-simple-access": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.10.4.tgz", + "integrity": "sha512-0fMy72ej/VEvF8ULmX6yb5MtHG4uH4Dbd6I/aHDb/JVg0bbivwt9Wg+h3uMvX+QSFtwr5MeItvazbrc4jtRAXw==", + "requires": { + "@babel/template": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helper-skip-transparent-expression-wrappers": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.11.0.tgz", + "integrity": "sha512-0XIdiQln4Elglgjbwo9wuJpL/K7AGCY26kmEt0+pRP0TAj4jjyNq1MjoRvikrTVqKcx4Gysxt4cXvVFXP/JO2Q==", + "requires": { + "@babel/types": "^7.11.0" + } + }, + "@babel/helper-split-export-declaration": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.11.0.tgz", + "integrity": "sha512-74Vejvp6mHkGE+m+k5vHY93FX2cAtrw1zXrZXRlG4l410Nm9PxfEiVTn1PjDPV5SnmieiueY4AFg2xqhNFuuZg==", + "requires": { + "@babel/types": "^7.11.0" + } + }, + "@babel/helper-validator-identifier": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz", + "integrity": "sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==" + }, + "@babel/helper-wrap-function": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helper-wrap-function/-/helper-wrap-function-7.10.4.tgz", + "integrity": "sha512-6py45WvEF0MhiLrdxtRjKjufwLL1/ob2qDJgg5JgNdojBAZSAKnAjkyOCNug6n+OBl4VW76XjvgSFTdaMcW0Ug==", + "requires": { + "@babel/helper-function-name": "^7.10.4", + "@babel/template": "^7.10.4", + "@babel/traverse": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/helpers": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.10.4.tgz", + "integrity": "sha512-L2gX/XeUONeEbI78dXSrJzGdz4GQ+ZTA/aazfUsFaWjSe95kiCuOZ5HsXvkiw3iwF+mFHSRUfJU8t6YavocdXA==", + "requires": { + "@babel/template": "^7.10.4", + "@babel/traverse": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/highlight": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.10.4.tgz", + "integrity": "sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==", + "requires": { + "@babel/helper-validator-identifier": "^7.10.4", + "chalk": "^2.0.0", + "js-tokens": "^4.0.0" + } + }, + "@babel/parser": { + "version": "7.11.3", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.11.3.tgz", + "integrity": "sha512-REo8xv7+sDxkKvoxEywIdsNFiZLybwdI7hcT5uEPyQrSMB4YQ973BfC9OOrD/81MaIjh6UxdulIQXkjmiH3PcA==" + }, + "@babel/plugin-proposal-async-generator-functions": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.10.5.tgz", + "integrity": "sha512-cNMCVezQbrRGvXJwm9fu/1sJj9bHdGAgKodZdLqOQIpfoH3raqmRPBM17+lh7CzhiKRRBrGtZL9WcjxSoGYUSg==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-remap-async-to-generator": "^7.10.4", + "@babel/plugin-syntax-async-generators": "^7.8.0" + } + }, + "@babel/plugin-proposal-class-properties": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.10.4.tgz", + "integrity": "sha512-vhwkEROxzcHGNu2mzUC0OFFNXdZ4M23ib8aRRcJSsW8BZK9pQMD7QB7csl97NBbgGZO7ZyHUyKDnxzOaP4IrCg==", + "requires": { + "@babel/helper-create-class-features-plugin": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-proposal-decorators": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-decorators/-/plugin-proposal-decorators-7.8.3.tgz", + "integrity": "sha512-e3RvdvS4qPJVTe288DlXjwKflpfy1hr0j5dz5WpIYYeP7vQZg2WfAEIp8k5/Lwis/m5REXEteIz6rrcDtXXG7w==", + "requires": { + "@babel/helper-create-class-features-plugin": "^7.8.3", + "@babel/helper-plugin-utils": "^7.8.3", + "@babel/plugin-syntax-decorators": "^7.8.3" + } + }, + "@babel/plugin-proposal-dynamic-import": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.10.4.tgz", + "integrity": "sha512-up6oID1LeidOOASNXgv/CFbgBqTuKJ0cJjz6An5tWD+NVBNlp3VNSBxv2ZdU7SYl3NxJC7agAQDApZusV6uFwQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-dynamic-import": "^7.8.0" + } + }, + "@babel/plugin-proposal-export-namespace-from": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.10.4.tgz", + "integrity": "sha512-aNdf0LY6/3WXkhh0Fdb6Zk9j1NMD8ovj3F6r0+3j837Pn1S1PdNtcwJ5EG9WkVPNHPxyJDaxMaAOVq4eki0qbg==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-export-namespace-from": "^7.8.3" + } + }, + "@babel/plugin-proposal-json-strings": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.10.4.tgz", + "integrity": "sha512-fCL7QF0Jo83uy1K0P2YXrfX11tj3lkpN7l4dMv9Y9VkowkhkQDwFHFd8IiwyK5MZjE8UpbgokkgtcReH88Abaw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-json-strings": "^7.8.0" + } + }, + "@babel/plugin-proposal-logical-assignment-operators": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.11.0.tgz", + "integrity": "sha512-/f8p4z+Auz0Uaf+i8Ekf1iM7wUNLcViFUGiPxKeXvxTSl63B875YPiVdUDdem7hREcI0E0kSpEhS8tF5RphK7Q==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4" + } + }, + "@babel/plugin-proposal-nullish-coalescing-operator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.10.4.tgz", + "integrity": "sha512-wq5n1M3ZUlHl9sqT2ok1T2/MTt6AXE0e1Lz4WzWBr95LsAZ5qDXe4KnFuauYyEyLiohvXFMdbsOTMyLZs91Zlw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0" + } + }, + "@babel/plugin-proposal-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.10.4.tgz", + "integrity": "sha512-73/G7QoRoeNkLZFxsoCCvlg4ezE4eM+57PnOqgaPOozd5myfj7p0muD1mRVJvbUWbOzD+q3No2bWbaKy+DJ8DA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-numeric-separator": "^7.10.4" + } + }, + "@babel/plugin-proposal-object-rest-spread": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.11.0.tgz", + "integrity": "sha512-wzch41N4yztwoRw0ak+37wxwJM2oiIiy6huGCoqkvSTA9acYWcPfn9Y4aJqmFFJ70KTJUu29f3DQ43uJ9HXzEA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.0", + "@babel/plugin-transform-parameters": "^7.10.4" + } + }, + "@babel/plugin-proposal-optional-catch-binding": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.10.4.tgz", + "integrity": "sha512-LflT6nPh+GK2MnFiKDyLiqSqVHkQnVf7hdoAvyTnnKj9xB3docGRsdPuxp6qqqW19ifK3xgc9U5/FwrSaCNX5g==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.0" + } + }, + "@babel/plugin-proposal-optional-chaining": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.11.0.tgz", + "integrity": "sha512-v9fZIu3Y8562RRwhm1BbMRxtqZNFmFA2EG+pT2diuU8PT3H6T/KXoZ54KgYisfOFZHV6PfvAiBIZ9Rcz+/JCxA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-skip-transparent-expression-wrappers": "^7.11.0", + "@babel/plugin-syntax-optional-chaining": "^7.8.0" + } + }, + "@babel/plugin-proposal-private-methods": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.10.4.tgz", + "integrity": "sha512-wh5GJleuI8k3emgTg5KkJK6kHNsGEr0uBTDBuQUBJwckk9xs1ez79ioheEVVxMLyPscB0LfkbVHslQqIzWV6Bw==", + "requires": { + "@babel/helper-create-class-features-plugin": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-proposal-unicode-property-regex": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.10.4.tgz", + "integrity": "sha512-H+3fOgPnEXFL9zGYtKQe4IDOPKYlZdF1kqFDQRRb8PK4B8af1vAGK04tF5iQAAsui+mHNBQSAtd2/ndEDe9wuA==", + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz", + "integrity": "sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-class-properties": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.10.4.tgz", + "integrity": "sha512-GCSBF7iUle6rNugfURwNmCGG3Z/2+opxAMLs1nND4bhEG5PuxTIggDBoeYYSujAlLtsupzOHYJQgPS3pivwXIA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-decorators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-decorators/-/plugin-syntax-decorators-7.10.4.tgz", + "integrity": "sha512-2NaoC6fAk2VMdhY1eerkfHV+lVYC1u8b+jmRJISqANCJlTxYy19HGdIkkQtix2UtkcPuPu+IlDgrVseZnU03bw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-dynamic-import": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz", + "integrity": "sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-export-namespace-from": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz", + "integrity": "sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.3" + } + }, + "@babel/plugin-syntax-flow": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-flow/-/plugin-syntax-flow-7.10.4.tgz", + "integrity": "sha512-yxQsX1dJixF4qEEdzVbst3SZQ58Nrooz8NV9Z9GL4byTE25BvJgl5lf0RECUf0fh28rZBb/RYTWn/eeKwCMrZQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz", + "integrity": "sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-jsx": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.10.4.tgz", + "integrity": "sha512-KCg9mio9jwiARCB7WAcQ7Y1q+qicILjoK8LP/VkPkEKaf5dkaZZK1EcTe91a3JJlZ3qy6L5s9X52boEYi8DM9g==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz", + "integrity": "sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz", + "integrity": "sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz", + "integrity": "sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz", + "integrity": "sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz", + "integrity": "sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz", + "integrity": "sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.0" + } + }, + "@babel/plugin-syntax-top-level-await": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.10.4.tgz", + "integrity": "sha512-ni1brg4lXEmWyafKr0ccFWkJG0CeMt4WV1oyeBW6EFObF4oOHclbkj5cARxAPQyAQ2UTuplJyK4nfkXIMMFvsQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-syntax-typescript": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.10.4.tgz", + "integrity": "sha512-oSAEz1YkBCAKr5Yiq8/BNtvSAPwkp/IyUnwZogd8p+F0RuYQQrLeRUzIQhueQTTBy/F+a40uS7OFKxnkRvmvFQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-arrow-functions": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.10.4.tgz", + "integrity": "sha512-9J/oD1jV0ZCBcgnoFWFq1vJd4msoKb/TCpGNFyyLt0zABdcvgK3aYikZ8HjzB14c26bc7E3Q1yugpwGy2aTPNA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-async-to-generator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.10.4.tgz", + "integrity": "sha512-F6nREOan7J5UXTLsDsZG3DXmZSVofr2tGNwfdrVwkDWHfQckbQXnXSPfD7iO+c/2HGqycwyLST3DnZ16n+cBJQ==", + "requires": { + "@babel/helper-module-imports": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-remap-async-to-generator": "^7.10.4" + } + }, + "@babel/plugin-transform-block-scoped-functions": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.10.4.tgz", + "integrity": "sha512-WzXDarQXYYfjaV1szJvN3AD7rZgZzC1JtjJZ8dMHUyiK8mxPRahynp14zzNjU3VkPqPsO38CzxiWO1c9ARZ8JA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-block-scoping": { + "version": "7.11.1", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.11.1.tgz", + "integrity": "sha512-00dYeDE0EVEHuuM+26+0w/SCL0BH2Qy7LwHuI4Hi4MH5gkC8/AqMN5uWFJIsoXZrAphiMm1iXzBw6L2T+eA0ew==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-classes": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-classes/-/plugin-transform-classes-7.10.4.tgz", + "integrity": "sha512-2oZ9qLjt161dn1ZE0Ms66xBncQH4In8Sqw1YWgBUZuGVJJS5c0OFZXL6dP2MRHrkU/eKhWg8CzFJhRQl50rQxA==", + "requires": { + "@babel/helper-annotate-as-pure": "^7.10.4", + "@babel/helper-define-map": "^7.10.4", + "@babel/helper-function-name": "^7.10.4", + "@babel/helper-optimise-call-expression": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-replace-supers": "^7.10.4", + "@babel/helper-split-export-declaration": "^7.10.4", + "globals": "^11.1.0" + } + }, + "@babel/plugin-transform-computed-properties": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.10.4.tgz", + "integrity": "sha512-JFwVDXcP/hM/TbyzGq3l/XWGut7p46Z3QvqFMXTfk6/09m7xZHJUN9xHfsv7vqqD4YnfI5ueYdSJtXqqBLyjBw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-destructuring": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.10.4.tgz", + "integrity": "sha512-+WmfvyfsyF603iPa6825mq6Qrb7uLjTOsa3XOFzlYcYDHSS4QmpOWOL0NNBY5qMbvrcf3tq0Cw+v4lxswOBpgA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-dotall-regex": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.10.4.tgz", + "integrity": "sha512-ZEAVvUTCMlMFAbASYSVQoxIbHm2OkG2MseW6bV2JjIygOjdVv8tuxrCTzj1+Rynh7ODb8GivUy7dzEXzEhuPaA==", + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-duplicate-keys": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.10.4.tgz", + "integrity": "sha512-GL0/fJnmgMclHiBTTWXNlYjYsA7rDrtsazHG6mglaGSTh0KsrW04qml+Bbz9FL0LcJIRwBWL5ZqlNHKTkU3xAA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-exponentiation-operator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.10.4.tgz", + "integrity": "sha512-S5HgLVgkBcRdyQAHbKj+7KyuWx8C6t5oETmUuwz1pt3WTWJhsUV0WIIXuVvfXMxl/QQyHKlSCNNtaIamG8fysw==", + "requires": { + "@babel/helper-builder-binary-assignment-operator-visitor": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-flow-strip-types": { + "version": "7.9.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-flow-strip-types/-/plugin-transform-flow-strip-types-7.9.0.tgz", + "integrity": "sha512-7Qfg0lKQhEHs93FChxVLAvhBshOPQDtJUTVHr/ZwQNRccCm4O9D79r9tVSoV8iNwjP1YgfD+e/fgHcPkN1qEQg==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.3", + "@babel/plugin-syntax-flow": "^7.8.3" + } + }, + "@babel/plugin-transform-for-of": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.10.4.tgz", + "integrity": "sha512-ItdQfAzu9AlEqmusA/65TqJ79eRcgGmpPPFvBnGILXZH975G0LNjP1yjHvGgfuCxqrPPueXOPe+FsvxmxKiHHQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-function-name": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.10.4.tgz", + "integrity": "sha512-OcDCq2y5+E0dVD5MagT5X+yTRbcvFjDI2ZVAottGH6tzqjx/LKpgkUepu3hp/u4tZBzxxpNGwLsAvGBvQ2mJzg==", + "requires": { + "@babel/helper-function-name": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-literals": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-literals/-/plugin-transform-literals-7.10.4.tgz", + "integrity": "sha512-Xd/dFSTEVuUWnyZiMu76/InZxLTYilOSr1UlHV+p115Z/Le2Fi1KXkJUYz0b42DfndostYlPub3m8ZTQlMaiqQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-member-expression-literals": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.10.4.tgz", + "integrity": "sha512-0bFOvPyAoTBhtcJLr9VcwZqKmSjFml1iVxvPL0ReomGU53CX53HsM4h2SzckNdkQcHox1bpAqzxBI1Y09LlBSw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-modules-amd": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.10.5.tgz", + "integrity": "sha512-elm5uruNio7CTLFItVC/rIzKLfQ17+fX7EVz5W0TMgIHFo1zY0Ozzx+lgwhL4plzl8OzVn6Qasx5DeEFyoNiRw==", + "requires": { + "@babel/helper-module-transforms": "^7.10.5", + "@babel/helper-plugin-utils": "^7.10.4", + "babel-plugin-dynamic-import-node": "^2.3.3" + } + }, + "@babel/plugin-transform-modules-commonjs": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.10.4.tgz", + "integrity": "sha512-Xj7Uq5o80HDLlW64rVfDBhao6OX89HKUmb+9vWYaLXBZOma4gA6tw4Ni1O5qVDoZWUV0fxMYA0aYzOawz0l+1w==", + "requires": { + "@babel/helper-module-transforms": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-simple-access": "^7.10.4", + "babel-plugin-dynamic-import-node": "^2.3.3" + } + }, + "@babel/plugin-transform-modules-systemjs": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.10.5.tgz", + "integrity": "sha512-f4RLO/OL14/FP1AEbcsWMzpbUz6tssRaeQg11RH1BP/XnPpRoVwgeYViMFacnkaw4k4wjRSjn3ip1Uw9TaXuMw==", + "requires": { + "@babel/helper-hoist-variables": "^7.10.4", + "@babel/helper-module-transforms": "^7.10.5", + "@babel/helper-plugin-utils": "^7.10.4", + "babel-plugin-dynamic-import-node": "^2.3.3" + } + }, + "@babel/plugin-transform-modules-umd": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.10.4.tgz", + "integrity": "sha512-mohW5q3uAEt8T45YT7Qc5ws6mWgJAaL/8BfWD9Dodo1A3RKWli8wTS+WiQ/knF+tXlPirW/1/MqzzGfCExKECA==", + "requires": { + "@babel/helper-module-transforms": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-named-capturing-groups-regex": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.10.4.tgz", + "integrity": "sha512-V6LuOnD31kTkxQPhKiVYzYC/Jgdq53irJC/xBSmqcNcqFGV+PER4l6rU5SH2Vl7bH9mLDHcc0+l9HUOe4RNGKA==", + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.10.4" + } + }, + "@babel/plugin-transform-new-target": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.10.4.tgz", + "integrity": "sha512-YXwWUDAH/J6dlfwqlWsztI2Puz1NtUAubXhOPLQ5gjR/qmQ5U96DY4FQO8At33JN4XPBhrjB8I4eMmLROjjLjw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-object-super": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.10.4.tgz", + "integrity": "sha512-5iTw0JkdRdJvr7sY0vHqTpnruUpTea32JHmq/atIWqsnNussbRzjEDyWep8UNztt1B5IusBYg8Irb0bLbiEBCQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-replace-supers": "^7.10.4" + } + }, + "@babel/plugin-transform-parameters": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.10.5.tgz", + "integrity": "sha512-xPHwUj5RdFV8l1wuYiu5S9fqWGM2DrYc24TMvUiRrPVm+SM3XeqU9BcokQX/kEUe+p2RBwy+yoiR1w/Blq6ubw==", + "requires": { + "@babel/helper-get-function-arity": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-property-literals": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.10.4.tgz", + "integrity": "sha512-ofsAcKiUxQ8TY4sScgsGeR2vJIsfrzqvFb9GvJ5UdXDzl+MyYCaBj/FGzXuv7qE0aJcjWMILny1epqelnFlz8g==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-react-constant-elements": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.10.4.tgz", + "integrity": "sha512-cYmQBW1pXrqBte1raMkAulXmi7rjg3VI6ZLg9QIic8Hq7BtYXaWuZSxsr2siOMI6SWwpxjWfnwhTUrd7JlAV7g==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-react-display-name": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-display-name/-/plugin-transform-react-display-name-7.10.4.tgz", + "integrity": "sha512-Zd4X54Mu9SBfPGnEcaGcOrVAYOtjT2on8QZkLKEq1S/tHexG39d9XXGZv19VfRrDjPJzFmPfTAqOQS1pfFOujw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-react-jsx": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.10.4.tgz", + "integrity": "sha512-L+MfRhWjX0eI7Js093MM6MacKU4M6dnCRa/QPDwYMxjljzSCzzlzKzj9Pk4P3OtrPcxr2N3znR419nr3Xw+65A==", + "requires": { + "@babel/helper-builder-react-jsx": "^7.10.4", + "@babel/helper-builder-react-jsx-experimental": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-jsx": "^7.10.4" + } + }, + "@babel/plugin-transform-react-jsx-development": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-development/-/plugin-transform-react-jsx-development-7.10.4.tgz", + "integrity": "sha512-RM3ZAd1sU1iQ7rI2dhrZRZGv0aqzNQMbkIUCS1txYpi9wHQ2ZHNjo5TwX+UD6pvFW4AbWqLVYvKy5qJSAyRGjQ==", + "requires": { + "@babel/helper-builder-react-jsx-experimental": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-jsx": "^7.10.4" + } + }, + "@babel/plugin-transform-react-jsx-self": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.10.4.tgz", + "integrity": "sha512-yOvxY2pDiVJi0axdTWHSMi5T0DILN+H+SaeJeACHKjQLezEzhLx9nEF9xgpBLPtkZsks9cnb5P9iBEi21En3gg==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-jsx": "^7.10.4" + } + }, + "@babel/plugin-transform-react-jsx-source": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.10.5.tgz", + "integrity": "sha512-wTeqHVkN1lfPLubRiZH3o73f4rfon42HpgxUSs86Nc+8QIcm/B9s8NNVXu/gwGcOyd7yDib9ikxoDLxJP0UiDA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-jsx": "^7.10.4" + } + }, + "@babel/plugin-transform-react-pure-annotations": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-pure-annotations/-/plugin-transform-react-pure-annotations-7.10.4.tgz", + "integrity": "sha512-+njZkqcOuS8RaPakrnR9KvxjoG1ASJWpoIv/doyWngId88JoFlPlISenGXjrVacZUIALGUr6eodRs1vmPnF23A==", + "requires": { + "@babel/helper-annotate-as-pure": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-regenerator": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.10.4.tgz", + "integrity": "sha512-3thAHwtor39A7C04XucbMg17RcZ3Qppfxr22wYzZNcVIkPHfpM9J0SO8zuCV6SZa265kxBJSrfKTvDCYqBFXGw==", + "requires": { + "regenerator-transform": "^0.14.2" + } + }, + "@babel/plugin-transform-reserved-words": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.10.4.tgz", + "integrity": "sha512-hGsw1O6Rew1fkFbDImZIEqA8GoidwTAilwCyWqLBM9f+e/u/sQMQu7uX6dyokfOayRuuVfKOW4O7HvaBWM+JlQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-runtime": { + "version": "7.9.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.9.0.tgz", + "integrity": "sha512-pUu9VSf3kI1OqbWINQ7MaugnitRss1z533436waNXp+0N3ur3zfut37sXiQMxkuCF4VUjwZucen/quskCh7NHw==", + "requires": { + "@babel/helper-module-imports": "^7.8.3", + "@babel/helper-plugin-utils": "^7.8.3", + "resolve": "^1.8.1", + "semver": "^5.5.1" + }, + "dependencies": { "semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" - }, - "serialize-javascript": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", - "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", - "requires": { - "randombytes": "^2.1.0" - } - }, - "set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" - }, - "set-value": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.1.tgz", - "integrity": "sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw==", - "optional": true, - "requires": { - "extend-shallow": "^2.0.1", - "is-extendable": "^0.1.1", - "is-plain-object": "^2.0.3", - "split-string": "^3.0.1" - }, - "dependencies": { - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "optional": true, - "requires": { - "is-extendable": "^0.1.0" - } - } - } - }, - "shebang-command": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", - "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "requires": { - "shebang-regex": "^3.0.0" - } - }, - "shebang-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", - "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" - }, - "slash": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-2.0.0.tgz", - "integrity": "sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==" - }, - "snapdragon": { - "version": "0.8.2", - "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz", - "integrity": "sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg==", - "optional": true, - "requires": { - "base": "^0.11.1", - "debug": "^2.2.0", - "define-property": "^0.2.5", - "extend-shallow": "^2.0.1", - "map-cache": "^0.2.2", - "source-map": "^0.5.6", - "source-map-resolve": "^0.5.0", - "use": "^3.1.0" - }, - "dependencies": { - "define-property": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", - "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", - "optional": true, - "requires": { - "is-descriptor": "^0.1.0" - } - }, - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "optional": true, - "requires": { - "is-extendable": "^0.1.0" - } - } - } - }, - "snapdragon-node": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/snapdragon-node/-/snapdragon-node-2.1.1.tgz", - "integrity": "sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==", - "optional": true, - "requires": { - "define-property": "^1.0.0", - "isobject": "^3.0.0", - "snapdragon-util": "^3.0.1" - }, - "dependencies": { - "define-property": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", - "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", - "optional": true, - "requires": { - "is-descriptor": "^1.0.0" - } - }, - "is-accessor-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "optional": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-descriptor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", - "optional": true, - "requires": { - "is-accessor-descriptor": "^1.0.0", - "is-data-descriptor": "^1.0.0", - "kind-of": "^6.0.2" - } - } - } - }, - "snapdragon-util": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/snapdragon-util/-/snapdragon-util-3.0.1.tgz", - "integrity": "sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ==", - "optional": true, - "requires": { - "kind-of": "^3.2.0" - }, - "dependencies": { - "kind-of": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", - "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", - "optional": true, - "requires": { - "is-buffer": "^1.1.5" - } - } - } - }, - "source-map": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", - "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" - }, - "source-map-resolve": { - "version": "0.5.3", - "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.5.3.tgz", - "integrity": "sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw==", - "optional": true, - "requires": { - "atob": "^2.1.2", - "decode-uri-component": "^0.2.0", - "resolve-url": "^0.2.1", - "source-map-url": "^0.4.0", - "urix": "^0.1.0" - } - }, - "source-map-support": { - "version": "0.5.19", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", - "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", - "requires": { - "buffer-from": "^1.0.0", - "source-map": "^0.6.0" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" - } - } - }, - "source-map-url": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/source-map-url/-/source-map-url-0.4.0.tgz", - "integrity": "sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM=", - "optional": true - }, - "split": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", - "integrity": "sha1-zQ7qXmOiEd//frDwkcQTPi0N0o8=", - "requires": { - "through": "2" - } - }, - "split-string": { + } + } + }, + "@babel/plugin-transform-shorthand-properties": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.10.4.tgz", + "integrity": "sha512-AC2K/t7o07KeTIxMoHneyX90v3zkm5cjHJEokrPEAGEy3UCp8sLKfnfOIGdZ194fyN4wfX/zZUWT9trJZ0qc+Q==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-spread": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-spread/-/plugin-transform-spread-7.11.0.tgz", + "integrity": "sha512-UwQYGOqIdQJe4aWNyS7noqAnN2VbaczPLiEtln+zPowRNlD+79w3oi2TWfYe0eZgd+gjZCbsydN7lzWysDt+gw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-skip-transparent-expression-wrappers": "^7.11.0" + } + }, + "@babel/plugin-transform-sticky-regex": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.10.4.tgz", + "integrity": "sha512-Ddy3QZfIbEV0VYcVtFDCjeE4xwVTJWTmUtorAJkn6u/92Z/nWJNV+mILyqHKrUxXYKA2EoCilgoPePymKL4DvQ==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/helper-regex": "^7.10.4" + } + }, + "@babel/plugin-transform-template-literals": { + "version": "7.10.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.10.5.tgz", + "integrity": "sha512-V/lnPGIb+KT12OQikDvgSuesRX14ck5FfJXt6+tXhdkJ+Vsd0lDCVtF6jcB4rNClYFzaB2jusZ+lNISDk2mMMw==", + "requires": { + "@babel/helper-annotate-as-pure": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-typeof-symbol": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.10.4.tgz", + "integrity": "sha512-QqNgYwuuW0y0H+kUE/GWSR45t/ccRhe14Fs/4ZRouNNQsyd4o3PG4OtHiIrepbM2WKUBDAXKCAK/Lk4VhzTaGA==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-typescript": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.11.0.tgz", + "integrity": "sha512-edJsNzTtvb3MaXQwj8403B7mZoGu9ElDJQZOKjGUnvilquxBA3IQoEIOvkX/1O8xfAsnHS/oQhe2w/IXrr+w0w==", + "requires": { + "@babel/helper-create-class-features-plugin": "^7.10.5", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-syntax-typescript": "^7.10.4" + } + }, + "@babel/plugin-transform-unicode-escapes": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.10.4.tgz", + "integrity": "sha512-y5XJ9waMti2J+e7ij20e+aH+fho7Wb7W8rNuu72aKRwCHFqQdhkdU2lo3uZ9tQuboEJcUFayXdARhcxLQ3+6Fg==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/plugin-transform-unicode-regex": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.10.4.tgz", + "integrity": "sha512-wNfsc4s8N2qnIwpO/WP2ZiSyjfpTamT2C9V9FDH/Ljub9zw6P3SjkXcFmc0RQUt96k2fmIvtla2MMjgTwIAC+A==", + "requires": { + "@babel/helper-create-regexp-features-plugin": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4" + } + }, + "@babel/preset-env": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.11.0.tgz", + "integrity": "sha512-2u1/k7rG/gTh02dylX2kL3S0IJNF+J6bfDSp4DI2Ma8QN6Y9x9pmAax59fsCk6QUQG0yqH47yJWA+u1I1LccAg==", + "requires": { + "@babel/compat-data": "^7.11.0", + "@babel/helper-compilation-targets": "^7.10.4", + "@babel/helper-module-imports": "^7.10.4", + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-proposal-async-generator-functions": "^7.10.4", + "@babel/plugin-proposal-class-properties": "^7.10.4", + "@babel/plugin-proposal-dynamic-import": "^7.10.4", + "@babel/plugin-proposal-export-namespace-from": "^7.10.4", + "@babel/plugin-proposal-json-strings": "^7.10.4", + "@babel/plugin-proposal-logical-assignment-operators": "^7.11.0", + "@babel/plugin-proposal-nullish-coalescing-operator": "^7.10.4", + "@babel/plugin-proposal-numeric-separator": "^7.10.4", + "@babel/plugin-proposal-object-rest-spread": "^7.11.0", + "@babel/plugin-proposal-optional-catch-binding": "^7.10.4", + "@babel/plugin-proposal-optional-chaining": "^7.11.0", + "@babel/plugin-proposal-private-methods": "^7.10.4", + "@babel/plugin-proposal-unicode-property-regex": "^7.10.4", + "@babel/plugin-syntax-async-generators": "^7.8.0", + "@babel/plugin-syntax-class-properties": "^7.10.4", + "@babel/plugin-syntax-dynamic-import": "^7.8.0", + "@babel/plugin-syntax-export-namespace-from": "^7.8.3", + "@babel/plugin-syntax-json-strings": "^7.8.0", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.0", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.0", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.0", + "@babel/plugin-syntax-optional-chaining": "^7.8.0", + "@babel/plugin-syntax-top-level-await": "^7.10.4", + "@babel/plugin-transform-arrow-functions": "^7.10.4", + "@babel/plugin-transform-async-to-generator": "^7.10.4", + "@babel/plugin-transform-block-scoped-functions": "^7.10.4", + "@babel/plugin-transform-block-scoping": "^7.10.4", + "@babel/plugin-transform-classes": "^7.10.4", + "@babel/plugin-transform-computed-properties": "^7.10.4", + "@babel/plugin-transform-destructuring": "^7.10.4", + "@babel/plugin-transform-dotall-regex": "^7.10.4", + "@babel/plugin-transform-duplicate-keys": "^7.10.4", + "@babel/plugin-transform-exponentiation-operator": "^7.10.4", + "@babel/plugin-transform-for-of": "^7.10.4", + "@babel/plugin-transform-function-name": "^7.10.4", + "@babel/plugin-transform-literals": "^7.10.4", + "@babel/plugin-transform-member-expression-literals": "^7.10.4", + "@babel/plugin-transform-modules-amd": "^7.10.4", + "@babel/plugin-transform-modules-commonjs": "^7.10.4", + "@babel/plugin-transform-modules-systemjs": "^7.10.4", + "@babel/plugin-transform-modules-umd": "^7.10.4", + "@babel/plugin-transform-named-capturing-groups-regex": "^7.10.4", + "@babel/plugin-transform-new-target": "^7.10.4", + "@babel/plugin-transform-object-super": "^7.10.4", + "@babel/plugin-transform-parameters": "^7.10.4", + "@babel/plugin-transform-property-literals": "^7.10.4", + "@babel/plugin-transform-regenerator": "^7.10.4", + "@babel/plugin-transform-reserved-words": "^7.10.4", + "@babel/plugin-transform-shorthand-properties": "^7.10.4", + "@babel/plugin-transform-spread": "^7.11.0", + "@babel/plugin-transform-sticky-regex": "^7.10.4", + "@babel/plugin-transform-template-literals": "^7.10.4", + "@babel/plugin-transform-typeof-symbol": "^7.10.4", + "@babel/plugin-transform-unicode-escapes": "^7.10.4", + "@babel/plugin-transform-unicode-regex": "^7.10.4", + "@babel/preset-modules": "^0.1.3", + "@babel/types": "^7.11.0", + "browserslist": "^4.12.0", + "core-js-compat": "^3.6.2", + "invariant": "^2.2.2", + "levenary": "^1.1.1", + "semver": "^5.5.0" + }, + "dependencies": { + "semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + } + } + }, + "@babel/preset-modules": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@babel/preset-modules/-/preset-modules-0.1.3.tgz", + "integrity": "sha512-Ra3JXOHBq2xd56xSF7lMKXdjBn3T772Y1Wet3yWnkDly9zHvJki029tAFzvAAK5cf4YV3yoxuP61crYRol6SVg==", + "requires": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/plugin-proposal-unicode-property-regex": "^7.4.4", + "@babel/plugin-transform-dotall-regex": "^7.4.4", + "@babel/types": "^7.4.4", + "esutils": "^2.0.2" + } + }, + "@babel/preset-react": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/preset-react/-/preset-react-7.10.4.tgz", + "integrity": "sha512-BrHp4TgOIy4M19JAfO1LhycVXOPWdDbTRep7eVyatf174Hff+6Uk53sDyajqZPu8W1qXRBiYOfIamek6jA7YVw==", + "requires": { + "@babel/helper-plugin-utils": "^7.10.4", + "@babel/plugin-transform-react-display-name": "^7.10.4", + "@babel/plugin-transform-react-jsx": "^7.10.4", + "@babel/plugin-transform-react-jsx-development": "^7.10.4", + "@babel/plugin-transform-react-jsx-self": "^7.10.4", + "@babel/plugin-transform-react-jsx-source": "^7.10.4", + "@babel/plugin-transform-react-pure-annotations": "^7.10.4" + } + }, + "@babel/preset-typescript": { + "version": "7.9.0", + "resolved": "https://registry.npmjs.org/@babel/preset-typescript/-/preset-typescript-7.9.0.tgz", + "integrity": "sha512-S4cueFnGrIbvYJgwsVFKdvOmpiL0XGw9MFW9D0vgRys5g36PBhZRL8NX8Gr2akz8XRtzq6HuDXPD/1nniagNUg==", + "requires": { + "@babel/helper-plugin-utils": "^7.8.3", + "@babel/plugin-transform-typescript": "^7.9.0" + } + }, + "@babel/runtime": { + "version": "7.11.2", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.11.2.tgz", + "integrity": "sha512-TeWkU52so0mPtDcaCTxNBI/IHiz0pZgr8VEFqXFtZWpYD08ZB6FaSwVAS8MKRQAP3bYKiVjwysOJgMFY28o6Tw==", + "requires": { + "regenerator-runtime": "^0.13.4" + } + }, + "@babel/runtime-corejs3": { + "version": "7.11.2", + "resolved": "https://registry.npmjs.org/@babel/runtime-corejs3/-/runtime-corejs3-7.11.2.tgz", + "integrity": "sha512-qh5IR+8VgFz83VBa6OkaET6uN/mJOhHONuy3m1sgF0CV6mXdPSEBdA7e1eUbVvyNtANjMbg22JUv71BaDXLY6A==", + "requires": { + "core-js-pure": "^3.0.0", + "regenerator-runtime": "^0.13.4" + } + }, + "@babel/template": { + "version": "7.10.4", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.10.4.tgz", + "integrity": "sha512-ZCjD27cGJFUB6nmCB1Enki3r+L5kJveX9pq1SvAUKoICy6CZ9yD8xO086YXdYhvNjBdnekm4ZnaP5yC8Cs/1tA==", + "requires": { + "@babel/code-frame": "^7.10.4", + "@babel/parser": "^7.10.4", + "@babel/types": "^7.10.4" + } + }, + "@babel/traverse": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.11.0.tgz", + "integrity": "sha512-ZB2V+LskoWKNpMq6E5UUCrjtDUh5IOTAyIl0dTjIEoXum/iKWkoIEKIRDnUucO6f+2FzNkE0oD4RLKoPIufDtg==", + "requires": { + "@babel/code-frame": "^7.10.4", + "@babel/generator": "^7.11.0", + "@babel/helper-function-name": "^7.10.4", + "@babel/helper-split-export-declaration": "^7.11.0", + "@babel/parser": "^7.11.0", + "@babel/types": "^7.11.0", + "debug": "^4.1.0", + "globals": "^11.1.0", + "lodash": "^4.17.19" + } + }, + "@babel/types": { + "version": "7.11.0", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.11.0.tgz", + "integrity": "sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA==", + "requires": { + "@babel/helper-validator-identifier": "^7.10.4", + "lodash": "^4.17.19", + "to-fast-properties": "^2.0.0" + } + }, + "@cnakazawa/watch": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@cnakazawa/watch/-/watch-1.0.4.tgz", + "integrity": "sha512-v9kIhKwjeZThiWrLmj0y17CWoyddASLj9O2yvbZkbvw/N3rWOYy9zkV66ursAoVr0mV15bL8g0c4QZUE6cdDoQ==", + "requires": { + "exec-sh": "^0.3.2", + "minimist": "^1.2.0" + } + }, + "@csstools/convert-colors": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/@csstools/convert-colors/-/convert-colors-1.4.0.tgz", + "integrity": "sha512-5a6wqoJV/xEdbRNKVo6I4hO3VjyDq//8q2f9I6PBAvMesJHFauXDorcNCsr9RzvsZnaWi5NYCcfyqP1QeFHFbw==" + }, + "@csstools/normalize.css": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/@csstools/normalize.css/-/normalize.css-10.1.0.tgz", + "integrity": "sha512-ij4wRiunFfaJxjB0BdrYHIH8FxBJpOwNPhhAcunlmPdXudL1WQV1qoP9un6JsEBAgQH+7UXyyjh0g7jTxXK6tg==" + }, + "@hapi/address": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@hapi/address/-/address-2.1.4.tgz", + "integrity": "sha512-QD1PhQk+s31P1ixsX0H0Suoupp3VMXzIVMSwobR3F3MSUO2YCV0B7xqLcUw/Bh8yuvd3LhpyqLQWTNcRmp6IdQ==" + }, + "@hapi/bourne": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@hapi/bourne/-/bourne-1.3.2.tgz", + "integrity": "sha512-1dVNHT76Uu5N3eJNTYcvxee+jzX4Z9lfciqRRHCU27ihbUcYi+iSc2iml5Ke1LXe1SyJCLA0+14Jh4tXJgOppA==" + }, + "@hapi/hoek": { + "version": "8.5.1", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-8.5.1.tgz", + "integrity": "sha512-yN7kbciD87WzLGc5539Tn0sApjyiGHAJgKvG9W8C7O+6c7qmoQMfVs0W4bX17eqz6C78QJqqFrtgdK5EWf6Qow==" + }, + "@hapi/joi": { + "version": "15.1.1", + "resolved": "https://registry.npmjs.org/@hapi/joi/-/joi-15.1.1.tgz", + "integrity": "sha512-entf8ZMOK8sc+8YfeOlM8pCfg3b5+WZIKBfUaaJT8UsjAAPjartzxIYm3TIbjvA4u+u++KbcXD38k682nVHDAQ==", + "requires": { + "@hapi/address": "2.x.x", + "@hapi/bourne": "1.x.x", + "@hapi/hoek": "8.x.x", + "@hapi/topo": "3.x.x" + } + }, + "@hapi/topo": { + "version": "3.1.6", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-3.1.6.tgz", + "integrity": "sha512-tAag0jEcjwH+P2quUfipd7liWCNX2F8NvYjQp2wtInsZxnMlypdw0FtAOLxtvvkO+GSRRbmNi8m/5y42PQJYCQ==", + "requires": { + "@hapi/hoek": "^8.3.0" + } + }, + "@jest/console": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/console/-/console-24.9.0.tgz", + "integrity": "sha512-Zuj6b8TnKXi3q4ymac8EQfc3ea/uhLeCGThFqXeC8H9/raaH8ARPUTdId+XyGd03Z4In0/VjD2OYFcBF09fNLQ==", + "requires": { + "@jest/source-map": "^24.9.0", + "chalk": "^2.0.1", + "slash": "^2.0.0" + } + }, + "@jest/core": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/core/-/core-24.9.0.tgz", + "integrity": "sha512-Fogg3s4wlAr1VX7q+rhV9RVnUv5tD7VuWfYy1+whMiWUrvl7U3QJSJyWcDio9Lq2prqYsZaeTv2Rz24pWGkJ2A==", + "requires": { + "@jest/console": "^24.7.1", + "@jest/reporters": "^24.9.0", + "@jest/test-result": "^24.9.0", + "@jest/transform": "^24.9.0", + "@jest/types": "^24.9.0", + "ansi-escapes": "^3.0.0", + "chalk": "^2.0.1", + "exit": "^0.1.2", + "graceful-fs": "^4.1.15", + "jest-changed-files": "^24.9.0", + "jest-config": "^24.9.0", + "jest-haste-map": "^24.9.0", + "jest-message-util": "^24.9.0", + "jest-regex-util": "^24.3.0", + "jest-resolve": "^24.9.0", + "jest-resolve-dependencies": "^24.9.0", + "jest-runner": "^24.9.0", + "jest-runtime": "^24.9.0", + "jest-snapshot": "^24.9.0", + "jest-util": "^24.9.0", + "jest-validate": "^24.9.0", + "jest-watcher": "^24.9.0", + "micromatch": "^3.1.10", + "p-each-series": "^1.0.0", + "realpath-native": "^1.1.0", + "rimraf": "^2.5.4", + "slash": "^2.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-escapes": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.2.0.tgz", + "integrity": "sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==" + } + } + }, + "@jest/environment": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-24.9.0.tgz", + "integrity": "sha512-5A1QluTPhvdIPFYnO3sZC3smkNeXPVELz7ikPbhUj0bQjB07EoE9qtLrem14ZUYWdVayYbsjVwIiL4WBIMV4aQ==", + "requires": { + "@jest/fake-timers": "^24.9.0", + "@jest/transform": "^24.9.0", + "@jest/types": "^24.9.0", + "jest-mock": "^24.9.0" + } + }, + "@jest/fake-timers": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-24.9.0.tgz", + "integrity": "sha512-eWQcNa2YSwzXWIMC5KufBh3oWRIijrQFROsIqt6v/NS9Io/gknw1jsAC9c+ih/RQX4A3O7SeWAhQeN0goKhT9A==", + "requires": { + "@jest/types": "^24.9.0", + "jest-message-util": "^24.9.0", + "jest-mock": "^24.9.0" + } + }, + "@jest/reporters": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-24.9.0.tgz", + "integrity": "sha512-mu4X0yjaHrffOsWmVLzitKmmmWSQ3GGuefgNscUSWNiUNcEOSEQk9k3pERKEQVBb0Cnn88+UESIsZEMH3o88Gw==", + "requires": { + "@jest/environment": "^24.9.0", + "@jest/test-result": "^24.9.0", + "@jest/transform": "^24.9.0", + "@jest/types": "^24.9.0", + "chalk": "^2.0.1", + "exit": "^0.1.2", + "glob": "^7.1.2", + "istanbul-lib-coverage": "^2.0.2", + "istanbul-lib-instrument": "^3.0.1", + "istanbul-lib-report": "^2.0.4", + "istanbul-lib-source-maps": "^3.0.1", + "istanbul-reports": "^2.2.6", + "jest-haste-map": "^24.9.0", + "jest-resolve": "^24.9.0", + "jest-runtime": "^24.9.0", + "jest-util": "^24.9.0", + "jest-worker": "^24.6.0", + "node-notifier": "^5.4.2", + "slash": "^2.0.0", + "source-map": "^0.6.0", + "string-length": "^2.0.0" + } + }, + "@jest/source-map": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-24.9.0.tgz", + "integrity": "sha512-/Xw7xGlsZb4MJzNDgB7PW5crou5JqWiBQaz6xyPd3ArOg2nfn/PunV8+olXbbEZzNl591o5rWKE9BRDaFAuIBg==", + "requires": { + "callsites": "^3.0.0", + "graceful-fs": "^4.1.15", + "source-map": "^0.6.0" + }, + "dependencies": { + "callsites": { "version": "3.1.0", - "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", - "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", - "optional": true, - "requires": { - "extend-shallow": "^3.0.0" - } - }, - "sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" - }, - "static-extend": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/static-extend/-/static-extend-0.1.2.tgz", - "integrity": "sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY=", - "optional": true, + "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", + "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==" + } + } + }, + "@jest/test-result": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-24.9.0.tgz", + "integrity": "sha512-XEFrHbBonBJ8dGp2JmF8kP/nQI/ImPpygKHwQ/SY+es59Z3L5PI4Qb9TQQMAEeYsThG1xF0k6tmG0tIKATNiiA==", + "requires": { + "@jest/console": "^24.9.0", + "@jest/types": "^24.9.0", + "@types/istanbul-lib-coverage": "^2.0.0" + } + }, + "@jest/test-sequencer": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/test-sequencer/-/test-sequencer-24.9.0.tgz", + "integrity": "sha512-6qqsU4o0kW1dvA95qfNog8v8gkRN9ph6Lz7r96IvZpHdNipP2cBcb07J1Z45mz/VIS01OHJ3pY8T5fUY38tg4A==", + "requires": { + "@jest/test-result": "^24.9.0", + "jest-haste-map": "^24.9.0", + "jest-runner": "^24.9.0", + "jest-runtime": "^24.9.0" + } + }, + "@jest/transform": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/transform/-/transform-24.9.0.tgz", + "integrity": "sha512-TcQUmyNRxV94S0QpMOnZl0++6RMiqpbH/ZMccFB/amku6Uwvyb1cjYX7xkp5nGNkbX4QPH/FcB6q1HBTHynLmQ==", + "requires": { + "@babel/core": "^7.1.0", + "@jest/types": "^24.9.0", + "babel-plugin-istanbul": "^5.1.0", + "chalk": "^2.0.1", + "convert-source-map": "^1.4.0", + "fast-json-stable-stringify": "^2.0.0", + "graceful-fs": "^4.1.15", + "jest-haste-map": "^24.9.0", + "jest-regex-util": "^24.9.0", + "jest-util": "^24.9.0", + "micromatch": "^3.1.10", + "pirates": "^4.0.1", + "realpath-native": "^1.1.0", + "slash": "^2.0.0", + "source-map": "^0.6.1", + "write-file-atomic": "2.4.1" + } + }, + "@jest/types": { + "version": "24.9.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-24.9.0.tgz", + "integrity": "sha512-XKK7ze1apu5JWQ5eZjHITP66AX+QsLlbaJRBGYr8pNzwcAE2JVkwnf0yqjHTsDRcjR0mujy/NmZMXw5kl+kGBw==", + "requires": { + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^1.1.1", + "@types/yargs": "^13.0.0" + } + }, + "@mrmlnc/readdir-enhanced": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz", + "integrity": "sha512-bPHp6Ji8b41szTOcaP63VlnbbO5Ny6dwAATtY6JTjh5N2OLrb5Qk/Th5cRkRQhkWCt+EJsYrNB0MiL+Gpn6e3g==", + "requires": { + "call-me-maybe": "^1.0.1", + "glob-to-regexp": "^0.3.0" + } + }, + "@nodelib/fs.stat": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-1.1.3.tgz", + "integrity": "sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw==" + }, + "@sheerun/mutationobserver-shim": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/@sheerun/mutationobserver-shim/-/mutationobserver-shim-0.3.3.tgz", + "integrity": "sha512-DetpxZw1fzPD5xUBrIAoplLChO2VB8DlL5Gg+I1IR9b2wPqYIca2WSUxL5g1vLeR4MsQq1NeWriXAVffV+U1Fw==" + }, + "@svgr/babel-plugin-add-jsx-attribute": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-add-jsx-attribute/-/babel-plugin-add-jsx-attribute-4.2.0.tgz", + "integrity": "sha512-j7KnilGyZzYr/jhcrSYS3FGWMZVaqyCG0vzMCwzvei0coIkczuYMcniK07nI0aHJINciujjH11T72ICW5eL5Ig==" + }, + "@svgr/babel-plugin-remove-jsx-attribute": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-attribute/-/babel-plugin-remove-jsx-attribute-4.2.0.tgz", + "integrity": "sha512-3XHLtJ+HbRCH4n28S7y/yZoEQnRpl0tvTZQsHqvaeNXPra+6vE5tbRliH3ox1yZYPCxrlqaJT/Mg+75GpDKlvQ==" + }, + "@svgr/babel-plugin-remove-jsx-empty-expression": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-remove-jsx-empty-expression/-/babel-plugin-remove-jsx-empty-expression-4.2.0.tgz", + "integrity": "sha512-yTr2iLdf6oEuUE9MsRdvt0NmdpMBAkgK8Bjhl6epb+eQWk6abBaX3d65UZ3E3FWaOwePyUgNyNCMVG61gGCQ7w==" + }, + "@svgr/babel-plugin-replace-jsx-attribute-value": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-replace-jsx-attribute-value/-/babel-plugin-replace-jsx-attribute-value-4.2.0.tgz", + "integrity": "sha512-U9m870Kqm0ko8beHawRXLGLvSi/ZMrl89gJ5BNcT452fAjtF2p4uRzXkdzvGJJJYBgx7BmqlDjBN/eCp5AAX2w==" + }, + "@svgr/babel-plugin-svg-dynamic-title": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-dynamic-title/-/babel-plugin-svg-dynamic-title-4.3.3.tgz", + "integrity": "sha512-w3Be6xUNdwgParsvxkkeZb545VhXEwjGMwExMVBIdPQJeyMQHqm9Msnb2a1teHBqUYL66qtwfhNkbj1iarCG7w==" + }, + "@svgr/babel-plugin-svg-em-dimensions": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-svg-em-dimensions/-/babel-plugin-svg-em-dimensions-4.2.0.tgz", + "integrity": "sha512-C0Uy+BHolCHGOZ8Dnr1zXy/KgpBOkEUYY9kI/HseHVPeMbluaX3CijJr7D4C5uR8zrc1T64nnq/k63ydQuGt4w==" + }, + "@svgr/babel-plugin-transform-react-native-svg": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-react-native-svg/-/babel-plugin-transform-react-native-svg-4.2.0.tgz", + "integrity": "sha512-7YvynOpZDpCOUoIVlaaOUU87J4Z6RdD6spYN4eUb5tfPoKGSF9OG2NuhgYnq4jSkAxcpMaXWPf1cePkzmqTPNw==" + }, + "@svgr/babel-plugin-transform-svg-component": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@svgr/babel-plugin-transform-svg-component/-/babel-plugin-transform-svg-component-4.2.0.tgz", + "integrity": "sha512-hYfYuZhQPCBVotABsXKSCfel2slf/yvJY8heTVX1PCTaq/IgASq1IyxPPKJ0chWREEKewIU/JMSsIGBtK1KKxw==" + }, + "@svgr/babel-preset": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@svgr/babel-preset/-/babel-preset-4.3.3.tgz", + "integrity": "sha512-6PG80tdz4eAlYUN3g5GZiUjg2FMcp+Wn6rtnz5WJG9ITGEF1pmFdzq02597Hn0OmnQuCVaBYQE1OVFAnwOl+0A==", + "requires": { + "@svgr/babel-plugin-add-jsx-attribute": "^4.2.0", + "@svgr/babel-plugin-remove-jsx-attribute": "^4.2.0", + "@svgr/babel-plugin-remove-jsx-empty-expression": "^4.2.0", + "@svgr/babel-plugin-replace-jsx-attribute-value": "^4.2.0", + "@svgr/babel-plugin-svg-dynamic-title": "^4.3.3", + "@svgr/babel-plugin-svg-em-dimensions": "^4.2.0", + "@svgr/babel-plugin-transform-react-native-svg": "^4.2.0", + "@svgr/babel-plugin-transform-svg-component": "^4.2.0" + } + }, + "@svgr/core": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@svgr/core/-/core-4.3.3.tgz", + "integrity": "sha512-qNuGF1QON1626UCaZamWt5yedpgOytvLj5BQZe2j1k1B8DUG4OyugZyfEwBeXozCUwhLEpsrgPrE+eCu4fY17w==", + "requires": { + "@svgr/plugin-jsx": "^4.3.3", + "camelcase": "^5.3.1", + "cosmiconfig": "^5.2.1" + } + }, + "@svgr/hast-util-to-babel-ast": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/@svgr/hast-util-to-babel-ast/-/hast-util-to-babel-ast-4.3.2.tgz", + "integrity": "sha512-JioXclZGhFIDL3ddn4Kiq8qEqYM2PyDKV0aYno8+IXTLuYt6TOgHUbUAAFvqtb0Xn37NwP0BTHglejFoYr8RZg==", + "requires": { + "@babel/types": "^7.4.4" + } + }, + "@svgr/plugin-jsx": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@svgr/plugin-jsx/-/plugin-jsx-4.3.3.tgz", + "integrity": "sha512-cLOCSpNWQnDB1/v+SUENHH7a0XY09bfuMKdq9+gYvtuwzC2rU4I0wKGFEp1i24holdQdwodCtDQdFtJiTCWc+w==", + "requires": { + "@babel/core": "^7.4.5", + "@svgr/babel-preset": "^4.3.3", + "@svgr/hast-util-to-babel-ast": "^4.3.2", + "svg-parser": "^2.0.0" + } + }, + "@svgr/plugin-svgo": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/@svgr/plugin-svgo/-/plugin-svgo-4.3.1.tgz", + "integrity": "sha512-PrMtEDUWjX3Ea65JsVCwTIXuSqa3CG9px+DluF1/eo9mlDrgrtFE7NE/DjdhjJgSM9wenlVBzkzneSIUgfUI/w==", + "requires": { + "cosmiconfig": "^5.2.1", + "merge-deep": "^3.0.2", + "svgo": "^1.2.2" + } + }, + "@svgr/webpack": { + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@svgr/webpack/-/webpack-4.3.3.tgz", + "integrity": "sha512-bjnWolZ6KVsHhgyCoYRFmbd26p8XVbulCzSG53BDQqAr+JOAderYK7CuYrB3bDjHJuF6LJ7Wrr42+goLRV9qIg==", + "requires": { + "@babel/core": "^7.4.5", + "@babel/plugin-transform-react-constant-elements": "^7.0.0", + "@babel/preset-env": "^7.4.5", + "@babel/preset-react": "^7.0.0", + "@svgr/core": "^4.3.3", + "@svgr/plugin-jsx": "^4.3.3", + "@svgr/plugin-svgo": "^4.3.1", + "loader-utils": "^1.2.3" + } + }, + "@testing-library/dom": { + "version": "6.16.0", + "resolved": "https://registry.npmjs.org/@testing-library/dom/-/dom-6.16.0.tgz", + "integrity": "sha512-lBD88ssxqEfz0wFL6MeUyyWZfV/2cjEZZV3YRpb2IoJRej/4f1jB0TzqIOznTpfR1r34CNesrubxwIlAQ8zgPA==", + "requires": { + "@babel/runtime": "^7.8.4", + "@sheerun/mutationobserver-shim": "^0.3.2", + "@types/testing-library__dom": "^6.12.1", + "aria-query": "^4.0.2", + "dom-accessibility-api": "^0.3.0", + "pretty-format": "^25.1.0", + "wait-for-expect": "^3.0.2" + }, + "dependencies": { + "@jest/types": { + "version": "25.5.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-25.5.0.tgz", + "integrity": "sha512-OXD0RgQ86Tu3MazKo8bnrkDRaDXXMGUqd+kTtLtK1Zb7CRzQcaSRPPPV37SvYTdevXEBVxe0HXylEjs8ibkmCw==", "requires": { - "define-property": "^0.2.5", - "object-copy": "^0.1.0" - }, - "dependencies": { - "define-property": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", - "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", - "optional": true, - "requires": { - "is-descriptor": "^0.1.0" - } - } + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^1.1.1", + "@types/yargs": "^15.0.0", + "chalk": "^3.0.0" } }, - "stream-combiner": { - "version": "0.0.4", - "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", - "integrity": "sha1-TV5DPBhSYd3mI8o/RMWGvPXErRQ=", + "@types/yargs": { + "version": "15.0.5", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-15.0.5.tgz", + "integrity": "sha512-Dk/IDOPtOgubt/IaevIUbTgV7doaKkoorvOyYM2CMwuDyP89bekI7H4xLIwunNYiK9jhCkmc6pUrJk3cj2AB9w==", "requires": { - "duplexer": "~0.1.1" + "@types/yargs-parser": "*" } }, - "string-argv": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/string-argv/-/string-argv-0.1.2.tgz", - "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==" + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "requires": { - "ansi-regex": "^3.0.0" - } - } + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" } }, - "string.prototype.trimend": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", - "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", + "chalk": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", + "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.5" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, - "string.prototype.trimstart": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", - "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.5" + "color-name": "~1.1.4" } }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "optional": true, - "requires": { - "safe-buffer": "~5.1.0" - } + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" }, - "strip-ansi": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", - "integrity": "sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w==", + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" + }, + "pretty-format": { + "version": "25.5.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-25.5.0.tgz", + "integrity": "sha512-kbo/kq2LQ/A/is0PQwsEHM7Ca6//bGPPvU6UnsdDRSKTWxT/ru/xb88v4BJf6a69H+uTytOEsTusT9ksd/1iWQ==", "requires": { - "ansi-regex": "^5.0.0" + "@jest/types": "^25.5.0", + "ansi-regex": "^5.0.0", + "ansi-styles": "^4.0.0", + "react-is": "^16.12.0" } }, - "strip-json-comments": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", - "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==" - }, "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", "requires": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" } - }, - "through": { - "version": "2.3.8", - "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", - "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=" - }, - "to-fast-properties": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", - "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=" - }, - "to-object-path": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/to-object-path/-/to-object-path-0.3.0.tgz", - "integrity": "sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68=", - "optional": true, + } + } + }, + "@testing-library/jest-dom": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/@testing-library/jest-dom/-/jest-dom-4.2.4.tgz", + "integrity": "sha512-j31Bn0rQo12fhCWOUWy9fl7wtqkp7In/YP2p5ZFyRuiiB9Qs3g+hS4gAmDWONbAHcRmVooNJ5eOHQDCOmUFXHg==", + "requires": { + "@babel/runtime": "^7.5.1", + "chalk": "^2.4.1", + "css": "^2.2.3", + "css.escape": "^1.5.1", + "jest-diff": "^24.0.0", + "jest-matcher-utils": "^24.0.0", + "lodash": "^4.17.11", + "pretty-format": "^24.0.0", + "redent": "^3.0.0" + } + }, + "@testing-library/react": { + "version": "9.5.0", + "resolved": "https://registry.npmjs.org/@testing-library/react/-/react-9.5.0.tgz", + "integrity": "sha512-di1b+D0p+rfeboHO5W7gTVeZDIK5+maEgstrZbWZSSvxDyfDRkkyBE1AJR5Psd6doNldluXlCWqXriUfqu/9Qg==", + "requires": { + "@babel/runtime": "^7.8.4", + "@testing-library/dom": "^6.15.0", + "@types/testing-library__react": "^9.1.2" + } + }, + "@testing-library/user-event": { + "version": "7.2.1", + "resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-7.2.1.tgz", + "integrity": "sha512-oZ0Ib5I4Z2pUEcoo95cT1cr6slco9WY7yiPpG+RGNkj8YcYgJnM7pXmYmorNOReh8MIGcKSqXyeGjxnr8YiZbA==" + }, + "@types/babel__core": { + "version": "7.1.9", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.1.9.tgz", + "integrity": "sha512-sY2RsIJ5rpER1u3/aQ8OFSI7qGIy8o1NEEbgb2UaJcvOtXOMpd39ko723NBpjQFg9SIX7TXtjejZVGeIMLhoOw==", + "requires": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "@types/babel__generator": { + "version": "7.6.1", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.6.1.tgz", + "integrity": "sha512-bBKm+2VPJcMRVwNhxKu8W+5/zT7pwNEqeokFOmbvVSqGzFneNxYcEBro9Ac7/N9tlsaPYnZLK8J1LWKkMsLAew==", + "requires": { + "@babel/types": "^7.0.0" + } + }, + "@types/babel__template": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.0.2.tgz", + "integrity": "sha512-/K6zCpeW7Imzgab2bLkLEbz0+1JlFSrUMdw7KoIIu+IUdu51GWaBZpd3y1VXGVXzynvGa4DaIaxNZHiON3GXUg==", + "requires": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "@types/babel__traverse": { + "version": "7.0.13", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.0.13.tgz", + "integrity": "sha512-i+zS7t6/s9cdQvbqKDARrcbrPvtJGlbYsMkazo03nTAK3RX9FNrLllXys22uiTGJapPOTZTQ35nHh4ISph4SLQ==", + "requires": { + "@babel/types": "^7.3.0" + } + }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==" + }, + "@types/eslint-visitor-keys": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@types/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz", + "integrity": "sha512-OCutwjDZ4aFS6PB1UZ988C4YgwlBHJd6wCeQqaLdmadZ/7e+w79+hbMUFC1QXDNCmdyoRfAFdm0RypzwR+Qpag==" + }, + "@types/glob": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/@types/glob/-/glob-7.1.3.tgz", + "integrity": "sha512-SEYeGAIQIQX8NN6LDKprLjbrd5dARM5EXsd8GI/A5l0apYI1fGMWgPHSe4ZKL4eozlAyI+doUE9XbYS4xCkQ1w==", + "requires": { + "@types/minimatch": "*", + "@types/node": "*" + } + }, + "@types/istanbul-lib-coverage": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.3.tgz", + "integrity": "sha512-sz7iLqvVUg1gIedBOvlkxPlc8/uVzyS5OwGz1cKjXzkl3FpL3al0crU8YGU1WoHkxn0Wxbw5tyi6hvzJKNzFsw==" + }, + "@types/istanbul-lib-report": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz", + "integrity": "sha512-plGgXAPfVKFoYfa9NpYDAkseG+g6Jr294RqeqcqDixSbU34MZVJRi/P+7Y8GDpzkEwLaGZZOpKIEmeVZNtKsrg==", + "requires": { + "@types/istanbul-lib-coverage": "*" + } + }, + "@types/istanbul-reports": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-1.1.2.tgz", + "integrity": "sha512-P/W9yOX/3oPZSpaYOCQzGqgCQRXn0FFO/V8bWrCQs+wLmvVVxk6CRBXALEvNs9OHIatlnlFokfhuDo2ug01ciw==", + "requires": { + "@types/istanbul-lib-coverage": "*", + "@types/istanbul-lib-report": "*" + } + }, + "@types/jest": { + "version": "24.9.1", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-24.9.1.tgz", + "integrity": "sha512-Fb38HkXSVA4L8fGKEZ6le5bB8r6MRWlOCZbVuWZcmOMSCd2wCYOwN1ibj8daIoV9naq7aaOZjrLCoCMptKU/4Q==", + "requires": { + "jest-diff": "^24.3.0" + } + }, + "@types/json-schema": { + "version": "7.0.5", + "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.5.tgz", + "integrity": "sha512-7+2BITlgjgDhH0vvwZU/HZJVyk+2XUlvxXe8dFMedNX/aMkaOq++rMAFXc0tM7ij15QaWlbdQASBR9dihi+bDQ==" + }, + "@types/minimatch": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.3.tgz", + "integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==" + }, + "@types/node": { + "version": "12.12.54", + "resolved": "https://registry.npmjs.org/@types/node/-/node-12.12.54.tgz", + "integrity": "sha512-ge4xZ3vSBornVYlDnk7yZ0gK6ChHf/CHB7Gl1I0Jhah8DDnEQqBzgohYG4FX4p81TNirSETOiSyn+y1r9/IR6w==" + }, + "@types/parse-json": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz", + "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==" + }, + "@types/prop-types": { + "version": "15.7.3", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.3.tgz", + "integrity": "sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw==" + }, + "@types/q": { + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/@types/q/-/q-1.5.4.tgz", + "integrity": "sha512-1HcDas8SEj4z1Wc696tH56G8OlRaH/sqZOynNNB+HF0WOeXPaxTtbYzJY2oEfiUxjSKjhCKr+MvR7dCHcEelug==" + }, + "@types/react": { + "version": "16.9.46", + "resolved": "https://registry.npmjs.org/@types/react/-/react-16.9.46.tgz", + "integrity": "sha512-dbHzO3aAq1lB3jRQuNpuZ/mnu+CdD3H0WVaaBQA8LTT3S33xhVBUj232T8M3tAhSWJs/D/UqORYUlJNl/8VQZg==", + "requires": { + "@types/prop-types": "*", + "csstype": "^3.0.2" + } + }, + "@types/react-dom": { + "version": "16.9.8", + "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-16.9.8.tgz", + "integrity": "sha512-ykkPQ+5nFknnlU6lDd947WbQ6TE3NNzbQAkInC2EKY1qeYdTKp7onFusmYZb+ityzx2YviqT6BXSu+LyWWJwcA==", + "requires": { + "@types/react": "*" + } + }, + "@types/stack-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-1.0.1.tgz", + "integrity": "sha512-l42BggppR6zLmpfU6fq9HEa2oGPEI8yrSPL3GITjfRInppYFahObbIQOQK3UGxEnyQpltZLaPe75046NOZQikw==" + }, + "@types/testing-library__dom": { + "version": "6.14.0", + "resolved": "https://registry.npmjs.org/@types/testing-library__dom/-/testing-library__dom-6.14.0.tgz", + "integrity": "sha512-sMl7OSv0AvMOqn1UJ6j1unPMIHRXen0Ita1ujnMX912rrOcawe4f7wu0Zt9GIQhBhJvH2BaibqFgQ3lP+Pj2hA==", + "requires": { + "pretty-format": "^24.3.0" + } + }, + "@types/testing-library__react": { + "version": "9.1.3", + "resolved": "https://registry.npmjs.org/@types/testing-library__react/-/testing-library__react-9.1.3.tgz", + "integrity": "sha512-iCdNPKU3IsYwRK9JieSYAiX0+aYDXOGAmrC/3/M7AqqSDKnWWVv07X+Zk1uFSL7cMTUYzv4lQRfohucEocn5/w==", + "requires": { + "@types/react-dom": "*", + "@types/testing-library__dom": "*", + "pretty-format": "^25.1.0" + }, + "dependencies": { + "@jest/types": { + "version": "25.5.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-25.5.0.tgz", + "integrity": "sha512-OXD0RgQ86Tu3MazKo8bnrkDRaDXXMGUqd+kTtLtK1Zb7CRzQcaSRPPPV37SvYTdevXEBVxe0HXylEjs8ibkmCw==", "requires": { - "kind-of": "^3.0.2" - }, - "dependencies": { - "kind-of": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", - "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", - "optional": true, - "requires": { - "is-buffer": "^1.1.5" - } - } + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^1.1.1", + "@types/yargs": "^15.0.0", + "chalk": "^3.0.0" } }, - "to-regex": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/to-regex/-/to-regex-3.0.2.tgz", - "integrity": "sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw==", - "optional": true, + "@types/yargs": { + "version": "15.0.5", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-15.0.5.tgz", + "integrity": "sha512-Dk/IDOPtOgubt/IaevIUbTgV7doaKkoorvOyYM2CMwuDyP89bekI7H4xLIwunNYiK9jhCkmc6pUrJk3cj2AB9w==", "requires": { - "define-property": "^2.0.2", - "extend-shallow": "^3.0.2", - "regex-not": "^1.0.2", - "safe-regex": "^1.1.0" + "@types/yargs-parser": "*" } }, - "to-regex-range": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-2.1.1.tgz", - "integrity": "sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg=", - "optional": true, - "requires": { - "is-number": "^3.0.0", - "repeat-string": "^1.6.1" - } + "ansi-regex": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.0.tgz", + "integrity": "sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg==" }, - "ts-node": { - "version": "8.10.2", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", - "integrity": "sha512-ISJJGgkIpDdBhWVu3jufsWpK3Rzo7bdiIXJjQc0ynKxVOVcg2oIrf2H2cejminGrptVc6q6/uynAHNCuWGbpVA==", + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", "requires": { - "arg": "^4.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.17", - "yn": "3.1.1" + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" } }, - "tsc-watch": { - "version": "4.2.9", - "resolved": "https://registry.npmjs.org/tsc-watch/-/tsc-watch-4.2.9.tgz", - "integrity": "sha512-DlTaoDs74+KUpyWr7dCGhuscAUKCz6CiFduBN7R9RbLJSSN1moWdwoCLASE7+zLgGvV5AwXfYDiEMAsPGaO+Vw==", + "chalk": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", + "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", "requires": { - "cross-spawn": "^7.0.3", - "node-cleanup": "^2.1.2", - "ps-tree": "^1.2.0", - "string-argv": "^0.1.1", - "strip-ansi": "^6.0.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, - "tslib": { + "color-convert": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.1.tgz", - "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==" - }, - "type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" - }, - "typescript": { - "version": "3.9.7", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", - "integrity": "sha512-BLbiRkiBzAwsjut4x/dsibSTB6yWpwT5qWmC2OfuCg3GgVQCSgMs4vEctYPhsaGtd0AeuuHMkjZ2h2WG8MSzRw==" - }, - "unicode-canonical-property-names-ecmascript": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz", - "integrity": "sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ==" - }, - "unicode-match-property-ecmascript": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz", - "integrity": "sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg==", - "requires": { - "unicode-canonical-property-names-ecmascript": "^1.0.4", - "unicode-property-aliases-ecmascript": "^1.0.4" - } - }, - "unicode-match-property-value-ecmascript": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz", - "integrity": "sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ==" - }, - "unicode-property-aliases-ecmascript": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz", - "integrity": "sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg==" - }, - "union-value": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/union-value/-/union-value-1.0.1.tgz", - "integrity": "sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg==", - "optional": true, - "requires": { - "arr-union": "^3.1.0", - "get-value": "^2.0.6", - "is-extendable": "^0.1.1", - "set-value": "^2.0.1" - } - }, - "unset-value": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-1.0.0.tgz", - "integrity": "sha1-g3aHP30jNRef+x5vw6jtDfyKtVk=", - "optional": true, + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "requires": { - "has-value": "^0.3.1", - "isobject": "^3.0.0" - }, - "dependencies": { - "has-value": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/has-value/-/has-value-0.3.1.tgz", - "integrity": "sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8=", - "optional": true, - "requires": { - "get-value": "^2.0.3", - "has-values": "^0.1.4", - "isobject": "^2.0.0" - }, - "dependencies": { - "isobject": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/isobject/-/isobject-2.1.0.tgz", - "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", - "optional": true, - "requires": { - "isarray": "1.0.0" - } - } - } - }, - "has-values": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/has-values/-/has-values-0.1.4.tgz", - "integrity": "sha1-bWHeldkd/Km5oCCJrThL/49it3E=", - "optional": true - } + "color-name": "~1.1.4" } }, - "upath": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/upath/-/upath-1.2.0.tgz", - "integrity": "sha512-aZwGpamFO61g3OlfT7OQCHqhGnW43ieH9WZeP7QxN/G/jS4jfqUkZxoryvJgVPEcrl5NL/ggHsSmLMHuH64Lhg==", - "optional": true - }, - "urix": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/urix/-/urix-0.1.0.tgz", - "integrity": "sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI=", - "optional": true - }, - "use": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/use/-/use-3.1.1.tgz", - "integrity": "sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ==", - "optional": true - }, - "util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", - "optional": true - }, - "which": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", - "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "requires": { - "isexe": "^2.0.0" - } + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" }, - "which-module": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" }, - "wide-align": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", - "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", + "pretty-format": { + "version": "25.5.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-25.5.0.tgz", + "integrity": "sha512-kbo/kq2LQ/A/is0PQwsEHM7Ca6//bGPPvU6UnsdDRSKTWxT/ru/xb88v4BJf6a69H+uTytOEsTusT9ksd/1iWQ==", "requires": { - "string-width": "^1.0.2 || 2" + "@jest/types": "^25.5.0", + "ansi-regex": "^5.0.0", + "ansi-styles": "^4.0.0", + "react-is": "^16.12.0" } }, - "workerpool": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", - "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==" - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": { - "ansi-regex": "^4.1.0" - } - } + "has-flag": "^4.0.0" } + } + } + }, + "@types/yargs": { + "version": "13.0.10", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-13.0.10.tgz", + "integrity": "sha512-MU10TSgzNABgdzKvQVW1nuuT+sgBMWeXNc3XOs5YXV5SDAK+PPja2eUuBNB9iqElu03xyEDqlnGw0jgl4nbqGQ==", + "requires": { + "@types/yargs-parser": "*" + } + }, + "@types/yargs-parser": { + "version": "15.0.0", + "resolved": "https://registry.npmjs.org/@types/yargs-parser/-/yargs-parser-15.0.0.tgz", + "integrity": "sha512-FA/BWv8t8ZWJ+gEOnLLd8ygxH/2UFbAvgEonyfN6yWGLKc7zVjbpl2Y4CTjid9h2RfgPP6SEt6uHwEOply00yw==" + }, + "@typescript-eslint/eslint-plugin": { + "version": "2.34.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-2.34.0.tgz", + "integrity": "sha512-4zY3Z88rEE99+CNvTbXSyovv2z9PNOVffTWD2W8QF5s2prBQtwN2zadqERcrHpcR7O/+KMI3fcTAmUUhK/iQcQ==", + "requires": { + "@typescript-eslint/experimental-utils": "2.34.0", + "functional-red-black-tree": "^1.0.1", + "regexpp": "^3.0.0", + "tsutils": "^3.17.1" + } + }, + "@typescript-eslint/experimental-utils": { + "version": "2.34.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-2.34.0.tgz", + "integrity": "sha512-eS6FTkq+wuMJ+sgtuNTtcqavWXqsflWcfBnlYhg/nS4aZ1leewkXGbvBhaapn1q6qf4M71bsR1tez5JTRMuqwA==", + "requires": { + "@types/json-schema": "^7.0.3", + "@typescript-eslint/typescript-estree": "2.34.0", + "eslint-scope": "^5.0.0", + "eslint-utils": "^2.0.0" + } + }, + "@typescript-eslint/parser": { + "version": "2.34.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-2.34.0.tgz", + "integrity": "sha512-03ilO0ucSD0EPTw2X4PntSIRFtDPWjrVq7C3/Z3VQHRC7+13YB55rcJI3Jt+YgeHbjUdJPcPa7b23rXCBokuyA==", + "requires": { + "@types/eslint-visitor-keys": "^1.0.0", + "@typescript-eslint/experimental-utils": "2.34.0", + "@typescript-eslint/typescript-estree": "2.34.0", + "eslint-visitor-keys": "^1.1.0" + } + }, + "@typescript-eslint/typescript-estree": { + "version": "2.34.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-2.34.0.tgz", + "integrity": "sha512-OMAr+nJWKdlVM9LOqCqh3pQQPwxHAN7Du8DR6dmwCrAmxtiXQnhHJ6tBNtf+cggqfo51SG/FCwnKhXCIM7hnVg==", + "requires": { + "debug": "^4.1.1", + "eslint-visitor-keys": "^1.1.0", + "glob": "^7.1.6", + "is-glob": "^4.0.1", + "lodash": "^4.17.15", + "semver": "^7.3.2", + "tsutils": "^3.17.1" + }, + "dependencies": { + "semver": { + "version": "7.3.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.2.tgz", + "integrity": "sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==" + } + } + }, + "@webassemblyjs/ast": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.8.5.tgz", + "integrity": "sha512-aJMfngIZ65+t71C3y2nBBg5FFG0Okt9m0XEgWZ7Ywgn1oMAT8cNwx00Uv1cQyHtidq0Xn94R4TAywO+LCQ+ZAQ==", + "requires": { + "@webassemblyjs/helper-module-context": "1.8.5", + "@webassemblyjs/helper-wasm-bytecode": "1.8.5", + "@webassemblyjs/wast-parser": "1.8.5" + } + }, + "@webassemblyjs/floating-point-hex-parser": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.8.5.tgz", + "integrity": "sha512-9p+79WHru1oqBh9ewP9zW95E3XAo+90oth7S5Re3eQnECGq59ly1Ri5tsIipKGpiStHsUYmY3zMLqtk3gTcOtQ==" + }, + "@webassemblyjs/helper-api-error": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.8.5.tgz", + "integrity": "sha512-Za/tnzsvnqdaSPOUXHyKJ2XI7PDX64kWtURyGiJJZKVEdFOsdKUCPTNEVFZq3zJ2R0G5wc2PZ5gvdTRFgm81zA==" + }, + "@webassemblyjs/helper-buffer": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.8.5.tgz", + "integrity": "sha512-Ri2R8nOS0U6G49Q86goFIPNgjyl6+oE1abW1pS84BuhP1Qcr5JqMwRFT3Ah3ADDDYGEgGs1iyb1DGX+kAi/c/Q==" + }, + "@webassemblyjs/helper-code-frame": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.8.5.tgz", + "integrity": "sha512-VQAadSubZIhNpH46IR3yWO4kZZjMxN1opDrzePLdVKAZ+DFjkGD/rf4v1jap744uPVU6yjL/smZbRIIJTOUnKQ==", + "requires": { + "@webassemblyjs/wast-printer": "1.8.5" + } + }, + "@webassemblyjs/helper-fsm": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-fsm/-/helper-fsm-1.8.5.tgz", + "integrity": "sha512-kRuX/saORcg8se/ft6Q2UbRpZwP4y7YrWsLXPbbmtepKr22i8Z4O3V5QE9DbZK908dh5Xya4Un57SDIKwB9eow==" + }, + "@webassemblyjs/helper-module-context": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-module-context/-/helper-module-context-1.8.5.tgz", + "integrity": "sha512-/O1B236mN7UNEU4t9X7Pj38i4VoU8CcMHyy3l2cV/kIF4U5KoHXDVqcDuOs1ltkac90IM4vZdHc52t1x8Yfs3g==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "mamacro": "^0.0.3" + } + }, + "@webassemblyjs/helper-wasm-bytecode": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.8.5.tgz", + "integrity": "sha512-Cu4YMYG3Ddl72CbmpjU/wbP6SACcOPVbHN1dI4VJNJVgFwaKf1ppeFJrwydOG3NDHxVGuCfPlLZNyEdIYlQ6QQ==" + }, + "@webassemblyjs/helper-wasm-section": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.8.5.tgz", + "integrity": "sha512-VV083zwR+VTrIWWtgIUpqfvVdK4ff38loRmrdDBgBT8ADXYsEZ5mPQ4Nde90N3UYatHdYoDIFb7oHzMncI02tA==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "@webassemblyjs/helper-buffer": "1.8.5", + "@webassemblyjs/helper-wasm-bytecode": "1.8.5", + "@webassemblyjs/wasm-gen": "1.8.5" + } + }, + "@webassemblyjs/ieee754": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.8.5.tgz", + "integrity": "sha512-aaCvQYrvKbY/n6wKHb/ylAJr27GglahUO89CcGXMItrOBqRarUMxWLJgxm9PJNuKULwN5n1csT9bYoMeZOGF3g==", + "requires": { + "@xtuc/ieee754": "^1.2.0" + } + }, + "@webassemblyjs/leb128": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.8.5.tgz", + "integrity": "sha512-plYUuUwleLIziknvlP8VpTgO4kqNaH57Y3JnNa6DLpu/sGcP6hbVdfdX5aHAV716pQBKrfuU26BJK29qY37J7A==", + "requires": { + "@xtuc/long": "4.2.2" + } + }, + "@webassemblyjs/utf8": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.8.5.tgz", + "integrity": "sha512-U7zgftmQriw37tfD934UNInokz6yTmn29inT2cAetAsaU9YeVCveWEwhKL1Mg4yS7q//NGdzy79nlXh3bT8Kjw==" + }, + "@webassemblyjs/wasm-edit": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.8.5.tgz", + "integrity": "sha512-A41EMy8MWw5yvqj7MQzkDjU29K7UJq1VrX2vWLzfpRHt3ISftOXqrtojn7nlPsZ9Ijhp5NwuODuycSvfAO/26Q==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "@webassemblyjs/helper-buffer": "1.8.5", + "@webassemblyjs/helper-wasm-bytecode": "1.8.5", + "@webassemblyjs/helper-wasm-section": "1.8.5", + "@webassemblyjs/wasm-gen": "1.8.5", + "@webassemblyjs/wasm-opt": "1.8.5", + "@webassemblyjs/wasm-parser": "1.8.5", + "@webassemblyjs/wast-printer": "1.8.5" + } + }, + "@webassemblyjs/wasm-gen": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.8.5.tgz", + "integrity": "sha512-BCZBT0LURC0CXDzj5FXSc2FPTsxwp3nWcqXQdOZE4U7h7i8FqtFK5Egia6f9raQLpEKT1VL7zr4r3+QX6zArWg==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "@webassemblyjs/helper-wasm-bytecode": "1.8.5", + "@webassemblyjs/ieee754": "1.8.5", + "@webassemblyjs/leb128": "1.8.5", + "@webassemblyjs/utf8": "1.8.5" + } + }, + "@webassemblyjs/wasm-opt": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.8.5.tgz", + "integrity": "sha512-HKo2mO/Uh9A6ojzu7cjslGaHaUU14LdLbGEKqTR7PBKwT6LdPtLLh9fPY33rmr5wcOMrsWDbbdCHq4hQUdd37Q==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "@webassemblyjs/helper-buffer": "1.8.5", + "@webassemblyjs/wasm-gen": "1.8.5", + "@webassemblyjs/wasm-parser": "1.8.5" + } + }, + "@webassemblyjs/wasm-parser": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.8.5.tgz", + "integrity": "sha512-pi0SYE9T6tfcMkthwcgCpL0cM9nRYr6/6fjgDtL6q/ZqKHdMWvxitRi5JcZ7RI4SNJJYnYNaWy5UUrHQy998lw==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "@webassemblyjs/helper-api-error": "1.8.5", + "@webassemblyjs/helper-wasm-bytecode": "1.8.5", + "@webassemblyjs/ieee754": "1.8.5", + "@webassemblyjs/leb128": "1.8.5", + "@webassemblyjs/utf8": "1.8.5" + } + }, + "@webassemblyjs/wast-parser": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-parser/-/wast-parser-1.8.5.tgz", + "integrity": "sha512-daXC1FyKWHF1i11obK086QRlsMsY4+tIOKgBqI1lxAnkp9xe9YMcgOxm9kLe+ttjs5aWV2KKE1TWJCN57/Btsg==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "@webassemblyjs/floating-point-hex-parser": "1.8.5", + "@webassemblyjs/helper-api-error": "1.8.5", + "@webassemblyjs/helper-code-frame": "1.8.5", + "@webassemblyjs/helper-fsm": "1.8.5", + "@xtuc/long": "4.2.2" + } + }, + "@webassemblyjs/wast-printer": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.8.5.tgz", + "integrity": "sha512-w0U0pD4EhlnvRyeJzBqaVSJAo9w/ce7/WPogeXLzGkO6hzhr4GnQIZ4W4uUt5b9ooAaXPtnXlj0gzsXEOUNYMg==", + "requires": { + "@webassemblyjs/ast": "1.8.5", + "@webassemblyjs/wast-parser": "1.8.5", + "@xtuc/long": "4.2.2" + } + }, + "@xtuc/ieee754": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", + "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==" + }, + "@xtuc/long": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", + "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==" + }, + "abab": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/abab/-/abab-2.0.4.tgz", + "integrity": "sha512-Eu9ELJWCz/c1e9gTiCY+FceWxcqzjYEbqMgtndnuSqZSUCOL73TWNK2mHfIj4Cw2E/ongOp+JISVNCmovt2KYQ==" + }, + "accepts": { + "version": "1.3.7", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", + "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", + "requires": { + "mime-types": "~2.1.24", + "negotiator": "0.6.2" + } + }, + "acorn": { + "version": "7.4.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.4.0.tgz", + "integrity": "sha512-+G7P8jJmCHr+S+cLfQxygbWhXy+8YTVGzAkpEbcLo2mLoL7tij/VG41QSHACSf5QgYRhMZYHuNc6drJaO0Da+w==" + }, + "acorn-globals": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-4.3.4.tgz", + "integrity": "sha512-clfQEh21R+D0leSbUdWf3OcfqyaCSAQ8Ryq00bofSekfr9W8u1jyYZo6ir0xu9Gtcf7BjcHJpnbZH7JOCpP60A==", + "requires": { + "acorn": "^6.0.1", + "acorn-walk": "^6.0.1" + }, + "dependencies": { + "acorn": { + "version": "6.4.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-6.4.1.tgz", + "integrity": "sha512-ZVA9k326Nwrj3Cj9jlh3wGFutC2ZornPNARZwsNYqQYgN0EsV2d53w5RN/co65Ohn4sUAUtb1rSUAOD6XN9idA==" + } + } + }, + "acorn-jsx": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.2.0.tgz", + "integrity": "sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==" + }, + "acorn-walk": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-6.2.0.tgz", + "integrity": "sha512-7evsyfH1cLOCdAzZAd43Cic04yKydNx0cF+7tiA19p1XnLLPU4dpCQOqpjqwokFe//vS0QqfqqjCS2JkiIs0cA==" + }, + "address": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/address/-/address-1.1.2.tgz", + "integrity": "sha512-aT6camzM4xEA54YVJYSqxz1kv4IHnQZRtThJJHhUMRExaU5spC7jX5ugSwTaTgJliIgs4VhZOk7htClvQ/LmRA==" + }, + "adjust-sourcemap-loader": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/adjust-sourcemap-loader/-/adjust-sourcemap-loader-2.0.0.tgz", + "integrity": "sha512-4hFsTsn58+YjrU9qKzML2JSSDqKvN8mUGQ0nNIrfPi8hmIONT4L3uUaT6MKdMsZ9AjsU6D2xDkZxCkbQPxChrA==", + "requires": { + "assert": "1.4.1", + "camelcase": "5.0.0", + "loader-utils": "1.2.3", + "object-path": "0.11.4", + "regex-parser": "2.2.10" + }, + "dependencies": { + "camelcase": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.0.0.tgz", + "integrity": "sha512-faqwZqnWxbxn+F1d399ygeamQNy3lPp/H9H6rNrqYh4FSVCtcY+3cub1MxA8o9mDd55mM8Aghuu/kuyYA6VTsA==" }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" - }, - "y18n": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", - "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==" - }, - "yargs": { - "version": "13.3.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", - "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.2" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "requires": { - "locate-path": "^3.0.0" - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "requires": { - "p-limit": "^2.0.0" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": { - "ansi-regex": "^4.1.0" - } - } - } + "emojis-list": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-2.1.0.tgz", + "integrity": "sha1-TapNnbAPmBmIDHn6RXrlsJof04k=" }, - "yargs-parser": { - "version": "13.1.2", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", - "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", + "json5": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", + "integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" + "minimist": "^1.2.0" } }, - "yargs-unparser": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", - "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", + "loader-utils": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.2.3.tgz", + "integrity": "sha512-fkpz8ejdnEMG3s37wGL07iSBDg99O9D5yflE9RGNH3hRdx9SOwYfnGYdZOUIZitN8E+E2vkq3MUMYMvPYl5ZZA==", "requires": { - "camelcase": "^5.3.1", - "decamelize": "^1.2.0", - "flat": "^4.1.0", - "is-plain-obj": "^1.1.0", - "yargs": "^14.2.3" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==" - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "requires": { - "locate-path": "^3.0.0" - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "requires": { - "p-limit": "^2.0.0" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "yargs": { - "version": "14.2.3", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", - "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", - "requires": { - "cliui": "^5.0.0", - "decamelize": "^1.2.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^15.0.1" - } - }, - "yargs-parser": { - "version": "15.0.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", - "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - } + "big.js": "^5.2.2", + "emojis-list": "^2.0.0", + "json5": "^1.0.1" } - }, - "yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" } } }, + "aggregate-error": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.0.1.tgz", + "integrity": "sha512-quoaXsZ9/BLNae5yiNoUz+Nhkwz83GhWwtYFglcjEQB2NDHCIpApbqXxIFnm4Pq/Nvhrsq5sYJFyohrrxnTGAA==", + "requires": { + "clean-stack": "^2.0.0", + "indent-string": "^4.0.0" + } + }, "ajv": { "version": "6.12.3", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.3.tgz", @@ -6239,7 +6134,7 @@ "requires": { "browserslist": "^4.12.0", "caniuse-lite": "^1.0.30001109", - "colorette": "^1.2.0", + "colorette": "^1.2.1", "normalize-range": "^0.1.2", "num2fraction": "^1.2.2", "postcss": "^7.0.32", diff --git a/examples/react-typescript/package.json b/examples/react-typescript/package.json index e2f0910e..7ddcc246 100644 --- a/examples/react-typescript/package.json +++ b/examples/react-typescript/package.json @@ -14,7 +14,8 @@ "react-dom": "^16.13.1", "react-scripts": "3.4.3", "typescript": "~3.7.2", - "agile-framework": "file:../../" + "@agile-ts/core": "file:../../packages/core", + "@agile-ts/react": "file:../../packages/react" }, "scripts": { "start": "react-scripts start", diff --git a/examples/react-typescript/src/App.tsx b/examples/react-typescript/src/App.tsx index 5d2fa97b..46ca8225 100644 --- a/examples/react-typescript/src/App.tsx +++ b/examples/react-typescript/src/App.tsx @@ -1,6 +1,6 @@ import React from 'react'; import './App.css'; -import {useAgile, useEvent} from 'agile-framework'; +import {useAgile, useEvent} from '@agile-ts/react'; import {MY_COLLECTION, MY_COMPUTED, MY_EVENT, MY_STATE, MY_STATE_2} from "./core"; const App = (props: any) => { @@ -10,6 +10,7 @@ const App = (props: any) => { const [myCollection] = useAgile([MY_COLLECTION.getGroup('myGroup')]); const mySelector = useAgile(MY_COLLECTION.getSelector('mySelector')); + // @ts-ignore useEvent(MY_EVENT, () => { console.log("Triggered Event"); }); diff --git a/examples/react-typescript/src/core/index.ts b/examples/react-typescript/src/core/index.ts index 07954424..d7676aef 100644 --- a/examples/react-typescript/src/core/index.ts +++ b/examples/react-typescript/src/core/index.ts @@ -1,9 +1,7 @@ -import Agile from 'agile-framework'; -import React from "react"; +import Agile from '@agile-ts/core'; export const App = new Agile({ logJobs: true, - framework: React }); export const MY_STATE = App.State("MyState", "my-state").persist(); diff --git a/packages/core/src/collection/group.ts b/packages/core/src/collection/group.ts index aa5fa2fe..b95f2c25 100644 --- a/packages/core/src/collection/group.ts +++ b/packages/core/src/collection/group.ts @@ -1,9 +1,9 @@ import { + Agile, + State, Collection, DefaultDataItem, ItemKey, - State, - Agile, defineConfig, normalizeArray } from '../internal'; diff --git a/packages/core/src/internal.ts b/packages/core/src/internal.ts index 6b4a6da2..b6b85bc0 100644 --- a/packages/core/src/internal.ts +++ b/packages/core/src/internal.ts @@ -1,31 +1,36 @@ // This file exposes Agile functions and types to the outside world. -// It also serves as a cyclic dependency workaround. -// All internal Agile modules must import from here. +// It also serves as a cyclic dependency workaround +// https://medium.com/visual-development/how-to-fix-nasty-circular-dependency-issues-once-and-for-all-in-javascript-typescript-a04c987cf0de. + +// !! All internal Agile modules must import from here. +// Otherwise we can run into annoying cycle dependencies // Agile export * from './agile'; +// State +export * from './state'; +export * from './state/dep'; + +// Computed +export {Computed} from './computed'; + // Collection export * from './collection'; export * from './collection/group'; export * from './collection/item'; export * from './collection/selector'; -// Computed -export* from './computed'; - // Event export * from './event'; -// State -export * from './state'; -export {Dep} from './state/dep'; - // Internal Classes export * from './runtime'; export * from './storage'; -export * from './runtime/subscription/sub'; -export * from './utils'; export * from './integrations'; +export * from './runtime/subscription/sub'; export * from './runtime/subscription/CallbackSubscriptionContainer'; -export * from './runtime/subscription/ComponentSubscriptionContainer'; \ No newline at end of file +export * from './runtime/subscription/ComponentSubscriptionContainer'; + +// Utils +export * from './utils'; \ No newline at end of file From f19a90b04cbd626efe37cdacf0ef3805e373c41f Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Thu, 1 Oct 2020 18:20:00 +0200 Subject: [PATCH 09/15] Updated useAgile and useEvent Test Hook --- .../react/tests/hooks/{useAgile.ts => useAgile_Test.ts} | 8 ++++---- packages/react/tests/hooks/useEvent.ts | 5 ----- packages/react/tests/hooks/useEvent_Test.ts | 5 +++++ packages/react/tests/index.ts | 4 ++-- 4 files changed, 11 insertions(+), 11 deletions(-) rename packages/react/tests/hooks/{useAgile.ts => useAgile_Test.ts} (78%) delete mode 100644 packages/react/tests/hooks/useEvent.ts create mode 100644 packages/react/tests/hooks/useEvent_Test.ts diff --git a/packages/react/tests/hooks/useAgile.ts b/packages/react/tests/hooks/useAgile_Test.ts similarity index 78% rename from packages/react/tests/hooks/useAgile.ts rename to packages/react/tests/hooks/useAgile_Test.ts index be74f212..41c9382e 100644 --- a/packages/react/tests/hooks/useAgile.ts +++ b/packages/react/tests/hooks/useAgile_Test.ts @@ -24,12 +24,12 @@ type AgileHookType = T extends Group ? U[] : never; // Array -export function useAgile>(deps: X, callBackFunction: Function, agileInstance?: Agile): AgileHookArrayType; +export function useAgile_Test>(deps: X, callbackFunction: Function, agileInstance?: Agile): AgileHookArrayType; // No Array -export function useAgile(deps: X, callBackFunction: Function, agileInstance?: Agile): AgileHookType; +export function useAgile_Test(deps: X, callbackFunction: Function, agileInstance?: Agile): AgileHookType; -export function useAgile, Y extends State | Collection | undefined>(deps: X | Y, callBackFunction: Function, agileInstance?: Agile): AgileHookArrayType | AgileHookType { +export function useAgile_Test, Y extends State | Collection | undefined>(deps: X | Y, callbackFunction: Function, agileInstance?: Agile): AgileHookArrayType | AgileHookType { // Normalize Dependencies let depsArray = normalizeArray(deps) .map(item => item instanceof Collection ? item.getGroup(item.config.defaultGroupKey || 'default') : item) @@ -58,7 +58,7 @@ export function useAgile, Y exte } // Create a callback base subscription, Callback invokes re-render Trigger - agileInstance?.subController.subscribeWithSubsArray(callBackFunction, depsArray); + agileInstance?.subController.subscribeWithSubsArray(callbackFunction, depsArray); return getReturnValue(depsArray); } diff --git a/packages/react/tests/hooks/useEvent.ts b/packages/react/tests/hooks/useEvent.ts deleted file mode 100644 index e480be88..00000000 --- a/packages/react/tests/hooks/useEvent.ts +++ /dev/null @@ -1,5 +0,0 @@ -import {Event, EventCallbackFunction} from '@agile-ts/core'; - -export function useEvent(event: E, callback: EventCallbackFunction) { - event.on(callback); -} diff --git a/packages/react/tests/hooks/useEvent_Test.ts b/packages/react/tests/hooks/useEvent_Test.ts new file mode 100644 index 00000000..62f16b4e --- /dev/null +++ b/packages/react/tests/hooks/useEvent_Test.ts @@ -0,0 +1,5 @@ +import {Event, EventCallbackFunction} from '@agile-ts/core'; + +export function useEvent_Test(event: E, callback: EventCallbackFunction) { + event.on(callback); +} diff --git a/packages/react/tests/index.ts b/packages/react/tests/index.ts index b7161b3b..44e4d87b 100644 --- a/packages/react/tests/index.ts +++ b/packages/react/tests/index.ts @@ -1,6 +1,6 @@ import testIntegration from "./test.integration"; -export {useAgile} from './hooks/useAgile'; -export {useEvent} from './hooks/useEvent'; +export {useAgile_Test} from './hooks/useAgile_Test'; +export {useEvent_Test} from './hooks/useEvent_Test'; export default testIntegration; From 8c05e60071348c9b3d091cb71c9ac23c0d7c1eb1 Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Thu, 1 Oct 2020 20:39:43 +0200 Subject: [PATCH 10/15] changed useAgile to useAgile_Test in spec.ts files --- .../tests/collection/functions/collect.function.spec.ts | 6 +++--- .../core/tests/collection/functions/remove.function.spec.ts | 6 +++--- .../core/tests/collection/functions/update.function.spec.ts | 4 ++-- packages/core/tests/collection/group/default.spec.ts | 6 +++--- .../tests/collection/group/functions/add.function.spec.ts | 4 ++-- .../collection/group/functions/remove.function.spec.ts | 4 ++-- packages/core/tests/collection/selector/default.spec.ts | 4 ++-- .../collection/selector/functions/select.function.spec.ts | 4 ++-- packages/core/tests/computed/default.spec.ts | 6 +++--- .../functions/updateComputeFunction.function.spec.ts | 4 ++-- .../core/tests/event/functions/trigger.function.spec.ts | 4 ++-- packages/core/tests/state/functions/patch.function.spec.ts | 4 ++-- packages/core/tests/state/functions/reset.function.spec.ts | 4 ++-- packages/core/tests/state/functions/set.function.spec.ts | 4 ++-- packages/core/tests/state/functions/undo.function.spec.ts | 4 ++-- 15 files changed, 34 insertions(+), 34 deletions(-) diff --git a/packages/core/tests/collection/functions/collect.function.spec.ts b/packages/core/tests/collection/functions/collect.function.spec.ts index 7632673b..476d5358 100644 --- a/packages/core/tests/collection/functions/collect.function.spec.ts +++ b/packages/core/tests/collection/functions/collect.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Group, Agile} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('Collect Function Tests', () => { // Define Agile @@ -21,7 +21,7 @@ describe('Collect Function Tests', () => { const MY_COLLECTION = App.Collection(); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookCollection] = useAgile([MY_COLLECTION], () => { + const [myHookCollection] = useAgile_Test([MY_COLLECTION], () => { rerenderCount++; }); @@ -304,7 +304,7 @@ describe('Collect Function Tests', () => { }); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookCollection] = useAgile([MY_COLLECTION], () => { + const [myHookCollection] = useAgile_Test([MY_COLLECTION], () => { rerenderCount++; }); diff --git a/packages/core/tests/collection/functions/remove.function.spec.ts b/packages/core/tests/collection/functions/remove.function.spec.ts index d1124afa..95678392 100644 --- a/packages/core/tests/collection/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/functions/remove.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Item} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('Remove Function Tests', () => { // Define Agile @@ -26,7 +26,7 @@ describe('Remove Function Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1, myGroup2] = useAgile([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { + const [myGroup1, myGroup2] = useAgile_Test([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { rerenderCount++; }); @@ -142,7 +142,7 @@ describe('Remove Function Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1, myGroup2] = useAgile([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { + const [myGroup1, myGroup2] = useAgile_Test([MY_COLLECTION.getGroup('group1'), MY_COLLECTION.getGroup('group2')], () => { rerenderCount++; }); diff --git a/packages/core/tests/collection/functions/update.function.spec.ts b/packages/core/tests/collection/functions/update.function.spec.ts index 746e0809..88d4ba15 100644 --- a/packages/core/tests/collection/functions/update.function.spec.ts +++ b/packages/core/tests/collection/functions/update.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Group} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('Update Function Tests', () => { let rerenderCount = 0; @@ -20,7 +20,7 @@ describe('Update Function Tests', () => { const MY_COLLECTION = App.Collection(); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookCollection] = useAgile([MY_COLLECTION], () => { + const [myHookCollection] = useAgile_Test([MY_COLLECTION], () => { rerenderCount++; }); diff --git a/packages/core/tests/collection/group/default.spec.ts b/packages/core/tests/collection/group/default.spec.ts index c2d05101..09f4a1a2 100644 --- a/packages/core/tests/collection/group/default.spec.ts +++ b/packages/core/tests/collection/group/default.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from "chai"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; import {Agile, Group} from "../../../src"; describe('Default Group Tests', () => { @@ -25,7 +25,7 @@ describe('Default Group Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + const [myGroup1] = useAgile_Test([MY_COLLECTION.getGroup('group1')], () => { rerenderCount++; }); @@ -93,7 +93,7 @@ describe('Default Group Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + const [myGroup1] = useAgile_Test([MY_COLLECTION.getGroup('group1')], () => { rerenderCount++; }); diff --git a/packages/core/tests/collection/group/functions/add.function.spec.ts b/packages/core/tests/collection/group/functions/add.function.spec.ts index 1a9a0e84..15eaf02c 100644 --- a/packages/core/tests/collection/group/functions/add.function.spec.ts +++ b/packages/core/tests/collection/group/functions/add.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from "chai"; -import {useAgile} from "../../../../../react/tests"; +import {useAgile_Test} from "../../../../../react/tests"; import {Agile, Group} from "../../../../src"; describe('Add function Tests', () => { @@ -24,7 +24,7 @@ describe('Add function Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + const [myGroup1] = useAgile_Test([MY_COLLECTION.getGroup('group1')], () => { rerenderCount++; }); diff --git a/packages/core/tests/collection/group/functions/remove.function.spec.ts b/packages/core/tests/collection/group/functions/remove.function.spec.ts index 3d1ee96a..322dfcb4 100644 --- a/packages/core/tests/collection/group/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/group/functions/remove.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from "chai"; import {Agile, Group} from "../../../../src"; -import {useAgile} from "../../../../../react/tests"; +import {useAgile_Test} from "../../../../../react/tests"; describe('Add function Tests', () => { let rerenderCount = 0; @@ -24,7 +24,7 @@ describe('Add function Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myGroup1] = useAgile([MY_COLLECTION.getGroup('group1')], () => { + const [myGroup1] = useAgile_Test([MY_COLLECTION.getGroup('group1')], () => { rerenderCount++; }); diff --git a/packages/core/tests/collection/selector/default.spec.ts b/packages/core/tests/collection/selector/default.spec.ts index 20876990..ac608c99 100644 --- a/packages/core/tests/collection/selector/default.spec.ts +++ b/packages/core/tests/collection/selector/default.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from "chai"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; import {Agile, Selector, Item} from "../../../src"; describe('Default Selector Tests', () => { @@ -25,7 +25,7 @@ describe('Default Selector Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [mySelector1] = useAgile([MY_COLLECTION.getSelector('selector1')], () => { + const [mySelector1] = useAgile_Test([MY_COLLECTION.getSelector('selector1')], () => { rerenderCount++; }); diff --git a/packages/core/tests/collection/selector/functions/select.function.spec.ts b/packages/core/tests/collection/selector/functions/select.function.spec.ts index eb9b6204..08b9b0c2 100644 --- a/packages/core/tests/collection/selector/functions/select.function.spec.ts +++ b/packages/core/tests/collection/selector/functions/select.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from "chai"; import {Agile, Selector, Item} from "../../../../src"; -import {useAgile} from "../../../../../react/tests"; +import {useAgile_Test} from "../../../../../react/tests"; describe('select Function Tests', () => { let rerenderCount = 0; @@ -24,7 +24,7 @@ describe('select Function Tests', () => { ); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [mySelector1] = useAgile([MY_COLLECTION.getSelector('selector1')], () => { + const [mySelector1] = useAgile_Test([MY_COLLECTION.getSelector('selector1')], () => { rerenderCount++; }); diff --git a/packages/core/tests/computed/default.spec.ts b/packages/core/tests/computed/default.spec.ts index 54c3be7a..e0ce80a8 100644 --- a/packages/core/tests/computed/default.spec.ts +++ b/packages/core/tests/computed/default.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Computed} from "../../src"; -import {useAgile} from "../../../react/tests"; +import {useAgile_Test} from "../../../react/tests"; describe('Default Computed Tests', () => { // Define Agile @@ -38,7 +38,7 @@ describe('Default Computed Tests', () => { }); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myComputed] = useAgile([MY_COMPUTED], () => { + const [myComputed] = useAgile_Test([MY_COMPUTED], () => { rerenderCount++; }); @@ -112,7 +112,7 @@ describe('Default Computed Tests', () => { }, [MY_STATE_3]); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myComputed] = useAgile([MY_COMPUTED], () => { + const [myComputed] = useAgile_Test([MY_COMPUTED], () => { rerenderCount++; }); diff --git a/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts index eb03a0e0..7b011eaa 100644 --- a/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts +++ b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Computed} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('updateComputeFunction Function tests', () => { let rerenderCount = 0; @@ -21,7 +21,7 @@ describe('updateComputeFunction Function tests', () => { }); // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myComputed] = useAgile([MY_COMPUTED], () => { + const [myComputed] = useAgile_Test([MY_COMPUTED], () => { rerenderCount++; }); diff --git a/packages/core/tests/event/functions/trigger.function.spec.ts b/packages/core/tests/event/functions/trigger.function.spec.ts index d5735ccc..f988ca81 100644 --- a/packages/core/tests/event/functions/trigger.function.spec.ts +++ b/packages/core/tests/event/functions/trigger.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useEvent} from "../../../../react/tests"; +import {useEvent_Test} from "../../../../react/tests"; describe('Trigger Function Tests', () => { @@ -25,7 +25,7 @@ describe('Trigger Function Tests', () => { }); // @ts-ignore - useEvent(MY_EVENT, (payload => { + useEvent_Test(MY_EVENT, (payload => { eventCallCount++; currentEventPayload = payload; })); diff --git a/packages/core/tests/state/functions/patch.function.spec.ts b/packages/core/tests/state/functions/patch.function.spec.ts index 681d8d78..45c199da 100644 --- a/packages/core/tests/state/functions/patch.function.spec.ts +++ b/packages/core/tests/state/functions/patch.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('Patch Function Tests', () => { let rerenderCount = 0; @@ -25,7 +25,7 @@ describe('Patch Function Tests', () => { }; // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { + const [myHookState] = useAgile_Test([MY_STATE], () => { rerenderCount++; }); diff --git a/packages/core/tests/state/functions/reset.function.spec.ts b/packages/core/tests/state/functions/reset.function.spec.ts index 998cd3b2..9b94d531 100644 --- a/packages/core/tests/state/functions/reset.function.spec.ts +++ b/packages/core/tests/state/functions/reset.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('Reset Function Tests', () => { let rerenderCount = 0; @@ -19,7 +19,7 @@ describe('Reset Function Tests', () => { }; // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { + const [myHookState] = useAgile_Test([MY_STATE], () => { rerenderCount++; }); diff --git a/packages/core/tests/state/functions/set.function.spec.ts b/packages/core/tests/state/functions/set.function.spec.ts index 24e4d161..b9d3d550 100644 --- a/packages/core/tests/state/functions/set.function.spec.ts +++ b/packages/core/tests/state/functions/set.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('Set Function Tests', () => { let rerenderCount = 0; @@ -19,7 +19,7 @@ describe('Set Function Tests', () => { }; // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { + const [myHookState] = useAgile_Test([MY_STATE], () => { rerenderCount++; }); diff --git a/packages/core/tests/state/functions/undo.function.spec.ts b/packages/core/tests/state/functions/undo.function.spec.ts index 0e63fc12..66356fc8 100644 --- a/packages/core/tests/state/functions/undo.function.spec.ts +++ b/packages/core/tests/state/functions/undo.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile} from "../../../../react/tests"; +import {useAgile_Test} from "../../../../react/tests"; describe('Undo Function Tests', () => { let rerenderCount = 0; @@ -19,7 +19,7 @@ describe('Undo Function Tests', () => { }; // Set 'Hook' for testing the rerenderFunctionality with the callbackFunction (Note: the value of myHookState doesn't get changed because no rerenders happen -> no reassign of the value) - const [myHookState] = useAgile([MY_STATE], () => { + const [myHookState] = useAgile_Test([MY_STATE], () => { rerenderCount++; }); From 97451c64bae71a04c7379af7eed54a65ad979aa3 Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Thu, 1 Oct 2020 20:40:26 +0200 Subject: [PATCH 11/15] Updated package.json of react packages.. --- packages/react/package-lock.json | 1264 ------------------------------ packages/react/package.json | 6 - 2 files changed, 1270 deletions(-) diff --git a/packages/react/package-lock.json b/packages/react/package-lock.json index 2fa8cad3..0d03e49d 100644 --- a/packages/react/package-lock.json +++ b/packages/react/package-lock.json @@ -7,266 +7,24 @@ "@agile-ts/core": { "version": "file:../core" }, - "@types/chai": { - "version": "4.2.12", - "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.2.12.tgz", - "integrity": "sha512-aN5IAC8QNtSUdQzxu7lGBgYAOuU1tmRU4c9dIq5OKGf/SBVjXo+ffM2wEjudAWbgpOhy60nLoAGH1xm8fpCKFQ==", - "dev": true - }, - "@types/color-name": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", - "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", - "dev": true - }, - "@types/mocha": { - "version": "8.0.3", - "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-8.0.3.tgz", - "integrity": "sha512-vyxR57nv8NfcU0GZu8EUXZLTbCMupIUwy95LJ6lllN+JRPG25CwMHoB1q5xKh8YKhQnHYRAn4yW2yuHbf/5xgg==", - "dev": true - }, "@types/node": { "version": "14.11.2", "resolved": "https://registry.npmjs.org/@types/node/-/node-14.11.2.tgz", "integrity": "sha512-jiE3QIxJ8JLNcb1Ps6rDbysDhN4xa8DJJvuC9prr6w+1tIh+QAbYyNF3tyiZNLDBIuBCf4KEcV2UvQm/V60xfA==", "dev": true }, - "@types/prop-types": { - "version": "15.7.3", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.3.tgz", - "integrity": "sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw==", - "dev": true - }, - "@types/react": { - "version": "16.9.49", - "resolved": "https://registry.npmjs.org/@types/react/-/react-16.9.49.tgz", - "integrity": "sha512-DtLFjSj0OYAdVLBbyjhuV9CdGVHCkHn2R+xr3XkBvK2rS1Y1tkc14XSGjYgm5Fjjr90AxH9tiSzc1pCFMGO06g==", - "dev": true, - "requires": { - "@types/prop-types": "*", - "csstype": "^3.0.2" - } - }, - "ansi-colors": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", - "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", - "dev": true - }, - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "dev": true - }, - "ansi-styles": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", - "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", - "dev": true, - "requires": { - "@types/color-name": "^1.1.1", - "color-convert": "^2.0.1" - } - }, - "anymatch": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.1.tgz", - "integrity": "sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg==", - "dev": true, - "requires": { - "normalize-path": "^3.0.0", - "picomatch": "^2.0.4" - } - }, "arg": { "version": "4.1.3", "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", "dev": true }, - "argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "dev": true, - "requires": { - "sprintf-js": "~1.0.2" - } - }, - "array.prototype.map": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array.prototype.map/-/array.prototype.map-1.0.2.tgz", - "integrity": "sha512-Az3OYxgsa1g7xDYp86l0nnN4bcmuEITGe1rbdEBVkrqkzMgDcbdQ2R7r41pNzti+4NMces3H8gMmuioZUilLgw==", - "dev": true, - "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.0-next.1", - "es-array-method-boxes-properly": "^1.0.0", - "is-string": "^1.0.4" - } - }, - "assertion-error": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", - "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", - "dev": true - }, - "balanced-match": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", - "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", - "dev": true - }, - "binary-extensions": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.1.0.tgz", - "integrity": "sha512-1Yj8h9Q+QDF5FzhMs/c9+6UntbD5MkRfRwac8DoEm9ZfUBZ7tZ55YcGVAzEe4bXsdQHEk+s9S5wsOKVdZrw0tQ==", - "dev": true - }, - "brace-expansion": { - "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", - "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, - "requires": { - "balanced-match": "^1.0.0", - "concat-map": "0.0.1" - } - }, - "braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "dev": true, - "requires": { - "fill-range": "^7.0.1" - } - }, - "browser-stdout": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", - "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", - "dev": true - }, "buffer-from": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz", "integrity": "sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A==", "dev": true }, - "camelcase": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", - "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", - "dev": true - }, - "chai": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/chai/-/chai-4.2.0.tgz", - "integrity": "sha512-XQU3bhBukrOsQCuwZndwGcCVQHyZi53fQ6Ys1Fym7E4olpIqqZZhhoFJoaKVvV17lWQoXYwgWN2nF5crA8J2jw==", - "dev": true, - "requires": { - "assertion-error": "^1.1.0", - "check-error": "^1.0.2", - "deep-eql": "^3.0.1", - "get-func-name": "^2.0.0", - "pathval": "^1.1.0", - "type-detect": "^4.0.5" - } - }, - "chalk": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz", - "integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "check-error": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", - "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", - "dev": true - }, - "chokidar": { - "version": "3.4.2", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.4.2.tgz", - "integrity": "sha512-IZHaDeBeI+sZJRX7lGcXsdzgvZqKv6sECqsbErJA4mHWfpRrD8B97kSFN4cQz6nGBGiuFia1MKR4d6c1o8Cv7A==", - "dev": true, - "requires": { - "anymatch": "~3.1.1", - "braces": "~3.0.2", - "fsevents": "~2.1.2", - "glob-parent": "~5.1.0", - "is-binary-path": "~2.1.0", - "is-glob": "~4.0.1", - "normalize-path": "~3.0.0", - "readdirp": "~3.4.0" - } - }, - "cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "dev": true, - "requires": { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "concat-map": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "dev": true - }, "cross-spawn": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", @@ -278,45 +36,6 @@ "which": "^2.0.1" } }, - "csstype": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.0.3.tgz", - "integrity": "sha512-jPl+wbWPOWJ7SXsWyqGRk3lGecbar0Cb0OvZF/r/ZU011R4YqiRehgkQ9p4eQfo9DSDLqLL3wHwfxeJiuIsNag==", - "dev": true - }, - "debug": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", - "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", - "dev": true, - "requires": { - "ms": "^2.1.1" - } - }, - "decamelize": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", - "dev": true - }, - "deep-eql": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-3.0.1.tgz", - "integrity": "sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==", - "dev": true, - "requires": { - "type-detect": "^4.0.0" - } - }, - "define-properties": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", - "integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==", - "dev": true, - "requires": { - "object-keys": "^1.0.12" - } - }, "diff": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", @@ -329,69 +48,6 @@ "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==", "dev": true }, - "emoji-regex": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", - "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", - "dev": true - }, - "es-abstract": { - "version": "1.17.6", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.17.6.tgz", - "integrity": "sha512-Fr89bON3WFyUi5EvAeI48QTWX0AyekGgLA8H+c+7fbfCkJwRWRMLd8CQedNEyJuoYYhmtEqY92pgte1FAhBlhw==", - "dev": true, - "requires": { - "es-to-primitive": "^1.2.1", - "function-bind": "^1.1.1", - "has": "^1.0.3", - "has-symbols": "^1.0.1", - "is-callable": "^1.2.0", - "is-regex": "^1.1.0", - "object-inspect": "^1.7.0", - "object-keys": "^1.1.1", - "object.assign": "^4.1.0", - "string.prototype.trimend": "^1.0.1", - "string.prototype.trimstart": "^1.0.1" - } - }, - "es-array-method-boxes-properly": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz", - "integrity": "sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==", - "dev": true - }, - "es-get-iterator": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.0.tgz", - "integrity": "sha512-UfrmHuWQlNMTs35e1ypnvikg6jCz3SK8v8ImvmDsh36fCVUR1MqoFDiyn0/k52C8NqO3YsO8Oe0azeesNuqSsQ==", - "dev": true, - "requires": { - "es-abstract": "^1.17.4", - "has-symbols": "^1.0.1", - "is-arguments": "^1.0.4", - "is-map": "^2.0.1", - "is-set": "^2.0.1", - "is-string": "^1.0.5", - "isarray": "^2.0.5" - } - }, - "es-to-primitive": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", - "dev": true, - "requires": { - "is-callable": "^1.1.4", - "is-date-object": "^1.0.1", - "is-symbol": "^1.0.2" - } - }, - "escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true - }, "eslint-config-prettier": { "version": "6.12.0", "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.12.0.tgz", @@ -401,12 +57,6 @@ "get-stdin": "^6.0.0" } }, - "esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "dev": true - }, "event-stream": { "version": "3.3.4", "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", @@ -422,322 +72,24 @@ "through": "~2.3.1" } }, - "fill-range": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "dev": true, - "requires": { - "to-regex-range": "^5.0.1" - } - }, - "find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", - "dev": true, - "requires": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" - } - }, - "flat": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/flat/-/flat-4.1.0.tgz", - "integrity": "sha512-Px/TiLIznH7gEDlPXcUD4KnBusa6kR6ayRUVcnEAbreRIuhkqow/mun59BuRXwoYk7ZQOLW1ZM05ilIvK38hFw==", - "dev": true, - "requires": { - "is-buffer": "~2.0.3" - } - }, "from": { "version": "0.1.7", "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", "integrity": "sha1-g8YK/Fi5xWmXAH7Rp2izqzA6RP4=", "dev": true }, - "fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "dev": true - }, - "fsevents": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.1.3.tgz", - "integrity": "sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==", - "dev": true, - "optional": true - }, - "function-bind": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", - "dev": true - }, - "get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true - }, - "get-func-name": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", - "integrity": "sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=", - "dev": true - }, "get-stdin": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz", "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g==", "dev": true }, - "glob": { - "version": "7.1.6", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", - "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - }, - "glob-parent": { - "version": "5.1.1", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.1.tgz", - "integrity": "sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==", - "dev": true, - "requires": { - "is-glob": "^4.0.1" - } - }, - "growl": { - "version": "1.10.5", - "resolved": "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz", - "integrity": "sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==", - "dev": true - }, - "has": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", - "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", - "dev": true, - "requires": { - "function-bind": "^1.1.1" - } - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "has-symbols": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.1.tgz", - "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", - "dev": true - }, - "he": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", - "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", - "dev": true - }, - "inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "dev": true, - "requires": { - "once": "^1.3.0", - "wrappy": "1" - } - }, - "inherits": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true - }, - "is-arguments": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.0.4.tgz", - "integrity": "sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==", - "dev": true - }, - "is-binary-path": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", - "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", - "dev": true, - "requires": { - "binary-extensions": "^2.0.0" - } - }, - "is-buffer": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.4.tgz", - "integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==", - "dev": true - }, - "is-callable": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz", - "integrity": "sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA==", - "dev": true - }, - "is-date-object": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz", - "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", - "dev": true - }, - "is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "dev": true - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "dev": true - }, - "is-glob": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", - "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", - "dev": true, - "requires": { - "is-extglob": "^2.1.1" - } - }, - "is-map": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.1.tgz", - "integrity": "sha512-T/S49scO8plUiAOA2DBTBG3JHpn1yiw0kRp6dgiZ0v2/6twi5eiB0rHtHFH9ZIrvlWc6+4O+m4zg5+Z833aXgw==", - "dev": true - }, - "is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true - }, - "is-plain-obj": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", - "integrity": "sha1-caUMhCnfync8kqOQpKA7OfzVHT4=", - "dev": true - }, - "is-regex": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.1.tgz", - "integrity": "sha512-1+QkEcxiLlB7VEyFtyBg94e08OAsvq7FUBgApTq/w2ymCLyKJgDPsybBENVtA7XCQEgEXxKPonG+mvYRxh/LIg==", - "dev": true, - "requires": { - "has-symbols": "^1.0.1" - } - }, - "is-set": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.1.tgz", - "integrity": "sha512-eJEzOtVyenDs1TMzSQ3kU3K+E0GUS9sno+F0OBT97xsgcJsF9nXMBtkT9/kut5JEpM7oL7X/0qxR17K3mcwIAA==", - "dev": true - }, - "is-string": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.5.tgz", - "integrity": "sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ==", - "dev": true - }, - "is-symbol": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.3.tgz", - "integrity": "sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==", - "dev": true, - "requires": { - "has-symbols": "^1.0.1" - } - }, - "isarray": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", - "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "dev": true - }, "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", "dev": true }, - "iterate-iterator": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/iterate-iterator/-/iterate-iterator-1.0.1.tgz", - "integrity": "sha512-3Q6tudGN05kbkDQDI4CqjaBf4qf85w6W6GnuZDtUVYwKgtC1q8yxYX7CZed7N+tLzQqS6roujWvszf13T+n9aw==", - "dev": true - }, - "iterate-value": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/iterate-value/-/iterate-value-1.0.2.tgz", - "integrity": "sha512-A6fMAio4D2ot2r/TYzr4yUWrmwNdsN5xL7+HUiyACE4DXm+q8HtPcnFTp+NnW3k4N05tZ7FVYFFb2CR13NxyHQ==", - "dev": true, - "requires": { - "es-get-iterator": "^1.0.2", - "iterate-iterator": "^1.0.1" - } - }, - "js-tokens": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", - "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true - }, - "js-yaml": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.0.tgz", - "integrity": "sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A==", - "dev": true, - "requires": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - } - }, - "locate-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", - "dev": true, - "requires": { - "p-locate": "^5.0.0" - } - }, - "log-symbols": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.0.0.tgz", - "integrity": "sha512-FN8JBzLx6CzeMrB0tg6pqlGU1wCrXW+ZXGH481kfsBqer0hToTIiHdjH4Mq8xJUbvATujKCvaREGWpGUionraA==", - "dev": true, - "requires": { - "chalk": "^4.0.0" - } - }, - "loose-envify": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", - "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==", - "dev": true, - "requires": { - "js-tokens": "^3.0.0 || ^4.0.0" - } - }, "make-error": { "version": "1.3.6", "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", @@ -750,153 +102,18 @@ "integrity": "sha1-5WqpTEyAVaFkBKBnS3jyFffI4ZQ=", "dev": true }, - "minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, - "requires": { - "brace-expansion": "^1.1.7" - } - }, - "mocha": { - "version": "8.1.3", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-8.1.3.tgz", - "integrity": "sha512-ZbaYib4hT4PpF4bdSO2DohooKXIn4lDeiYqB+vTmCdr6l2woW0b6H3pf5x4sM5nwQMru9RvjjHYWVGltR50ZBw==", - "dev": true, - "requires": { - "ansi-colors": "4.1.1", - "browser-stdout": "1.3.1", - "chokidar": "3.4.2", - "debug": "4.1.1", - "diff": "4.0.2", - "escape-string-regexp": "4.0.0", - "find-up": "5.0.0", - "glob": "7.1.6", - "growl": "1.10.5", - "he": "1.2.0", - "js-yaml": "3.14.0", - "log-symbols": "4.0.0", - "minimatch": "3.0.4", - "ms": "2.1.2", - "object.assign": "4.1.0", - "promise.allsettled": "1.0.2", - "serialize-javascript": "4.0.0", - "strip-json-comments": "3.0.1", - "supports-color": "7.1.0", - "which": "2.0.2", - "wide-align": "1.1.3", - "workerpool": "6.0.0", - "yargs": "13.3.2", - "yargs-parser": "13.1.2", - "yargs-unparser": "1.6.1" - } - }, - "ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node-cleanup": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/node-cleanup/-/node-cleanup-2.1.2.tgz", "integrity": "sha1-esGavSl+Caf3KnFUXZUbUX5N3iw=", "dev": true }, - "normalize-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", - "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", - "dev": true - }, - "object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", - "dev": true - }, - "object-inspect": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.8.0.tgz", - "integrity": "sha512-jLdtEOB112fORuypAyl/50VRVIBIdVQOSUUGQHzJ4xBSbit81zRarz7GThkEFZy1RceYrWYcPcBFPQwHyAc1gA==", - "dev": true - }, - "object-keys": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", - "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", - "dev": true - }, - "object.assign": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.0.tgz", - "integrity": "sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==", - "dev": true, - "requires": { - "define-properties": "^1.1.2", - "function-bind": "^1.1.1", - "has-symbols": "^1.0.0", - "object-keys": "^1.0.11" - } - }, - "once": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", - "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "dev": true, - "requires": { - "wrappy": "1" - } - }, - "p-limit": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", - "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", - "dev": true, - "requires": { - "p-limit": "^3.0.2" - } - }, - "p-try": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", - "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", - "dev": true - }, - "path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true - }, - "path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "dev": true - }, "path-key": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", "dev": true }, - "pathval": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.0.tgz", - "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=", - "dev": true - }, "pause-stream": { "version": "0.0.11", "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", @@ -906,42 +123,12 @@ "through": "~2.3" } }, - "picomatch": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", - "integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg==", - "dev": true - }, "prettier": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.0.5.tgz", "integrity": "sha512-7PtVymN48hGcO4fGjybyBSIWDsLU4H4XlvOHfq91pz9kkGlonzwTfYkaIEwiRg/dAJF9YlbsduBAgtYLi+8cFg==", "dev": true }, - "promise.allsettled": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/promise.allsettled/-/promise.allsettled-1.0.2.tgz", - "integrity": "sha512-UpcYW5S1RaNKT6pd+s9jp9K9rlQge1UXKskec0j6Mmuq7UJCvlS2J2/s/yuPN8ehftf9HXMxWlKiPbGGUzpoRg==", - "dev": true, - "requires": { - "array.prototype.map": "^1.0.1", - "define-properties": "^1.1.3", - "es-abstract": "^1.17.0-next.1", - "function-bind": "^1.1.1", - "iterate-value": "^1.0.0" - } - }, - "prop-types": { - "version": "15.7.2", - "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.7.2.tgz", - "integrity": "sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==", - "dev": true, - "requires": { - "loose-envify": "^1.4.0", - "object-assign": "^4.1.1", - "react-is": "^16.8.1" - } - }, "ps-tree": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", @@ -951,74 +138,6 @@ "event-stream": "=3.3.4" } }, - "randombytes": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", - "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", - "dev": true, - "requires": { - "safe-buffer": "^5.1.0" - } - }, - "react": { - "version": "16.13.1", - "resolved": "https://registry.npmjs.org/react/-/react-16.13.1.tgz", - "integrity": "sha512-YMZQQq32xHLX0bz5Mnibv1/LHb3Sqzngu7xstSM+vrkE5Kzr9xE0yMByK5kMoTK30YVJE61WfbxIFFvfeDKT1w==", - "dev": true, - "requires": { - "loose-envify": "^1.1.0", - "object-assign": "^4.1.1", - "prop-types": "^15.6.2" - } - }, - "react-is": { - "version": "16.13.1", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", - "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", - "dev": true - }, - "readdirp": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.4.0.tgz", - "integrity": "sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ==", - "dev": true, - "requires": { - "picomatch": "^2.2.1" - } - }, - "require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", - "dev": true - }, - "require-main-filename": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", - "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", - "dev": true - }, - "safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "dev": true - }, - "serialize-javascript": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", - "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", - "dev": true, - "requires": { - "randombytes": "^2.1.0" - } - }, - "set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", - "dev": true - }, "shebang-command": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", @@ -1059,12 +178,6 @@ "through": "2" } }, - "sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=", - "dev": true - }, "stream-combiner": { "version": "0.0.4", "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", @@ -1080,75 +193,12 @@ "integrity": "sha512-mBqPGEOMNJKXRo7z0keX0wlAhbBAjilUdPW13nN0PecVryZxdHIeM7TqbsSUA7VYuS00HGC6mojP7DlQzfa9ZA==", "dev": true }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "dev": true, - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - } - }, - "string.prototype.trimend": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz", - "integrity": "sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g==", - "dev": true, - "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.5" - } - }, - "string.prototype.trimstart": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz", - "integrity": "sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw==", - "dev": true, - "requires": { - "define-properties": "^1.1.3", - "es-abstract": "^1.17.5" - } - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "dev": true, - "requires": { - "ansi-regex": "^3.0.0" - } - }, - "strip-json-comments": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz", - "integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw==", - "dev": true - }, - "supports-color": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", - "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - }, "through": { "version": "2.3.8", "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", "dev": true }, - "to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "dev": true, - "requires": { - "is-number": "^7.0.0" - } - }, "ts-node": { "version": "8.10.2", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.10.2.tgz", @@ -1198,12 +248,6 @@ "integrity": "sha512-SgIkNheinmEBgx1IUNirK0TUD4X9yjjBRTqqjggWCU3pUEqIk3/Uwl3yRixYKT6WjQuGiwDv4NomL3wqRCj+CQ==", "dev": true }, - "type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", - "dev": true - }, "typescript": { "version": "3.9.7", "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", @@ -1219,314 +263,6 @@ "isexe": "^2.0.0" } }, - "which-module": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", - "dev": true - }, - "wide-align": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz", - "integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==", - "dev": true, - "requires": { - "string-width": "^1.0.2 || 2" - } - }, - "workerpool": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.0.0.tgz", - "integrity": "sha512-fU2OcNA/GVAJLLyKUoHkAgIhKb0JoCpSjLC/G2vYKxUjVmQwGbRVeoPJ1a8U4pnVofz4AQV5Y/NEw8oKqxEBtA==", - "dev": true - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", - "dev": true, - "requires": { - "color-name": "1.1.3" - } - }, - "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", - "dev": true - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "wrappy": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "dev": true - }, - "y18n": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", - "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", - "dev": true - }, - "yargs": { - "version": "13.3.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", - "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", - "dev": true, - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.2" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "dev": true, - "requires": { - "locate-path": "^3.0.0" - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "dev": true, - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "dev": true, - "requires": { - "p-limit": "^2.0.0" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", - "dev": true - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - } - } - }, - "yargs-parser": { - "version": "13.1.2", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", - "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - }, - "yargs-unparser": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-1.6.1.tgz", - "integrity": "sha512-qZV14lK9MWsGCmcr7u5oXGH0dbGqZAIxTDrWXZDo5zUr6b6iUmelNKO6x6R1dQT24AH3LgRxJpr8meWy2unolA==", - "dev": true, - "requires": { - "camelcase": "^5.3.1", - "decamelize": "^1.2.0", - "flat": "^4.1.0", - "is-plain-obj": "^1.1.0", - "yargs": "^14.2.3" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "dev": true, - "requires": { - "locate-path": "^3.0.0" - } - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "dev": true, - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "p-limit": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", - "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "dev": true, - "requires": { - "p-limit": "^2.0.0" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", - "dev": true - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "yargs": { - "version": "14.2.3", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-14.2.3.tgz", - "integrity": "sha512-ZbotRWhF+lkjijC/VhmOT9wSgyBQ7+zr13+YLkhfsSiTriYsMzkTUFP18pFhWwBeMa5gUc1MzbhrO6/VB7c9Xg==", - "dev": true, - "requires": { - "cliui": "^5.0.0", - "decamelize": "^1.2.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^15.0.1" - } - }, - "yargs-parser": { - "version": "15.0.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-15.0.1.tgz", - "integrity": "sha512-0OAMV2mAZQrs3FkNpDQcBk1x5HXb8X4twADss4S0Iuk+2dGnLOE/fRHrsYm542GduMveyA77OF4wrNJuanRCWw==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - } - } - }, "yn": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", diff --git a/packages/react/package.json b/packages/react/package.json index 46b471d8..eb0db404 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -17,14 +17,8 @@ "react": "^16.13.1" }, "devDependencies": { - "@types/react": "^16.9.49", - "react": "^16.13.1", - "@types/chai": "^4.2.12", - "@types/mocha": "^8.0.2", "@types/node": "^14.6.0", - "chai": "^4.2.0", "eslint-config-prettier": "^6.11.0", - "mocha": "^8.1.1", "prettier": "2.0.5", "ts-node": "^8.10.2", "tsc-watch": "^4.1.0", From 8b6702ca21206adacf059f68ec65476c3d26587a Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Thu, 1 Oct 2020 20:54:08 +0200 Subject: [PATCH 12/15] Fixed wired 'super' issue --- packages/core/src/computed/index.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/packages/core/src/computed/index.ts b/packages/core/src/computed/index.ts index f4da511c..603223e7 100644 --- a/packages/core/src/computed/index.ts +++ b/packages/core/src/computed/index.ts @@ -26,7 +26,13 @@ export class Computed extends State } public get value(): ComputedValueType { - return super.value; + // Note can't use 'super.value' because of 'https://github.com/Microsoft/TypeScript/issues/338' + + // Add state to foundState (for auto tracking used states in computed functions) + if (this.agileInstance().runtime.trackState) + this.agileInstance().runtime.foundStates.add(this); + + return this._value; } From 38c302b8ebb8dbf804f1d0dc00f54cada285964f Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Fri, 2 Oct 2020 21:49:32 +0200 Subject: [PATCH 13/15] Moved test_integration from the folder 'react' to the folder 'core' because of wired type errors --- examples/react-typescript/src/core/index.ts | 4 ++-- .../core/tests/collection/functions/collect.function.spec.ts | 2 +- .../core/tests/collection/functions/remove.function.spec.ts | 2 +- .../core/tests/collection/functions/update.function.spec.ts | 2 +- packages/core/tests/collection/group/default.spec.ts | 2 +- .../tests/collection/group/functions/add.function.spec.ts | 2 +- .../tests/collection/group/functions/remove.function.spec.ts | 2 +- packages/core/tests/collection/selector/default.spec.ts | 2 +- .../collection/selector/functions/select.function.spec.ts | 2 +- packages/core/tests/computed/default.spec.ts | 2 +- .../computed/functions/updateComputeFunction.function.spec.ts | 4 ++-- packages/core/tests/event/functions/trigger.function.spec.ts | 2 +- packages/core/tests/state/functions/patch.function.spec.ts | 2 +- packages/core/tests/state/functions/reset.function.spec.ts | 2 +- packages/core/tests/state/functions/set.function.spec.ts | 2 +- packages/core/tests/state/functions/undo.function.spec.ts | 2 +- packages/core/tests/test_integration/ReadMe.md | 1 + .../tests/test_integration}/hooks/useAgile_Test.ts | 2 +- .../tests/test_integration}/hooks/useEvent_Test.ts | 2 +- .../{react/tests => core/tests/test_integration}/index.ts | 0 .../tests => core/tests/test_integration}/test.integration.ts | 2 +- 21 files changed, 22 insertions(+), 21 deletions(-) create mode 100644 packages/core/tests/test_integration/ReadMe.md rename packages/{react/tests => core/tests/test_integration}/hooks/useAgile_Test.ts (98%) rename packages/{react/tests => core/tests/test_integration}/hooks/useEvent_Test.ts (68%) rename packages/{react/tests => core/tests/test_integration}/index.ts (100%) rename packages/{react/tests => core/tests/test_integration}/test.integration.ts (86%) diff --git a/examples/react-typescript/src/core/index.ts b/examples/react-typescript/src/core/index.ts index d7676aef..d2d72cd6 100644 --- a/examples/react-typescript/src/core/index.ts +++ b/examples/react-typescript/src/core/index.ts @@ -4,8 +4,8 @@ export const App = new Agile({ logJobs: true, }); -export const MY_STATE = App.State("MyState", "my-state").persist(); -export const MY_STATE_2 = App.State("MyState2").persist("my-state2"); +export const MY_STATE = App.State("MyState", "my-state");//.persist(); +export const MY_STATE_2 = App.State("MyState2");//.persist("my-state2"); MY_STATE.watch("test", (value) => { console.log("Watch " + value); diff --git a/packages/core/tests/collection/functions/collect.function.spec.ts b/packages/core/tests/collection/functions/collect.function.spec.ts index 476d5358..deea14f7 100644 --- a/packages/core/tests/collection/functions/collect.function.spec.ts +++ b/packages/core/tests/collection/functions/collect.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Group, Agile} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; describe('Collect Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/remove.function.spec.ts b/packages/core/tests/collection/functions/remove.function.spec.ts index 95678392..ce490945 100644 --- a/packages/core/tests/collection/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/functions/remove.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Item} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; describe('Remove Function Tests', () => { // Define Agile diff --git a/packages/core/tests/collection/functions/update.function.spec.ts b/packages/core/tests/collection/functions/update.function.spec.ts index 88d4ba15..6798d92b 100644 --- a/packages/core/tests/collection/functions/update.function.spec.ts +++ b/packages/core/tests/collection/functions/update.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Group} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; describe('Update Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/collection/group/default.spec.ts b/packages/core/tests/collection/group/default.spec.ts index 09f4a1a2..afc85def 100644 --- a/packages/core/tests/collection/group/default.spec.ts +++ b/packages/core/tests/collection/group/default.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from "chai"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; import {Agile, Group} from "../../../src"; describe('Default Group Tests', () => { diff --git a/packages/core/tests/collection/group/functions/add.function.spec.ts b/packages/core/tests/collection/group/functions/add.function.spec.ts index 15eaf02c..441a7380 100644 --- a/packages/core/tests/collection/group/functions/add.function.spec.ts +++ b/packages/core/tests/collection/group/functions/add.function.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from "chai"; -import {useAgile_Test} from "../../../../../react/tests"; +import {useAgile_Test} from "../../../test_integration"; import {Agile, Group} from "../../../../src"; describe('Add function Tests', () => { diff --git a/packages/core/tests/collection/group/functions/remove.function.spec.ts b/packages/core/tests/collection/group/functions/remove.function.spec.ts index 322dfcb4..1f3cc480 100644 --- a/packages/core/tests/collection/group/functions/remove.function.spec.ts +++ b/packages/core/tests/collection/group/functions/remove.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from "chai"; import {Agile, Group} from "../../../../src"; -import {useAgile_Test} from "../../../../../react/tests"; +import {useAgile_Test} from "../../../test_integration"; describe('Add function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/collection/selector/default.spec.ts b/packages/core/tests/collection/selector/default.spec.ts index ac608c99..61683127 100644 --- a/packages/core/tests/collection/selector/default.spec.ts +++ b/packages/core/tests/collection/selector/default.spec.ts @@ -1,6 +1,6 @@ import 'mocha'; import {expect} from "chai"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; import {Agile, Selector, Item} from "../../../src"; describe('Default Selector Tests', () => { diff --git a/packages/core/tests/collection/selector/functions/select.function.spec.ts b/packages/core/tests/collection/selector/functions/select.function.spec.ts index 08b9b0c2..6891ac7b 100644 --- a/packages/core/tests/collection/selector/functions/select.function.spec.ts +++ b/packages/core/tests/collection/selector/functions/select.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from "chai"; import {Agile, Selector, Item} from "../../../../src"; -import {useAgile_Test} from "../../../../../react/tests"; +import {useAgile_Test} from "../../../test_integration"; describe('select Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/computed/default.spec.ts b/packages/core/tests/computed/default.spec.ts index e0ce80a8..b6ad74a5 100644 --- a/packages/core/tests/computed/default.spec.ts +++ b/packages/core/tests/computed/default.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Computed} from "../../src"; -import {useAgile_Test} from "../../../react/tests"; +import {useAgile_Test} from "../test_integration"; describe('Default Computed Tests', () => { // Define Agile diff --git a/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts index 7b011eaa..e047bcb2 100644 --- a/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts +++ b/packages/core/tests/computed/functions/updateComputeFunction.function.spec.ts @@ -1,9 +1,9 @@ import 'mocha'; import {expect} from 'chai'; import {Agile, Computed} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; -describe('updateComputeFunction Function tests', () => { +describe('updateComputeFunction Function test_integration', () => { let rerenderCount = 0; // Define Agile diff --git a/packages/core/tests/event/functions/trigger.function.spec.ts b/packages/core/tests/event/functions/trigger.function.spec.ts index f988ca81..c6b6f874 100644 --- a/packages/core/tests/event/functions/trigger.function.spec.ts +++ b/packages/core/tests/event/functions/trigger.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useEvent_Test} from "../../../../react/tests"; +import {useEvent_Test} from "../../test_integration"; describe('Trigger Function Tests', () => { diff --git a/packages/core/tests/state/functions/patch.function.spec.ts b/packages/core/tests/state/functions/patch.function.spec.ts index 45c199da..feaeb06b 100644 --- a/packages/core/tests/state/functions/patch.function.spec.ts +++ b/packages/core/tests/state/functions/patch.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; describe('Patch Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/state/functions/reset.function.spec.ts b/packages/core/tests/state/functions/reset.function.spec.ts index 9b94d531..d12edd91 100644 --- a/packages/core/tests/state/functions/reset.function.spec.ts +++ b/packages/core/tests/state/functions/reset.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; describe('Reset Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/state/functions/set.function.spec.ts b/packages/core/tests/state/functions/set.function.spec.ts index b9d3d550..1c3e4b93 100644 --- a/packages/core/tests/state/functions/set.function.spec.ts +++ b/packages/core/tests/state/functions/set.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; describe('Set Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/state/functions/undo.function.spec.ts b/packages/core/tests/state/functions/undo.function.spec.ts index 66356fc8..ecd73978 100644 --- a/packages/core/tests/state/functions/undo.function.spec.ts +++ b/packages/core/tests/state/functions/undo.function.spec.ts @@ -1,7 +1,7 @@ import 'mocha'; import {expect} from 'chai'; import {Agile} from "../../../src"; -import {useAgile_Test} from "../../../../react/tests"; +import {useAgile_Test} from "../../test_integration"; describe('Undo Function Tests', () => { let rerenderCount = 0; diff --git a/packages/core/tests/test_integration/ReadMe.md b/packages/core/tests/test_integration/ReadMe.md new file mode 100644 index 00000000..5f070e83 --- /dev/null +++ b/packages/core/tests/test_integration/ReadMe.md @@ -0,0 +1 @@ +Has to be in this package otherwise wired type errors will occur \ No newline at end of file diff --git a/packages/react/tests/hooks/useAgile_Test.ts b/packages/core/tests/test_integration/hooks/useAgile_Test.ts similarity index 98% rename from packages/react/tests/hooks/useAgile_Test.ts rename to packages/core/tests/test_integration/hooks/useAgile_Test.ts index 41c9382e..458716e5 100644 --- a/packages/react/tests/hooks/useAgile_Test.ts +++ b/packages/core/tests/test_integration/hooks/useAgile_Test.ts @@ -1,4 +1,4 @@ -import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '@agile-ts/core'; +import {Group, State, Collection, Agile, getAgileInstance, normalizeArray} from '../../../src'; //========================================================================================================= diff --git a/packages/react/tests/hooks/useEvent_Test.ts b/packages/core/tests/test_integration/hooks/useEvent_Test.ts similarity index 68% rename from packages/react/tests/hooks/useEvent_Test.ts rename to packages/core/tests/test_integration/hooks/useEvent_Test.ts index 62f16b4e..fd9f78b4 100644 --- a/packages/react/tests/hooks/useEvent_Test.ts +++ b/packages/core/tests/test_integration/hooks/useEvent_Test.ts @@ -1,4 +1,4 @@ -import {Event, EventCallbackFunction} from '@agile-ts/core'; +import {Event, EventCallbackFunction} from '../../../src'; export function useEvent_Test(event: E, callback: EventCallbackFunction) { event.on(callback); diff --git a/packages/react/tests/index.ts b/packages/core/tests/test_integration/index.ts similarity index 100% rename from packages/react/tests/index.ts rename to packages/core/tests/test_integration/index.ts diff --git a/packages/react/tests/test.integration.ts b/packages/core/tests/test_integration/test.integration.ts similarity index 86% rename from packages/react/tests/test.integration.ts rename to packages/core/tests/test_integration/test.integration.ts index b2e68b18..48129b0e 100644 --- a/packages/react/tests/test.integration.ts +++ b/packages/core/tests/test_integration/test.integration.ts @@ -1,4 +1,4 @@ -import {Agile, Integration} from '@agile-ts/core' +import {Agile, Integration} from '../../src'; const testIntegration = new Integration({ name: 'test', From ec13a89350bac829c54919ed9fb97f2c598e0421 Mon Sep 17 00:00:00 2001 From: Benno Kohrs Date: Fri, 2 Oct 2020 22:08:54 +0200 Subject: [PATCH 14/15] Updated readme and counted version to 0.0.3 --- ReadMe.md | 17 +++++++++++++---- packages/api/package.json | 2 +- packages/core/package.json | 2 +- packages/react/package.json | 2 +- 4 files changed, 16 insertions(+), 7 deletions(-) diff --git a/ReadMe.md b/ReadMe.md index c59d282b..f8535e3b 100644 --- a/ReadMe.md +++ b/ReadMe.md @@ -1,14 +1,23 @@ -# Agile Framework `1.0.2` +# Agile Framework `v0.0.3` _Agile is a global state and logic framework for reactive Typescript & Javascript applications. Supporting frameworks like React and React Native._ #### Agile is strongly inspired by [PulseJs](https://github.com/pulse-framework/pulse) -It was mainly created to learn how Pulse works under the hood, and it was fun to 'copy' and optimize PulseJs. -I will use this project mainly for my own projects because here the code style is after my taste.. -So I can change things quickly and don't have to deal with a big framework which is used by many people and must function perfectly. +It was mainly created to learn how PulseJs works under the hood, and it was fun to 'copy' and optimize PulseJs. +This framework will mainly be used for my own projects because here I can make changes quickly without having fear to damage big projects from other people.. +because nearly every app depends on a state-management framework.. and if that doesn't work properly the app won't too + ##### Feel free to use it but be aware that it is optimized to my needs and has no [docs](https://pulsejs.org/) +| Name | Latest Version | +| ------------------------------------------------------------------------ | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | +| [@agile-ts/core](/packages/core) | [![badge](https://img.shields.io/npm/v/@agile-ts/core.svg?style=flat-square)](https://www.npmjs.com/package/@react-navigation/core) | +| [@agile-ts/react](/packages/react) | [![badge](https://img.shields.io/npm/v/@agile-ts/react.svg?style=flat-square)](https://www.npmjs.com/package/@react-navigation/native) | +| [@agile-ts/api](/packages/api) | [![badge](https://img.shields.io/npm/v/@agile-ts/api.svg?style=flat-square)](https://www.npmjs.com/package/@react-navigation/routers) | +
+ + diff --git a/packages/api/package.json b/packages/api/package.json index 895151f7..f25b3948 100644 --- a/packages/api/package.json +++ b/packages/api/package.json @@ -1,6 +1,6 @@ { "name": "@agile-ts/api", - "version": "0.0.2", + "version": "0.0.3", "author": "BennoDev", "license": "ISC", "description": "API extension for AgileTs", diff --git a/packages/core/package.json b/packages/core/package.json index 0d44bee3..62fff745 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@agile-ts/core", - "version": "0.0.2", + "version": "0.0.3", "author": "BennoDev", "license": "ISC", "description": "Global state and logic framework for reactive JavaScript & TypeScript applications.", diff --git a/packages/react/package.json b/packages/react/package.json index eb0db404..71342e94 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@agile-ts/react", - "version": "0.0.2", + "version": "0.0.3", "author": "BennoDev", "license": "ISC", "description": "React extension for AgileTs", From f78e1d9a1fe80921f2347e86ec5de722c054d7a1 Mon Sep 17 00:00:00 2001 From: BennoDev <57860196+bennodev19@users.noreply.github.com> Date: Sat, 3 Oct 2020 12:19:51 +0200 Subject: [PATCH 15/15] Update ReadMe.md Fixed pacakge link --- ReadMe.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ReadMe.md b/ReadMe.md index f8535e3b..01eb2122 100644 --- a/ReadMe.md +++ b/ReadMe.md @@ -12,9 +12,9 @@ because nearly every app depends on a state-management framework.. and if that d | Name | Latest Version | | ------------------------------------------------------------------------ | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | -| [@agile-ts/core](/packages/core) | [![badge](https://img.shields.io/npm/v/@agile-ts/core.svg?style=flat-square)](https://www.npmjs.com/package/@react-navigation/core) | -| [@agile-ts/react](/packages/react) | [![badge](https://img.shields.io/npm/v/@agile-ts/react.svg?style=flat-square)](https://www.npmjs.com/package/@react-navigation/native) | -| [@agile-ts/api](/packages/api) | [![badge](https://img.shields.io/npm/v/@agile-ts/api.svg?style=flat-square)](https://www.npmjs.com/package/@react-navigation/routers) | +| [@agile-ts/core](/packages/core) | [![badge](https://img.shields.io/npm/v/@agile-ts/core.svg?style=flat-square)](https://www.npmjs.com/package/@agile-ts/core) | +| [@agile-ts/react](/packages/react) | [![badge](https://img.shields.io/npm/v/@agile-ts/react.svg?style=flat-square)](https://www.npmjs.com/package/@agile-ts/react) | +| [@agile-ts/api](/packages/api) | [![badge](https://img.shields.io/npm/v/@agile-ts/api.svg?style=flat-square)](https://www.npmjs.com/package/@agile-ts/api) |