From 89c2ff64b98602abe83c2fa992c7978f27171cdb Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Thu, 17 Aug 2023 20:52:11 -0600 Subject: [PATCH 001/134] Add skeleton application methods --- src/CONST.js | 4 ++ src/libs/Middleware/SaveResponseInOnyx.js | 50 ++++++++++++++--------- src/libs/actions/App.js | 32 ++++++++++++++- src/libs/actions/OnyxUpdates.js | 10 ++++- src/libs/actions/User.js | 21 +++++++--- 5 files changed, 88 insertions(+), 29 deletions(-) diff --git a/src/CONST.js b/src/CONST.js index 6920f8fbcc64..dc31da3f37b4 100755 --- a/src/CONST.js +++ b/src/CONST.js @@ -2552,6 +2552,10 @@ const CONST = { NAVIGATE: 'NAVIGATE', }, }, + ONYX_UPDATE_TYPES: { + HTTPS: 'https', + PUSHER: 'pusher', + }, }; export default CONST; diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index b347e45ab61c..895a94f5f9fb 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -16,29 +16,39 @@ function SaveResponseInOnyx(response, request) { } // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server - OnyxUpdates.saveUpdateIDs(Number(responseData.lastUpdateID || 0), Number(responseData.previousUpdateID || 0)); + OnyxUpdates.saveUpdateIDs( + { + updateType: CONST.ONYX_UPDATE_TYPES.HTTPS, + data: { + request, + response, + }, + }, + Number(responseData.lastUpdateID || 0), + Number(responseData.previousUpdateID || 0), + ); - // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in - // the UI. See https://github.com/Expensify/App/issues/12775 for more info. - const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; + // // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in + // // the UI. See https://github.com/Expensify/App/issues/12775 for more info. + // const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; - // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then - // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained - // in successData/failureData until after the component has received and API data. - const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); + // // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then + // // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained + // // in successData/failureData until after the component has received and API data. + // const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); - return onyxDataUpdatePromise - .then(() => { - // Handle the request's success/failure data (client-side data) - if (responseData.jsonCode === 200 && request.successData) { - return updateHandler(request.successData); - } - if (responseData.jsonCode !== 200 && request.failureData) { - return updateHandler(request.failureData); - } - return Promise.resolve(); - }) - .then(() => responseData); + // return onyxDataUpdatePromise + // .then(() => { + // // Handle the request's success/failure data (client-side data) + // if (responseData.jsonCode === 200 && request.successData) { + // return updateHandler(request.successData); + // } + // if (responseData.jsonCode !== 200 && request.failureData) { + // return updateHandler(request.failureData); + // } + // return Promise.resolve(); + // }) + // .then(() => responseData); }); } diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index d82c1e78fe0c..b33a90ab3fc0 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -234,6 +234,36 @@ function getMissingOnyxUpdates(updateIDFrom = 0, updateIDTo = 0) { // The next 40ish lines of code are used for detecting when there is a gap of OnyxUpdates between what was last applied to the client and the updates the server has. // When a gap is detected, the missing updates are fetched from the API. +/** + * @param {Object} data + * @param {Object} data.request + * @param {Object} data.response + */ +function applyHTTPSOnyxUpdates({request, response}) {} + +/** + * @param {Object} data + * @param {Object} data.onyxData + */ +function applyPusherOnyxUpdates({onyxData}) {} + +/** + * @param {Object[]} updateParams + * @param {String} updateParams.type + * @param {Object} updateParams.data + * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.onyxData] Exists if updateParams.type === 'pusher' + */ +function applyOnyxUpdates({type, data}) { + if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { + applyHTTPSOnyxUpdates(data); + } + if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { + applyPusherOnyxUpdates(data); + } +} + // These key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated let lastUpdateIDAppliedToClient = 0; Onyx.connect({ @@ -248,7 +278,7 @@ Onyx.connect({ return; } - const {lastUpdateIDFromServer, previousUpdateIDFromServer} = val; + const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; console.debug('[OnyxUpdates] Received lastUpdateID from server', lastUpdateIDFromServer); console.debug('[OnyxUpdates] Received previousUpdateID from server', previousUpdateIDFromServer); console.debug('[OnyxUpdates] Last update ID applied to the client', lastUpdateIDAppliedToClient); diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index e582016f0109..96cee3a228bc 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -2,11 +2,16 @@ import Onyx from 'react-native-onyx'; import ONYXKEYS from '../../ONYXKEYS'; /** - * + * @param {Object[]} updateParams + * @param {String} updateParams.type + * @param {Object} updateParams.data + * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.onyxData] Exists if updateParams.type === 'pusher' * @param {Number} [lastUpdateID] * @param {Number} [previousUpdateID] */ -function saveUpdateIDs(lastUpdateID = 0, previousUpdateID = 0) { +function saveUpdateIDs(updateParams, lastUpdateID = 0, previousUpdateID = 0) { // Return early if there were no updateIDs if (!lastUpdateID) { return; @@ -15,6 +20,7 @@ function saveUpdateIDs(lastUpdateID = 0, previousUpdateID = 0) { Onyx.merge(ONYXKEYS.ONYX_UPDATES_FROM_SERVER, { lastUpdateIDFromServer: lastUpdateID, previousUpdateIDFromServer: previousUpdateID, + updateParams, }); } diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index 9648b77220ac..92c0e805017d 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -552,13 +552,22 @@ function subscribeToUserEvents() { // lastUpdateID, previousUpdateID and updates if (_.isArray(pushJSON)) { updates = pushJSON; - } else { - updates = pushJSON.updates; - OnyxUpdates.saveUpdateIDs(Number(pushJSON.lastUpdateID || 0), Number(pushJSON.previousUpdateID || 0)); + _.each(updates, (multipleEvent) => { + PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); + }); + return; } - _.each(updates, (multipleEvent) => { - PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); - }); + + OnyxUpdates.saveUpdateIDs( + { + updateType: CONST.ONYX_UPDATE_TYPES.PUSHER, + data: { + onyxUpdates: pushJSON.updates, + }, + }, + Number(pushJSON.lastUpdateID || 0), + Number(pushJSON.previousUpdateID || 0), + ); }); // Handles Onyx updates coming from Pusher through the mega multipleEvents. From 424f9e9dc2cff25644a929dbaed88bf63397442f Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Thu, 17 Aug 2023 21:07:18 -0600 Subject: [PATCH 002/134] Build update application methods --- src/libs/Middleware/SaveResponseInOnyx.js | 26 +------------ src/libs/actions/App.js | 45 ++++++++++++++++++++--- src/libs/actions/OnyxUpdates.js | 4 +- src/libs/actions/User.js | 2 +- 4 files changed, 44 insertions(+), 33 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 895a94f5f9fb..695b050610e6 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -1,6 +1,4 @@ -import Onyx from 'react-native-onyx'; import CONST from '../../CONST'; -import * as QueuedOnyxUpdates from '../actions/QueuedOnyxUpdates'; import * as OnyxUpdates from '../actions/OnyxUpdates'; /** @@ -21,34 +19,14 @@ function SaveResponseInOnyx(response, request) { updateType: CONST.ONYX_UPDATE_TYPES.HTTPS, data: { request, - response, + responseData, }, }, Number(responseData.lastUpdateID || 0), Number(responseData.previousUpdateID || 0), ); - // // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in - // // the UI. See https://github.com/Expensify/App/issues/12775 for more info. - // const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; - - // // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then - // // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained - // // in successData/failureData until after the component has received and API data. - // const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); - - // return onyxDataUpdatePromise - // .then(() => { - // // Handle the request's success/failure data (client-side data) - // if (responseData.jsonCode === 200 && request.successData) { - // return updateHandler(request.successData); - // } - // if (responseData.jsonCode !== 200 && request.failureData) { - // return updateHandler(request.failureData); - // } - // return Promise.resolve(); - // }) - // .then(() => responseData); + return responseData; }); } diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index b33a90ab3fc0..c4114e05d100 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -19,6 +19,8 @@ import * as ReportActionsUtils from '../ReportActionsUtils'; import Timing from './Timing'; import * as Browser from '../Browser'; import * as SequentialQueue from '../Network/SequentialQueue'; +import PusherUtils from '../PusherUtils'; +import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; let currentUserAccountID; let currentUserEmail; @@ -237,15 +239,41 @@ function getMissingOnyxUpdates(updateIDFrom = 0, updateIDTo = 0) { /** * @param {Object} data * @param {Object} data.request - * @param {Object} data.response + * @param {Object} data.responseData */ -function applyHTTPSOnyxUpdates({request, response}) {} +function applyHTTPSOnyxUpdates({request, responseData}) { + // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in + // the UI. See https://github.com/Expensify/App/issues/12775 for more info. + const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; + + // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then + // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained + // in successData/failureData until after the component has received and API data. + const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); + + onyxDataUpdatePromise + .then(() => { + // Handle the request's success/failure data (client-side data) + if (responseData.jsonCode === 200 && request.successData) { + return updateHandler(request.successData); + } + if (responseData.jsonCode !== 200 && request.failureData) { + return updateHandler(request.failureData); + } + return Promise.resolve(); + }) + .then(() => responseData); +} /** * @param {Object} data - * @param {Object} data.onyxData + * @param {Object} data.multipleEvents */ -function applyPusherOnyxUpdates({onyxData}) {} +function applyPusherOnyxUpdates({multipleEvents}) { + _.each(multipleEvents, (multipleEvent) => { + PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); + }); +} /** * @param {Object[]} updateParams @@ -253,7 +281,7 @@ function applyPusherOnyxUpdates({onyxData}) {} * @param {Object} updateParams.data * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.onyxData] Exists if updateParams.type === 'pusher' + * @param {Object} [updateParams.data.multipleEvents] Exists if updateParams.type === 'pusher' */ function applyOnyxUpdates({type, data}) { if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { @@ -293,7 +321,12 @@ Onyx.connect({ lastUpdateIDAppliedToClient, }); SequentialQueue.pause(); - getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(SequentialQueue.unpause); + getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { + applyOnyxUpdates(updateParams); + SequentialQueue.unpause(); + }); + } else { + applyOnyxUpdates(updateParams); } if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 96cee3a228bc..6e8dffc1b047 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -6,8 +6,8 @@ import ONYXKEYS from '../../ONYXKEYS'; * @param {String} updateParams.type * @param {Object} updateParams.data * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.onyxData] Exists if updateParams.type === 'pusher' + * @param {Object} [updateParams.data.responseData] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.multipleEvents] Exists if updateParams.type === 'pusher' * @param {Number} [lastUpdateID] * @param {Number} [previousUpdateID] */ diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index 92c0e805017d..30d5af52decd 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -562,7 +562,7 @@ function subscribeToUserEvents() { { updateType: CONST.ONYX_UPDATE_TYPES.PUSHER, data: { - onyxUpdates: pushJSON.updates, + multipleEvents: pushJSON.updates, }, }, Number(pushJSON.lastUpdateID || 0), From 59fd99f7f57bcecdde9968b03b381168c7d36cd9 Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Thu, 17 Aug 2023 21:32:29 -0600 Subject: [PATCH 003/134] Use a promise to know when updates are done --- src/libs/actions/App.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index c4114e05d100..3ae191390014 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -240,6 +240,7 @@ function getMissingOnyxUpdates(updateIDFrom = 0, updateIDTo = 0) { * @param {Object} data * @param {Object} data.request * @param {Object} data.responseData + * @returns {Promise} */ function applyHTTPSOnyxUpdates({request, responseData}) { // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in @@ -251,7 +252,7 @@ function applyHTTPSOnyxUpdates({request, responseData}) { // in successData/failureData until after the component has received and API data. const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); - onyxDataUpdatePromise + return onyxDataUpdatePromise .then(() => { // Handle the request's success/failure data (client-side data) if (responseData.jsonCode === 200 && request.successData) { @@ -270,6 +271,7 @@ function applyHTTPSOnyxUpdates({request, responseData}) { * @param {Object} data.multipleEvents */ function applyPusherOnyxUpdates({multipleEvents}) { + console.log('timxxx', 1, multipleEvents); _.each(multipleEvents, (multipleEvent) => { PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); }); @@ -282,13 +284,15 @@ function applyPusherOnyxUpdates({multipleEvents}) { * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.multipleEvents] Exists if updateParams.type === 'pusher' + * @returns {Promise} */ function applyOnyxUpdates({type, data}) { if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { - applyHTTPSOnyxUpdates(data); + return applyHTTPSOnyxUpdates(data); } if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { applyPusherOnyxUpdates(data); + return new Promise().resolve(); } } @@ -322,8 +326,7 @@ Onyx.connect({ }); SequentialQueue.pause(); getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { - applyOnyxUpdates(updateParams); - SequentialQueue.unpause(); + applyOnyxUpdates(updateParams).then(SequentialQueue.unpause); }); } else { applyOnyxUpdates(updateParams); From ea1ebe33913ea621f75a85d407354bc0cbe15d34 Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Thu, 17 Aug 2023 21:48:20 -0600 Subject: [PATCH 004/134] Remove debug --- src/libs/actions/App.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index 3ae191390014..a0e4289ddb11 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -271,7 +271,6 @@ function applyHTTPSOnyxUpdates({request, responseData}) { * @param {Object} data.multipleEvents */ function applyPusherOnyxUpdates({multipleEvents}) { - console.log('timxxx', 1, multipleEvents); _.each(multipleEvents, (multipleEvent) => { PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); }); From b9ecfc78f2497c8c10abfc0a25a11a83134e48bb Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Sat, 19 Aug 2023 13:31:10 -0600 Subject: [PATCH 005/134] Refactor the location of code --- src/libs/actions/App.js | 109 +---------------------- src/libs/actions/OnyxUpdatesManager.js | 116 +++++++++++++++++++++++++ 2 files changed, 117 insertions(+), 108 deletions(-) create mode 100644 src/libs/actions/OnyxUpdatesManager.js diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index 098e99063fc7..56a313e81c0b 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -18,9 +18,6 @@ import * as Session from './Session'; import * as ReportActionsUtils from '../ReportActionsUtils'; import Timing from './Timing'; import * as Browser from '../Browser'; -import * as SequentialQueue from '../Network/SequentialQueue'; -import PusherUtils from '../PusherUtils'; -import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; let currentUserAccountID; let currentUserEmail; @@ -233,111 +230,6 @@ function getMissingOnyxUpdates(updateIDFrom = 0, updateIDTo = 0) { ); } -// The next 40ish lines of code are used for detecting when there is a gap of OnyxUpdates between what was last applied to the client and the updates the server has. -// When a gap is detected, the missing updates are fetched from the API. - -/** - * @param {Object} data - * @param {Object} data.request - * @param {Object} data.responseData - * @returns {Promise} - */ -function applyHTTPSOnyxUpdates({request, responseData}) { - // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in - // the UI. See https://github.com/Expensify/App/issues/12775 for more info. - const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; - - // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then - // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained - // in successData/failureData until after the component has received and API data. - const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); - - return onyxDataUpdatePromise - .then(() => { - // Handle the request's success/failure data (client-side data) - if (responseData.jsonCode === 200 && request.successData) { - return updateHandler(request.successData); - } - if (responseData.jsonCode !== 200 && request.failureData) { - return updateHandler(request.failureData); - } - return Promise.resolve(); - }) - .then(() => responseData); -} - -/** - * @param {Object} data - * @param {Object} data.multipleEvents - */ -function applyPusherOnyxUpdates({multipleEvents}) { - _.each(multipleEvents, (multipleEvent) => { - PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); - }); -} - -/** - * @param {Object[]} updateParams - * @param {String} updateParams.type - * @param {Object} updateParams.data - * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.multipleEvents] Exists if updateParams.type === 'pusher' - * @returns {Promise} - */ -function applyOnyxUpdates({type, data}) { - if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { - return applyHTTPSOnyxUpdates(data); - } - if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { - applyPusherOnyxUpdates(data); - return new Promise().resolve(); - } -} - -// These key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated -let lastUpdateIDAppliedToClient = 0; -Onyx.connect({ - key: ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, - callback: (val) => (lastUpdateIDAppliedToClient = val), -}); - -Onyx.connect({ - key: ONYXKEYS.ONYX_UPDATES_FROM_SERVER, - callback: (val) => { - if (!val) { - return; - } - - const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; - console.debug('[OnyxUpdates] Received lastUpdateID from server', lastUpdateIDFromServer); - console.debug('[OnyxUpdates] Received previousUpdateID from server', previousUpdateIDFromServer); - console.debug('[OnyxUpdates] Last update ID applied to the client', lastUpdateIDAppliedToClient); - - // If the previous update from the server does not match the last update the client got, then the client is missing some updates. - // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. - if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { - console.debug('[OnyxUpdates] Gap detected in update IDs so fetching incremental updates'); - Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { - lastUpdateIDFromServer, - previousUpdateIDFromServer, - lastUpdateIDAppliedToClient, - }); - SequentialQueue.pause(); - getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { - applyOnyxUpdates(updateParams).then(SequentialQueue.unpause); - }); - } else { - applyOnyxUpdates(updateParams); - } - - if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { - // Update this value so that it matches what was just received from the server - Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateIDFromServer || 0); - } - }, -}); - /** * This promise is used so that deeplink component know when a transition is end. * This is necessary because we want to begin deeplink redirection after the transition is end. @@ -542,4 +434,5 @@ export { beginDeepLinkRedirect, beginDeepLinkRedirectAfterTransition, createWorkspaceAndNavigateToIt, + getMissingOnyxUpdates, }; diff --git a/src/libs/actions/OnyxUpdatesManager.js b/src/libs/actions/OnyxUpdatesManager.js new file mode 100644 index 000000000000..cdfa610cd146 --- /dev/null +++ b/src/libs/actions/OnyxUpdatesManager.js @@ -0,0 +1,116 @@ +import _ from 'underscore'; +import Onyx from 'react-native-onyx'; +import ONYXKEYS from '../../ONYXKEYS'; +import CONST from '../../CONST'; +import Log from '../Log'; +import * as SequentialQueue from '../Network/SequentialQueue'; +import PusherUtils from '../PusherUtils'; +import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; +import * as App from './App'; + +// The next 40ish lines of code are used for detecting when there is a gap of OnyxUpdates between what was last applied to the client and the updates the server has. +// When a gap is detected, the missing updates are fetched from the API. + +/** + * @param {Object} data + * @param {Object} data.request + * @param {Object} data.responseData + * @returns {Promise} + */ +function applyHTTPSOnyxUpdates({request, responseData}) { + // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in + // the UI. See https://github.com/Expensify/App/issues/12775 for more info. + const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; + + // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then + // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained + // in successData/failureData until after the component has received and API data. + const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); + + return onyxDataUpdatePromise + .then(() => { + // Handle the request's success/failure data (client-side data) + if (responseData.jsonCode === 200 && request.successData) { + return updateHandler(request.successData); + } + if (responseData.jsonCode !== 200 && request.failureData) { + return updateHandler(request.failureData); + } + return Promise.resolve(); + }) + .then(() => responseData); +} + +/** + * @param {Object} data + * @param {Object} data.multipleEvents + */ +function applyPusherOnyxUpdates({multipleEvents}) { + _.each(multipleEvents, (multipleEvent) => { + PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); + }); +} + +/** + * @param {Object[]} updateParams + * @param {String} updateParams.type + * @param {Object} updateParams.data + * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.multipleEvents] Exists if updateParams.type === 'pusher' + * @returns {Promise} + */ +function applyOnyxUpdates({type, data}) { + if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { + return applyHTTPSOnyxUpdates(data); + } + if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { + applyPusherOnyxUpdates(data); + return new Promise().resolve(); + } +} + +// This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated +let lastUpdateIDAppliedToClient = 0; +Onyx.connect({ + key: ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, + callback: (val) => (lastUpdateIDAppliedToClient = val), +}); + +Onyx.connect({ + key: ONYXKEYS.ONYX_UPDATES_FROM_SERVER, + callback: (val) => { + if (!val) { + return; + } + + const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; + console.debug('[OnyxUpdates] Received lastUpdateID from server', lastUpdateIDFromServer); + console.debug('[OnyxUpdates] Received previousUpdateID from server', previousUpdateIDFromServer); + console.debug('[OnyxUpdates] Last update ID applied to the client', lastUpdateIDAppliedToClient); + + // If the previous update from the server does not match the last update the client got, then the client is missing some updates. + // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. + if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { + console.debug('[OnyxUpdates] Gap detected in update IDs so fetching incremental updates'); + Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { + lastUpdateIDFromServer, + previousUpdateIDFromServer, + lastUpdateIDAppliedToClient, + }); + + SequentialQueue.pause(); + + App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { + applyOnyxUpdates(updateParams).then(SequentialQueue.unpause); + }); + } else { + applyOnyxUpdates(updateParams); + } + + if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { + // Update this value so that it matches what was just received from the server + Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateIDFromServer || 0); + } + }, +}); From 842ec64cc4167f68d0d679dbb809875b59428989 Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Sat, 19 Aug 2023 13:32:57 -0600 Subject: [PATCH 006/134] Start the update manager from authscreens --- .../Navigation/AppNavigator/AuthScreens.js | 2 + src/libs/actions/OnyxUpdatesManager.js | 66 ++++++++++--------- 2 files changed, 36 insertions(+), 32 deletions(-) diff --git a/src/libs/Navigation/AppNavigator/AuthScreens.js b/src/libs/Navigation/AppNavigator/AuthScreens.js index 7317306cdbe6..8078d1d8db84 100644 --- a/src/libs/Navigation/AppNavigator/AuthScreens.js +++ b/src/libs/Navigation/AppNavigator/AuthScreens.js @@ -35,6 +35,7 @@ import DesktopSignInRedirectPage from '../../../pages/signin/DesktopSignInRedire import styles from '../../../styles/styles'; import * as SessionUtils from '../../SessionUtils'; import getNavigationModalCardStyle from '../../../styles/getNavigationModalCardStyles'; +import OnyxUpdatesManager from '../../actions/OnyxUpdatesManager'; let timezone; let currentAccountID; @@ -125,6 +126,7 @@ class AuthScreens extends React.Component { } componentDidMount() { + OnyxUpdatesManager(); NetworkConnection.listenForReconnect(); NetworkConnection.onReconnect(() => App.reconnectApp(this.props.lastUpdateIDAppliedToClient)); PusherConnectionManager.init(); diff --git a/src/libs/actions/OnyxUpdatesManager.js b/src/libs/actions/OnyxUpdatesManager.js index cdfa610cd146..38a021ae4540 100644 --- a/src/libs/actions/OnyxUpdatesManager.js +++ b/src/libs/actions/OnyxUpdatesManager.js @@ -77,40 +77,42 @@ Onyx.connect({ callback: (val) => (lastUpdateIDAppliedToClient = val), }); -Onyx.connect({ - key: ONYXKEYS.ONYX_UPDATES_FROM_SERVER, - callback: (val) => { - if (!val) { - return; - } +export default () => { + Onyx.connect({ + key: ONYXKEYS.ONYX_UPDATES_FROM_SERVER, + callback: (val) => { + if (!val) { + return; + } - const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; - console.debug('[OnyxUpdates] Received lastUpdateID from server', lastUpdateIDFromServer); - console.debug('[OnyxUpdates] Received previousUpdateID from server', previousUpdateIDFromServer); - console.debug('[OnyxUpdates] Last update ID applied to the client', lastUpdateIDAppliedToClient); + const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; + console.debug('[OnyxUpdates] Received lastUpdateID from server', lastUpdateIDFromServer); + console.debug('[OnyxUpdates] Received previousUpdateID from server', previousUpdateIDFromServer); + console.debug('[OnyxUpdates] Last update ID applied to the client', lastUpdateIDAppliedToClient); - // If the previous update from the server does not match the last update the client got, then the client is missing some updates. - // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. - if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { - console.debug('[OnyxUpdates] Gap detected in update IDs so fetching incremental updates'); - Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { - lastUpdateIDFromServer, - previousUpdateIDFromServer, - lastUpdateIDAppliedToClient, - }); + // If the previous update from the server does not match the last update the client got, then the client is missing some updates. + // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. + if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { + console.debug('[OnyxUpdates] Gap detected in update IDs so fetching incremental updates'); + Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { + lastUpdateIDFromServer, + previousUpdateIDFromServer, + lastUpdateIDAppliedToClient, + }); - SequentialQueue.pause(); + SequentialQueue.pause(); - App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { - applyOnyxUpdates(updateParams).then(SequentialQueue.unpause); - }); - } else { - applyOnyxUpdates(updateParams); - } + App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { + applyOnyxUpdates(updateParams).then(SequentialQueue.unpause); + }); + } else { + applyOnyxUpdates(updateParams); + } - if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { - // Update this value so that it matches what was just received from the server - Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateIDFromServer || 0); - } - }, -}); + if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { + // Update this value so that it matches what was just received from the server + Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateIDFromServer || 0); + } + }, + }); +}; From ba59617ccd7575fcab247daf2c4b6d0f405cdee4 Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Sat, 19 Aug 2023 13:34:13 -0600 Subject: [PATCH 007/134] Improve logging --- src/libs/actions/OnyxUpdatesManager.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/libs/actions/OnyxUpdatesManager.js b/src/libs/actions/OnyxUpdatesManager.js index 38a021ae4540..85120cdbd83b 100644 --- a/src/libs/actions/OnyxUpdatesManager.js +++ b/src/libs/actions/OnyxUpdatesManager.js @@ -78,6 +78,7 @@ Onyx.connect({ }); export default () => { + console.debug('[OnyxUpdateManager] Listening for updates from the server'); Onyx.connect({ key: ONYXKEYS.ONYX_UPDATES_FROM_SERVER, callback: (val) => { @@ -86,14 +87,14 @@ export default () => { } const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; - console.debug('[OnyxUpdates] Received lastUpdateID from server', lastUpdateIDFromServer); - console.debug('[OnyxUpdates] Received previousUpdateID from server', previousUpdateIDFromServer); - console.debug('[OnyxUpdates] Last update ID applied to the client', lastUpdateIDAppliedToClient); + console.debug('[OnyxUpdateManager] Received lastUpdateID from server', lastUpdateIDFromServer); + console.debug('[OnyxUpdateManager] Received previousUpdateID from server', previousUpdateIDFromServer); + console.debug('[OnyxUpdateManager] Last update ID applied to the client', lastUpdateIDAppliedToClient); // If the previous update from the server does not match the last update the client got, then the client is missing some updates. // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { - console.debug('[OnyxUpdates] Gap detected in update IDs so fetching incremental updates'); + console.debug('[OnyxUpdateManager] Gap detected in update IDs so fetching incremental updates'); Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { lastUpdateIDFromServer, previousUpdateIDFromServer, From 427043eb2e6fdb2ce7b7aa959d7d551937d626fb Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Sat, 19 Aug 2023 13:35:20 -0600 Subject: [PATCH 008/134] Rename method --- src/libs/Middleware/SaveResponseInOnyx.js | 2 +- src/libs/actions/OnyxUpdates.js | 4 ++-- src/libs/actions/User.js | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index db978b990751..c3bc66e86fbb 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -38,7 +38,7 @@ function SaveResponseInOnyx(response, request) { }); // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server - OnyxUpdates.saveUpdateIDs( + OnyxUpdates.saveUpdateInformation( { updateType: CONST.ONYX_UPDATE_TYPES.HTTPS, data: { diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 6e8dffc1b047..48ec66280fdd 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -11,7 +11,7 @@ import ONYXKEYS from '../../ONYXKEYS'; * @param {Number} [lastUpdateID] * @param {Number} [previousUpdateID] */ -function saveUpdateIDs(updateParams, lastUpdateID = 0, previousUpdateID = 0) { +function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID = 0) { // Return early if there were no updateIDs if (!lastUpdateID) { return; @@ -25,4 +25,4 @@ function saveUpdateIDs(updateParams, lastUpdateID = 0, previousUpdateID = 0) { } // eslint-disable-next-line import/prefer-default-export -export {saveUpdateIDs}; +export {saveUpdateInformation}; diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index bd018f1d3e15..c83bd3f37891 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -563,7 +563,7 @@ function subscribeToUserEvents() { return; } - OnyxUpdates.saveUpdateIDs( + OnyxUpdates.saveUpdateInformation( { updateType: CONST.ONYX_UPDATE_TYPES.PUSHER, data: { From ebe24bf6e1895536d27cd830c3951bd4e164f4fc Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Sat, 19 Aug 2023 13:55:26 -0600 Subject: [PATCH 009/134] Rename file and add promises to pusher events --- .../Navigation/AppNavigator/AuthScreens.js | 4 +- src/libs/PusherUtils.js | 5 ++- ...UpdatesManager.js => OnyxUpdateManager.js} | 45 ++++++++++++++++--- src/libs/actions/User.js | 12 +++-- 4 files changed, 52 insertions(+), 14 deletions(-) rename src/libs/actions/{OnyxUpdatesManager.js => OnyxUpdateManager.js} (69%) diff --git a/src/libs/Navigation/AppNavigator/AuthScreens.js b/src/libs/Navigation/AppNavigator/AuthScreens.js index 8078d1d8db84..dce177fe5d97 100644 --- a/src/libs/Navigation/AppNavigator/AuthScreens.js +++ b/src/libs/Navigation/AppNavigator/AuthScreens.js @@ -35,7 +35,7 @@ import DesktopSignInRedirectPage from '../../../pages/signin/DesktopSignInRedire import styles from '../../../styles/styles'; import * as SessionUtils from '../../SessionUtils'; import getNavigationModalCardStyle from '../../../styles/getNavigationModalCardStyles'; -import OnyxUpdatesManager from '../../actions/OnyxUpdatesManager'; +import OnyxUpdateManager from '../../actions/OnyxUpdateManager'; let timezone; let currentAccountID; @@ -126,7 +126,7 @@ class AuthScreens extends React.Component { } componentDidMount() { - OnyxUpdatesManager(); + OnyxUpdateManager(); NetworkConnection.listenForReconnect(); NetworkConnection.onReconnect(() => App.reconnectApp(this.props.lastUpdateIDAppliedToClient)); PusherConnectionManager.init(); diff --git a/src/libs/PusherUtils.js b/src/libs/PusherUtils.js index 9d84bd4012fe..7fdd12cf6296 100644 --- a/src/libs/PusherUtils.js +++ b/src/libs/PusherUtils.js @@ -18,12 +18,13 @@ function subscribeToMultiEvent(eventType, callback) { /** * @param {String} eventType * @param {Mixed} data + * @returns {Promise} */ function triggerMultiEventHandler(eventType, data) { if (!multiEventCallbackMapping[eventType]) { - return; + return new Promise().resolve(); } - multiEventCallbackMapping[eventType](data); + return multiEventCallbackMapping[eventType](data); } /** diff --git a/src/libs/actions/OnyxUpdatesManager.js b/src/libs/actions/OnyxUpdateManager.js similarity index 69% rename from src/libs/actions/OnyxUpdatesManager.js rename to src/libs/actions/OnyxUpdateManager.js index 85120cdbd83b..de9a928f6ee0 100644 --- a/src/libs/actions/OnyxUpdatesManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -38,16 +38,27 @@ function applyHTTPSOnyxUpdates({request, responseData}) { } return Promise.resolve(); }) - .then(() => responseData); + .then(() => { + console.debug('[OnyxUpdateManager] Done applying HTTPS update'); + }); } /** * @param {Object} data * @param {Object} data.multipleEvents + * @returns {Promise} */ function applyPusherOnyxUpdates({multipleEvents}) { - _.each(multipleEvents, (multipleEvent) => { - PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); + const pusherEventPromises = _.reduce( + multipleEvents, + (result, multipleEvent) => { + result.push(PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data)); + return result; + }, + [], + ); + return Promise.all(pusherEventPromises).then(() => { + console.debug('[OnyxUpdateManager] Done applying Pusher update'); }); } @@ -65,8 +76,7 @@ function applyOnyxUpdates({type, data}) { return applyHTTPSOnyxUpdates(data); } if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { - applyPusherOnyxUpdates(data); - return new Promise().resolve(); + return applyPusherOnyxUpdates(data); } } @@ -91,6 +101,14 @@ export default () => { console.debug('[OnyxUpdateManager] Received previousUpdateID from server', previousUpdateIDFromServer); console.debug('[OnyxUpdateManager] Last update ID applied to the client', lastUpdateIDAppliedToClient); + // This can happen when a user has just started getting reliable updates from the server but they haven't + // had an OpenApp or ReconnectApp call yet. This can result in never getting reliable updates because + // lastUpdateIDAppliedToClient will always be null. For this case, reconnectApp() will be triggered for them + // to kick start the reliable updates. + if (!lastUpdateIDAppliedToClient && previousUpdateIDFromServer > 0) { + App.reconnectApp(); + } + // If the previous update from the server does not match the last update the client got, then the client is missing some updates. // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { @@ -101,10 +119,25 @@ export default () => { lastUpdateIDAppliedToClient, }); + // Pause the sequential queue while the missing Onyx updates are fetched from the server. This is important + // so that the updates are applied in their correct and specific order. If this queue was not paused, then + // there would be a lot of onyx data being applied while we are fetching the missing updates and that would + // put them all out of order. SequentialQueue.pause(); App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { - applyOnyxUpdates(updateParams).then(SequentialQueue.unpause); + console.debug('[OnyxUpdateManager] Done Getting missing onyx updates'); + + // The onyx update from the initial request could have been either from HTTPS or Pusher. + // Now that the missing onyx updates have been applied, we can apply the original onyxUpdates from + // the API request. + applyOnyxUpdates(updateParams).then(() => { + console.debug('[OnyxUpdateManager] Done applying all updates'); + + // Finally, the missing updates were applied, the original update was applied, and now the + // sequential queue is free to continue. + SequentialQueue.unpause(); + }); }); } else { applyOnyxUpdates(updateParams); diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index c83bd3f37891..8822afd9ec08 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -576,17 +576,21 @@ function subscribeToUserEvents() { }); // Handles Onyx updates coming from Pusher through the mega multipleEvents. - PusherUtils.subscribeToMultiEvent(Pusher.TYPE.MULTIPLE_EVENT_TYPE.ONYX_API_UPDATE, (pushJSON) => { + PusherUtils.subscribeToMultiEvent(Pusher.TYPE.MULTIPLE_EVENT_TYPE.ONYX_API_UPDATE, (pushJSON) => SequentialQueue.getCurrentRequest().then(() => { // If we don't have the currentUserAccountID (user is logged out) we don't want to update Onyx with data from Pusher if (!currentUserAccountID) { return; } - Onyx.update(pushJSON); + const onyxUpdatePromise = Onyx.update(pushJSON); triggerNotifications(pushJSON); - }); - }); + + // Return a promise when Onyx is done updating so that the OnyxUpdatesManager can properly apply all + // the onyx updates in order + return onyxUpdatePromise; + }), + ); } /** From ff9a773ae32ff1b19530f714280fadf9b0525d69 Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Sat, 19 Aug 2023 13:57:53 -0600 Subject: [PATCH 010/134] Improve logs --- src/libs/actions/OnyxUpdateManager.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index de9a928f6ee0..ecd81ffbddcf 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -106,13 +106,14 @@ export default () => { // lastUpdateIDAppliedToClient will always be null. For this case, reconnectApp() will be triggered for them // to kick start the reliable updates. if (!lastUpdateIDAppliedToClient && previousUpdateIDFromServer > 0) { + console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); App.reconnectApp(); } // If the previous update from the server does not match the last update the client got, then the client is missing some updates. // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { - console.debug('[OnyxUpdateManager] Gap detected in update IDs so fetching incremental updates'); + console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { lastUpdateIDFromServer, previousUpdateIDFromServer, @@ -140,6 +141,7 @@ export default () => { }); }); } else { + console.debug(`[OnyxUpdateManager] Client is in sync with the server`); applyOnyxUpdates(updateParams); } From 528062b1c45cc94531039e63dccd010d84bcc494 Mon Sep 17 00:00:00 2001 From: Tim Golen Date: Sat, 19 Aug 2023 14:31:40 -0600 Subject: [PATCH 011/134] Fix the updating and improve comments --- src/App.js | 2 ++ src/libs/Middleware/SaveResponseInOnyx.js | 2 +- src/libs/Navigation/AppNavigator/AuthScreens.js | 2 -- src/libs/actions/OnyxUpdateManager.js | 16 +++++++++++----- src/libs/actions/OnyxUpdates.js | 3 ++- src/libs/actions/User.js | 2 +- 6 files changed, 17 insertions(+), 10 deletions(-) diff --git a/src/App.js b/src/App.js index d8faa911f86b..f072f46961ef 100644 --- a/src/App.js +++ b/src/App.js @@ -23,6 +23,7 @@ import ThemeStylesProvider from './styles/ThemeStylesProvider'; import {CurrentReportIDContextProvider} from './components/withCurrentReportID'; import {EnvironmentProvider} from './components/withEnvironment'; import * as Session from './libs/actions/Session'; +import OnyxUpdateManager from './libs/actions/OnyxUpdateManager'; // For easier debugging and development, when we are in web we expose Onyx to the window, so you can more easily set data into Onyx if (window && Environment.isDevelopment()) { @@ -40,6 +41,7 @@ LogBox.ignoreLogs([ const fill = {flex: 1}; function App() { + OnyxUpdateManager(); return ( App.reconnectApp(this.props.lastUpdateIDAppliedToClient)); PusherConnectionManager.init(); diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index ecd81ffbddcf..d08feb8504c7 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -8,8 +8,14 @@ import PusherUtils from '../PusherUtils'; import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; import * as App from './App'; -// The next 40ish lines of code are used for detecting when there is a gap of OnyxUpdates between what was last applied to the client and the updates the server has. -// When a gap is detected, the missing updates are fetched from the API. +// This file is in charge of looking at the updateIDs coming from the server and comparing them to the last updateID that the client has. +// If the client is behind the server, then we need to pause everything, get the missing updates from the server, apply those updates, +// then restart everything. This will ensure that the client is up-to-date with the server and all the updates have been applied +// in the correct order. +// It's important that this file is separate and not imported by OnyxUpdates.js, so that there are no circular dependencies. Onyx +// is used as a pub/sub mechanism to break out of the circular dependencies. +// The circular dependency happen because this file calls the API GetMissingOnyxUpdates which uses the SaveResponseInOnyx.js file +// (as a middleware). Therefore, SaveResponseInOnyx.js can't import and use this file directly. /** * @param {Object} data @@ -18,6 +24,7 @@ import * as App from './App'; * @returns {Promise} */ function applyHTTPSOnyxUpdates({request, responseData}) { + console.debug('[OnyxUpdateManager] Applying https update'); // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in // the UI. See https://github.com/Expensify/App/issues/12775 for more info. const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; @@ -49,6 +56,7 @@ function applyHTTPSOnyxUpdates({request, responseData}) { * @returns {Promise} */ function applyPusherOnyxUpdates({multipleEvents}) { + console.debug('[OnyxUpdateManager] Applying pusher update'); const pusherEventPromises = _.reduce( multipleEvents, (result, multipleEvent) => { @@ -72,6 +80,7 @@ function applyPusherOnyxUpdates({multipleEvents}) { * @returns {Promise} */ function applyOnyxUpdates({type, data}) { + console.debug(`[OnyxUpdateManager] Applying update type: ${type}`, data); if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { return applyHTTPSOnyxUpdates(data); } @@ -97,9 +106,6 @@ export default () => { } const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; - console.debug('[OnyxUpdateManager] Received lastUpdateID from server', lastUpdateIDFromServer); - console.debug('[OnyxUpdateManager] Received previousUpdateID from server', previousUpdateIDFromServer); - console.debug('[OnyxUpdateManager] Last update ID applied to the client', lastUpdateIDAppliedToClient); // This can happen when a user has just started getting reliable updates from the server but they haven't // had an OpenApp or ReconnectApp call yet. This can result in never getting reliable updates because diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 48ec66280fdd..bb09015393f4 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -17,7 +17,8 @@ function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID return; } - Onyx.merge(ONYXKEYS.ONYX_UPDATES_FROM_SERVER, { + // Always use set() here so that the updateParams are never merged and always unique to the request that came in + Onyx.set(ONYXKEYS.ONYX_UPDATES_FROM_SERVER, { lastUpdateIDFromServer: lastUpdateID, previousUpdateIDFromServer: previousUpdateID, updateParams, diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index 8822afd9ec08..b5429ae0893d 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -565,7 +565,7 @@ function subscribeToUserEvents() { OnyxUpdates.saveUpdateInformation( { - updateType: CONST.ONYX_UPDATE_TYPES.PUSHER, + type: CONST.ONYX_UPDATE_TYPES.PUSHER, data: { multipleEvents: pushJSON.updates, }, From f6eb1bae4cd1a9e1e6a3b8a23d282dd22a173cb3 Mon Sep 17 00:00:00 2001 From: Blazej Kustra Date: Wed, 23 Aug 2023 11:37:44 +0200 Subject: [PATCH 012/134] [TS migration] Migrate 'ROUTES.js' constant to TypeScript --- src/{ROUTES.js => ROUTES.ts} | 112 ++++++++++++++++++----------------- 1 file changed, 57 insertions(+), 55 deletions(-) rename src/{ROUTES.js => ROUTES.ts} (59%) diff --git a/src/ROUTES.js b/src/ROUTES.ts similarity index 59% rename from src/ROUTES.js rename to src/ROUTES.ts index 3f96d77d477e..26b12da2f68c 100644 --- a/src/ROUTES.js +++ b/src/ROUTES.ts @@ -1,10 +1,16 @@ -import lodashGet from 'lodash/get'; +import {ValueOf} from 'type-fest'; import * as Url from './libs/Url'; +import CONST from './CONST'; /** * This is a file containing constants for all of the routes we want to be able to go to */ +type ParseReportRouteParams = { + reportID: string; + isSubReportPageRoute: boolean; +}; + const REPORT = 'r'; const IOU_REQUEST = 'request/new'; const IOU_BILL = 'split/new'; @@ -20,7 +26,7 @@ export default { BANK_ACCOUNT_NEW: 'bank-account/new', BANK_ACCOUNT_WITH_STEP_TO_OPEN: 'bank-account/:stepToOpen?', BANK_ACCOUNT_PERSONAL: 'bank-account/personal', - getBankAccountRoute: (stepToOpen = '', policyID = '', backTo = '') => { + getBankAccountRoute: (stepToOpen = '', policyID = '', backTo = ''): string => { const backToParam = backTo ? `&backTo=${encodeURIComponent(backTo)}` : ''; return `bank-account/${stepToOpen}?policyID=${policyID}${backToParam}`; }, @@ -48,7 +54,7 @@ export default { SETTINGS_ADD_DEBIT_CARD: 'settings/wallet/add-debit-card', SETTINGS_ADD_BANK_ACCOUNT: 'settings/wallet/add-bank-account', SETTINGS_ENABLE_PAYMENTS: 'settings/wallet/enable-payments', - getSettingsAddLoginRoute: (type) => `settings/addlogin/${type}`, + getSettingsAddLoginRoute: (type: string): string => `settings/addlogin/${type}`, SETTINGS_WALLET_TRANSFER_BALANCE: 'settings/wallet/transfer-balance', SETTINGS_WALLET_CHOOSE_TRANSFER_ACCOUNT: 'settings/wallet/choose-transfer-account', SETTINGS_PERSONAL_DETAILS, @@ -57,7 +63,7 @@ export default { SETTINGS_PERSONAL_DETAILS_ADDRESS: `${SETTINGS_PERSONAL_DETAILS}/address`, SETTINGS_CONTACT_METHODS, SETTINGS_CONTACT_METHOD_DETAILS: `${SETTINGS_CONTACT_METHODS}/:contactMethod/details`, - getEditContactMethodRoute: (contactMethod) => `${SETTINGS_CONTACT_METHODS}/${encodeURIComponent(contactMethod)}/details`, + getEditContactMethodRoute: (contactMethod: string): string => `${SETTINGS_CONTACT_METHODS}/${encodeURIComponent(contactMethod)}/details`, SETTINGS_NEW_CONTACT_METHOD: `${SETTINGS_CONTACT_METHODS}/new`, SETTINGS_2FA: 'settings/security/two-factor-auth', SETTINGS_STATUS, @@ -68,14 +74,14 @@ export default { REPORT, REPORT_WITH_ID: 'r/:reportID?', EDIT_REQUEST: 'r/:threadReportID/edit/:field', - getEditRequestRoute: (threadReportID, field) => `r/${threadReportID}/edit/${field}`, + getEditRequestRoute: (threadReportID: string, field: ValueOf) => `r/${threadReportID}/edit/${field}`, EDIT_CURRENCY_REQUEST: 'r/:threadReportID/edit/currency', - getEditRequestCurrencyRoute: (threadReportID, currency, backTo) => `r/${threadReportID}/edit/currency?currency=${currency}&backTo=${backTo}`, - getReportRoute: (reportID) => `r/${reportID}`, + getEditRequestCurrencyRoute: (threadReportID: string, currency: string, backTo: string): string => `r/${threadReportID}/edit/currency?currency=${currency}&backTo=${backTo}`, + getReportRoute: (reportID: string): string => `r/${reportID}`, REPORT_WITH_ID_DETAILS_SHARE_CODE: 'r/:reportID/details/shareCode', - getReportShareCodeRoute: (reportID) => `r/${reportID}/details/shareCode`, + getReportShareCodeRoute: (reportID: string): string => `r/${reportID}/details/shareCode`, REPORT_ATTACHMENTS: 'r/:reportID/attachment', - getReportAttachmentRoute: (reportID, source) => `r/${reportID}/attachment?source=${encodeURI(source)}`, + getReportAttachmentRoute: (reportID: string, source: string): string => `r/${reportID}/attachment?source=${encodeURI(source)}`, /** This is a utility route used to go to the user's concierge chat, or the sign-in page if the user's not authenticated */ CONCIERGE: 'concierge', @@ -100,56 +106,57 @@ export default { IOU_SEND_ADD_BANK_ACCOUNT: `${IOU_SEND}/add-bank-account`, IOU_SEND_ADD_DEBIT_CARD: `${IOU_SEND}/add-debit-card`, IOU_SEND_ENABLE_PAYMENTS: `${IOU_SEND}/enable-payments`, - getMoneyRequestRoute: (iouType, reportID = '') => `${iouType}/new/${reportID}`, - getMoneyRequestAmountRoute: (iouType, reportID = '') => `${iouType}/new/amount/${reportID}`, - getMoneyRequestParticipantsRoute: (iouType, reportID = '') => `${iouType}/new/participants/${reportID}`, - getMoneyRequestConfirmationRoute: (iouType, reportID = '') => `${iouType}/new/confirmation/${reportID}`, - getMoneyRequestCreatedRoute: (iouType, reportID = '') => `${iouType}/new/date/${reportID}`, - getMoneyRequestCurrencyRoute: (iouType, reportID = '', currency, backTo) => `${iouType}/new/currency/${reportID}?currency=${currency}&backTo=${backTo}`, - getMoneyRequestDescriptionRoute: (iouType, reportID = '') => `${iouType}/new/description/${reportID}`, - getMoneyRequestMerchantRoute: (iouType, reportID = '') => `${iouType}/new/merchant/${reportID}`, - getMoneyRequestDistanceTabRoute: (iouType, reportID = '') => `${iouType}/new/${reportID}/distance`, - getMoneyRequestWaypointRoute: (iouType, waypointIndex) => `${iouType}/new/waypoint/${waypointIndex}`, + getMoneyRequestRoute: (iouType: string, reportID = ''): string => `${iouType}/new/${reportID}`, + getMoneyRequestAmountRoute: (iouType: string, reportID = ''): string => `${iouType}/new/amount/${reportID}`, + getMoneyRequestParticipantsRoute: (iouType: string, reportID = ''): string => `${iouType}/new/participants/${reportID}`, + getMoneyRequestConfirmationRoute: (iouType: string, reportID = ''): string => `${iouType}/new/confirmation/${reportID}`, + getMoneyRequestCreatedRoute: (iouType: string, reportID = ''): string => `${iouType}/new/date/${reportID}`, + getMoneyRequestCurrencyRoute: (iouType: string, reportID: string, currency: string, backTo: string): string => + `${iouType}/new/currency/${reportID}?currency=${currency}&backTo=${backTo}`, + getMoneyRequestDescriptionRoute: (iouType: string, reportID = ''): string => `${iouType}/new/description/${reportID}`, + getMoneyRequestMerchantRoute: (iouType: string, reportID = ''): string => `${iouType}/new/merchant/${reportID}`, + getMoneyRequestDistanceTabRoute: (iouType: string, reportID = ''): string => `${iouType}/new/${reportID}/distance`, + getMoneyRequestWaypointRoute: (iouType: string, waypointIndex: number): string => `${iouType}/new/waypoint/${waypointIndex}`, SPLIT_BILL_DETAILS: `r/:reportID/split/:reportActionID`, - getSplitBillDetailsRoute: (reportID, reportActionID) => `r/${reportID}/split/${reportActionID}`, - getNewTaskRoute: (reportID) => `${NEW_TASK}/${reportID}`, + getSplitBillDetailsRoute: (reportID: string, reportActionID: string) => `r/${reportID}/split/${reportActionID}`, + getNewTaskRoute: (reportID: string): string => `${NEW_TASK}/${reportID}`, NEW_TASK_WITH_REPORT_ID: `${NEW_TASK}/:reportID?`, TASK_TITLE: 'r/:reportID/title', TASK_DESCRIPTION: 'r/:reportID/description', TASK_ASSIGNEE: 'r/:reportID/assignee', - getTaskReportTitleRoute: (reportID) => `r/${reportID}/title`, - getTaskReportDescriptionRoute: (reportID) => `r/${reportID}/description`, - getTaskReportAssigneeRoute: (reportID) => `r/${reportID}/assignee`, + getTaskReportTitleRoute: (reportID: string): string => `r/${reportID}/title`, + getTaskReportDescriptionRoute: (reportID: string): string => `r/${reportID}/description`, + getTaskReportAssigneeRoute: (reportID: string): string => `r/${reportID}/assignee`, NEW_TASK_ASSIGNEE: `${NEW_TASK}/assignee`, NEW_TASK_SHARE_DESTINATION: `${NEW_TASK}/share-destination`, NEW_TASK_DETAILS: `${NEW_TASK}/details`, NEW_TASK_TITLE: `${NEW_TASK}/title`, NEW_TASK_DESCRIPTION: `${NEW_TASK}/description`, FLAG_COMMENT: `flag/:reportID/:reportActionID`, - getFlagCommentRoute: (reportID, reportActionID) => `flag/${reportID}/${reportActionID}`, + getFlagCommentRoute: (reportID: string, reportActionID: string): string => `flag/${reportID}/${reportActionID}`, SEARCH: 'search', DETAILS: 'details', - getDetailsRoute: (login) => `details?login=${encodeURIComponent(login)}`, + getDetailsRoute: (login: string) => `details?login=${encodeURIComponent(login)}`, PROFILE: 'a/:accountID', - getProfileRoute: (accountID) => `a/${accountID}`, + getProfileRoute: (accountID: string | number) => `a/${accountID}`, REPORT_PARTICIPANTS: 'r/:reportID/participants', - getReportParticipantsRoute: (reportID) => `r/${reportID}/participants`, + getReportParticipantsRoute: (reportID: string): string => `r/${reportID}/participants`, REPORT_WITH_ID_DETAILS: 'r/:reportID/details', - getReportDetailsRoute: (reportID) => `r/${reportID}/details`, + getReportDetailsRoute: (reportID: string): string => `r/${reportID}/details`, REPORT_SETTINGS: 'r/:reportID/settings', - getReportSettingsRoute: (reportID) => `r/${reportID}/settings`, + getReportSettingsRoute: (reportID: string): string => `r/${reportID}/settings`, REPORT_SETTINGS_ROOM_NAME: 'r/:reportID/settings/room-name', - getReportSettingsRoomNameRoute: (reportID) => `r/${reportID}/settings/room-name`, + getReportSettingsRoomNameRoute: (reportID: string): string => `r/${reportID}/settings/room-name`, REPORT_SETTINGS_NOTIFICATION_PREFERENCES: 'r/:reportID/settings/notification-preferences', - getReportSettingsNotificationPreferencesRoute: (reportID) => `r/${reportID}/settings/notification-preferences`, + getReportSettingsNotificationPreferencesRoute: (reportID: string): string => `r/${reportID}/settings/notification-preferences`, REPORT_WELCOME_MESSAGE: 'r/:reportID/welcomeMessage', - getReportWelcomeMessageRoute: (reportID) => `r/${reportID}/welcomeMessage`, + getReportWelcomeMessageRoute: (reportID: string): string => `r/${reportID}/welcomeMessage`, REPORT_SETTINGS_WRITE_CAPABILITY: 'r/:reportID/settings/who-can-post', - getReportSettingsWriteCapabilityRoute: (reportID) => `r/${reportID}/settings/who-can-post`, + getReportSettingsWriteCapabilityRoute: (reportID: string): string => `r/${reportID}/settings/who-can-post`, TRANSITION_BETWEEN_APPS: 'transition', VALIDATE_LOGIN: 'v/:accountID/:validateCode', GET_ASSISTANCE: 'get-assistance/:taskID', - getGetAssistanceRoute: (taskID) => `get-assistance/${taskID}`, + getGetAssistanceRoute: (taskID: string): string => `get-assistance/${taskID}`, UNLINK_LOGIN: 'u/:accountID/:validateCode', APPLE_SIGN_IN: 'sign-in-with-apple', @@ -160,7 +167,7 @@ export default { // when linking users from e.com in order to share a session in this app. ENABLE_PAYMENTS: 'enable-payments', WALLET_STATEMENT_WITH_DATE: 'statements/:yearMonth', - getWalletStatementWithDateRoute: (yearMonth) => `statements/${yearMonth}`, + getWalletStatementWithDateRoute: (yearMonth: string) => `statements/${yearMonth}`, WORKSPACE_NEW: 'workspace/new', WORKSPACE_INITIAL: 'workspace/:policyID', WORKSPACE_INVITE: 'workspace/:policyID/invite', @@ -174,23 +181,18 @@ export default { WORKSPACE_TRAVEL: 'workspace/:policyID/travel', WORKSPACE_MEMBERS: 'workspace/:policyID/members', WORKSPACE_NEW_ROOM: 'workspace/new-room', - getWorkspaceInitialRoute: (policyID) => `workspace/${policyID}`, - getWorkspaceInviteRoute: (policyID) => `workspace/${policyID}/invite`, - getWorkspaceInviteMessageRoute: (policyID) => `workspace/${policyID}/invite-message`, - getWorkspaceSettingsRoute: (policyID) => `workspace/${policyID}/settings`, - getWorkspaceCardRoute: (policyID) => `workspace/${policyID}/card`, - getWorkspaceReimburseRoute: (policyID) => `workspace/${policyID}/reimburse`, - getWorkspaceRateAndUnitRoute: (policyID) => `workspace/${policyID}/rateandunit`, - getWorkspaceBillsRoute: (policyID) => `workspace/${policyID}/bills`, - getWorkspaceInvoicesRoute: (policyID) => `workspace/${policyID}/invoices`, - getWorkspaceTravelRoute: (policyID) => `workspace/${policyID}/travel`, - getWorkspaceMembersRoute: (policyID) => `workspace/${policyID}/members`, - - /** - * @param {String} route - * @returns {Object} - */ - parseReportRouteParams: (route) => { + getWorkspaceInitialRoute: (policyID: string): string => `workspace/${policyID}`, + getWorkspaceInviteRoute: (policyID: string): string => `workspace/${policyID}/invite`, + getWorkspaceInviteMessageRoute: (policyID: string): string => `workspace/${policyID}/invite-message`, + getWorkspaceSettingsRoute: (policyID: string): string => `workspace/${policyID}/settings`, + getWorkspaceCardRoute: (policyID: string): string => `workspace/${policyID}/card`, + getWorkspaceReimburseRoute: (policyID: string): string => `workspace/${policyID}/reimburse`, + getWorkspaceRateAndUnitRoute: (policyID: string): string => `workspace/${policyID}/rateandunit`, + getWorkspaceBillsRoute: (policyID: string): string => `workspace/${policyID}/bills`, + getWorkspaceInvoicesRoute: (policyID: string): string => `workspace/${policyID}/invoices`, + getWorkspaceTravelRoute: (policyID: string): string => `workspace/${policyID}/travel`, + getWorkspaceMembersRoute: (policyID: string): string => `workspace/${policyID}/members`, + parseReportRouteParams: (route: string): ParseReportRouteParams => { let parsingRoute = route; if (parsingRoute.at(0) === '/') { // remove the first slash @@ -203,9 +205,9 @@ export default { const pathSegments = parsingRoute.split('/'); return { - reportID: lodashGet(pathSegments, 1), + reportID: pathSegments[1], isSubReportPageRoute: pathSegments.length > 2, }; }, SIGN_IN_MODAL: 'sign-in-modal', -}; +} as const; From 2ac26e5ae9fafba27c3f205e8d9cb07c66ffbc7a Mon Sep 17 00:00:00 2001 From: Blazej Kustra Date: Wed, 23 Aug 2023 11:43:02 +0200 Subject: [PATCH 013/134] Remove explicit return types --- src/ROUTES.ts | 80 +++++++++++++++++++++++++-------------------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/src/ROUTES.ts b/src/ROUTES.ts index 26b12da2f68c..8c3f3a7868a7 100644 --- a/src/ROUTES.ts +++ b/src/ROUTES.ts @@ -54,7 +54,7 @@ export default { SETTINGS_ADD_DEBIT_CARD: 'settings/wallet/add-debit-card', SETTINGS_ADD_BANK_ACCOUNT: 'settings/wallet/add-bank-account', SETTINGS_ENABLE_PAYMENTS: 'settings/wallet/enable-payments', - getSettingsAddLoginRoute: (type: string): string => `settings/addlogin/${type}`, + getSettingsAddLoginRoute: (type: string) => `settings/addlogin/${type}`, SETTINGS_WALLET_TRANSFER_BALANCE: 'settings/wallet/transfer-balance', SETTINGS_WALLET_CHOOSE_TRANSFER_ACCOUNT: 'settings/wallet/choose-transfer-account', SETTINGS_PERSONAL_DETAILS, @@ -63,7 +63,7 @@ export default { SETTINGS_PERSONAL_DETAILS_ADDRESS: `${SETTINGS_PERSONAL_DETAILS}/address`, SETTINGS_CONTACT_METHODS, SETTINGS_CONTACT_METHOD_DETAILS: `${SETTINGS_CONTACT_METHODS}/:contactMethod/details`, - getEditContactMethodRoute: (contactMethod: string): string => `${SETTINGS_CONTACT_METHODS}/${encodeURIComponent(contactMethod)}/details`, + getEditContactMethodRoute: (contactMethod: string) => `${SETTINGS_CONTACT_METHODS}/${encodeURIComponent(contactMethod)}/details`, SETTINGS_NEW_CONTACT_METHOD: `${SETTINGS_CONTACT_METHODS}/new`, SETTINGS_2FA: 'settings/security/two-factor-auth', SETTINGS_STATUS, @@ -76,12 +76,12 @@ export default { EDIT_REQUEST: 'r/:threadReportID/edit/:field', getEditRequestRoute: (threadReportID: string, field: ValueOf) => `r/${threadReportID}/edit/${field}`, EDIT_CURRENCY_REQUEST: 'r/:threadReportID/edit/currency', - getEditRequestCurrencyRoute: (threadReportID: string, currency: string, backTo: string): string => `r/${threadReportID}/edit/currency?currency=${currency}&backTo=${backTo}`, - getReportRoute: (reportID: string): string => `r/${reportID}`, + getEditRequestCurrencyRoute: (threadReportID: string, currency: string, backTo: string) => `r/${threadReportID}/edit/currency?currency=${currency}&backTo=${backTo}`, + getReportRoute: (reportID: string) => `r/${reportID}`, REPORT_WITH_ID_DETAILS_SHARE_CODE: 'r/:reportID/details/shareCode', - getReportShareCodeRoute: (reportID: string): string => `r/${reportID}/details/shareCode`, + getReportShareCodeRoute: (reportID: string) => `r/${reportID}/details/shareCode`, REPORT_ATTACHMENTS: 'r/:reportID/attachment', - getReportAttachmentRoute: (reportID: string, source: string): string => `r/${reportID}/attachment?source=${encodeURI(source)}`, + getReportAttachmentRoute: (reportID: string, source: string) => `r/${reportID}/attachment?source=${encodeURI(source)}`, /** This is a utility route used to go to the user's concierge chat, or the sign-in page if the user's not authenticated */ CONCIERGE: 'concierge', @@ -106,57 +106,57 @@ export default { IOU_SEND_ADD_BANK_ACCOUNT: `${IOU_SEND}/add-bank-account`, IOU_SEND_ADD_DEBIT_CARD: `${IOU_SEND}/add-debit-card`, IOU_SEND_ENABLE_PAYMENTS: `${IOU_SEND}/enable-payments`, - getMoneyRequestRoute: (iouType: string, reportID = ''): string => `${iouType}/new/${reportID}`, - getMoneyRequestAmountRoute: (iouType: string, reportID = ''): string => `${iouType}/new/amount/${reportID}`, - getMoneyRequestParticipantsRoute: (iouType: string, reportID = ''): string => `${iouType}/new/participants/${reportID}`, - getMoneyRequestConfirmationRoute: (iouType: string, reportID = ''): string => `${iouType}/new/confirmation/${reportID}`, - getMoneyRequestCreatedRoute: (iouType: string, reportID = ''): string => `${iouType}/new/date/${reportID}`, - getMoneyRequestCurrencyRoute: (iouType: string, reportID: string, currency: string, backTo: string): string => + getMoneyRequestRoute: (iouType: string, reportID = '') => `${iouType}/new/${reportID}`, + getMoneyRequestAmountRoute: (iouType: string, reportID = '') => `${iouType}/new/amount/${reportID}`, + getMoneyRequestParticipantsRoute: (iouType: string, reportID = '') => `${iouType}/new/participants/${reportID}`, + getMoneyRequestConfirmationRoute: (iouType: string, reportID = '') => `${iouType}/new/confirmation/${reportID}`, + getMoneyRequestCreatedRoute: (iouType: string, reportID = '') => `${iouType}/new/date/${reportID}`, + getMoneyRequestCurrencyRoute: (iouType: string, reportID: string, currency: string, backTo: string) => `${iouType}/new/currency/${reportID}?currency=${currency}&backTo=${backTo}`, - getMoneyRequestDescriptionRoute: (iouType: string, reportID = ''): string => `${iouType}/new/description/${reportID}`, - getMoneyRequestMerchantRoute: (iouType: string, reportID = ''): string => `${iouType}/new/merchant/${reportID}`, - getMoneyRequestDistanceTabRoute: (iouType: string, reportID = ''): string => `${iouType}/new/${reportID}/distance`, - getMoneyRequestWaypointRoute: (iouType: string, waypointIndex: number): string => `${iouType}/new/waypoint/${waypointIndex}`, + getMoneyRequestDescriptionRoute: (iouType: string, reportID = '') => `${iouType}/new/description/${reportID}`, + getMoneyRequestMerchantRoute: (iouType: string, reportID = '') => `${iouType}/new/merchant/${reportID}`, + getMoneyRequestDistanceTabRoute: (iouType: string, reportID = '') => `${iouType}/new/${reportID}/distance`, + getMoneyRequestWaypointRoute: (iouType: string, waypointIndex: number) => `${iouType}/new/waypoint/${waypointIndex}`, SPLIT_BILL_DETAILS: `r/:reportID/split/:reportActionID`, getSplitBillDetailsRoute: (reportID: string, reportActionID: string) => `r/${reportID}/split/${reportActionID}`, - getNewTaskRoute: (reportID: string): string => `${NEW_TASK}/${reportID}`, + getNewTaskRoute: (reportID: string) => `${NEW_TASK}/${reportID}`, NEW_TASK_WITH_REPORT_ID: `${NEW_TASK}/:reportID?`, TASK_TITLE: 'r/:reportID/title', TASK_DESCRIPTION: 'r/:reportID/description', TASK_ASSIGNEE: 'r/:reportID/assignee', - getTaskReportTitleRoute: (reportID: string): string => `r/${reportID}/title`, - getTaskReportDescriptionRoute: (reportID: string): string => `r/${reportID}/description`, - getTaskReportAssigneeRoute: (reportID: string): string => `r/${reportID}/assignee`, + getTaskReportTitleRoute: (reportID: string) => `r/${reportID}/title`, + getTaskReportDescriptionRoute: (reportID: string) => `r/${reportID}/description`, + getTaskReportAssigneeRoute: (reportID: string) => `r/${reportID}/assignee`, NEW_TASK_ASSIGNEE: `${NEW_TASK}/assignee`, NEW_TASK_SHARE_DESTINATION: `${NEW_TASK}/share-destination`, NEW_TASK_DETAILS: `${NEW_TASK}/details`, NEW_TASK_TITLE: `${NEW_TASK}/title`, NEW_TASK_DESCRIPTION: `${NEW_TASK}/description`, FLAG_COMMENT: `flag/:reportID/:reportActionID`, - getFlagCommentRoute: (reportID: string, reportActionID: string): string => `flag/${reportID}/${reportActionID}`, + getFlagCommentRoute: (reportID: string, reportActionID: string) => `flag/${reportID}/${reportActionID}`, SEARCH: 'search', DETAILS: 'details', getDetailsRoute: (login: string) => `details?login=${encodeURIComponent(login)}`, PROFILE: 'a/:accountID', getProfileRoute: (accountID: string | number) => `a/${accountID}`, REPORT_PARTICIPANTS: 'r/:reportID/participants', - getReportParticipantsRoute: (reportID: string): string => `r/${reportID}/participants`, + getReportParticipantsRoute: (reportID: string) => `r/${reportID}/participants`, REPORT_WITH_ID_DETAILS: 'r/:reportID/details', - getReportDetailsRoute: (reportID: string): string => `r/${reportID}/details`, + getReportDetailsRoute: (reportID: string) => `r/${reportID}/details`, REPORT_SETTINGS: 'r/:reportID/settings', - getReportSettingsRoute: (reportID: string): string => `r/${reportID}/settings`, + getReportSettingsRoute: (reportID: string) => `r/${reportID}/settings`, REPORT_SETTINGS_ROOM_NAME: 'r/:reportID/settings/room-name', - getReportSettingsRoomNameRoute: (reportID: string): string => `r/${reportID}/settings/room-name`, + getReportSettingsRoomNameRoute: (reportID: string) => `r/${reportID}/settings/room-name`, REPORT_SETTINGS_NOTIFICATION_PREFERENCES: 'r/:reportID/settings/notification-preferences', - getReportSettingsNotificationPreferencesRoute: (reportID: string): string => `r/${reportID}/settings/notification-preferences`, + getReportSettingsNotificationPreferencesRoute: (reportID: string) => `r/${reportID}/settings/notification-preferences`, REPORT_WELCOME_MESSAGE: 'r/:reportID/welcomeMessage', - getReportWelcomeMessageRoute: (reportID: string): string => `r/${reportID}/welcomeMessage`, + getReportWelcomeMessageRoute: (reportID: string) => `r/${reportID}/welcomeMessage`, REPORT_SETTINGS_WRITE_CAPABILITY: 'r/:reportID/settings/who-can-post', - getReportSettingsWriteCapabilityRoute: (reportID: string): string => `r/${reportID}/settings/who-can-post`, + getReportSettingsWriteCapabilityRoute: (reportID: string) => `r/${reportID}/settings/who-can-post`, TRANSITION_BETWEEN_APPS: 'transition', VALIDATE_LOGIN: 'v/:accountID/:validateCode', GET_ASSISTANCE: 'get-assistance/:taskID', - getGetAssistanceRoute: (taskID: string): string => `get-assistance/${taskID}`, + getGetAssistanceRoute: (taskID: string) => `get-assistance/${taskID}`, UNLINK_LOGIN: 'u/:accountID/:validateCode', APPLE_SIGN_IN: 'sign-in-with-apple', @@ -181,17 +181,17 @@ export default { WORKSPACE_TRAVEL: 'workspace/:policyID/travel', WORKSPACE_MEMBERS: 'workspace/:policyID/members', WORKSPACE_NEW_ROOM: 'workspace/new-room', - getWorkspaceInitialRoute: (policyID: string): string => `workspace/${policyID}`, - getWorkspaceInviteRoute: (policyID: string): string => `workspace/${policyID}/invite`, - getWorkspaceInviteMessageRoute: (policyID: string): string => `workspace/${policyID}/invite-message`, - getWorkspaceSettingsRoute: (policyID: string): string => `workspace/${policyID}/settings`, - getWorkspaceCardRoute: (policyID: string): string => `workspace/${policyID}/card`, - getWorkspaceReimburseRoute: (policyID: string): string => `workspace/${policyID}/reimburse`, - getWorkspaceRateAndUnitRoute: (policyID: string): string => `workspace/${policyID}/rateandunit`, - getWorkspaceBillsRoute: (policyID: string): string => `workspace/${policyID}/bills`, - getWorkspaceInvoicesRoute: (policyID: string): string => `workspace/${policyID}/invoices`, - getWorkspaceTravelRoute: (policyID: string): string => `workspace/${policyID}/travel`, - getWorkspaceMembersRoute: (policyID: string): string => `workspace/${policyID}/members`, + getWorkspaceInitialRoute: (policyID: string) => `workspace/${policyID}`, + getWorkspaceInviteRoute: (policyID: string) => `workspace/${policyID}/invite`, + getWorkspaceInviteMessageRoute: (policyID: string) => `workspace/${policyID}/invite-message`, + getWorkspaceSettingsRoute: (policyID: string) => `workspace/${policyID}/settings`, + getWorkspaceCardRoute: (policyID: string) => `workspace/${policyID}/card`, + getWorkspaceReimburseRoute: (policyID: string) => `workspace/${policyID}/reimburse`, + getWorkspaceRateAndUnitRoute: (policyID: string) => `workspace/${policyID}/rateandunit`, + getWorkspaceBillsRoute: (policyID: string) => `workspace/${policyID}/bills`, + getWorkspaceInvoicesRoute: (policyID: string) => `workspace/${policyID}/invoices`, + getWorkspaceTravelRoute: (policyID: string) => `workspace/${policyID}/travel`, + getWorkspaceMembersRoute: (policyID: string) => `workspace/${policyID}/members`, parseReportRouteParams: (route: string): ParseReportRouteParams => { let parsingRoute = route; if (parsingRoute.at(0) === '/') { From 1a8ac614aed9a043ddf24991d29566dfcb7ce649 Mon Sep 17 00:00:00 2001 From: Blazej Kustra Date: Wed, 23 Aug 2023 12:55:12 +0200 Subject: [PATCH 014/134] Run prettier --- src/ROUTES.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/ROUTES.ts b/src/ROUTES.ts index 8c3f3a7868a7..d44e638a1f49 100644 --- a/src/ROUTES.ts +++ b/src/ROUTES.ts @@ -111,8 +111,7 @@ export default { getMoneyRequestParticipantsRoute: (iouType: string, reportID = '') => `${iouType}/new/participants/${reportID}`, getMoneyRequestConfirmationRoute: (iouType: string, reportID = '') => `${iouType}/new/confirmation/${reportID}`, getMoneyRequestCreatedRoute: (iouType: string, reportID = '') => `${iouType}/new/date/${reportID}`, - getMoneyRequestCurrencyRoute: (iouType: string, reportID: string, currency: string, backTo: string) => - `${iouType}/new/currency/${reportID}?currency=${currency}&backTo=${backTo}`, + getMoneyRequestCurrencyRoute: (iouType: string, reportID: string, currency: string, backTo: string) => `${iouType}/new/currency/${reportID}?currency=${currency}&backTo=${backTo}`, getMoneyRequestDescriptionRoute: (iouType: string, reportID = '') => `${iouType}/new/description/${reportID}`, getMoneyRequestMerchantRoute: (iouType: string, reportID = '') => `${iouType}/new/merchant/${reportID}`, getMoneyRequestDistanceTabRoute: (iouType: string, reportID = '') => `${iouType}/new/${reportID}/distance`, From 7b421695dad00701c1b166386d04333b60085a9f Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 23 Aug 2023 21:21:20 +0200 Subject: [PATCH 015/134] added ANY to format on updates since that's still undefined --- src/ONYXKEYS.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ONYXKEYS.ts b/src/ONYXKEYS.ts index d4d2ab1f90a6..d4cb591c704d 100755 --- a/src/ONYXKEYS.ts +++ b/src/ONYXKEYS.ts @@ -350,7 +350,7 @@ type OnyxValues = { [ONYXKEYS.SELECTED_TAB]: string; [ONYXKEYS.RECEIPT_MODAL]: OnyxTypes.ReceiptModal; [ONYXKEYS.MAPBOX_ACCESS_TOKEN]: OnyxTypes.MapboxAccessToken; - [ONYXKEYS.ONYX_UPDATES_FROM_SERVER]: number; + [ONYXKEYS.ONYX_UPDATES_FROM_SERVER]: any; [ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT]: number; // Collections From 3002c64da3ef4811ce2685af3223bd30f1e994c3 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 23 Aug 2023 21:21:54 +0200 Subject: [PATCH 016/134] adding early return in case of responses without onyxData --- src/libs/Middleware/SaveResponseInOnyx.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index efb38ef19018..24bf60e5cdaf 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -27,6 +27,13 @@ function SaveResponseInOnyx(response, request) { // Supports both the old format and the new format const onyxUpdates = _.isArray(responseData) ? responseData : responseData.onyxData; + + // Sometimes we call requests that are successfull but they don't have any response. Let's return early since + // we don't need to store anything here. + if(!onyxUpdates){ + return; + } + // If there is an OnyxUpdate for using memory only keys, enable them _.find(onyxUpdates, ({key, value}) => { if (key !== ONYXKEYS.IS_USING_MEMORY_ONLY_KEYS || !value) { From c4d40949c3ad2de650a5561956a874de640a1d09 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 23 Aug 2023 21:22:45 +0200 Subject: [PATCH 017/134] updating save function to not return early if missing lastUpdateID --- src/libs/actions/OnyxUpdates.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index bb09015393f4..f5b7adeab23c 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -12,11 +12,6 @@ import ONYXKEYS from '../../ONYXKEYS'; * @param {Number} [previousUpdateID] */ function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID = 0) { - // Return early if there were no updateIDs - if (!lastUpdateID) { - return; - } - // Always use set() here so that the updateParams are never merged and always unique to the request that came in Onyx.set(ONYXKEYS.ONYX_UPDATES_FROM_SERVER, { lastUpdateIDFromServer: lastUpdateID, From fe50fd0ebfa76ea8556bf7a6edf8beff0e556adb Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 23 Aug 2023 21:23:40 +0200 Subject: [PATCH 018/134] adding check on reconnect app after switching to updates beta to not do the request if this is open app --- src/libs/actions/OnyxUpdateManager.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index d08feb8504c7..8003fd09bc95 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -104,6 +104,7 @@ export default () => { if (!val) { return; } + debugger; const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; @@ -111,7 +112,12 @@ export default () => { // had an OpenApp or ReconnectApp call yet. This can result in never getting reliable updates because // lastUpdateIDAppliedToClient will always be null. For this case, reconnectApp() will be triggered for them // to kick start the reliable updates. - if (!lastUpdateIDAppliedToClient && previousUpdateIDFromServer > 0) { + if ( + !lastUpdateIDAppliedToClient + && previousUpdateIDFromServer > 0 + && updateParams.type == CONST.ONYX_UPDATE_TYPES.HTTPS + && updateParams.request.command !== "OpenApp" + ) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); App.reconnectApp(); } From a5e812751a1b87ebee06a9832b7ce6c966f77c79 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 23 Aug 2023 21:25:05 +0200 Subject: [PATCH 019/134] adding reconnect app to the list of methods we shouldn't check --- src/libs/actions/OnyxUpdateManager.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 8003fd09bc95..71b6f0607899 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -104,7 +104,6 @@ export default () => { if (!val) { return; } - debugger; const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; @@ -116,8 +115,10 @@ export default () => { !lastUpdateIDAppliedToClient && previousUpdateIDFromServer > 0 && updateParams.type == CONST.ONYX_UPDATE_TYPES.HTTPS - && updateParams.request.command !== "OpenApp" - ) { + && ( + updateParams.request.command !== "OpenApp" + || updateParams.request.command !== "ReconnectApp" + )) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); App.reconnectApp(); } From ba47492e63aefa135d49954fd43c94fbc51b84d5 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 23 Aug 2023 22:27:53 +0200 Subject: [PATCH 020/134] adding check to prevent us from running both ReconnectApp and GetOnyxUpdates on the same request --- src/libs/actions/OnyxUpdateManager.js | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 71b6f0607899..3cdcfeda40d0 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -105,27 +105,37 @@ export default () => { return; } + // Since people will have migrations hapening in their accounts while they use the app, we don't want to trigger + // a full ReconnectApp and then trigger a GetOnyxUpdates. Let's use this as a control variable until we enable + // the beta to all users. + let updateEnablesBeta = false; + const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; // This can happen when a user has just started getting reliable updates from the server but they haven't // had an OpenApp or ReconnectApp call yet. This can result in never getting reliable updates because // lastUpdateIDAppliedToClient will always be null. For this case, reconnectApp() will be triggered for them - // to kick start the reliable updates. + // to kick start the reliable updates. We also filter OpenApp and ReconnectApp so we don't create a loop. if ( !lastUpdateIDAppliedToClient && previousUpdateIDFromServer > 0 - && updateParams.type == CONST.ONYX_UPDATE_TYPES.HTTPS && ( - updateParams.request.command !== "OpenApp" - || updateParams.request.command !== "ReconnectApp" + updateParams.type == CONST.ONYX_UPDATE_TYPES.PUSHER + || ( + updateParams.type == CONST.ONYX_UPDATE_TYPES.HTTPS + && ( + updateParams.data.request.command !== "OpenApp" + || updateParams.data.request.command !== "ReconnectApp" + )) )) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); App.reconnectApp(); + updateEnablesBeta = true; } // If the previous update from the server does not match the last update the client got, then the client is missing some updates. // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. - if (lastUpdateIDAppliedToClient && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { + if (!updateEnablesBeta && previousUpdateIDFromServer && (lastUpdateIDAppliedToClient < previousUpdateIDFromServer)) { console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { lastUpdateIDFromServer, From dde0814580ebab0af4e384ffdb705512abeeaf75 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 23 Aug 2023 22:28:51 +0200 Subject: [PATCH 021/134] prettier --- src/libs/Middleware/SaveResponseInOnyx.js | 2 +- src/libs/actions/OnyxUpdateManager.js | 20 +++++++------------- 2 files changed, 8 insertions(+), 14 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 24bf60e5cdaf..13244dd64e36 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -30,7 +30,7 @@ function SaveResponseInOnyx(response, request) { // Sometimes we call requests that are successfull but they don't have any response. Let's return early since // we don't need to store anything here. - if(!onyxUpdates){ + if (!onyxUpdates) { return; } diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 3cdcfeda40d0..039f89e146c3 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -109,7 +109,7 @@ export default () => { // a full ReconnectApp and then trigger a GetOnyxUpdates. Let's use this as a control variable until we enable // the beta to all users. let updateEnablesBeta = false; - + const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; // This can happen when a user has just started getting reliable updates from the server but they haven't @@ -117,17 +117,11 @@ export default () => { // lastUpdateIDAppliedToClient will always be null. For this case, reconnectApp() will be triggered for them // to kick start the reliable updates. We also filter OpenApp and ReconnectApp so we don't create a loop. if ( - !lastUpdateIDAppliedToClient - && previousUpdateIDFromServer > 0 - && ( - updateParams.type == CONST.ONYX_UPDATE_TYPES.PUSHER - || ( - updateParams.type == CONST.ONYX_UPDATE_TYPES.HTTPS - && ( - updateParams.data.request.command !== "OpenApp" - || updateParams.data.request.command !== "ReconnectApp" - )) - )) { + !lastUpdateIDAppliedToClient && + previousUpdateIDFromServer > 0 && + (updateParams.type == CONST.ONYX_UPDATE_TYPES.PUSHER || + (updateParams.type == CONST.ONYX_UPDATE_TYPES.HTTPS && (updateParams.data.request.command !== 'OpenApp' || updateParams.data.request.command !== 'ReconnectApp'))) + ) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); App.reconnectApp(); updateEnablesBeta = true; @@ -135,7 +129,7 @@ export default () => { // If the previous update from the server does not match the last update the client got, then the client is missing some updates. // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. - if (!updateEnablesBeta && previousUpdateIDFromServer && (lastUpdateIDAppliedToClient < previousUpdateIDFromServer)) { + if (!updateEnablesBeta && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { lastUpdateIDFromServer, From 321041a4b27eb80b8402421591a68d2b2e6735d3 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Thu, 24 Aug 2023 18:33:11 +0200 Subject: [PATCH 022/134] adding fields that were missing in the request object --- src/types/onyx/Request.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/types/onyx/Request.ts b/src/types/onyx/Request.ts index e730dfd807fb..cc57c9410e30 100644 --- a/src/types/onyx/Request.ts +++ b/src/types/onyx/Request.ts @@ -1,8 +1,12 @@ +import { OnyxUpdate } from "react-native-onyx"; + type Request = { command?: string; data?: Record; type?: string; shouldUseSecure?: boolean; + successData?: OnyxUpdate[]; + failureData?: OnyxUpdate[]; }; export default Request; From 85bd8ba018fa2b8df89b2cd2d6e68c8b317138eb Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Thu, 24 Aug 2023 18:33:30 +0200 Subject: [PATCH 023/134] adding response object --- src/types/onyx/Response.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 src/types/onyx/Response.ts diff --git a/src/types/onyx/Response.ts b/src/types/onyx/Response.ts new file mode 100644 index 000000000000..01956adffc87 --- /dev/null +++ b/src/types/onyx/Response.ts @@ -0,0 +1,11 @@ +import { OnyxUpdate } from "react-native-onyx"; + +type Request = { + previousUpdateID?: number; + lastUpdateID?: number; + jsonCode?: number; + onyxData?: OnyxUpdate[]; + requestID?: string; +}; + +export default Response; From 659de586ca7bdf3c1bf7ed414bfc09fadfaa8e45 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Thu, 24 Aug 2023 18:33:45 +0200 Subject: [PATCH 024/134] adding OnyxUpdatesFromServer object --- src/types/onyx/OnyxUpdatesFromServer.ts | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 src/types/onyx/OnyxUpdatesFromServer.ts diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts new file mode 100644 index 000000000000..e510c3d75c4a --- /dev/null +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -0,0 +1,20 @@ +import { OnyxUpdate } from "react-native-onyx"; +import Request from "./Request"; +import Response from "./Response"; + + +type OnyxUpdateFromServerData = { + request?: Request; + response?: Response; + updates?: OnyxUpdate[]; +} + + +type OnyxUpdateFromServer = { + lastUpdateID: number; + previousUpdateID: number; + type: 'HTTPS' | 'PUSHER' + data: OnyxUpdateFromServerData +}; + +export default OnyxUpdateFromServer; \ No newline at end of file From 85b4ef07ea5f628fae4075991c4903a507951c0a Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Thu, 24 Aug 2023 18:36:24 +0200 Subject: [PATCH 025/134] renaming and changing object in onyxKeys --- src/ONYXKEYS.ts | 2 +- src/types/onyx/OnyxUpdatesFromServer.ts | 8 ++++---- src/types/onyx/index.ts | 2 ++ 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/ONYXKEYS.ts b/src/ONYXKEYS.ts index d4cb591c704d..716e3288ebcc 100755 --- a/src/ONYXKEYS.ts +++ b/src/ONYXKEYS.ts @@ -350,7 +350,7 @@ type OnyxValues = { [ONYXKEYS.SELECTED_TAB]: string; [ONYXKEYS.RECEIPT_MODAL]: OnyxTypes.ReceiptModal; [ONYXKEYS.MAPBOX_ACCESS_TOKEN]: OnyxTypes.MapboxAccessToken; - [ONYXKEYS.ONYX_UPDATES_FROM_SERVER]: any; + [ONYXKEYS.ONYX_UPDATES_FROM_SERVER]: OnyxTypes.OnyxUpdatesFromServer; [ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT]: number; // Collections diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index e510c3d75c4a..22bf42b38706 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -3,18 +3,18 @@ import Request from "./Request"; import Response from "./Response"; -type OnyxUpdateFromServerData = { +type OnyxUpdatesFromServerData = { request?: Request; response?: Response; updates?: OnyxUpdate[]; } -type OnyxUpdateFromServer = { +type OnyxUpdatesFromServer = { lastUpdateID: number; previousUpdateID: number; type: 'HTTPS' | 'PUSHER' - data: OnyxUpdateFromServerData + data: OnyxUpdatesFromServerData }; -export default OnyxUpdateFromServer; \ No newline at end of file +export default OnyxUpdatesFromServer; \ No newline at end of file diff --git a/src/types/onyx/index.ts b/src/types/onyx/index.ts index e7ab360551c5..7733b27138b0 100644 --- a/src/types/onyx/index.ts +++ b/src/types/onyx/index.ts @@ -32,6 +32,7 @@ import ReimbursementAccountDraft from './ReimbursementAccountDraft'; import WalletTransfer from './WalletTransfer'; import ReceiptModal from './ReceiptModal'; import MapboxAccessToken from './MapboxAccessToken'; +import OnyxUpdatesFromServer from './OnyxUpdatesFromServer'; import Download from './Download'; import PolicyMember from './PolicyMember'; @@ -89,4 +90,5 @@ export type { Transaction, Form, AddDebitCardForm, + OnyxUpdatesFromServer, }; From 42555c1051e0655870f4dee06dca307b6b004cab Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Thu, 24 Aug 2023 18:37:41 +0200 Subject: [PATCH 026/134] renaming property to updates --- src/libs/actions/OnyxUpdateManager.js | 12 ++++++------ src/types/onyx/OnyxUpdatesFromServer.ts | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 039f89e146c3..1ae1343dc79f 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -52,15 +52,15 @@ function applyHTTPSOnyxUpdates({request, responseData}) { /** * @param {Object} data - * @param {Object} data.multipleEvents + * @param {Object} data.updates * @returns {Promise} */ -function applyPusherOnyxUpdates({multipleEvents}) { +function applyPusherOnyxUpdates({updates}) { console.debug('[OnyxUpdateManager] Applying pusher update'); const pusherEventPromises = _.reduce( - multipleEvents, - (result, multipleEvent) => { - result.push(PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data)); + updates, + (result, update) => { + result.push(PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); return result; }, [], @@ -76,7 +76,7 @@ function applyPusherOnyxUpdates({multipleEvents}) { * @param {Object} updateParams.data * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.multipleEvents] Exists if updateParams.type === 'pusher' + * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' * @returns {Promise} */ function applyOnyxUpdates({type, data}) { diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index 22bf42b38706..2e55d40b9c87 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -13,7 +13,7 @@ type OnyxUpdatesFromServerData = { type OnyxUpdatesFromServer = { lastUpdateID: number; previousUpdateID: number; - type: 'HTTPS' | 'PUSHER' + type: 'https' | 'pusher' data: OnyxUpdatesFromServerData }; From 4d02eb5b37e46801d0f6c49fc06a2ec6a3c69c81 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Thu, 24 Aug 2023 18:38:42 +0200 Subject: [PATCH 027/134] renaming multipleEvents to updates --- src/libs/actions/OnyxUpdates.js | 2 +- src/libs/actions/User.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index f5b7adeab23c..8834fc4e34f7 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -7,7 +7,7 @@ import ONYXKEYS from '../../ONYXKEYS'; * @param {Object} updateParams.data * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.responseData] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.multipleEvents] Exists if updateParams.type === 'pusher' + * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' * @param {Number} [lastUpdateID] * @param {Number} [previousUpdateID] */ diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index b5429ae0893d..940ed780f655 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -567,7 +567,7 @@ function subscribeToUserEvents() { { type: CONST.ONYX_UPDATE_TYPES.PUSHER, data: { - multipleEvents: pushJSON.updates, + updates: pushJSON.updates, }, }, Number(pushJSON.lastUpdateID || 0), From c5d726476955438a0b8340ce11723537031614ee Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 29 Aug 2023 10:42:43 +0200 Subject: [PATCH 028/134] prettier --- src/types/onyx/OnyxUpdatesFromServer.ts | 20 +++++++++----------- src/types/onyx/Request.ts | 2 +- src/types/onyx/Response.ts | 2 +- 3 files changed, 11 insertions(+), 13 deletions(-) diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index 2e55d40b9c87..c2c76afa0aa8 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -1,20 +1,18 @@ -import { OnyxUpdate } from "react-native-onyx"; -import Request from "./Request"; -import Response from "./Response"; - +import {OnyxUpdate} from 'react-native-onyx'; +import Request from './Request'; +import Response from './Response'; type OnyxUpdatesFromServerData = { request?: Request; response?: Response; updates?: OnyxUpdate[]; -} - +}; type OnyxUpdatesFromServer = { - lastUpdateID: number; - previousUpdateID: number; - type: 'https' | 'pusher' - data: OnyxUpdatesFromServerData + lastUpdateID: number | string; + previousUpdateID: number | string; + type: 'https' | 'pusher'; + data: OnyxUpdatesFromServerData; }; -export default OnyxUpdatesFromServer; \ No newline at end of file +export default OnyxUpdatesFromServer; diff --git a/src/types/onyx/Request.ts b/src/types/onyx/Request.ts index cc57c9410e30..1df20cfb28fe 100644 --- a/src/types/onyx/Request.ts +++ b/src/types/onyx/Request.ts @@ -1,4 +1,4 @@ -import { OnyxUpdate } from "react-native-onyx"; +import {OnyxUpdate} from 'react-native-onyx'; type Request = { command?: string; diff --git a/src/types/onyx/Response.ts b/src/types/onyx/Response.ts index 01956adffc87..27077cc9bc74 100644 --- a/src/types/onyx/Response.ts +++ b/src/types/onyx/Response.ts @@ -1,4 +1,4 @@ -import { OnyxUpdate } from "react-native-onyx"; +import {OnyxUpdate} from 'react-native-onyx'; type Request = { previousUpdateID?: number; From 473d5df1dbdd6c3019c07bc25ae8511ae046342b Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 29 Aug 2023 10:43:43 +0200 Subject: [PATCH 029/134] renaming property --- ios/NewExpensify.xcodeproj/project.pbxproj | 8 ++++++-- src/libs/actions/OnyxUpdateManager.js | 6 +++--- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/ios/NewExpensify.xcodeproj/project.pbxproj b/ios/NewExpensify.xcodeproj/project.pbxproj index d87226269a8b..6aeb6cd1cf7d 100644 --- a/ios/NewExpensify.xcodeproj/project.pbxproj +++ b/ios/NewExpensify.xcodeproj/project.pbxproj @@ -29,7 +29,7 @@ 70CF6E82262E297300711ADC /* BootSplash.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 70CF6E81262E297300711ADC /* BootSplash.storyboard */; }; BDB853621F354EBB84E619C2 /* ExpensifyNewKansas-MediumItalic.otf in Resources */ = {isa = PBXBuildFile; fileRef = D2AFB39EC1D44BF9B91D3227 /* ExpensifyNewKansas-MediumItalic.otf */; }; DD79042B2792E76D004484B4 /* RCTBootSplash.m in Sources */ = {isa = PBXBuildFile; fileRef = DD79042A2792E76D004484B4 /* RCTBootSplash.m */; }; - E51DC681C7DEE40AEBDDFBFE /* BuildFile in Frameworks */ = {isa = PBXBuildFile; }; + E51DC681C7DEE40AEBDDFBFE /* (null) in Frameworks */ = {isa = PBXBuildFile; }; E9DF872D2525201700607FDC /* AirshipConfig.plist in Resources */ = {isa = PBXBuildFile; fileRef = E9DF872C2525201700607FDC /* AirshipConfig.plist */; }; ED222ED90E074A5481A854FA /* ExpensifyNeue-BoldItalic.otf in Resources */ = {isa = PBXBuildFile; fileRef = 8B28D84EF339436DBD42A203 /* ExpensifyNeue-BoldItalic.otf */; }; F0C450EA2705020500FD2970 /* colors.json in Resources */ = {isa = PBXBuildFile; fileRef = F0C450E92705020500FD2970 /* colors.json */; }; @@ -112,7 +112,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - E51DC681C7DEE40AEBDDFBFE /* BuildFile in Frameworks */, + E51DC681C7DEE40AEBDDFBFE /* (null) in Frameworks */, 5A464BC8112CDB1DE1E38F1C /* libPods-NewExpensify.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; @@ -701,6 +701,7 @@ CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 3; DEVELOPMENT_TEAM = 368M544MTT; + "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 368M544MTT; ENABLE_BITCODE = NO; INFOPLIST_FILE = "$(SRCROOT)/NewExpensify/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 13.0; @@ -714,6 +715,7 @@ PRODUCT_BUNDLE_IDENTIFIER = com.expensify.chat.dev; PRODUCT_NAME = "New Expensify Dev"; PROVISIONING_PROFILE_SPECIFIER = expensify_chat_dev; + "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = expensify_chat_dev; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; @@ -733,6 +735,7 @@ CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 3; DEVELOPMENT_TEAM = 368M544MTT; + "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 368M544MTT; INFOPLIST_FILE = NewExpensify/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 13.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; @@ -745,6 +748,7 @@ PRODUCT_BUNDLE_IDENTIFIER = com.expensify.chat.dev; PRODUCT_NAME = "New Expensify Dev"; PROVISIONING_PROFILE_SPECIFIER = expensify_chat_dev; + "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = expensify_chat_dev; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 1ae1343dc79f..358be3c07690 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -108,7 +108,7 @@ export default () => { // Since people will have migrations hapening in their accounts while they use the app, we don't want to trigger // a full ReconnectApp and then trigger a GetOnyxUpdates. Let's use this as a control variable until we enable // the beta to all users. - let updateEnablesBeta = false; + let isUserGettingReliableUpdatesForTheVeryFirstTime = false; const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; @@ -124,12 +124,12 @@ export default () => { ) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); App.reconnectApp(); - updateEnablesBeta = true; + isUserGettingReliableUpdatesForTheVeryFirstTime = true; } // If the previous update from the server does not match the last update the client got, then the client is missing some updates. // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. - if (!updateEnablesBeta && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { + if (!isUserGettingReliableUpdatesForTheVeryFirstTime && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { lastUpdateIDFromServer, From 424944dbc91757aa3ddcf1567db762de7778ddd9 Mon Sep 17 00:00:00 2001 From: Bartosz Grajdek Date: Tue, 29 Aug 2023 11:46:06 +0200 Subject: [PATCH 030/134] [TS migration] Migrate 'shouldRenderOffscreen' lib to TypeScript --- src/libs/shouldRenderOffscreen/index.android.js | 2 -- src/libs/shouldRenderOffscreen/index.android.ts | 6 ++++++ src/libs/shouldRenderOffscreen/index.js | 1 - src/libs/shouldRenderOffscreen/index.ts | 5 +++++ src/libs/shouldRenderOffscreen/types.ts | 3 +++ 5 files changed, 14 insertions(+), 3 deletions(-) delete mode 100644 src/libs/shouldRenderOffscreen/index.android.js create mode 100644 src/libs/shouldRenderOffscreen/index.android.ts delete mode 100644 src/libs/shouldRenderOffscreen/index.js create mode 100644 src/libs/shouldRenderOffscreen/index.ts create mode 100644 src/libs/shouldRenderOffscreen/types.ts diff --git a/src/libs/shouldRenderOffscreen/index.android.js b/src/libs/shouldRenderOffscreen/index.android.js deleted file mode 100644 index c91ffa15894d..000000000000 --- a/src/libs/shouldRenderOffscreen/index.android.js +++ /dev/null @@ -1,2 +0,0 @@ -// Rendering offscreen on Android allows it to apply opacity to stacked components correctly. -export default true; diff --git a/src/libs/shouldRenderOffscreen/index.android.ts b/src/libs/shouldRenderOffscreen/index.android.ts new file mode 100644 index 000000000000..fef74bdf1829 --- /dev/null +++ b/src/libs/shouldRenderOffscreen/index.android.ts @@ -0,0 +1,6 @@ +import ShouldRenderOffscreen from './types'; +// Rendering offscreen on Android allows it to apply opacity to stacked components correctly. + +const shouldRenderOffscreen: ShouldRenderOffscreen = true; + +export default shouldRenderOffscreen; diff --git a/src/libs/shouldRenderOffscreen/index.js b/src/libs/shouldRenderOffscreen/index.js deleted file mode 100644 index 33136544dba2..000000000000 --- a/src/libs/shouldRenderOffscreen/index.js +++ /dev/null @@ -1 +0,0 @@ -export default false; diff --git a/src/libs/shouldRenderOffscreen/index.ts b/src/libs/shouldRenderOffscreen/index.ts new file mode 100644 index 000000000000..eadcc44814f9 --- /dev/null +++ b/src/libs/shouldRenderOffscreen/index.ts @@ -0,0 +1,5 @@ +import ShouldRenderOffscreen from './types'; + +const shouldRenderOffscreen: ShouldRenderOffscreen = false; + +export default shouldRenderOffscreen; diff --git a/src/libs/shouldRenderOffscreen/types.ts b/src/libs/shouldRenderOffscreen/types.ts new file mode 100644 index 000000000000..63cd98eec31b --- /dev/null +++ b/src/libs/shouldRenderOffscreen/types.ts @@ -0,0 +1,3 @@ +type ShouldRenderOffscreen = boolean; + +export default ShouldRenderOffscreen; From 6a51999af2786b55aa202adb380f0314e274df33 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 29 Aug 2023 12:22:12 +0200 Subject: [PATCH 031/134] lint errors --- src/libs/actions/OnyxUpdateManager.js | 4 ++-- src/types/onyx/Response.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 358be3c07690..97456d8d704f 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -119,8 +119,8 @@ export default () => { if ( !lastUpdateIDAppliedToClient && previousUpdateIDFromServer > 0 && - (updateParams.type == CONST.ONYX_UPDATE_TYPES.PUSHER || - (updateParams.type == CONST.ONYX_UPDATE_TYPES.HTTPS && (updateParams.data.request.command !== 'OpenApp' || updateParams.data.request.command !== 'ReconnectApp'))) + (updateParams.type === CONST.ONYX_UPDATE_TYPES.PUSHER || + (updateParams.type === CONST.ONYX_UPDATE_TYPES.HTTPS && (updateParams.data.request.command !== 'OpenApp' || updateParams.data.request.command !== 'ReconnectApp'))) ) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); App.reconnectApp(); diff --git a/src/types/onyx/Response.ts b/src/types/onyx/Response.ts index 27077cc9bc74..d9395b6e8dab 100644 --- a/src/types/onyx/Response.ts +++ b/src/types/onyx/Response.ts @@ -1,6 +1,6 @@ import {OnyxUpdate} from 'react-native-onyx'; -type Request = { +type Response = { previousUpdateID?: number; lastUpdateID?: number; jsonCode?: number; From 184d2211653ab21c18dfcdb5e898b261f07f6c1b Mon Sep 17 00:00:00 2001 From: Bartosz Grajdek Date: Tue, 29 Aug 2023 13:28:34 +0200 Subject: [PATCH 032/134] Move comment --- src/libs/shouldRenderOffscreen/index.android.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/shouldRenderOffscreen/index.android.ts b/src/libs/shouldRenderOffscreen/index.android.ts index fef74bdf1829..bf2d9837086f 100644 --- a/src/libs/shouldRenderOffscreen/index.android.ts +++ b/src/libs/shouldRenderOffscreen/index.android.ts @@ -1,6 +1,6 @@ import ShouldRenderOffscreen from './types'; -// Rendering offscreen on Android allows it to apply opacity to stacked components correctly. +// Rendering offscreen on Android allows it to apply opacity to stacked components correctly. const shouldRenderOffscreen: ShouldRenderOffscreen = true; export default shouldRenderOffscreen; From 72629ebb6d701d1b73a85d4b61bc9d2444dd8249 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 29 Aug 2023 23:39:22 +0200 Subject: [PATCH 033/134] reverting file to main --- ios/NewExpensify.xcodeproj/project.pbxproj | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/ios/NewExpensify.xcodeproj/project.pbxproj b/ios/NewExpensify.xcodeproj/project.pbxproj index 6aeb6cd1cf7d..d87226269a8b 100644 --- a/ios/NewExpensify.xcodeproj/project.pbxproj +++ b/ios/NewExpensify.xcodeproj/project.pbxproj @@ -29,7 +29,7 @@ 70CF6E82262E297300711ADC /* BootSplash.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 70CF6E81262E297300711ADC /* BootSplash.storyboard */; }; BDB853621F354EBB84E619C2 /* ExpensifyNewKansas-MediumItalic.otf in Resources */ = {isa = PBXBuildFile; fileRef = D2AFB39EC1D44BF9B91D3227 /* ExpensifyNewKansas-MediumItalic.otf */; }; DD79042B2792E76D004484B4 /* RCTBootSplash.m in Sources */ = {isa = PBXBuildFile; fileRef = DD79042A2792E76D004484B4 /* RCTBootSplash.m */; }; - E51DC681C7DEE40AEBDDFBFE /* (null) in Frameworks */ = {isa = PBXBuildFile; }; + E51DC681C7DEE40AEBDDFBFE /* BuildFile in Frameworks */ = {isa = PBXBuildFile; }; E9DF872D2525201700607FDC /* AirshipConfig.plist in Resources */ = {isa = PBXBuildFile; fileRef = E9DF872C2525201700607FDC /* AirshipConfig.plist */; }; ED222ED90E074A5481A854FA /* ExpensifyNeue-BoldItalic.otf in Resources */ = {isa = PBXBuildFile; fileRef = 8B28D84EF339436DBD42A203 /* ExpensifyNeue-BoldItalic.otf */; }; F0C450EA2705020500FD2970 /* colors.json in Resources */ = {isa = PBXBuildFile; fileRef = F0C450E92705020500FD2970 /* colors.json */; }; @@ -112,7 +112,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - E51DC681C7DEE40AEBDDFBFE /* (null) in Frameworks */, + E51DC681C7DEE40AEBDDFBFE /* BuildFile in Frameworks */, 5A464BC8112CDB1DE1E38F1C /* libPods-NewExpensify.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; @@ -701,7 +701,6 @@ CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 3; DEVELOPMENT_TEAM = 368M544MTT; - "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 368M544MTT; ENABLE_BITCODE = NO; INFOPLIST_FILE = "$(SRCROOT)/NewExpensify/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 13.0; @@ -715,7 +714,6 @@ PRODUCT_BUNDLE_IDENTIFIER = com.expensify.chat.dev; PRODUCT_NAME = "New Expensify Dev"; PROVISIONING_PROFILE_SPECIFIER = expensify_chat_dev; - "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = expensify_chat_dev; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; @@ -735,7 +733,6 @@ CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 3; DEVELOPMENT_TEAM = 368M544MTT; - "DEVELOPMENT_TEAM[sdk=iphoneos*]" = 368M544MTT; INFOPLIST_FILE = NewExpensify/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 13.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; @@ -748,7 +745,6 @@ PRODUCT_BUNDLE_IDENTIFIER = com.expensify.chat.dev; PRODUCT_NAME = "New Expensify Dev"; PROVISIONING_PROFILE_SPECIFIER = expensify_chat_dev; - "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = expensify_chat_dev; SWIFT_VERSION = 5.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; From fca14f475b702b085d1ce35b8ad78089b90ed9a3 Mon Sep 17 00:00:00 2001 From: rory Date: Wed, 30 Aug 2023 12:20:22 +0200 Subject: [PATCH 034/134] Create git hook to add CP actor to commit message --- .github/workflows/cherryPick.yml | 20 ++++++++++++++++++++ tests/unit/CIGitLogicTest.sh | 5 +++++ 2 files changed, 25 insertions(+) diff --git a/.github/workflows/cherryPick.yml b/.github/workflows/cherryPick.yml index d4c17a734b1c..25a8e7fe682b 100644 --- a/.github/workflows/cherryPick.yml +++ b/.github/workflows/cherryPick.yml @@ -77,6 +77,23 @@ jobs: id: cherryPick run: | echo "Attempting to cherry-pick ${{ steps.getCPMergeCommit.outputs.MERGE_COMMIT_SHA }}" + + # Set up a git hook to include the actor who triggered this CP in the commit message + # Note that the -x flag to `git cherry-pick` appends a message like '(cherry picked from commit abcd)' to the original commit message + # The git hook we create here will update that to: '(cherry picked from commit by roryabraham)' (using the username of the deployer that triggered the CP) + # Note that we can't change the actor because only OSBotify has permission to push code straight to staging + echo '#!/bin/bash' >> .git/hooks/prepare-commit-msg + + # Explaining this command: + # -i flag tells sed to "edit the file inline" + # -E means "use extended regex" + # The regex itself captures "(cherry picked from commit abcd" and then appends "by ${{ github.actor }}" using \1 (the capture group) + # $1 – the first argument to the prepare-commit-msg hook is the filepath of the text file containing the commit message + # shellcheck disable=SC2016 + echo 'sed -i "" -E "s/(\(cherry picked from commit .*[^)])/\1 by ${{ github.actor }}/" $1' >> .git/hooks/prepare-commit-msg + chmod u+x .git/hooks/prepare-commit-msg + + # Run the cherry-pick command if git cherry-pick -S -x --mainline 1 ${{ steps.getCPMergeCommit.outputs.MERGE_COMMIT_SHA }}; then echo "🎉 No conflicts! CP was a success, PR can be automerged 🎉" echo "HAS_CONFLICTS=false" >> "$GITHUB_OUTPUT" @@ -88,6 +105,9 @@ jobs: echo "HAS_CONFLICTS=true" >> "$GITHUB_OUTPUT" fi + # Clean up git hook + rm .git/hooks/prepare-commit-msg + - name: Push changes run: | if [[ ${{steps.cherryPick.outputs.HAS_CONFLICTS}} == 'true' ]]; then diff --git a/tests/unit/CIGitLogicTest.sh b/tests/unit/CIGitLogicTest.sh index 1bb5c88d3427..d79fa7a22c0c 100755 --- a/tests/unit/CIGitLogicTest.sh +++ b/tests/unit/CIGitLogicTest.sh @@ -135,7 +135,12 @@ function cherry_pick_pr { git switch staging git switch -c cherry-pick-staging + echo '#!/bin/bash' >> .git/hooks/prepare-commit-msg + # shellcheck disable=SC2016 + echo 'sed -i "" -E "s/(\(cherry picked from commit .*[^)])/\1 by humanDeployer/" $1' >> .git/hooks/prepare-commit-msg + chmod u+x .git/hooks/prepare-commit-msg git cherry-pick -x --mainline 1 --strategy=recursive -Xtheirs "$PR_MERGE_COMMIT" + rm .git/hooks/prepare-commit-msg git cherry-pick -x --mainline 1 "$VERSION_BUMP_COMMIT" git switch staging From 5a447c48eb57525dbea37d57d8b7e3e4f025667d Mon Sep 17 00:00:00 2001 From: rory Date: Wed, 30 Aug 2023 13:58:24 +0200 Subject: [PATCH 035/134] Reimplement markPullRequestsAsDeployed --- .eslintrc.js | 8 + .../javascript/authorChecklist/index.js | 3646 +++++++++------- .../javascript/awaitStagingDeploys/index.js | 3648 +++++++++------- .../actions/javascript/bumpVersion/index.js | 2712 +++++++----- .../javascript/checkDeployBlockers/index.js | 3648 +++++++++------- .../createOrUpdateStagingDeploy/index.js | 3652 ++++++++++------- .../getDeployPullRequestList/index.js | 3652 ++++++++++------- .../javascript/getPreviousVersion/index.js | 2712 +++++++----- .../javascript/getPullRequestDetails/index.js | 3648 +++++++++------- .../javascript/getReleaseBody/index.js | 3648 +++++++++------- .../javascript/isStagingDeployLocked/index.js | 3648 +++++++++------- .../markPullRequestsAsDeployed/index.js | 2991 +++++++++----- .../markPullRequestsAsDeployed.js | 131 +- .../javascript/postTestBuildComment/index.js | 3646 +++++++++------- .../reopenIssueWithComment/index.js | 3646 +++++++++------- .../javascript/reviewerChecklist/index.js | 3646 +++++++++------- .../javascript/verifySignedCommits/index.js | 3648 +++++++++------- 17 files changed, 32355 insertions(+), 19975 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index ec55f16b2832..22b94d79e369 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -163,5 +163,13 @@ module.exports = { ], }, }, + { + files: ['tests/**/*.{js,jsx,ts,tsx}', '.github/**/*.{js,jsx,ts,tsx}'], + rules: { + '@lwc/lwc/no-async-await': 'off', + 'no-await-in-loop': 'off', + 'no-restricted-syntax': ['error', 'ForInStatement', 'LabeledStatement', 'WithStatement'], + }, + }, ], }; diff --git a/.github/actions/javascript/authorChecklist/index.js b/.github/actions/javascript/authorChecklist/index.js index 4276ea0ba6fc..a63cbc78ec62 100644 --- a/.github/actions/javascript/authorChecklist/index.js +++ b/.github/actions/javascript/authorChecklist/index.js @@ -105,7 +105,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16117,1066 +16117,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17185,19 +17250,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17208,34 +17282,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17245,15 +17333,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17276,31 +17369,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17315,9 +17430,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17326,6 +17446,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17334,6 +17457,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17343,10 +17467,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17364,32 +17492,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17426,7 +17575,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17480,7 +17629,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17489,14 +17638,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17504,11 +17657,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17517,13 +17671,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17535,6 +17696,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17553,26 +17719,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17580,12 +17762,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17598,11 +17780,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17610,31 +17797,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17682,6 +17883,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17720,13 +17925,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17734,6 +17943,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17747,6 +17957,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17756,6 +17967,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17769,9 +17981,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17783,11 +18003,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17796,18 +18020,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17815,10 +18049,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17830,7 +18069,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17840,29 +18079,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17870,7 +18132,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17883,10 +18145,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17896,12 +18163,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17921,12 +18193,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17938,15 +18220,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17955,10 +18247,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17967,20 +18264,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -17995,25 +18304,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -18033,12 +18356,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18058,6 +18387,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18067,21 +18405,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18093,11 +18438,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18119,6 +18472,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18132,53 +18489,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18187,545 +18571,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/awaitStagingDeploys/index.js b/.github/actions/javascript/awaitStagingDeploys/index.js index bc8510ba5bc6..c5aa6d3b20b3 100644 --- a/.github/actions/javascript/awaitStagingDeploys/index.js +++ b/.github/actions/javascript/awaitStagingDeploys/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 1021: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const CONST = __nccwpck_require__(4097); const ActionUtils = __nccwpck_require__(970); const GitHubUtils = __nccwpck_require__(7999); @@ -143,7 +143,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16158,1066 +16158,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17226,19 +17291,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17249,34 +17323,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17286,15 +17374,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17317,31 +17410,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17356,9 +17471,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17367,6 +17487,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17375,6 +17498,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17384,10 +17508,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17405,32 +17533,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17467,7 +17616,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17521,7 +17670,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17530,14 +17679,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17545,11 +17698,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17558,13 +17712,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17576,6 +17737,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17594,26 +17760,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17621,12 +17803,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17639,11 +17821,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17651,31 +17838,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17723,6 +17924,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17761,13 +17966,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17775,6 +17984,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17788,6 +17998,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17797,6 +18008,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17810,9 +18022,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17824,11 +18044,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17837,18 +18061,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17856,10 +18090,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17871,7 +18110,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17881,29 +18120,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17911,7 +18173,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17924,10 +18186,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17937,12 +18204,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17962,12 +18234,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17979,15 +18261,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17996,10 +18288,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -18008,20 +18305,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -18036,25 +18345,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -18074,12 +18397,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18099,6 +18428,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18108,21 +18446,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18134,11 +18479,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18160,6 +18513,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18173,53 +18530,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18228,545 +18612,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/bumpVersion/index.js b/.github/actions/javascript/bumpVersion/index.js index f780e50a4587..830dbf626548 100644 --- a/.github/actions/javascript/bumpVersion/index.js +++ b/.github/actions/javascript/bumpVersion/index.js @@ -11,7 +11,7 @@ module.exports = const {promisify} = __nccwpck_require__(669); const fs = __nccwpck_require__(747); const exec = promisify(__nccwpck_require__(129).exec); -const _ = __nccwpck_require__(571); +const _ = __nccwpck_require__(947); const core = __nccwpck_require__(186); const versionUpdater = __nccwpck_require__(7); const {updateAndroidVersion, updateiOSVersion, generateAndroidVersionCode} = __nccwpck_require__(322); @@ -178,7 +178,7 @@ exports.updateiOSVersion = function updateiOSVersion(version) { /***/ 7: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(571); +const _ = __nccwpck_require__(947); const SEMANTIC_VERSION_LEVELS = { MAJOR: 'MAJOR', @@ -3068,8 +3068,8 @@ exports.debug = debug; // for test /***/ }), -/***/ 521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +/***/ 947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; // ESM COMPAT FLAG @@ -3077,636 +3077,672 @@ __nccwpck_require__.r(__webpack_exports__); // EXPORTS __nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip }); -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; - return rnds8Pool.slice(poolPtr, poolPtr += 16); -} -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); -} +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -const byteToHex = []; +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return uuid; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; +} -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; +} - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +/* harmony default export */ const isString = (tagTester('String')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +/* harmony default export */ const isNumber = (tagTester('Number')); - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isDate = (tagTester('Date')); - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +/* harmony default export */ const isError = (tagTester('Error')); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +/* harmony default export */ const isSymbol = (tagTester('Symbol')); - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - b[i++] = clockseq & 0xff; // `node` - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - return buf || esm_node_stringify(b); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +var isFunction = tagTester('Function'); - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ +/* harmony default export */ const modules_isFunction = (isFunction); - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - const bytes = []; - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } - return bytes; -} -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } - - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` - - - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; - - if (buf) { - offset = offset || 0; - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +var isDataView = tagTester('DataView'); - return buf; - } +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); +} - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; -} -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } - return external_crypto_default().createHash('md5').update(bytes).digest(); +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js - +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +var isArguments = tagTester('Arguments'); -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +/* harmony default export */ const modules_isArguments = (isArguments); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); } -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } - return external_crypto_default().createHash('sha1').update(bytes).digest(); +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js - +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } - - return parseInt(uuid.substr(14, 1), 16); } -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js - +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js -/***/ }), -/***/ 641: -/***/ ((__unused_webpack_module, exports) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. -Object.defineProperty(exports, "__esModule", ({ value: true })); -// Current version. -var VERSION = '1.13.4'; +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); } - args[startIndex] = rest; - return func.apply(this, args); }; } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} - -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} - -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} - -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } } -var isString = tagTester('String'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); - -var isSymbol = tagTester('Symbol'); - -var isArrayBuffer = tagTester('ArrayBuffer'); - -var isFunction = tagTester('Function'); - -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} - -var isFunction$1 = isFunction; - -var hasObjectTag = tagTester('Object'); - -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); - -var isDataView = tagTester('DataView'); - -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); -} - -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); - -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); - -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); -} - -var isArguments = tagTester('Arguments'); - -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); - -var isArguments$1 = isArguments; - -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} - -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; - }; -} - -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; - } -} - -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; -} - -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); - -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); - -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); -} - -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); - -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); - -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); - } - }; -} - -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; - - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} // Retrieve the names of an object's own properties. // Delegates to **ECMAScript 5**'s native `Object.keys`. @@ -3714,25 +3750,35 @@ function keys(obj) { if (!isObject(obj)) return []; if (nativeKeys) return nativeKeys(obj); var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); + for (var key in obj) if (has(obj, key)) keys.push(key); // Ahem, IE < 9. if (hasEnumBug) collectNonEnumProps(obj, keys); return keys; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js + + + + + + // Is a given array, string, or object empty? // An "empty" object has no enumerable own-properties. function isEmpty(obj) { if (obj == null) return true; // Skip the more expensive `toString`-based type checks if `obj` has no // `.length`. - var length = getLength(obj); + var length = _getLength(obj); if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) + isArray(obj) || isString(obj) || modules_isArguments(obj) )) return length === 0; - return getLength(keys(obj)) === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js + + // Returns whether an object has a given set of `key:value` pairs. function isMatch(object, attrs) { var _keys = keys(attrs), length = _keys.length; @@ -3745,40 +3791,58 @@ function isMatch(object, attrs) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js + + // If Underscore is called as a function, it returns a wrapped object that can // be used OO-style. This wrapper holds altered versions of all functions added // through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); this._wrapped = obj; } -_$1.VERSION = VERSION; +_.VERSION = VERSION; // Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { +_.prototype.value = function() { return this._wrapped; }; // Provide unwrapping proxies for some methods used in engine operations // such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -_$1.prototype.toString = function() { +_.prototype.toString = function() { return String(this._wrapped); }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js + + // Internal function to wrap or shallow-copy an ArrayBuffer, // typed array or DataView to a new view, reusing the buffer. function toBufferView(bufferSource) { return new Uint8Array( bufferSource.buffer || bufferSource, bufferSource.byteOffset || 0, - getByteLength(bufferSource) + _getByteLength(bufferSource) ); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js + + + + + + + + + + + // We use this string twice, so give it a name for minification. var tagDataView = '[object DataView]'; @@ -3800,14 +3864,14 @@ function eq(a, b, aStack, bStack) { // Internal recursive comparison function for `_.isEqual`. function deepEq(a, b, aStack, bStack) { // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; className = tagDataView; } switch (className) { @@ -3839,9 +3903,9 @@ function deepEq(a, b, aStack, bStack) { } var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; areArrays = true; } @@ -3851,8 +3915,8 @@ function deepEq(a, b, aStack, bStack) { // Objects with different constructors are not equivalent, but `Object`s or `Array`s // from different frames are. var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) && ('constructor' in a && 'constructor' in b)) { return false; } @@ -3893,7 +3957,7 @@ function deepEq(a, b, aStack, bStack) { while (length--) { // Deep compare each member key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; } } // Remove the first object from the stack of traversed objects. @@ -3907,6 +3971,11 @@ function isEqual(a, b) { return eq(a, b); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js + + + + // Retrieve all the enumerable property names of an object. function allKeys(obj) { if (!isObject(obj)) return []; @@ -3917,24 +3986,29 @@ function allKeys(obj) { return keys; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js + + + + // Since the regular `Object.prototype.toString` type tests don't work for // some types in IE 11, we use a fingerprinting heuristic instead, based // on the methods. It's not great, but it's the best we got. // The fingerprint method lists are defined below. function ie11fingerprint(methods) { - var length = getLength(methods); + var length = _getLength(methods); return function(obj) { if (obj == null) return false; // `Map`, `WeakMap` and `Set` have no enumerable keys. var keys = allKeys(obj); - if (getLength(keys)) return false; + if (_getLength(keys)) return false; for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; + if (!modules_isFunction(obj[methods[i]])) return false; } // If we are testing against `WeakMap`, we need to ensure that // `obj` doesn't have a `forEach` method in order to distinguish // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } @@ -3951,13 +4025,34 @@ var mapMethods = commonInit.concat(forEachName, mapTail), weakMapMethods = commonInit.concat(mapTail), setMethods = ['add'].concat(commonInit, forEachName, hasName); -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js -var isWeakSet = tagTester('WeakSet'); // Retrieve the values of an object's properties. function values(obj) { @@ -3970,6 +4065,9 @@ function values(obj) { return values; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + // Convert an object into a list of `[key, value]` pairs. // The opposite of `_.object` with one argument. function pairs(obj) { @@ -3982,6 +4080,9 @@ function pairs(obj) { return pairs; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js + + // Invert the keys and values of an object. The values must be serializable. function invert(obj) { var result = {}; @@ -3992,15 +4093,19 @@ function invert(obj) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js + + // Return a sorted list of the function names available on the object. function functions(obj) { var names = []; for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); + if (modules_isFunction(obj[key])) names.push(key); } return names.sort(); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js // An internal function for creating assigner functions. function createAssigner(keysFunc, defaults) { return function(obj) { @@ -4020,16 +4125,32 @@ function createAssigner(keysFunc, defaults) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js + + + // Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); +/* harmony default export */ const extend = (createAssigner(allKeys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js + + // Assigns a given object with all the own properties in the passed-in // object(s). // (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + // Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + // Create a naked function reference for surrogate-prototype-swapping. function ctor() { @@ -4047,6 +4168,10 @@ function baseCreate(prototype) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js + + + // Creates an object that inherits from the given prototype object. // If additional properties are provided then they will be added to the // created object. @@ -4056,12 +4181,18 @@ function create(prototype, props) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js + + + + // Create a (shallow-cloned) duplicate of an object. function clone(obj) { if (!isObject(obj)) return obj; return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -4070,19 +4201,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -4093,34 +4233,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -4130,15 +4284,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -4161,31 +4320,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -4200,9 +4381,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -4211,6 +4397,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -4219,6 +4408,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -4228,10 +4418,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -4249,32 +4443,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + + +// Function for unescaping strings from HTML interpolation. +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js -// Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -4311,7 +4526,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -4365,7 +4580,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -4374,14 +4589,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -4389,11 +4608,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -4402,13 +4622,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -4420,6 +4647,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -4438,26 +4670,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -4465,12 +4713,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -4483,11 +4731,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -4495,31 +4748,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -4567,6 +4834,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -4605,13 +4876,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -4619,6 +4894,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -4632,6 +4908,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -4641,6 +4918,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -4654,9 +4932,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -4668,11 +4954,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -4681,18 +4971,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -4700,10 +5000,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -4715,7 +5020,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -4725,29 +5030,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -4755,7 +5083,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -4768,10 +5096,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -4781,12 +5114,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -4806,12 +5144,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -4823,15 +5171,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -4840,10 +5198,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -4852,20 +5215,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -4880,25 +5255,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -4918,12 +5307,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -4943,6 +5338,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -4952,21 +5356,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -4978,11 +5389,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -5004,6 +5423,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -5017,53 +5440,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -5072,22 +5522,34 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + // Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in @@ -5096,6 +5558,9 @@ function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + // Get the first element of an array. Passing **n** will return the first N // values in the array. The **guard** check allows it to work with `_.map`. function first(array, n, guard) { @@ -5104,6 +5569,9 @@ function first(array, n, guard) { return initial(array, array.length - n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + // Returns everything but the first entry of the `array`. Especially useful on // the `arguments` object. Passing an **n** will return the rest N values in the // `array`. @@ -5111,6 +5579,9 @@ function rest(array, n, guard) { return slice.call(array, n == null || guard ? 1 : n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + // Get the last element of an array. Passing **n** will return the last N // values in the array. function last(array, n, guard) { @@ -5119,30 +5590,52 @@ function last(array, n, guard) { return rest(array, Math.max(0, array.length - n)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + // Trim out all falsy values from an array. function compact(array) { return filter(array, Boolean); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + // Flatten out an array, either recursively (by default), or up to `depth`. // Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); +function flatten_flatten(array, depth) { + return flatten(array, depth, false); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + // Take the difference between one array and a number of other arrays. // Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); return filter(array, function(value){ return !contains(rest, value); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + // Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { return difference(array, otherArrays); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + // Produce a duplicate-free version of the array. If the array has already // been sorted, you have the option of using a faster algorithm. @@ -5158,7 +5651,7 @@ function uniq(array, isSorted, iteratee, context) { if (iteratee != null) iteratee = cb(iteratee, context); var result = []; var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { + for (var i = 0, length = _getLength(array); i < length; i++) { var value = array[i], computed = iteratee ? iteratee(value, i, array) : value; if (isSorted && !iteratee) { @@ -5176,18 +5669,27 @@ function uniq(array, isSorted, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + // Produce an array that contains the union: each distinct element from all of // the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + // Produce an array that contains every item shared between all the // passed-in arrays. function intersection(array) { var result = []; var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { + for (var i = 0, length = _getLength(array); i < length; i++) { var item = array[i]; if (contains(result, item)) continue; var j; @@ -5199,10 +5701,15 @@ function intersection(array) { return result; } -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; var result = Array(length); for (var index = 0; index < length; index++) { @@ -5211,16 +5718,23 @@ function unzip(array) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + // Zip together multiple lists into a single array -- elements that share // an index go together. -var zip = restArguments(unzip); +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + // Converts lists into objects. Pass either a single array of `[key, value]` // pairs, or two parallel arrays of the same length -- one of keys, and one of // the corresponding values. Passing by pairs is the reverse of `_.pairs`. function object(list, values) { var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { + for (var i = 0, length = _getLength(list); i < length; i++) { if (values) { result[list[i]] = values[i]; } else { @@ -5230,6 +5744,7 @@ function object(list, values) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js // Generate an integer Array containing an arithmetic progression. A port of // the native Python `range()` function. See // [the Python documentation](https://docs.python.org/library/functions.html#range). @@ -5252,6 +5767,9 @@ function range(start, stop, step) { return range; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + // Chunk a single array into multiple arrays, each containing `count` or fewer // items. function chunk(array, count) { @@ -5264,28 +5782,44 @@ function chunk(array, count) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + // Helper function to continue chaining intermediate results. function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return instance._chain ? _(obj).chain() : obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + // Add your own custom functions to the Underscore object. function mixin(obj) { each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { + var func = _[name] = obj[name]; + _.prototype[name] = function() { var args = [this._wrapped]; push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); + return chainResult(this, func.apply(_, args)); }; }); - return _$1; + return _; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + // Add all mutator `Array` functions to the wrapper. each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { var method = ArrayProto[name]; - _$1.prototype[name] = function() { + _.prototype[name] = function() { var obj = this._wrapped; if (obj != null) { method.apply(obj, arguments); @@ -5300,317 +5834,609 @@ each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function( // Add all accessor `Array` functions to the wrapper. each(['concat', 'join', 'slice'], function(name) { var method = ArrayProto[name]; - _$1.prototype[name] = function() { + _.prototype[name] = function() { var obj = this._wrapped; if (obj != null) obj = method.apply(obj, arguments); return chainResult(this, obj); }; }); +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js // Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js // Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + // Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); +var index_default_ = mixin(modules_namespaceObject); // Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + /***/ }), -/***/ 571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + + + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js + + +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } + + return external_crypto_default().createHash('md5').update(bytes).digest(); +} + +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js + + +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js + + + +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` + + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; + } + + return buf; + } + + return esm_node_stringify(rnds); +} + +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js + + +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } + + return external_crypto_default().createHash('sha1').update(bytes).digest(); +} + +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + return parseInt(uuid.substr(14, 1), 16); +} + +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + + -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. -var underscoreNodeF = __nccwpck_require__(641); -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map /***/ }), diff --git a/.github/actions/javascript/checkDeployBlockers/index.js b/.github/actions/javascript/checkDeployBlockers/index.js index ca368f0cff29..77f58453fa04 100644 --- a/.github/actions/javascript/checkDeployBlockers/index.js +++ b/.github/actions/javascript/checkDeployBlockers/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 6265: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const core = __nccwpck_require__(2186); const CONST = __nccwpck_require__(4097); const GithubUtils = __nccwpck_require__(7999); @@ -110,7 +110,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16078,1066 +16078,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17146,19 +17211,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17169,34 +17243,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17206,15 +17294,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17237,31 +17330,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17276,9 +17391,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17287,6 +17407,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17295,6 +17418,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17304,10 +17428,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17325,32 +17453,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17387,7 +17536,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17441,7 +17590,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17450,14 +17599,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17465,11 +17618,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17478,13 +17632,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17496,6 +17657,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17514,26 +17680,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17541,12 +17723,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17559,11 +17741,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17571,31 +17758,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17643,6 +17844,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17681,13 +17886,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17695,6 +17904,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17708,6 +17918,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17717,6 +17928,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17730,9 +17942,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17744,11 +17964,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17757,18 +17981,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17776,10 +18010,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17791,7 +18030,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17801,29 +18040,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17831,7 +18093,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17844,10 +18106,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17857,12 +18124,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17882,12 +18154,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17899,15 +18181,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17916,10 +18208,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17928,20 +18225,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -17956,25 +18265,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -17994,12 +18317,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18019,6 +18348,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18028,21 +18366,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18054,11 +18399,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18080,6 +18433,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18093,53 +18450,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18148,545 +18532,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js index 1b2e81fc244e..d774a73eb23c 100644 --- a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js +++ b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 3926: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const core = __nccwpck_require__(2186); const moment = __nccwpck_require__(9623); const CONST = __nccwpck_require__(4097); @@ -212,7 +212,7 @@ module.exports = CONST; /***/ 669: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const {spawn, execSync} = __nccwpck_require__(3129); const CONST = __nccwpck_require__(4097); const sanitizeStringForJSONParse = __nccwpck_require__(9338); @@ -351,7 +351,7 @@ module.exports = { /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -909,7 +909,7 @@ module.exports = function (inputString) { /***/ 8007: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const SEMANTIC_VERSION_LEVELS = { MAJOR: 'MAJOR', @@ -22193,1066 +22193,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -23261,19 +23326,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -23284,34 +23358,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -23321,15 +23409,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -23352,31 +23445,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -23391,9 +23506,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -23402,6 +23522,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -23410,6 +23533,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -23419,10 +23543,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -23440,32 +23568,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -23502,7 +23651,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -23556,7 +23705,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -23565,14 +23714,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -23580,11 +23733,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -23593,13 +23747,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -23611,6 +23772,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -23629,26 +23795,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -23656,12 +23838,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -23674,11 +23856,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -23686,31 +23873,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -23758,6 +23959,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -23796,13 +24001,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -23810,6 +24019,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -23823,6 +24033,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -23832,6 +24043,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -23845,9 +24057,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -23859,11 +24079,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -23872,18 +24096,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -23891,10 +24125,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -23906,7 +24145,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -23916,29 +24155,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -23946,7 +24208,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -23959,10 +24221,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -23972,12 +24239,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -23997,12 +24269,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -24014,15 +24296,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -24031,10 +24323,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -24043,20 +24340,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -24071,25 +24380,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -24109,12 +24432,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -24134,6 +24463,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -24143,21 +24481,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -24169,11 +24514,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -24195,6 +24548,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -24208,53 +24565,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -24263,545 +24647,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/getDeployPullRequestList/index.js b/.github/actions/javascript/getDeployPullRequestList/index.js index 56541aa31b27..01e8f166b397 100644 --- a/.github/actions/javascript/getDeployPullRequestList/index.js +++ b/.github/actions/javascript/getDeployPullRequestList/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 5847: /***/ ((__unused_webpack_module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const core = __nccwpck_require__(2186); const github = __nccwpck_require__(5438); const ActionUtils = __nccwpck_require__(970); @@ -146,7 +146,7 @@ module.exports = CONST; /***/ 669: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const {spawn, execSync} = __nccwpck_require__(3129); const CONST = __nccwpck_require__(4097); const sanitizeStringForJSONParse = __nccwpck_require__(9338); @@ -285,7 +285,7 @@ module.exports = { /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -843,7 +843,7 @@ module.exports = function (inputString) { /***/ 8007: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const SEMANTIC_VERSION_LEVELS = { MAJOR: 'MAJOR', @@ -16479,1066 +16479,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17547,19 +17612,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17570,34 +17644,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17607,15 +17695,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17638,31 +17731,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17677,9 +17792,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17688,6 +17808,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17696,6 +17819,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17705,10 +17829,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17726,32 +17854,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17788,7 +17937,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17842,7 +17991,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17851,14 +18000,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17866,11 +18019,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17879,13 +18033,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17897,6 +18058,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17915,26 +18081,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17942,12 +18124,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17960,11 +18142,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17972,31 +18159,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -18044,6 +18245,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -18082,13 +18287,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -18096,6 +18305,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -18109,6 +18319,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -18118,6 +18329,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -18131,9 +18343,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -18145,11 +18365,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -18158,18 +18382,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -18177,10 +18411,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -18192,7 +18431,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -18202,29 +18441,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -18232,7 +18494,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -18245,10 +18507,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -18258,12 +18525,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -18283,12 +18555,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -18300,15 +18582,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -18317,10 +18609,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -18329,20 +18626,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -18357,25 +18666,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -18395,12 +18718,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18420,6 +18749,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18429,21 +18767,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18455,11 +18800,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18481,6 +18834,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18494,53 +18851,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18549,545 +18933,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/getPreviousVersion/index.js b/.github/actions/javascript/getPreviousVersion/index.js index 5498aa3996d7..37db08db93e9 100644 --- a/.github/actions/javascript/getPreviousVersion/index.js +++ b/.github/actions/javascript/getPreviousVersion/index.js @@ -10,7 +10,7 @@ module.exports = const {readFileSync} = __nccwpck_require__(747); const core = __nccwpck_require__(186); -const _ = __nccwpck_require__(571); +const _ = __nccwpck_require__(947); const versionUpdater = __nccwpck_require__(7); const semverLevel = core.getInput('SEMVER_LEVEL', {require: true}); @@ -28,7 +28,7 @@ core.setOutput('PREVIOUS_VERSION', previousVersion); /***/ 7: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(571); +const _ = __nccwpck_require__(947); const SEMANTIC_VERSION_LEVELS = { MAJOR: 'MAJOR', @@ -2214,8 +2214,8 @@ exports.debug = debug; // for test /***/ }), -/***/ 521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +/***/ 947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; // ESM COMPAT FLAG @@ -2223,636 +2223,672 @@ __nccwpck_require__.r(__webpack_exports__); // EXPORTS __nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip }); -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; - return rnds8Pool.slice(poolPtr, poolPtr += 16); -} -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); -} +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -const byteToHex = []; +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return uuid; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; +} -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; +} - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +/* harmony default export */ const isString = (tagTester('String')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +/* harmony default export */ const isNumber = (tagTester('Number')); - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isDate = (tagTester('Date')); - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +/* harmony default export */ const isError = (tagTester('Error')); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +/* harmony default export */ const isSymbol = (tagTester('Symbol')); - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - b[i++] = clockseq & 0xff; // `node` - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - return buf || esm_node_stringify(b); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +var isFunction = tagTester('Function'); - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ +/* harmony default export */ const modules_isFunction = (isFunction); - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - const bytes = []; - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } - return bytes; -} -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } - - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` - - - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; - - if (buf) { - offset = offset || 0; - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +var isDataView = tagTester('DataView'); - return buf; - } +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); +} - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; -} -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } - return external_crypto_default().createHash('md5').update(bytes).digest(); +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js - +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +var isArguments = tagTester('Arguments'); -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +/* harmony default export */ const modules_isArguments = (isArguments); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); } -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } - return external_crypto_default().createHash('sha1').update(bytes).digest(); +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js - +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } - - return parseInt(uuid.substr(14, 1), 16); } -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js - +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js -/***/ }), -/***/ 641: -/***/ ((__unused_webpack_module, exports) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. -Object.defineProperty(exports, "__esModule", ({ value: true })); -// Current version. -var VERSION = '1.13.4'; +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); } - args[startIndex] = rest; - return func.apply(this, args); }; } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} - -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} - -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} - -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } } -var isString = tagTester('String'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); - -var isSymbol = tagTester('Symbol'); - -var isArrayBuffer = tagTester('ArrayBuffer'); - -var isFunction = tagTester('Function'); - -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} - -var isFunction$1 = isFunction; - -var hasObjectTag = tagTester('Object'); - -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); - -var isDataView = tagTester('DataView'); - -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); -} - -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); - -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); - -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); -} - -var isArguments = tagTester('Arguments'); - -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); - -var isArguments$1 = isArguments; - -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} - -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; - }; -} - -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; - } -} - -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; -} - -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); - -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); - -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); -} - -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); - -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); - -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); - } - }; -} - -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; - - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} // Retrieve the names of an object's own properties. // Delegates to **ECMAScript 5**'s native `Object.keys`. @@ -2860,25 +2896,35 @@ function keys(obj) { if (!isObject(obj)) return []; if (nativeKeys) return nativeKeys(obj); var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); + for (var key in obj) if (has(obj, key)) keys.push(key); // Ahem, IE < 9. if (hasEnumBug) collectNonEnumProps(obj, keys); return keys; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js + + + + + + // Is a given array, string, or object empty? // An "empty" object has no enumerable own-properties. function isEmpty(obj) { if (obj == null) return true; // Skip the more expensive `toString`-based type checks if `obj` has no // `.length`. - var length = getLength(obj); + var length = _getLength(obj); if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) + isArray(obj) || isString(obj) || modules_isArguments(obj) )) return length === 0; - return getLength(keys(obj)) === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js + + // Returns whether an object has a given set of `key:value` pairs. function isMatch(object, attrs) { var _keys = keys(attrs), length = _keys.length; @@ -2891,40 +2937,58 @@ function isMatch(object, attrs) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js + + // If Underscore is called as a function, it returns a wrapped object that can // be used OO-style. This wrapper holds altered versions of all functions added // through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); this._wrapped = obj; } -_$1.VERSION = VERSION; +_.VERSION = VERSION; // Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { +_.prototype.value = function() { return this._wrapped; }; // Provide unwrapping proxies for some methods used in engine operations // such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -_$1.prototype.toString = function() { +_.prototype.toString = function() { return String(this._wrapped); }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js + + // Internal function to wrap or shallow-copy an ArrayBuffer, // typed array or DataView to a new view, reusing the buffer. function toBufferView(bufferSource) { return new Uint8Array( bufferSource.buffer || bufferSource, bufferSource.byteOffset || 0, - getByteLength(bufferSource) + _getByteLength(bufferSource) ); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js + + + + + + + + + + + // We use this string twice, so give it a name for minification. var tagDataView = '[object DataView]'; @@ -2946,14 +3010,14 @@ function eq(a, b, aStack, bStack) { // Internal recursive comparison function for `_.isEqual`. function deepEq(a, b, aStack, bStack) { // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; className = tagDataView; } switch (className) { @@ -2985,9 +3049,9 @@ function deepEq(a, b, aStack, bStack) { } var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; areArrays = true; } @@ -2997,8 +3061,8 @@ function deepEq(a, b, aStack, bStack) { // Objects with different constructors are not equivalent, but `Object`s or `Array`s // from different frames are. var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) && ('constructor' in a && 'constructor' in b)) { return false; } @@ -3039,7 +3103,7 @@ function deepEq(a, b, aStack, bStack) { while (length--) { // Deep compare each member key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; } } // Remove the first object from the stack of traversed objects. @@ -3053,6 +3117,11 @@ function isEqual(a, b) { return eq(a, b); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js + + + + // Retrieve all the enumerable property names of an object. function allKeys(obj) { if (!isObject(obj)) return []; @@ -3063,24 +3132,29 @@ function allKeys(obj) { return keys; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js + + + + // Since the regular `Object.prototype.toString` type tests don't work for // some types in IE 11, we use a fingerprinting heuristic instead, based // on the methods. It's not great, but it's the best we got. // The fingerprint method lists are defined below. function ie11fingerprint(methods) { - var length = getLength(methods); + var length = _getLength(methods); return function(obj) { if (obj == null) return false; // `Map`, `WeakMap` and `Set` have no enumerable keys. var keys = allKeys(obj); - if (getLength(keys)) return false; + if (_getLength(keys)) return false; for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; + if (!modules_isFunction(obj[methods[i]])) return false; } // If we are testing against `WeakMap`, we need to ensure that // `obj` doesn't have a `forEach` method in order to distinguish // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } @@ -3097,13 +3171,34 @@ var mapMethods = commonInit.concat(forEachName, mapTail), weakMapMethods = commonInit.concat(mapTail), setMethods = ['add'].concat(commonInit, forEachName, hasName); -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js -var isWeakSet = tagTester('WeakSet'); // Retrieve the values of an object's properties. function values(obj) { @@ -3116,6 +3211,9 @@ function values(obj) { return values; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + // Convert an object into a list of `[key, value]` pairs. // The opposite of `_.object` with one argument. function pairs(obj) { @@ -3128,6 +3226,9 @@ function pairs(obj) { return pairs; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js + + // Invert the keys and values of an object. The values must be serializable. function invert(obj) { var result = {}; @@ -3138,15 +3239,19 @@ function invert(obj) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js + + // Return a sorted list of the function names available on the object. function functions(obj) { var names = []; for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); + if (modules_isFunction(obj[key])) names.push(key); } return names.sort(); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js // An internal function for creating assigner functions. function createAssigner(keysFunc, defaults) { return function(obj) { @@ -3166,16 +3271,32 @@ function createAssigner(keysFunc, defaults) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js + + + // Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); +/* harmony default export */ const extend = (createAssigner(allKeys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js + + // Assigns a given object with all the own properties in the passed-in // object(s). // (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + // Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + // Create a naked function reference for surrogate-prototype-swapping. function ctor() { @@ -3193,6 +3314,10 @@ function baseCreate(prototype) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js + + + // Creates an object that inherits from the given prototype object. // If additional properties are provided then they will be added to the // created object. @@ -3202,12 +3327,18 @@ function create(prototype, props) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js + + + + // Create a (shallow-cloned) duplicate of an object. function clone(obj) { if (!isObject(obj)) return obj; return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -3216,19 +3347,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -3239,34 +3379,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -3276,15 +3430,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -3307,31 +3466,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -3346,9 +3527,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -3357,6 +3543,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -3365,6 +3554,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -3374,10 +3564,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -3395,32 +3589,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + + +// Function for unescaping strings from HTML interpolation. +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js -// Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -3457,7 +3672,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -3511,7 +3726,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -3520,14 +3735,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -3535,11 +3754,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -3548,13 +3768,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -3566,6 +3793,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -3584,26 +3816,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -3611,12 +3859,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -3629,11 +3877,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -3641,31 +3894,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -3713,6 +3980,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -3751,13 +4022,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -3765,6 +4040,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -3778,6 +4054,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -3787,6 +4064,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -3800,9 +4078,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -3814,11 +4100,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -3827,18 +4117,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -3846,10 +4146,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -3861,7 +4166,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -3871,29 +4176,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -3901,7 +4229,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -3914,10 +4242,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -3927,12 +4260,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -3952,12 +4290,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -3969,15 +4317,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -3986,10 +4344,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -3998,20 +4361,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -4026,25 +4401,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -4064,12 +4453,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -4089,6 +4484,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -4098,21 +4502,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -4124,11 +4535,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -4150,6 +4569,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -4163,53 +4586,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -4218,22 +4668,34 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + // Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in @@ -4242,6 +4704,9 @@ function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + // Get the first element of an array. Passing **n** will return the first N // values in the array. The **guard** check allows it to work with `_.map`. function first(array, n, guard) { @@ -4250,6 +4715,9 @@ function first(array, n, guard) { return initial(array, array.length - n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + // Returns everything but the first entry of the `array`. Especially useful on // the `arguments` object. Passing an **n** will return the rest N values in the // `array`. @@ -4257,6 +4725,9 @@ function rest(array, n, guard) { return slice.call(array, n == null || guard ? 1 : n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + // Get the last element of an array. Passing **n** will return the last N // values in the array. function last(array, n, guard) { @@ -4265,30 +4736,52 @@ function last(array, n, guard) { return rest(array, Math.max(0, array.length - n)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + // Trim out all falsy values from an array. function compact(array) { return filter(array, Boolean); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + // Flatten out an array, either recursively (by default), or up to `depth`. // Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); +function flatten_flatten(array, depth) { + return flatten(array, depth, false); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + // Take the difference between one array and a number of other arrays. // Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); return filter(array, function(value){ return !contains(rest, value); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + // Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { return difference(array, otherArrays); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + // Produce a duplicate-free version of the array. If the array has already // been sorted, you have the option of using a faster algorithm. @@ -4304,7 +4797,7 @@ function uniq(array, isSorted, iteratee, context) { if (iteratee != null) iteratee = cb(iteratee, context); var result = []; var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { + for (var i = 0, length = _getLength(array); i < length; i++) { var value = array[i], computed = iteratee ? iteratee(value, i, array) : value; if (isSorted && !iteratee) { @@ -4322,18 +4815,27 @@ function uniq(array, isSorted, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + // Produce an array that contains the union: each distinct element from all of // the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + // Produce an array that contains every item shared between all the // passed-in arrays. function intersection(array) { var result = []; var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { + for (var i = 0, length = _getLength(array); i < length; i++) { var item = array[i]; if (contains(result, item)) continue; var j; @@ -4345,10 +4847,15 @@ function intersection(array) { return result; } -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; var result = Array(length); for (var index = 0; index < length; index++) { @@ -4357,16 +4864,23 @@ function unzip(array) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + // Zip together multiple lists into a single array -- elements that share // an index go together. -var zip = restArguments(unzip); +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + // Converts lists into objects. Pass either a single array of `[key, value]` // pairs, or two parallel arrays of the same length -- one of keys, and one of // the corresponding values. Passing by pairs is the reverse of `_.pairs`. function object(list, values) { var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { + for (var i = 0, length = _getLength(list); i < length; i++) { if (values) { result[list[i]] = values[i]; } else { @@ -4376,6 +4890,7 @@ function object(list, values) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js // Generate an integer Array containing an arithmetic progression. A port of // the native Python `range()` function. See // [the Python documentation](https://docs.python.org/library/functions.html#range). @@ -4398,6 +4913,9 @@ function range(start, stop, step) { return range; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + // Chunk a single array into multiple arrays, each containing `count` or fewer // items. function chunk(array, count) { @@ -4410,28 +4928,44 @@ function chunk(array, count) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + // Helper function to continue chaining intermediate results. function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return instance._chain ? _(obj).chain() : obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + // Add your own custom functions to the Underscore object. function mixin(obj) { each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { + var func = _[name] = obj[name]; + _.prototype[name] = function() { var args = [this._wrapped]; push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); + return chainResult(this, func.apply(_, args)); }; }); - return _$1; + return _; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + // Add all mutator `Array` functions to the wrapper. each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { var method = ArrayProto[name]; - _$1.prototype[name] = function() { + _.prototype[name] = function() { var obj = this._wrapped; if (obj != null) { method.apply(obj, arguments); @@ -4446,317 +4980,609 @@ each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function( // Add all accessor `Array` functions to the wrapper. each(['concat', 'join', 'slice'], function(name) { var method = ArrayProto[name]; - _$1.prototype[name] = function() { + _.prototype[name] = function() { var obj = this._wrapped; if (obj != null) obj = method.apply(obj, arguments); return chainResult(this, obj); }; }); +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js // Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js // Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + // Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); +var index_default_ = mixin(modules_namespaceObject); // Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + /***/ }), -/***/ 571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + + + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js + + +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } + + return external_crypto_default().createHash('md5').update(bytes).digest(); +} + +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js + + +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js + + + +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` + + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; + } + + return buf; + } + + return esm_node_stringify(rnds); +} + +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js + + +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } + + return external_crypto_default().createHash('sha1').update(bytes).digest(); +} + +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + return parseInt(uuid.substr(14, 1), 16); +} + +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + + -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. -var underscoreNodeF = __nccwpck_require__(641); -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map /***/ }), diff --git a/.github/actions/javascript/getPullRequestDetails/index.js b/.github/actions/javascript/getPullRequestDetails/index.js index 28e0a65db686..b62d404b9f89 100644 --- a/.github/actions/javascript/getPullRequestDetails/index.js +++ b/.github/actions/javascript/getPullRequestDetails/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 8306: /***/ ((__unused_webpack_module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const core = __nccwpck_require__(2186); const CONST = __nccwpck_require__(4097); const ActionUtils = __nccwpck_require__(970); @@ -155,7 +155,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16123,1066 +16123,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17191,19 +17256,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17214,34 +17288,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17251,15 +17339,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17282,31 +17375,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17321,9 +17436,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17332,6 +17452,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17340,6 +17463,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17349,10 +17473,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17370,32 +17498,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17432,7 +17581,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17486,7 +17635,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17495,14 +17644,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17510,11 +17663,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17523,13 +17677,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17541,6 +17702,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17559,26 +17725,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17586,12 +17768,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17604,11 +17786,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17616,31 +17803,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17688,6 +17889,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17726,13 +17931,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17740,6 +17949,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17753,6 +17963,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17762,6 +17973,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17775,9 +17987,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17789,11 +18009,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17802,18 +18026,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17821,10 +18055,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17836,7 +18075,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17846,29 +18085,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17876,7 +18138,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17889,10 +18151,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17902,12 +18169,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17927,12 +18199,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17944,15 +18226,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17961,10 +18253,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17973,20 +18270,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -18001,25 +18310,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -18039,12 +18362,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18064,6 +18393,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18073,21 +18411,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18099,11 +18444,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18125,6 +18478,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18138,53 +18495,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18193,545 +18577,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/getReleaseBody/index.js b/.github/actions/javascript/getReleaseBody/index.js index 460ac29d724e..c1cb5c473912 100644 --- a/.github/actions/javascript/getReleaseBody/index.js +++ b/.github/actions/javascript/getReleaseBody/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 8201: /***/ ((__unused_webpack_module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const core = __nccwpck_require__(2186); const ActionUtils = __nccwpck_require__(970); const GithubUtils = __nccwpck_require__(7999); @@ -97,7 +97,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16065,1066 +16065,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17133,19 +17198,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17156,34 +17230,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17193,15 +17281,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17224,31 +17317,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17263,9 +17378,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17274,6 +17394,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17282,6 +17405,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17291,10 +17415,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17312,32 +17440,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17374,7 +17523,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17428,7 +17577,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17437,14 +17586,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17452,11 +17605,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17465,13 +17619,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17483,6 +17644,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17501,26 +17667,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17528,12 +17710,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17546,11 +17728,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17558,31 +17745,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17630,6 +17831,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17668,13 +17873,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17682,6 +17891,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17695,6 +17905,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17704,6 +17915,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17717,9 +17929,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17731,11 +17951,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17744,18 +17968,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17763,10 +17997,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17778,7 +18017,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17788,29 +18027,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17818,7 +18080,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17831,10 +18093,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17844,12 +18111,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17869,12 +18141,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17886,15 +18168,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17903,10 +18195,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17915,20 +18212,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -17943,25 +18252,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -17981,12 +18304,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18006,6 +18335,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18015,21 +18353,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18041,11 +18386,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18067,6 +18420,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18080,53 +18437,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18135,545 +18519,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/isStagingDeployLocked/index.js b/.github/actions/javascript/isStagingDeployLocked/index.js index 9bcb3f24e7ac..d4bd75fcec59 100644 --- a/.github/actions/javascript/isStagingDeployLocked/index.js +++ b/.github/actions/javascript/isStagingDeployLocked/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 8441: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const core = __nccwpck_require__(2186); const GithubUtils = __nccwpck_require__(7999); @@ -61,7 +61,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16029,1066 +16029,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17097,19 +17162,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17120,34 +17194,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17157,15 +17245,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17188,31 +17281,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17227,9 +17342,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17238,6 +17358,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17246,6 +17369,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17255,10 +17379,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17276,32 +17404,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17338,7 +17487,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17392,7 +17541,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17401,14 +17550,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17416,11 +17569,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17429,13 +17583,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17447,6 +17608,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17465,26 +17631,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17492,12 +17674,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17510,11 +17692,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17522,31 +17709,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17594,6 +17795,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17632,13 +17837,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17646,6 +17855,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17659,6 +17869,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17668,6 +17879,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17681,9 +17893,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17695,11 +17915,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17708,18 +17932,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17727,10 +17961,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17742,7 +17981,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17752,29 +17991,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17782,7 +18044,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17795,10 +18057,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17808,12 +18075,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17833,12 +18105,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17850,15 +18132,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17867,10 +18159,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17879,20 +18176,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -17907,25 +18216,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -17945,12 +18268,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -17970,6 +18299,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -17979,21 +18317,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18005,11 +18350,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18031,6 +18384,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18044,53 +18401,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18099,545 +18483,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/markPullRequestsAsDeployed/index.js b/.github/actions/javascript/markPullRequestsAsDeployed/index.js index 38a45bda5054..1b353abcb054 100644 --- a/.github/actions/javascript/markPullRequestsAsDeployed/index.js +++ b/.github/actions/javascript/markPullRequestsAsDeployed/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 2759: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {context} = __nccwpck_require__(5438); @@ -75,86 +75,77 @@ function getDeployMessage(deployer, deployVerb, prTitle) { * @param {String} message * @returns {Promise} */ -function commentPR(PR, message) { - return GithubUtils.createComment(context.repo.repo, PR, message) - .then(() => console.log(`Comment created on #${PR} successfully 🎉`)) - .catch((err) => { - console.log(`Unable to write comment on #${PR} 😞`); - core.setFailed(err.message); - }); +async function commentPR(PR, message) { + try { + await GithubUtils.createComment(context.repo.report, PR, message); + console.log(`Comment created on #${PR} successfully 🎉`); + } catch (err) { + console.log(`Unable to write comment on #${PR} 😞`); + core.setFailed(err.message); + } } -const run = function () { +const run = async function () { if (isProd) { - // First find the deployer (who closed the last deploy checklist)? - return GithubUtils.octokit.issues - .listForRepo({ - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - labels: CONST.LABELS.STAGING_DEPLOY, - state: 'closed', - }) - .then(({data}) => _.first(data).number) - .then((lastDeployChecklistNumber) => GithubUtils.getActorWhoClosedIssue(lastDeployChecklistNumber)) - .then((actor) => { - // Create comment on each pull request (one after another to avoid throttling issues) - const deployMessage = getDeployMessage(actor, 'Deployed'); - _.reduce(prList, (promise, pr) => promise.then(() => commentPR(pr, deployMessage)), Promise.resolve()); - }); + // Find the previous deploy checklist + const {data: deployChecklists} = await GithubUtils.octokit.issues.listForRepo({ + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + labels: CONST.LABELS.STAGING_DEPLOY, + state: 'closed', + }); + const previousChecklistID = _.first(deployChecklists).number; + + // who closed the last deploy checklist? + const deployer = await GithubUtils.getActorWhoClosedIssue(previousChecklistID); + + // Create comment on each pull request (one at a time to avoid throttling issues) + const deployMessage = getDeployMessage(deployer, 'Deployed'); + for (const pr of prList) { + await commentPR(pr, deployMessage); + } + return; } // First find out if this is a normal staging deploy or a CP by looking at the commit message on the tag - return GithubUtils.octokit.repos - .listTags({ + const {data: recentTags} = await GithubUtils.octokit.repos.listTags({ + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + per_page: 100, + }); + const currentTag = _.find(recentTags, (tag) => tag.name === version); + if (!currentTag) { + const err = `Could not find tag matching ${version}`; + console.error(err); + core.setFailed(err); + return; + } + const commitMessage = ( + await GithubUtils.octokit.git.getCommit({ owner: CONST.GITHUB_OWNER, repo: CONST.APP_REPO, - per_page: 100, - }) - .then(({data}) => { - const tagSHA = _.find(data, (tag) => tag.name === version).commit.sha; - return GithubUtils.octokit.git.getCommit({ - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - commit_sha: tagSHA, - }); + commit_sha: currentTag.commit.sha, }) - .then(({data}) => { - const isCP = /Merge pull request #\d+ from Expensify\/.*-?cherry-pick-staging-\d+/.test(data.message); - _.reduce( - prList, - (promise, PR) => - promise - - // Then, for each PR, find out who merged it and determine the deployer - .then(() => - GithubUtils.octokit.pulls.get({ - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - pull_number: PR, - }), - ) - .then((response) => { - /* - * The deployer for staging deploys is: - * 1. For regular staging deploys, the person who merged the PR. - * 2. For automatic CPs (using the label), the person who merged the PR. - * 3. For manual CPs (using the GH UI), the person who triggered the workflow - * (reflected in the branch name). - */ - let deployer = lodashGet(response, 'data.merged_by.login', ''); - const issueTitle = lodashGet(response, 'data.title', ''); - const CPActorMatches = data.message.match(/Merge pull request #\d+ from Expensify\/(.+)-cherry-pick-staging-\d+/); - if (_.isArray(CPActorMatches) && CPActorMatches.length === 2 && CPActorMatches[1] !== CONST.OS_BOTIFY) { - deployer = CPActorMatches[1]; - } - - // Finally, comment on the PR - const deployMessage = getDeployMessage(deployer, isCP ? 'Cherry-picked' : 'Deployed', issueTitle); - return commentPR(PR, deployMessage); - }), - Promise.resolve(), - ); + ).data.message; + const isCP = /[\S\s]*\(cherry picked from commit .*\)/.test(commitMessage); + + for (const prNumber of prList) { + /* + * Determine who the deployer for the PR is. The "deployer" for staging deploys is: + * 1. For regular staging deploys, the person who merged the PR. + * 2. For CPs, the person who triggered the workflow (documented in the cherry-pick commit message) + */ + const {data: pr} = await GithubUtils.octokit.pulls.get({ + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + pull_number: prNumber, }); + const deployer = isCP ? commitMessage.match(/\(cherry picked from commit \w*(?: by (.*))?[)]/)[1] || CONST.OS_BOTIFY : pr.merged_by.login; + + const title = pr.title; + const deployMessage = getDeployMessage(deployer, isCP ? 'Cherry-picked' : 'Deployed', title); + await commentPR(prNumber, deployMessage); + } }; if (require.main === require.cache[eval('__filename')]) { @@ -238,7 +229,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16250,711 +16241,681 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } - - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } - - return ""; -} +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -/***/ }), +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ -const byteToHex = []; +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; +} -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js - - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html - -let _nodeId; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js -let _clockseq; // Previous uuid creation time +/* harmony default export */ const isString = (tagTester('String')); -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); +/* harmony default export */ const isNumber = (tagTester('Number')); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +/* harmony default export */ const isDate = (tagTester('Date')); - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isError = (tagTester('Error')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch +/* harmony default export */ const isSymbol = (tagTester('Symbol')); - msecs += 12219292800000; // `time_low` +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +var isFunction = tagTester('Function'); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } - - return buf || esm_node_stringify(b); +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; } -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js - +/* harmony default export */ const modules_isFunction = (isFunction); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; -} +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +var isDataView = tagTester('DataView'); - return bytes; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } - - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; - if (buf) { - offset = offset || 0; - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - return buf; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; -} -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +var isArguments = tagTester('Arguments'); -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; } +}()); - return external_crypto_default().createHash('md5').update(bytes).digest(); -} - -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js - +/* harmony default export */ const modules_isArguments = (isArguments); -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - if (buf) { - offset = offset || 0; - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); +} - return esm_node_stringify(rnds); +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; } -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } - - return external_crypto_default().createHash('sha1').update(bytes).digest(); } -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/***/ }), -/***/ 2940: -/***/ ((module) => { +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) + }; +} + +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); } - return ret } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; - -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; - -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; - -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; - -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; - -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; - -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; - -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; - -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; -} - -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} - -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} - -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} - -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} - -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} - -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} - -var isString = tagTester('String'); - -var isNumber = tagTester('Number'); - -var isDate = tagTester('Date'); - -var isRegExp = tagTester('RegExp'); - -var isError = tagTester('Error'); - -var isSymbol = tagTester('Symbol'); - -var isArrayBuffer = tagTester('ArrayBuffer'); - -var isFunction = tagTester('Function'); - -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} - -var isFunction$1 = isFunction; - -var hasObjectTag = tagTester('Object'); - -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); - -var isDataView = tagTester('DataView'); - -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); -} - -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); - -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); - -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); -} - -var isArguments = tagTester('Arguments'); - -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); - -var isArguments$1 = isArguments; - -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} - -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; - }; -} - -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; - } -} - -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; -} - -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); - -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); - -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); -} - -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); - -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); - -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); - } - }; -} - -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; - - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} // Retrieve the names of an object's own properties. // Delegates to **ECMAScript 5**'s native `Object.keys`. @@ -16962,25 +16923,35 @@ function keys(obj) { if (!isObject(obj)) return []; if (nativeKeys) return nativeKeys(obj); var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); + for (var key in obj) if (has(obj, key)) keys.push(key); // Ahem, IE < 9. if (hasEnumBug) collectNonEnumProps(obj, keys); return keys; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js + + + + + + // Is a given array, string, or object empty? // An "empty" object has no enumerable own-properties. function isEmpty(obj) { if (obj == null) return true; // Skip the more expensive `toString`-based type checks if `obj` has no // `.length`. - var length = getLength(obj); + var length = _getLength(obj); if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) + isArray(obj) || isString(obj) || modules_isArguments(obj) )) return length === 0; - return getLength(keys(obj)) === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js + + // Returns whether an object has a given set of `key:value` pairs. function isMatch(object, attrs) { var _keys = keys(attrs), length = _keys.length; @@ -16993,40 +16964,58 @@ function isMatch(object, attrs) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js + + // If Underscore is called as a function, it returns a wrapped object that can // be used OO-style. This wrapper holds altered versions of all functions added // through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); this._wrapped = obj; } -_$1.VERSION = VERSION; +_.VERSION = VERSION; // Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { +_.prototype.value = function() { return this._wrapped; }; // Provide unwrapping proxies for some methods used in engine operations // such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -_$1.prototype.toString = function() { +_.prototype.toString = function() { return String(this._wrapped); }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js + + // Internal function to wrap or shallow-copy an ArrayBuffer, // typed array or DataView to a new view, reusing the buffer. function toBufferView(bufferSource) { return new Uint8Array( bufferSource.buffer || bufferSource, bufferSource.byteOffset || 0, - getByteLength(bufferSource) + _getByteLength(bufferSource) ); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js + + + + + + + + + + + // We use this string twice, so give it a name for minification. var tagDataView = '[object DataView]'; @@ -17048,14 +17037,14 @@ function eq(a, b, aStack, bStack) { // Internal recursive comparison function for `_.isEqual`. function deepEq(a, b, aStack, bStack) { // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; className = tagDataView; } switch (className) { @@ -17087,9 +17076,9 @@ function deepEq(a, b, aStack, bStack) { } var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; areArrays = true; } @@ -17099,8 +17088,8 @@ function deepEq(a, b, aStack, bStack) { // Objects with different constructors are not equivalent, but `Object`s or `Array`s // from different frames are. var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) && ('constructor' in a && 'constructor' in b)) { return false; } @@ -17141,7 +17130,7 @@ function deepEq(a, b, aStack, bStack) { while (length--) { // Deep compare each member key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; } } // Remove the first object from the stack of traversed objects. @@ -17155,6 +17144,11 @@ function isEqual(a, b) { return eq(a, b); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js + + + + // Retrieve all the enumerable property names of an object. function allKeys(obj) { if (!isObject(obj)) return []; @@ -17165,24 +17159,29 @@ function allKeys(obj) { return keys; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js + + + + // Since the regular `Object.prototype.toString` type tests don't work for // some types in IE 11, we use a fingerprinting heuristic instead, based // on the methods. It's not great, but it's the best we got. // The fingerprint method lists are defined below. function ie11fingerprint(methods) { - var length = getLength(methods); + var length = _getLength(methods); return function(obj) { if (obj == null) return false; // `Map`, `WeakMap` and `Set` have no enumerable keys. var keys = allKeys(obj); - if (getLength(keys)) return false; + if (_getLength(keys)) return false; for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; + if (!modules_isFunction(obj[methods[i]])) return false; } // If we are testing against `WeakMap`, we need to ensure that // `obj` doesn't have a `forEach` method in order to distinguish // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } @@ -17199,13 +17198,34 @@ var mapMethods = commonInit.concat(forEachName, mapTail), weakMapMethods = commonInit.concat(mapTail), setMethods = ['add'].concat(commonInit, forEachName, hasName); -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js -var isWeakSet = tagTester('WeakSet'); // Retrieve the values of an object's properties. function values(obj) { @@ -17218,6 +17238,9 @@ function values(obj) { return values; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + // Convert an object into a list of `[key, value]` pairs. // The opposite of `_.object` with one argument. function pairs(obj) { @@ -17230,6 +17253,9 @@ function pairs(obj) { return pairs; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js + + // Invert the keys and values of an object. The values must be serializable. function invert(obj) { var result = {}; @@ -17240,15 +17266,19 @@ function invert(obj) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js + + // Return a sorted list of the function names available on the object. function functions(obj) { var names = []; for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); + if (modules_isFunction(obj[key])) names.push(key); } return names.sort(); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js // An internal function for creating assigner functions. function createAssigner(keysFunc, defaults) { return function(obj) { @@ -17268,16 +17298,32 @@ function createAssigner(keysFunc, defaults) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js + + + // Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); +/* harmony default export */ const extend = (createAssigner(allKeys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js + + // Assigns a given object with all the own properties in the passed-in // object(s). // (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + // Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + // Create a naked function reference for surrogate-prototype-swapping. function ctor() { @@ -17295,6 +17341,10 @@ function baseCreate(prototype) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js + + + // Creates an object that inherits from the given prototype object. // If additional properties are provided then they will be added to the // created object. @@ -17304,12 +17354,18 @@ function create(prototype, props) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js + + + + // Create a (shallow-cloned) duplicate of an object. function clone(obj) { if (!isObject(obj)) return obj; return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17318,19 +17374,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17341,34 +17406,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17378,15 +17457,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17409,31 +17493,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17448,9 +17554,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17459,6 +17570,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17467,6 +17581,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17476,10 +17591,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17497,32 +17616,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17559,7 +17699,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17613,7 +17753,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17622,14 +17762,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17637,11 +17781,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17650,13 +17795,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17668,6 +17820,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17686,26 +17843,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17713,12 +17886,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17731,11 +17904,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17743,31 +17921,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17815,6 +18007,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17853,13 +18049,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17867,6 +18067,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17880,6 +18081,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17889,6 +18091,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17902,9 +18105,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17916,11 +18127,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17929,18 +18144,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17948,10 +18173,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17963,7 +18193,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17973,29 +18203,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -18003,7 +18256,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -18016,10 +18269,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -18029,12 +18287,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -18054,12 +18317,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -18071,15 +18344,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -18088,10 +18371,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -18100,20 +18388,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -18128,25 +18428,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -18166,12 +18480,18 @@ function max(obj, iteratee, context) { return result; } -// Return the minimum element (or element-based computation). -function min(obj, iteratee, context) { - var result = Infinity, lastComputed = Infinity, +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + +// Return the minimum element (or element-based computation). +function min(obj, iteratee, context) { + var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18191,6 +18511,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18200,21 +18529,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18226,11 +18562,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18252,6 +18596,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18265,53 +18613,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18320,22 +18695,34 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + // Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in @@ -18344,6 +18731,9 @@ function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + // Get the first element of an array. Passing **n** will return the first N // values in the array. The **guard** check allows it to work with `_.map`. function first(array, n, guard) { @@ -18352,6 +18742,9 @@ function first(array, n, guard) { return initial(array, array.length - n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + // Returns everything but the first entry of the `array`. Especially useful on // the `arguments` object. Passing an **n** will return the rest N values in the // `array`. @@ -18359,6 +18752,9 @@ function rest(array, n, guard) { return slice.call(array, n == null || guard ? 1 : n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + // Get the last element of an array. Passing **n** will return the last N // values in the array. function last(array, n, guard) { @@ -18367,30 +18763,52 @@ function last(array, n, guard) { return rest(array, Math.max(0, array.length - n)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + // Trim out all falsy values from an array. function compact(array) { return filter(array, Boolean); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + // Flatten out an array, either recursively (by default), or up to `depth`. // Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); +function flatten_flatten(array, depth) { + return flatten(array, depth, false); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + // Take the difference between one array and a number of other arrays. // Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); return filter(array, function(value){ return !contains(rest, value); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + // Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { return difference(array, otherArrays); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + // Produce a duplicate-free version of the array. If the array has already // been sorted, you have the option of using a faster algorithm. @@ -18406,7 +18824,7 @@ function uniq(array, isSorted, iteratee, context) { if (iteratee != null) iteratee = cb(iteratee, context); var result = []; var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { + for (var i = 0, length = _getLength(array); i < length; i++) { var value = array[i], computed = iteratee ? iteratee(value, i, array) : value; if (isSorted && !iteratee) { @@ -18424,18 +18842,27 @@ function uniq(array, isSorted, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + // Produce an array that contains the union: each distinct element from all of // the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + // Produce an array that contains every item shared between all the // passed-in arrays. function intersection(array) { var result = []; var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { + for (var i = 0, length = _getLength(array); i < length; i++) { var item = array[i]; if (contains(result, item)) continue; var j; @@ -18447,10 +18874,15 @@ function intersection(array) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + // Complement of zip. Unzip accepts an array of arrays and groups // each array's elements on shared indices. function unzip(array) { - var length = (array && max(array, getLength).length) || 0; + var length = (array && max(array, _getLength).length) || 0; var result = Array(length); for (var index = 0; index < length; index++) { @@ -18459,16 +18891,23 @@ function unzip(array) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + // Zip together multiple lists into a single array -- elements that share // an index go together. -var zip = restArguments(unzip); +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + // Converts lists into objects. Pass either a single array of `[key, value]` // pairs, or two parallel arrays of the same length -- one of keys, and one of // the corresponding values. Passing by pairs is the reverse of `_.pairs`. function object(list, values) { var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { + for (var i = 0, length = _getLength(list); i < length; i++) { if (values) { result[list[i]] = values[i]; } else { @@ -18478,6 +18917,7 @@ function object(list, values) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js // Generate an integer Array containing an arithmetic progression. A port of // the native Python `range()` function. See // [the Python documentation](https://docs.python.org/library/functions.html#range). @@ -18500,6 +18940,9 @@ function range(start, stop, step) { return range; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + // Chunk a single array into multiple arrays, each containing `count` or fewer // items. function chunk(array, count) { @@ -18512,28 +18955,44 @@ function chunk(array, count) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + // Helper function to continue chaining intermediate results. function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return instance._chain ? _(obj).chain() : obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + // Add your own custom functions to the Underscore object. function mixin(obj) { each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { + var func = _[name] = obj[name]; + _.prototype[name] = function() { var args = [this._wrapped]; push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); + return chainResult(this, func.apply(_, args)); }; }); - return _$1; + return _; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + // Add all mutator `Array` functions to the wrapper. each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { var method = ArrayProto[name]; - _$1.prototype[name] = function() { + _.prototype[name] = function() { var obj = this._wrapped; if (obj != null) { method.apply(obj, arguments); @@ -18548,317 +19007,675 @@ each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function( // Add all accessor `Array` functions to the wrapper. each(['concat', 'join', 'slice'], function(name) { var method = ArrayProto[name]; - _$1.prototype[name] = function() { + _.prototype[name] = function() { var obj = this._wrapped; if (obj != null) obj = method.apply(obj, arguments); return chainResult(this, obj); }; }); +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js // Named Exports +// ============= -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. -// Default Export +// Baseline setup. -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map -/***/ }), +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. -var underscoreNodeF = __nccwpck_require__(1641); -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + + + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js + + +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } + + return external_crypto_default().createHash('md5').update(bytes).digest(); +} + +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js + + +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js + + + +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` + + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; + } + + return buf; + } + + return esm_node_stringify(rnds); +} + +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js + + +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } + + return external_crypto_default().createHash('sha1').update(bytes).digest(); +} + +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + return parseInt(uuid.substr(14, 1), 16); +} + +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + + + + + + + + + +/***/ }), + +/***/ 2940: +/***/ ((module) => { + +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) + + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + + return wrapper + + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js b/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js index 708d001892c2..865379ac83fb 100644 --- a/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js +++ b/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js @@ -65,86 +65,77 @@ function getDeployMessage(deployer, deployVerb, prTitle) { * @param {String} message * @returns {Promise} */ -function commentPR(PR, message) { - return GithubUtils.createComment(context.repo.repo, PR, message) - .then(() => console.log(`Comment created on #${PR} successfully 🎉`)) - .catch((err) => { - console.log(`Unable to write comment on #${PR} 😞`); - core.setFailed(err.message); - }); +async function commentPR(PR, message) { + try { + await GithubUtils.createComment(context.repo.report, PR, message); + console.log(`Comment created on #${PR} successfully 🎉`); + } catch (err) { + console.log(`Unable to write comment on #${PR} 😞`); + core.setFailed(err.message); + } } -const run = function () { +const run = async function () { if (isProd) { - // First find the deployer (who closed the last deploy checklist)? - return GithubUtils.octokit.issues - .listForRepo({ - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - labels: CONST.LABELS.STAGING_DEPLOY, - state: 'closed', - }) - .then(({data}) => _.first(data).number) - .then((lastDeployChecklistNumber) => GithubUtils.getActorWhoClosedIssue(lastDeployChecklistNumber)) - .then((actor) => { - // Create comment on each pull request (one after another to avoid throttling issues) - const deployMessage = getDeployMessage(actor, 'Deployed'); - _.reduce(prList, (promise, pr) => promise.then(() => commentPR(pr, deployMessage)), Promise.resolve()); - }); + // Find the previous deploy checklist + const {data: deployChecklists} = await GithubUtils.octokit.issues.listForRepo({ + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + labels: CONST.LABELS.STAGING_DEPLOY, + state: 'closed', + }); + const previousChecklistID = _.first(deployChecklists).number; + + // who closed the last deploy checklist? + const deployer = await GithubUtils.getActorWhoClosedIssue(previousChecklistID); + + // Create comment on each pull request (one at a time to avoid throttling issues) + const deployMessage = getDeployMessage(deployer, 'Deployed'); + for (const pr of prList) { + await commentPR(pr, deployMessage); + } + return; } // First find out if this is a normal staging deploy or a CP by looking at the commit message on the tag - return GithubUtils.octokit.repos - .listTags({ + const {data: recentTags} = await GithubUtils.octokit.repos.listTags({ + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + per_page: 100, + }); + const currentTag = _.find(recentTags, (tag) => tag.name === version); + if (!currentTag) { + const err = `Could not find tag matching ${version}`; + console.error(err); + core.setFailed(err); + return; + } + const commitMessage = ( + await GithubUtils.octokit.git.getCommit({ owner: CONST.GITHUB_OWNER, repo: CONST.APP_REPO, - per_page: 100, - }) - .then(({data}) => { - const tagSHA = _.find(data, (tag) => tag.name === version).commit.sha; - return GithubUtils.octokit.git.getCommit({ - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - commit_sha: tagSHA, - }); + commit_sha: currentTag.commit.sha, }) - .then(({data}) => { - const isCP = /Merge pull request #\d+ from Expensify\/.*-?cherry-pick-staging-\d+/.test(data.message); - _.reduce( - prList, - (promise, PR) => - promise - - // Then, for each PR, find out who merged it and determine the deployer - .then(() => - GithubUtils.octokit.pulls.get({ - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - pull_number: PR, - }), - ) - .then((response) => { - /* - * The deployer for staging deploys is: - * 1. For regular staging deploys, the person who merged the PR. - * 2. For automatic CPs (using the label), the person who merged the PR. - * 3. For manual CPs (using the GH UI), the person who triggered the workflow - * (reflected in the branch name). - */ - let deployer = lodashGet(response, 'data.merged_by.login', ''); - const issueTitle = lodashGet(response, 'data.title', ''); - const CPActorMatches = data.message.match(/Merge pull request #\d+ from Expensify\/(.+)-cherry-pick-staging-\d+/); - if (_.isArray(CPActorMatches) && CPActorMatches.length === 2 && CPActorMatches[1] !== CONST.OS_BOTIFY) { - deployer = CPActorMatches[1]; - } - - // Finally, comment on the PR - const deployMessage = getDeployMessage(deployer, isCP ? 'Cherry-picked' : 'Deployed', issueTitle); - return commentPR(PR, deployMessage); - }), - Promise.resolve(), - ); + ).data.message; + const isCP = /[\S\s]*\(cherry picked from commit .*\)/.test(commitMessage); + + for (const prNumber of prList) { + /* + * Determine who the deployer for the PR is. The "deployer" for staging deploys is: + * 1. For regular staging deploys, the person who merged the PR. + * 2. For CPs, the person who triggered the workflow (documented in the cherry-pick commit message) + */ + const {data: pr} = await GithubUtils.octokit.pulls.get({ + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + pull_number: prNumber, }); + const deployer = isCP ? commitMessage.match(/\(cherry picked from commit \w*(?: by (.*))?[)]/)[1] || CONST.OS_BOTIFY : pr.merged_by.login; + + const title = pr.title; + const deployMessage = getDeployMessage(deployer, isCP ? 'Cherry-picked' : 'Deployed', title); + await commentPR(prNumber, deployMessage); + } }; if (require.main === module) { diff --git a/.github/actions/javascript/postTestBuildComment/index.js b/.github/actions/javascript/postTestBuildComment/index.js index 5da6c7ed667a..0537f1a22430 100644 --- a/.github/actions/javascript/postTestBuildComment/index.js +++ b/.github/actions/javascript/postTestBuildComment/index.js @@ -105,7 +105,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16117,1066 +16117,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17185,19 +17250,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17208,34 +17282,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17245,15 +17333,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17276,31 +17369,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17315,9 +17430,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17326,6 +17446,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17334,6 +17457,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17343,10 +17467,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17364,32 +17492,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17426,7 +17575,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17480,7 +17629,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17489,14 +17638,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17504,11 +17657,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17517,13 +17671,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17535,6 +17696,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17553,26 +17719,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17580,12 +17762,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17598,11 +17780,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17610,31 +17797,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17682,6 +17883,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17720,13 +17925,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17734,6 +17943,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17747,6 +17957,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17756,6 +17967,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17769,9 +17981,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17783,11 +18003,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17796,18 +18020,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17815,10 +18049,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17830,7 +18069,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17840,29 +18079,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17870,7 +18132,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17883,10 +18145,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17896,12 +18163,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17921,12 +18193,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17938,15 +18220,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17955,10 +18247,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17967,20 +18264,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -17995,25 +18304,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -18033,12 +18356,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18058,6 +18387,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18067,21 +18405,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18093,11 +18438,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18119,6 +18472,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18132,53 +18489,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18187,545 +18571,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/reopenIssueWithComment/index.js b/.github/actions/javascript/reopenIssueWithComment/index.js index 3efa2664a4c5..9c4532794ad1 100644 --- a/.github/actions/javascript/reopenIssueWithComment/index.js +++ b/.github/actions/javascript/reopenIssueWithComment/index.js @@ -74,7 +74,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16042,1066 +16042,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17110,19 +17175,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17133,34 +17207,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17170,15 +17258,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17201,31 +17294,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17240,9 +17355,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17251,6 +17371,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17259,6 +17382,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17268,10 +17392,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17289,32 +17417,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17351,7 +17500,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17405,7 +17554,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17414,14 +17563,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17429,11 +17582,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17442,13 +17596,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17460,6 +17621,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17478,26 +17644,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17505,12 +17687,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17523,11 +17705,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17535,31 +17722,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17607,6 +17808,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17645,13 +17850,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17659,6 +17868,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17672,6 +17882,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17681,6 +17892,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17694,9 +17906,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17708,11 +17928,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17721,18 +17945,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17740,10 +17974,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17755,7 +17994,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17765,29 +18004,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17795,7 +18057,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17808,10 +18070,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17821,12 +18088,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17846,12 +18118,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17863,15 +18145,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17880,10 +18172,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17892,20 +18189,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -17920,25 +18229,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -17958,12 +18281,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -17983,6 +18312,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -17992,21 +18330,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18018,11 +18363,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18044,6 +18397,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18057,53 +18414,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18112,545 +18496,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/reviewerChecklist/index.js b/.github/actions/javascript/reviewerChecklist/index.js index fc4ba728220b..3e8d06bf4e49 100644 --- a/.github/actions/javascript/reviewerChecklist/index.js +++ b/.github/actions/javascript/reviewerChecklist/index.js @@ -140,7 +140,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16152,1066 +16152,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17220,19 +17285,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17243,34 +17317,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17280,15 +17368,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17311,31 +17404,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17350,9 +17465,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17361,6 +17481,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17369,6 +17492,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17378,10 +17502,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17399,32 +17527,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17461,7 +17610,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17515,7 +17664,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17524,14 +17673,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17539,11 +17692,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17552,13 +17706,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17570,6 +17731,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17588,26 +17754,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17615,12 +17797,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17633,11 +17815,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17645,31 +17832,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17717,6 +17918,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17755,13 +17960,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17769,6 +17978,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17782,6 +17992,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17791,6 +18002,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17804,9 +18016,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17818,11 +18038,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17831,18 +18055,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17850,10 +18084,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17865,7 +18104,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17875,29 +18114,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17905,7 +18167,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17918,10 +18180,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17931,12 +18198,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17956,12 +18228,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17973,15 +18255,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17990,10 +18282,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -18002,20 +18299,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -18030,25 +18339,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -18068,12 +18391,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18093,6 +18422,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18102,21 +18440,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18128,11 +18473,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18154,6 +18507,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18167,53 +18524,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18222,545 +18606,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), diff --git a/.github/actions/javascript/verifySignedCommits/index.js b/.github/actions/javascript/verifySignedCommits/index.js index df8ca5b31bad..f96b2f7defe6 100644 --- a/.github/actions/javascript/verifySignedCommits/index.js +++ b/.github/actions/javascript/verifySignedCommits/index.js @@ -8,7 +8,7 @@ module.exports = /***/ 5740: /***/ ((__unused_webpack_module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const core = __nccwpck_require__(2186); const github = __nccwpck_require__(5438); const CONST = __nccwpck_require__(4097); @@ -63,7 +63,7 @@ module.exports = CONST; /***/ 7999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const _ = __nccwpck_require__(3571); +const _ = __nccwpck_require__(2947); const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {GitHub, getOctokitOptions} = __nccwpck_require__(3030); @@ -16075,1066 +16075,1131 @@ exports.debug = debug; // for test /***/ }), -/***/ 5030: -/***/ ((__unused_webpack_module, exports) => { +/***/ 2947: +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __nccwpck_require__) => { "use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "VERSION": () => /* reexport */ VERSION, + "after": () => /* reexport */ after, + "all": () => /* reexport */ every, + "allKeys": () => /* reexport */ allKeys, + "any": () => /* reexport */ some, + "assign": () => /* reexport */ extendOwn, + "before": () => /* reexport */ before, + "bind": () => /* reexport */ bind, + "bindAll": () => /* reexport */ bindAll, + "chain": () => /* reexport */ chain, + "chunk": () => /* reexport */ chunk, + "clone": () => /* reexport */ clone, + "collect": () => /* reexport */ map, + "compact": () => /* reexport */ compact, + "compose": () => /* reexport */ compose, + "constant": () => /* reexport */ constant, + "contains": () => /* reexport */ contains, + "countBy": () => /* reexport */ countBy, + "create": () => /* reexport */ create, + "debounce": () => /* reexport */ debounce, + "default": () => /* reexport */ index_default, + "defaults": () => /* reexport */ defaults, + "defer": () => /* reexport */ defer, + "delay": () => /* reexport */ delay, + "detect": () => /* reexport */ find, + "difference": () => /* reexport */ difference, + "drop": () => /* reexport */ rest, + "each": () => /* reexport */ each, + "escape": () => /* reexport */ modules_escape, + "every": () => /* reexport */ every, + "extend": () => /* reexport */ extend, + "extendOwn": () => /* reexport */ extendOwn, + "filter": () => /* reexport */ filter, + "find": () => /* reexport */ find, + "findIndex": () => /* reexport */ findIndex, + "findKey": () => /* reexport */ findKey, + "findLastIndex": () => /* reexport */ findLastIndex, + "findWhere": () => /* reexport */ findWhere, + "first": () => /* reexport */ first, + "flatten": () => /* reexport */ flatten_flatten, + "foldl": () => /* reexport */ reduce, + "foldr": () => /* reexport */ reduceRight, + "forEach": () => /* reexport */ each, + "functions": () => /* reexport */ functions, + "get": () => /* reexport */ get, + "groupBy": () => /* reexport */ groupBy, + "has": () => /* reexport */ has_has, + "head": () => /* reexport */ first, + "identity": () => /* reexport */ identity, + "include": () => /* reexport */ contains, + "includes": () => /* reexport */ contains, + "indexBy": () => /* reexport */ indexBy, + "indexOf": () => /* reexport */ indexOf, + "initial": () => /* reexport */ initial, + "inject": () => /* reexport */ reduce, + "intersection": () => /* reexport */ intersection, + "invert": () => /* reexport */ invert, + "invoke": () => /* reexport */ invoke, + "isArguments": () => /* reexport */ modules_isArguments, + "isArray": () => /* reexport */ isArray, + "isArrayBuffer": () => /* reexport */ isArrayBuffer, + "isBoolean": () => /* reexport */ isBoolean, + "isDataView": () => /* reexport */ modules_isDataView, + "isDate": () => /* reexport */ isDate, + "isElement": () => /* reexport */ isElement, + "isEmpty": () => /* reexport */ isEmpty, + "isEqual": () => /* reexport */ isEqual, + "isError": () => /* reexport */ isError, + "isFinite": () => /* reexport */ isFinite_isFinite, + "isFunction": () => /* reexport */ modules_isFunction, + "isMap": () => /* reexport */ isMap, + "isMatch": () => /* reexport */ isMatch, + "isNaN": () => /* reexport */ isNaN_isNaN, + "isNull": () => /* reexport */ isNull, + "isNumber": () => /* reexport */ isNumber, + "isObject": () => /* reexport */ isObject, + "isRegExp": () => /* reexport */ isRegExp, + "isSet": () => /* reexport */ isSet, + "isString": () => /* reexport */ isString, + "isSymbol": () => /* reexport */ isSymbol, + "isTypedArray": () => /* reexport */ modules_isTypedArray, + "isUndefined": () => /* reexport */ isUndefined, + "isWeakMap": () => /* reexport */ isWeakMap, + "isWeakSet": () => /* reexport */ isWeakSet, + "iteratee": () => /* reexport */ iteratee, + "keys": () => /* reexport */ keys, + "last": () => /* reexport */ last, + "lastIndexOf": () => /* reexport */ lastIndexOf, + "map": () => /* reexport */ map, + "mapObject": () => /* reexport */ mapObject, + "matcher": () => /* reexport */ matcher, + "matches": () => /* reexport */ matcher, + "max": () => /* reexport */ max, + "memoize": () => /* reexport */ memoize, + "methods": () => /* reexport */ functions, + "min": () => /* reexport */ min, + "mixin": () => /* reexport */ mixin, + "negate": () => /* reexport */ negate, + "noop": () => /* reexport */ noop, + "now": () => /* reexport */ now, + "object": () => /* reexport */ object, + "omit": () => /* reexport */ omit, + "once": () => /* reexport */ once, + "pairs": () => /* reexport */ pairs, + "partial": () => /* reexport */ modules_partial, + "partition": () => /* reexport */ partition, + "pick": () => /* reexport */ pick, + "pluck": () => /* reexport */ pluck, + "property": () => /* reexport */ property, + "propertyOf": () => /* reexport */ propertyOf, + "random": () => /* reexport */ random, + "range": () => /* reexport */ range, + "reduce": () => /* reexport */ reduce, + "reduceRight": () => /* reexport */ reduceRight, + "reject": () => /* reexport */ reject, + "rest": () => /* reexport */ rest, + "restArguments": () => /* reexport */ restArguments, + "result": () => /* reexport */ result, + "sample": () => /* reexport */ sample, + "select": () => /* reexport */ filter, + "shuffle": () => /* reexport */ shuffle, + "size": () => /* reexport */ size, + "some": () => /* reexport */ some, + "sortBy": () => /* reexport */ sortBy, + "sortedIndex": () => /* reexport */ sortedIndex, + "tail": () => /* reexport */ rest, + "take": () => /* reexport */ first, + "tap": () => /* reexport */ tap, + "template": () => /* reexport */ template, + "templateSettings": () => /* reexport */ templateSettings, + "throttle": () => /* reexport */ throttle, + "times": () => /* reexport */ times, + "toArray": () => /* reexport */ toArray, + "toPath": () => /* reexport */ toPath, + "transpose": () => /* reexport */ unzip, + "unescape": () => /* reexport */ modules_unescape, + "union": () => /* reexport */ union, + "uniq": () => /* reexport */ uniq, + "unique": () => /* reexport */ uniq, + "uniqueId": () => /* reexport */ uniqueId, + "unzip": () => /* reexport */ unzip, + "values": () => /* reexport */ values, + "where": () => /* reexport */ where, + "without": () => /* reexport */ without, + "wrap": () => /* reexport */ wrap, + "zip": () => /* reexport */ zip +}); -Object.defineProperty(exports, "__esModule", ({ value: true })); - -function getUserAgent() { - if (typeof navigator === "object" && "userAgent" in navigator) { - return navigator.userAgent; - } +// NAMESPACE OBJECT: ./node_modules/underscore/modules/index.js +var modules_namespaceObject = {}; +__nccwpck_require__.r(modules_namespaceObject); +__nccwpck_require__.d(modules_namespaceObject, { + "VERSION": () => VERSION, + "after": () => after, + "all": () => every, + "allKeys": () => allKeys, + "any": () => some, + "assign": () => extendOwn, + "before": () => before, + "bind": () => bind, + "bindAll": () => bindAll, + "chain": () => chain, + "chunk": () => chunk, + "clone": () => clone, + "collect": () => map, + "compact": () => compact, + "compose": () => compose, + "constant": () => constant, + "contains": () => contains, + "countBy": () => countBy, + "create": () => create, + "debounce": () => debounce, + "default": () => underscore_array_methods, + "defaults": () => defaults, + "defer": () => defer, + "delay": () => delay, + "detect": () => find, + "difference": () => difference, + "drop": () => rest, + "each": () => each, + "escape": () => modules_escape, + "every": () => every, + "extend": () => extend, + "extendOwn": () => extendOwn, + "filter": () => filter, + "find": () => find, + "findIndex": () => findIndex, + "findKey": () => findKey, + "findLastIndex": () => findLastIndex, + "findWhere": () => findWhere, + "first": () => first, + "flatten": () => flatten_flatten, + "foldl": () => reduce, + "foldr": () => reduceRight, + "forEach": () => each, + "functions": () => functions, + "get": () => get, + "groupBy": () => groupBy, + "has": () => has_has, + "head": () => first, + "identity": () => identity, + "include": () => contains, + "includes": () => contains, + "indexBy": () => indexBy, + "indexOf": () => indexOf, + "initial": () => initial, + "inject": () => reduce, + "intersection": () => intersection, + "invert": () => invert, + "invoke": () => invoke, + "isArguments": () => modules_isArguments, + "isArray": () => isArray, + "isArrayBuffer": () => isArrayBuffer, + "isBoolean": () => isBoolean, + "isDataView": () => modules_isDataView, + "isDate": () => isDate, + "isElement": () => isElement, + "isEmpty": () => isEmpty, + "isEqual": () => isEqual, + "isError": () => isError, + "isFinite": () => isFinite_isFinite, + "isFunction": () => modules_isFunction, + "isMap": () => isMap, + "isMatch": () => isMatch, + "isNaN": () => isNaN_isNaN, + "isNull": () => isNull, + "isNumber": () => isNumber, + "isObject": () => isObject, + "isRegExp": () => isRegExp, + "isSet": () => isSet, + "isString": () => isString, + "isSymbol": () => isSymbol, + "isTypedArray": () => modules_isTypedArray, + "isUndefined": () => isUndefined, + "isWeakMap": () => isWeakMap, + "isWeakSet": () => isWeakSet, + "iteratee": () => iteratee, + "keys": () => keys, + "last": () => last, + "lastIndexOf": () => lastIndexOf, + "map": () => map, + "mapObject": () => mapObject, + "matcher": () => matcher, + "matches": () => matcher, + "max": () => max, + "memoize": () => memoize, + "methods": () => functions, + "min": () => min, + "mixin": () => mixin, + "negate": () => negate, + "noop": () => noop, + "now": () => now, + "object": () => object, + "omit": () => omit, + "once": () => once, + "pairs": () => pairs, + "partial": () => modules_partial, + "partition": () => partition, + "pick": () => pick, + "pluck": () => pluck, + "property": () => property, + "propertyOf": () => propertyOf, + "random": () => random, + "range": () => range, + "reduce": () => reduce, + "reduceRight": () => reduceRight, + "reject": () => reject, + "rest": () => rest, + "restArguments": () => restArguments, + "result": () => result, + "sample": () => sample, + "select": () => filter, + "shuffle": () => shuffle, + "size": () => size, + "some": () => some, + "sortBy": () => sortBy, + "sortedIndex": () => sortedIndex, + "tail": () => rest, + "take": () => first, + "tap": () => tap, + "template": () => template, + "templateSettings": () => templateSettings, + "throttle": () => throttle, + "times": () => times, + "toArray": () => toArray, + "toPath": () => toPath, + "transpose": () => unzip, + "unescape": () => modules_unescape, + "union": () => union, + "uniq": () => uniq, + "unique": () => uniq, + "uniqueId": () => uniqueId, + "unzip": () => unzip, + "values": () => values, + "where": () => where, + "without": () => without, + "wrap": () => wrap, + "zip": () => zip +}); - if (typeof process === "object" && "version" in process) { - return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_setup.js +// Current version. +var VERSION = '1.13.6'; - return ""; -} +// Establish the root object, `window` (`self`) in the browser, `global` +// on the server, or `this` in some virtual machines. We use `self` +// instead of `window` for `WebWorker` support. +var root = (typeof self == 'object' && self.self === self && self) || + (typeof global == 'object' && global.global === global && global) || + Function('return this')() || + {}; -exports.getUserAgent = getUserAgent; -//# sourceMappingURL=index.js.map +// Save bytes in the minified (but not gzipped) version: +var ArrayProto = Array.prototype, ObjProto = Object.prototype; +var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// Create quick reference variables for speed access to core prototypes. +var push = ArrayProto.push, + slice = ArrayProto.slice, + _setup_toString = ObjProto.toString, + _setup_hasOwnProperty = ObjProto.hasOwnProperty; -/***/ }), +// Modern feature detection. +var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', + supportsDataView = typeof DataView !== 'undefined'; -/***/ 9521: -/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { +// All **ECMAScript 5+** native function implementations that we hope to use +// are declared here. +var nativeIsArray = Array.isArray, + nativeKeys = Object.keys, + nativeCreate = Object.create, + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; -"use strict"; -// ESM COMPAT FLAG -__nccwpck_require__.r(__webpack_exports__); +// Create references to these builtin functions because we override them. +var _isNaN = isNaN, + _isFinite = isFinite; -// EXPORTS -__nccwpck_require__.d(__webpack_exports__, { - "NIL": () => /* reexport */ nil, - "parse": () => /* reexport */ esm_node_parse, - "stringify": () => /* reexport */ esm_node_stringify, - "v1": () => /* reexport */ esm_node_v1, - "v3": () => /* reexport */ esm_node_v3, - "v4": () => /* reexport */ esm_node_v4, - "v5": () => /* reexport */ esm_node_v5, - "validate": () => /* reexport */ esm_node_validate, - "version": () => /* reexport */ esm_node_version -}); +// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. +var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); +var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', + 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; -// CONCATENATED MODULE: external "crypto" -const external_crypto_namespaceObject = require("crypto");; -var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); +// The largest integer that can be represented exactly. +var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/restArguments.js +// Some functions take a variable number of arguments, or a few expected +// arguments at the beginning and then a variable number of values to operate +// on. This helper accumulates all remaining arguments past the function’s +// argument length (or an explicit `startIndex`), into an array that becomes +// the last argument. Similar to ES6’s "rest parameter". +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), + rest = Array(length), + index = 0; + for (; index < length; index++) { + rest[index] = arguments[index + startIndex]; + } + switch (startIndex) { + case 0: return func.call(this, rest); + case 1: return func.call(this, arguments[0], rest); + case 2: return func.call(this, arguments[0], arguments[1], rest); + } + var args = Array(startIndex + 1); + for (index = 0; index < startIndex; index++) { + args[index] = arguments[index]; + } + args[startIndex] = rest; + return func.apply(this, args); + }; +} -const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate +// CONCATENATED MODULE: ./node_modules/underscore/modules/isObject.js +// Is a given variable an object? +function isObject(obj) { + var type = typeof obj; + return type === 'function' || (type === 'object' && !!obj); +} -let poolPtr = rnds8Pool.length; -function rng() { - if (poolPtr > rnds8Pool.length - 16) { - external_crypto_default().randomFillSync(rnds8Pool); - poolPtr = 0; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNull.js +// Is a given value equal to null? +function isNull(obj) { + return obj === null; +} - return rnds8Pool.slice(poolPtr, poolPtr += 16); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isUndefined.js +// Is a given variable undefined? +function isUndefined(obj) { + return obj === void 0; } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js -/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isBoolean.js -function validate(uuid) { - return typeof uuid === 'string' && regex.test(uuid); + +// Is a given value a boolean? +function isBoolean(obj) { + return obj === true || obj === false || _setup_toString.call(obj) === '[object Boolean]'; } -/* harmony default export */ const esm_node_validate = (validate); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isElement.js +// Is a given value a DOM element? +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} -/** - * Convert array of 16 byte values to UUID string format of the form: - * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX - */ +// CONCATENATED MODULE: ./node_modules/underscore/modules/_tagTester.js -const byteToHex = []; -for (let i = 0; i < 256; ++i) { - byteToHex.push((i + 0x100).toString(16).substr(1)); +// Internal function for creating a `toString`-based type tester. +function tagTester(name) { + var tag = '[object ' + name + ']'; + return function(obj) { + return _setup_toString.call(obj) === tag; + }; } -function stringify(arr, offset = 0) { - // Note: Be careful editing this code! It's been tuned for performance - // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 - const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one - // of the following: - // - One or more input array values don't map to a hex octet (leading to - // "undefined" in the uuid) - // - Invalid input values for the RFC `version` or `variant` fields +// CONCATENATED MODULE: ./node_modules/underscore/modules/isString.js - if (!esm_node_validate(uuid)) { - throw TypeError('Stringified UUID is invalid'); - } - return uuid; -} +/* harmony default export */ const isString = (tagTester('String')); -/* harmony default export */ const esm_node_stringify = (stringify); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNumber.js - // **`v1()` - Generate time-based UUID** -// -// Inspired by https://github.com/LiosK/UUID.js -// and http://docs.python.org/library/uuid.html -let _nodeId; +/* harmony default export */ const isNumber = (tagTester('Number')); -let _clockseq; // Previous uuid creation time +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDate.js -let _lastMSecs = 0; -let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details +/* harmony default export */ const isDate = (tagTester('Date')); -function v1(options, buf, offset) { - let i = buf && offset || 0; - const b = buf || new Array(16); - options = options || {}; - let node = options.node || _nodeId; - let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not - // specified. We do this lazily to minimize issues related to insufficient - // system entropy. See #189 +// CONCATENATED MODULE: ./node_modules/underscore/modules/isRegExp.js - if (node == null || clockseq == null) { - const seedBytes = options.random || (options.rng || rng)(); - if (node == null) { - // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) - node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; - } +/* harmony default export */ const isRegExp = (tagTester('RegExp')); - if (clockseq == null) { - // Per 4.2.2, randomize (14 bit) clockseq - clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; - } - } // UUID timestamps are 100 nano-second units since the Gregorian epoch, - // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so - // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' - // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. +// CONCATENATED MODULE: ./node_modules/underscore/modules/isError.js - let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock - // cycle to simulate higher resolution clock +/* harmony default export */ const isError = (tagTester('Error')); - let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSymbol.js - const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression - if (dt < 0 && options.clockseq === undefined) { - clockseq = clockseq + 1 & 0x3fff; - } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new - // time interval +/* harmony default export */ const isSymbol = (tagTester('Symbol')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArrayBuffer.js - if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { - nsecs = 0; - } // Per 4.2.1.2 Throw error if too many uuids are requested +/* harmony default export */ const isArrayBuffer = (tagTester('ArrayBuffer')); - if (nsecs >= 10000) { - throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFunction.js - _lastMSecs = msecs; - _lastNSecs = nsecs; - _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch - msecs += 12219292800000; // `time_low` - const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; - b[i++] = tl >>> 24 & 0xff; - b[i++] = tl >>> 16 & 0xff; - b[i++] = tl >>> 8 & 0xff; - b[i++] = tl & 0xff; // `time_mid` +var isFunction = tagTester('Function'); - const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; - b[i++] = tmh >>> 8 & 0xff; - b[i++] = tmh & 0xff; // `time_high_and_version` +// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old +// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). +var nodelist = root.document && root.document.childNodes; +if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { + isFunction = function(obj) { + return typeof obj == 'function' || false; + }; +} - b[i++] = tmh >>> 24 & 0xf | 0x10; // include version +/* harmony default export */ const modules_isFunction = (isFunction); - b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) +// CONCATENATED MODULE: ./node_modules/underscore/modules/_hasObjectTag.js - b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` - b[i++] = clockseq & 0xff; // `node` +/* harmony default export */ const _hasObjectTag = (tagTester('Object')); - for (let n = 0; n < 6; ++n) { - b[i + n] = node[n]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_stringTagBug.js - return buf || esm_node_stringify(b); -} -/* harmony default export */ const esm_node_v1 = (v1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js +// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. +// In IE 11, the most common among them, this problem also applies to +// `Map`, `WeakMap` and `Set`. +var hasStringTagBug = ( + supportsDataView && _hasObjectTag(new DataView(new ArrayBuffer(8))) + ), + isIE11 = (typeof Map !== 'undefined' && _hasObjectTag(new Map)); -function parse(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isDataView.js - let v; - const arr = new Uint8Array(16); // Parse ########-....-....-....-............ - arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; - arr[1] = v >>> 16 & 0xff; - arr[2] = v >>> 8 & 0xff; - arr[3] = v & 0xff; // Parse ........-####-....-....-............ - arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; - arr[5] = v & 0xff; // Parse ........-....-####-....-............ - arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; - arr[7] = v & 0xff; // Parse ........-....-....-####-............ - arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; - arr[9] = v & 0xff; // Parse ........-....-....-....-############ - // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) +var isDataView = tagTester('DataView'); - arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; - arr[11] = v / 0x100000000 & 0xff; - arr[12] = v >>> 24 & 0xff; - arr[13] = v >>> 16 & 0xff; - arr[14] = v >>> 8 & 0xff; - arr[15] = v & 0xff; - return arr; +// In IE 10 - Edge 13, we need a different heuristic +// to determine whether an object is a `DataView`. +function ie10IsDataView(obj) { + return obj != null && modules_isFunction(obj.getInt8) && isArrayBuffer(obj.buffer); } -/* harmony default export */ const esm_node_parse = (parse); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js +/* harmony default export */ const modules_isDataView = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArray.js -function stringToBytes(str) { - str = unescape(encodeURIComponent(str)); // UTF8 escape - const bytes = []; +// Is a given value an array? +// Delegates to ECMA5's native `Array.isArray`. +/* harmony default export */ const isArray = (nativeIsArray || tagTester('Array')); - for (let i = 0; i < str.length; ++i) { - bytes.push(str.charCodeAt(i)); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_has.js - return bytes; + +// Internal function to check whether `key` is an own property name of `obj`. +function has(obj, key) { + return obj != null && _setup_hasOwnProperty.call(obj, key); } -const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; -const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; -/* harmony default export */ function v35(name, version, hashfunc) { - function generateUUID(value, namespace, buf, offset) { - if (typeof value === 'string') { - value = stringToBytes(value); - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isArguments.js - if (typeof namespace === 'string') { - namespace = esm_node_parse(namespace); - } - if (namespace.length !== 16) { - throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); - } // Compute hash of namespace and value, Per 4.3 - // Future: Use spread syntax when supported on all platforms, e.g. `bytes = - // hashfunc([...namespace, ... value])` +var isArguments = tagTester('Arguments'); - let bytes = new Uint8Array(16 + value.length); - bytes.set(namespace); - bytes.set(value, namespace.length); - bytes = hashfunc(bytes); - bytes[6] = bytes[6] & 0x0f | version; - bytes[8] = bytes[8] & 0x3f | 0x80; +// Define a fallback version of the method in browsers (ahem, IE < 9), where +// there isn't any inspectable "Arguments" type. +(function() { + if (!isArguments(arguments)) { + isArguments = function(obj) { + return has(obj, 'callee'); + }; + } +}()); - if (buf) { - offset = offset || 0; +/* harmony default export */ const modules_isArguments = (isArguments); - for (let i = 0; i < 16; ++i) { - buf[offset + i] = bytes[i]; - } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isFinite.js - return buf; - } - return esm_node_stringify(bytes); - } // Function#name is not settable on some platforms (#270) +// Is a given object a finite number? +function isFinite_isFinite(obj) { + return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} - try { - generateUUID.name = name; // eslint-disable-next-line no-empty - } catch (err) {} // For CommonJS default export support +// CONCATENATED MODULE: ./node_modules/underscore/modules/isNaN.js - generateUUID.DNS = DNS; - generateUUID.URL = URL; - return generateUUID; + +// Is the given value `NaN`? +function isNaN_isNaN(obj) { + return isNumber(obj) && _isNaN(obj); } -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/constant.js +// Predicate-generating function. Often useful outside of Underscore. +function constant(value) { + return function() { + return value; + }; +} -function md5(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createSizePropertyCheck.js + + +// Common internal logic for `isArrayLike` and `isBufferLike`. +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; } +} - return external_crypto_default().createHash('md5').update(bytes).digest(); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_shallowProperty.js +// Internal helper to generate a function to obtain property `key` from `obj`. +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; } -/* harmony default export */ const esm_node_md5 = (md5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getByteLength.js -const v3 = v35('v3', 0x30, esm_node_md5); -/* harmony default export */ const esm_node_v3 = (v3); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js +// Internal helper to obtain the `byteLength` property of an object. +/* harmony default export */ const _getByteLength = (shallowProperty('byteLength')); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isBufferLike.js -function v4(options, buf, offset) { - options = options || {}; - const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - rnds[6] = rnds[6] & 0x0f | 0x40; - rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided +// Internal helper to determine whether we should spend extensive checks against +// `ArrayBuffer` et al. +/* harmony default export */ const _isBufferLike = (createSizePropertyCheck(_getByteLength)); - if (buf) { - offset = offset || 0; +// CONCATENATED MODULE: ./node_modules/underscore/modules/isTypedArray.js - for (let i = 0; i < 16; ++i) { - buf[offset + i] = rnds[i]; - } - return buf; - } - return esm_node_stringify(rnds); -} -/* harmony default export */ const esm_node_v4 = (v4); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js +// Is a given value a typed array? +var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; +function isTypedArray(obj) { + // `ArrayBuffer.isView` is the most future-proof, so use it when available. + // Otherwise, fall back on the above regular expression. + return nativeIsView ? (nativeIsView(obj) && !modules_isDataView(obj)) : + _isBufferLike(obj) && typedArrayPattern.test(_setup_toString.call(obj)); +} -function sha1(bytes) { - if (Array.isArray(bytes)) { - bytes = Buffer.from(bytes); - } else if (typeof bytes === 'string') { - bytes = Buffer.from(bytes, 'utf8'); - } +/* harmony default export */ const modules_isTypedArray = (supportsArrayBuffer ? isTypedArray : constant(false)); - return external_crypto_default().createHash('sha1').update(bytes).digest(); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/_getLength.js -/* harmony default export */ const esm_node_sha1 = (sha1); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js +// Internal helper to obtain the `length` property of an object. +/* harmony default export */ const _getLength = (shallowProperty('length')); -const v5 = v35('v5', 0x50, esm_node_sha1); -/* harmony default export */ const esm_node_v5 = (v5); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js -/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js +// CONCATENATED MODULE: ./node_modules/underscore/modules/_collectNonEnumProps.js -function version(uuid) { - if (!esm_node_validate(uuid)) { - throw TypeError('Invalid UUID'); - } - return parseInt(uuid.substr(14, 1), 16); -} -/* harmony default export */ const esm_node_version = (version); -// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js +// Internal helper to create a simple lookup structure. +// `collectNonEnumProps` used to depend on `_.contains`, but this led to +// circular imports. `emulatedSet` is a one-off solution that only works for +// arrays of strings. +function emulatedSet(keys) { + var hash = {}; + for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; + return { + contains: function(key) { return hash[key] === true; }, + push: function(key) { + hash[key] = true; + return keys.push(key); + } + }; +} +// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't +// be iterated by `for key in ...` and thus missed. Extends `keys` in place if +// needed. +function collectNonEnumProps(obj, keys) { + keys = emulatedSet(keys); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = (modules_isFunction(constructor) && constructor.prototype) || ObjProto; + // Constructor is a special case. + var prop = 'constructor'; + if (has(obj, prop) && !keys.contains(prop)) keys.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { + keys.push(prop); + } + } +} +// CONCATENATED MODULE: ./node_modules/underscore/modules/keys.js +// Retrieve the names of an object's own properties. +// Delegates to **ECMAScript 5**'s native `Object.keys`. +function keys(obj) { + if (!isObject(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys = []; + for (var key in obj) if (has(obj, key)) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; +} -/***/ }), +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEmpty.js -/***/ 2940: -/***/ ((module) => { -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] - }) - return wrapper - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) - } - return ret - } +// Is a given array, string, or object empty? +// An "empty" object has no enumerable own-properties. +function isEmpty(obj) { + if (obj == null) return true; + // Skip the more expensive `toString`-based type checks if `obj` has no + // `.length`. + var length = _getLength(obj); + if (typeof length == 'number' && ( + isArray(obj) || isString(obj) || modules_isArguments(obj) + )) return length === 0; + return _getLength(keys(obj)) === 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMatch.js -/***/ }), -/***/ 1641: -/***/ ((__unused_webpack_module, exports) => { +// Returns whether an object has a given set of `key:value` pairs. +function isMatch(object, attrs) { + var _keys = keys(attrs), length = _keys.length; + if (object == null) return !length; + var obj = Object(object); + for (var i = 0; i < length; i++) { + var key = _keys[i]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore.js -Object.defineProperty(exports, "__esModule", ({ value: true })); - -// Current version. -var VERSION = '1.13.4'; - -// Establish the root object, `window` (`self`) in the browser, `global` -// on the server, or `this` in some virtual machines. We use `self` -// instead of `window` for `WebWorker` support. -var root = (typeof self == 'object' && self.self === self && self) || - (typeof global == 'object' && global.global === global && global) || - Function('return this')() || - {}; -// Save bytes in the minified (but not gzipped) version: -var ArrayProto = Array.prototype, ObjProto = Object.prototype; -var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null; +// If Underscore is called as a function, it returns a wrapped object that can +// be used OO-style. This wrapper holds altered versions of all functions added +// through `_.mixin`. Wrapped objects may be chained. +function _(obj) { + if (obj instanceof _) return obj; + if (!(this instanceof _)) return new _(obj); + this._wrapped = obj; +} -// Create quick reference variables for speed access to core prototypes. -var push = ArrayProto.push, - slice = ArrayProto.slice, - toString = ObjProto.toString, - hasOwnProperty = ObjProto.hasOwnProperty; +_.VERSION = VERSION; -// Modern feature detection. -var supportsArrayBuffer = typeof ArrayBuffer !== 'undefined', - supportsDataView = typeof DataView !== 'undefined'; +// Extracts the result from a wrapped and chained object. +_.prototype.value = function() { + return this._wrapped; +}; -// All **ECMAScript 5+** native function implementations that we hope to use -// are declared here. -var nativeIsArray = Array.isArray, - nativeKeys = Object.keys, - nativeCreate = Object.create, - nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; +// Provide unwrapping proxies for some methods used in engine operations +// such as arithmetic and JSON stringification. +_.prototype.valueOf = _.prototype.toJSON = _.prototype.value; -// Create references to these builtin functions because we override them. -var _isNaN = isNaN, - _isFinite = isFinite; +_.prototype.toString = function() { + return String(this._wrapped); +}; -// Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed. -var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString'); -var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString', - 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toBufferView.js -// The largest integer that can be represented exactly. -var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; -// Some functions take a variable number of arguments, or a few expected -// arguments at the beginning and then a variable number of values to operate -// on. This helper accumulates all remaining arguments past the function’s -// argument length (or an explicit `startIndex`), into an array that becomes -// the last argument. Similar to ES6’s "rest parameter". -function restArguments(func, startIndex) { - startIndex = startIndex == null ? func.length - 1 : +startIndex; - return function() { - var length = Math.max(arguments.length - startIndex, 0), - rest = Array(length), - index = 0; - for (; index < length; index++) { - rest[index] = arguments[index + startIndex]; - } - switch (startIndex) { - case 0: return func.call(this, rest); - case 1: return func.call(this, arguments[0], rest); - case 2: return func.call(this, arguments[0], arguments[1], rest); - } - var args = Array(startIndex + 1); - for (index = 0; index < startIndex; index++) { - args[index] = arguments[index]; - } - args[startIndex] = rest; - return func.apply(this, args); - }; +// Internal function to wrap or shallow-copy an ArrayBuffer, +// typed array or DataView to a new view, reusing the buffer. +function toBufferView(bufferSource) { + return new Uint8Array( + bufferSource.buffer || bufferSource, + bufferSource.byteOffset || 0, + _getByteLength(bufferSource) + ); } -// Is a given variable an object? -function isObject(obj) { - var type = typeof obj; - return type === 'function' || (type === 'object' && !!obj); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/isEqual.js -// Is a given value equal to null? -function isNull(obj) { - return obj === null; -} -// Is a given variable undefined? -function isUndefined(obj) { - return obj === void 0; -} -// Is a given value a boolean? -function isBoolean(obj) { - return obj === true || obj === false || toString.call(obj) === '[object Boolean]'; -} -// Is a given value a DOM element? -function isElement(obj) { - return !!(obj && obj.nodeType === 1); -} -// Internal function for creating a `toString`-based type tester. -function tagTester(name) { - var tag = '[object ' + name + ']'; - return function(obj) { - return toString.call(obj) === tag; - }; -} -var isString = tagTester('String'); -var isNumber = tagTester('Number'); -var isDate = tagTester('Date'); -var isRegExp = tagTester('RegExp'); -var isError = tagTester('Error'); -var isSymbol = tagTester('Symbol'); +// We use this string twice, so give it a name for minification. +var tagDataView = '[object DataView]'; -var isArrayBuffer = tagTester('ArrayBuffer'); +// Internal recursive comparison function for `_.isEqual`. +function eq(a, b, aStack, bStack) { + // Identical objects are equal. `0 === -0`, but they aren't identical. + // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). + if (a === b) return a !== 0 || 1 / a === 1 / b; + // `null` or `undefined` only equal to itself (strict comparison). + if (a == null || b == null) return false; + // `NaN`s are equivalent, but non-reflexive. + if (a !== a) return b !== b; + // Exhaust primitive checks + var type = typeof a; + if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; + return deepEq(a, b, aStack, bStack); +} -var isFunction = tagTester('Function'); +// Internal recursive comparison function for `_.isEqual`. +function deepEq(a, b, aStack, bStack) { + // Unwrap any wrapped objects. + if (a instanceof _) a = a._wrapped; + if (b instanceof _) b = b._wrapped; + // Compare `[[Class]]` names. + var className = _setup_toString.call(a); + if (className !== _setup_toString.call(b)) return false; + // Work around a bug in IE 10 - Edge 13. + if (hasStringTagBug && className == '[object Object]' && modules_isDataView(a)) { + if (!modules_isDataView(b)) return false; + className = tagDataView; + } + switch (className) { + // These types are compared by value. + case '[object RegExp]': + // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') + case '[object String]': + // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is + // equivalent to `new String("5")`. + return '' + a === '' + b; + case '[object Number]': + // `NaN`s are equivalent, but non-reflexive. + // Object(NaN) is equivalent to NaN. + if (+a !== +a) return +b !== +b; + // An `egal` comparison is performed for other numeric values. + return +a === 0 ? 1 / +a === 1 / b : +a === +b; + case '[object Date]': + case '[object Boolean]': + // Coerce dates and booleans to numeric primitive values. Dates are compared by their + // millisecond representations. Note that invalid dates with millisecond representations + // of `NaN` are not equivalent. + return +a === +b; + case '[object Symbol]': + return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); + case '[object ArrayBuffer]': + case tagDataView: + // Coerce to typed array so we can fall through. + return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); + } -// Optimize `isFunction` if appropriate. Work around some `typeof` bugs in old -// v8, IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236). -var nodelist = root.document && root.document.childNodes; -if ( true && typeof Int8Array != 'object' && typeof nodelist != 'function') { - isFunction = function(obj) { - return typeof obj == 'function' || false; - }; -} + var areArrays = className === '[object Array]'; + if (!areArrays && modules_isTypedArray(a)) { + var byteLength = _getByteLength(a); + if (byteLength !== _getByteLength(b)) return false; + if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != 'object' || typeof b != 'object') return false; -var isFunction$1 = isFunction; + // Objects with different constructors are not equivalent, but `Object`s or `Array`s + // from different frames are. + var aCtor = a.constructor, bCtor = b.constructor; + if (aCtor !== bCtor && !(modules_isFunction(aCtor) && aCtor instanceof aCtor && + modules_isFunction(bCtor) && bCtor instanceof bCtor) + && ('constructor' in a && 'constructor' in b)) { + return false; + } + } + // Assume equality for cyclic structures. The algorithm for detecting cyclic + // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. -var hasObjectTag = tagTester('Object'); + // Initializing stack of traversed objects. + // It's done here since we only need them for objects and arrays comparison. + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) { + // Linear search. Performance is inversely proportional to the number of + // unique nested structures. + if (aStack[length] === a) return bStack[length] === b; + } -// In IE 10 - Edge 13, `DataView` has string tag `'[object Object]'`. -// In IE 11, the most common among them, this problem also applies to -// `Map`, `WeakMap` and `Set`. -var hasStringTagBug = ( - supportsDataView && hasObjectTag(new DataView(new ArrayBuffer(8))) - ), - isIE11 = (typeof Map !== 'undefined' && hasObjectTag(new Map)); + // Add the first object to the stack of traversed objects. + aStack.push(a); + bStack.push(b); -var isDataView = tagTester('DataView'); + // Recursively compare objects and arrays. + if (areArrays) { + // Compare array lengths to determine if a deep comparison is necessary. + length = a.length; + if (length !== b.length) return false; + // Deep compare the contents, ignoring non-numeric properties. + while (length--) { + if (!eq(a[length], b[length], aStack, bStack)) return false; + } + } else { + // Deep compare objects. + var _keys = keys(a), key; + length = _keys.length; + // Ensure that both objects contain the same number of properties before comparing deep equality. + if (keys(b).length !== length) return false; + while (length--) { + // Deep compare each member + key = _keys[length]; + if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false; + } + } + // Remove the first object from the stack of traversed objects. + aStack.pop(); + bStack.pop(); + return true; +} -// In IE 10 - Edge 13, we need a different heuristic -// to determine whether an object is a `DataView`. -function ie10IsDataView(obj) { - return obj != null && isFunction$1(obj.getInt8) && isArrayBuffer(obj.buffer); +// Perform a deep comparison to check if two objects are equal. +function isEqual(a, b) { + return eq(a, b); } -var isDataView$1 = (hasStringTagBug ? ie10IsDataView : isDataView); +// CONCATENATED MODULE: ./node_modules/underscore/modules/allKeys.js -// Is a given value an array? -// Delegates to ECMA5's native `Array.isArray`. -var isArray = nativeIsArray || tagTester('Array'); -// Internal function to check whether `key` is an own property name of `obj`. -function has$1(obj, key) { - return obj != null && hasOwnProperty.call(obj, key); + + +// Retrieve all the enumerable property names of an object. +function allKeys(obj) { + if (!isObject(obj)) return []; + var keys = []; + for (var key in obj) keys.push(key); + // Ahem, IE < 9. + if (hasEnumBug) collectNonEnumProps(obj, keys); + return keys; } -var isArguments = tagTester('Arguments'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/_methodFingerprint.js -// Define a fallback version of the method in browsers (ahem, IE < 9), where -// there isn't any inspectable "Arguments" type. -(function() { - if (!isArguments(arguments)) { - isArguments = function(obj) { - return has$1(obj, 'callee'); - }; - } -}()); -var isArguments$1 = isArguments; -// Is a given object a finite number? -function isFinite$1(obj) { - return !isSymbol(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); -} -// Is the given value `NaN`? -function isNaN$1(obj) { - return isNumber(obj) && _isNaN(obj); -} - -// Predicate-generating function. Often useful outside of Underscore. -function constant(value) { - return function() { - return value; +// Since the regular `Object.prototype.toString` type tests don't work for +// some types in IE 11, we use a fingerprinting heuristic instead, based +// on the methods. It's not great, but it's the best we got. +// The fingerprint method lists are defined below. +function ie11fingerprint(methods) { + var length = _getLength(methods); + return function(obj) { + if (obj == null) return false; + // `Map`, `WeakMap` and `Set` have no enumerable keys. + var keys = allKeys(obj); + if (_getLength(keys)) return false; + for (var i = 0; i < length; i++) { + if (!modules_isFunction(obj[methods[i]])) return false; + } + // If we are testing against `WeakMap`, we need to ensure that + // `obj` doesn't have a `forEach` method in order to distinguish + // it from a regular `Map`. + return methods !== weakMapMethods || !modules_isFunction(obj[forEachName]); }; } -// Common internal logic for `isArrayLike` and `isBufferLike`. -function createSizePropertyCheck(getSizeProperty) { - return function(collection) { - var sizeProperty = getSizeProperty(collection); - return typeof sizeProperty == 'number' && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; +// In the interest of compact minification, we write +// each string in the fingerprints only once. +var forEachName = 'forEach', + hasName = 'has', + commonInit = ['clear', 'delete'], + mapTail = ['get', hasName, 'set']; + +// `Map`, `WeakMap` and `Set` each have slightly different +// combinations of the above sublists. +var mapMethods = commonInit.concat(forEachName, mapTail), + weakMapMethods = commonInit.concat(mapTail), + setMethods = ['add'].concat(commonInit, forEachName, hasName); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isMap.js + + + + +/* harmony default export */ const isMap = (isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakMap.js + + + + +/* harmony default export */ const isWeakMap = (isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isSet.js + + + + +/* harmony default export */ const isSet = (isIE11 ? ie11fingerprint(setMethods) : tagTester('Set')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/isWeakSet.js + + +/* harmony default export */ const isWeakSet = (tagTester('WeakSet')); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/values.js + + +// Retrieve the values of an object's properties. +function values(obj) { + var _keys = keys(obj); + var length = _keys.length; + var values = Array(length); + for (var i = 0; i < length; i++) { + values[i] = obj[_keys[i]]; } + return values; } -// Internal helper to generate a function to obtain property `key` from `obj`. -function shallowProperty(key) { - return function(obj) { - return obj == null ? void 0 : obj[key]; - }; +// CONCATENATED MODULE: ./node_modules/underscore/modules/pairs.js + + +// Convert an object into a list of `[key, value]` pairs. +// The opposite of `_.object` with one argument. +function pairs(obj) { + var _keys = keys(obj); + var length = _keys.length; + var pairs = Array(length); + for (var i = 0; i < length; i++) { + pairs[i] = [_keys[i], obj[_keys[i]]]; + } + return pairs; } -// Internal helper to obtain the `byteLength` property of an object. -var getByteLength = shallowProperty('byteLength'); +// CONCATENATED MODULE: ./node_modules/underscore/modules/invert.js -// Internal helper to determine whether we should spend extensive checks against -// `ArrayBuffer` et al. -var isBufferLike = createSizePropertyCheck(getByteLength); -// Is a given value a typed array? -var typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; -function isTypedArray(obj) { - // `ArrayBuffer.isView` is the most future-proof, so use it when available. - // Otherwise, fall back on the above regular expression. - return nativeIsView ? (nativeIsView(obj) && !isDataView$1(obj)) : - isBufferLike(obj) && typedArrayPattern.test(toString.call(obj)); +// Invert the keys and values of an object. The values must be serializable. +function invert(obj) { + var result = {}; + var _keys = keys(obj); + for (var i = 0, length = _keys.length; i < length; i++) { + result[obj[_keys[i]]] = _keys[i]; + } + return result; } -var isTypedArray$1 = supportsArrayBuffer ? isTypedArray : constant(false); +// CONCATENATED MODULE: ./node_modules/underscore/modules/functions.js -// Internal helper to obtain the `length` property of an object. -var getLength = shallowProperty('length'); -// Internal helper to create a simple lookup structure. -// `collectNonEnumProps` used to depend on `_.contains`, but this led to -// circular imports. `emulatedSet` is a one-off solution that only works for -// arrays of strings. -function emulatedSet(keys) { - var hash = {}; - for (var l = keys.length, i = 0; i < l; ++i) hash[keys[i]] = true; - return { - contains: function(key) { return hash[key] === true; }, - push: function(key) { - hash[key] = true; - return keys.push(key); +// Return a sorted list of the function names available on the object. +function functions(obj) { + var names = []; + for (var key in obj) { + if (modules_isFunction(obj[key])) names.push(key); + } + return names.sort(); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createAssigner.js +// An internal function for creating assigner functions. +function createAssigner(keysFunc, defaults) { + return function(obj) { + var length = arguments.length; + if (defaults) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index = 1; index < length; index++) { + var source = arguments[index], + keys = keysFunc(source), + l = keys.length; + for (var i = 0; i < l; i++) { + var key = keys[i]; + if (!defaults || obj[key] === void 0) obj[key] = source[key]; + } } + return obj; }; } -// Internal helper. Checks `keys` for the presence of keys in IE < 9 that won't -// be iterated by `for key in ...` and thus missed. Extends `keys` in place if -// needed. -function collectNonEnumProps(obj, keys) { - keys = emulatedSet(keys); - var nonEnumIdx = nonEnumerableProps.length; - var constructor = obj.constructor; - var proto = (isFunction$1(constructor) && constructor.prototype) || ObjProto; +// CONCATENATED MODULE: ./node_modules/underscore/modules/extend.js - // Constructor is a special case. - var prop = 'constructor'; - if (has$1(obj, prop) && !keys.contains(prop)) keys.push(prop); - while (nonEnumIdx--) { - prop = nonEnumerableProps[nonEnumIdx]; - if (prop in obj && obj[prop] !== proto[prop] && !keys.contains(prop)) { - keys.push(prop); - } - } -} -// Retrieve the names of an object's own properties. -// Delegates to **ECMAScript 5**'s native `Object.keys`. -function keys(obj) { - if (!isObject(obj)) return []; - if (nativeKeys) return nativeKeys(obj); - var keys = []; - for (var key in obj) if (has$1(obj, key)) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} +// Extend a given object with all the properties in passed-in object(s). +/* harmony default export */ const extend = (createAssigner(allKeys)); -// Is a given array, string, or object empty? -// An "empty" object has no enumerable own-properties. -function isEmpty(obj) { - if (obj == null) return true; - // Skip the more expensive `toString`-based type checks if `obj` has no - // `.length`. - var length = getLength(obj); - if (typeof length == 'number' && ( - isArray(obj) || isString(obj) || isArguments$1(obj) - )) return length === 0; - return getLength(keys(obj)) === 0; -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/extendOwn.js -// Returns whether an object has a given set of `key:value` pairs. -function isMatch(object, attrs) { - var _keys = keys(attrs), length = _keys.length; - if (object == null) return !length; - var obj = Object(object); - for (var i = 0; i < length; i++) { - var key = _keys[i]; - if (attrs[key] !== obj[key] || !(key in obj)) return false; - } - return true; -} -// If Underscore is called as a function, it returns a wrapped object that can -// be used OO-style. This wrapper holds altered versions of all functions added -// through `_.mixin`. Wrapped objects may be chained. -function _$1(obj) { - if (obj instanceof _$1) return obj; - if (!(this instanceof _$1)) return new _$1(obj); - this._wrapped = obj; + +// Assigns a given object with all the own properties in the passed-in +// object(s). +// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) +/* harmony default export */ const extendOwn = (createAssigner(keys)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defaults.js + + + +// Fill in a given object with default properties. +/* harmony default export */ const defaults = (createAssigner(allKeys, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseCreate.js + + + +// Create a naked function reference for surrogate-prototype-swapping. +function ctor() { + return function(){}; } -_$1.VERSION = VERSION; +// An internal function for creating a new object that inherits from another. +function baseCreate(prototype) { + if (!isObject(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result = new Ctor; + Ctor.prototype = null; + return result; +} -// Extracts the result from a wrapped and chained object. -_$1.prototype.value = function() { - return this._wrapped; -}; +// CONCATENATED MODULE: ./node_modules/underscore/modules/create.js -// Provide unwrapping proxies for some methods used in engine operations -// such as arithmetic and JSON stringification. -_$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; -_$1.prototype.toString = function() { - return String(this._wrapped); -}; -// Internal function to wrap or shallow-copy an ArrayBuffer, -// typed array or DataView to a new view, reusing the buffer. -function toBufferView(bufferSource) { - return new Uint8Array( - bufferSource.buffer || bufferSource, - bufferSource.byteOffset || 0, - getByteLength(bufferSource) - ); +// Creates an object that inherits from the given prototype object. +// If additional properties are provided then they will be added to the +// created object. +function create(prototype, props) { + var result = baseCreate(prototype); + if (props) extendOwn(result, props); + return result; } -// We use this string twice, so give it a name for minification. -var tagDataView = '[object DataView]'; +// CONCATENATED MODULE: ./node_modules/underscore/modules/clone.js -// Internal recursive comparison function for `_.isEqual`. -function eq(a, b, aStack, bStack) { - // Identical objects are equal. `0 === -0`, but they aren't identical. - // See the [Harmony `egal` proposal](https://wiki.ecmascript.org/doku.php?id=harmony:egal). - if (a === b) return a !== 0 || 1 / a === 1 / b; - // `null` or `undefined` only equal to itself (strict comparison). - if (a == null || b == null) return false; - // `NaN`s are equivalent, but non-reflexive. - if (a !== a) return b !== b; - // Exhaust primitive checks - var type = typeof a; - if (type !== 'function' && type !== 'object' && typeof b != 'object') return false; - return deepEq(a, b, aStack, bStack); -} - -// Internal recursive comparison function for `_.isEqual`. -function deepEq(a, b, aStack, bStack) { - // Unwrap any wrapped objects. - if (a instanceof _$1) a = a._wrapped; - if (b instanceof _$1) b = b._wrapped; - // Compare `[[Class]]` names. - var className = toString.call(a); - if (className !== toString.call(b)) return false; - // Work around a bug in IE 10 - Edge 13. - if (hasStringTagBug && className == '[object Object]' && isDataView$1(a)) { - if (!isDataView$1(b)) return false; - className = tagDataView; - } - switch (className) { - // These types are compared by value. - case '[object RegExp]': - // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i') - case '[object String]': - // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is - // equivalent to `new String("5")`. - return '' + a === '' + b; - case '[object Number]': - // `NaN`s are equivalent, but non-reflexive. - // Object(NaN) is equivalent to NaN. - if (+a !== +a) return +b !== +b; - // An `egal` comparison is performed for other numeric values. - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - // Coerce dates and booleans to numeric primitive values. Dates are compared by their - // millisecond representations. Note that invalid dates with millisecond representations - // of `NaN` are not equivalent. - return +a === +b; - case '[object Symbol]': - return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b); - case '[object ArrayBuffer]': - case tagDataView: - // Coerce to typed array so we can fall through. - return deepEq(toBufferView(a), toBufferView(b), aStack, bStack); - } - - var areArrays = className === '[object Array]'; - if (!areArrays && isTypedArray$1(a)) { - var byteLength = getByteLength(a); - if (byteLength !== getByteLength(b)) return false; - if (a.buffer === b.buffer && a.byteOffset === b.byteOffset) return true; - areArrays = true; - } - if (!areArrays) { - if (typeof a != 'object' || typeof b != 'object') return false; - - // Objects with different constructors are not equivalent, but `Object`s or `Array`s - // from different frames are. - var aCtor = a.constructor, bCtor = b.constructor; - if (aCtor !== bCtor && !(isFunction$1(aCtor) && aCtor instanceof aCtor && - isFunction$1(bCtor) && bCtor instanceof bCtor) - && ('constructor' in a && 'constructor' in b)) { - return false; - } - } - // Assume equality for cyclic structures. The algorithm for detecting cyclic - // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`. - - // Initializing stack of traversed objects. - // It's done here since we only need them for objects and arrays comparison. - aStack = aStack || []; - bStack = bStack || []; - var length = aStack.length; - while (length--) { - // Linear search. Performance is inversely proportional to the number of - // unique nested structures. - if (aStack[length] === a) return bStack[length] === b; - } - - // Add the first object to the stack of traversed objects. - aStack.push(a); - bStack.push(b); - - // Recursively compare objects and arrays. - if (areArrays) { - // Compare array lengths to determine if a deep comparison is necessary. - length = a.length; - if (length !== b.length) return false; - // Deep compare the contents, ignoring non-numeric properties. - while (length--) { - if (!eq(a[length], b[length], aStack, bStack)) return false; - } - } else { - // Deep compare objects. - var _keys = keys(a), key; - length = _keys.length; - // Ensure that both objects contain the same number of properties before comparing deep equality. - if (keys(b).length !== length) return false; - while (length--) { - // Deep compare each member - key = _keys[length]; - if (!(has$1(b, key) && eq(a[key], b[key], aStack, bStack))) return false; - } - } - // Remove the first object from the stack of traversed objects. - aStack.pop(); - bStack.pop(); - return true; -} - -// Perform a deep comparison to check if two objects are equal. -function isEqual(a, b) { - return eq(a, b); -} - -// Retrieve all the enumerable property names of an object. -function allKeys(obj) { - if (!isObject(obj)) return []; - var keys = []; - for (var key in obj) keys.push(key); - // Ahem, IE < 9. - if (hasEnumBug) collectNonEnumProps(obj, keys); - return keys; -} - -// Since the regular `Object.prototype.toString` type tests don't work for -// some types in IE 11, we use a fingerprinting heuristic instead, based -// on the methods. It's not great, but it's the best we got. -// The fingerprint method lists are defined below. -function ie11fingerprint(methods) { - var length = getLength(methods); - return function(obj) { - if (obj == null) return false; - // `Map`, `WeakMap` and `Set` have no enumerable keys. - var keys = allKeys(obj); - if (getLength(keys)) return false; - for (var i = 0; i < length; i++) { - if (!isFunction$1(obj[methods[i]])) return false; - } - // If we are testing against `WeakMap`, we need to ensure that - // `obj` doesn't have a `forEach` method in order to distinguish - // it from a regular `Map`. - return methods !== weakMapMethods || !isFunction$1(obj[forEachName]); - }; -} - -// In the interest of compact minification, we write -// each string in the fingerprints only once. -var forEachName = 'forEach', - hasName = 'has', - commonInit = ['clear', 'delete'], - mapTail = ['get', hasName, 'set']; - -// `Map`, `WeakMap` and `Set` each have slightly different -// combinations of the above sublists. -var mapMethods = commonInit.concat(forEachName, mapTail), - weakMapMethods = commonInit.concat(mapTail), - setMethods = ['add'].concat(commonInit, forEachName, hasName); - -var isMap = isIE11 ? ie11fingerprint(mapMethods) : tagTester('Map'); - -var isWeakMap = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester('WeakMap'); - -var isSet = isIE11 ? ie11fingerprint(setMethods) : tagTester('Set'); - -var isWeakSet = tagTester('WeakSet'); - -// Retrieve the values of an object's properties. -function values(obj) { - var _keys = keys(obj); - var length = _keys.length; - var values = Array(length); - for (var i = 0; i < length; i++) { - values[i] = obj[_keys[i]]; - } - return values; -} - -// Convert an object into a list of `[key, value]` pairs. -// The opposite of `_.object` with one argument. -function pairs(obj) { - var _keys = keys(obj); - var length = _keys.length; - var pairs = Array(length); - for (var i = 0; i < length; i++) { - pairs[i] = [_keys[i], obj[_keys[i]]]; - } - return pairs; -} - -// Invert the keys and values of an object. The values must be serializable. -function invert(obj) { - var result = {}; - var _keys = keys(obj); - for (var i = 0, length = _keys.length; i < length; i++) { - result[obj[_keys[i]]] = _keys[i]; - } - return result; -} - -// Return a sorted list of the function names available on the object. -function functions(obj) { - var names = []; - for (var key in obj) { - if (isFunction$1(obj[key])) names.push(key); - } - return names.sort(); -} - -// An internal function for creating assigner functions. -function createAssigner(keysFunc, defaults) { - return function(obj) { - var length = arguments.length; - if (defaults) obj = Object(obj); - if (length < 2 || obj == null) return obj; - for (var index = 1; index < length; index++) { - var source = arguments[index], - keys = keysFunc(source), - l = keys.length; - for (var i = 0; i < l; i++) { - var key = keys[i]; - if (!defaults || obj[key] === void 0) obj[key] = source[key]; - } - } - return obj; - }; -} - -// Extend a given object with all the properties in passed-in object(s). -var extend = createAssigner(allKeys); - -// Assigns a given object with all the own properties in the passed-in -// object(s). -// (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) -var extendOwn = createAssigner(keys); - -// Fill in a given object with default properties. -var defaults = createAssigner(allKeys, true); - -// Create a naked function reference for surrogate-prototype-swapping. -function ctor() { - return function(){}; -} - -// An internal function for creating a new object that inherits from another. -function baseCreate(prototype) { - if (!isObject(prototype)) return {}; - if (nativeCreate) return nativeCreate(prototype); - var Ctor = ctor(); - Ctor.prototype = prototype; - var result = new Ctor; - Ctor.prototype = null; - return result; -} - -// Creates an object that inherits from the given prototype object. -// If additional properties are provided then they will be added to the -// created object. -function create(prototype, props) { - var result = baseCreate(prototype); - if (props) extendOwn(result, props); - return result; -} - -// Create a (shallow-cloned) duplicate of an object. -function clone(obj) { - if (!isObject(obj)) return obj; - return isArray(obj) ? obj.slice() : extend({}, obj); + + + +// Create a (shallow-cloned) duplicate of an object. +function clone(obj) { + if (!isObject(obj)) return obj; + return isArray(obj) ? obj.slice() : extend({}, obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/tap.js // Invokes `interceptor` with the `obj` and then returns `obj`. // The primary purpose of this method is to "tap into" a method chain, in // order to perform operations on intermediate results within the chain. @@ -17143,19 +17208,28 @@ function tap(obj, interceptor) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toPath.js + + + // Normalize a (deep) property `path` to array. // Like `_.iteratee`, this function can be customized. -function toPath$1(path) { +function toPath(path) { return isArray(path) ? path : [path]; } -_$1.toPath = toPath$1; +_.toPath = toPath; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_toPath.js + + // Internal wrapper for `_.toPath` to enable minification. // Similar to `cb` for `_.iteratee`. -function toPath(path) { - return _$1.toPath(path); +function _toPath_toPath(path) { + return _.toPath(path); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_deepGet.js // Internal function to obtain a nested property in `obj` along `path`. function deepGet(obj, path) { var length = path.length; @@ -17166,34 +17240,48 @@ function deepGet(obj, path) { return length ? obj : void 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/get.js + + + + // Get the value of the (deep) property on `path` from `object`. // If any property in `path` does not exist or if the value is // `undefined`, return `defaultValue` instead. // The `path` is normalized through `_.toPath`. function get(object, path, defaultValue) { - var value = deepGet(object, toPath(path)); + var value = deepGet(object, _toPath_toPath(path)); return isUndefined(value) ? defaultValue : value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/has.js + + + // Shortcut function for checking if an object has a given property directly on // itself (in other words, not on a prototype). Unlike the internal `has` // function, this public version can also traverse nested properties. -function has(obj, path) { - path = toPath(path); +function has_has(obj, path) { + path = _toPath_toPath(path); var length = path.length; for (var i = 0; i < length; i++) { var key = path[i]; - if (!has$1(obj, key)) return false; + if (!has(obj, key)) return false; obj = obj[key]; } return !!length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/identity.js // Keep the identity function around for default iteratees. function identity(value) { return value; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/matcher.js + + + // Returns a predicate for checking whether an object has a given set of // `key:value` pairs. function matcher(attrs) { @@ -17203,15 +17291,20 @@ function matcher(attrs) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/property.js + + + // Creates a function that, when passed an object, will traverse that object’s // properties down the given `path`, specified as an array of keys or indices. function property(path) { - path = toPath(path); + path = _toPath_toPath(path); return function(obj) { return deepGet(obj, path); }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_optimizeCb.js // Internal function that returns an efficient (for current engines) version // of the passed-in callback, to be repeatedly applied in other Underscore // functions. @@ -17234,31 +17327,53 @@ function optimizeCb(func, context, argCount) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_baseIteratee.js + + + + + + + + // An internal function to generate callbacks that can be applied to each // element in a collection, returning the desired result — either `_.identity`, // an arbitrary callback, a property matcher, or a property accessor. function baseIteratee(value, context, argCount) { if (value == null) return identity; - if (isFunction$1(value)) return optimizeCb(value, context, argCount); + if (modules_isFunction(value)) return optimizeCb(value, context, argCount); if (isObject(value) && !isArray(value)) return matcher(value); return property(value); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/iteratee.js + + + // External wrapper for our callback generator. Users may customize // `_.iteratee` if they want additional predicate/iteratee shorthand styles. // This abstraction hides the internal-only `argCount` argument. function iteratee(value, context) { return baseIteratee(value, context, Infinity); } -_$1.iteratee = iteratee; +_.iteratee = iteratee; + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_cb.js + + + // The function we call internally to generate a callback. It invokes // `_.iteratee` if overridden, otherwise `baseIteratee`. function cb(value, context, argCount) { - if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + if (_.iteratee !== iteratee) return _.iteratee(value, context); return baseIteratee(value, context, argCount); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/mapObject.js + + + // Returns the results of applying the `iteratee` to each element of `obj`. // In contrast to `_.map` it returns an object. function mapObject(obj, iteratee, context) { @@ -17273,9 +17388,14 @@ function mapObject(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/noop.js // Predicate-generating function. Often useful outside of Underscore. function noop(){} +// CONCATENATED MODULE: ./node_modules/underscore/modules/propertyOf.js + + + // Generates a function for a given object that returns a given property. function propertyOf(obj) { if (obj == null) return noop; @@ -17284,6 +17404,9 @@ function propertyOf(obj) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/times.js + + // Run a function **n** times. function times(n, iteratee, context) { var accum = Array(Math.max(0, n)); @@ -17292,6 +17415,7 @@ function times(n, iteratee, context) { return accum; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/random.js // Return a random integer between `min` and `max` (inclusive). function random(min, max) { if (max == null) { @@ -17301,10 +17425,14 @@ function random(min, max) { return min + Math.floor(Math.random() * (max - min + 1)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/now.js // A (possibly faster) way to get the current timestamp as an integer. -var now = Date.now || function() { +/* harmony default export */ const now = (Date.now || function() { return new Date().getTime(); -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createEscaper.js + // Internal helper to generate functions for escaping and unescaping strings // to/from HTML interpolation. @@ -17322,32 +17450,53 @@ function createEscaper(map) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_escapeMap.js // Internal list of HTML entities for escaping. -var escapeMap = { +/* harmony default export */ const _escapeMap = ({ '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`' -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/escape.js + + // Function for escaping strings to HTML interpolation. -var _escape = createEscaper(escapeMap); +/* harmony default export */ const modules_escape = (createEscaper(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_unescapeMap.js + + // Internal list of HTML entities for unescaping. -var unescapeMap = invert(escapeMap); +/* harmony default export */ const _unescapeMap = (invert(_escapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unescape.js + + // Function for unescaping strings from HTML interpolation. -var _unescape = createEscaper(unescapeMap); +/* harmony default export */ const modules_unescape = (createEscaper(_unescapeMap)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/templateSettings.js + // By default, Underscore uses ERB-style template delimiters. Change the // following template settings to use alternative delimiters. -var templateSettings = _$1.templateSettings = { +/* harmony default export */ const templateSettings = (_.templateSettings = { evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g -}; +}); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/template.js + + + // When customizing `_.templateSettings`, if you don't want to define an // interpolation, evaluation or escaping regex, we need one that is @@ -17384,7 +17533,7 @@ var bareIdentifier = /^\s*(\w|\$)+\s*$/; // NB: `oldSettings` only exists for backwards compatibility. function template(text, settings, oldSettings) { if (!settings && oldSettings) settings = oldSettings; - settings = defaults({}, settings, _$1.templateSettings); + settings = defaults({}, settings, _.templateSettings); // Combine delimiters into one regular expression via alternation. var matcher = RegExp([ @@ -17438,7 +17587,7 @@ function template(text, settings, oldSettings) { } var template = function(data) { - return render.call(this, data, _$1); + return render.call(this, data, _); }; // Provide the compiled source as a convenience for precompilation. @@ -17447,14 +17596,18 @@ function template(text, settings, oldSettings) { return template; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/result.js + + + // Traverses the children of `obj` along `path`. If a child is a function, it // is invoked with its parent as context. Returns the value of the final // child, or `fallback` if any child is undefined. function result(obj, path, fallback) { - path = toPath(path); + path = _toPath_toPath(path); var length = path.length; if (!length) { - return isFunction$1(fallback) ? fallback.call(obj) : fallback; + return modules_isFunction(fallback) ? fallback.call(obj) : fallback; } for (var i = 0; i < length; i++) { var prop = obj == null ? void 0 : obj[path[i]]; @@ -17462,11 +17615,12 @@ function result(obj, path, fallback) { prop = fallback; i = length; // Ensure we don't continue iterating. } - obj = isFunction$1(prop) ? prop.call(obj) : prop; + obj = modules_isFunction(prop) ? prop.call(obj) : prop; } return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniqueId.js // Generate a unique integer id (unique within the entire client session). // Useful for temporary DOM ids. var idCounter = 0; @@ -17475,13 +17629,20 @@ function uniqueId(prefix) { return prefix ? prefix + id : id; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/chain.js + + // Start chaining a wrapped Underscore object. function chain(obj) { - var instance = _$1(obj); + var instance = _(obj); instance._chain = true; return instance; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_executeBound.js + + + // Internal function to execute `sourceFunc` bound to `context` with optional // `args`. Determines whether to execute a function as a constructor or as a // normal function. @@ -17493,6 +17654,11 @@ function executeBound(sourceFunc, boundFunc, context, callingContext, args) { return self; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/partial.js + + + + // Partially apply a function by creating a version that has had some of its // arguments pre-filled, without changing its dynamic `this` context. `_` acts // as a placeholder by default, allowing any combination of arguments to be @@ -17511,26 +17677,42 @@ var partial = restArguments(function(func, boundArgs) { return bound; }); -partial.placeholder = _$1; +partial.placeholder = _; +/* harmony default export */ const modules_partial = (partial); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/bind.js + + + // Create a function bound to a given object (assigning `this`, and arguments, // optionally). -var bind = restArguments(function(func, context, args) { - if (!isFunction$1(func)) throw new TypeError('Bind must be called on a function'); +/* harmony default export */ const bind = (restArguments(function(func, context, args) { + if (!modules_isFunction(func)) throw new TypeError('Bind must be called on a function'); var bound = restArguments(function(callArgs) { return executeBound(func, bound, context, this, args.concat(callArgs)); }); return bound; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_isArrayLike.js + + // Internal helper for collection methods to determine whether a collection // should be iterated as an array or as an object. // Related: https://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094 -var isArrayLike = createSizePropertyCheck(getLength); +/* harmony default export */ const _isArrayLike = (createSizePropertyCheck(_getLength)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_flatten.js + + + + // Internal implementation of a recursive `flatten` function. -function flatten$1(input, depth, strict, output) { +function flatten(input, depth, strict, output) { output = output || []; if (!depth && depth !== 0) { depth = Infinity; @@ -17538,12 +17720,12 @@ function flatten$1(input, depth, strict, output) { return output.concat(input); } var idx = output.length; - for (var i = 0, length = getLength(input); i < length; i++) { + for (var i = 0, length = _getLength(input); i < length; i++) { var value = input[i]; - if (isArrayLike(value) && (isArray(value) || isArguments$1(value))) { + if (_isArrayLike(value) && (isArray(value) || modules_isArguments(value))) { // Flatten current level of array or arguments object. if (depth > 1) { - flatten$1(value, depth - 1, strict, output); + flatten(value, depth - 1, strict, output); idx = output.length; } else { var j = 0, len = value.length; @@ -17556,11 +17738,16 @@ function flatten$1(input, depth, strict, output) { return output; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/bindAll.js + + + + // Bind a number of an object's methods to that object. Remaining arguments // are the method names to be bound. Useful for ensuring that all callbacks // defined on an object belong to it. -var bindAll = restArguments(function(obj, keys) { - keys = flatten$1(keys, false, false); +/* harmony default export */ const bindAll = (restArguments(function(obj, keys) { + keys = flatten(keys, false, false); var index = keys.length; if (index < 1) throw new Error('bindAll must be passed function names'); while (index--) { @@ -17568,31 +17755,45 @@ var bindAll = restArguments(function(obj, keys) { obj[key] = bind(obj[key], obj); } return obj; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/memoize.js + // Memoize an expensive function by storing its results. function memoize(func, hasher) { var memoize = function(key) { var cache = memoize.cache; var address = '' + (hasher ? hasher.apply(this, arguments) : key); - if (!has$1(cache, address)) cache[address] = func.apply(this, arguments); + if (!has(cache, address)) cache[address] = func.apply(this, arguments); return cache[address]; }; memoize.cache = {}; return memoize; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/delay.js + + // Delays a function for the given number of milliseconds, and then calls // it with the arguments supplied. -var delay = restArguments(function(func, wait, args) { +/* harmony default export */ const delay = (restArguments(function(func, wait, args) { return setTimeout(function() { return func.apply(null, args); }, wait); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/defer.js + + + // Defers a function, scheduling it to run after the current call stack has // cleared. -var defer = partial(delay, _$1, 1); +/* harmony default export */ const defer = (modules_partial(delay, _, 1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/throttle.js + // Returns a function, that, when invoked, will only be triggered at most once // during a given window of time. Normally, the throttled function will run @@ -17640,6 +17841,10 @@ function throttle(func, wait, options) { return throttled; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/debounce.js + + + // When a sequence of calls of the returned function ends, the argument // function is triggered. The end of a sequence is defined by the `wait` // parameter. If `immediate` is passed, the argument function will be @@ -17678,13 +17883,17 @@ function debounce(func, wait, immediate) { return debounced; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/wrap.js + + // Returns the first function passed as an argument to the second, // allowing you to adjust arguments, run code before and after, and // conditionally execute the original function. function wrap(func, wrapper) { - return partial(wrapper, func); + return modules_partial(wrapper, func); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/negate.js // Returns a negated version of the passed-in predicate. function negate(predicate) { return function() { @@ -17692,6 +17901,7 @@ function negate(predicate) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/compose.js // Returns a function that is the composition of a list of functions, each // consuming the return value of the function that follows. function compose() { @@ -17705,6 +17915,7 @@ function compose() { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/after.js // Returns a function that will only be executed on and after the Nth call. function after(times, func) { return function() { @@ -17714,6 +17925,7 @@ function after(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/before.js // Returns a function that will only be executed up to (but not including) the // Nth call. function before(times, func) { @@ -17727,9 +17939,17 @@ function before(times, func) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/once.js + + + // Returns a function that will be executed at most one time, no matter how // often you call it. Useful for lazy initialization. -var once = partial(before, 2); +/* harmony default export */ const once = (modules_partial(before, 2)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findKey.js + + // Returns the first key on an object that passes a truth test. function findKey(obj, predicate, context) { @@ -17741,11 +17961,15 @@ function findKey(obj, predicate, context) { } } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createPredicateIndexFinder.js + + + // Internal function to generate `_.findIndex` and `_.findLastIndex`. function createPredicateIndexFinder(dir) { return function(array, predicate, context) { predicate = cb(predicate, context); - var length = getLength(array); + var length = _getLength(array); var index = dir > 0 ? 0 : length - 1; for (; index >= 0 && index < length; index += dir) { if (predicate(array[index], index, array)) return index; @@ -17754,18 +17978,28 @@ function createPredicateIndexFinder(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findIndex.js + + // Returns the first index on an array-like that passes a truth test. -var findIndex = createPredicateIndexFinder(1); +/* harmony default export */ const findIndex = (createPredicateIndexFinder(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/findLastIndex.js + // Returns the last index on an array-like that passes a truth test. -var findLastIndex = createPredicateIndexFinder(-1); +/* harmony default export */ const findLastIndex = (createPredicateIndexFinder(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortedIndex.js + + // Use a comparator function to figure out the smallest index at which // an object should be inserted so as to maintain order. Uses binary search. function sortedIndex(array, obj, iteratee, context) { iteratee = cb(iteratee, context, 1); var value = iteratee(obj); - var low = 0, high = getLength(array); + var low = 0, high = _getLength(array); while (low < high) { var mid = Math.floor((low + high) / 2); if (iteratee(array[mid]) < value) low = mid + 1; else high = mid; @@ -17773,10 +18007,15 @@ function sortedIndex(array, obj, iteratee, context) { return low; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createIndexFinder.js + + + + // Internal function to generate the `_.indexOf` and `_.lastIndexOf` functions. function createIndexFinder(dir, predicateFind, sortedIndex) { return function(array, item, idx) { - var i = 0, length = getLength(array); + var i = 0, length = _getLength(array); if (typeof idx == 'number') { if (dir > 0) { i = idx >= 0 ? idx : Math.max(idx + length, i); @@ -17788,7 +18027,7 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { return array[idx] === item ? idx : -1; } if (item !== item) { - idx = predicateFind(slice.call(array, i, length), isNaN$1); + idx = predicateFind(slice.call(array, i, length), isNaN_isNaN); return idx >= 0 ? idx + i : -1; } for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) { @@ -17798,29 +18037,52 @@ function createIndexFinder(dir, predicateFind, sortedIndex) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexOf.js + + + + // Return the position of the first occurrence of an item in an array, // or -1 if the item is not included in the array. // If the array is large and already in sort order, pass `true` // for **isSorted** to use binary search. -var indexOf = createIndexFinder(1, findIndex, sortedIndex); +/* harmony default export */ const indexOf = (createIndexFinder(1, findIndex, sortedIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/lastIndexOf.js + + // Return the position of the last occurrence of an item in an array, // or -1 if the item is not included in the array. -var lastIndexOf = createIndexFinder(-1, findLastIndex); +/* harmony default export */ const lastIndexOf = (createIndexFinder(-1, findLastIndex)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/find.js + + + // Return the first value which passes a truth test. function find(obj, predicate, context) { - var keyFinder = isArrayLike(obj) ? findIndex : findKey; + var keyFinder = _isArrayLike(obj) ? findIndex : findKey; var key = keyFinder(obj, predicate, context); if (key !== void 0 && key !== -1) return obj[key]; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/findWhere.js + + + // Convenience version of a common use case of `_.find`: getting the first // object containing specific `key:value` pairs. function findWhere(obj, attrs) { return find(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/each.js + + + + // The cornerstone for collection functions, an `each` // implementation, aka `forEach`. // Handles raw objects in addition to array-likes. Treats all @@ -17828,7 +18090,7 @@ function findWhere(obj, attrs) { function each(obj, iteratee, context) { iteratee = optimizeCb(iteratee, context); var i, length; - if (isArrayLike(obj)) { + if (_isArrayLike(obj)) { for (i = 0, length = obj.length; i < length; i++) { iteratee(obj[i], i, obj); } @@ -17841,10 +18103,15 @@ function each(obj, iteratee, context) { return obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/map.js + + + + // Return the results of applying the iteratee to each element. function map(obj, iteratee, context) { iteratee = cb(iteratee, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, results = Array(length); for (var index = 0; index < length; index++) { @@ -17854,12 +18121,17 @@ function map(obj, iteratee, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_createReduce.js + + + + // Internal helper to create a reducing function, iterating left or right. function createReduce(dir) { // Wrap code that reassigns argument variables in a separate function than // the one that accesses `arguments.length` to avoid a perf hit. (#1991) var reducer = function(obj, iteratee, memo, initial) { - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length, index = dir > 0 ? 0 : length - 1; if (!initial) { @@ -17879,12 +18151,22 @@ function createReduce(dir) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduce.js + + // **Reduce** builds up a single result from a list of values, aka `inject`, // or `foldl`. -var reduce = createReduce(1); +/* harmony default export */ const reduce = (createReduce(1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/reduceRight.js + // The right-associative version of reduce, also known as `foldr`. -var reduceRight = createReduce(-1); +/* harmony default export */ const reduceRight = (createReduce(-1)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/filter.js + + // Return all the elements that pass a truth test. function filter(obj, predicate, context) { @@ -17896,15 +18178,25 @@ function filter(obj, predicate, context) { return results; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/reject.js + + + + // Return all the elements for which a truth test fails. function reject(obj, predicate, context) { return filter(obj, negate(cb(predicate)), context); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/every.js + + + + // Determine whether all of the elements pass a truth test. function every(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17913,10 +18205,15 @@ function every(obj, predicate, context) { return true; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/some.js + + + + // Determine if at least one element in the object passes a truth test. function some(obj, predicate, context) { predicate = cb(predicate, context); - var _keys = !isArrayLike(obj) && keys(obj), + var _keys = !_isArrayLike(obj) && keys(obj), length = (_keys || obj).length; for (var index = 0; index < length; index++) { var currentKey = _keys ? _keys[index] : index; @@ -17925,20 +18222,32 @@ function some(obj, predicate, context) { return false; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/contains.js + + + + // Determine if the array or object contains a given item (using `===`). function contains(obj, item, fromIndex, guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); if (typeof fromIndex != 'number' || guard) fromIndex = 0; return indexOf(obj, item, fromIndex) >= 0; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/invoke.js + + + + + + // Invoke a method (with arguments) on every item in a collection. -var invoke = restArguments(function(obj, path, args) { +/* harmony default export */ const invoke = (restArguments(function(obj, path, args) { var contextPath, func; - if (isFunction$1(path)) { + if (modules_isFunction(path)) { func = path; } else { - path = toPath(path); + path = _toPath_toPath(path); contextPath = path.slice(0, -1); path = path[path.length - 1]; } @@ -17953,25 +18262,39 @@ var invoke = restArguments(function(obj, path, args) { } return method == null ? method : method.apply(context, args); }); -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/pluck.js + + // Convenience version of a common use case of `_.map`: fetching a property. function pluck(obj, key) { return map(obj, property(key)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/where.js + + + // Convenience version of a common use case of `_.filter`: selecting only // objects containing specific `key:value` pairs. function where(obj, attrs) { return filter(obj, matcher(attrs)); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/max.js + + + + + // Return the maximum element (or element-based computation). function max(obj, iteratee, context) { var result = -Infinity, lastComputed = -Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value > result) { @@ -17991,12 +18314,18 @@ function max(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/min.js + + + + + // Return the minimum element (or element-based computation). function min(obj, iteratee, context) { var result = Infinity, lastComputed = Infinity, value, computed; if (iteratee == null || (typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null)) { - obj = isArrayLike(obj) ? obj : values(obj); + obj = _isArrayLike(obj) ? obj : values(obj); for (var i = 0, length = obj.length; i < length; i++) { value = obj[i]; if (value != null && value < result) { @@ -18016,6 +18345,15 @@ function min(obj, iteratee, context) { return result; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/toArray.js + + + + + + + + // Safely create a real, live array from anything iterable. var reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; function toArray(obj) { @@ -18025,21 +18363,28 @@ function toArray(obj) { // Keep surrogate pair characters together. return obj.match(reStrSymbol); } - if (isArrayLike(obj)) return map(obj, identity); + if (_isArrayLike(obj)) return map(obj, identity); return values(obj); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sample.js + + + + + + // Sample **n** random values from a collection using the modern version of the // [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher–Yates_shuffle). // If **n** is not specified, returns a single random element. // The internal `guard` argument allows it to work with `_.map`. function sample(obj, n, guard) { if (n == null || guard) { - if (!isArrayLike(obj)) obj = values(obj); + if (!_isArrayLike(obj)) obj = values(obj); return obj[random(obj.length - 1)]; } var sample = toArray(obj); - var length = getLength(sample); + var length = _getLength(sample); n = Math.max(Math.min(n, length), 0); var last = length - 1; for (var index = 0; index < n; index++) { @@ -18051,11 +18396,19 @@ function sample(obj, n, guard) { return sample.slice(0, n); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/shuffle.js + + // Shuffle a collection. function shuffle(obj) { return sample(obj, Infinity); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/sortBy.js + + + + // Sort the object's values by a criterion produced by an iteratee. function sortBy(obj, iteratee, context) { var index = 0; @@ -18077,6 +18430,10 @@ function sortBy(obj, iteratee, context) { }), 'value'); } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_group.js + + + // An internal function used for aggregate "group by" operations. function group(behavior, partition) { return function(obj, iteratee, context) { @@ -18090,53 +18447,80 @@ function group(behavior, partition) { }; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/groupBy.js + + + // Groups the object's values by a criterion. Pass either a string attribute // to group by, or a function that returns the criterion. -var groupBy = group(function(result, value, key) { - if (has$1(result, key)) result[key].push(value); else result[key] = [value]; -}); +/* harmony default export */ const groupBy = (group(function(result, value, key) { + if (has(result, key)) result[key].push(value); else result[key] = [value]; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/indexBy.js + // Indexes the object's values by a criterion, similar to `_.groupBy`, but for // when you know that your index values will be unique. -var indexBy = group(function(result, value, key) { +/* harmony default export */ const indexBy = (group(function(result, value, key) { result[key] = value; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/countBy.js + + // Counts instances of an object that group by a certain criterion. Pass // either a string attribute to count by, or a function that returns the // criterion. -var countBy = group(function(result, value, key) { - if (has$1(result, key)) result[key]++; else result[key] = 1; -}); +/* harmony default export */ const countBy = (group(function(result, value, key) { + if (has(result, key)) result[key]++; else result[key] = 1; +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/partition.js + // Split a collection into two arrays: one whose elements all pass the given // truth test, and one whose elements all do not pass the truth test. -var partition = group(function(result, value, pass) { +/* harmony default export */ const partition = (group(function(result, value, pass) { result[pass ? 0 : 1].push(value); -}, true); +}, true)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/size.js + + // Return the number of elements in a collection. function size(obj) { if (obj == null) return 0; - return isArrayLike(obj) ? obj.length : keys(obj).length; + return _isArrayLike(obj) ? obj.length : keys(obj).length; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/_keyInObj.js // Internal `_.pick` helper function to determine whether `key` is an enumerable // property name of `obj`. function keyInObj(value, key, obj) { return key in obj; } +// CONCATENATED MODULE: ./node_modules/underscore/modules/pick.js + + + + + + + // Return a copy of the object only containing the allowed properties. -var pick = restArguments(function(obj, keys) { +/* harmony default export */ const pick = (restArguments(function(obj, keys) { var result = {}, iteratee = keys[0]; if (obj == null) return result; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]); keys = allKeys(obj); } else { iteratee = keyInObj; - keys = flatten$1(keys, false, false); + keys = flatten(keys, false, false); obj = Object(obj); } for (var i = 0, length = keys.length; i < length; i++) { @@ -18145,545 +18529,987 @@ var pick = restArguments(function(obj, keys) { if (iteratee(value, key, obj)) result[key] = value; } return result; -}); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/omit.js + + + + + + + // Return a copy of the object without the disallowed properties. -var omit = restArguments(function(obj, keys) { +/* harmony default export */ const omit = (restArguments(function(obj, keys) { var iteratee = keys[0], context; - if (isFunction$1(iteratee)) { + if (modules_isFunction(iteratee)) { iteratee = negate(iteratee); if (keys.length > 1) context = keys[1]; } else { - keys = map(flatten$1(keys, false, false), String); + keys = map(flatten(keys, false, false), String); iteratee = function(value, key) { return !contains(keys, key); }; } return pick(obj, iteratee, context); -}); +})); -// Returns everything but the last entry of the array. Especially useful on +// CONCATENATED MODULE: ./node_modules/underscore/modules/initial.js + + +// Returns everything but the last entry of the array. Especially useful on // the arguments object. Passing **n** will return all the values in // the array, excluding the last N. function initial(array, n, guard) { return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n))); } -// Get the first element of an array. Passing **n** will return the first N -// values in the array. The **guard** check allows it to work with `_.map`. -function first(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[0]; - return initial(array, array.length - n); -} +// CONCATENATED MODULE: ./node_modules/underscore/modules/first.js + + +// Get the first element of an array. Passing **n** will return the first N +// values in the array. The **guard** check allows it to work with `_.map`. +function first(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[0]; + return initial(array, array.length - n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/rest.js + + +// Returns everything but the first entry of the `array`. Especially useful on +// the `arguments` object. Passing an **n** will return the rest N values in the +// `array`. +function rest(array, n, guard) { + return slice.call(array, n == null || guard ? 1 : n); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/last.js + + +// Get the last element of an array. Passing **n** will return the last N +// values in the array. +function last(array, n, guard) { + if (array == null || array.length < 1) return n == null || guard ? void 0 : []; + if (n == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n)); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/compact.js + + +// Trim out all falsy values from an array. +function compact(array) { + return filter(array, Boolean); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/flatten.js + + +// Flatten out an array, either recursively (by default), or up to `depth`. +// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. +function flatten_flatten(array, depth) { + return flatten(array, depth, false); +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/difference.js + + + + + +// Take the difference between one array and a number of other arrays. +// Only the elements present in just the first array will remain. +/* harmony default export */ const difference = (restArguments(function(array, rest) { + rest = flatten(rest, true, true); + return filter(array, function(value){ + return !contains(rest, value); + }); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/without.js + + + +// Return a version of the array that does not contain the specified value(s). +/* harmony default export */ const without = (restArguments(function(array, otherArrays) { + return difference(array, otherArrays); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/uniq.js + + + + + +// Produce a duplicate-free version of the array. If the array has already +// been sorted, you have the option of using a faster algorithm. +// The faster algorithm will not work with an iteratee if the iteratee +// is not a one-to-one function, so providing an iteratee will disable +// the faster algorithm. +function uniq(array, isSorted, iteratee, context) { + if (!isBoolean(isSorted)) { + context = iteratee; + iteratee = isSorted; + isSorted = false; + } + if (iteratee != null) iteratee = cb(iteratee, context); + var result = []; + var seen = []; + for (var i = 0, length = _getLength(array); i < length; i++) { + var value = array[i], + computed = iteratee ? iteratee(value, i, array) : value; + if (isSorted && !iteratee) { + if (!i || seen !== computed) result.push(value); + seen = computed; + } else if (iteratee) { + if (!contains(seen, computed)) { + seen.push(computed); + result.push(value); + } + } else if (!contains(result, value)) { + result.push(value); + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/union.js + + + + +// Produce an array that contains the union: each distinct element from all of +// the passed-in arrays. +/* harmony default export */ const union = (restArguments(function(arrays) { + return uniq(flatten(arrays, true, true)); +})); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/intersection.js + + + +// Produce an array that contains every item shared between all the +// passed-in arrays. +function intersection(array) { + var result = []; + var argsLength = arguments.length; + for (var i = 0, length = _getLength(array); i < length; i++) { + var item = array[i]; + if (contains(result, item)) continue; + var j; + for (j = 1; j < argsLength; j++) { + if (!contains(arguments[j], item)) break; + } + if (j === argsLength) result.push(item); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/unzip.js + + + + +// Complement of zip. Unzip accepts an array of arrays and groups +// each array's elements on shared indices. +function unzip(array) { + var length = (array && max(array, _getLength).length) || 0; + var result = Array(length); + + for (var index = 0; index < length; index++) { + result[index] = pluck(array, index); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/zip.js + + + +// Zip together multiple lists into a single array -- elements that share +// an index go together. +/* harmony default export */ const zip = (restArguments(unzip)); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/object.js + + +// Converts lists into objects. Pass either a single array of `[key, value]` +// pairs, or two parallel arrays of the same length -- one of keys, and one of +// the corresponding values. Passing by pairs is the reverse of `_.pairs`. +function object(list, values) { + var result = {}; + for (var i = 0, length = _getLength(list); i < length; i++) { + if (values) { + result[list[i]] = values[i]; + } else { + result[list[i][0]] = list[i][1]; + } + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/range.js +// Generate an integer Array containing an arithmetic progression. A port of +// the native Python `range()` function. See +// [the Python documentation](https://docs.python.org/library/functions.html#range). +function range(start, stop, step) { + if (stop == null) { + stop = start || 0; + start = 0; + } + if (!step) { + step = stop < start ? -1 : 1; + } + + var length = Math.max(Math.ceil((stop - start) / step), 0); + var range = Array(length); + + for (var idx = 0; idx < length; idx++, start += step) { + range[idx] = start; + } + + return range; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/chunk.js + + +// Chunk a single array into multiple arrays, each containing `count` or fewer +// items. +function chunk(array, count) { + if (count == null || count < 1) return []; + var result = []; + var i = 0, length = array.length; + while (i < length) { + result.push(slice.call(array, i, i += count)); + } + return result; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/_chainResult.js + + +// Helper function to continue chaining intermediate results. +function chainResult(instance, obj) { + return instance._chain ? _(obj).chain() : obj; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/mixin.js + + + + + + +// Add your own custom functions to the Underscore object. +function mixin(obj) { + each(functions(obj), function(name) { + var func = _[name] = obj[name]; + _.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_, args)); + }; + }); + return _; +} + +// CONCATENATED MODULE: ./node_modules/underscore/modules/underscore-array-methods.js + + + + + +// Add all mutator `Array` functions to the wrapper. +each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === 'shift' || name === 'splice') && obj.length === 0) { + delete obj[0]; + } + } + return chainResult(this, obj); + }; +}); + +// Add all accessor `Array` functions to the wrapper. +each(['concat', 'join', 'slice'], function(name) { + var method = ArrayProto[name]; + _.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; +}); + +/* harmony default export */ const underscore_array_methods = (_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index.js +// Named Exports +// ============= + +// Underscore.js 1.13.6 +// https://underscorejs.org +// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors +// Underscore may be freely distributed under the MIT license. + +// Baseline setup. + + + +// Object Functions +// ---------------- +// Our most fundamental functions operate on any JavaScript object. +// Most functions in Underscore depend on at least one function in this section. + +// A group of functions that check the types of core JavaScript values. +// These are often informally referred to as the "isType" functions. + + + + + + + + + + + + + + + + + + + + + + + + + + + +// Functions that treat an object as a dictionary of key-value pairs. + + + + + + + + + + + + + + + + +// Utility Functions +// ----------------- +// A bit of a grab bag: Predicate-generating functions for use with filters and +// loops, string escaping and templating, create random numbers and unique ids, +// and functions that facilitate Underscore's chaining and iteration conventions. + + + + + + + + + + + + + + + + + + + +// Function (ahem) Functions +// ------------------------- +// These functions take a function as an argument and return a new function +// as the result. Also known as higher-order functions. + + + + + + + + + + + + + + + +// Finders +// ------- +// Functions that extract (the position of) a single element from an object +// or array based on some criterion. + + + + + + + + + +// Collection Functions +// -------------------- +// Functions that work on any collection of elements: either an array, or +// an object of key-value pairs. + + + + + + + + + + + + + + + + + + + + + + + + +// `_.pick` and `_.omit` are actually object functions, but we put +// them here in order to create a more natural reading order in the +// monolithic build as they depend on `_.contains`. + + + +// Array Functions +// --------------- +// Functions that operate on arrays (and array-likes) only, because they’re +// expressed in terms of operations on an ordered list of values. + + + + + + + + + + + + + + + + + +// OOP +// --- +// These modules support the "object-oriented" calling style. See also +// `underscore.js` and `index-default.js`. + + + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-default.js +// Default Export +// ============== +// In this module, we mix our bundled exports into the `_` object and export +// the result. This is analogous to setting `module.exports = _` in CommonJS. +// Hence, this module is also the entry point of our UMD bundle and the package +// entry point for CommonJS and AMD users. In other words, this is (the source +// of) the module you are interfacing with when you do any of the following: +// +// ```js +// // CommonJS +// var _ = require('underscore'); +// +// // AMD +// define(['underscore'], function(_) {...}); +// +// // UMD in the browser +// // _ is available as a global variable +// ``` + + + +// Add all of the Underscore functions to the wrapper object. +var index_default_ = mixin(modules_namespaceObject); +// Legacy Node.js API. +index_default_._ = index_default_; +// Export the Underscore API. +/* harmony default export */ const index_default = (index_default_); + +// CONCATENATED MODULE: ./node_modules/underscore/modules/index-all.js +// ESM Exports +// =========== +// This module is the package entry point for ES module users. In other words, +// it is the module they are interfacing with when they import from the whole +// package instead of from a submodule, like this: +// +// ```js +// import { map } from 'underscore'; +// ``` +// +// The difference with `./index-default`, which is the package entry point for +// CommonJS, AMD and UMD users, is purely technical. In ES modules, named and +// default exports are considered to be siblings, so when you have a default +// export, its properties are not automatically available as named exports. For +// this reason, we re-export the named exports in addition to providing the same +// default export as in `./index-default`. + + + + +/***/ }), + +/***/ 5030: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", ({ value: true })); + +function getUserAgent() { + if (typeof navigator === "object" && "userAgent" in navigator) { + return navigator.userAgent; + } + + if (typeof process === "object" && "version" in process) { + return `Node.js/${process.version.substr(1)} (${process.platform}; ${process.arch})`; + } + + return ""; +} + +exports.getUserAgent = getUserAgent; +//# sourceMappingURL=index.js.map + + +/***/ }), + +/***/ 9521: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +// ESM COMPAT FLAG +__nccwpck_require__.r(__webpack_exports__); + +// EXPORTS +__nccwpck_require__.d(__webpack_exports__, { + "NIL": () => /* reexport */ nil, + "parse": () => /* reexport */ esm_node_parse, + "stringify": () => /* reexport */ esm_node_stringify, + "v1": () => /* reexport */ esm_node_v1, + "v3": () => /* reexport */ esm_node_v3, + "v4": () => /* reexport */ esm_node_v4, + "v5": () => /* reexport */ esm_node_v5, + "validate": () => /* reexport */ esm_node_validate, + "version": () => /* reexport */ esm_node_version +}); + +// CONCATENATED MODULE: external "crypto" +const external_crypto_namespaceObject = require("crypto");; +var external_crypto_default = /*#__PURE__*/__nccwpck_require__.n(external_crypto_namespaceObject); + +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/rng.js + +const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate + +let poolPtr = rnds8Pool.length; +function rng() { + if (poolPtr > rnds8Pool.length - 16) { + external_crypto_default().randomFillSync(rnds8Pool); + poolPtr = 0; + } + + return rnds8Pool.slice(poolPtr, poolPtr += 16); +} +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/regex.js +/* harmony default export */ const regex = (/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/validate.js + + +function validate(uuid) { + return typeof uuid === 'string' && regex.test(uuid); +} + +/* harmony default export */ const esm_node_validate = (validate); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/stringify.js + +/** + * Convert array of 16 byte values to UUID string format of the form: + * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX + */ + +const byteToHex = []; + +for (let i = 0; i < 256; ++i) { + byteToHex.push((i + 0x100).toString(16).substr(1)); +} + +function stringify(arr, offset = 0) { + // Note: Be careful editing this code! It's been tuned for performance + // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434 + const uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID. If this throws, it's likely due to one + // of the following: + // - One or more input array values don't map to a hex octet (leading to + // "undefined" in the uuid) + // - Invalid input values for the RFC `version` or `variant` fields + + if (!esm_node_validate(uuid)) { + throw TypeError('Stringified UUID is invalid'); + } + + return uuid; +} + +/* harmony default export */ const esm_node_stringify = (stringify); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v1.js + + // **`v1()` - Generate time-based UUID** +// +// Inspired by https://github.com/LiosK/UUID.js +// and http://docs.python.org/library/uuid.html + +let _nodeId; + +let _clockseq; // Previous uuid creation time + + +let _lastMSecs = 0; +let _lastNSecs = 0; // See https://github.com/uuidjs/uuid for API details + +function v1(options, buf, offset) { + let i = buf && offset || 0; + const b = buf || new Array(16); + options = options || {}; + let node = options.node || _nodeId; + let clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq; // node and clockseq need to be initialized to random values if they're not + // specified. We do this lazily to minimize issues related to insufficient + // system entropy. See #189 + + if (node == null || clockseq == null) { + const seedBytes = options.random || (options.rng || rng)(); + + if (node == null) { + // Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1) + node = _nodeId = [seedBytes[0] | 0x01, seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]]; + } + + if (clockseq == null) { + // Per 4.2.2, randomize (14 bit) clockseq + clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff; + } + } // UUID timestamps are 100 nano-second units since the Gregorian epoch, + // (1582-10-15 00:00). JSNumbers aren't precise enough for this, so + // time is handled internally as 'msecs' (integer milliseconds) and 'nsecs' + // (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00. + + + let msecs = options.msecs !== undefined ? options.msecs : Date.now(); // Per 4.2.1.2, use count of uuid's generated during the current clock + // cycle to simulate higher resolution clock + + let nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1; // Time since last uuid creation (in msecs) + + const dt = msecs - _lastMSecs + (nsecs - _lastNSecs) / 10000; // Per 4.2.1.2, Bump clockseq on clock regression + + if (dt < 0 && options.clockseq === undefined) { + clockseq = clockseq + 1 & 0x3fff; + } // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new + // time interval + + + if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) { + nsecs = 0; + } // Per 4.2.1.2 Throw error if too many uuids are requested + + + if (nsecs >= 10000) { + throw new Error("uuid.v1(): Can't create more than 10M uuids/sec"); + } + + _lastMSecs = msecs; + _lastNSecs = nsecs; + _clockseq = clockseq; // Per 4.1.4 - Convert from unix epoch to Gregorian epoch + + msecs += 12219292800000; // `time_low` + + const tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000; + b[i++] = tl >>> 24 & 0xff; + b[i++] = tl >>> 16 & 0xff; + b[i++] = tl >>> 8 & 0xff; + b[i++] = tl & 0xff; // `time_mid` + + const tmh = msecs / 0x100000000 * 10000 & 0xfffffff; + b[i++] = tmh >>> 8 & 0xff; + b[i++] = tmh & 0xff; // `time_high_and_version` + + b[i++] = tmh >>> 24 & 0xf | 0x10; // include version + + b[i++] = tmh >>> 16 & 0xff; // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant) + + b[i++] = clockseq >>> 8 | 0x80; // `clock_seq_low` + + b[i++] = clockseq & 0xff; // `node` + + for (let n = 0; n < 6; ++n) { + b[i + n] = node[n]; + } + + return buf || esm_node_stringify(b); +} + +/* harmony default export */ const esm_node_v1 = (v1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/parse.js + + +function parse(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); + } + + let v; + const arr = new Uint8Array(16); // Parse ########-....-....-....-............ + + arr[0] = (v = parseInt(uuid.slice(0, 8), 16)) >>> 24; + arr[1] = v >>> 16 & 0xff; + arr[2] = v >>> 8 & 0xff; + arr[3] = v & 0xff; // Parse ........-####-....-....-............ + + arr[4] = (v = parseInt(uuid.slice(9, 13), 16)) >>> 8; + arr[5] = v & 0xff; // Parse ........-....-####-....-............ + + arr[6] = (v = parseInt(uuid.slice(14, 18), 16)) >>> 8; + arr[7] = v & 0xff; // Parse ........-....-....-####-............ + + arr[8] = (v = parseInt(uuid.slice(19, 23), 16)) >>> 8; + arr[9] = v & 0xff; // Parse ........-....-....-....-############ + // (Use "/" to avoid 32-bit truncation when bit-shifting high-order bytes) + + arr[10] = (v = parseInt(uuid.slice(24, 36), 16)) / 0x10000000000 & 0xff; + arr[11] = v / 0x100000000 & 0xff; + arr[12] = v >>> 24 & 0xff; + arr[13] = v >>> 16 & 0xff; + arr[14] = v >>> 8 & 0xff; + arr[15] = v & 0xff; + return arr; +} + +/* harmony default export */ const esm_node_parse = (parse); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v35.js + + + +function stringToBytes(str) { + str = unescape(encodeURIComponent(str)); // UTF8 escape + + const bytes = []; + + for (let i = 0; i < str.length; ++i) { + bytes.push(str.charCodeAt(i)); + } + + return bytes; +} + +const DNS = '6ba7b810-9dad-11d1-80b4-00c04fd430c8'; +const URL = '6ba7b811-9dad-11d1-80b4-00c04fd430c8'; +/* harmony default export */ function v35(name, version, hashfunc) { + function generateUUID(value, namespace, buf, offset) { + if (typeof value === 'string') { + value = stringToBytes(value); + } + + if (typeof namespace === 'string') { + namespace = esm_node_parse(namespace); + } + + if (namespace.length !== 16) { + throw TypeError('Namespace must be array-like (16 iterable integer values, 0-255)'); + } // Compute hash of namespace and value, Per 4.3 + // Future: Use spread syntax when supported on all platforms, e.g. `bytes = + // hashfunc([...namespace, ... value])` + + + let bytes = new Uint8Array(16 + value.length); + bytes.set(namespace); + bytes.set(value, namespace.length); + bytes = hashfunc(bytes); + bytes[6] = bytes[6] & 0x0f | version; + bytes[8] = bytes[8] & 0x3f | 0x80; + + if (buf) { + offset = offset || 0; + + for (let i = 0; i < 16; ++i) { + buf[offset + i] = bytes[i]; + } + + return buf; + } + + return esm_node_stringify(bytes); + } // Function#name is not settable on some platforms (#270) + + + try { + generateUUID.name = name; // eslint-disable-next-line no-empty + } catch (err) {} // For CommonJS default export support + -// Returns everything but the first entry of the `array`. Especially useful on -// the `arguments` object. Passing an **n** will return the rest N values in the -// `array`. -function rest(array, n, guard) { - return slice.call(array, n == null || guard ? 1 : n); + generateUUID.DNS = DNS; + generateUUID.URL = URL; + return generateUUID; } +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/md5.js -// Get the last element of an array. Passing **n** will return the last N -// values in the array. -function last(array, n, guard) { - if (array == null || array.length < 1) return n == null || guard ? void 0 : []; - if (n == null || guard) return array[array.length - 1]; - return rest(array, Math.max(0, array.length - n)); -} -// Trim out all falsy values from an array. -function compact(array) { - return filter(array, Boolean); -} +function md5(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); + } -// Flatten out an array, either recursively (by default), or up to `depth`. -// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively. -function flatten(array, depth) { - return flatten$1(array, depth, false); + return external_crypto_default().createHash('md5').update(bytes).digest(); } -// Take the difference between one array and a number of other arrays. -// Only the elements present in just the first array will remain. -var difference = restArguments(function(array, rest) { - rest = flatten$1(rest, true, true); - return filter(array, function(value){ - return !contains(rest, value); - }); -}); +/* harmony default export */ const esm_node_md5 = (md5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v3.js -// Return a version of the array that does not contain the specified value(s). -var without = restArguments(function(array, otherArrays) { - return difference(array, otherArrays); -}); -// Produce a duplicate-free version of the array. If the array has already -// been sorted, you have the option of using a faster algorithm. -// The faster algorithm will not work with an iteratee if the iteratee -// is not a one-to-one function, so providing an iteratee will disable -// the faster algorithm. -function uniq(array, isSorted, iteratee, context) { - if (!isBoolean(isSorted)) { - context = iteratee; - iteratee = isSorted; - isSorted = false; - } - if (iteratee != null) iteratee = cb(iteratee, context); - var result = []; - var seen = []; - for (var i = 0, length = getLength(array); i < length; i++) { - var value = array[i], - computed = iteratee ? iteratee(value, i, array) : value; - if (isSorted && !iteratee) { - if (!i || seen !== computed) result.push(value); - seen = computed; - } else if (iteratee) { - if (!contains(seen, computed)) { - seen.push(computed); - result.push(value); - } - } else if (!contains(result, value)) { - result.push(value); - } - } - return result; -} +const v3 = v35('v3', 0x30, esm_node_md5); +/* harmony default export */ const esm_node_v3 = (v3); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v4.js -// Produce an array that contains the union: each distinct element from all of -// the passed-in arrays. -var union = restArguments(function(arrays) { - return uniq(flatten$1(arrays, true, true)); -}); -// Produce an array that contains every item shared between all the -// passed-in arrays. -function intersection(array) { - var result = []; - var argsLength = arguments.length; - for (var i = 0, length = getLength(array); i < length; i++) { - var item = array[i]; - if (contains(result, item)) continue; - var j; - for (j = 1; j < argsLength; j++) { - if (!contains(arguments[j], item)) break; - } - if (j === argsLength) result.push(item); - } - return result; -} -// Complement of zip. Unzip accepts an array of arrays and groups -// each array's elements on shared indices. -function unzip(array) { - var length = (array && max(array, getLength).length) || 0; - var result = Array(length); +function v4(options, buf, offset) { + options = options || {}; + const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved` - for (var index = 0; index < length; index++) { - result[index] = pluck(array, index); - } - return result; -} + rnds[6] = rnds[6] & 0x0f | 0x40; + rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided -// Zip together multiple lists into a single array -- elements that share -// an index go together. -var zip = restArguments(unzip); + if (buf) { + offset = offset || 0; -// Converts lists into objects. Pass either a single array of `[key, value]` -// pairs, or two parallel arrays of the same length -- one of keys, and one of -// the corresponding values. Passing by pairs is the reverse of `_.pairs`. -function object(list, values) { - var result = {}; - for (var i = 0, length = getLength(list); i < length; i++) { - if (values) { - result[list[i]] = values[i]; - } else { - result[list[i][0]] = list[i][1]; + for (let i = 0; i < 16; ++i) { + buf[offset + i] = rnds[i]; } + + return buf; } - return result; + + return esm_node_stringify(rnds); } -// Generate an integer Array containing an arithmetic progression. A port of -// the native Python `range()` function. See -// [the Python documentation](https://docs.python.org/library/functions.html#range). -function range(start, stop, step) { - if (stop == null) { - stop = start || 0; - start = 0; - } - if (!step) { - step = stop < start ? -1 : 1; - } +/* harmony default export */ const esm_node_v4 = (v4); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/sha1.js - var length = Math.max(Math.ceil((stop - start) / step), 0); - var range = Array(length); - for (var idx = 0; idx < length; idx++, start += step) { - range[idx] = start; +function sha1(bytes) { + if (Array.isArray(bytes)) { + bytes = Buffer.from(bytes); + } else if (typeof bytes === 'string') { + bytes = Buffer.from(bytes, 'utf8'); } - return range; + return external_crypto_default().createHash('sha1').update(bytes).digest(); } -// Chunk a single array into multiple arrays, each containing `count` or fewer -// items. -function chunk(array, count) { - if (count == null || count < 1) return []; - var result = []; - var i = 0, length = array.length; - while (i < length) { - result.push(slice.call(array, i, i += count)); +/* harmony default export */ const esm_node_sha1 = (sha1); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/v5.js + + +const v5 = v35('v5', 0x50, esm_node_sha1); +/* harmony default export */ const esm_node_v5 = (v5); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/nil.js +/* harmony default export */ const nil = ('00000000-0000-0000-0000-000000000000'); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/version.js + + +function version(uuid) { + if (!esm_node_validate(uuid)) { + throw TypeError('Invalid UUID'); } - return result; -} -// Helper function to continue chaining intermediate results. -function chainResult(instance, obj) { - return instance._chain ? _$1(obj).chain() : obj; + return parseInt(uuid.substr(14, 1), 16); } -// Add your own custom functions to the Underscore object. -function mixin(obj) { - each(functions(obj), function(name) { - var func = _$1[name] = obj[name]; - _$1.prototype[name] = function() { - var args = [this._wrapped]; - push.apply(args, arguments); - return chainResult(this, func.apply(_$1, args)); - }; - }); - return _$1; -} +/* harmony default export */ const esm_node_version = (version); +// CONCATENATED MODULE: ./node_modules/uuid/dist/esm-node/index.js + + -// Add all mutator `Array` functions to the wrapper. -each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) { - method.apply(obj, arguments); - if ((name === 'shift' || name === 'splice') && obj.length === 0) { - delete obj[0]; - } - } - return chainResult(this, obj); - }; -}); -// Add all accessor `Array` functions to the wrapper. -each(['concat', 'join', 'slice'], function(name) { - var method = ArrayProto[name]; - _$1.prototype[name] = function() { - var obj = this._wrapped; - if (obj != null) obj = method.apply(obj, arguments); - return chainResult(this, obj); - }; -}); -// Named Exports -var allExports = { - __proto__: null, - VERSION: VERSION, - restArguments: restArguments, - isObject: isObject, - isNull: isNull, - isUndefined: isUndefined, - isBoolean: isBoolean, - isElement: isElement, - isString: isString, - isNumber: isNumber, - isDate: isDate, - isRegExp: isRegExp, - isError: isError, - isSymbol: isSymbol, - isArrayBuffer: isArrayBuffer, - isDataView: isDataView$1, - isArray: isArray, - isFunction: isFunction$1, - isArguments: isArguments$1, - isFinite: isFinite$1, - isNaN: isNaN$1, - isTypedArray: isTypedArray$1, - isEmpty: isEmpty, - isMatch: isMatch, - isEqual: isEqual, - isMap: isMap, - isWeakMap: isWeakMap, - isSet: isSet, - isWeakSet: isWeakSet, - keys: keys, - allKeys: allKeys, - values: values, - pairs: pairs, - invert: invert, - functions: functions, - methods: functions, - extend: extend, - extendOwn: extendOwn, - assign: extendOwn, - defaults: defaults, - create: create, - clone: clone, - tap: tap, - get: get, - has: has, - mapObject: mapObject, - identity: identity, - constant: constant, - noop: noop, - toPath: toPath$1, - property: property, - propertyOf: propertyOf, - matcher: matcher, - matches: matcher, - times: times, - random: random, - now: now, - escape: _escape, - unescape: _unescape, - templateSettings: templateSettings, - template: template, - result: result, - uniqueId: uniqueId, - chain: chain, - iteratee: iteratee, - partial: partial, - bind: bind, - bindAll: bindAll, - memoize: memoize, - delay: delay, - defer: defer, - throttle: throttle, - debounce: debounce, - wrap: wrap, - negate: negate, - compose: compose, - after: after, - before: before, - once: once, - findKey: findKey, - findIndex: findIndex, - findLastIndex: findLastIndex, - sortedIndex: sortedIndex, - indexOf: indexOf, - lastIndexOf: lastIndexOf, - find: find, - detect: find, - findWhere: findWhere, - each: each, - forEach: each, - map: map, - collect: map, - reduce: reduce, - foldl: reduce, - inject: reduce, - reduceRight: reduceRight, - foldr: reduceRight, - filter: filter, - select: filter, - reject: reject, - every: every, - all: every, - some: some, - any: some, - contains: contains, - includes: contains, - include: contains, - invoke: invoke, - pluck: pluck, - where: where, - max: max, - min: min, - shuffle: shuffle, - sample: sample, - sortBy: sortBy, - groupBy: groupBy, - indexBy: indexBy, - countBy: countBy, - partition: partition, - toArray: toArray, - size: size, - pick: pick, - omit: omit, - first: first, - head: first, - take: first, - initial: initial, - last: last, - rest: rest, - tail: rest, - drop: rest, - compact: compact, - flatten: flatten, - without: without, - uniq: uniq, - unique: uniq, - union: union, - intersection: intersection, - difference: difference, - unzip: unzip, - transpose: unzip, - zip: zip, - object: object, - range: range, - chunk: chunk, - mixin: mixin, - 'default': _$1 -}; -// Default Export -// Add all of the Underscore functions to the wrapper object. -var _ = mixin(allExports); -// Legacy Node.js API. -_._ = _; - -exports.VERSION = VERSION; -exports._ = _; -exports._escape = _escape; -exports._unescape = _unescape; -exports.after = after; -exports.allKeys = allKeys; -exports.before = before; -exports.bind = bind; -exports.bindAll = bindAll; -exports.chain = chain; -exports.chunk = chunk; -exports.clone = clone; -exports.compact = compact; -exports.compose = compose; -exports.constant = constant; -exports.contains = contains; -exports.countBy = countBy; -exports.create = create; -exports.debounce = debounce; -exports.defaults = defaults; -exports.defer = defer; -exports.delay = delay; -exports.difference = difference; -exports.each = each; -exports.every = every; -exports.extend = extend; -exports.extendOwn = extendOwn; -exports.filter = filter; -exports.find = find; -exports.findIndex = findIndex; -exports.findKey = findKey; -exports.findLastIndex = findLastIndex; -exports.findWhere = findWhere; -exports.first = first; -exports.flatten = flatten; -exports.functions = functions; -exports.get = get; -exports.groupBy = groupBy; -exports.has = has; -exports.identity = identity; -exports.indexBy = indexBy; -exports.indexOf = indexOf; -exports.initial = initial; -exports.intersection = intersection; -exports.invert = invert; -exports.invoke = invoke; -exports.isArguments = isArguments$1; -exports.isArray = isArray; -exports.isArrayBuffer = isArrayBuffer; -exports.isBoolean = isBoolean; -exports.isDataView = isDataView$1; -exports.isDate = isDate; -exports.isElement = isElement; -exports.isEmpty = isEmpty; -exports.isEqual = isEqual; -exports.isError = isError; -exports.isFinite = isFinite$1; -exports.isFunction = isFunction$1; -exports.isMap = isMap; -exports.isMatch = isMatch; -exports.isNaN = isNaN$1; -exports.isNull = isNull; -exports.isNumber = isNumber; -exports.isObject = isObject; -exports.isRegExp = isRegExp; -exports.isSet = isSet; -exports.isString = isString; -exports.isSymbol = isSymbol; -exports.isTypedArray = isTypedArray$1; -exports.isUndefined = isUndefined; -exports.isWeakMap = isWeakMap; -exports.isWeakSet = isWeakSet; -exports.iteratee = iteratee; -exports.keys = keys; -exports.last = last; -exports.lastIndexOf = lastIndexOf; -exports.map = map; -exports.mapObject = mapObject; -exports.matcher = matcher; -exports.max = max; -exports.memoize = memoize; -exports.min = min; -exports.mixin = mixin; -exports.negate = negate; -exports.noop = noop; -exports.now = now; -exports.object = object; -exports.omit = omit; -exports.once = once; -exports.pairs = pairs; -exports.partial = partial; -exports.partition = partition; -exports.pick = pick; -exports.pluck = pluck; -exports.property = property; -exports.propertyOf = propertyOf; -exports.random = random; -exports.range = range; -exports.reduce = reduce; -exports.reduceRight = reduceRight; -exports.reject = reject; -exports.rest = rest; -exports.restArguments = restArguments; -exports.result = result; -exports.sample = sample; -exports.shuffle = shuffle; -exports.size = size; -exports.some = some; -exports.sortBy = sortBy; -exports.sortedIndex = sortedIndex; -exports.tap = tap; -exports.template = template; -exports.templateSettings = templateSettings; -exports.throttle = throttle; -exports.times = times; -exports.toArray = toArray; -exports.toPath = toPath$1; -exports.union = union; -exports.uniq = uniq; -exports.uniqueId = uniqueId; -exports.unzip = unzip; -exports.values = values; -exports.where = where; -exports.without = without; -exports.wrap = wrap; -exports.zip = zip; -//# sourceMappingURL=underscore-node-f.cjs.map /***/ }), -/***/ 3571: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 2940: +/***/ ((module) => { -// Underscore.js 1.13.4 -// https://underscorejs.org -// (c) 2009-2022 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors -// Underscore may be freely distributed under the MIT license. +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -var underscoreNodeF = __nccwpck_require__(1641); + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = underscoreNodeF._; -//# sourceMappingURL=underscore-node.cjs.map + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), From 819a769cc89e96bbdb127eda8771c5ddde9c6caa Mon Sep 17 00:00:00 2001 From: Pierre Michel Date: Wed, 30 Aug 2023 07:17:44 -0600 Subject: [PATCH 036/134] Subscribe to top most report changes because the keyboard avoiding view depends on it and the composer was hidden behind keyboard Signed-off-by: Pierre Michel --- src/pages/home/ReportScreen.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/pages/home/ReportScreen.js b/src/pages/home/ReportScreen.js index 6daa15785921..5ef8011c0aeb 100644 --- a/src/pages/home/ReportScreen.js +++ b/src/pages/home/ReportScreen.js @@ -37,6 +37,7 @@ import ReportScreenContext from './ReportScreenContext'; import TaskHeaderActionButton from '../../components/TaskHeaderActionButton'; import DragAndDropProvider from '../../components/DragAndDrop/Provider'; import usePrevious from '../../hooks/usePrevious'; +import withCurrentReportID from '../../components/withCurrentReportID'; const propTypes = { /** Navigation route context info provided by react navigation */ @@ -396,6 +397,7 @@ export default compose( withLocalize, withWindowDimensions, withNetwork(), + withCurrentReportID, withOnyx({ isSidebarLoaded: { key: ONYXKEYS.IS_SIDEBAR_LOADED, From b52347d5a0e3090d3faab44a822fd3979be467de Mon Sep 17 00:00:00 2001 From: rory Date: Wed, 30 Aug 2023 15:43:29 +0200 Subject: [PATCH 037/134] Reimplement and simplify createOrUpdateStagingDeployCash --- .../createOrUpdateStagingDeploy.js | 230 ++++++++---------- .../createOrUpdateStagingDeploy/index.js | 229 ++++++++--------- .../getDeployPullRequestList/index.js | 5 +- .github/libs/GitUtils.js | 5 +- tests/unit/createOrUpdateStagingDeployTest.js | 16 +- 5 files changed, 203 insertions(+), 282 deletions(-) diff --git a/.github/actions/javascript/createOrUpdateStagingDeploy/createOrUpdateStagingDeploy.js b/.github/actions/javascript/createOrUpdateStagingDeploy/createOrUpdateStagingDeploy.js index a514f8a9bcab..31ce88d3d775 100644 --- a/.github/actions/javascript/createOrUpdateStagingDeploy/createOrUpdateStagingDeploy.js +++ b/.github/actions/javascript/createOrUpdateStagingDeploy/createOrUpdateStagingDeploy.js @@ -5,166 +5,126 @@ const CONST = require('../../../libs/CONST'); const GithubUtils = require('../../../libs/GithubUtils'); const GitUtils = require('../../../libs/GitUtils'); -const run = function () { +const run = async function () { const newVersion = core.getInput('NPM_VERSION'); console.log('New version found from action input:', newVersion); - let shouldCreateNewStagingDeployCash = false; - let newTag = newVersion; - let newDeployBlockers = []; - let previousStagingDeployCashData = {}; - let currentStagingDeployCashData = null; - - // Start by fetching the list of recent StagingDeployCash issues, along with the list of open deploy blockers - return Promise.all([ - GithubUtils.octokit.issues.listForRepo({ + try { + // Start by fetching the list of recent StagingDeployCash issues, along with the list of open deploy blockers + const {data: recentDeployChecklists} = await GithubUtils.octokit.issues.listForRepo({ log: console, owner: CONST.GITHUB_OWNER, repo: CONST.APP_REPO, labels: CONST.LABELS.STAGING_DEPLOY, state: 'all', - }), - GithubUtils.octokit.issues.listForRepo({ - log: console, - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - labels: CONST.LABELS.DEPLOY_BLOCKER, - }), - ]) - .then(([stagingDeployResponse, deployBlockerResponse]) => { - if (!stagingDeployResponse || !stagingDeployResponse.data || _.isEmpty(stagingDeployResponse.data)) { - console.error('Failed fetching StagingDeployCash issues from Github!', stagingDeployResponse); - throw new Error('Failed fetching StagingDeployCash issues from Github'); - } - - if (!deployBlockerResponse || !deployBlockerResponse.data) { - console.log('Failed fetching DeployBlockerCash issues from Github, continuing...'); - } - - newDeployBlockers = _.map(deployBlockerResponse.data, ({html_url}) => ({ - url: html_url, - number: GithubUtils.getIssueOrPullRequestNumberFromURL(html_url), - isResolved: false, - })); - - // Look at the state of the most recent StagingDeployCash, - // if it is open then we'll update the existing one, otherwise, we'll create a new one. - shouldCreateNewStagingDeployCash = Boolean(stagingDeployResponse.data[0].state !== 'open'); - if (shouldCreateNewStagingDeployCash) { - console.log('Latest StagingDeployCash is closed, creating a new one.', stagingDeployResponse.data[0]); - } else { - console.log( - 'Latest StagingDeployCash is open, updating it instead of creating a new one.', - 'Current:', - stagingDeployResponse.data[0], - 'Previous:', - stagingDeployResponse.data[1], - ); - } - - // Parse the data from the previous StagingDeployCash - // (newest if there are none open, otherwise second-newest) - previousStagingDeployCashData = shouldCreateNewStagingDeployCash - ? GithubUtils.getStagingDeployCashData(stagingDeployResponse.data[0]) - : GithubUtils.getStagingDeployCashData(stagingDeployResponse.data[1]); - - console.log('Found tag of previous StagingDeployCash:', previousStagingDeployCashData.tag); - - // Find the list of PRs merged between the last StagingDeployCash and the new version - if (shouldCreateNewStagingDeployCash) { - return GitUtils.getPullRequestsMergedBetween(previousStagingDeployCashData.tag, newTag); - } - - currentStagingDeployCashData = GithubUtils.getStagingDeployCashData(stagingDeployResponse.data[0]); - console.log('Parsed the following data from the current StagingDeployCash:', currentStagingDeployCashData); - - // If we aren't sent a tag, then use the existing tag - newTag = newTag || currentStagingDeployCashData.tag; - - return GitUtils.getPullRequestsMergedBetween(previousStagingDeployCashData.tag, newTag); - }) - .then((mergedPRs) => { - console.log(`The following PRs have been merged between the previous StagingDeployCash (${previousStagingDeployCashData.tag}) and new version (${newVersion}):`, mergedPRs); - - if (shouldCreateNewStagingDeployCash) { - return GithubUtils.generateStagingDeployCashBody(newTag, _.map(mergedPRs, GithubUtils.getPullRequestURLFromNumber)); - } - - const didVersionChange = newVersion ? newVersion !== currentStagingDeployCashData.tag : false; - - // Generate the PR list, preserving the previous state of `isVerified` for existing PRs - const PRList = _.sortBy( - _.unique( - _.union( - currentStagingDeployCashData.PRList, - _.map(mergedPRs, (number) => ({ - number: Number.parseInt(number, 10), - url: GithubUtils.getPullRequestURLFromNumber(number), + }); - // Since this is the second argument to _.union, - // it will appear later in the array than any duplicate. - // Since it is later in the array, it will be truncated by _.unique, - // and the original value of isVerified will be preserved. - isVerified: false, - })), - ), - false, - (item) => item.number, - ), - 'number', + // Look at the state of the most recent StagingDeployCash, + // if it is open then we'll update the existing one, otherwise, we'll create a new one. + const mostRecentChecklist = recentDeployChecklists[0]; + const shouldCreateNewDeployChecklist = mostRecentChecklist.state !== 'open'; + const previousChecklist = shouldCreateNewDeployChecklist ? mostRecentChecklist : recentDeployChecklists[1]; + if (shouldCreateNewDeployChecklist) { + console.log('Latest StagingDeployCash is closed, creating a new one.', mostRecentChecklist); + } else { + console.log('Latest StagingDeployCash is open, updating it instead of creating a new one.', 'Current:', mostRecentChecklist, 'Previous:', previousChecklist); + } + + // Parse the data from the previous and current checklists into the format used to generate the checklist + const previousChecklistData = GithubUtils.getStagingDeployCashData(previousChecklist); + const currentChecklistData = shouldCreateNewDeployChecklist ? {} : GithubUtils.getStagingDeployCashData(mostRecentChecklist); + + // Find the list of PRs merged between the current checklist and the previous checklist + // Note that any time we're creating a new checklist we MUST have `NPM_VERSION` passed in as an input + const newTag = newVersion || _.get(currentChecklistData, 'tag'); + const mergedPRs = await GitUtils.getPullRequestsMergedBetween(previousChecklistData.tag, newTag); + + // Next, we generate the checklist body + let checklistBody = ''; + if (shouldCreateNewDeployChecklist) { + checklistBody = await GithubUtils.generateStagingDeployCashBody(newTag, _.map(mergedPRs, GithubUtils.getPullRequestURLFromNumber)); + } else { + // Generate the updated PR list, preserving the previous state of `isVerified` for existing PRs + const PRList = _.reduce( + mergedPRs, + (memo, prNum) => { + const indexOfPRInCurrentChecklist = _.findIndex(currentChecklistData.PRList, (pr) => pr.number === prNum); + const isVerified = indexOfPRInCurrentChecklist >= 0 ? currentChecklistData.PRList[indexOfPRInCurrentChecklist].isVerified : false; + memo.push({ + number: prNum, + url: GithubUtils.getPullRequestURLFromNumber(prNum), + isVerified, + }); + return memo; + }, + [], ); // Generate the deploy blocker list, preserving the previous state of `isResolved` - const deployBlockers = _.sortBy( - _.unique(_.union(currentStagingDeployCashData.deployBlockers, newDeployBlockers), false, (item) => item.number), - 'number', + const {data: openDeployBlockers} = await GithubUtils.octokit.issues.listForRepo({ + log: console, + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + labels: CONST.LABELS.DEPLOY_BLOCKER, + }); + const deployBlockers = _.reduce( + openDeployBlockers, + (memo, deployBlocker) => { + const {html_url, number} = deployBlocker; + const indexInCurrentChecklist = _.findIndex(currentChecklistData.deployBlockers, (item) => item.number === number); + const isResolved = indexInCurrentChecklist >= 0 ? currentChecklistData.deployBlockers[indexInCurrentChecklist].isResolved : false; + memo.push({ + number, + url: html_url, + isResolved, + }); + return memo; + }, + [], ); - // Get the internalQA PR list, preserving the previous state of `isResolved` - const internalQAPRList = _.sortBy(currentStagingDeployCashData.internalQAPRList, 'number'); - - return GithubUtils.generateStagingDeployCashBody( + const didVersionChange = newVersion ? newVersion !== currentChecklistData.tag : false; + checklistBody = await GithubUtils.generateStagingDeployCashBody( newTag, _.pluck(PRList, 'url'), _.pluck(_.where(PRList, {isVerified: true}), 'url'), _.pluck(deployBlockers, 'url'), _.pluck(_.where(deployBlockers, {isResolved: true}), 'url'), - _.pluck(_.where(internalQAPRList, {isResolved: true}), 'url'), - didVersionChange ? false : currentStagingDeployCashData.isTimingDashboardChecked, - didVersionChange ? false : currentStagingDeployCashData.isFirebaseChecked, - didVersionChange ? false : currentStagingDeployCashData.isGHStatusChecked, + _.pluck(_.where(currentChecklistData.internalQAPRList, {isResolved: true}), 'url'), + didVersionChange ? false : currentChecklistData.isTimingDashboardChecked, + didVersionChange ? false : currentChecklistData.isFirebaseChecked, + didVersionChange ? false : currentChecklistData.isGHStatusChecked, ); - }) - .then((body) => { - const defaultPayload = { - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - body, - }; + } - if (shouldCreateNewStagingDeployCash) { - return GithubUtils.octokit.issues.create({ - ...defaultPayload, - title: `Deploy Checklist: New Expensify ${moment().format('YYYY-MM-DD')}`, - labels: [CONST.LABELS.STAGING_DEPLOY], - assignees: [CONST.APPLAUSE_BOT], - }); - } + // Finally, create or update the checklist + const defaultPayload = { + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + body: checklistBody, + }; - return GithubUtils.octokit.issues.update({ + if (shouldCreateNewDeployChecklist) { + const {data: newChecklist} = await GithubUtils.octokit.issues.create({ ...defaultPayload, - issue_number: currentStagingDeployCashData.number, + title: `Deploy Checklist: New Expensify ${moment().format('YYYY-MM-DD')}`, + labels: [CONST.LABELS.STAGING_DEPLOY], + assignees: [CONST.APPLAUSE_BOT], }); - }) - .then(({data}) => { - // eslint-disable-next-line max-len - console.log(`Successfully ${shouldCreateNewStagingDeployCash ? 'created new' : 'updated'} StagingDeployCash! 🎉 ${data.html_url}`); - return data; - }) - .catch((err) => { - console.error('An unknown error occurred!', err); - core.setFailed(err); + console.log(`Successfully created new StagingDeployCash! 🎉 ${newChecklist.html_url}`); + return newChecklist; + } + + const {data: updatedChecklist} = await GithubUtils.octokit.issues.update({ + ...defaultPayload, + issue_number: currentChecklistData.number, }); + console.log(`Successfully updated StagingDeployCash! 🎉 ${updatedChecklist.html_url}`); + return updatedChecklist; + } catch (err) { + console.error('An unknown error occurred!', err); + core.setFailed(err); + } }; if (require.main === module) { diff --git a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js index d774a73eb23c..2313925146d1 100644 --- a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js +++ b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js @@ -15,166 +15,126 @@ const CONST = __nccwpck_require__(4097); const GithubUtils = __nccwpck_require__(7999); const GitUtils = __nccwpck_require__(669); -const run = function () { +const run = async function () { const newVersion = core.getInput('NPM_VERSION'); console.log('New version found from action input:', newVersion); - let shouldCreateNewStagingDeployCash = false; - let newTag = newVersion; - let newDeployBlockers = []; - let previousStagingDeployCashData = {}; - let currentStagingDeployCashData = null; - - // Start by fetching the list of recent StagingDeployCash issues, along with the list of open deploy blockers - return Promise.all([ - GithubUtils.octokit.issues.listForRepo({ + try { + // Start by fetching the list of recent StagingDeployCash issues, along with the list of open deploy blockers + const {data: recentDeployChecklists} = await GithubUtils.octokit.issues.listForRepo({ log: console, owner: CONST.GITHUB_OWNER, repo: CONST.APP_REPO, labels: CONST.LABELS.STAGING_DEPLOY, state: 'all', - }), - GithubUtils.octokit.issues.listForRepo({ - log: console, - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - labels: CONST.LABELS.DEPLOY_BLOCKER, - }), - ]) - .then(([stagingDeployResponse, deployBlockerResponse]) => { - if (!stagingDeployResponse || !stagingDeployResponse.data || _.isEmpty(stagingDeployResponse.data)) { - console.error('Failed fetching StagingDeployCash issues from Github!', stagingDeployResponse); - throw new Error('Failed fetching StagingDeployCash issues from Github'); - } - - if (!deployBlockerResponse || !deployBlockerResponse.data) { - console.log('Failed fetching DeployBlockerCash issues from Github, continuing...'); - } - - newDeployBlockers = _.map(deployBlockerResponse.data, ({html_url}) => ({ - url: html_url, - number: GithubUtils.getIssueOrPullRequestNumberFromURL(html_url), - isResolved: false, - })); - - // Look at the state of the most recent StagingDeployCash, - // if it is open then we'll update the existing one, otherwise, we'll create a new one. - shouldCreateNewStagingDeployCash = Boolean(stagingDeployResponse.data[0].state !== 'open'); - if (shouldCreateNewStagingDeployCash) { - console.log('Latest StagingDeployCash is closed, creating a new one.', stagingDeployResponse.data[0]); - } else { - console.log( - 'Latest StagingDeployCash is open, updating it instead of creating a new one.', - 'Current:', - stagingDeployResponse.data[0], - 'Previous:', - stagingDeployResponse.data[1], - ); - } - - // Parse the data from the previous StagingDeployCash - // (newest if there are none open, otherwise second-newest) - previousStagingDeployCashData = shouldCreateNewStagingDeployCash - ? GithubUtils.getStagingDeployCashData(stagingDeployResponse.data[0]) - : GithubUtils.getStagingDeployCashData(stagingDeployResponse.data[1]); - - console.log('Found tag of previous StagingDeployCash:', previousStagingDeployCashData.tag); - - // Find the list of PRs merged between the last StagingDeployCash and the new version - if (shouldCreateNewStagingDeployCash) { - return GitUtils.getPullRequestsMergedBetween(previousStagingDeployCashData.tag, newTag); - } - - currentStagingDeployCashData = GithubUtils.getStagingDeployCashData(stagingDeployResponse.data[0]); - console.log('Parsed the following data from the current StagingDeployCash:', currentStagingDeployCashData); + }); - // If we aren't sent a tag, then use the existing tag - newTag = newTag || currentStagingDeployCashData.tag; + // Look at the state of the most recent StagingDeployCash, + // if it is open then we'll update the existing one, otherwise, we'll create a new one. + const mostRecentChecklist = recentDeployChecklists[0]; + const shouldCreateNewDeployChecklist = mostRecentChecklist.state !== 'open'; + const previousChecklist = shouldCreateNewDeployChecklist ? mostRecentChecklist : recentDeployChecklists[1]; + if (shouldCreateNewDeployChecklist) { + console.log('Latest StagingDeployCash is closed, creating a new one.', mostRecentChecklist); + } else { + console.log('Latest StagingDeployCash is open, updating it instead of creating a new one.', 'Current:', mostRecentChecklist, 'Previous:', previousChecklist); + } - return GitUtils.getPullRequestsMergedBetween(previousStagingDeployCashData.tag, newTag); - }) - .then((mergedPRs) => { - console.log(`The following PRs have been merged between the previous StagingDeployCash (${previousStagingDeployCashData.tag}) and new version (${newVersion}):`, mergedPRs); + // Parse the data from the previous and current checklists into the format used to generate the checklist + const previousChecklistData = GithubUtils.getStagingDeployCashData(previousChecklist); + const currentChecklistData = shouldCreateNewDeployChecklist ? {} : GithubUtils.getStagingDeployCashData(mostRecentChecklist); - if (shouldCreateNewStagingDeployCash) { - return GithubUtils.generateStagingDeployCashBody(newTag, _.map(mergedPRs, GithubUtils.getPullRequestURLFromNumber)); - } + // Find the list of PRs merged between the current checklist and the previous checklist + // Note that any time we're creating a new checklist we MUST have `NPM_VERSION` passed in as an input + const newTag = newVersion || _.get(currentChecklistData, 'tag'); + const mergedPRs = await GitUtils.getPullRequestsMergedBetween(previousChecklistData.tag, newTag); - const didVersionChange = newVersion ? newVersion !== currentStagingDeployCashData.tag : false; - - // Generate the PR list, preserving the previous state of `isVerified` for existing PRs - const PRList = _.sortBy( - _.unique( - _.union( - currentStagingDeployCashData.PRList, - _.map(mergedPRs, (number) => ({ - number: Number.parseInt(number, 10), - url: GithubUtils.getPullRequestURLFromNumber(number), - - // Since this is the second argument to _.union, - // it will appear later in the array than any duplicate. - // Since it is later in the array, it will be truncated by _.unique, - // and the original value of isVerified will be preserved. - isVerified: false, - })), - ), - false, - (item) => item.number, - ), - 'number', + // Next, we generate the checklist body + let checklistBody = ''; + if (shouldCreateNewDeployChecklist) { + checklistBody = await GithubUtils.generateStagingDeployCashBody(newTag, _.map(mergedPRs, GithubUtils.getPullRequestURLFromNumber)); + } else { + // Generate the updated PR list, preserving the previous state of `isVerified` for existing PRs + const PRList = _.reduce( + mergedPRs, + (memo, prNum) => { + const indexOfPRInCurrentChecklist = _.findIndex(currentChecklistData.PRList, (pr) => pr.number === prNum); + const isVerified = indexOfPRInCurrentChecklist >= 0 ? currentChecklistData.PRList[indexOfPRInCurrentChecklist].isVerified : false; + memo.push({ + number: prNum, + url: GithubUtils.getPullRequestURLFromNumber(prNum), + isVerified, + }); + return memo; + }, + [], ); // Generate the deploy blocker list, preserving the previous state of `isResolved` - const deployBlockers = _.sortBy( - _.unique(_.union(currentStagingDeployCashData.deployBlockers, newDeployBlockers), false, (item) => item.number), - 'number', + const {data: openDeployBlockers} = await GithubUtils.octokit.issues.listForRepo({ + log: console, + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + labels: CONST.LABELS.DEPLOY_BLOCKER, + }); + const deployBlockers = _.reduce( + openDeployBlockers, + (memo, deployBlocker) => { + const {html_url, number} = deployBlocker; + const indexInCurrentChecklist = _.findIndex(currentChecklistData.deployBlockers, (item) => item.number === number); + const isResolved = indexInCurrentChecklist >= 0 ? currentChecklistData.deployBlockers[indexInCurrentChecklist].isResolved : false; + memo.push({ + number, + url: html_url, + isResolved, + }); + return memo; + }, + [], ); - // Get the internalQA PR list, preserving the previous state of `isResolved` - const internalQAPRList = _.sortBy(currentStagingDeployCashData.internalQAPRList, 'number'); - - return GithubUtils.generateStagingDeployCashBody( + const didVersionChange = newVersion ? newVersion !== currentChecklistData.tag : false; + checklistBody = await GithubUtils.generateStagingDeployCashBody( newTag, _.pluck(PRList, 'url'), _.pluck(_.where(PRList, {isVerified: true}), 'url'), _.pluck(deployBlockers, 'url'), _.pluck(_.where(deployBlockers, {isResolved: true}), 'url'), - _.pluck(_.where(internalQAPRList, {isResolved: true}), 'url'), - didVersionChange ? false : currentStagingDeployCashData.isTimingDashboardChecked, - didVersionChange ? false : currentStagingDeployCashData.isFirebaseChecked, - didVersionChange ? false : currentStagingDeployCashData.isGHStatusChecked, + _.pluck(_.where(currentChecklistData.internalQAPRList, {isResolved: true}), 'url'), + didVersionChange ? false : currentChecklistData.isTimingDashboardChecked, + didVersionChange ? false : currentChecklistData.isFirebaseChecked, + didVersionChange ? false : currentChecklistData.isGHStatusChecked, ); - }) - .then((body) => { - const defaultPayload = { - owner: CONST.GITHUB_OWNER, - repo: CONST.APP_REPO, - body, - }; + } - if (shouldCreateNewStagingDeployCash) { - return GithubUtils.octokit.issues.create({ - ...defaultPayload, - title: `Deploy Checklist: New Expensify ${moment().format('YYYY-MM-DD')}`, - labels: [CONST.LABELS.STAGING_DEPLOY], - assignees: [CONST.APPLAUSE_BOT], - }); - } + // Finally, create or update the checklist + const defaultPayload = { + owner: CONST.GITHUB_OWNER, + repo: CONST.APP_REPO, + body: checklistBody, + }; - return GithubUtils.octokit.issues.update({ + if (shouldCreateNewDeployChecklist) { + const {data: newChecklist} = await GithubUtils.octokit.issues.create({ ...defaultPayload, - issue_number: currentStagingDeployCashData.number, + title: `Deploy Checklist: New Expensify ${moment().format('YYYY-MM-DD')}`, + labels: [CONST.LABELS.STAGING_DEPLOY], + assignees: [CONST.APPLAUSE_BOT], }); - }) - .then(({data}) => { - // eslint-disable-next-line max-len - console.log(`Successfully ${shouldCreateNewStagingDeployCash ? 'created new' : 'updated'} StagingDeployCash! 🎉 ${data.html_url}`); - return data; - }) - .catch((err) => { - console.error('An unknown error occurred!', err); - core.setFailed(err); + console.log(`Successfully created new StagingDeployCash! 🎉 ${newChecklist.html_url}`); + return newChecklist; + } + + const {data: updatedChecklist} = await GithubUtils.octokit.issues.update({ + ...defaultPayload, + issue_number: currentChecklistData.number, }); + console.log(`Successfully updated StagingDeployCash! 🎉 ${updatedChecklist.html_url}`); + return updatedChecklist; + } catch (err) { + console.error('An unknown error occurred!', err); + core.setFailed(err); + } }; if (require.main === require.cache[eval('__filename')]) { @@ -327,16 +287,17 @@ function getValidMergedPRs(commits) { * * @param {String} fromTag * @param {String} toTag - * @returns {Promise>} – Pull request numbers + * @returns {Promise>} – Pull request numbers */ function getPullRequestsMergedBetween(fromTag, toTag) { + console.log(`Looking for commits made between ${fromTag} and ${toTag}...`); return getCommitHistoryAsJSON(fromTag, toTag).then((commitList) => { console.log(`Commits made between ${fromTag} and ${toTag}:`, commitList); // Find which commit messages correspond to merged PR's const pullRequestNumbers = getValidMergedPRs(commitList); console.log(`List of pull requests merged between ${fromTag} and ${toTag}`, pullRequestNumbers); - return pullRequestNumbers; + return _.map(pullRequestNumbers, (prNum) => Number.parseInt(prNum, 10)); }); } diff --git a/.github/actions/javascript/getDeployPullRequestList/index.js b/.github/actions/javascript/getDeployPullRequestList/index.js index 01e8f166b397..e1c8dfdabcae 100644 --- a/.github/actions/javascript/getDeployPullRequestList/index.js +++ b/.github/actions/javascript/getDeployPullRequestList/index.js @@ -261,16 +261,17 @@ function getValidMergedPRs(commits) { * * @param {String} fromTag * @param {String} toTag - * @returns {Promise>} – Pull request numbers + * @returns {Promise>} – Pull request numbers */ function getPullRequestsMergedBetween(fromTag, toTag) { + console.log(`Looking for commits made between ${fromTag} and ${toTag}...`); return getCommitHistoryAsJSON(fromTag, toTag).then((commitList) => { console.log(`Commits made between ${fromTag} and ${toTag}:`, commitList); // Find which commit messages correspond to merged PR's const pullRequestNumbers = getValidMergedPRs(commitList); console.log(`List of pull requests merged between ${fromTag} and ${toTag}`, pullRequestNumbers); - return pullRequestNumbers; + return _.map(pullRequestNumbers, (prNum) => Number.parseInt(prNum, 10)); }); } diff --git a/.github/libs/GitUtils.js b/.github/libs/GitUtils.js index 979121bfbed7..b2f080df07b1 100644 --- a/.github/libs/GitUtils.js +++ b/.github/libs/GitUtils.js @@ -113,16 +113,17 @@ function getValidMergedPRs(commits) { * * @param {String} fromTag * @param {String} toTag - * @returns {Promise>} – Pull request numbers + * @returns {Promise>} – Pull request numbers */ function getPullRequestsMergedBetween(fromTag, toTag) { + console.log(`Looking for commits made between ${fromTag} and ${toTag}...`); return getCommitHistoryAsJSON(fromTag, toTag).then((commitList) => { console.log(`Commits made between ${fromTag} and ${toTag}:`, commitList); // Find which commit messages correspond to merged PR's const pullRequestNumbers = getValidMergedPRs(commitList); console.log(`List of pull requests merged between ${fromTag} and ${toTag}`, pullRequestNumbers); - return pullRequestNumbers; + return _.map(pullRequestNumbers, (prNum) => Number.parseInt(prNum, 10)); }); } diff --git a/tests/unit/createOrUpdateStagingDeployTest.js b/tests/unit/createOrUpdateStagingDeployTest.js index 679653fb2822..9e1b9f23af70 100644 --- a/tests/unit/createOrUpdateStagingDeployTest.js +++ b/tests/unit/createOrUpdateStagingDeployTest.js @@ -94,8 +94,6 @@ const basePRList = [ 'https://github.com/Expensify/App/pull/8', 'https://github.com/Expensify/App/pull/9', 'https://github.com/Expensify/App/pull/10', - 'https://github.com/Expensify/App/issues/11', - 'https://github.com/Expensify/App/issues/12', ]; const baseIssueList = ['https://github.com/Expensify/App/issues/11', 'https://github.com/Expensify/App/issues/12']; @@ -138,7 +136,7 @@ describe('createOrUpdateStagingDeployCash', () => { `${lineBreakDouble}${ccApplauseLeads}`, }; - const baseNewPullRequests = ['6', '7', '8']; + const baseNewPullRequests = [6, 7, 8]; test('creates new issue when there is none open', () => { mockGetInput.mockImplementation((arg) => { @@ -220,13 +218,13 @@ describe('createOrUpdateStagingDeployCash', () => { labels: [LABELS.DEPLOY_BLOCKER_CASH], }, { - html_url: 'https://github.com/Expensify/App/issues/9', + html_url: 'https://github.com/Expensify/App/pull/9', number: 9, state: 'open', labels: [LABELS.DEPLOY_BLOCKER_CASH], }, { - html_url: 'https://github.com/Expensify/App/issues/10', + html_url: 'https://github.com/Expensify/App/pull/10', number: 10, state: 'closed', labels: [LABELS.DEPLOY_BLOCKER_CASH], @@ -245,7 +243,7 @@ describe('createOrUpdateStagingDeployCash', () => { }); // New pull requests to add to open StagingDeployCash - const newPullRequests = ['9', '10']; + const newPullRequests = [9, 10]; mockGetPullRequestsMergedBetween.mockImplementation((fromRef, toRef) => { if (fromRef === '1.0.1-0' && toRef === '1.0.2-2') { return [...baseNewPullRequests, ...newPullRequests]; @@ -300,8 +298,8 @@ describe('createOrUpdateStagingDeployCash', () => { `${lineBreak}${openCheckbox}${basePRList[5]}` + `${lineBreak}${openCheckbox}${basePRList[8]}` + `${lineBreak}${closedCheckbox}${basePRList[9]}` + - `${lineBreak}${openCheckbox}${basePRList[10]}` + - `${lineBreak}${openCheckbox}${basePRList[11]}${lineBreak}` + + `${lineBreak}${openCheckbox}${baseIssueList[0]}` + + `${lineBreak}${openCheckbox}${baseIssueList[1]}${lineBreak}` + `${lineBreakDouble}${deployerVerificationsHeader}` + // Note: these will be unchecked with a new app version, and that's intentional `${lineBreak}${openCheckbox}${timingDashboardVerification}` + @@ -320,7 +318,7 @@ describe('createOrUpdateStagingDeployCash', () => { return 'fake_token'; }); mockGetPullRequestsMergedBetween.mockImplementation((fromRef, toRef) => { - if (fromRef === '1.0.1-0' && toRef === '1.0.2-2') { + if (fromRef === '1.0.1-0' && toRef === '1.0.2-1') { return [...baseNewPullRequests]; } return []; From 35bec3545c68248c1bf0f2718634eca9b6d2319c Mon Sep 17 00:00:00 2001 From: rory Date: Wed, 30 Aug 2023 15:59:58 +0200 Subject: [PATCH 038/134] Run createOrUpdateStagingDeploy after platformDeploy completes --- .github/workflows/finishReleaseCycle.yml | 28 ----------------------- .github/workflows/platformDeploy.yml | 29 ++++++++++++++++++++++++ .github/workflows/preDeploy.yml | 19 ---------------- 3 files changed, 29 insertions(+), 47 deletions(-) diff --git a/.github/workflows/finishReleaseCycle.yml b/.github/workflows/finishReleaseCycle.yml index b78a5fac4b69..7b71f6263c88 100644 --- a/.github/workflows/finishReleaseCycle.yml +++ b/.github/workflows/finishReleaseCycle.yml @@ -119,31 +119,3 @@ jobs: uses: Expensify/App/.github/actions/composite/announceFailedWorkflowInSlack@main with: SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} - - # Create a new StagingDeployCash for the next release cycle. - createNewStagingDeployCash: - runs-on: ubuntu-latest - needs: [updateStaging, createNewPatchVersion] - steps: - - uses: actions/checkout@v3 - with: - ref: staging - token: ${{ secrets.OS_BOTIFY_TOKEN }} - - # Create a local git tag so that GitUtils.getPullRequestsMergedBetween can use `git log` to generate a - # list of pull requests that were merged between this version tag and another. - # NOTE: This tag is only used locally and shouldn't be pushed to the remote. - # If it was pushed, that would trigger the staging deploy which is handled in a separate workflow (deploy.yml) - - name: Tag version - run: git tag ${{ needs.createNewPatchVersion.outputs.NEW_VERSION }} - - - name: Create new StagingDeployCash - uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main - with: - GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} - NPM_VERSION: ${{ needs.createNewPatchVersion.outputs.NEW_VERSION }} - - - if: ${{ failure() }} - uses: Expensify/App/.github/actions/composite/announceFailedWorkflowInSlack@main - with: - SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} diff --git a/.github/workflows/platformDeploy.yml b/.github/workflows/platformDeploy.yml index 84f8373ff247..b50a14dc9ca1 100644 --- a/.github/workflows/platformDeploy.yml +++ b/.github/workflows/platformDeploy.yml @@ -387,3 +387,32 @@ jobs: DESKTOP: ${{ needs.desktop.result }} IOS: ${{ needs.iOS.result }} WEB: ${{ needs.web.result }} + + deployChecklist: + name: Create or update deploy checklist + runs-on: ubuntu-latest + if: ${{ always() }} + needs: [android, desktop, iOS, web] + steps: + - name: Quit early if all platforms failed + run: | + if [[ ${{ needs.android.result }} != 'success' && \ + ${{ needs.desktop.result }} != 'success' && \ + ${{ needs.iOS.result }} != 'success' && \ + ${{ needs.web.result }} != 'success' ]]; then + echo 'Deploy failed on all platforms, not updating the checklist...' + exit 1 + fi + + - uses: actions/checkout@v3 + + - uses: Expensify/App/.github/actions/composite/setupNode@main + + - name: Set version + run: echo "VERSION=$(npm run print-version --silent)" >> "$GITHUB_ENV" + + - name: Create or update staging deploy + uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main + with: + GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} + NPM_VERSION: ${{ needs.createNewVersion.outputs.NEW_VERSION }} diff --git a/.github/workflows/preDeploy.yml b/.github/workflows/preDeploy.yml index c9fb636238aa..e3977734fc50 100644 --- a/.github/workflows/preDeploy.yml +++ b/.github/workflows/preDeploy.yml @@ -98,25 +98,6 @@ jobs: # Force-update the remote staging branch git push --force origin staging - # Create a local git tag on staging so that GitUtils.getPullRequestsMergedBetween can use `git log` to generate a - # list of pull requests that were merged between this version tag and another. - # NOTE: This tag is only used locally and shouldn't be pushed to the remote. - # If it was pushed, that would trigger the staging deploy which is handled in a separate workflow (deploy.yml) - - name: Tag staging - run: git tag ${{ needs.createNewVersion.outputs.NEW_VERSION }} - - - name: Update StagingDeployCash - uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main - with: - GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} - NPM_VERSION: ${{ needs.createNewVersion.outputs.NEW_VERSION }} - - - name: Find open StagingDeployCash - id: getStagingDeployCash - run: echo "STAGING_DEPLOY_CASH=$(gh issue list --label StagingDeployCash --json number --jq '.[0].number')" >> "$GITHUB_OUTPUT" - env: - GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} - - if: ${{ failure() }} uses: Expensify/App/.github/actions/composite/announceFailedWorkflowInSlack@main with: From f6a6383de6c082c6f1f1221823af898a9dd8c22a Mon Sep 17 00:00:00 2001 From: rory Date: Wed, 30 Aug 2023 16:11:23 +0200 Subject: [PATCH 039/134] getPullRequestsBetween now returns an array of numbers --- .../getReleaseBody/getReleaseBody.js | 2 +- .../markPullRequestsAsDeployed.js | 1 - .github/libs/GitUtils.js | 5 +--- tests/unit/CIGitLogicTest.sh | 26 +++++++++---------- 4 files changed, 15 insertions(+), 19 deletions(-) diff --git a/.github/actions/javascript/getReleaseBody/getReleaseBody.js b/.github/actions/javascript/getReleaseBody/getReleaseBody.js index d0b1b4af34c5..fc5df102506f 100644 --- a/.github/actions/javascript/getReleaseBody/getReleaseBody.js +++ b/.github/actions/javascript/getReleaseBody/getReleaseBody.js @@ -4,7 +4,7 @@ const ActionUtils = require('../../../libs/ActionUtils'); const GithubUtils = require('../../../libs/GithubUtils'); // Parse the stringified JSON array of PR numbers, and cast each from String -> Number -const PRList = _.map(ActionUtils.getJSONInput('PR_LIST', {required: true}), Number); +const PRList = ActionUtils.getJSONInput('PR_LIST', {required: true}); console.log(`Got PR list: ${PRList}`); const releaseBody = GithubUtils.getReleaseBody(PRList); diff --git a/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js b/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js index 865379ac83fb..f1339ffe78f4 100644 --- a/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js +++ b/.github/actions/javascript/markPullRequestsAsDeployed/markPullRequestsAsDeployed.js @@ -1,5 +1,4 @@ const _ = require('underscore'); -const lodashGet = require('lodash/get'); const core = require('@actions/core'); const {context} = require('@actions/github'); const CONST = require('../../../libs/CONST'); diff --git a/.github/libs/GitUtils.js b/.github/libs/GitUtils.js index b2f080df07b1..282e60c03143 100644 --- a/.github/libs/GitUtils.js +++ b/.github/libs/GitUtils.js @@ -22,10 +22,7 @@ function fetchTag(tag) { console.log(`Running command: ${command}`); execSync(command); } catch (e) { - // This can happen if the tag was only created locally but does not exist in the remote. In this case, we'll fetch history of the staging branch instead - const command = `git fetch origin staging --no-tags --shallow-exclude=${previousPatchVersion}`; - console.log(`Running command: ${command}`); - execSync(command); + console.error(e); } } diff --git a/tests/unit/CIGitLogicTest.sh b/tests/unit/CIGitLogicTest.sh index d79fa7a22c0c..6a045bcb13e0 100755 --- a/tests/unit/CIGitLogicTest.sh +++ b/tests/unit/CIGitLogicTest.sh @@ -212,7 +212,7 @@ tag_staging git switch main # Verify output for checklist and deploy comment -assert_prs_merged_between '1.0.0-0' '1.0.0-1' "[ '1' ]" +assert_prs_merged_between '1.0.0-0' '1.0.0-1' "[ 1 ]" success "Scenario #1 completed successfully!" @@ -241,10 +241,10 @@ cherry_pick_pr 3 tag_staging # Verify output for checklist -assert_prs_merged_between '1.0.0-0' '1.0.0-2' "[ '3', '1' ]" +assert_prs_merged_between '1.0.0-0' '1.0.0-2' "[ 3, 1 ]" # Verify output for deploy comment -assert_prs_merged_between '1.0.0-1' '1.0.0-2' "[ '3' ]" +assert_prs_merged_between '1.0.0-1' '1.0.0-2' "[ 3 ]" success "Scenario #3 completed successfully!" @@ -255,7 +255,7 @@ title "Scenario #4A: Run the production deploy" update_production_from_staging # Verify output for release body and production deploy comments -assert_prs_merged_between '1.0.0-0' '1.0.0-2' "[ '3', '1' ]" +assert_prs_merged_between '1.0.0-0' '1.0.0-2' "[ 3, 1 ]" success "Scenario #4A completed successfully!" @@ -266,7 +266,7 @@ update_staging_from_main tag_staging # Verify output for new checklist and staging deploy comments -assert_prs_merged_between '1.0.0-2' '1.0.1-0' "[ '2' ]" +assert_prs_merged_between '1.0.0-2' '1.0.1-0' "[ 2 ]" success "Scenario #4B completed successfully!" @@ -287,10 +287,10 @@ update_staging_from_main tag_staging # Verify output for checklist -assert_prs_merged_between '1.0.0-2' '1.0.1-1' "[ '5', '2' ]" +assert_prs_merged_between '1.0.0-2' '1.0.1-1' "[ 5, 2 ]" # Verify output for deploy comment -assert_prs_merged_between '1.0.1-0' '1.0.1-1' "[ '5' ]" +assert_prs_merged_between '1.0.1-0' '1.0.1-1' "[ 5 ]" success "Scenario #5 completed successfully!" @@ -310,10 +310,10 @@ update_staging_from_main tag_staging # Verify output for checklist -assert_prs_merged_between '1.0.0-2' '1.0.1-2' "[ '6', '5', '2' ]" +assert_prs_merged_between '1.0.0-2' '1.0.1-2' "[ 6, 5, 2 ]" # Verify output for deploy comment -assert_prs_merged_between '1.0.1-1' '1.0.1-2' "[ '6' ]" +assert_prs_merged_between '1.0.1-1' '1.0.1-2' "[ 6 ]" info "Appending and prepending content to myFile.txt in PR #7" setup_git_as_human @@ -332,10 +332,10 @@ update_staging_from_main tag_staging # Verify output for checklist -assert_prs_merged_between '1.0.0-2' '1.0.1-3' "[ '7', '6', '5', '2' ]" +assert_prs_merged_between '1.0.0-2' '1.0.1-3' "[ 7, 6, 5, 2 ]" # Verify output for deploy comment -assert_prs_merged_between '1.0.1-2' '1.0.1-3' "[ '7' ]" +assert_prs_merged_between '1.0.1-2' '1.0.1-3' "[ 7 ]" info "Making an unrelated change in PR #8" setup_git_as_human @@ -392,10 +392,10 @@ update_staging_from_main tag_staging # Verify production release list -assert_prs_merged_between '1.0.0-2' '1.0.1-4' "[ '9', '7', '6', '5', '2' ]" +assert_prs_merged_between '1.0.0-2' '1.0.1-4' "[ 9, 7, 6, 5, 2 ]" # Verify PR list for the new checklist -assert_prs_merged_between '1.0.1-4' '1.0.2-0' "[ '10', '8' ]" +assert_prs_merged_between '1.0.1-4' '1.0.2-0' "[ 10, 8 ]" ### Cleanup title "Cleaning up..." From 2bceea3987fe94a90d6b0e21a8ed3486bb80bd9b Mon Sep 17 00:00:00 2001 From: rory Date: Wed, 30 Aug 2023 16:18:03 +0200 Subject: [PATCH 040/134] Rebuild GH actions --- .../javascript/createOrUpdateStagingDeploy/index.js | 5 +---- .../actions/javascript/getDeployPullRequestList/index.js | 5 +---- .github/actions/javascript/getReleaseBody/index.js | 2 +- .../javascript/markPullRequestsAsDeployed/index.js | 9 ++++----- 4 files changed, 7 insertions(+), 14 deletions(-) diff --git a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js index 2313925146d1..914711264d4c 100644 --- a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js +++ b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js @@ -196,10 +196,7 @@ function fetchTag(tag) { console.log(`Running command: ${command}`); execSync(command); } catch (e) { - // This can happen if the tag was only created locally but does not exist in the remote. In this case, we'll fetch history of the staging branch instead - const command = `git fetch origin staging --no-tags --shallow-exclude=${previousPatchVersion}`; - console.log(`Running command: ${command}`); - execSync(command); + console.error(e); } } diff --git a/.github/actions/javascript/getDeployPullRequestList/index.js b/.github/actions/javascript/getDeployPullRequestList/index.js index e1c8dfdabcae..f1dc0c7b8dad 100644 --- a/.github/actions/javascript/getDeployPullRequestList/index.js +++ b/.github/actions/javascript/getDeployPullRequestList/index.js @@ -170,10 +170,7 @@ function fetchTag(tag) { console.log(`Running command: ${command}`); execSync(command); } catch (e) { - // This can happen if the tag was only created locally but does not exist in the remote. In this case, we'll fetch history of the staging branch instead - const command = `git fetch origin staging --no-tags --shallow-exclude=${previousPatchVersion}`; - console.log(`Running command: ${command}`); - execSync(command); + console.error(e); } } diff --git a/.github/actions/javascript/getReleaseBody/index.js b/.github/actions/javascript/getReleaseBody/index.js index c1cb5c473912..c2ed605a462a 100644 --- a/.github/actions/javascript/getReleaseBody/index.js +++ b/.github/actions/javascript/getReleaseBody/index.js @@ -14,7 +14,7 @@ const ActionUtils = __nccwpck_require__(970); const GithubUtils = __nccwpck_require__(7999); // Parse the stringified JSON array of PR numbers, and cast each from String -> Number -const PRList = _.map(ActionUtils.getJSONInput('PR_LIST', {required: true}), Number); +const PRList = ActionUtils.getJSONInput('PR_LIST', {required: true}); console.log(`Got PR list: ${PRList}`); const releaseBody = GithubUtils.getReleaseBody(PRList); diff --git a/.github/actions/javascript/markPullRequestsAsDeployed/index.js b/.github/actions/javascript/markPullRequestsAsDeployed/index.js index 1b353abcb054..bd71eeb51894 100644 --- a/.github/actions/javascript/markPullRequestsAsDeployed/index.js +++ b/.github/actions/javascript/markPullRequestsAsDeployed/index.js @@ -9,7 +9,6 @@ module.exports = /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const _ = __nccwpck_require__(2947); -const lodashGet = __nccwpck_require__(6908); const core = __nccwpck_require__(2186); const {context} = __nccwpck_require__(5438); const CONST = __nccwpck_require__(4097); @@ -8162,7 +8161,7 @@ var modules = [ __nccwpck_require__(9557), __nccwpck_require__(1155), __nccwpck_require__(1644), - __nccwpck_require__(373), + __nccwpck_require__(6657), __nccwpck_require__(1080), __nccwpck_require__(1012), __nccwpck_require__(9695), @@ -8386,7 +8385,7 @@ InternalDecoderCesu8.prototype.end = function() { /***/ }), -/***/ 373: +/***/ 6657: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { "use strict"; @@ -10446,7 +10445,7 @@ module.exports = Map; /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { var mapCacheClear = __nccwpck_require__(1610), - mapCacheDelete = __nccwpck_require__(6657), + mapCacheDelete = __nccwpck_require__(5991), mapCacheGet = __nccwpck_require__(1372), mapCacheHas = __nccwpck_require__(609), mapCacheSet = __nccwpck_require__(5582); @@ -11288,7 +11287,7 @@ module.exports = mapCacheClear; /***/ }), -/***/ 6657: +/***/ 5991: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { var getMapData = __nccwpck_require__(9980); From c2f3097941439015ebca802c3939ee7b44077a4f Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 30 Aug 2023 16:57:53 +0200 Subject: [PATCH 041/134] add onyxupdatemanager on tests --- tests/actions/IOUTest.js | 2 ++ tests/actions/ReportTest.js | 2 ++ tests/actions/SessionTest.js | 2 ++ 3 files changed, 6 insertions(+) diff --git a/tests/actions/IOUTest.js b/tests/actions/IOUTest.js index 6fbbe19cec8e..afb06cdb6fb3 100644 --- a/tests/actions/IOUTest.js +++ b/tests/actions/IOUTest.js @@ -9,6 +9,7 @@ import DateUtils from '../../src/libs/DateUtils'; import * as NumberUtils from '../../src/libs/NumberUtils'; import * as ReportActions from '../../src/libs/actions/ReportActions'; import * as Report from '../../src/libs/actions/Report'; +import OnyxUpdateManager from '../../src/libs/actions/OnyxUpdateManager'; const CARLOS_EMAIL = 'cmartins@expensifail.com'; const CARLOS_ACCOUNT_ID = 1; @@ -19,6 +20,7 @@ const RORY_ACCOUNT_ID = 3; const VIT_EMAIL = 'vit@expensifail.com'; const VIT_ACCOUNT_ID = 4; +OnyxUpdateManager(); describe('actions/IOU', () => { beforeAll(() => { Onyx.init({ diff --git a/tests/actions/ReportTest.js b/tests/actions/ReportTest.js index c06d3bc83766..978186fcf9c4 100644 --- a/tests/actions/ReportTest.js +++ b/tests/actions/ReportTest.js @@ -14,6 +14,7 @@ import * as PersistedRequests from '../../src/libs/actions/PersistedRequests'; import * as User from '../../src/libs/actions/User'; import * as ReportUtils from '../../src/libs/ReportUtils'; import DateUtils from '../../src/libs/DateUtils'; +import OnyxUpdateManager from '../../src/libs/actions/OnyxUpdateManager'; jest.mock('../../src/libs/actions/Report', () => { const originalModule = jest.requireActual('../../src/libs/actions/Report'); @@ -24,6 +25,7 @@ jest.mock('../../src/libs/actions/Report', () => { }; }); +OnyxUpdateManager(); describe('actions/Report', () => { beforeAll(() => { PusherHelper.setup(); diff --git a/tests/actions/SessionTest.js b/tests/actions/SessionTest.js index d8bfa144e358..59a7441679ea 100644 --- a/tests/actions/SessionTest.js +++ b/tests/actions/SessionTest.js @@ -7,6 +7,7 @@ import * as TestHelper from '../utils/TestHelper'; import CONST from '../../src/CONST'; import PushNotification from '../../src/libs/Notification/PushNotification'; import * as App from '../../src/libs/actions/App'; +import OnyxUpdateManager from '../../src/libs/actions/OnyxUpdateManager'; // This lib needs to be imported, but it has nothing to export since all it contains is an Onyx connection // eslint-disable-next-line no-unused-vars @@ -24,6 +25,7 @@ Onyx.init({ registerStorageEventListener: () => {}, }); +OnyxUpdateManager(); beforeEach(() => Onyx.clear().then(waitForPromisesToResolve)); describe('Session', () => { From 57874c757bc92154e4147ddfb5ad4d4ad196ad91 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 30 Aug 2023 17:00:07 +0200 Subject: [PATCH 042/134] adding additional checks for early return --- src/libs/Middleware/SaveResponseInOnyx.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 13244dd64e36..448574af8101 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -28,9 +28,9 @@ function SaveResponseInOnyx(response, request) { // Supports both the old format and the new format const onyxUpdates = _.isArray(responseData) ? responseData : responseData.onyxData; - // Sometimes we call requests that are successfull but they don't have any response. Let's return early since + // Sometimes we call requests that are successfull but they don't have any response or any success/failure data to set. Let's return early since // we don't need to store anything here. - if (!onyxUpdates) { + if (!onyxUpdates && !request.successData && !request.failureData) { return; } From 4cf1934c1d00cd2fc2032f517f4b31ec8ff2df9b Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 30 Aug 2023 19:18:58 +0200 Subject: [PATCH 043/134] adding onyx update manager to Network tests --- tests/unit/NetworkTest.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/unit/NetworkTest.js b/tests/unit/NetworkTest.js index c8dcda0e2af5..0b577dc82469 100644 --- a/tests/unit/NetworkTest.js +++ b/tests/unit/NetworkTest.js @@ -14,6 +14,7 @@ import Log from '../../src/libs/Log'; import * as MainQueue from '../../src/libs/Network/MainQueue'; import * as App from '../../src/libs/actions/App'; import NetworkConnection from '../../src/libs/NetworkConnection'; +import OnyxUpdateManager from '../../src/libs/actions/OnyxUpdateManager'; jest.mock('../../src/libs/Log'); jest.useFakeTimers(); @@ -21,7 +22,7 @@ jest.useFakeTimers(); Onyx.init({ keys: ONYXKEYS, }); - +OnyxUpdateManager(); const originalXHR = HttpUtils.xhr; beforeEach(() => { From 64e006c0cf7c4f7eff875111ed518bb3fc033429 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 30 Aug 2023 19:21:31 +0200 Subject: [PATCH 044/134] adding space for style --- tests/unit/NetworkTest.js | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/unit/NetworkTest.js b/tests/unit/NetworkTest.js index 0b577dc82469..7d8c4f23197c 100644 --- a/tests/unit/NetworkTest.js +++ b/tests/unit/NetworkTest.js @@ -22,6 +22,7 @@ jest.useFakeTimers(); Onyx.init({ keys: ONYXKEYS, }); + OnyxUpdateManager(); const originalXHR = HttpUtils.xhr; From 6ca99584ec8dd0df568570272dcc22df753735c5 Mon Sep 17 00:00:00 2001 From: DylanDylann Date: Thu, 31 Aug 2023 09:41:02 +0700 Subject: [PATCH 045/134] fix incorrect when inviting existing member --- src/pages/workspace/WorkspaceInvitePage.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/workspace/WorkspaceInvitePage.js b/src/pages/workspace/WorkspaceInvitePage.js index 6db3a20a3e4a..b7a1986c06e6 100644 --- a/src/pages/workspace/WorkspaceInvitePage.js +++ b/src/pages/workspace/WorkspaceInvitePage.js @@ -186,7 +186,7 @@ function WorkspaceInvitePage(props) { ); const headerMessage = useMemo(() => { - const searchValue = searchTerm.trim(); + const searchValue = searchTerm.trim().toLowerCase(); if (!userToInvite && CONST.EXPENSIFY_EMAILS.includes(searchValue)) { return translate('messages.errorMessageInvalidEmail'); } From 0665ea020b6f1bd5cc87a3fcbb48e4a5a8ef2df6 Mon Sep 17 00:00:00 2001 From: Pierre Michel Date: Thu, 31 Aug 2023 04:58:15 -0600 Subject: [PATCH 046/134] Add withCurrentReportIDPropTypes and use the prop currentReportID instead of calling getTopmostReportId Signed-off-by: Pierre Michel --- src/pages/home/ReportScreen.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/pages/home/ReportScreen.js b/src/pages/home/ReportScreen.js index 5ef8011c0aeb..5d0cb5ab9bf6 100644 --- a/src/pages/home/ReportScreen.js +++ b/src/pages/home/ReportScreen.js @@ -37,7 +37,7 @@ import ReportScreenContext from './ReportScreenContext'; import TaskHeaderActionButton from '../../components/TaskHeaderActionButton'; import DragAndDropProvider from '../../components/DragAndDrop/Provider'; import usePrevious from '../../hooks/usePrevious'; -import withCurrentReportID from '../../components/withCurrentReportID'; +import withCurrentReportID, {withCurrentReportIDPropTypes, withCurrentReportIDDefaultProps} from '../../components/withCurrentReportID'; const propTypes = { /** Navigation route context info provided by react navigation */ @@ -89,6 +89,7 @@ const propTypes = { ...windowDimensionsPropTypes, ...viewportOffsetTopPropTypes, + ...withCurrentReportIDPropTypes, }; const defaultProps = { @@ -103,6 +104,7 @@ const defaultProps = { policies: {}, accountManagerReportID: null, personalDetails: {}, + ...withCurrentReportIDDefaultProps, }; /** @@ -132,6 +134,7 @@ function ReportScreen({ viewportOffsetTop, isComposerFullSize, errors, + currentReportID, }) { const firstRenderRef = useRef(true); const flatListRef = useRef(); @@ -158,7 +161,7 @@ function ReportScreen({ const policy = policies[`${ONYXKEYS.COLLECTION.POLICY}${report.policyID}`]; - const isTopMostReportId = Navigation.getTopmostReportId() === getReportID(route); + const isTopMostReportId = currentReportID === getReportID(route); let headerView = ( Date: Fri, 1 Sep 2023 03:49:25 +0200 Subject: [PATCH 047/134] adding new method to return promise on reconnectApp --- src/libs/actions/App.js | 44 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index 56a313e81c0b..2e3185ea4d1b 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -207,6 +207,49 @@ function reconnectApp(updateIDFrom = 0) { }); } +/** + * Fetches data when the app will call reconnectApp without params for the last time. This is a separate function + * because it will follow patterns that are not recommended so we can be sure we're not putting the app in a unusable + * state because of race conditions between reconnectApp and other pusher updates being applied at the same time. + * @return {Promise} + */ +function lastReconnectAppAfterActivatingReliableUpdates() { + console.debug(`[OnyxUpdates] Executing last reconnect app with promise`); + return getPolicyParamsForOpenOrReconnect().then((policyParams) => { + const params = {...policyParams}; + + // When the app reconnects we do a fast "sync" of the LHN and only return chats that have new messages. We achieve this by sending the most recent reportActionID. + // we have locally. And then only update the user about chats with messages that have occurred after that reportActionID. + // + // - Look through the local report actions and reports to find the most recently modified report action or report. + // - We send this to the server so that it can compute which new chats the user needs to see and return only those as an optimization. + Timing.start(CONST.TIMING.CALCULATE_MOST_RECENT_LAST_MODIFIED_ACTION); + params.mostRecentReportActionLastModified = ReportActionsUtils.getMostRecentReportActionLastModified(); + Timing.end(CONST.TIMING.CALCULATE_MOST_RECENT_LAST_MODIFIED_ACTION, '', 500); + + // Include the update IDs when reconnecting so that the server can send incremental updates if they are available. + // Otherwise, a full set of app data will be returned. + if (updateIDFrom) { + params.updateIDFrom = updateIDFrom; + } + + // It is SUPER BAD FORM to return promises from action methods. + // DO NOT FOLLOW THIS PATTERN!!!!! + // It was absolutely necessary in order to not break the app while migrating to the new reliable updates pattern. This method will be removed + // as soon as we have everyone migrated to it + // eslint-disable-next-line rulesdir/no-api-side-effects-method + return API.makeRequestWithSideEffects( + 'ReconnectApp', + { + updateIDFrom, + updateIDTo, + }, + getOnyxDataForOpenOrReconnect(), + ); + }); + +} + /** * Fetches data when the client has discovered it missed some Onyx updates from the server * @param {Number} [updateIDFrom] the ID of the Onyx update that we want to start fetching from @@ -435,4 +478,5 @@ export { beginDeepLinkRedirectAfterTransition, createWorkspaceAndNavigateToIt, getMissingOnyxUpdates, + lastReconnectAppAfterActivatingReliableUpdates, }; From d5cc741047ab671767c6b1967685a083ed3fad70 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 03:49:46 +0200 Subject: [PATCH 048/134] adding usage to new method to reconnect app --- src/libs/actions/OnyxUpdateManager.js | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 97456d8d704f..c29c83b3885b 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -27,6 +27,7 @@ function applyHTTPSOnyxUpdates({request, responseData}) { console.debug('[OnyxUpdateManager] Applying https update'); // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in // the UI. See https://github.com/Expensify/App/issues/12775 for more info. + // 2023-08-31 - const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then @@ -105,11 +106,6 @@ export default () => { return; } - // Since people will have migrations hapening in their accounts while they use the app, we don't want to trigger - // a full ReconnectApp and then trigger a GetOnyxUpdates. Let's use this as a control variable until we enable - // the beta to all users. - let isUserGettingReliableUpdatesForTheVeryFirstTime = false; - const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; // This can happen when a user has just started getting reliable updates from the server but they haven't @@ -120,16 +116,13 @@ export default () => { !lastUpdateIDAppliedToClient && previousUpdateIDFromServer > 0 && (updateParams.type === CONST.ONYX_UPDATE_TYPES.PUSHER || - (updateParams.type === CONST.ONYX_UPDATE_TYPES.HTTPS && (updateParams.data.request.command !== 'OpenApp' || updateParams.data.request.command !== 'ReconnectApp'))) + (updateParams.type === CONST.ONYX_UPDATE_TYPES.HTTPS && updateParams.data.request.command !== 'OpenApp' && updateParams.data.request.command !== 'ReconnectApp')) ) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); - App.reconnectApp(); - isUserGettingReliableUpdatesForTheVeryFirstTime = true; - } - - // If the previous update from the server does not match the last update the client got, then the client is missing some updates. - // getMissingOnyxUpdates will fetch updates starting from the last update this client got and going to the last update the server sent. - if (!isUserGettingReliableUpdatesForTheVeryFirstTime && previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { + App.lastReconnectAppAfterActivatingReliableUpdates().finally(() => { + applyOnyxUpdates(updateParams); + }); + } else if (previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { lastUpdateIDFromServer, From c613170dfffd9afa6ef657740eb79a7e79560c6b Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 04:14:13 +0200 Subject: [PATCH 049/134] refactor the code a little bit --- src/libs/actions/OnyxUpdateManager.js | 80 +++++++++++++-------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index c29c83b3885b..46130467c86d 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -108,51 +108,51 @@ export default () => { const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; - // This can happen when a user has just started getting reliable updates from the server but they haven't - // had an OpenApp or ReconnectApp call yet. This can result in never getting reliable updates because - // lastUpdateIDAppliedToClient will always be null. For this case, reconnectApp() will be triggered for them - // to kick start the reliable updates. We also filter OpenApp and ReconnectApp so we don't create a loop. - if ( - !lastUpdateIDAppliedToClient && - previousUpdateIDFromServer > 0 && - (updateParams.type === CONST.ONYX_UPDATE_TYPES.PUSHER || - (updateParams.type === CONST.ONYX_UPDATE_TYPES.HTTPS && updateParams.data.request.command !== 'OpenApp' && updateParams.data.request.command !== 'ReconnectApp')) - ) { - console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); - App.lastReconnectAppAfterActivatingReliableUpdates().finally(() => { - applyOnyxUpdates(updateParams); - }); - } else if (previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { - console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); - Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { - lastUpdateIDFromServer, - previousUpdateIDFromServer, - lastUpdateIDAppliedToClient, - }); + // If we don't have a previousUpdateID from the request, or if we if it's the same as we currently have stored + // we can simply apply the updates and move on. + if (!previousUpdateIDFromServer || lastUpdateIDAppliedToClient === previousUpdateIDFromServer) { + console.debug(`[OnyxUpdateManager] Client is in sync with the server, applying updates`); + applyOnyxUpdates(updateParams); + } else { - // Pause the sequential queue while the missing Onyx updates are fetched from the server. This is important - // so that the updates are applied in their correct and specific order. If this queue was not paused, then - // there would be a lot of onyx data being applied while we are fetching the missing updates and that would - // put them all out of order. + // In cases where we received a previousUpdateID and it doesn't match our lastUpdateIDAppliedToClient + // we need to perform one of the 2 possible cases: + // + // 1. This is the first time we're receiving an lastUpdateID, so we need to do a final reconnectApp before + // fully migrating to the reliable updates mode; + // 2. This this client already has the reliable updates mode enabled, but it's missing some updates and it + // needs to fech those. + // + // To to both of those, we need to pause the sequential queue. This is important so that the updates are + // applied in their correct and specific order. If this queue was not paused, then there would be a lot of + // onyx data being applied while we are fetching the missing updates and that would put them all out of order. SequentialQueue.pause(); - App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).finally(() => { - console.debug('[OnyxUpdateManager] Done Getting missing onyx updates'); - - // The onyx update from the initial request could have been either from HTTPS or Pusher. - // Now that the missing onyx updates have been applied, we can apply the original onyxUpdates from - // the API request. - applyOnyxUpdates(updateParams).then(() => { - console.debug('[OnyxUpdateManager] Done applying all updates'); - - // Finally, the missing updates were applied, the original update was applied, and now the - // sequential queue is free to continue. - SequentialQueue.unpause(); + let promise; + + // The flow below is setting the promise to a reconnect app to address flow (1) explained above. + if (!lastUpdateIDAppliedToClient && + (updateParams.type === CONST.ONYX_UPDATE_TYPES.PUSHER || updateParams.data.request.command !== 'OpenApp' && updateParams.data.request.command !== 'ReconnectApp') + ) { + console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); + Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); + promise = App.lastReconnectAppAfterActivatingReliableUpdates(); + } else if (previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { + // The flow below is setting the promise to a getMissingOnyxUpdates to address flow (2) explained above. + console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); + Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { + lastUpdateIDFromServer, + previousUpdateIDFromServer, + lastUpdateIDAppliedToClient, }); + promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer); + } + + promise.finally(() => { + console.debug('[OnyxUpdateManager] Done applying all updates'); + applyOnyxUpdates(updateParams); + SequentialQueue.unpause(); }); - } else { - console.debug(`[OnyxUpdateManager] Client is in sync with the server`); - applyOnyxUpdates(updateParams); } if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { From 377cb9353cac64e9e714b516ca08b84cb233c50c Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 04:14:30 +0200 Subject: [PATCH 050/134] adding a few more checks and refactoring --- src/libs/actions/OnyxUpdateManager.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 46130467c86d..0b952cad9ef5 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -108,13 +108,14 @@ export default () => { const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; - // If we don't have a previousUpdateID from the request, or if we if it's the same as we currently have stored + // If we don't have a previousUpdateID from the request, or if we if it's the less or equal w we currently have stored // we can simply apply the updates and move on. if (!previousUpdateIDFromServer || lastUpdateIDAppliedToClient === previousUpdateIDFromServer) { console.debug(`[OnyxUpdateManager] Client is in sync with the server, applying updates`); applyOnyxUpdates(updateParams); + } else if (lastUpdateIDFromServer < lastUpdateIDAppliedToClient) { + console.debug(`[OnyxUpdateManager] Client is more up to date than the update received, skipping processing`); } else { - // In cases where we received a previousUpdateID and it doesn't match our lastUpdateIDAppliedToClient // we need to perform one of the 2 possible cases: // @@ -127,7 +128,6 @@ export default () => { // applied in their correct and specific order. If this queue was not paused, then there would be a lot of // onyx data being applied while we are fetching the missing updates and that would put them all out of order. SequentialQueue.pause(); - let promise; // The flow below is setting the promise to a reconnect app to address flow (1) explained above. @@ -137,7 +137,7 @@ export default () => { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); promise = App.lastReconnectAppAfterActivatingReliableUpdates(); - } else if (previousUpdateIDFromServer && lastUpdateIDAppliedToClient < previousUpdateIDFromServer) { + } else { // The flow below is setting the promise to a getMissingOnyxUpdates to address flow (2) explained above. console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { From df82f2efdb04e0e32215791f2a06173bdfbb65ae Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 04:21:09 +0200 Subject: [PATCH 051/134] adding check if queue is paused before moving on with applying queued onyx updates --- src/libs/Network/SequentialQueue.js | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index f8ea396663a5..4894456fa789 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -94,7 +94,7 @@ function flush() { isSequentialQueueRunning = false; resolveIsReadyPromise(); currentRequest = null; - Onyx.update(QueuedOnyxUpdates.getQueuedUpdates()).then(QueuedOnyxUpdates.clear); + flushAndClearOnyxQueue(); }); }, }); @@ -149,6 +149,17 @@ function waitForIdle() { return isReadyPromise; } + +/** + * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. + */ +function flushAndClearOnyxQueue() { + if (isQueuePaused) { + return; + } + Onyx.update(QueuedOnyxUpdates.getQueuedUpdates()).then(QueuedOnyxUpdates.clear); +} + /** * Puts the queue into a paused state so that no requests will be processed */ @@ -172,6 +183,10 @@ function unpause() { const numberOfPersistedRequests = PersistedRequests.getAll().length || 0; console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); isQueuePaused = false; + + // Since the writes may happen async to the queue, in case we had any writes happen while the queue was paused + // (because of race conditions), let's also apply the queued updates and clear them before continuing the queue. + flushAndClearOnyxQueue(); flush(); } From 181c54a317baa79b47bc815a5e715e6a38043e06 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 04:21:39 +0200 Subject: [PATCH 052/134] prettier --- src/libs/Network/SequentialQueue.js | 3 +-- src/libs/actions/App.js | 3 +-- src/libs/actions/OnyxUpdateManager.js | 17 +++++++++-------- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 4894456fa789..10c1329cca28 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -149,7 +149,6 @@ function waitForIdle() { return isReadyPromise; } - /** * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. */ @@ -184,7 +183,7 @@ function unpause() { console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); isQueuePaused = false; - // Since the writes may happen async to the queue, in case we had any writes happen while the queue was paused + // Since the writes may happen async to the queue, in case we had any writes happen while the queue was paused // (because of race conditions), let's also apply the queued updates and clear them before continuing the queue. flushAndClearOnyxQueue(); flush(); diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index 2e3185ea4d1b..820173a7be8e 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -232,7 +232,7 @@ function lastReconnectAppAfterActivatingReliableUpdates() { if (updateIDFrom) { params.updateIDFrom = updateIDFrom; } - + // It is SUPER BAD FORM to return promises from action methods. // DO NOT FOLLOW THIS PATTERN!!!!! // It was absolutely necessary in order to not break the app while migrating to the new reliable updates pattern. This method will be removed @@ -247,7 +247,6 @@ function lastReconnectAppAfterActivatingReliableUpdates() { getOnyxDataForOpenOrReconnect(), ); }); - } /** diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 0b952cad9ef5..83fda3234557 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -27,7 +27,7 @@ function applyHTTPSOnyxUpdates({request, responseData}) { console.debug('[OnyxUpdateManager] Applying https update'); // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in // the UI. See https://github.com/Expensify/App/issues/12775 for more info. - // 2023-08-31 - + // 2023-08-31 - const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then @@ -113,7 +113,7 @@ export default () => { if (!previousUpdateIDFromServer || lastUpdateIDAppliedToClient === previousUpdateIDFromServer) { console.debug(`[OnyxUpdateManager] Client is in sync with the server, applying updates`); applyOnyxUpdates(updateParams); - } else if (lastUpdateIDFromServer < lastUpdateIDAppliedToClient) { + } else if (lastUpdateIDFromServer < lastUpdateIDAppliedToClient) { console.debug(`[OnyxUpdateManager] Client is more up to date than the update received, skipping processing`); } else { // In cases where we received a previousUpdateID and it doesn't match our lastUpdateIDAppliedToClient @@ -121,18 +121,19 @@ export default () => { // // 1. This is the first time we're receiving an lastUpdateID, so we need to do a final reconnectApp before // fully migrating to the reliable updates mode; - // 2. This this client already has the reliable updates mode enabled, but it's missing some updates and it + // 2. This this client already has the reliable updates mode enabled, but it's missing some updates and it // needs to fech those. // - // To to both of those, we need to pause the sequential queue. This is important so that the updates are - // applied in their correct and specific order. If this queue was not paused, then there would be a lot of + // To to both of those, we need to pause the sequential queue. This is important so that the updates are + // applied in their correct and specific order. If this queue was not paused, then there would be a lot of // onyx data being applied while we are fetching the missing updates and that would put them all out of order. SequentialQueue.pause(); let promise; - + // The flow below is setting the promise to a reconnect app to address flow (1) explained above. - if (!lastUpdateIDAppliedToClient && - (updateParams.type === CONST.ONYX_UPDATE_TYPES.PUSHER || updateParams.data.request.command !== 'OpenApp' && updateParams.data.request.command !== 'ReconnectApp') + if ( + !lastUpdateIDAppliedToClient && + (updateParams.type === CONST.ONYX_UPDATE_TYPES.PUSHER || (updateParams.data.request.command !== 'OpenApp' && updateParams.data.request.command !== 'ReconnectApp')) ) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); From 97ef06e729b189ef0bab59ef6bd0a8972008aaee Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 04:43:36 +0200 Subject: [PATCH 053/134] prettier, some refactoring and adding the unpause in the right place --- src/libs/Network/SequentialQueue.js | 6 +++--- src/libs/actions/App.js | 15 +-------------- src/libs/actions/OnyxUpdateManager.js | 22 +++++++++++++++------- 3 files changed, 19 insertions(+), 24 deletions(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 10c1329cca28..27dd0755c966 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -94,7 +94,7 @@ function flush() { isSequentialQueueRunning = false; resolveIsReadyPromise(); currentRequest = null; - flushAndClearOnyxQueue(); + flushAndClearOnyxUpdatesQueue(); }); }, }); @@ -152,7 +152,7 @@ function waitForIdle() { /** * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. */ -function flushAndClearOnyxQueue() { +function flushAndClearOnyxUpdatesQueue() { if (isQueuePaused) { return; } @@ -185,7 +185,7 @@ function unpause() { // Since the writes may happen async to the queue, in case we had any writes happen while the queue was paused // (because of race conditions), let's also apply the queued updates and clear them before continuing the queue. - flushAndClearOnyxQueue(); + flushAndClearOnyxUpdatesQueue(); flush(); } diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index 820173a7be8e..0bba4249bf11 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -227,25 +227,12 @@ function lastReconnectAppAfterActivatingReliableUpdates() { params.mostRecentReportActionLastModified = ReportActionsUtils.getMostRecentReportActionLastModified(); Timing.end(CONST.TIMING.CALCULATE_MOST_RECENT_LAST_MODIFIED_ACTION, '', 500); - // Include the update IDs when reconnecting so that the server can send incremental updates if they are available. - // Otherwise, a full set of app data will be returned. - if (updateIDFrom) { - params.updateIDFrom = updateIDFrom; - } - // It is SUPER BAD FORM to return promises from action methods. // DO NOT FOLLOW THIS PATTERN!!!!! // It was absolutely necessary in order to not break the app while migrating to the new reliable updates pattern. This method will be removed // as soon as we have everyone migrated to it // eslint-disable-next-line rulesdir/no-api-side-effects-method - return API.makeRequestWithSideEffects( - 'ReconnectApp', - { - updateIDFrom, - updateIDTo, - }, - getOnyxDataForOpenOrReconnect(), - ); + return API.makeRequestWithSideEffects('ReconnectApp', params, getOnyxDataForOpenOrReconnect()); }); } diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 83fda3234557..28c74874a564 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -21,9 +21,10 @@ import * as App from './App'; * @param {Object} data * @param {Object} data.request * @param {Object} data.responseData + * @param {Boolean} data.unpauseQueue * @returns {Promise} */ -function applyHTTPSOnyxUpdates({request, responseData}) { +function applyHTTPSOnyxUpdates({request, responseData, unpauseQueue}) { console.debug('[OnyxUpdateManager] Applying https update'); // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in // the UI. See https://github.com/Expensify/App/issues/12775 for more info. @@ -47,6 +48,9 @@ function applyHTTPSOnyxUpdates({request, responseData}) { return Promise.resolve(); }) .then(() => { + if (unpauseQueue) { + SequentialQueue.unpause(); + } console.debug('[OnyxUpdateManager] Done applying HTTPS update'); }); } @@ -54,9 +58,10 @@ function applyHTTPSOnyxUpdates({request, responseData}) { /** * @param {Object} data * @param {Object} data.updates + * @param {Boolean} data.unpauseQueue * @returns {Promise} */ -function applyPusherOnyxUpdates({updates}) { +function applyPusherOnyxUpdates({updates, unpauseQueue}) { console.debug('[OnyxUpdateManager] Applying pusher update'); const pusherEventPromises = _.reduce( updates, @@ -67,6 +72,9 @@ function applyPusherOnyxUpdates({updates}) { [], ); return Promise.all(pusherEventPromises).then(() => { + if (unpauseQueue) { + SequentialQueue.unpause(); + } console.debug('[OnyxUpdateManager] Done applying Pusher update'); }); } @@ -74,19 +82,20 @@ function applyPusherOnyxUpdates({updates}) { /** * @param {Object[]} updateParams * @param {String} updateParams.type + * @param {Boolean} updateParams.unpauseQueue * @param {Object} updateParams.data * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' * @returns {Promise} */ -function applyOnyxUpdates({type, data}) { +function applyOnyxUpdates({type, data, unpauseQueue = false}) { console.debug(`[OnyxUpdateManager] Applying update type: ${type}`, data); if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { - return applyHTTPSOnyxUpdates(data); + return applyHTTPSOnyxUpdates({...data, unpauseQueue}); } if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { - return applyPusherOnyxUpdates(data); + return applyPusherOnyxUpdates({...data, unpauseQueue}); } } @@ -151,8 +160,7 @@ export default () => { promise.finally(() => { console.debug('[OnyxUpdateManager] Done applying all updates'); - applyOnyxUpdates(updateParams); - SequentialQueue.unpause(); + applyOnyxUpdates({...updateParams, unpauseQueue: true}); }); } From 03da9725ba4ba8604a3a34c2b54b25c67dfb1930 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 04:45:30 +0200 Subject: [PATCH 054/134] using the promise instead of passing variable down --- src/libs/actions/OnyxUpdateManager.js | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 28c74874a564..24bceda6e181 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -21,10 +21,9 @@ import * as App from './App'; * @param {Object} data * @param {Object} data.request * @param {Object} data.responseData - * @param {Boolean} data.unpauseQueue * @returns {Promise} */ -function applyHTTPSOnyxUpdates({request, responseData, unpauseQueue}) { +function applyHTTPSOnyxUpdates({request, responseData}) { console.debug('[OnyxUpdateManager] Applying https update'); // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in // the UI. See https://github.com/Expensify/App/issues/12775 for more info. @@ -48,9 +47,6 @@ function applyHTTPSOnyxUpdates({request, responseData, unpauseQueue}) { return Promise.resolve(); }) .then(() => { - if (unpauseQueue) { - SequentialQueue.unpause(); - } console.debug('[OnyxUpdateManager] Done applying HTTPS update'); }); } @@ -58,10 +54,9 @@ function applyHTTPSOnyxUpdates({request, responseData, unpauseQueue}) { /** * @param {Object} data * @param {Object} data.updates - * @param {Boolean} data.unpauseQueue * @returns {Promise} */ -function applyPusherOnyxUpdates({updates, unpauseQueue}) { +function applyPusherOnyxUpdates({updates}) { console.debug('[OnyxUpdateManager] Applying pusher update'); const pusherEventPromises = _.reduce( updates, @@ -72,9 +67,6 @@ function applyPusherOnyxUpdates({updates, unpauseQueue}) { [], ); return Promise.all(pusherEventPromises).then(() => { - if (unpauseQueue) { - SequentialQueue.unpause(); - } console.debug('[OnyxUpdateManager] Done applying Pusher update'); }); } @@ -160,7 +152,9 @@ export default () => { promise.finally(() => { console.debug('[OnyxUpdateManager] Done applying all updates'); - applyOnyxUpdates({...updateParams, unpauseQueue: true}); + applyOnyxUpdates(updateParams).finally(() => { + SequentialQueue.unpause(); + }); }); } From d5fd7edcc7c9d4a019036321343bdb4c222a9f38 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 05:35:12 +0200 Subject: [PATCH 055/134] linting files and adjusting checks --- src/libs/Network/SequentialQueue.js | 21 +++++++++++---------- src/libs/actions/OnyxUpdateManager.js | 7 ++----- 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 27dd0755c966..2bbc766d868f 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -62,6 +62,17 @@ function process() { return currentRequest; } + +/** + * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. + */ +function flushAndClearOnyxUpdatesQueue() { + if (isQueuePaused) { + return; + } + Onyx.update(QueuedOnyxUpdates.getQueuedUpdates()).then(QueuedOnyxUpdates.clear); +} + function flush() { // When the queue is paused, return early. This will keep an requests in the queue and they will get flushed again when the queue is unpaused if (isQueuePaused) { @@ -149,16 +160,6 @@ function waitForIdle() { return isReadyPromise; } -/** - * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. - */ -function flushAndClearOnyxUpdatesQueue() { - if (isQueuePaused) { - return; - } - Onyx.update(QueuedOnyxUpdates.getQueuedUpdates()).then(QueuedOnyxUpdates.clear); -} - /** * Puts the queue into a paused state so that no requests will be processed */ diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 24bceda6e181..f1a9973ade4c 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -111,7 +111,7 @@ export default () => { // If we don't have a previousUpdateID from the request, or if we if it's the less or equal w we currently have stored // we can simply apply the updates and move on. - if (!previousUpdateIDFromServer || lastUpdateIDAppliedToClient === previousUpdateIDFromServer) { + if (!previousUpdateIDFromServer || lastUpdateIDAppliedToClient === previousUpdateIDFromServer || (updateParams.type === CONST.ONYX_UPDATE_TYPES.HTTPS && (updateParams.data.request.command === 'OpenApp' || updateParams.data.request.command === 'ReconnectApp'))) { console.debug(`[OnyxUpdateManager] Client is in sync with the server, applying updates`); applyOnyxUpdates(updateParams); } else if (lastUpdateIDFromServer < lastUpdateIDAppliedToClient) { @@ -132,10 +132,7 @@ export default () => { let promise; // The flow below is setting the promise to a reconnect app to address flow (1) explained above. - if ( - !lastUpdateIDAppliedToClient && - (updateParams.type === CONST.ONYX_UPDATE_TYPES.PUSHER || (updateParams.data.request.command !== 'OpenApp' && updateParams.data.request.command !== 'ReconnectApp')) - ) { + if (!lastUpdateIDAppliedToClient) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); promise = App.lastReconnectAppAfterActivatingReliableUpdates(); From b8abf43c92492b8892836974f3f6ac5b0378fd51 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 1 Sep 2023 06:10:51 +0200 Subject: [PATCH 056/134] adding the right check in lastUpdateAppliedToClient --- src/libs/actions/OnyxUpdateManager.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index f1a9973ade4c..0028ee9776ec 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -114,7 +114,7 @@ export default () => { if (!previousUpdateIDFromServer || lastUpdateIDAppliedToClient === previousUpdateIDFromServer || (updateParams.type === CONST.ONYX_UPDATE_TYPES.HTTPS && (updateParams.data.request.command === 'OpenApp' || updateParams.data.request.command === 'ReconnectApp'))) { console.debug(`[OnyxUpdateManager] Client is in sync with the server, applying updates`); applyOnyxUpdates(updateParams); - } else if (lastUpdateIDFromServer < lastUpdateIDAppliedToClient) { + } else if (lastUpdateIDFromServer <= lastUpdateIDAppliedToClient) { console.debug(`[OnyxUpdateManager] Client is more up to date than the update received, skipping processing`); } else { // In cases where we received a previousUpdateID and it doesn't match our lastUpdateIDAppliedToClient From b9f452fc2eb6a54f3fb16fe614a3e269f81b4210 Mon Sep 17 00:00:00 2001 From: Thanos30 Date: Fri, 1 Sep 2023 17:41:32 +0300 Subject: [PATCH 057/134] Emoji Suggestions Adjustments + Remove Duplicates --- src/libs/EmojiTrie.js | 43 ++++++++++++++++++++++++++++-------------- src/libs/EmojiUtils.js | 9 ++++++++- 2 files changed, 37 insertions(+), 15 deletions(-) diff --git a/src/libs/EmojiTrie.js b/src/libs/EmojiTrie.js index c5448c340d81..3bebbf750628 100644 --- a/src/libs/EmojiTrie.js +++ b/src/libs/EmojiTrie.js @@ -18,26 +18,40 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { return; } - const name = isDefaultLocale ? item.name : _.get(langEmojis, [item.code, 'name']); - const names = isDefaultLocale ? [name] : [...new Set([name, item.name])]; - _.forEach(names, (nm) => { - const node = trie.search(nm); - if (!node) { - trie.add(nm, {code: item.code, types: item.types, name: nm, suggestions: []}); - } else { - trie.update(nm, {code: item.code, types: item.types, name: nm, suggestions: node.metaData.suggestions}); - } - }); - - const keywords = _.get(langEmojis, [item.code, 'keywords'], []).concat(isDefaultLocale ? [] : _.get(localeEmojis, [CONST.LOCALES.DEFAULT, item.code, 'keywords'], [])); + const defaultName = item.name; + const preferredLanguageName = _.get(langEmojis, [item.code, 'name'], defaultName); + + // Add the actual name of the emoji for the current language + const node = trie.search(preferredLanguageName); + if (!node) { + trie.add(preferredLanguageName, {code: item.code, types: item.types, name: preferredLanguageName, suggestions: []}); + } else { + trie.update(preferredLanguageName, {code: item.code, types: item.types, name: preferredLanguageName, suggestions: node.metaData.suggestions}); + } + + // Add keywords of both the current language and the default language, in case current language isn't the default. + const keywords = _.get(langEmojis, [item.code, 'keywords'], []).concat(isDefaultLocale ? [] : _.get(localeEmojis, [CONST.LOCALES.DEFAULT, item.code, 'keywords'], []));; for (let j = 0; j < keywords.length; j++) { const keywordNode = trie.search(keywords[j]); if (!keywordNode) { - trie.add(keywords[j], {suggestions: [{code: item.code, types: item.types, name}]}); + trie.add(keywords[j], {suggestions: [{code: item.code, types: item.types, name: preferredLanguageName}]}); } else { trie.update(keywords[j], { ...keywordNode.metaData, - suggestions: [...keywordNode.metaData.suggestions, {code: item.code, types: item.types, name}], + suggestions: [...keywordNode.metaData.suggestions, {code: item.code, types: item.types, name: preferredLanguageName}], + }); + } + } + + // If current language isn't the default, prepend the English name of the emoji in the suggestions as well. + if (!isDefaultLocale) { + const englishNode = trie.search(defaultName); + if (!englishNode) { + trie.add(defaultName, {suggestions: [{code: item.code, types: item.types, name: preferredLanguageName}]}); + } else { + trie.update(defaultName, { + ...englishNode.metaData, + suggestions: [{code: item.code, types: item.types, name: preferredLanguageName}, ...englishNode.metaData.suggestions], }); } } @@ -46,6 +60,7 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { return trie; } + const emojiTrie = _.reduce(supportedLanguages, (prev, cur) => ({...prev, [cur]: createTrie(cur)}), {}); Timing.end(CONST.TIMING.TRIE_INITIALIZATION); diff --git a/src/libs/EmojiUtils.js b/src/libs/EmojiUtils.js index df00418b7524..c8133023d80e 100644 --- a/src/libs/EmojiUtils.js +++ b/src/libs/EmojiUtils.js @@ -319,7 +319,14 @@ function replaceEmojis(text, preferredSkinTone = CONST.EMOJI_DEFAULT_SKIN_TONE, } for (let i = 0; i < emojiData.length; i++) { const name = emojiData[i].slice(1, -1); - const checkEmoji = trie.search(name); + let checkEmoji = trie.search(name); + if ((!checkEmoji || !checkEmoji.metaData.code) && lang !== CONST.LOCALES.DEFAULT) { + const englishTrie = emojisTrie[CONST.LOCALES.DEFAULT]; + if (englishTrie) { + const englishEmoji = englishTrie.search(name); + checkEmoji = englishEmoji; + } + } if (checkEmoji && checkEmoji.metaData.code) { let emojiReplacement = getEmojiCodeWithSkinColor(checkEmoji.metaData, preferredSkinTone); emojis.push({ From 5f744b7c293e3dcb0e022de61b5dcd04a6b9c8be Mon Sep 17 00:00:00 2001 From: Thanos30 Date: Fri, 1 Sep 2023 21:05:13 +0300 Subject: [PATCH 058/134] npm run prettier --- src/libs/EmojiTrie.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/libs/EmojiTrie.js b/src/libs/EmojiTrie.js index 3bebbf750628..7f396e5188af 100644 --- a/src/libs/EmojiTrie.js +++ b/src/libs/EmojiTrie.js @@ -20,7 +20,7 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { const defaultName = item.name; const preferredLanguageName = _.get(langEmojis, [item.code, 'name'], defaultName); - + // Add the actual name of the emoji for the current language const node = trie.search(preferredLanguageName); if (!node) { @@ -28,9 +28,9 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { } else { trie.update(preferredLanguageName, {code: item.code, types: item.types, name: preferredLanguageName, suggestions: node.metaData.suggestions}); } - + // Add keywords of both the current language and the default language, in case current language isn't the default. - const keywords = _.get(langEmojis, [item.code, 'keywords'], []).concat(isDefaultLocale ? [] : _.get(localeEmojis, [CONST.LOCALES.DEFAULT, item.code, 'keywords'], []));; + const keywords = _.get(langEmojis, [item.code, 'keywords'], []).concat(isDefaultLocale ? [] : _.get(localeEmojis, [CONST.LOCALES.DEFAULT, item.code, 'keywords'], [])); for (let j = 0; j < keywords.length; j++) { const keywordNode = trie.search(keywords[j]); if (!keywordNode) { @@ -60,7 +60,6 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { return trie; } - const emojiTrie = _.reduce(supportedLanguages, (prev, cur) => ({...prev, [cur]: createTrie(cur)}), {}); Timing.end(CONST.TIMING.TRIE_INITIALIZATION); From 9cc67478fc26b0df9dc0fb40d3fa71314cab609e Mon Sep 17 00:00:00 2001 From: Anusha Date: Sat, 2 Sep 2023 10:02:35 +0500 Subject: [PATCH 059/134] temporary message disappears --- src/libs/ReportActionsUtils.js | 13 ++++++++++--- src/libs/ReportUtils.js | 1 + src/libs/actions/Report.js | 2 +- src/pages/home/report/ReportActionItem.js | 3 ++- src/pages/home/report/ReportActionItemFragment.js | 2 +- src/pages/home/report/ReportActionItemMessage.js | 2 +- 6 files changed, 16 insertions(+), 7 deletions(-) diff --git a/src/libs/ReportActionsUtils.js b/src/libs/ReportActionsUtils.js index 3ed10b865812..b81234d7c9b6 100644 --- a/src/libs/ReportActionsUtils.js +++ b/src/libs/ReportActionsUtils.js @@ -105,11 +105,18 @@ function isWhisperAction(action) { } /** + * + * Returns whether the comment is a thread parent message/the first message in a thread + * * @param {Object} reportAction + * @param {Number} reportID * @returns {Boolean} */ -function hasCommentThread(reportAction) { - return lodashGet(reportAction, 'childType', '') === CONST.REPORT.TYPE.CHAT && lodashGet(reportAction, 'childVisibleActionCount', 0) > 0; +function isThreadParentMessage(reportAction, reportID) { + return ( + lodashGet(reportAction, 'childType', '') === CONST.REPORT.TYPE.CHAT && + (lodashGet(reportAction, 'childVisibleActionCount', 0) > 0 || (!_.isUndefined(reportAction.childReportID) && reportAction.childReportID.toString() === reportID)) + ); } /** @@ -624,7 +631,7 @@ export { getLastClosedReportAction, getLatestReportActionFromOnyxData, isMoneyRequestAction, - hasCommentThread, + isThreadParentMessage, getLinkedTransactionID, getMostRecentReportActionLastModified, getReportPreviewAction, diff --git a/src/libs/ReportUtils.js b/src/libs/ReportUtils.js index ff9a5ee14519..df5c50f28522 100644 --- a/src/libs/ReportUtils.js +++ b/src/libs/ReportUtils.js @@ -1797,6 +1797,7 @@ function buildOptimisticAddCommentReportAction(text, file) { attachmentInfo, pendingAction: CONST.RED_BRICK_ROAD_PENDING_ACTION.ADD, shouldShow: true, + childType: 'chat', }, }; } diff --git a/src/libs/actions/Report.js b/src/libs/actions/Report.js index 8b898a6aaaea..ad396b8bbaac 100644 --- a/src/libs/actions/Report.js +++ b/src/libs/actions/Report.js @@ -926,7 +926,7 @@ function deleteReportComment(reportID, reportAction) { html: '', text: '', isEdited: true, - isDeletedParentAction: ReportActionsUtils.hasCommentThread(reportAction), + isDeletedParentAction: ReportActionsUtils.isThreadParentMessage(reportAction, reportID), }, ]; const optimisticReportActions = { diff --git a/src/pages/home/report/ReportActionItem.js b/src/pages/home/report/ReportActionItem.js index d5d8b38bb92c..c2f14aba54ec 100644 --- a/src/pages/home/report/ReportActionItem.js +++ b/src/pages/home/report/ReportActionItem.js @@ -341,6 +341,7 @@ function ReportActionItem(props) { {!props.draftMessage ? ( ReportActions.clearReportActionErrors(props.report.reportID, props.action)} pendingAction={props.draftMessage ? null : props.action.pendingAction} - shouldHideOnDelete={!ReportActionsUtils.hasCommentThread(props.action)} + shouldHideOnDelete={!ReportActionsUtils.isThreadParentMessage(props.action, props.report.reportID)} errors={props.action.errors} errorRowStyles={[styles.ml10, styles.mr2]} needsOffscreenAlphaCompositing={ReportActionsUtils.isMoneyRequestAction(props.action)} diff --git a/src/pages/home/report/ReportActionItemFragment.js b/src/pages/home/report/ReportActionItemFragment.js index 91ee8f7531da..e6745a89e493 100644 --- a/src/pages/home/report/ReportActionItemFragment.js +++ b/src/pages/home/report/ReportActionItemFragment.js @@ -113,7 +113,7 @@ function ReportActionItemFragment(props) { // While offline we display the previous message with a strikethrough style. Once online we want to // immediately display "[Deleted message]" while the delete action is pending. - if ((!props.network.isOffline && props.hasCommentThread && props.pendingAction === CONST.RED_BRICK_ROAD_PENDING_ACTION.DELETE) || props.fragment.isDeletedParentAction) { + if ((!props.network.isOffline && props.isThreadParentMessage && props.pendingAction === CONST.RED_BRICK_ROAD_PENDING_ACTION.DELETE) || props.fragment.isDeletedParentAction) { return ${props.translate('parentReportAction.deletedMessage')}`} />; } diff --git a/src/pages/home/report/ReportActionItemMessage.js b/src/pages/home/report/ReportActionItemMessage.js index 40d2d5e6d89c..6e25702c821d 100644 --- a/src/pages/home/report/ReportActionItemMessage.js +++ b/src/pages/home/report/ReportActionItemMessage.js @@ -53,7 +53,7 @@ function ReportActionItemMessage(props) { fragment={fragment} isAttachment={props.action.isAttachment} iouMessage={iouMessage} - hasCommentThread={ReportActionsUtils.hasCommentThread(props.action)} + isThreadParentMessage={ReportActionsUtils.isThreadParentMessage(props.action, props.reportID)} attachmentInfo={props.action.attachmentInfo} pendingAction={props.action.pendingAction} source={lodashGet(props.action, 'originalMessage.source')} From 293d0739d11e4025a40748dca51323a0e695893b Mon Sep 17 00:00:00 2001 From: Blazej Kustra Date: Mon, 4 Sep 2023 16:47:40 +0200 Subject: [PATCH 060/134] [TS migration] Migrate 'canFocusInputOnScreenFocus' lib to TypeScript --- src/libs/canFocusInputOnScreenFocus/index.js | 3 --- src/libs/canFocusInputOnScreenFocus/index.native.js | 1 - src/libs/canFocusInputOnScreenFocus/index.native.ts | 5 +++++ src/libs/canFocusInputOnScreenFocus/index.ts | 6 ++++++ src/libs/canFocusInputOnScreenFocus/types.ts | 3 +++ 5 files changed, 14 insertions(+), 4 deletions(-) delete mode 100644 src/libs/canFocusInputOnScreenFocus/index.js delete mode 100644 src/libs/canFocusInputOnScreenFocus/index.native.js create mode 100644 src/libs/canFocusInputOnScreenFocus/index.native.ts create mode 100644 src/libs/canFocusInputOnScreenFocus/index.ts create mode 100644 src/libs/canFocusInputOnScreenFocus/types.ts diff --git a/src/libs/canFocusInputOnScreenFocus/index.js b/src/libs/canFocusInputOnScreenFocus/index.js deleted file mode 100644 index c930c0d944ec..000000000000 --- a/src/libs/canFocusInputOnScreenFocus/index.js +++ /dev/null @@ -1,3 +0,0 @@ -import * as DeviceCapabilities from '../DeviceCapabilities'; - -export default () => !DeviceCapabilities.canUseTouchScreen(); diff --git a/src/libs/canFocusInputOnScreenFocus/index.native.js b/src/libs/canFocusInputOnScreenFocus/index.native.js deleted file mode 100644 index eae5767cffbc..000000000000 --- a/src/libs/canFocusInputOnScreenFocus/index.native.js +++ /dev/null @@ -1 +0,0 @@ -export default () => false; diff --git a/src/libs/canFocusInputOnScreenFocus/index.native.ts b/src/libs/canFocusInputOnScreenFocus/index.native.ts new file mode 100644 index 000000000000..79d711c49fa6 --- /dev/null +++ b/src/libs/canFocusInputOnScreenFocus/index.native.ts @@ -0,0 +1,5 @@ +import CanFocusInputOnScreenFocus from './types'; + +const canFocusInputOnScreenFocus: CanFocusInputOnScreenFocus = () => false; + +export default canFocusInputOnScreenFocus; diff --git a/src/libs/canFocusInputOnScreenFocus/index.ts b/src/libs/canFocusInputOnScreenFocus/index.ts new file mode 100644 index 000000000000..be500074d7e3 --- /dev/null +++ b/src/libs/canFocusInputOnScreenFocus/index.ts @@ -0,0 +1,6 @@ +import * as DeviceCapabilities from '../DeviceCapabilities'; +import CanFocusInputOnScreenFocus from './types'; + +const canFocusInputOnScreenFocus: CanFocusInputOnScreenFocus = () => !DeviceCapabilities.canUseTouchScreen(); + +export default canFocusInputOnScreenFocus; diff --git a/src/libs/canFocusInputOnScreenFocus/types.ts b/src/libs/canFocusInputOnScreenFocus/types.ts new file mode 100644 index 000000000000..5a65e5e7d198 --- /dev/null +++ b/src/libs/canFocusInputOnScreenFocus/types.ts @@ -0,0 +1,3 @@ +type CanFocusInputOnScreenFocus = () => boolean; + +export default CanFocusInputOnScreenFocus; From 39a1074ba34a59b5c9fa79f086035b8a4d911143 Mon Sep 17 00:00:00 2001 From: Anusha Date: Mon, 4 Sep 2023 19:45:43 +0500 Subject: [PATCH 061/134] set optimistic childType --- src/libs/ReportUtils.js | 1 - src/libs/actions/Report.js | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/libs/ReportUtils.js b/src/libs/ReportUtils.js index 5778450ba571..893145a8e5fa 100644 --- a/src/libs/ReportUtils.js +++ b/src/libs/ReportUtils.js @@ -1805,7 +1805,6 @@ function buildOptimisticAddCommentReportAction(text, file) { attachmentInfo, pendingAction: CONST.RED_BRICK_ROAD_PENDING_ACTION.ADD, shouldShow: true, - childType: 'chat', }, }; } diff --git a/src/libs/actions/Report.js b/src/libs/actions/Report.js index ad396b8bbaac..c4c9b2bfcb4f 100644 --- a/src/libs/actions/Report.js +++ b/src/libs/actions/Report.js @@ -528,12 +528,12 @@ function openReport(reportID, participantLoginList = [], newReportObject = {}, p onyxData.optimisticData.push({ onyxMethod: Onyx.METHOD.MERGE, key: `${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${newReportObject.parentReportID}`, - value: {[parentReportActionID]: {childReportID: reportID}}, + value: {[parentReportActionID]: {childReportID: reportID, childType: CONST.REPORT.TYPE.CHAT}}, }); onyxData.failureData.push({ onyxMethod: Onyx.METHOD.MERGE, key: `${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${newReportObject.parentReportID}`, - value: {[parentReportActionID]: {childReportID: '0'}}, + value: {[parentReportActionID]: {childReportID: '0', childType: ''}}, }); } } From 2cb0fe8c2102707c7b5fd024103cda409d8d3d2d Mon Sep 17 00:00:00 2001 From: dukenv0307 Date: Tue, 5 Sep 2023 10:35:10 +0700 Subject: [PATCH 062/134] fix: pressing enter doesn't open the selected option page --- src/components/PopoverMenu/index.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/components/PopoverMenu/index.js b/src/components/PopoverMenu/index.js index 67b9a0406aef..5fabf73547ea 100644 --- a/src/components/PopoverMenu/index.js +++ b/src/components/PopoverMenu/index.js @@ -1,5 +1,5 @@ import _ from 'underscore'; -import React, {useState} from 'react'; +import React, {useRef} from 'react'; import PropTypes from 'prop-types'; import {View} from 'react-native'; import PopoverWithMeasuredContent from '../PopoverWithMeasuredContent'; @@ -48,13 +48,13 @@ const defaultProps = { function PopoverMenu(props) { const {isSmallScreenWidth} = useWindowDimensions(); - const [selectedItemIndex, setSelectedItemIndex] = useState(null); + const selectedItemIndex = useRef(null); const [focusedIndex, setFocusedIndex] = useArrowKeyFocusManager({initialFocusedIndex: -1, maxIndex: props.menuItems.length - 1, isActive: props.isVisible}); const selectItem = (index) => { const selectedItem = props.menuItems[index]; props.onItemSelected(selectedItem, index); - setSelectedItemIndex(index); + selectedItemIndex.current = index; }; useKeyboardShortcut( @@ -78,9 +78,9 @@ function PopoverMenu(props) { isVisible={props.isVisible} onModalHide={() => { setFocusedIndex(-1); - if (selectedItemIndex !== null) { - props.menuItems[selectedItemIndex].onSelected(); - setSelectedItemIndex(null); + if (selectedItemIndex.current !== null) { + props.menuItems[selectedItemIndex.current].onSelected(); + selectedItemIndex.current = null; } }} animationIn={props.animationIn} From 3a5927c595c8e97933e045d25be2d78646e60eb0 Mon Sep 17 00:00:00 2001 From: Thanos30 Date: Tue, 5 Sep 2023 14:35:42 +0300 Subject: [PATCH 063/134] name refactoring --- src/libs/EmojiTrie.js | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/libs/EmojiTrie.js b/src/libs/EmojiTrie.js index 7f396e5188af..b6cc68f57ec8 100644 --- a/src/libs/EmojiTrie.js +++ b/src/libs/EmojiTrie.js @@ -18,15 +18,15 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { return; } - const defaultName = item.name; - const preferredLanguageName = _.get(langEmojis, [item.code, 'name'], defaultName); + const englishName = item.name; + const localeName = _.get(langEmojis, [item.code, 'name'], englishName); // Add the actual name of the emoji for the current language - const node = trie.search(preferredLanguageName); + const node = trie.search(localeName); if (!node) { - trie.add(preferredLanguageName, {code: item.code, types: item.types, name: preferredLanguageName, suggestions: []}); + trie.add(localeName, {code: item.code, types: item.types, name: localeName, suggestions: []}); } else { - trie.update(preferredLanguageName, {code: item.code, types: item.types, name: preferredLanguageName, suggestions: node.metaData.suggestions}); + trie.update(localeName, {code: item.code, types: item.types, name: localeName, suggestions: node.metaData.suggestions}); } // Add keywords of both the current language and the default language, in case current language isn't the default. @@ -34,24 +34,24 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { for (let j = 0; j < keywords.length; j++) { const keywordNode = trie.search(keywords[j]); if (!keywordNode) { - trie.add(keywords[j], {suggestions: [{code: item.code, types: item.types, name: preferredLanguageName}]}); + trie.add(keywords[j], {suggestions: [{code: item.code, types: item.types, name: localeName}]}); } else { trie.update(keywords[j], { ...keywordNode.metaData, - suggestions: [...keywordNode.metaData.suggestions, {code: item.code, types: item.types, name: preferredLanguageName}], + suggestions: [...keywordNode.metaData.suggestions, {code: item.code, types: item.types, name: localeName}], }); } } // If current language isn't the default, prepend the English name of the emoji in the suggestions as well. if (!isDefaultLocale) { - const englishNode = trie.search(defaultName); + const englishNode = trie.search(englishName); if (!englishNode) { - trie.add(defaultName, {suggestions: [{code: item.code, types: item.types, name: preferredLanguageName}]}); + trie.add(englishName, {suggestions: [{code: item.code, types: item.types, name: localeName}]}); } else { - trie.update(defaultName, { + trie.update(englishName, { ...englishNode.metaData, - suggestions: [{code: item.code, types: item.types, name: preferredLanguageName}, ...englishNode.metaData.suggestions], + suggestions: [{code: item.code, types: item.types, name: localeName}, ...englishNode.metaData.suggestions], }); } } From f47d363b86c896b4889ba665692c1ad9d30456f8 Mon Sep 17 00:00:00 2001 From: Thanos30 Date: Tue, 5 Sep 2023 14:47:15 +0300 Subject: [PATCH 064/134] Add comments + Clear code --- src/libs/EmojiTrie.js | 4 ++-- src/libs/EmojiUtils.js | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/libs/EmojiTrie.js b/src/libs/EmojiTrie.js index b6cc68f57ec8..b0bd0d5eec5d 100644 --- a/src/libs/EmojiTrie.js +++ b/src/libs/EmojiTrie.js @@ -21,7 +21,6 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { const englishName = item.name; const localeName = _.get(langEmojis, [item.code, 'name'], englishName); - // Add the actual name of the emoji for the current language const node = trie.search(localeName); if (!node) { trie.add(localeName, {code: item.code, types: item.types, name: localeName, suggestions: []}); @@ -29,7 +28,7 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { trie.update(localeName, {code: item.code, types: item.types, name: localeName, suggestions: node.metaData.suggestions}); } - // Add keywords of both the current language and the default language, in case current language isn't the default. + // Add keywords for both the locale language and English to enable users to search using either language. const keywords = _.get(langEmojis, [item.code, 'keywords'], []).concat(isDefaultLocale ? [] : _.get(localeEmojis, [CONST.LOCALES.DEFAULT, item.code, 'keywords'], [])); for (let j = 0; j < keywords.length; j++) { const keywordNode = trie.search(keywords[j]); @@ -44,6 +43,7 @@ function createTrie(lang = CONST.LOCALES.DEFAULT) { } // If current language isn't the default, prepend the English name of the emoji in the suggestions as well. + // We do this because when the user types the english name of the emoji, we want to show the emoji in the suggestions before all the others. if (!isDefaultLocale) { const englishNode = trie.search(englishName); if (!englishNode) { diff --git a/src/libs/EmojiUtils.js b/src/libs/EmojiUtils.js index c8133023d80e..80665541e24b 100644 --- a/src/libs/EmojiUtils.js +++ b/src/libs/EmojiUtils.js @@ -320,7 +320,9 @@ function replaceEmojis(text, preferredSkinTone = CONST.EMOJI_DEFAULT_SKIN_TONE, for (let i = 0; i < emojiData.length; i++) { const name = emojiData[i].slice(1, -1); let checkEmoji = trie.search(name); - if ((!checkEmoji || !checkEmoji.metaData.code) && lang !== CONST.LOCALES.DEFAULT) { + // If the user has selected a language other than English, and the emoji doesn't exist in that language, + // we will check if the emoji exists in English. + if (lang !== CONST.LOCALES.DEFAULT && (!checkEmoji || !checkEmoji.metaData.code)) { const englishTrie = emojisTrie[CONST.LOCALES.DEFAULT]; if (englishTrie) { const englishEmoji = englishTrie.search(name); From dfffb8a6585b810e316d6654bb03773349f45ddc Mon Sep 17 00:00:00 2001 From: Pujan Date: Tue, 5 Sep 2023 17:42:10 +0530 Subject: [PATCH 065/134] rerender report actions on participants number change --- src/pages/home/report/ReportActionsView.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/pages/home/report/ReportActionsView.js b/src/pages/home/report/ReportActionsView.js index da475e61f749..a694c4996438 100755 --- a/src/pages/home/report/ReportActionsView.js +++ b/src/pages/home/report/ReportActionsView.js @@ -275,6 +275,10 @@ function arePropsEqual(oldProps, newProps) { return false; } + if (lodashGet(newProps, 'report.participantAccountIDs', 0) !== lodashGet(oldProps, 'report.participantAccountIDs', 0)) { + return false; + } + return _.isEqual(lodashGet(newProps.report, 'icons', []), lodashGet(oldProps.report, 'icons', [])); } From ee3cddf663a081ffa054c26905bb859c29b16bdd Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 20:44:20 +0200 Subject: [PATCH 066/134] refactoring in progress --- src/libs/actions/OnyxUpdateManager.js | 150 ++++++-------------------- src/libs/actions/OnyxUpdates.js | 99 ++++++++++++++++- 2 files changed, 132 insertions(+), 117 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 0028ee9776ec..25c98b0ce8e0 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -4,9 +4,8 @@ import ONYXKEYS from '../../ONYXKEYS'; import CONST from '../../CONST'; import Log from '../Log'; import * as SequentialQueue from '../Network/SequentialQueue'; -import PusherUtils from '../PusherUtils'; -import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; import * as App from './App'; +import * as OnyxUpdates from './OnyxUpdates' // This file is in charge of looking at the updateIDs coming from the server and comparing them to the last updateID that the client has. // If the client is behind the server, then we need to pause everything, get the missing updates from the server, apply those updates, @@ -17,79 +16,7 @@ import * as App from './App'; // The circular dependency happen because this file calls the API GetMissingOnyxUpdates which uses the SaveResponseInOnyx.js file // (as a middleware). Therefore, SaveResponseInOnyx.js can't import and use this file directly. -/** - * @param {Object} data - * @param {Object} data.request - * @param {Object} data.responseData - * @returns {Promise} - */ -function applyHTTPSOnyxUpdates({request, responseData}) { - console.debug('[OnyxUpdateManager] Applying https update'); - // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in - // the UI. See https://github.com/Expensify/App/issues/12775 for more info. - // 2023-08-31 - - const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; - // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then - // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained - // in successData/failureData until after the component has received and API data. - const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); - - return onyxDataUpdatePromise - .then(() => { - // Handle the request's success/failure data (client-side data) - if (responseData.jsonCode === 200 && request.successData) { - return updateHandler(request.successData); - } - if (responseData.jsonCode !== 200 && request.failureData) { - return updateHandler(request.failureData); - } - return Promise.resolve(); - }) - .then(() => { - console.debug('[OnyxUpdateManager] Done applying HTTPS update'); - }); -} - -/** - * @param {Object} data - * @param {Object} data.updates - * @returns {Promise} - */ -function applyPusherOnyxUpdates({updates}) { - console.debug('[OnyxUpdateManager] Applying pusher update'); - const pusherEventPromises = _.reduce( - updates, - (result, update) => { - result.push(PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); - return result; - }, - [], - ); - return Promise.all(pusherEventPromises).then(() => { - console.debug('[OnyxUpdateManager] Done applying Pusher update'); - }); -} - -/** - * @param {Object[]} updateParams - * @param {String} updateParams.type - * @param {Boolean} updateParams.unpauseQueue - * @param {Object} updateParams.data - * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' - * @returns {Promise} - */ -function applyOnyxUpdates({type, data, unpauseQueue = false}) { - console.debug(`[OnyxUpdateManager] Applying update type: ${type}`, data); - if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { - return applyHTTPSOnyxUpdates({...data, unpauseQueue}); - } - if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { - return applyPusherOnyxUpdates({...data, unpauseQueue}); - } -} // This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated let lastUpdateIDAppliedToClient = 0; @@ -109,52 +36,43 @@ export default () => { const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; - // If we don't have a previousUpdateID from the request, or if we if it's the less or equal w we currently have stored - // we can simply apply the updates and move on. - if (!previousUpdateIDFromServer || lastUpdateIDAppliedToClient === previousUpdateIDFromServer || (updateParams.type === CONST.ONYX_UPDATE_TYPES.HTTPS && (updateParams.data.request.command === 'OpenApp' || updateParams.data.request.command === 'ReconnectApp'))) { - console.debug(`[OnyxUpdateManager] Client is in sync with the server, applying updates`); - applyOnyxUpdates(updateParams); - } else if (lastUpdateIDFromServer <= lastUpdateIDAppliedToClient) { - console.debug(`[OnyxUpdateManager] Client is more up to date than the update received, skipping processing`); - } else { - // In cases where we received a previousUpdateID and it doesn't match our lastUpdateIDAppliedToClient - // we need to perform one of the 2 possible cases: - // - // 1. This is the first time we're receiving an lastUpdateID, so we need to do a final reconnectApp before - // fully migrating to the reliable updates mode; - // 2. This this client already has the reliable updates mode enabled, but it's missing some updates and it - // needs to fech those. - // - // To to both of those, we need to pause the sequential queue. This is important so that the updates are - // applied in their correct and specific order. If this queue was not paused, then there would be a lot of - // onyx data being applied while we are fetching the missing updates and that would put them all out of order. - SequentialQueue.pause(); - let promise; - - // The flow below is setting the promise to a reconnect app to address flow (1) explained above. - if (!lastUpdateIDAppliedToClient) { - console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); - Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); - promise = App.lastReconnectAppAfterActivatingReliableUpdates(); - } else { - // The flow below is setting the promise to a getMissingOnyxUpdates to address flow (2) explained above. - console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); - Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { - lastUpdateIDFromServer, - previousUpdateIDFromServer, - lastUpdateIDAppliedToClient, - }); - promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer); - } + // In cases where we received a previousUpdateID and it doesn't match our lastUpdateIDAppliedToClient + // we need to perform one of the 2 possible cases: + // + // 1. This is the first time we're receiving an lastUpdateID, so we need to do a final reconnectApp before + // fully migrating to the reliable updates mode; + // 2. This this client already has the reliable updates mode enabled, but it's missing some updates and it + // needs to fech those. + // + // To to both of those, we need to pause the sequential queue. This is important so that the updates are + // applied in their correct and specific order. If this queue was not paused, then there would be a lot of + // onyx data being applied while we are fetching the missing updates and that would put them all out of order. + SequentialQueue.pause(); + let promise; - promise.finally(() => { - console.debug('[OnyxUpdateManager] Done applying all updates'); - applyOnyxUpdates(updateParams).finally(() => { - SequentialQueue.unpause(); - }); + // The flow below is setting the promise to a reconnect app to address flow (1) explained above. + if (!lastUpdateIDAppliedToClient) { + console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); + Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); + promise = App.lastReconnectAppAfterActivatingReliableUpdates(); + } else { + // The flow below is setting the promise to a getMissingOnyxUpdates to address flow (2) explained above. + console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); + Log.info('Gap detected in update IDs from server so fetching incremental updates', true, { + lastUpdateIDFromServer, + previousUpdateIDFromServer, + lastUpdateIDAppliedToClient, }); + promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer); } + promise.finally(() => { + console.debug('[OnyxUpdateManager] Done applying all updates'); + OnyxUpdates.applyOnyxUpdates(updateParams).finally(() => { + SequentialQueue.unpause(); + }); + }); + if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { // Update this value so that it matches what was just received from the server Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateIDFromServer || 0); diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 8834fc4e34f7..f3caead988d4 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -1,5 +1,79 @@ import Onyx from 'react-native-onyx'; import ONYXKEYS from '../../ONYXKEYS'; +import * as QueuedOnyxUpdates from './QueuedOnyxUpdates' + + +/** + * @param {Object} data + * @param {Object} data.request + * @param {Object} data.responseData + * @returns {Promise} + */ +function applyHTTPSOnyxUpdates({request, responseData}) { + console.debug('[OnyxUpdateManager] Applying https update'); + // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in + // the UI. See https://github.com/Expensify/App/issues/12775 for more info. + const updateHandler = request.data.apiRequestType === CONST.API_REQUEST_TYPE.WRITE ? QueuedOnyxUpdates.queueOnyxUpdates : Onyx.update; + + // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then + // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained + // in successData/failureData until after the component has received and API data. + const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); + + return onyxDataUpdatePromise + .then(() => { + // Handle the request's success/failure data (client-side data) + if (responseData.jsonCode === 200 && request.successData) { + return updateHandler(request.successData); + } + if (responseData.jsonCode !== 200 && request.failureData) { + return updateHandler(request.failureData); + } + return Promise.resolve(); + }) + .then(() => { + console.debug('[OnyxUpdateManager] Done applying HTTPS update'); + }); +} + +/** + * @param {Object} data + * @param {Object} data.updates + * @returns {Promise} + */ +function applyPusherOnyxUpdates({updates}) { + console.debug('[OnyxUpdateManager] Applying pusher update'); + const pusherEventPromises = _.reduce( + updates, + (result, update) => { + result.push(PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); + return result; + }, + [], + ); + return Promise.all(pusherEventPromises).then(() => { + console.debug('[OnyxUpdateManager] Done applying Pusher update'); + }); +} + +/** + * @param {Object[]} updateParams + * @param {String} updateParams.type + * @param {Object} updateParams.data + * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' + * @returns {Promise} + */ +function applyOnyxUpdates({type, data}) { + console.debug(`[OnyxUpdateManager] Applying update type: ${type}`, data); + if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { + return applyHTTPSOnyxUpdates(data); + } + if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { + return applyPusherOnyxUpdates(data); + } +} /** * @param {Object[]} updateParams @@ -20,5 +94,28 @@ function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID }); } +// This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated +let lastUpdateIDAppliedToClient = 0; +Onyx.connect({ + key: ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, + callback: (val) => (lastUpdateIDAppliedToClient = val), +}); + + +function needsToUpdateClient(previousUpdateID = 0) { + + // If no previousUpdateID is sent, this is not a WRITE request so we don't need to update our current state + if(!previousUpdateID) { + return false; + } + + // If we don't have any value in lastUpdateIDAppliedToClient, this is the first time we're receiving anything, so we need to do a last reconnectApp + if(!lastUpdateIDAppliedToClient) { + return true; + } + + return lastUpdateIDAppliedToClient < previousUpdateID; +} + // eslint-disable-next-line import/prefer-default-export -export {saveUpdateInformation}; +export {saveUpdateInformation, needsToUpdateClient, applyOnyxUpdates}; From db642ebb41409868391dd300bac1dfd075e347bd Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 20:57:12 +0200 Subject: [PATCH 067/134] adding clarifying comment --- src/libs/API.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/libs/API.js b/src/libs/API.js index 9405fb8f3a51..4eade86a68bf 100644 --- a/src/libs/API.js +++ b/src/libs/API.js @@ -21,7 +21,8 @@ Request.use(Middleware.RecheckConnection); // Reauthentication - Handles jsonCode 407 which indicates an expired authToken. We need to reauthenticate and get a new authToken with our stored credentials. Request.use(Middleware.Reauthentication); -// SaveResponseInOnyx - Merges either the successData or failureData into Onyx depending on if the call was successful or not +// SaveResponseInOnyx - Merges either the successData or failureData into Onyx depending on if the call was successful or not. This needs to be the LAST middleware we use, don't add any +// middlewares after this. Request.use(Middleware.SaveResponseInOnyx); /** From bd72f2a514e66f0babd0b059a63b21ac6f3722b1 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 20:59:57 +0200 Subject: [PATCH 068/134] adding syncronous processing in case there's no need to fetch updates from the server --- src/libs/Middleware/SaveResponseInOnyx.js | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 448574af8101..e164a2bdb644 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -4,6 +4,9 @@ import ONYXKEYS from '../../ONYXKEYS'; import * as MemoryOnlyKeys from '../actions/MemoryOnlyKeys/MemoryOnlyKeys'; import * as OnyxUpdates from '../actions/OnyxUpdates'; +// If we're executing any of these requests, we don't need to trigger our OnyxUpdates flow to update the current data even if our current value is out of date. +const requestsToIgnoreLastUpdateID = ['OpenApp', 'ReconnectApp', 'GetMissingOnyxMessages']; + /** * @param {Promise} response * @param {Object} request @@ -31,7 +34,7 @@ function SaveResponseInOnyx(response, request) { // Sometimes we call requests that are successfull but they don't have any response or any success/failure data to set. Let's return early since // we don't need to store anything here. if (!onyxUpdates && !request.successData && !request.failureData) { - return; + return Promise.resolve(responseData); } // If there is an OnyxUpdate for using memory only keys, enable them @@ -44,6 +47,14 @@ function SaveResponseInOnyx(response, request) { return true; }); + if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.needsToUpdateClient(Number(responseData.previousUpdateID || 0))) { + return OnyxUpdates.applyOnyxUpdates({ + type: CONST.ONYX_UPDATE_TYPES.HTTPS, + request: request, + responseData: responseData + }); + } + // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server OnyxUpdates.saveUpdateInformation( { @@ -57,7 +68,7 @@ function SaveResponseInOnyx(response, request) { Number(responseData.previousUpdateID || 0), ); - return responseData; + return Promise.resolve(responseData); }); } From b758fd4b52aa5a5c72508b05fef6e29e65627a04 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 21:01:19 +0200 Subject: [PATCH 069/134] fixing parameters --- src/libs/Middleware/SaveResponseInOnyx.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index e164a2bdb644..6775a927c6d2 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -50,8 +50,10 @@ function SaveResponseInOnyx(response, request) { if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.needsToUpdateClient(Number(responseData.previousUpdateID || 0))) { return OnyxUpdates.applyOnyxUpdates({ type: CONST.ONYX_UPDATE_TYPES.HTTPS, - request: request, - responseData: responseData + data: { + request, + responseData, + }, }); } From fb9e4831d9435b4926c5a0027490737bcb6e051e Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 21:01:49 +0200 Subject: [PATCH 070/134] removing unecessary check for APIs --- src/libs/Middleware/SaveResponseInOnyx.js | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 6775a927c6d2..0ffc77c00e6a 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -18,18 +18,7 @@ function SaveResponseInOnyx(response, request) { if (!responseData) { return; } - - // The data for this response comes in two different formats: - // 1. Original format - this is what was sent before the RELIABLE_UPDATES project and will go away once RELIABLE_UPDATES is fully complete - // - The data is an array of objects, where each object is an onyx update - // Example: [{onyxMethod: 'whatever', key: 'foo', value: 'bar'}] - // 1. Reliable updates format - this is what was sent with the RELIABLE_UPDATES project and will be the format from now on - // - The data is an object, containing updateIDs from the server and an array of onyx updates (this array is the same format as the original format above) - // Example: {lastUpdateID: 1, previousUpdateID: 0, onyxData: [{onyxMethod: 'whatever', key: 'foo', value: 'bar'}]} - // NOTE: This is slightly different than the format of the pusher event data, where pusher has "updates" and HTTPS responses have "onyxData" (long story) - - // Supports both the old format and the new format - const onyxUpdates = _.isArray(responseData) ? responseData : responseData.onyxData; + const onyxUpdates = responseData.onyxData; // Sometimes we call requests that are successfull but they don't have any response or any success/failure data to set. Let's return early since // we don't need to store anything here. From 06d72505900c42041f298c0812ea06580dd89785 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 21:03:04 +0200 Subject: [PATCH 071/134] renaming redundant name --- src/libs/Middleware/SaveResponseInOnyx.js | 2 +- src/libs/actions/OnyxUpdateManager.js | 2 +- src/libs/actions/OnyxUpdates.js | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 0ffc77c00e6a..b1971ec3560a 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -37,7 +37,7 @@ function SaveResponseInOnyx(response, request) { }); if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.needsToUpdateClient(Number(responseData.previousUpdateID || 0))) { - return OnyxUpdates.applyOnyxUpdates({ + return OnyxUpdates.apply({ type: CONST.ONYX_UPDATE_TYPES.HTTPS, data: { request, diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 25c98b0ce8e0..bf378e683a34 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -68,7 +68,7 @@ export default () => { promise.finally(() => { console.debug('[OnyxUpdateManager] Done applying all updates'); - OnyxUpdates.applyOnyxUpdates(updateParams).finally(() => { + OnyxUpdates.apply(updateParams).finally(() => { SequentialQueue.unpause(); }); }); diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index f3caead988d4..730293c36907 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -65,7 +65,7 @@ function applyPusherOnyxUpdates({updates}) { * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' * @returns {Promise} */ -function applyOnyxUpdates({type, data}) { +function apply({type, data}) { console.debug(`[OnyxUpdateManager] Applying update type: ${type}`, data); if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { return applyHTTPSOnyxUpdates(data); @@ -118,4 +118,4 @@ function needsToUpdateClient(previousUpdateID = 0) { } // eslint-disable-next-line import/prefer-default-export -export {saveUpdateInformation, needsToUpdateClient, applyOnyxUpdates}; +export {saveUpdateInformation, needsToUpdateClient, apply}; From d896c7e60b1b93b90edeece1d22f299c851a70e8 Mon Sep 17 00:00:00 2001 From: Pavlo Tsimura Date: Sat, 2 Sep 2023 16:09:44 +0200 Subject: [PATCH 072/134] Add validation for rate <= 0 --- src/languages/en.ts | 1 + src/languages/es.ts | 1 + src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js | 4 +++- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/languages/en.ts b/src/languages/en.ts index 79bb1300010c..7289ac1faf83 100755 --- a/src/languages/en.ts +++ b/src/languages/en.ts @@ -1344,6 +1344,7 @@ export default { fastReimbursementsVBACopy: "You're all set to reimburse receipts from your bank account!", updateCustomUnitError: "Your changes couldn't be saved. The workspace was modified while you were offline, please try again.", invalidRateError: 'Please enter a valid rate', + lowRateError: 'Rate must be greater than 0', }, bills: { manageYourBills: 'Manage your bills', diff --git a/src/languages/es.ts b/src/languages/es.ts index 0252fce3a421..5daedfba2a4c 100644 --- a/src/languages/es.ts +++ b/src/languages/es.ts @@ -1372,6 +1372,7 @@ export default { fastReimbursementsVBACopy: '¡Todo listo para reembolsar recibos desde tu cuenta bancaria!', updateCustomUnitError: 'Los cambios no han podido ser guardados. El espacio de trabajo ha sido modificado mientras estabas desconectado. Por favor, inténtalo de nuevo.', invalidRateError: 'Por favor, introduce una tarifa válida', + lowRateError: 'La tarifa debe ser mayor que 0', }, bills: { manageYourBills: 'Gestiona tus facturas', diff --git a/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js b/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js index e72b02e18696..e7aee59bb854 100644 --- a/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js +++ b/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js @@ -93,9 +93,11 @@ class WorkspaceRateAndUnitPage extends React.Component { validate(values) { const errors = {}; const decimalSeparator = this.props.toLocaleDigit('.'); - const rateValueRegex = RegExp(String.raw`^\d{0,8}([${getPermittedDecimalSeparator(decimalSeparator)}]\d{1,3})?$`, 'i'); + const rateValueRegex = RegExp(String.raw`^-?\d{0,8}([${getPermittedDecimalSeparator(decimalSeparator)}]\d{1,3})?$`, 'i'); if (!rateValueRegex.test(values.rate) || values.rate === '') { errors.rate = 'workspace.reimburse.invalidRateError'; + } else if (parseFloat(values.rate) <= 0) { + errors.rate = 'workspace.reimburse.lowRateError' } return errors; } From a516500ea1329d913a4ba06b7f1e20fb7d2a5345 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 21:40:48 +0200 Subject: [PATCH 073/134] adding check on network if we should pause after a request is done --- src/libs/Network/SequentialQueue.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 2bbc766d868f..febf51ab94fb 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -44,7 +44,12 @@ function process() { // Set the current request to a promise awaiting its processing so that getCurrentRequest can be used to take some action after the current request has processed. currentRequest = Request.processWithMiddleware(requestToProcess, true) - .then(() => { + .then((responseData) => { + // While processing the request, we might return the property to pause the queue if we notice that we're out of date. We're doing this here so we avoid + // circular dependencies. + if(responseData.pauseQueue) { + pause(); + } PersistedRequests.remove(requestToProcess); RequestThrottle.clear(); return process(); From 440eaf9208deb4ea359dde20fbb38490e09521d6 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 21:41:39 +0200 Subject: [PATCH 074/134] adding new property on middleware response so we can block the queue if we need to hold the queue --- src/libs/Middleware/SaveResponseInOnyx.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index b1971ec3560a..4a7cca1dd6eb 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -59,7 +59,10 @@ function SaveResponseInOnyx(response, request) { Number(responseData.previousUpdateID || 0), ); - return Promise.resolve(responseData); + return Promise.resolve({ + ...responseData, + pauseQueue: true + }); }); } From 204cfd11d05c764c7fc26ed63625e8f111dd4a33 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 21:43:05 +0200 Subject: [PATCH 075/134] working on onyx updates queue so we don't lose updates when flushing --- src/libs/Network/SequentialQueue.js | 8 ++++---- src/libs/actions/QueuedOnyxUpdates.js | 24 ++++++++++++++++++++---- 2 files changed, 24 insertions(+), 8 deletions(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index febf51ab94fb..0e3db0663ce0 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -71,11 +71,11 @@ function process() { /** * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. */ -function flushAndClearOnyxUpdatesQueue() { +function flushOnyxUpdatesQueue() { if (isQueuePaused) { return; } - Onyx.update(QueuedOnyxUpdates.getQueuedUpdates()).then(QueuedOnyxUpdates.clear); + QueuedOnyxUpdates.flushQueue(); } function flush() { @@ -110,7 +110,7 @@ function flush() { isSequentialQueueRunning = false; resolveIsReadyPromise(); currentRequest = null; - flushAndClearOnyxUpdatesQueue(); + flushOnyxUpdatesQueue(); }); }, }); @@ -191,7 +191,7 @@ function unpause() { // Since the writes may happen async to the queue, in case we had any writes happen while the queue was paused // (because of race conditions), let's also apply the queued updates and clear them before continuing the queue. - flushAndClearOnyxUpdatesQueue(); + flushOnyxUpdatesQueue(); flush(); } diff --git a/src/libs/actions/QueuedOnyxUpdates.js b/src/libs/actions/QueuedOnyxUpdates.js index 486108dd56cf..30d6ee04cc9c 100644 --- a/src/libs/actions/QueuedOnyxUpdates.js +++ b/src/libs/actions/QueuedOnyxUpdates.js @@ -3,6 +3,8 @@ import ONYXKEYS from '../../ONYXKEYS'; // In this file we manage a queue of Onyx updates while the SequentialQueue is processing. There are functions to get the updates and clear the queue after saving the updates in Onyx. +let isFlushing = false; +let flushPromise; let queuedOnyxUpdates = []; Onyx.connect({ key: ONYXKEYS.QUEUED_ONYX_UPDATES, @@ -21,11 +23,25 @@ function clear() { Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, null); } +function internalFlush() { + const currentFlush = queuedOnyxUpdates; + queuedOnyxUpdates = []; + + Onyx.update(queuedOnyxUpdates) + return Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, null).then(() => isFlushing = false); +} + /** - * @returns {Array} + * @returns {Promise} */ -function getQueuedUpdates() { - return queuedOnyxUpdates; +function flushQueue() { + + if(isFlushing) { + flushPromise.then(internalFlush); + } + isFlushing = true; + flushPromise = internalFlush(); + return flushPromise; } -export {queueOnyxUpdates, clear, getQueuedUpdates}; +export {queueOnyxUpdates, clear, flushQueue}; From 798dde27cda1117620b921cb263203647ba0b919 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 22:16:58 +0200 Subject: [PATCH 076/134] a little bit of refactor --- src/libs/Network/SequentialQueue.js | 3 --- src/libs/actions/QueuedOnyxUpdates.js | 18 ++---------------- 2 files changed, 2 insertions(+), 19 deletions(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 0e3db0663ce0..8d937c16f7d7 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -189,9 +189,6 @@ function unpause() { console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); isQueuePaused = false; - // Since the writes may happen async to the queue, in case we had any writes happen while the queue was paused - // (because of race conditions), let's also apply the queued updates and clear them before continuing the queue. - flushOnyxUpdatesQueue(); flush(); } diff --git a/src/libs/actions/QueuedOnyxUpdates.js b/src/libs/actions/QueuedOnyxUpdates.js index 30d6ee04cc9c..af98f406f8fb 100644 --- a/src/libs/actions/QueuedOnyxUpdates.js +++ b/src/libs/actions/QueuedOnyxUpdates.js @@ -23,25 +23,11 @@ function clear() { Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, null); } -function internalFlush() { - const currentFlush = queuedOnyxUpdates; - queuedOnyxUpdates = []; - - Onyx.update(queuedOnyxUpdates) - return Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, null).then(() => isFlushing = false); -} - /** * @returns {Promise} */ function flushQueue() { - - if(isFlushing) { - flushPromise.then(internalFlush); - } - isFlushing = true; - flushPromise = internalFlush(); - return flushPromise; + return Onyx.update(queuedOnyxUpdates).then(clear); } -export {queueOnyxUpdates, clear, flushQueue}; +export {flushQueue}; From 4de4fb70793ddb8850d2ca087a3260cff50028f0 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 22:33:31 +0200 Subject: [PATCH 077/134] more refactor --- src/libs/Middleware/SaveResponseInOnyx.js | 25 ++++++++++------------- src/libs/actions/OnyxUpdateManager.js | 19 ++++++++--------- src/libs/actions/OnyxUpdates.js | 23 ++++++++++++--------- 3 files changed, 33 insertions(+), 34 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 4a7cca1dd6eb..a5e31462bae0 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -36,25 +36,22 @@ function SaveResponseInOnyx(response, request) { return true; }); + const responseToApply = { + type: CONST.ONYX_UPDATE_TYPES.HTTPS, + lastUpdateID: Number(responseData.lastUpdateID || 0), + data: { + request, + responseData, + }, + }; + if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.needsToUpdateClient(Number(responseData.previousUpdateID || 0))) { - return OnyxUpdates.apply({ - type: CONST.ONYX_UPDATE_TYPES.HTTPS, - data: { - request, - responseData, - }, - }); + return OnyxUpdates.apply(responseToApply); } // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server OnyxUpdates.saveUpdateInformation( - { - type: CONST.ONYX_UPDATE_TYPES.HTTPS, - data: { - request, - responseData, - }, - }, + responseToApply, Number(responseData.lastUpdateID || 0), Number(responseData.previousUpdateID || 0), ); diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index bf378e683a34..b10fefd0924c 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -42,7 +42,7 @@ export default () => { // 1. This is the first time we're receiving an lastUpdateID, so we need to do a final reconnectApp before // fully migrating to the reliable updates mode; // 2. This this client already has the reliable updates mode enabled, but it's missing some updates and it - // needs to fech those. + // needs to fetch those. // // To to both of those, we need to pause the sequential queue. This is important so that the updates are // applied in their correct and specific order. If this queue was not paused, then there would be a lot of @@ -54,6 +54,8 @@ export default () => { if (!lastUpdateIDAppliedToClient) { console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); + + // Since this is a full reconnectApp, we'll not apply the updates we received - those will come in the reconnect app request. promise = App.lastReconnectAppAfterActivatingReliableUpdates(); } else { // The flow below is setting the promise to a getMissingOnyxUpdates to address flow (2) explained above. @@ -63,20 +65,17 @@ export default () => { previousUpdateIDFromServer, lastUpdateIDAppliedToClient, }); - promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer); + promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).then(() => { + OnyxUpdates.apply({...updateParams, lastUpdateID: lastUpdateIDFromServer}).finally(() => { + console.debug('[OnyxUpdateManager] Done applying all updates'); + }); + }); } promise.finally(() => { - console.debug('[OnyxUpdateManager] Done applying all updates'); - OnyxUpdates.apply(updateParams).finally(() => { - SequentialQueue.unpause(); - }); + SequentialQueue.unpause(); }); - if (lastUpdateIDFromServer > lastUpdateIDAppliedToClient) { - // Update this value so that it matches what was just received from the server - Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateIDFromServer || 0); - } }, }); }; diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 730293c36907..7a1211907529 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -3,6 +3,13 @@ import ONYXKEYS from '../../ONYXKEYS'; import * as QueuedOnyxUpdates from './QueuedOnyxUpdates' +// This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated +let lastUpdateIDAppliedToClient = 0; +Onyx.connect({ + key: ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, + callback: (val) => (lastUpdateIDAppliedToClient = val), +}); + /** * @param {Object} data * @param {Object} data.request @@ -59,14 +66,18 @@ function applyPusherOnyxUpdates({updates}) { /** * @param {Object[]} updateParams * @param {String} updateParams.type + * @param {Number} updateParams.lastUpdateID * @param {Object} updateParams.data * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' * @returns {Promise} */ -function apply({type, data}) { - console.debug(`[OnyxUpdateManager] Applying update type: ${type}`, data); +function apply({lastUpdateID, type, data}) { + console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, data); + if (lastUpdateID && lastUpdateID > lastUpdateIDAppliedToClient) { + Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateID); + } if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { return applyHTTPSOnyxUpdates(data); } @@ -94,14 +105,6 @@ function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID }); } -// This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated -let lastUpdateIDAppliedToClient = 0; -Onyx.connect({ - key: ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, - callback: (val) => (lastUpdateIDAppliedToClient = val), -}); - - function needsToUpdateClient(previousUpdateID = 0) { // If no previousUpdateID is sent, this is not a WRITE request so we don't need to update our current state From b3da51b6fa1e59f6b5728d519f7de62ade6bd907 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 22:39:06 +0200 Subject: [PATCH 078/134] fixing User.js calls --- src/libs/actions/User.js | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index f723032f0431..04c4a51c8677 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -546,8 +546,6 @@ function subscribeToUserEvents() { // Handles the mega multipleEvents from Pusher which contains an array of single events. // Each single event is passed to PusherUtils in order to trigger the callbacks for that event PusherUtils.subscribeToPrivateUserChannelEvent(Pusher.TYPE.MULTIPLE_EVENTS, currentUserAccountID, (pushJSON) => { - let updates; - // The data for this push event comes in two different formats: // 1. Original format - this is what was sent before the RELIABLE_UPDATES project and will go away once RELIABLE_UPDATES is fully complete // - The data is an array of objects, where each object is an onyx update @@ -556,20 +554,29 @@ function subscribeToUserEvents() { // - The data is an object, containing updateIDs from the server and an array of onyx updates (this array is the same format as the original format above) // Example: {lastUpdateID: 1, previousUpdateID: 0, updates: [{onyxMethod: 'whatever', key: 'foo', value: 'bar'}]} if (_.isArray(pushJSON)) { - updates = pushJSON; - _.each(updates, (multipleEvent) => { + _.each(pushJSON, (multipleEvent) => { PusherUtils.triggerMultiEventHandler(multipleEvent.eventType, multipleEvent.data); }); return; } - OnyxUpdates.saveUpdateInformation( - { - type: CONST.ONYX_UPDATE_TYPES.PUSHER, - data: { - updates: pushJSON.updates, - }, + const updates = { + type: CONST.ONYX_UPDATE_TYPES.PUSHER, + lastUpdateID: Number(pushJSON.lastUpdateID || 0), + data: { + updates: pushJSON.updates, }, + }; + if (!OnyxUpdates.needsToUpdateClient(Number(responseData.previousUpdateID || 0))) { + OnyxUpdates.apply(responseToApply); + return; + } + + // If we reached this point, we need to pause the queue while we prepare to fetch older OnyxUpdates. This needs to happen here since adding it on OnyxUpdates + // would cause a circular reference issue. + SequentialQueue.pause(); + OnyxUpdates.saveUpdateInformation( + updates, Number(pushJSON.lastUpdateID || 0), Number(pushJSON.previousUpdateID || 0), ); From a07073b80e8ec3eca14bb24eb24a5acd68779de3 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 22:42:08 +0200 Subject: [PATCH 079/134] adding property --- src/types/onyx/OnyxUpdatesFromServer.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index c2c76afa0aa8..781a6b8564aa 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -3,6 +3,7 @@ import Request from './Request'; import Response from './Response'; type OnyxUpdatesFromServerData = { + lastUpdateID: number | string; request?: Request; response?: Response; updates?: OnyxUpdate[]; From 48934f8778591f2909e794ccbe55aba5daa0a3b4 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 22:43:44 +0200 Subject: [PATCH 080/134] returning responseData on applyHTTPSOnyxUpdates --- src/libs/actions/OnyxUpdates.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 7a1211907529..fb6cf018f8ba 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -40,6 +40,7 @@ function applyHTTPSOnyxUpdates({request, responseData}) { }) .then(() => { console.debug('[OnyxUpdateManager] Done applying HTTPS update'); + return responseData; }); } From d30a4eb9c958f8dc3aee242f6e9001f7b84f4c13 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 22:45:38 +0200 Subject: [PATCH 081/134] adding comment for clarity --- src/libs/Middleware/SaveResponseInOnyx.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index a5e31462bae0..c1890f6eb3b8 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -55,7 +55,9 @@ function SaveResponseInOnyx(response, request) { Number(responseData.lastUpdateID || 0), Number(responseData.previousUpdateID || 0), ); - + + // We'll add the pauseQueue property here to guarantee we're pausing the queue before we execute the next request. If we do it only on the trigger in + // OnyxUpdateManager, then we might have already started another request while we wait. return Promise.resolve({ ...responseData, pauseQueue: true From ec719bf5a6944cbd95eafe3c382610c9d5dd7440 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 22:48:11 +0200 Subject: [PATCH 082/134] clearing unused method --- src/libs/actions/QueuedOnyxUpdates.js | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/libs/actions/QueuedOnyxUpdates.js b/src/libs/actions/QueuedOnyxUpdates.js index af98f406f8fb..5aa8159624d7 100644 --- a/src/libs/actions/QueuedOnyxUpdates.js +++ b/src/libs/actions/QueuedOnyxUpdates.js @@ -11,14 +11,6 @@ Onyx.connect({ callback: (val) => (queuedOnyxUpdates = val || []), }); -/** - * @param {Array} updates Onyx updates to queue for later - * @returns {Promise} - */ -function queueOnyxUpdates(updates) { - return Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, [...queuedOnyxUpdates, ...updates]); -} - function clear() { Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, null); } From 7aab96e5980c721661aa65178dfea3524e91876b Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 23:00:19 +0200 Subject: [PATCH 083/134] prettier, fixing const reference --- src/libs/Middleware/SaveResponseInOnyx.js | 14 +++++--------- src/libs/Network/SequentialQueue.js | 3 +-- src/libs/actions/OnyxUpdateManager.js | 7 ++----- src/libs/actions/OnyxUpdates.js | 13 ++++++------- src/libs/actions/User.js | 6 +----- 5 files changed, 15 insertions(+), 28 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index c1890f6eb3b8..2cdab0630eb0 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -36,7 +36,7 @@ function SaveResponseInOnyx(response, request) { return true; }); - const responseToApply = { + const responseToApply = { type: CONST.ONYX_UPDATE_TYPES.HTTPS, lastUpdateID: Number(responseData.lastUpdateID || 0), data: { @@ -50,17 +50,13 @@ function SaveResponseInOnyx(response, request) { } // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server - OnyxUpdates.saveUpdateInformation( - responseToApply, - Number(responseData.lastUpdateID || 0), - Number(responseData.previousUpdateID || 0), - ); - - // We'll add the pauseQueue property here to guarantee we're pausing the queue before we execute the next request. If we do it only on the trigger in + OnyxUpdates.saveUpdateInformation(responseToApply, Number(responseData.lastUpdateID || 0), Number(responseData.previousUpdateID || 0)); + + // We'll add the pauseQueue property here to guarantee we're pausing the queue before we execute the next request. If we do it only on the trigger in // OnyxUpdateManager, then we might have already started another request while we wait. return Promise.resolve({ ...responseData, - pauseQueue: true + pauseQueue: true, }); }); } diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 8d937c16f7d7..dbb9edf18499 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -47,7 +47,7 @@ function process() { .then((responseData) => { // While processing the request, we might return the property to pause the queue if we notice that we're out of date. We're doing this here so we avoid // circular dependencies. - if(responseData.pauseQueue) { + if (responseData.pauseQueue) { pause(); } PersistedRequests.remove(requestToProcess); @@ -67,7 +67,6 @@ function process() { return currentRequest; } - /** * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. */ diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index b10fefd0924c..967b1f6515af 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -5,7 +5,7 @@ import CONST from '../../CONST'; import Log from '../Log'; import * as SequentialQueue from '../Network/SequentialQueue'; import * as App from './App'; -import * as OnyxUpdates from './OnyxUpdates' +import * as OnyxUpdates from './OnyxUpdates'; // This file is in charge of looking at the updateIDs coming from the server and comparing them to the last updateID that the client has. // If the client is behind the server, then we need to pause everything, get the missing updates from the server, apply those updates, @@ -16,8 +16,6 @@ import * as OnyxUpdates from './OnyxUpdates' // The circular dependency happen because this file calls the API GetMissingOnyxUpdates which uses the SaveResponseInOnyx.js file // (as a middleware). Therefore, SaveResponseInOnyx.js can't import and use this file directly. - - // This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated let lastUpdateIDAppliedToClient = 0; Onyx.connect({ @@ -67,7 +65,7 @@ export default () => { }); promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).then(() => { OnyxUpdates.apply({...updateParams, lastUpdateID: lastUpdateIDFromServer}).finally(() => { - console.debug('[OnyxUpdateManager] Done applying all updates'); + console.debug('[OnyxUpdateManager] Done applying all updates'); }); }); } @@ -75,7 +73,6 @@ export default () => { promise.finally(() => { SequentialQueue.unpause(); }); - }, }); }; diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index fb6cf018f8ba..6caa6c351a1e 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -1,7 +1,7 @@ import Onyx from 'react-native-onyx'; import ONYXKEYS from '../../ONYXKEYS'; -import * as QueuedOnyxUpdates from './QueuedOnyxUpdates' - +import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; +import CONST from './CONST'; // This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated let lastUpdateIDAppliedToClient = 0; @@ -76,7 +76,7 @@ function applyPusherOnyxUpdates({updates}) { */ function apply({lastUpdateID, type, data}) { console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, data); - if (lastUpdateID && lastUpdateID > lastUpdateIDAppliedToClient) { + if (lastUpdateID && lastUpdateID > lastUpdateIDAppliedToClient) { Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateID); } if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { @@ -107,14 +107,13 @@ function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID } function needsToUpdateClient(previousUpdateID = 0) { - // If no previousUpdateID is sent, this is not a WRITE request so we don't need to update our current state - if(!previousUpdateID) { + if (!previousUpdateID) { return false; } - + // If we don't have any value in lastUpdateIDAppliedToClient, this is the first time we're receiving anything, so we need to do a last reconnectApp - if(!lastUpdateIDAppliedToClient) { + if (!lastUpdateIDAppliedToClient) { return true; } diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index 425caebc6096..b2cba5b9adf4 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -575,11 +575,7 @@ function subscribeToUserEvents() { // If we reached this point, we need to pause the queue while we prepare to fetch older OnyxUpdates. This needs to happen here since adding it on OnyxUpdates // would cause a circular reference issue. SequentialQueue.pause(); - OnyxUpdates.saveUpdateInformation( - updates, - Number(pushJSON.lastUpdateID || 0), - Number(pushJSON.previousUpdateID || 0), - ); + OnyxUpdates.saveUpdateInformation(updates, Number(pushJSON.lastUpdateID || 0), Number(pushJSON.previousUpdateID || 0)); }); // Handles Onyx updates coming from Pusher through the mega multipleEvents. From 9ede8ad1ba3512361bf8b18ecc353a681c51d5fc Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Tue, 5 Sep 2023 23:10:21 +0200 Subject: [PATCH 084/134] fixing import to the right path --- src/libs/actions/OnyxUpdates.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 6caa6c351a1e..01b7ff7ec1bb 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -1,7 +1,7 @@ import Onyx from 'react-native-onyx'; import ONYXKEYS from '../../ONYXKEYS'; import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; -import CONST from './CONST'; +import CONST from '../../CONST'; // This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated let lastUpdateIDAppliedToClient = 0; From 8a73c0a5726056cde611399002ea935fda378c52 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 00:28:43 +0200 Subject: [PATCH 085/134] adding back a method that is used --- src/libs/actions/QueuedOnyxUpdates.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/libs/actions/QueuedOnyxUpdates.js b/src/libs/actions/QueuedOnyxUpdates.js index 5aa8159624d7..dbda87ea5530 100644 --- a/src/libs/actions/QueuedOnyxUpdates.js +++ b/src/libs/actions/QueuedOnyxUpdates.js @@ -11,6 +11,14 @@ Onyx.connect({ callback: (val) => (queuedOnyxUpdates = val || []), }); +/** + * @param {Array} updates Onyx updates to queue for later + * @returns {Promise} + */ +function queueOnyxUpdates(updates) { + return Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, [...queuedOnyxUpdates, ...updates]); +} + function clear() { Onyx.set(ONYXKEYS.QUEUED_ONYX_UPDATES, null); } @@ -22,4 +30,4 @@ function flushQueue() { return Onyx.update(queuedOnyxUpdates).then(clear); } -export {flushQueue}; +export {queueOnyxUpdates, flushQueue}; From a8697eed212e7c3366e116533ced66dc14600403 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 00:29:22 +0200 Subject: [PATCH 086/134] adding back the flush call when restarting the queue --- src/libs/Network/SequentialQueue.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index dbb9edf18499..2ff77a207c53 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -187,7 +187,7 @@ function unpause() { const numberOfPersistedRequests = PersistedRequests.getAll().length || 0; console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); isQueuePaused = false; - + flushOnyxUpdatesQueue(); flush(); } From 2cda55b87caa1c91b9a1d627bf4eb4aad1e4c567 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 00:30:03 +0200 Subject: [PATCH 087/134] adding sequentialqueue.unpause on promise cal --- src/libs/actions/OnyxUpdateManager.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 967b1f6515af..b8e58458b61c 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -63,15 +63,14 @@ export default () => { previousUpdateIDFromServer, lastUpdateIDAppliedToClient, }); - promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer).then(() => { - OnyxUpdates.apply({...updateParams, lastUpdateID: lastUpdateIDFromServer}).finally(() => { - console.debug('[OnyxUpdateManager] Done applying all updates'); - }); - }); + promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer); } promise.finally(() => { - SequentialQueue.unpause(); + OnyxUpdates.apply({...updateParams, lastUpdateID: lastUpdateIDFromServer}).finally(() => { + console.debug('[OnyxUpdateManager] Done applying all updates'); + SequentialQueue.unpause(); + }); }); }, }); From b333592c44990a4ffd8911586cc57905868a3cde Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 00:31:20 +0200 Subject: [PATCH 088/134] prettier and adding a check to ignore updates if they are older than current state --- src/libs/actions/OnyxUpdates.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 01b7ff7ec1bb..8d34213ac3ad 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -76,6 +76,11 @@ function applyPusherOnyxUpdates({updates}) { */ function apply({lastUpdateID, type, data}) { console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, data); + + if (lastUpdateID < lastUpdateIDAppliedToClient) { + console.debug('[OnyxUpdateManager] Update received was older than current state, returning without applying the updates'); + return new Promise().resolve(); + } if (lastUpdateID && lastUpdateID > lastUpdateIDAppliedToClient) { Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateID); } From 45d3a6df9dd91227bd1addd240fec1ec79f96dee Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 00:50:40 +0200 Subject: [PATCH 089/134] addressing comments, fixing lint issues and prettier --- src/libs/API.js | 2 +- src/libs/Middleware/SaveResponseInOnyx.js | 10 ++-- src/libs/Network/SequentialQueue.js | 62 ++++++++++++----------- src/libs/actions/App.js | 6 +-- src/libs/actions/OnyxUpdateManager.js | 34 +++++++------ src/libs/actions/OnyxUpdates.js | 13 +++-- src/libs/actions/QueuedOnyxUpdates.js | 2 - src/libs/actions/User.js | 4 +- 8 files changed, 71 insertions(+), 62 deletions(-) diff --git a/src/libs/API.js b/src/libs/API.js index 4eade86a68bf..491503f07381 100644 --- a/src/libs/API.js +++ b/src/libs/API.js @@ -22,7 +22,7 @@ Request.use(Middleware.RecheckConnection); Request.use(Middleware.Reauthentication); // SaveResponseInOnyx - Merges either the successData or failureData into Onyx depending on if the call was successful or not. This needs to be the LAST middleware we use, don't add any -// middlewares after this. +// middlewares after this, because the SequentialQueue depends on the result of this middleware to pause the queue (if needed) to bring the app to an up-to-date state. Request.use(Middleware.SaveResponseInOnyx); /** diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 2cdab0630eb0..ce178a2b2e16 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -4,7 +4,8 @@ import ONYXKEYS from '../../ONYXKEYS'; import * as MemoryOnlyKeys from '../actions/MemoryOnlyKeys/MemoryOnlyKeys'; import * as OnyxUpdates from '../actions/OnyxUpdates'; -// If we're executing any of these requests, we don't need to trigger our OnyxUpdates flow to update the current data even if our current value is out of date. +// If we're executing any of these requests, we don't need to trigger our OnyxUpdates flow to update the current data even if our current value is out of +// date because all these requests are updating the app to the most current state. const requestsToIgnoreLastUpdateID = ['OpenApp', 'ReconnectApp', 'GetMissingOnyxMessages']; /** @@ -45,18 +46,17 @@ function SaveResponseInOnyx(response, request) { }, }; - if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.needsToUpdateClient(Number(responseData.previousUpdateID || 0))) { + if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.doesClientNeedToBeUpdated(Number(responseData.previousUpdateID || 0))) { return OnyxUpdates.apply(responseToApply); } // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server OnyxUpdates.saveUpdateInformation(responseToApply, Number(responseData.lastUpdateID || 0), Number(responseData.previousUpdateID || 0)); - // We'll add the pauseQueue property here to guarantee we're pausing the queue before we execute the next request. If we do it only on the trigger in - // OnyxUpdateManager, then we might have already started another request while we wait. + // Ensure the queue is paused while the client resolves the gap in onyx updates so that updates are guaranteed to happen in a specific order. return Promise.resolve({ ...responseData, - pauseQueue: true, + shouldPauseQueue: true, }); }); } diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 2ff77a207c53..e3e6f4b3f780 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -21,6 +21,33 @@ let isSequentialQueueRunning = false; let currentRequest = null; let isQueuePaused = false; +/** + * Puts the queue into a paused state so that no requests will be processed + */ +function pause() { + if (isQueuePaused) { + return; + } + + console.debug('[SequentialQueue] Pausing the queue'); + isQueuePaused = true; +} + +/** + * Unpauses the queue and flushes all the requests that were in it or were added to it while paused + */ +function unpause() { + if (!isQueuePaused) { + return; + } + + const numberOfPersistedRequests = PersistedRequests.getAll().length || 0; + console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); + isQueuePaused = false; + flushOnyxUpdatesQueue(); + flush(); +} + /** * Process any persisted requests, when online, one at a time until the queue is empty. * @@ -45,9 +72,9 @@ function process() { // Set the current request to a promise awaiting its processing so that getCurrentRequest can be used to take some action after the current request has processed. currentRequest = Request.processWithMiddleware(requestToProcess, true) .then((responseData) => { - // While processing the request, we might return the property to pause the queue if we notice that we're out of date. We're doing this here so we avoid - // circular dependencies. - if (responseData.pauseQueue) { + // A response might indicate that the queue should be paused. This happens when a gap in onyx updates is detected between the client and the server and + // that gap needs resolved before the queue can continue. + if (responseData.shouldPauseQueue) { pause(); } PersistedRequests.remove(requestToProcess); @@ -71,6 +98,8 @@ function process() { * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. */ function flushOnyxUpdatesQueue() { + // The only situation where the queue is paused is if we found a gap between the app current data state and our server's. If that happens, + // we'll trigger async calls to make the client updated again. While we do that, we don't want to insert anything in Onyx. if (isQueuePaused) { return; } @@ -164,31 +193,4 @@ function waitForIdle() { return isReadyPromise; } -/** - * Puts the queue into a paused state so that no requests will be processed - */ -function pause() { - if (isQueuePaused) { - return; - } - - console.debug('[SequentialQueue] Pausing the queue'); - isQueuePaused = true; -} - -/** - * Unpauses the queue and flushes all the requests that were in it or were added to it while paused - */ -function unpause() { - if (!isQueuePaused) { - return; - } - - const numberOfPersistedRequests = PersistedRequests.getAll().length || 0; - console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); - isQueuePaused = false; - flushOnyxUpdatesQueue(); - flush(); -} - export {flush, getCurrentRequest, isRunning, push, waitForIdle, pause, unpause}; diff --git a/src/libs/actions/App.js b/src/libs/actions/App.js index 076a89917d7e..90c2a9ec4f16 100644 --- a/src/libs/actions/App.js +++ b/src/libs/actions/App.js @@ -213,7 +213,7 @@ function reconnectApp(updateIDFrom = 0) { * state because of race conditions between reconnectApp and other pusher updates being applied at the same time. * @return {Promise} */ -function lastReconnectAppAfterActivatingReliableUpdates() { +function finalReconnectAppAfterActivatingReliableUpdates() { console.debug(`[OnyxUpdates] Executing last reconnect app with promise`); return getPolicyParamsForOpenOrReconnect().then((policyParams) => { const params = {...policyParams}; @@ -230,7 +230,7 @@ function lastReconnectAppAfterActivatingReliableUpdates() { // It is SUPER BAD FORM to return promises from action methods. // DO NOT FOLLOW THIS PATTERN!!!!! // It was absolutely necessary in order to not break the app while migrating to the new reliable updates pattern. This method will be removed - // as soon as we have everyone migrated to it + // as soon as we have everyone migrated to the reliableUpdate beta. // eslint-disable-next-line rulesdir/no-api-side-effects-method return API.makeRequestWithSideEffects('ReconnectApp', params, getOnyxDataForOpenOrReconnect()); }); @@ -471,5 +471,5 @@ export { beginDeepLinkRedirectAfterTransition, createWorkspaceAndNavigateToIt, getMissingOnyxUpdates, - lastReconnectAppAfterActivatingReliableUpdates, + finalReconnectAppAfterActivatingReliableUpdates, }; diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index b8e58458b61c..8d0335ed03b7 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -1,22 +1,25 @@ -import _ from 'underscore'; import Onyx from 'react-native-onyx'; import ONYXKEYS from '../../ONYXKEYS'; -import CONST from '../../CONST'; import Log from '../Log'; import * as SequentialQueue from '../Network/SequentialQueue'; import * as App from './App'; import * as OnyxUpdates from './OnyxUpdates'; // This file is in charge of looking at the updateIDs coming from the server and comparing them to the last updateID that the client has. -// If the client is behind the server, then we need to pause everything, get the missing updates from the server, apply those updates, -// then restart everything. This will ensure that the client is up-to-date with the server and all the updates have been applied -// in the correct order. +// If the client is behind the server, then we need to +// 1. Pause all sequential queue requests +// 2. Pause all Onyx updates from Pusher +// 3. Get the missing updates from the server +// 4. Apply those updates +// 5. Apply the original update that triggered this request (it could have come from either HTTPS or Pusher) +// 6. Restart the sequential queue +// 7. Restart the Onyx updates from Pusher +// This will ensure that the client is up-to-date with the server and all the updates have been applied in the correct order. // It's important that this file is separate and not imported by OnyxUpdates.js, so that there are no circular dependencies. Onyx -// is used as a pub/sub mechanism to break out of the circular dependencies. -// The circular dependency happen because this file calls the API GetMissingOnyxUpdates which uses the SaveResponseInOnyx.js file +// is used as a pub/sub mechanism to break out of the circular dependency. +// The circular dependency happens because this file calls API.GetMissingOnyxUpdates() which uses the SaveResponseInOnyx.js file // (as a middleware). Therefore, SaveResponseInOnyx.js can't import and use this file directly. -// This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated let lastUpdateIDAppliedToClient = 0; Onyx.connect({ key: ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, @@ -38,23 +41,22 @@ export default () => { // we need to perform one of the 2 possible cases: // // 1. This is the first time we're receiving an lastUpdateID, so we need to do a final reconnectApp before - // fully migrating to the reliable updates mode; - // 2. This this client already has the reliable updates mode enabled, but it's missing some updates and it + // fully migrating to the reliable updates mode. + // 2. This client already has the reliable updates mode enabled, but it's missing some updates and it // needs to fetch those. // - // To to both of those, we need to pause the sequential queue. This is important so that the updates are + // For both of those, we need to pause the sequential queue. This is important so that the updates are // applied in their correct and specific order. If this queue was not paused, then there would be a lot of // onyx data being applied while we are fetching the missing updates and that would put them all out of order. SequentialQueue.pause(); - let promise; + let canUnpauseQueuePromise; // The flow below is setting the promise to a reconnect app to address flow (1) explained above. if (!lastUpdateIDAppliedToClient) { - console.debug('[OnyxUpdateManager] Client has not gotten reliable updates before so reconnecting the app to start the process'); Log.info('Client has not gotten reliable updates before so reconnecting the app to start the process'); // Since this is a full reconnectApp, we'll not apply the updates we received - those will come in the reconnect app request. - promise = App.lastReconnectAppAfterActivatingReliableUpdates(); + canUnpauseQueuePromise = App.finalReconnectAppAfterActivatingReliableUpdates(); } else { // The flow below is setting the promise to a getMissingOnyxUpdates to address flow (2) explained above. console.debug(`[OnyxUpdateManager] Client is behind the server by ${previousUpdateIDFromServer - lastUpdateIDAppliedToClient} so fetching incremental updates`); @@ -63,10 +65,10 @@ export default () => { previousUpdateIDFromServer, lastUpdateIDAppliedToClient, }); - promise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer); + canUnpauseQueuePromise = App.getMissingOnyxUpdates(lastUpdateIDAppliedToClient, lastUpdateIDFromServer); } - promise.finally(() => { + canUnpauseQueuePromise.finally(() => { OnyxUpdates.apply({...updateParams, lastUpdateID: lastUpdateIDFromServer}).finally(() => { console.debug('[OnyxUpdateManager] Done applying all updates'); SequentialQueue.unpause(); diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 8d34213ac3ad..939c2d4a50d2 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -1,9 +1,12 @@ +import _ from 'underscore'; +import PusherUtils from '../PusherUtils'; import Onyx from 'react-native-onyx'; import ONYXKEYS from '../../ONYXKEYS'; import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; import CONST from '../../CONST'; -// This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated +// This key needs to be separate from ONYXKEYS.ONYX_UPDATES_FROM_SERVER so that it can be updated without triggering the callback when the server IDs are updated. If that +// callback were triggered it would lead to duplicate processing of server updates. let lastUpdateIDAppliedToClient = 0; Onyx.connect({ key: ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, @@ -111,7 +114,11 @@ function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID }); } -function needsToUpdateClient(previousUpdateID = 0) { +/** + * This function will receive the previousUpdateID from any request/pusher update that has it, compare to our current app state + * and return if an update is needed + */ +function doesClientNeedToBeUpdated(previousUpdateID = 0) { // If no previousUpdateID is sent, this is not a WRITE request so we don't need to update our current state if (!previousUpdateID) { return false; @@ -126,4 +133,4 @@ function needsToUpdateClient(previousUpdateID = 0) { } // eslint-disable-next-line import/prefer-default-export -export {saveUpdateInformation, needsToUpdateClient, apply}; +export {saveUpdateInformation, doesClientNeedToBeUpdated, apply}; diff --git a/src/libs/actions/QueuedOnyxUpdates.js b/src/libs/actions/QueuedOnyxUpdates.js index dbda87ea5530..06f15be1340f 100644 --- a/src/libs/actions/QueuedOnyxUpdates.js +++ b/src/libs/actions/QueuedOnyxUpdates.js @@ -3,8 +3,6 @@ import ONYXKEYS from '../../ONYXKEYS'; // In this file we manage a queue of Onyx updates while the SequentialQueue is processing. There are functions to get the updates and clear the queue after saving the updates in Onyx. -let isFlushing = false; -let flushPromise; let queuedOnyxUpdates = []; Onyx.connect({ key: ONYXKEYS.QUEUED_ONYX_UPDATES, diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index b2cba5b9adf4..a54568463c70 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -567,8 +567,8 @@ function subscribeToUserEvents() { updates: pushJSON.updates, }, }; - if (!OnyxUpdates.needsToUpdateClient(Number(responseData.previousUpdateID || 0))) { - OnyxUpdates.apply(responseToApply); + if (!OnyxUpdates.doesClientNeedToBeUpdated(Number(pushJSON.previousUpdateID || 0))) { + OnyxUpdates.apply(updates); return; } From 7e0e60a0811fcdf3f2e5e8297db96f6f7b4d34e2 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 00:58:03 +0200 Subject: [PATCH 090/134] lint --- src/libs/Network/SequentialQueue.js | 92 ++++++++++++++--------------- src/libs/actions/OnyxUpdates.js | 4 +- 2 files changed, 49 insertions(+), 47 deletions(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index e3e6f4b3f780..c4f6100dfb0f 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -48,52 +48,6 @@ function unpause() { flush(); } -/** - * Process any persisted requests, when online, one at a time until the queue is empty. - * - * If a request fails due to some kind of network error, such as a request being throttled or when our backend is down, then we retry it with an exponential back off process until a response - * is successfully returned. The first time a request fails we set a random, small, initial wait time. After waiting, we retry the request. If there are subsequent failures the request wait - * time is doubled creating an exponential back off in the frequency of requests hitting the server. Since the initial wait time is random and it increases exponentially, the load of - * requests to our backend is evenly distributed and it gradually decreases with time, which helps the servers catch up. - * @returns {Promise} - */ -function process() { - // When the queue is paused, return early. This prevents any new requests from happening. The queue will be flushed again when the queue is unpaused. - if (isQueuePaused) { - return Promise.resolve(); - } - - const persistedRequests = PersistedRequests.getAll(); - if (_.isEmpty(persistedRequests) || NetworkStore.isOffline()) { - return Promise.resolve(); - } - const requestToProcess = persistedRequests[0]; - - // Set the current request to a promise awaiting its processing so that getCurrentRequest can be used to take some action after the current request has processed. - currentRequest = Request.processWithMiddleware(requestToProcess, true) - .then((responseData) => { - // A response might indicate that the queue should be paused. This happens when a gap in onyx updates is detected between the client and the server and - // that gap needs resolved before the queue can continue. - if (responseData.shouldPauseQueue) { - pause(); - } - PersistedRequests.remove(requestToProcess); - RequestThrottle.clear(); - return process(); - }) - .catch((error) => { - // On sign out we cancel any in flight requests from the user. Since that user is no longer signed in their requests should not be retried. - // Duplicate records don't need to be retried as they just mean the record already exists on the server - if (error.name === CONST.ERROR.REQUEST_CANCELLED || error.message === CONST.ERROR.DUPLICATE_RECORD) { - PersistedRequests.remove(requestToProcess); - RequestThrottle.clear(); - return process(); - } - return RequestThrottle.sleep().then(process); - }); - return currentRequest; -} - /** * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. */ @@ -144,6 +98,52 @@ function flush() { }); } +/** + * Process any persisted requests, when online, one at a time until the queue is empty. + * + * If a request fails due to some kind of network error, such as a request being throttled or when our backend is down, then we retry it with an exponential back off process until a response + * is successfully returned. The first time a request fails we set a random, small, initial wait time. After waiting, we retry the request. If there are subsequent failures the request wait + * time is doubled creating an exponential back off in the frequency of requests hitting the server. Since the initial wait time is random and it increases exponentially, the load of + * requests to our backend is evenly distributed and it gradually decreases with time, which helps the servers catch up. + * @returns {Promise} + */ +function process() { + // When the queue is paused, return early. This prevents any new requests from happening. The queue will be flushed again when the queue is unpaused. + if (isQueuePaused) { + return Promise.resolve(); + } + + const persistedRequests = PersistedRequests.getAll(); + if (_.isEmpty(persistedRequests) || NetworkStore.isOffline()) { + return Promise.resolve(); + } + const requestToProcess = persistedRequests[0]; + + // Set the current request to a promise awaiting its processing so that getCurrentRequest can be used to take some action after the current request has processed. + currentRequest = Request.processWithMiddleware(requestToProcess, true) + .then((responseData) => { + // A response might indicate that the queue should be paused. This happens when a gap in onyx updates is detected between the client and the server and + // that gap needs resolved before the queue can continue. + if (responseData.shouldPauseQueue) { + pause(); + } + PersistedRequests.remove(requestToProcess); + RequestThrottle.clear(); + return process(); + }) + .catch((error) => { + // On sign out we cancel any in flight requests from the user. Since that user is no longer signed in their requests should not be retried. + // Duplicate records don't need to be retried as they just mean the record already exists on the server + if (error.name === CONST.ERROR.REQUEST_CANCELLED || error.message === CONST.ERROR.DUPLICATE_RECORD) { + PersistedRequests.remove(requestToProcess); + RequestThrottle.clear(); + return process(); + } + return RequestThrottle.sleep().then(process); + }); + return currentRequest; +} + /** * @returns {Boolean} */ diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 939c2d4a50d2..29c3f39d16dd 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -1,6 +1,6 @@ +import Onyx from 'react-native-onyx'; import _ from 'underscore'; import PusherUtils from '../PusherUtils'; -import Onyx from 'react-native-onyx'; import ONYXKEYS from '../../ONYXKEYS'; import * as QueuedOnyxUpdates from './QueuedOnyxUpdates'; import CONST from '../../CONST'; @@ -117,6 +117,8 @@ function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID /** * This function will receive the previousUpdateID from any request/pusher update that has it, compare to our current app state * and return if an update is needed + * @param {Number} previousUpdateID The previousUpdateID contained in the response object + * @returns {Boolean} */ function doesClientNeedToBeUpdated(previousUpdateID = 0) { // If no previousUpdateID is sent, this is not a WRITE request so we don't need to update our current state From 1d91a4def7cb0c8349ac43d5e474e5b7b246b26b Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 01:06:38 +0200 Subject: [PATCH 091/134] fixing order hopefully for the last time for linter --- src/libs/Network/SequentialQueue.js | 106 ++++++++++++++-------------- 1 file changed, 53 insertions(+), 53 deletions(-) diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index c4f6100dfb0f..56a11b492442 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -33,21 +33,6 @@ function pause() { isQueuePaused = true; } -/** - * Unpauses the queue and flushes all the requests that were in it or were added to it while paused - */ -function unpause() { - if (!isQueuePaused) { - return; - } - - const numberOfPersistedRequests = PersistedRequests.getAll().length || 0; - console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); - isQueuePaused = false; - flushOnyxUpdatesQueue(); - flush(); -} - /** * Gets the current Onyx queued updates, apply them and clear the queue if the queue is not paused. */ @@ -60,44 +45,6 @@ function flushOnyxUpdatesQueue() { QueuedOnyxUpdates.flushQueue(); } -function flush() { - // When the queue is paused, return early. This will keep an requests in the queue and they will get flushed again when the queue is unpaused - if (isQueuePaused) { - return; - } - - if (isSequentialQueueRunning || _.isEmpty(PersistedRequests.getAll())) { - return; - } - - // ONYXKEYS.PERSISTED_REQUESTS is shared across clients, thus every client/tab will have a copy - // It is very important to only process the queue from leader client otherwise requests will be duplicated. - if (!ActiveClientManager.isClientTheLeader()) { - return; - } - - isSequentialQueueRunning = true; - - // Reset the isReadyPromise so that the queue will be flushed as soon as the request is finished - isReadyPromise = new Promise((resolve) => { - resolveIsReadyPromise = resolve; - }); - - // Ensure persistedRequests are read from storage before proceeding with the queue - const connectionID = Onyx.connect({ - key: ONYXKEYS.PERSISTED_REQUESTS, - callback: () => { - Onyx.disconnect(connectionID); - process().finally(() => { - isSequentialQueueRunning = false; - resolveIsReadyPromise(); - currentRequest = null; - flushOnyxUpdatesQueue(); - }); - }, - }); -} - /** * Process any persisted requests, when online, one at a time until the queue is empty. * @@ -144,6 +91,59 @@ function process() { return currentRequest; } +function flush() { + // When the queue is paused, return early. This will keep an requests in the queue and they will get flushed again when the queue is unpaused + if (isQueuePaused) { + return; + } + + if (isSequentialQueueRunning || _.isEmpty(PersistedRequests.getAll())) { + return; + } + + // ONYXKEYS.PERSISTED_REQUESTS is shared across clients, thus every client/tab will have a copy + // It is very important to only process the queue from leader client otherwise requests will be duplicated. + if (!ActiveClientManager.isClientTheLeader()) { + return; + } + + isSequentialQueueRunning = true; + + // Reset the isReadyPromise so that the queue will be flushed as soon as the request is finished + isReadyPromise = new Promise((resolve) => { + resolveIsReadyPromise = resolve; + }); + + // Ensure persistedRequests are read from storage before proceeding with the queue + const connectionID = Onyx.connect({ + key: ONYXKEYS.PERSISTED_REQUESTS, + callback: () => { + Onyx.disconnect(connectionID); + process().finally(() => { + isSequentialQueueRunning = false; + resolveIsReadyPromise(); + currentRequest = null; + flushOnyxUpdatesQueue(); + }); + }, + }); +} + +/** + * Unpauses the queue and flushes all the requests that were in it or were added to it while paused + */ +function unpause() { + if (!isQueuePaused) { + return; + } + + const numberOfPersistedRequests = PersistedRequests.getAll().length || 0; + console.debug(`[SequentialQueue] Unpausing the queue and flushing ${numberOfPersistedRequests} requests`); + isQueuePaused = false; + flushOnyxUpdatesQueue(); + flush(); +} + /** * @returns {Boolean} */ From acb86ef4c7a6b997644fe9e70d702b0cc8ce36a5 Mon Sep 17 00:00:00 2001 From: Anusha Date: Wed, 6 Sep 2023 05:03:47 +0500 Subject: [PATCH 092/134] improve code readability --- src/libs/ReportActionsUtils.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/libs/ReportActionsUtils.js b/src/libs/ReportActionsUtils.js index 7582dd5258ed..768034be785a 100644 --- a/src/libs/ReportActionsUtils.js +++ b/src/libs/ReportActionsUtils.js @@ -113,10 +113,8 @@ function isWhisperAction(action) { * @returns {Boolean} */ function isThreadParentMessage(reportAction, reportID) { - return ( - lodashGet(reportAction, 'childType', '') === CONST.REPORT.TYPE.CHAT && - (lodashGet(reportAction, 'childVisibleActionCount', 0) > 0 || (!_.isUndefined(reportAction.childReportID) && reportAction.childReportID.toString() === reportID)) - ); + const {childType, childVisibleActionCount = 0, childReportID} = reportAction; + return childType === CONST.REPORT.TYPE.CHAT && (childVisibleActionCount > 0 || String(childReportID) === reportID); } /** From d0d0d3f11a315b31ed96118388e62aa181d1a668 Mon Sep 17 00:00:00 2001 From: Bernhard Owen Josephus Date: Wed, 6 Sep 2023 12:00:27 +0800 Subject: [PATCH 093/134] remove bottom position --- src/components/Composer/index.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/Composer/index.js b/src/components/Composer/index.js index cbd22cc39dfd..251c0cc1e33c 100755 --- a/src/components/Composer/index.js +++ b/src/components/Composer/index.js @@ -413,7 +413,6 @@ function Composer({ Date: Wed, 6 Sep 2023 17:59:37 +0500 Subject: [PATCH 094/134] apply suggested changes --- src/libs/ReportActionsUtils.js | 2 +- src/pages/home/report/ReportActionItemMessage.js | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/libs/ReportActionsUtils.js b/src/libs/ReportActionsUtils.js index 768034be785a..c68cbd84a9f8 100644 --- a/src/libs/ReportActionsUtils.js +++ b/src/libs/ReportActionsUtils.js @@ -109,7 +109,7 @@ function isWhisperAction(action) { * Returns whether the comment is a thread parent message/the first message in a thread * * @param {Object} reportAction - * @param {Number} reportID + * @param {String} reportID * @returns {Boolean} */ function isThreadParentMessage(reportAction, reportID) { diff --git a/src/pages/home/report/ReportActionItemMessage.js b/src/pages/home/report/ReportActionItemMessage.js index 6e25702c821d..bc92889158d0 100644 --- a/src/pages/home/report/ReportActionItemMessage.js +++ b/src/pages/home/report/ReportActionItemMessage.js @@ -23,6 +23,9 @@ const propTypes = { /** Whether or not the message is hidden by moderation */ isHidden: PropTypes.bool, + /** The ID of the report */ + reportID: PropTypes.string.isRequired, + /** localization props */ ...withLocalizePropTypes, }; From 7ab2d523417623d50a4ca91c76c9f19f567423a0 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Sep 2023 19:18:56 +0200 Subject: [PATCH 095/134] fixing resolve response --- src/libs/PusherUtils.js | 2 +- src/libs/actions/OnyxUpdates.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/PusherUtils.js b/src/libs/PusherUtils.js index 7fdd12cf6296..b4615d3c7d8b 100644 --- a/src/libs/PusherUtils.js +++ b/src/libs/PusherUtils.js @@ -22,7 +22,7 @@ function subscribeToMultiEvent(eventType, callback) { */ function triggerMultiEventHandler(eventType, data) { if (!multiEventCallbackMapping[eventType]) { - return new Promise().resolve(); + return Promise.resolve(); } return multiEventCallbackMapping[eventType](data); } diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 29c3f39d16dd..bd313c221575 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -82,7 +82,7 @@ function apply({lastUpdateID, type, data}) { if (lastUpdateID < lastUpdateIDAppliedToClient) { console.debug('[OnyxUpdateManager] Update received was older than current state, returning without applying the updates'); - return new Promise().resolve(); + return Promise.resolve(); } if (lastUpdateID && lastUpdateID > lastUpdateIDAppliedToClient) { Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateID); From 30d8eafe4df5d310bade33b2b4301a583c053cae Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Thu, 7 Sep 2023 00:49:19 +0200 Subject: [PATCH 096/134] fixing check to apply updates in case lastUpdateID is 0 --- src/libs/actions/OnyxUpdates.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index bd313c221575..27b18cdec9c7 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -80,7 +80,7 @@ function applyPusherOnyxUpdates({updates}) { function apply({lastUpdateID, type, data}) { console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, data); - if (lastUpdateID < lastUpdateIDAppliedToClient) { + if (lastUpdateID && lastUpdateID < lastUpdateIDAppliedToClient) { console.debug('[OnyxUpdateManager] Update received was older than current state, returning without applying the updates'); return Promise.resolve(); } From 03c893372d29a4096835c7d139c9a36538ec9bcf Mon Sep 17 00:00:00 2001 From: Yuwen Memon Date: Wed, 6 Sep 2023 17:14:05 -0700 Subject: [PATCH 097/134] Add policyRecentlyUsedCategories_ as collection key --- src/ONYXKEYS.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/ONYXKEYS.ts b/src/ONYXKEYS.ts index b3ef88cc0094..05131b6cee31 100755 --- a/src/ONYXKEYS.ts +++ b/src/ONYXKEYS.ts @@ -242,6 +242,7 @@ const ONYXKEYS = { POLICY: 'policy_', POLICY_MEMBERS: 'policyMembers_', POLICY_CATEGORIES: 'policyCategories_', + POLICY_RECENTLY_USED_CATEGORIES: 'policyRecentlyUsedCategories_', WORKSPACE_INVITE_MEMBERS_DRAFT: 'workspaceInviteMembersDraft_', REPORT: 'report_', REPORT_ACTIONS: 'reportActions_', From a7671fea9c60d259a956d896fbfd76e6831cff3f Mon Sep 17 00:00:00 2001 From: Yuwen Memon Date: Wed, 6 Sep 2023 17:18:05 -0700 Subject: [PATCH 098/134] Add RecentlyUsedCategories type --- src/types/onyx/RecentlyUsedCategories.ts | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 src/types/onyx/RecentlyUsedCategories.ts diff --git a/src/types/onyx/RecentlyUsedCategories.ts b/src/types/onyx/RecentlyUsedCategories.ts new file mode 100644 index 000000000000..167506599134 --- /dev/null +++ b/src/types/onyx/RecentlyUsedCategories.ts @@ -0,0 +1,3 @@ +type RecentlyUsedCategories = Array; + +export default RecentlyUsedCategories; From 24d9957bab45c3b0a43b3a5c44e537d09632dd62 Mon Sep 17 00:00:00 2001 From: Pujan Date: Thu, 7 Sep 2023 18:08:11 +0530 Subject: [PATCH 099/134] prevent auto focus for transaction thread empty chat --- .../home/report/ReportActionCompose/ComposerWithSuggestions.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js index 36b0af156ae5..1496b6757b7e 100644 --- a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js +++ b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js @@ -111,7 +111,8 @@ function ComposerWithSuggestions({ const maxComposerLines = isSmallScreenWidth ? CONST.COMPOSER.MAX_LINES_SMALL_SCREEN : CONST.COMPOSER.MAX_LINES; const isEmptyChat = useMemo(() => _.size(reportActions) === 1, [reportActions]); - const shouldAutoFocus = !modal.isVisible && (shouldFocusInputOnScreenFocus || isEmptyChat) && shouldShowComposeInput; + const parentReportAction = ReportActionsUtils.getParentReportAction(report); + const shouldAutoFocus = !modal.isVisible && (shouldFocusInputOnScreenFocus || (isEmptyChat && !ReportActionsUtils.isTransactionThread(parentReportAction))) && shouldShowComposeInput; const valueRef = useRef(value); valueRef.current = value; From fd4c4a4b78384674e9e6260a3763d68edb333c23 Mon Sep 17 00:00:00 2001 From: Pujan Date: Thu, 7 Sep 2023 19:14:28 +0530 Subject: [PATCH 100/134] lint fix --- .../report/ReportActionCompose/ComposerWithSuggestions.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js index 1496b6757b7e..45882dc23a78 100644 --- a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js +++ b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js @@ -111,8 +111,8 @@ function ComposerWithSuggestions({ const maxComposerLines = isSmallScreenWidth ? CONST.COMPOSER.MAX_LINES_SMALL_SCREEN : CONST.COMPOSER.MAX_LINES; const isEmptyChat = useMemo(() => _.size(reportActions) === 1, [reportActions]); - const parentReportAction = ReportActionsUtils.getParentReportAction(report); - const shouldAutoFocus = !modal.isVisible && (shouldFocusInputOnScreenFocus || (isEmptyChat && !ReportActionsUtils.isTransactionThread(parentReportAction))) && shouldShowComposeInput; + const parentAction = ReportActionsUtils.getParentReportAction(report); + const shouldAutoFocus = !modal.isVisible && (shouldFocusInputOnScreenFocus || (isEmptyChat && !ReportActionsUtils.isTransactionThread(parentAction))) && shouldShowComposeInput; const valueRef = useRef(value); valueRef.current = value; From e7ef9a778c8ea5206b634c7c162682ec667d6ddd Mon Sep 17 00:00:00 2001 From: snyk-bot Date: Thu, 7 Sep 2023 15:13:56 +0000 Subject: [PATCH 101/134] fix: package.json & package-lock.json to reduce vulnerabilities The following vulnerabilities are fixed with an upgrade: - https://snyk.io/vuln/SNYK-JS-ELECTRON-5885041 --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 739acd3be10b..62d49f41e997 100644 --- a/package-lock.json +++ b/package-lock.json @@ -179,7 +179,7 @@ "css-loader": "^6.7.2", "diff-so-fancy": "^1.3.0", "dotenv": "^16.0.3", - "electron": "^25.4.0", + "electron": "^25.5.0", "electron-builder": "24.5.0", "eslint": "^7.6.0", "eslint-config-airbnb-typescript": "^17.1.0", @@ -25005,9 +25005,9 @@ } }, "node_modules/electron": { - "version": "25.4.0", - "resolved": "https://registry.npmjs.org/electron/-/electron-25.4.0.tgz", - "integrity": "sha512-VLTRxDhL4UvQbqM7pTNENnJo62cdAPZT92N+B7BZQ5Xfok1wuVPEewIjBot4K7U3EpLUuHn1veeLzho3ihiP+Q==", + "version": "25.5.0", + "resolved": "https://registry.npmjs.org/electron/-/electron-25.5.0.tgz", + "integrity": "sha512-w1DNj1LuAk0Vaas1rQ0pAkTe2gZ5YG75J27mC2m88y0G6Do5b5YoFDaF84fOGQHeQ4j8tC5LngSgWhbwmqDlrw==", "dev": true, "hasInstallScript": true, "dependencies": { @@ -65715,9 +65715,9 @@ } }, "electron": { - "version": "25.4.0", - "resolved": "https://registry.npmjs.org/electron/-/electron-25.4.0.tgz", - "integrity": "sha512-VLTRxDhL4UvQbqM7pTNENnJo62cdAPZT92N+B7BZQ5Xfok1wuVPEewIjBot4K7U3EpLUuHn1veeLzho3ihiP+Q==", + "version": "25.5.0", + "resolved": "https://registry.npmjs.org/electron/-/electron-25.5.0.tgz", + "integrity": "sha512-w1DNj1LuAk0Vaas1rQ0pAkTe2gZ5YG75J27mC2m88y0G6Do5b5YoFDaF84fOGQHeQ4j8tC5LngSgWhbwmqDlrw==", "dev": true, "requires": { "@electron/get": "^2.0.0", diff --git a/package.json b/package.json index a294b8f740b5..711c4c061373 100644 --- a/package.json +++ b/package.json @@ -219,7 +219,7 @@ "css-loader": "^6.7.2", "diff-so-fancy": "^1.3.0", "dotenv": "^16.0.3", - "electron": "^25.4.0", + "electron": "^25.5.0", "electron-builder": "24.5.0", "eslint": "^7.6.0", "eslint-config-airbnb-typescript": "^17.1.0", From cad29e52f92ad1f939adc9e60f11febf79053cd6 Mon Sep 17 00:00:00 2001 From: Yuwen Memon Date: Thu, 7 Sep 2023 13:45:32 -0700 Subject: [PATCH 102/134] Update src/types/onyx/RecentlyUsedCategories.ts Co-authored-by: Amy Evans --- src/types/onyx/RecentlyUsedCategories.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/types/onyx/RecentlyUsedCategories.ts b/src/types/onyx/RecentlyUsedCategories.ts index 167506599134..d251b16f8667 100644 --- a/src/types/onyx/RecentlyUsedCategories.ts +++ b/src/types/onyx/RecentlyUsedCategories.ts @@ -1,3 +1,3 @@ -type RecentlyUsedCategories = Array; +type RecentlyUsedCategories = string[]; export default RecentlyUsedCategories; From a652268a3a19cacb3be10e08c30b493459c12a95 Mon Sep 17 00:00:00 2001 From: Yuwen Memon Date: Thu, 7 Sep 2023 15:59:41 -0700 Subject: [PATCH 103/134] Add types on Onyx files --- src/ONYXKEYS.ts | 1 + src/types/onyx/index.ts | 2 ++ 2 files changed, 3 insertions(+) diff --git a/src/ONYXKEYS.ts b/src/ONYXKEYS.ts index 05131b6cee31..b7ac091ad0ca 100755 --- a/src/ONYXKEYS.ts +++ b/src/ONYXKEYS.ts @@ -378,6 +378,7 @@ type OnyxValues = { [ONYXKEYS.COLLECTION.POLICY]: OnyxTypes.Policy; [ONYXKEYS.COLLECTION.POLICY_CATEGORIES]: unknown; [ONYXKEYS.COLLECTION.POLICY_MEMBERS]: OnyxTypes.PolicyMember; + [ONYXKEYS.COLLECTION.POLICY_RECENTLY_USED_CATEGORIES]: OnyxTypes.RecentlyUsedCategories; [ONYXKEYS.COLLECTION.DEPRECATED_POLICY_MEMBER_LIST]: OnyxTypes.PolicyMember; [ONYXKEYS.COLLECTION.WORKSPACE_INVITE_MEMBERS_DRAFT]: Record; [ONYXKEYS.COLLECTION.REPORT]: OnyxTypes.Report; diff --git a/src/types/onyx/index.ts b/src/types/onyx/index.ts index 039448fac531..9786d42a48da 100644 --- a/src/types/onyx/index.ts +++ b/src/types/onyx/index.ts @@ -43,6 +43,7 @@ import SecurityGroup from './SecurityGroup'; import Transaction from './Transaction'; import Form, {AddDebitCardForm} from './Form'; import RecentWaypoints from './RecentWaypoints'; +import RecentlyUsedCategories from './RecentlyUsedCategories'; export type { Account, @@ -91,4 +92,5 @@ export type { Form, AddDebitCardForm, RecentWaypoints, + RecentlyUsedCategories, }; From c1388d85807612873efa5f10ed69c940672e4fa4 Mon Sep 17 00:00:00 2001 From: Pavlo Tsimura Date: Fri, 8 Sep 2023 12:44:29 +0200 Subject: [PATCH 104/134] Formatting --- src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js b/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js index e7aee59bb854..e551e0d6d1b9 100644 --- a/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js +++ b/src/pages/workspace/reimburse/WorkspaceRateAndUnitPage.js @@ -97,7 +97,7 @@ class WorkspaceRateAndUnitPage extends React.Component { if (!rateValueRegex.test(values.rate) || values.rate === '') { errors.rate = 'workspace.reimburse.invalidRateError'; } else if (parseFloat(values.rate) <= 0) { - errors.rate = 'workspace.reimburse.lowRateError' + errors.rate = 'workspace.reimburse.lowRateError'; } return errors; } From aa9c074b5be5c5803b9a5f9b742e3ba8384285a8 Mon Sep 17 00:00:00 2001 From: Hezekiel Tamire Date: Fri, 8 Sep 2023 14:04:27 +0300 Subject: [PATCH 105/134] use isCommentEmpty flag to hide expand Icon of composer --- .../ReportActionCompose/AttachmentPickerWithMenuItems.js | 8 ++++++-- .../report/ReportActionCompose/ReportActionCompose.js | 3 ++- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js b/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js index 5864b9b05023..effe19d6ea58 100644 --- a/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js +++ b/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js @@ -43,6 +43,9 @@ const propTypes = { /** Whether or not the full size composer is available */ isFullComposerAvailable: PropTypes.bool.isRequired, + /** Whether or not the text input is empty */ + isCommentEmpty: PropTypes.bool.isRequired, + /** Whether or not the composer is full size */ isComposerFullSize: PropTypes.bool.isRequired, @@ -101,6 +104,7 @@ function AttachmentPickerWithMenuItems({ displayFileInModal, isFullComposerAvailable, isComposerFullSize, + isCommentEmpty, updateShouldShowSuggestionMenuToFalse, reportID, isBlockedFromConcierge, @@ -193,7 +197,7 @@ function AttachmentPickerWithMenuItems({ return ( <> - {isComposerFullSize && ( + {isComposerFullSize && !isCommentEmpty && ( { @@ -212,7 +216,7 @@ function AttachmentPickerWithMenuItems({ )} - {!isComposerFullSize && isFullComposerAvailable && ( + {!isComposerFullSize && isFullComposerAvailable && !isCommentEmpty && ( { diff --git a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js index c7517977aa27..aaf0e1de0eae 100644 --- a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js +++ b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js @@ -296,7 +296,7 @@ function ReportActionCompose({ // eslint-disable-next-line react-hooks/exhaustive-deps [], ); - + const reportRecipientAcountIDs = ReportUtils.getReportRecipientAccountIDs(report, currentUserPersonalDetails.accountID); const reportRecipient = personalDetails[reportRecipientAcountIDs[0]]; const shouldUseFocusedColor = !isBlockedFromConcierge && !disabled && isFocused; @@ -340,6 +340,7 @@ function ReportActionCompose({ reportParticipantIDs={reportParticipantIDs} isFullComposerAvailable={isFullComposerAvailable} isComposerFullSize={isComposerFullSize} + isCommentEmpty={isCommentEmpty} updateShouldShowSuggestionMenuToFalse={updateShouldShowSuggestionMenuToFalse} isBlockedFromConcierge={isBlockedFromConcierge} disabled={disabled} From a501d5e922d042503132f90dfdb5e560b5d504e9 Mon Sep 17 00:00:00 2001 From: Hezekiel Tamire Date: Fri, 8 Sep 2023 14:05:44 +0300 Subject: [PATCH 106/134] remove indentation --- .../home/report/ReportActionCompose/ReportActionCompose.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js index aaf0e1de0eae..d4630e78f3e3 100644 --- a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js +++ b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js @@ -296,7 +296,7 @@ function ReportActionCompose({ // eslint-disable-next-line react-hooks/exhaustive-deps [], ); - + const reportRecipientAcountIDs = ReportUtils.getReportRecipientAccountIDs(report, currentUserPersonalDetails.accountID); const reportRecipient = personalDetails[reportRecipientAcountIDs[0]]; const shouldUseFocusedColor = !isBlockedFromConcierge && !disabled && isFocused; From d2c141755ed071f32a41acaeb3ae4f58b0c610a4 Mon Sep 17 00:00:00 2001 From: Blazej Kustra Date: Fri, 8 Sep 2023 13:16:37 +0200 Subject: [PATCH 107/134] [TS migration] Migrate 'AppUpdate.js' lib to TypeScript --- src/libs/actions/{AppUpdate.js => AppUpdate.ts} | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) rename src/libs/actions/{AppUpdate.js => AppUpdate.ts} (78%) diff --git a/src/libs/actions/AppUpdate.js b/src/libs/actions/AppUpdate.ts similarity index 78% rename from src/libs/actions/AppUpdate.js rename to src/libs/actions/AppUpdate.ts index 502ef9762252..f0e3c1c3da20 100644 --- a/src/libs/actions/AppUpdate.js +++ b/src/libs/actions/AppUpdate.ts @@ -5,10 +5,7 @@ function triggerUpdateAvailable() { Onyx.set(ONYXKEYS.UPDATE_AVAILABLE, true); } -/** - * @param {Boolean} isBeta - */ -function setIsAppInBeta(isBeta) { +function setIsAppInBeta(isBeta: boolean) { Onyx.set(ONYXKEYS.IS_BETA, isBeta); } From 05938e2942a589a4217e553981e0b82762ec760e Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 8 Sep 2023 15:14:45 +0200 Subject: [PATCH 108/134] removing comment about the circular reference --- src/libs/actions/User.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index a54568463c70..6fccf5220bc8 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -572,8 +572,7 @@ function subscribeToUserEvents() { return; } - // If we reached this point, we need to pause the queue while we prepare to fetch older OnyxUpdates. This needs to happen here since adding it on OnyxUpdates - // would cause a circular reference issue. + // If we reached this point, we need to pause the queue while we prepare to fetch older OnyxUpdates. SequentialQueue.pause(); OnyxUpdates.saveUpdateInformation(updates, Number(pushJSON.lastUpdateID || 0), Number(pushJSON.previousUpdateID || 0)); }); From ead5186fd0ecc3ee93d6ba0bb148e22dee7ddae8 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 8 Sep 2023 15:18:43 +0200 Subject: [PATCH 109/134] updating signature for ts mapping --- src/types/onyx/OnyxUpdatesFromServer.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index 781a6b8564aa..8ced8dd12757 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -10,8 +10,8 @@ type OnyxUpdatesFromServerData = { }; type OnyxUpdatesFromServer = { - lastUpdateID: number | string; - previousUpdateID: number | string; + lastUpdateIDFromServer: number | string; + previousUpdateIDFromServer: number | string; type: 'https' | 'pusher'; data: OnyxUpdatesFromServerData; }; From 0b8a8ccc83b2f17e19c3788263550dc7a15c58ed Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 8 Sep 2023 15:20:41 +0200 Subject: [PATCH 110/134] renaming responseData to response --- src/libs/Middleware/SaveResponseInOnyx.js | 20 ++++++++++---------- src/libs/actions/OnyxUpdates.js | 14 +++++++------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index ce178a2b2e16..4241df5abf23 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -14,17 +14,17 @@ const requestsToIgnoreLastUpdateID = ['OpenApp', 'ReconnectApp', 'GetMissingOnyx * @returns {Promise} */ function SaveResponseInOnyx(response, request) { - return response.then((responseData) => { - // Make sure we have response data (i.e. response isn't a promise being passed down to us by a failed retry request and responseData undefined) - if (!responseData) { + return response.then((response) => { + // Make sure we have response data (i.e. response isn't a promise being passed down to us by a failed retry request and response undefined) + if (!response) { return; } - const onyxUpdates = responseData.onyxData; + const onyxUpdates = response.onyxData; // Sometimes we call requests that are successfull but they don't have any response or any success/failure data to set. Let's return early since // we don't need to store anything here. if (!onyxUpdates && !request.successData && !request.failureData) { - return Promise.resolve(responseData); + return Promise.resolve(response); } // If there is an OnyxUpdate for using memory only keys, enable them @@ -39,23 +39,23 @@ function SaveResponseInOnyx(response, request) { const responseToApply = { type: CONST.ONYX_UPDATE_TYPES.HTTPS, - lastUpdateID: Number(responseData.lastUpdateID || 0), + lastUpdateID: Number(response.lastUpdateID || 0), data: { request, - responseData, + response, }, }; - if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.doesClientNeedToBeUpdated(Number(responseData.previousUpdateID || 0))) { + if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.doesClientNeedToBeUpdated(Number(response.previousUpdateID || 0))) { return OnyxUpdates.apply(responseToApply); } // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server - OnyxUpdates.saveUpdateInformation(responseToApply, Number(responseData.lastUpdateID || 0), Number(responseData.previousUpdateID || 0)); + OnyxUpdates.saveUpdateInformation(responseToApply, Number(response.lastUpdateID || 0), Number(response.previousUpdateID || 0)); // Ensure the queue is paused while the client resolves the gap in onyx updates so that updates are guaranteed to happen in a specific order. return Promise.resolve({ - ...responseData, + ...response, shouldPauseQueue: true, }); }); diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 27b18cdec9c7..58220109b568 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -16,10 +16,10 @@ Onyx.connect({ /** * @param {Object} data * @param {Object} data.request - * @param {Object} data.responseData + * @param {Object} data.response * @returns {Promise} */ -function applyHTTPSOnyxUpdates({request, responseData}) { +function applyHTTPSOnyxUpdates({request, response}) { console.debug('[OnyxUpdateManager] Applying https update'); // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in // the UI. See https://github.com/Expensify/App/issues/12775 for more info. @@ -28,22 +28,22 @@ function applyHTTPSOnyxUpdates({request, responseData}) { // First apply any onyx data updates that are being sent back from the API. We wait for this to complete and then // apply successData or failureData. This ensures that we do not update any pending, loading, or other UI states contained // in successData/failureData until after the component has received and API data. - const onyxDataUpdatePromise = responseData.onyxData ? updateHandler(responseData.onyxData) : Promise.resolve(); + const onyxDataUpdatePromise = response.onyxData ? updateHandler(response.onyxData) : Promise.resolve(); return onyxDataUpdatePromise .then(() => { // Handle the request's success/failure data (client-side data) - if (responseData.jsonCode === 200 && request.successData) { + if (response.jsonCode === 200 && request.successData) { return updateHandler(request.successData); } - if (responseData.jsonCode !== 200 && request.failureData) { + if (response.jsonCode !== 200 && request.failureData) { return updateHandler(request.failureData); } return Promise.resolve(); }) .then(() => { console.debug('[OnyxUpdateManager] Done applying HTTPS update'); - return responseData; + return response; }); } @@ -100,7 +100,7 @@ function apply({lastUpdateID, type, data}) { * @param {String} updateParams.type * @param {Object} updateParams.data * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.responseData] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' * @param {Number} [lastUpdateID] * @param {Number} [previousUpdateID] From ec61746f80a944e8152f00173d48dc8a95477129 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 8 Sep 2023 15:23:59 +0200 Subject: [PATCH 111/134] changing from reduce to map --- src/libs/actions/OnyxUpdates.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 58220109b568..1ddbf066465d 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -54,14 +54,7 @@ function applyHTTPSOnyxUpdates({request, response}) { */ function applyPusherOnyxUpdates({updates}) { console.debug('[OnyxUpdateManager] Applying pusher update'); - const pusherEventPromises = _.reduce( - updates, - (result, update) => { - result.push(PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); - return result; - }, - [], - ); + const pusherEventPromises = _.map(updates, update => PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); return Promise.all(pusherEventPromises).then(() => { console.debug('[OnyxUpdateManager] Done applying Pusher update'); }); From c5a8eb542758b578a112fb2fa94d73243d5b1111 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 8 Sep 2023 15:39:41 +0200 Subject: [PATCH 112/134] linter and fixing signature again --- src/libs/Middleware/SaveResponseInOnyx.js | 4 ++-- src/libs/Network/SequentialQueue.js | 4 ++-- src/libs/actions/OnyxUpdates.js | 2 +- src/types/onyx/OnyxUpdatesFromServer.ts | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 4241df5abf23..8ee5d167589c 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -13,8 +13,8 @@ const requestsToIgnoreLastUpdateID = ['OpenApp', 'ReconnectApp', 'GetMissingOnyx * @param {Object} request * @returns {Promise} */ -function SaveResponseInOnyx(response, request) { - return response.then((response) => { +function SaveResponseInOnyx(requestResponse, request) { + return requestResponse.then((response) => { // Make sure we have response data (i.e. response isn't a promise being passed down to us by a failed retry request and response undefined) if (!response) { return; diff --git a/src/libs/Network/SequentialQueue.js b/src/libs/Network/SequentialQueue.js index 56a11b492442..e53515fb5e87 100644 --- a/src/libs/Network/SequentialQueue.js +++ b/src/libs/Network/SequentialQueue.js @@ -68,10 +68,10 @@ function process() { // Set the current request to a promise awaiting its processing so that getCurrentRequest can be used to take some action after the current request has processed. currentRequest = Request.processWithMiddleware(requestToProcess, true) - .then((responseData) => { + .then((response) => { // A response might indicate that the queue should be paused. This happens when a gap in onyx updates is detected between the client and the server and // that gap needs resolved before the queue can continue. - if (responseData.shouldPauseQueue) { + if (response.shouldPauseQueue) { pause(); } PersistedRequests.remove(requestToProcess); diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 1ddbf066465d..906dda2eb6dc 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -54,7 +54,7 @@ function applyHTTPSOnyxUpdates({request, response}) { */ function applyPusherOnyxUpdates({updates}) { console.debug('[OnyxUpdateManager] Applying pusher update'); - const pusherEventPromises = _.map(updates, update => PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); + const pusherEventPromises = _.map(updates, (update) => PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); return Promise.all(pusherEventPromises).then(() => { console.debug('[OnyxUpdateManager] Done applying Pusher update'); }); diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index 8ced8dd12757..c653a5054673 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -13,7 +13,7 @@ type OnyxUpdatesFromServer = { lastUpdateIDFromServer: number | string; previousUpdateIDFromServer: number | string; type: 'https' | 'pusher'; - data: OnyxUpdatesFromServerData; + updateParams: OnyxUpdatesFromServerData; }; export default OnyxUpdatesFromServer; From 20fead9f220d38864b1618009ee7ca74a564a489 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Fri, 8 Sep 2023 15:44:28 +0200 Subject: [PATCH 113/134] fixing lint --- src/libs/Middleware/SaveResponseInOnyx.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index 8ee5d167589c..af407294a01d 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -9,7 +9,7 @@ import * as OnyxUpdates from '../actions/OnyxUpdates'; const requestsToIgnoreLastUpdateID = ['OpenApp', 'ReconnectApp', 'GetMissingOnyxMessages']; /** - * @param {Promise} response + * @param {Promise} requestResponse * @param {Object} request * @returns {Promise} */ From d8adf782db2cdb039e2d922dc23231a330c4e59a Mon Sep 17 00:00:00 2001 From: Hezekiel Tamire Date: Fri, 8 Sep 2023 23:17:58 +0300 Subject: [PATCH 114/134] reset isComposerFullSize to false in SendButton --- .../ReportActionCompose/AttachmentPickerWithMenuItems.js | 8 ++------ .../report/ReportActionCompose/ReportActionCompose.js | 9 ++++++++- src/pages/home/report/ReportActionCompose/SendButton.js | 6 +++++- 3 files changed, 15 insertions(+), 8 deletions(-) diff --git a/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js b/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js index effe19d6ea58..5864b9b05023 100644 --- a/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js +++ b/src/pages/home/report/ReportActionCompose/AttachmentPickerWithMenuItems.js @@ -43,9 +43,6 @@ const propTypes = { /** Whether or not the full size composer is available */ isFullComposerAvailable: PropTypes.bool.isRequired, - /** Whether or not the text input is empty */ - isCommentEmpty: PropTypes.bool.isRequired, - /** Whether or not the composer is full size */ isComposerFullSize: PropTypes.bool.isRequired, @@ -104,7 +101,6 @@ function AttachmentPickerWithMenuItems({ displayFileInModal, isFullComposerAvailable, isComposerFullSize, - isCommentEmpty, updateShouldShowSuggestionMenuToFalse, reportID, isBlockedFromConcierge, @@ -197,7 +193,7 @@ function AttachmentPickerWithMenuItems({ return ( <> - {isComposerFullSize && !isCommentEmpty && ( + {isComposerFullSize && ( { @@ -216,7 +212,7 @@ function AttachmentPickerWithMenuItems({ )} - {!isComposerFullSize && isFullComposerAvailable && !isCommentEmpty && ( + {!isComposerFullSize && isFullComposerAvailable && ( { diff --git a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js index d4630e78f3e3..13d7943b579d 100644 --- a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js +++ b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js @@ -285,6 +285,13 @@ function ReportActionCompose({ setIsFocused(true); }, []); + const resetFullComposerToFalse = useCallback(() => { + if (isComposerFullSize) { + Report.setIsComposerFullSize(reportID, false); + } + setIsFullComposerAvailable(false); + }, [isComposerFullSize, reportID]); + // We are returning a callback here as we want to incoke the method on unmount only useEffect( () => () => { @@ -340,7 +347,6 @@ function ReportActionCompose({ reportParticipantIDs={reportParticipantIDs} isFullComposerAvailable={isFullComposerAvailable} isComposerFullSize={isComposerFullSize} - isCommentEmpty={isCommentEmpty} updateShouldShowSuggestionMenuToFalse={updateShouldShowSuggestionMenuToFalse} isBlockedFromConcierge={isBlockedFromConcierge} disabled={disabled} @@ -401,6 +407,7 @@ function ReportActionCompose({ diff --git a/src/pages/home/report/ReportActionCompose/SendButton.js b/src/pages/home/report/ReportActionCompose/SendButton.js index 4f1dc5fff191..258a1859379d 100644 --- a/src/pages/home/report/ReportActionCompose/SendButton.js +++ b/src/pages/home/report/ReportActionCompose/SendButton.js @@ -23,11 +23,14 @@ const propTypes = { /** Sets the isCommentEmpty flag to true */ setIsCommentEmpty: PropTypes.func.isRequired, + /** Sets the isComposerFullSize to false */ + resetFullComposerToFalse: PropTypes.func.isRequired, + /** Submits the form */ submitForm: PropTypes.func.isRequired, }; -function SendButton({isDisabled: isDisabledProp, animatedRef, setIsCommentEmpty, submitForm}) { +function SendButton({isDisabled: isDisabledProp, animatedRef, setIsCommentEmpty, resetFullComposerToFalse, submitForm}) { const {translate} = useLocalize(); const Tap = Gesture.Tap() @@ -40,6 +43,7 @@ function SendButton({isDisabled: isDisabledProp, animatedRef, setIsCommentEmpty, const updates = {text: ''}; // We are setting the isCommentEmpty flag to true so the status of it will be in sync of the native text input state runOnJS(setIsCommentEmpty)(true); + runOnJS(resetFullComposerToFalse)(); updatePropsPaperWorklet(viewTag, viewName, updates); // clears native text input on the UI thread runOnJS(submitForm)(); }); From 250aa1797a7f1b5d17224c9aa71aa0510dd93b54 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Sat, 9 Sep 2023 00:47:43 +0300 Subject: [PATCH 115/134] changing object signature to simplify it --- src/libs/Middleware/SaveResponseInOnyx.js | 9 +++-- src/libs/actions/OnyxUpdateManager.js | 6 ++-- src/libs/actions/OnyxUpdates.js | 44 ++++++++++------------- src/libs/actions/User.js | 7 ++-- src/types/onyx/OnyxUpdatesFromServer.ts | 10 ++---- 5 files changed, 31 insertions(+), 45 deletions(-) diff --git a/src/libs/Middleware/SaveResponseInOnyx.js b/src/libs/Middleware/SaveResponseInOnyx.js index af407294a01d..8cb66c0c10d0 100644 --- a/src/libs/Middleware/SaveResponseInOnyx.js +++ b/src/libs/Middleware/SaveResponseInOnyx.js @@ -40,10 +40,9 @@ function SaveResponseInOnyx(requestResponse, request) { const responseToApply = { type: CONST.ONYX_UPDATE_TYPES.HTTPS, lastUpdateID: Number(response.lastUpdateID || 0), - data: { - request, - response, - }, + previousUpdateID: Number(response.previousUpdateID || 0), + request, + response, }; if (_.includes(requestsToIgnoreLastUpdateID, request.command) || !OnyxUpdates.doesClientNeedToBeUpdated(Number(response.previousUpdateID || 0))) { @@ -51,7 +50,7 @@ function SaveResponseInOnyx(requestResponse, request) { } // Save the update IDs to Onyx so they can be used to fetch incremental updates if the client gets out of sync from the server - OnyxUpdates.saveUpdateInformation(responseToApply, Number(response.lastUpdateID || 0), Number(response.previousUpdateID || 0)); + OnyxUpdates.saveUpdateInformation(responseToApply); // Ensure the queue is paused while the client resolves the gap in onyx updates so that updates are guaranteed to happen in a specific order. return Promise.resolve({ diff --git a/src/libs/actions/OnyxUpdateManager.js b/src/libs/actions/OnyxUpdateManager.js index 8d0335ed03b7..f0051b85f302 100644 --- a/src/libs/actions/OnyxUpdateManager.js +++ b/src/libs/actions/OnyxUpdateManager.js @@ -35,7 +35,9 @@ export default () => { return; } - const {lastUpdateIDFromServer, previousUpdateIDFromServer, updateParams} = val; + const updateParams = val; + const lastUpdateIDFromServer = val.lastUpdateID; + const previousUpdateIDFromServer = val.previousUpdateID; // In cases where we received a previousUpdateID and it doesn't match our lastUpdateIDAppliedToClient // we need to perform one of the 2 possible cases: @@ -69,7 +71,7 @@ export default () => { } canUnpauseQueuePromise.finally(() => { - OnyxUpdates.apply({...updateParams, lastUpdateID: lastUpdateIDFromServer}).finally(() => { + OnyxUpdates.apply(updateParams).finally(() => { console.debug('[OnyxUpdateManager] Done applying all updates'); SequentialQueue.unpause(); }); diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 906dda2eb6dc..6c210f1abadc 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -14,12 +14,11 @@ Onyx.connect({ }); /** - * @param {Object} data - * @param {Object} data.request - * @param {Object} data.response + * @param {Object} request + * @param {Object} response * @returns {Promise} */ -function applyHTTPSOnyxUpdates({request, response}) { +function applyHTTPSOnyxUpdates(request, response) { console.debug('[OnyxUpdateManager] Applying https update'); // For most requests we can immediately update Onyx. For write requests we queue the updates and apply them after the sequential queue has flushed to prevent a replay effect in // the UI. See https://github.com/Expensify/App/issues/12775 for more info. @@ -48,11 +47,10 @@ function applyHTTPSOnyxUpdates({request, response}) { } /** - * @param {Object} data - * @param {Object} data.updates + * @param {Array} updates * @returns {Promise} */ -function applyPusherOnyxUpdates({updates}) { +function applyPusherOnyxUpdates(updates) { console.debug('[OnyxUpdateManager] Applying pusher update'); const pusherEventPromises = _.map(updates, (update) => PusherUtils.triggerMultiEventHandler(update.eventType, update.data)); return Promise.all(pusherEventPromises).then(() => { @@ -64,13 +62,12 @@ function applyPusherOnyxUpdates({updates}) { * @param {Object[]} updateParams * @param {String} updateParams.type * @param {Number} updateParams.lastUpdateID - * @param {Object} updateParams.data - * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' + * @param {Object} [updateParams.request] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.response] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.updates] Exists if updateParams.type === 'pusher' * @returns {Promise} */ -function apply({lastUpdateID, type, data}) { +function apply({lastUpdateID, type, request, response, updates}) { console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, data); if (lastUpdateID && lastUpdateID < lastUpdateIDAppliedToClient) { @@ -81,30 +78,25 @@ function apply({lastUpdateID, type, data}) { Onyx.merge(ONYXKEYS.ONYX_UPDATES_LAST_UPDATE_ID_APPLIED_TO_CLIENT, lastUpdateID); } if (type === CONST.ONYX_UPDATE_TYPES.HTTPS) { - return applyHTTPSOnyxUpdates(data); + return applyHTTPSOnyxUpdates(request, response); } if (type === CONST.ONYX_UPDATE_TYPES.PUSHER) { - return applyPusherOnyxUpdates(data); + return applyPusherOnyxUpdates(updates); } } /** * @param {Object[]} updateParams * @param {String} updateParams.type - * @param {Object} updateParams.data - * @param {Object} [updateParams.data.request] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.response] Exists if updateParams.type === 'https' - * @param {Object} [updateParams.data.updates] Exists if updateParams.type === 'pusher' - * @param {Number} [lastUpdateID] - * @param {Number} [previousUpdateID] + * @param {Object} [updateParams.request] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.response] Exists if updateParams.type === 'https' + * @param {Object} [updateParams.updates] Exists if updateParams.type === 'pusher' + * @param {Number} [updateParams.lastUpdateID] + * @param {Number} [updateParams.previousUpdateID] */ -function saveUpdateInformation(updateParams, lastUpdateID = 0, previousUpdateID = 0) { +function saveUpdateInformation(updateParams) { // Always use set() here so that the updateParams are never merged and always unique to the request that came in - Onyx.set(ONYXKEYS.ONYX_UPDATES_FROM_SERVER, { - lastUpdateIDFromServer: lastUpdateID, - previousUpdateIDFromServer: previousUpdateID, - updateParams, - }); + Onyx.set(ONYXKEYS.ONYX_UPDATES_FROM_SERVER, updateParams); } /** diff --git a/src/libs/actions/User.js b/src/libs/actions/User.js index 6fccf5220bc8..ee93c6acb1e5 100644 --- a/src/libs/actions/User.js +++ b/src/libs/actions/User.js @@ -563,9 +563,8 @@ function subscribeToUserEvents() { const updates = { type: CONST.ONYX_UPDATE_TYPES.PUSHER, lastUpdateID: Number(pushJSON.lastUpdateID || 0), - data: { - updates: pushJSON.updates, - }, + updates: pushJSON.updates, + previousUpdateID: Number(pushJSON.previousUpdateID || 0), }; if (!OnyxUpdates.doesClientNeedToBeUpdated(Number(pushJSON.previousUpdateID || 0))) { OnyxUpdates.apply(updates); @@ -574,7 +573,7 @@ function subscribeToUserEvents() { // If we reached this point, we need to pause the queue while we prepare to fetch older OnyxUpdates. SequentialQueue.pause(); - OnyxUpdates.saveUpdateInformation(updates, Number(pushJSON.lastUpdateID || 0), Number(pushJSON.previousUpdateID || 0)); + OnyxUpdates.saveUpdateInformation(updates); }); // Handles Onyx updates coming from Pusher through the mega multipleEvents. diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index c653a5054673..c50362f3e6c7 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -2,18 +2,12 @@ import {OnyxUpdate} from 'react-native-onyx'; import Request from './Request'; import Response from './Response'; -type OnyxUpdatesFromServerData = { +type OnyxUpdatesFromServer = { + type: 'https' | 'pusher'; lastUpdateID: number | string; request?: Request; response?: Response; updates?: OnyxUpdate[]; }; -type OnyxUpdatesFromServer = { - lastUpdateIDFromServer: number | string; - previousUpdateIDFromServer: number | string; - type: 'https' | 'pusher'; - updateParams: OnyxUpdatesFromServerData; -}; - export default OnyxUpdatesFromServer; From e07c47c1b087b7201607d38079408fbbfd2ef665 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Sat, 9 Sep 2023 01:19:45 +0300 Subject: [PATCH 116/134] removing data reference --- src/libs/actions/OnyxUpdates.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 6c210f1abadc..5c4d3bf93a65 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -42,7 +42,7 @@ function applyHTTPSOnyxUpdates(request, response) { }) .then(() => { console.debug('[OnyxUpdateManager] Done applying HTTPS update'); - return response; + return Promise.resolve(response);; }); } @@ -68,7 +68,7 @@ function applyPusherOnyxUpdates(updates) { * @returns {Promise} */ function apply({lastUpdateID, type, request, response, updates}) { - console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, data); + console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, { request, response, updates } ); if (lastUpdateID && lastUpdateID < lastUpdateIDAppliedToClient) { console.debug('[OnyxUpdateManager] Update received was older than current state, returning without applying the updates'); From 9b700142137b36d990bd87326e6bd25eacab06e8 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Sat, 9 Sep 2023 03:40:41 +0300 Subject: [PATCH 117/134] prettier --- src/libs/actions/OnyxUpdates.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/actions/OnyxUpdates.js b/src/libs/actions/OnyxUpdates.js index 5c4d3bf93a65..8e45e7dd2e66 100644 --- a/src/libs/actions/OnyxUpdates.js +++ b/src/libs/actions/OnyxUpdates.js @@ -42,7 +42,7 @@ function applyHTTPSOnyxUpdates(request, response) { }) .then(() => { console.debug('[OnyxUpdateManager] Done applying HTTPS update'); - return Promise.resolve(response);; + return Promise.resolve(response); }); } @@ -68,7 +68,7 @@ function applyPusherOnyxUpdates(updates) { * @returns {Promise} */ function apply({lastUpdateID, type, request, response, updates}) { - console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, { request, response, updates } ); + console.debug(`[OnyxUpdateManager] Applying update type: ${type} with lastUpdateID: ${lastUpdateID}`, {request, response, updates}); if (lastUpdateID && lastUpdateID < lastUpdateIDAppliedToClient) { console.debug('[OnyxUpdateManager] Update received was older than current state, returning without applying the updates'); From 1116ace9b1e4faac51dbc28ee510c7a30d46ae96 Mon Sep 17 00:00:00 2001 From: Hezekiel Tamire Date: Sat, 9 Sep 2023 14:23:24 +0300 Subject: [PATCH 118/134] added extra check and renamed the function to make it more descriptive --- .../report/ReportActionCompose/ReportActionCompose.js | 8 +++++--- src/pages/home/report/ReportActionCompose/SendButton.js | 8 ++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js index 13d7943b579d..3ad92fa5c769 100644 --- a/src/pages/home/report/ReportActionCompose/ReportActionCompose.js +++ b/src/pages/home/report/ReportActionCompose/ReportActionCompose.js @@ -285,7 +285,9 @@ function ReportActionCompose({ setIsFocused(true); }, []); - const resetFullComposerToFalse = useCallback(() => { + // resets the composer to normal size when + // the send button is pressed. + const resetFullComposerSize = useCallback(() => { if (isComposerFullSize) { Report.setIsComposerFullSize(reportID, false); } @@ -345,7 +347,7 @@ function ReportActionCompose({ reportID={reportID} report={report} reportParticipantIDs={reportParticipantIDs} - isFullComposerAvailable={isFullComposerAvailable} + isFullComposerAvailable={isFullComposerAvailable && !isCommentEmpty} isComposerFullSize={isComposerFullSize} updateShouldShowSuggestionMenuToFalse={updateShouldShowSuggestionMenuToFalse} isBlockedFromConcierge={isBlockedFromConcierge} @@ -407,7 +409,7 @@ function ReportActionCompose({ diff --git a/src/pages/home/report/ReportActionCompose/SendButton.js b/src/pages/home/report/ReportActionCompose/SendButton.js index 258a1859379d..8128b5a6b39d 100644 --- a/src/pages/home/report/ReportActionCompose/SendButton.js +++ b/src/pages/home/report/ReportActionCompose/SendButton.js @@ -23,14 +23,14 @@ const propTypes = { /** Sets the isCommentEmpty flag to true */ setIsCommentEmpty: PropTypes.func.isRequired, - /** Sets the isComposerFullSize to false */ - resetFullComposerToFalse: PropTypes.func.isRequired, + /** resets the composer to normal size */ + resetFullComposerSize: PropTypes.func.isRequired, /** Submits the form */ submitForm: PropTypes.func.isRequired, }; -function SendButton({isDisabled: isDisabledProp, animatedRef, setIsCommentEmpty, resetFullComposerToFalse, submitForm}) { +function SendButton({isDisabled: isDisabledProp, animatedRef, setIsCommentEmpty, resetFullComposerSize, submitForm}) { const {translate} = useLocalize(); const Tap = Gesture.Tap() @@ -43,7 +43,7 @@ function SendButton({isDisabled: isDisabledProp, animatedRef, setIsCommentEmpty, const updates = {text: ''}; // We are setting the isCommentEmpty flag to true so the status of it will be in sync of the native text input state runOnJS(setIsCommentEmpty)(true); - runOnJS(resetFullComposerToFalse)(); + runOnJS(resetFullComposerSize)(); updatePropsPaperWorklet(viewTag, viewName, updates); // clears native text input on the UI thread runOnJS(submitForm)(); }); From a17dec6cc9aef8c49c6bf582b9f6c404338ae85b Mon Sep 17 00:00:00 2001 From: Hezekiel Tamire Date: Sat, 9 Sep 2023 14:51:53 +0300 Subject: [PATCH 119/134] remove redundant code --- .../report/ReportActionCompose/ComposerWithSuggestions.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js index 36b0af156ae5..7929e0ae8b97 100644 --- a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js +++ b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js @@ -243,12 +243,8 @@ function ComposerWithSuggestions({ updateComment(''); setTextInputShouldClear(true); - if (isComposerFullSize) { - Report.setIsComposerFullSize(reportID, false); - } - setIsFullComposerAvailable(false); return trimmedComment; - }, [updateComment, setTextInputShouldClear, isComposerFullSize, setIsFullComposerAvailable, reportID]); + }, [updateComment, setTextInputShouldClear]); /** * Callback to add whatever text is chosen into the main input (used f.e as callback for the emoji picker) From 6232d7ee7df8d4cd53b773c17e1570f9339686fa Mon Sep 17 00:00:00 2001 From: Hezekiel Tamire Date: Sat, 9 Sep 2023 16:43:53 +0300 Subject: [PATCH 120/134] revert change --- .../report/ReportActionCompose/ComposerWithSuggestions.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js index 7929e0ae8b97..36b0af156ae5 100644 --- a/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js +++ b/src/pages/home/report/ReportActionCompose/ComposerWithSuggestions.js @@ -243,8 +243,12 @@ function ComposerWithSuggestions({ updateComment(''); setTextInputShouldClear(true); + if (isComposerFullSize) { + Report.setIsComposerFullSize(reportID, false); + } + setIsFullComposerAvailable(false); return trimmedComment; - }, [updateComment, setTextInputShouldClear]); + }, [updateComment, setTextInputShouldClear, isComposerFullSize, setIsFullComposerAvailable, reportID]); /** * Callback to add whatever text is chosen into the main input (used f.e as callback for the emoji picker) From 584e48723259e0e3e358cbfe4f3fff5f02dbed35 Mon Sep 17 00:00:00 2001 From: snyk-bot Date: Sat, 9 Sep 2023 19:01:51 +0000 Subject: [PATCH 121/134] fix: package.json & package-lock.json to reduce vulnerabilities The following vulnerabilities are fixed with an upgrade: - https://snyk.io/vuln/SNYK-JS-ELECTRON-5880432 --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 4128a740b360..3000f44c7a9d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -179,7 +179,7 @@ "css-loader": "^6.7.2", "diff-so-fancy": "^1.3.0", "dotenv": "^16.0.3", - "electron": "^25.4.0", + "electron": "^25.8.0", "electron-builder": "24.5.0", "eslint": "^7.6.0", "eslint-config-airbnb-typescript": "^17.1.0", @@ -25005,9 +25005,9 @@ } }, "node_modules/electron": { - "version": "25.4.0", - "resolved": "https://registry.npmjs.org/electron/-/electron-25.4.0.tgz", - "integrity": "sha512-VLTRxDhL4UvQbqM7pTNENnJo62cdAPZT92N+B7BZQ5Xfok1wuVPEewIjBot4K7U3EpLUuHn1veeLzho3ihiP+Q==", + "version": "25.8.0", + "resolved": "https://registry.npmjs.org/electron/-/electron-25.8.0.tgz", + "integrity": "sha512-T3kC1a/3ntSaYMCVVfUUc9v7myPzi6J2GP0Ad/CyfWKDPp054dGyKxb2EEjKnxQQ7wfjsT1JTEdBG04x6ekVBw==", "dev": true, "hasInstallScript": true, "dependencies": { @@ -65715,9 +65715,9 @@ } }, "electron": { - "version": "25.4.0", - "resolved": "https://registry.npmjs.org/electron/-/electron-25.4.0.tgz", - "integrity": "sha512-VLTRxDhL4UvQbqM7pTNENnJo62cdAPZT92N+B7BZQ5Xfok1wuVPEewIjBot4K7U3EpLUuHn1veeLzho3ihiP+Q==", + "version": "25.8.0", + "resolved": "https://registry.npmjs.org/electron/-/electron-25.8.0.tgz", + "integrity": "sha512-T3kC1a/3ntSaYMCVVfUUc9v7myPzi6J2GP0Ad/CyfWKDPp054dGyKxb2EEjKnxQQ7wfjsT1JTEdBG04x6ekVBw==", "dev": true, "requires": { "@electron/get": "^2.0.0", diff --git a/package.json b/package.json index 6574bcc4b77c..bc7f57f90f06 100644 --- a/package.json +++ b/package.json @@ -219,7 +219,7 @@ "css-loader": "^6.7.2", "diff-so-fancy": "^1.3.0", "dotenv": "^16.0.3", - "electron": "^25.4.0", + "electron": "^25.8.0", "electron-builder": "24.5.0", "eslint": "^7.6.0", "eslint-config-airbnb-typescript": "^17.1.0", From d012c5499e2500dd4cf16bd8b3a1fd19deb95a73 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Sun, 10 Sep 2023 10:55:11 +0800 Subject: [PATCH 122/134] adding previousUpdateID --- src/types/onyx/OnyxUpdatesFromServer.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/types/onyx/OnyxUpdatesFromServer.ts b/src/types/onyx/OnyxUpdatesFromServer.ts index c50362f3e6c7..02a96d4ce230 100644 --- a/src/types/onyx/OnyxUpdatesFromServer.ts +++ b/src/types/onyx/OnyxUpdatesFromServer.ts @@ -5,6 +5,7 @@ import Response from './Response'; type OnyxUpdatesFromServer = { type: 'https' | 'pusher'; lastUpdateID: number | string; + previousUpdateID: number | string; request?: Request; response?: Response; updates?: OnyxUpdate[]; From 326010b5edb65c395c1a0b4786c42410f1fe1ae2 Mon Sep 17 00:00:00 2001 From: Anusha Date: Sun, 10 Sep 2023 17:57:45 +0500 Subject: [PATCH 123/134] comments fixed --- src/libs/ReportActionsUtils.js | 3 +-- src/pages/home/report/ReportActionItemFragment.js | 4 ++++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/libs/ReportActionsUtils.js b/src/libs/ReportActionsUtils.js index c68cbd84a9f8..9bb365c0f42a 100644 --- a/src/libs/ReportActionsUtils.js +++ b/src/libs/ReportActionsUtils.js @@ -105,14 +105,13 @@ function isWhisperAction(action) { } /** - * * Returns whether the comment is a thread parent message/the first message in a thread * * @param {Object} reportAction * @param {String} reportID * @returns {Boolean} */ -function isThreadParentMessage(reportAction, reportID) { +function isThreadParentMessage(reportAction = {}, reportID) { const {childType, childVisibleActionCount = 0, childReportID} = reportAction; return childType === CONST.REPORT.TYPE.CHAT && (childVisibleActionCount > 0 || String(childReportID) === reportID); } diff --git a/src/pages/home/report/ReportActionItemFragment.js b/src/pages/home/report/ReportActionItemFragment.js index e6745a89e493..d768fcacd5b7 100644 --- a/src/pages/home/report/ReportActionItemFragment.js +++ b/src/pages/home/report/ReportActionItemFragment.js @@ -67,6 +67,9 @@ const propTypes = { /** icon */ actorIcon: avatarPropTypes, + /** Whether the comment is a thread parent message/the first message in a thread */ + isThreadParentMessage: PropTypes.bool, + ...windowDimensionsPropTypes, /** localization props */ @@ -88,6 +91,7 @@ const defaultProps = { style: [], delegateAccountID: 0, actorIcon: {}, + isThreadParentMessage: false, }; function ReportActionItemFragment(props) { From 23933fd7ea1d1fd7fae8c27459e72a3492af1281 Mon Sep 17 00:00:00 2001 From: OSBotify Date: Mon, 11 Sep 2023 03:08:22 +0000 Subject: [PATCH 124/134] Update version to 1.3.67-0 --- android/app/build.gradle | 4 ++-- ios/NewExpensify/Info.plist | 4 ++-- ios/NewExpensifyTests/Info.plist | 4 ++-- package-lock.json | 4 ++-- package.json | 2 +- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/android/app/build.gradle b/android/app/build.gradle index 7cba91e7b0a9..7f8ab01ca837 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -90,8 +90,8 @@ android { minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion multiDexEnabled rootProject.ext.multiDexEnabled - versionCode 1001036603 - versionName "1.3.66-3" + versionCode 1001036700 + versionName "1.3.67-0" } flavorDimensions "default" diff --git a/ios/NewExpensify/Info.plist b/ios/NewExpensify/Info.plist index e9e9394fcaae..083e2a524ef5 100644 --- a/ios/NewExpensify/Info.plist +++ b/ios/NewExpensify/Info.plist @@ -19,7 +19,7 @@ CFBundlePackageType APPL CFBundleShortVersionString - 1.3.66 + 1.3.67 CFBundleSignature ???? CFBundleURLTypes @@ -40,7 +40,7 @@ CFBundleVersion - 1.3.66.3 + 1.3.67.0 ITSAppUsesNonExemptEncryption LSApplicationQueriesSchemes diff --git a/ios/NewExpensifyTests/Info.plist b/ios/NewExpensifyTests/Info.plist index 7286b383a0c7..30c8e2b034ca 100644 --- a/ios/NewExpensifyTests/Info.plist +++ b/ios/NewExpensifyTests/Info.plist @@ -15,10 +15,10 @@ CFBundlePackageType BNDL CFBundleShortVersionString - 1.3.66 + 1.3.67 CFBundleSignature ???? CFBundleVersion - 1.3.66.3 + 1.3.67.0 diff --git a/package-lock.json b/package-lock.json index 4128a740b360..8267e79a6d3c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "new.expensify", - "version": "1.3.66-3", + "version": "1.3.67-0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "new.expensify", - "version": "1.3.66-3", + "version": "1.3.67-0", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index 25718357b151..d6d6ed4cae1b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "new.expensify", - "version": "1.3.66-3", + "version": "1.3.67-0", "author": "Expensify, Inc.", "homepage": "https://new.expensify.com", "description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.", From fadfb92c9454c03e12a5d4e420550d82dad70916 Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Mon, 11 Sep 2023 11:22:48 +0800 Subject: [PATCH 125/134] changing types to accept both number and string --- src/types/onyx/Response.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/types/onyx/Response.ts b/src/types/onyx/Response.ts index d9395b6e8dab..c501034e971c 100644 --- a/src/types/onyx/Response.ts +++ b/src/types/onyx/Response.ts @@ -1,8 +1,8 @@ import {OnyxUpdate} from 'react-native-onyx'; type Response = { - previousUpdateID?: number; - lastUpdateID?: number; + previousUpdateID?: number | string; + lastUpdateID?: number | string; jsonCode?: number; onyxData?: OnyxUpdate[]; requestID?: string; From f36a8cde556c04bbafbba3020ebe2bda4a467a42 Mon Sep 17 00:00:00 2001 From: rory Date: Mon, 11 Sep 2023 12:29:26 +0800 Subject: [PATCH 126/134] Rebuild GH actions --- .../javascript/createOrUpdateStagingDeploy/index.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js index 701a9bca70a7..561b8e61bc21 100644 --- a/.github/actions/javascript/createOrUpdateStagingDeploy/index.js +++ b/.github/actions/javascript/createOrUpdateStagingDeploy/index.js @@ -207,10 +207,7 @@ function fetchTag(tag) { console.log(`Running command: ${command}`); execSync(command); } catch (e) { - // This can happen if the tag was only created locally but does not exist in the remote. In this case, we'll fetch history of the staging branch instead - const command = `git fetch origin staging --no-tags --shallow-exclude=${previousPatchVersion}`; - console.log(`Running command: ${command}`); - execSync(command); + console.error(e); } } @@ -301,13 +298,14 @@ function getValidMergedPRs(commits) { * @returns {Promise>} – Pull request numbers */ function getPullRequestsMergedBetween(fromTag, toTag) { + console.log(`Looking for commits made between ${fromTag} and ${toTag}...`); return getCommitHistoryAsJSON(fromTag, toTag).then((commitList) => { console.log(`Commits made between ${fromTag} and ${toTag}:`, commitList); // Find which commit messages correspond to merged PR's const pullRequestNumbers = getValidMergedPRs(commitList); console.log(`List of pull requests merged between ${fromTag} and ${toTag}`, pullRequestNumbers); - return pullRequestNumbers; + return _.map(pullRequestNumbers, (prNum) => Number.parseInt(prNum, 10)); }); } From 5e15589205c2d7878f830f075d5f72e5e3963da9 Mon Sep 17 00:00:00 2001 From: rory Date: Mon, 11 Sep 2023 12:45:40 +0800 Subject: [PATCH 127/134] Use version from step instead of needs --- .github/workflows/platformDeploy.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/platformDeploy.yml b/.github/workflows/platformDeploy.yml index b50a14dc9ca1..cb49dd4acddf 100644 --- a/.github/workflows/platformDeploy.yml +++ b/.github/workflows/platformDeploy.yml @@ -409,10 +409,11 @@ jobs: - uses: Expensify/App/.github/actions/composite/setupNode@main - name: Set version + id: getVersion run: echo "VERSION=$(npm run print-version --silent)" >> "$GITHUB_ENV" - name: Create or update staging deploy uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main with: GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} - NPM_VERSION: ${{ needs.createNewVersion.outputs.NEW_VERSION }} + NPM_VERSION: ${{ steps.getVersion.outputs.VERSION }} From d12ff8fe3b9aeef5f5fda857be653efacc1d8f79 Mon Sep 17 00:00:00 2001 From: rory Date: Mon, 11 Sep 2023 12:51:25 +0800 Subject: [PATCH 128/134] Optimistically update the checklist at the top of platformDeploy.yml --- .github/workflows/platformDeploy.yml | 49 +++++++++++----------------- 1 file changed, 19 insertions(+), 30 deletions(-) diff --git a/.github/workflows/platformDeploy.yml b/.github/workflows/platformDeploy.yml index cb49dd4acddf..400a0d4364fe 100644 --- a/.github/workflows/platformDeploy.yml +++ b/.github/workflows/platformDeploy.yml @@ -28,6 +28,25 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} + # Note: we're updating the checklist before running the deploys and assuming that it will succeed on at least one platform + deployChecklist: + name: Create or update deploy checklist + runs-on: ubuntu-latest + needs: validateActor + steps: + - uses: actions/checkout@v3 + - uses: Expensify/App/.github/actions/composite/setupNode@main + + - name: Set version + id: getVersion + run: echo "VERSION=$(npm run print-version --silent)" >> "$GITHUB_ENV" + + - name: Create or update staging deploy + uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main + with: + GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} + NPM_VERSION: ${{ steps.getVersion.outputs.VERSION }} + android: name: Build and deploy Android needs: validateActor @@ -387,33 +406,3 @@ jobs: DESKTOP: ${{ needs.desktop.result }} IOS: ${{ needs.iOS.result }} WEB: ${{ needs.web.result }} - - deployChecklist: - name: Create or update deploy checklist - runs-on: ubuntu-latest - if: ${{ always() }} - needs: [android, desktop, iOS, web] - steps: - - name: Quit early if all platforms failed - run: | - if [[ ${{ needs.android.result }} != 'success' && \ - ${{ needs.desktop.result }} != 'success' && \ - ${{ needs.iOS.result }} != 'success' && \ - ${{ needs.web.result }} != 'success' ]]; then - echo 'Deploy failed on all platforms, not updating the checklist...' - exit 1 - fi - - - uses: actions/checkout@v3 - - - uses: Expensify/App/.github/actions/composite/setupNode@main - - - name: Set version - id: getVersion - run: echo "VERSION=$(npm run print-version --silent)" >> "$GITHUB_ENV" - - - name: Create or update staging deploy - uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main - with: - GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} - NPM_VERSION: ${{ steps.getVersion.outputs.VERSION }} From 46ea92c5e52d5245f9b1835ff2d5c07beab83424 Mon Sep 17 00:00:00 2001 From: Hayata Suenaga Date: Mon, 11 Sep 2023 13:12:43 +0800 Subject: [PATCH 129/134] chore: add new property to transaction object --- src/types/onyx/Transaction.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/types/onyx/Transaction.ts b/src/types/onyx/Transaction.ts index 9e6cd603472f..17e3e8b5f429 100644 --- a/src/types/onyx/Transaction.ts +++ b/src/types/onyx/Transaction.ts @@ -6,6 +6,18 @@ type Comment = { comment?: string; }; +type Geometry = { + coordinates: number[][]; + type: 'LineString'; +}; + +type Route = { + distance: number; + geometry: Geometry; +}; + +type Routes = Record; + type Transaction = { transactionID: string; amount: number; @@ -25,6 +37,7 @@ type Transaction = { source?: string; state?: ValueOf; }; + routes: Routes; }; export default Transaction; From b82bc07c652ab944227425cdf7d5852b083fec62 Mon Sep 17 00:00:00 2001 From: OSBotify Date: Mon, 11 Sep 2023 05:38:21 +0000 Subject: [PATCH 130/134] Update version to 1.3.67-1 --- android/app/build.gradle | 4 ++-- ios/NewExpensify/Info.plist | 2 +- ios/NewExpensifyTests/Info.plist | 2 +- package-lock.json | 4 ++-- package.json | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/android/app/build.gradle b/android/app/build.gradle index 7f8ab01ca837..1cb4ff03a6a2 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -90,8 +90,8 @@ android { minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion multiDexEnabled rootProject.ext.multiDexEnabled - versionCode 1001036700 - versionName "1.3.67-0" + versionCode 1001036701 + versionName "1.3.67-1" } flavorDimensions "default" diff --git a/ios/NewExpensify/Info.plist b/ios/NewExpensify/Info.plist index 083e2a524ef5..068fe2b29cce 100644 --- a/ios/NewExpensify/Info.plist +++ b/ios/NewExpensify/Info.plist @@ -40,7 +40,7 @@ CFBundleVersion - 1.3.67.0 + 1.3.67.1 ITSAppUsesNonExemptEncryption LSApplicationQueriesSchemes diff --git a/ios/NewExpensifyTests/Info.plist b/ios/NewExpensifyTests/Info.plist index 30c8e2b034ca..04334b57fe77 100644 --- a/ios/NewExpensifyTests/Info.plist +++ b/ios/NewExpensifyTests/Info.plist @@ -19,6 +19,6 @@ CFBundleSignature ???? CFBundleVersion - 1.3.67.0 + 1.3.67.1 diff --git a/package-lock.json b/package-lock.json index ac697c0c5f7e..aec5e3fb86e4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "new.expensify", - "version": "1.3.67-0", + "version": "1.3.67-1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "new.expensify", - "version": "1.3.67-0", + "version": "1.3.67-1", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index ce1ede2302a0..fc40abc69006 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "new.expensify", - "version": "1.3.67-0", + "version": "1.3.67-1", "author": "Expensify, Inc.", "homepage": "https://new.expensify.com", "description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.", From 189c28181065abf0a7cde1aad8417684c4f173da Mon Sep 17 00:00:00 2001 From: Hayata Suenaga Date: Mon, 11 Sep 2023 13:52:40 +0800 Subject: [PATCH 131/134] fix: make routes property optional --- src/types/onyx/Transaction.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/types/onyx/Transaction.ts b/src/types/onyx/Transaction.ts index 17e3e8b5f429..4326920ab51f 100644 --- a/src/types/onyx/Transaction.ts +++ b/src/types/onyx/Transaction.ts @@ -37,7 +37,7 @@ type Transaction = { source?: string; state?: ValueOf; }; - routes: Routes; + routes?: Routes; }; export default Transaction; From a325f5810487c1e0e0908517f0e2013f03150bba Mon Sep 17 00:00:00 2001 From: OSBotify Date: Mon, 11 Sep 2023 05:58:26 +0000 Subject: [PATCH 132/134] Update version to 1.3.67-2 --- android/app/build.gradle | 4 ++-- ios/NewExpensify/Info.plist | 2 +- ios/NewExpensifyTests/Info.plist | 2 +- package-lock.json | 4 ++-- package.json | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/android/app/build.gradle b/android/app/build.gradle index 1cb4ff03a6a2..bd38d9ebe4ba 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -90,8 +90,8 @@ android { minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion multiDexEnabled rootProject.ext.multiDexEnabled - versionCode 1001036701 - versionName "1.3.67-1" + versionCode 1001036702 + versionName "1.3.67-2" } flavorDimensions "default" diff --git a/ios/NewExpensify/Info.plist b/ios/NewExpensify/Info.plist index 068fe2b29cce..00b380a7d1dc 100644 --- a/ios/NewExpensify/Info.plist +++ b/ios/NewExpensify/Info.plist @@ -40,7 +40,7 @@ CFBundleVersion - 1.3.67.1 + 1.3.67.2 ITSAppUsesNonExemptEncryption LSApplicationQueriesSchemes diff --git a/ios/NewExpensifyTests/Info.plist b/ios/NewExpensifyTests/Info.plist index 04334b57fe77..031ce55e7518 100644 --- a/ios/NewExpensifyTests/Info.plist +++ b/ios/NewExpensifyTests/Info.plist @@ -19,6 +19,6 @@ CFBundleSignature ???? CFBundleVersion - 1.3.67.1 + 1.3.67.2 diff --git a/package-lock.json b/package-lock.json index aec5e3fb86e4..7cb287dcd7b3 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "new.expensify", - "version": "1.3.67-1", + "version": "1.3.67-2", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "new.expensify", - "version": "1.3.67-1", + "version": "1.3.67-2", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index fc40abc69006..a70330117caf 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "new.expensify", - "version": "1.3.67-1", + "version": "1.3.67-2", "author": "Expensify, Inc.", "homepage": "https://new.expensify.com", "description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.", From f9171abef70899330502b799e107907b8fcd022b Mon Sep 17 00:00:00 2001 From: Hans Date: Thu, 31 Aug 2023 15:19:25 +0700 Subject: [PATCH 133/134] update translation for modify expense update Spanish for modify expense message update the merchant add check case for merchant fix linting --- src/languages/en.ts | 5 +++++ src/languages/es.ts | 8 ++++++-- src/languages/types.ts | 9 +++++++++ src/libs/ReportUtils.js | 17 +++++++++-------- 4 files changed, 29 insertions(+), 10 deletions(-) diff --git a/src/languages/en.ts b/src/languages/en.ts index c863caae67ff..c025ab20c0f9 100755 --- a/src/languages/en.ts +++ b/src/languages/en.ts @@ -523,6 +523,11 @@ export default { paidUsingExpensifyWithAmount: ({amount}: PaidUsingExpensifyWithAmountParams) => `paid ${amount} using Expensify`, noReimbursableExpenses: 'This report has an invalid amount', pendingConversionMessage: "Total will update when you're back online", + changedTheRequest: 'changed the request', + setTheRequest: ({valueName, newValueToDisplay}: SetTheRequestParams) => `set the ${valueName} to ${newValueToDisplay}`, + removedTheRequest: ({valueName, oldValueToDisplay}: RemovedTheRequestParams) => `removed the ${valueName} (previously ${oldValueToDisplay})`, + updatedTheRequest: ({valueName, newValueToDisplay, oldValueToDisplay}: UpdatedTheRequestParams) => + `changed the ${valueName} to ${newValueToDisplay} (previously ${oldValueToDisplay})`, threadRequestReportName: ({formattedAmount, comment}: ThreadRequestReportNameParams) => `${formattedAmount} request${comment ? ` for ${comment}` : ''}`, threadSentMoneyReportName: ({formattedAmount, comment}: ThreadSentMoneyReportNameParams) => `${formattedAmount} sent${comment ? ` for ${comment}` : ''}`, error: { diff --git a/src/languages/es.ts b/src/languages/es.ts index fd98e3ef51fa..c106f50a6326 100644 --- a/src/languages/es.ts +++ b/src/languages/es.ts @@ -524,8 +524,12 @@ export default { paidUsingExpensifyWithAmount: ({amount}: PaidUsingExpensifyWithAmountParams) => `pagó ${amount} con Expensify`, noReimbursableExpenses: 'El importe de este informe no es válido', pendingConversionMessage: 'El total se actualizará cuando estés online', - threadRequestReportName: ({formattedAmount, comment}: ThreadRequestReportNameParams) => `Solicitud de ${formattedAmount}${comment ? ` para ${comment}` : ''}`, - threadSentMoneyReportName: ({formattedAmount, comment}: ThreadSentMoneyReportNameParams) => `${formattedAmount} enviado${comment ? ` para ${comment}` : ''}`, + changedTheRequest: 'cambió la solicitud', + setTheRequest: ({valueName, newValueToDisplay}: SetTheRequestParams) => `estableció ${valueName === 'comerciante' ? 'el' : 'la'} ${valueName} a ${newValueToDisplay}`, + removedTheRequest: ({valueName, oldValueToDisplay}: RemovedTheRequestParams) => + `eliminó ${valueName === 'comerciante' ? 'el' : 'la'} ${valueName} (previamente ${oldValueToDisplay})`, + updatedTheRequest: ({valueName, newValueToDisplay, oldValueToDisplay}: UpdatedTheRequestParams) => + `cambío ${valueName === 'comerciante' ? 'el' : 'la'} ${valueName} a ${newValueToDisplay} (previamente ${oldValueToDisplay})`, error: { invalidSplit: 'La suma de las partes no equivale al monto total', other: 'Error inesperado, por favor inténtalo más tarde', diff --git a/src/languages/types.ts b/src/languages/types.ts index 50290fb5776c..1acb8de864d8 100644 --- a/src/languages/types.ts +++ b/src/languages/types.ts @@ -184,6 +184,15 @@ type OOOEventSummaryPartialDayParams = {summary: string; timePeriod: string; dat type ParentNavigationSummaryParams = {rootReportName: string; workspaceName: string}; +<<<<<<< HEAD +======= +type SetTheRequestParams = {valueName: string; newValueToDisplay: string}; + +type RemovedTheRequestParams = {valueName: string; oldValueToDisplay: string}; + +type UpdatedTheRequestParams = {valueName: string; newValueToDisplay: string; oldValueToDisplay: string}; + +>>>>>>> dac2d87957 (fix linting) export type { AddressLineParams, CharacterLimitParams, diff --git a/src/libs/ReportUtils.js b/src/libs/ReportUtils.js index 53423e8deaf2..6167a04ada2f 100644 --- a/src/libs/ReportUtils.js +++ b/src/libs/ReportUtils.js @@ -1478,14 +1478,15 @@ function getReportPreviewMessage(report, reportAction = {}, shouldConsiderReceip function getProperSchemaForModifiedExpenseMessage(newValue, oldValue, valueName, valueInQuotes) { const newValueToDisplay = valueInQuotes ? `"${newValue}"` : newValue; const oldValueToDisplay = valueInQuotes ? `"${oldValue}"` : oldValue; + const displayValueName = valueName.toLowerCase(); if (!oldValue) { - return `set the ${valueName} to ${newValueToDisplay}`; + return Localize.translateLocal('iou.setTheRequest', {valueName: displayValueName, newValueToDisplay}); } if (!newValue) { - return `removed the ${valueName} (previously ${oldValueToDisplay})`; + return Localize.translateLocal('iou.removedTheRequest', {valueName: displayValueName, oldValueToDisplay}); } - return `changed the ${valueName} to ${newValueToDisplay} (previously ${oldValueToDisplay})`; + return Localize.translateLocal('iou.updatedTheRequest', {valueName: displayValueName, newValueToDisplay, oldValueToDisplay}); } /** @@ -1497,7 +1498,7 @@ function getProperSchemaForModifiedExpenseMessage(newValue, oldValue, valueName, function getModifiedExpenseMessage(reportAction) { const reportActionOriginalMessage = lodashGet(reportAction, 'originalMessage', {}); if (_.isEmpty(reportActionOriginalMessage)) { - return `changed the request`; + return Localize.translateLocal('iou.changedTheRequest'); } const hasModifiedAmount = @@ -1512,12 +1513,12 @@ function getModifiedExpenseMessage(reportAction) { const currency = reportActionOriginalMessage.currency; const amount = CurrencyUtils.convertToDisplayString(reportActionOriginalMessage.amount, currency); - return getProperSchemaForModifiedExpenseMessage(amount, oldAmount, 'amount', false); + return getProperSchemaForModifiedExpenseMessage(amount, oldAmount, Localize.translateLocal('iou.amount'), false); } const hasModifiedComment = _.has(reportActionOriginalMessage, 'oldComment') && _.has(reportActionOriginalMessage, 'newComment'); if (hasModifiedComment) { - return getProperSchemaForModifiedExpenseMessage(reportActionOriginalMessage.newComment, reportActionOriginalMessage.oldComment, 'description', true); + return getProperSchemaForModifiedExpenseMessage(reportActionOriginalMessage.newComment, reportActionOriginalMessage.oldComment, Localize.translateLocal('common.description'), true); } const hasModifiedCreated = _.has(reportActionOriginalMessage, 'oldCreated') && _.has(reportActionOriginalMessage, 'created'); @@ -1525,12 +1526,12 @@ function getModifiedExpenseMessage(reportAction) { // Take only the YYYY-MM-DD value as the original date includes timestamp let formattedOldCreated = parseISO(reportActionOriginalMessage.oldCreated); formattedOldCreated = format(formattedOldCreated, CONST.DATE.FNS_FORMAT_STRING); - return getProperSchemaForModifiedExpenseMessage(reportActionOriginalMessage.created, formattedOldCreated, 'date', false); + return getProperSchemaForModifiedExpenseMessage(reportActionOriginalMessage.created, formattedOldCreated, Localize.translateLocal('common.date'), false); } const hasModifiedMerchant = _.has(reportActionOriginalMessage, 'oldMerchant') && _.has(reportActionOriginalMessage, 'merchant'); if (hasModifiedMerchant) { - return getProperSchemaForModifiedExpenseMessage(reportActionOriginalMessage.merchant, reportActionOriginalMessage.oldMerchant, 'merchant', true); + return getProperSchemaForModifiedExpenseMessage(reportActionOriginalMessage.merchant, reportActionOriginalMessage.oldMerchant, Localize.translateLocal('common.merchant'), true); } } From 3db0427f7c7de86e2ff45af6c858be1c98cd9c0c Mon Sep 17 00:00:00 2001 From: Hans Date: Mon, 11 Sep 2023 15:13:27 +0700 Subject: [PATCH 134/134] update singing commit --- src/languages/en.ts | 3 +++ src/languages/es.ts | 5 +++++ src/languages/types.ts | 6 +++--- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/languages/en.ts b/src/languages/en.ts index c025ab20c0f9..f52848589663 100755 --- a/src/languages/en.ts +++ b/src/languages/en.ts @@ -68,6 +68,9 @@ import type { OOOEventSummaryPartialDayParams, ParentNavigationSummaryParams, ManagerApprovedParams, + SetTheRequestParams, + UpdatedTheRequestParams, + RemovedTheRequestParams, } from './types'; import * as ReportActionsUtils from '../libs/ReportActionsUtils'; diff --git a/src/languages/es.ts b/src/languages/es.ts index c106f50a6326..8610f41308e1 100644 --- a/src/languages/es.ts +++ b/src/languages/es.ts @@ -68,6 +68,9 @@ import type { OOOEventSummaryPartialDayParams, ParentNavigationSummaryParams, ManagerApprovedParams, + SetTheRequestParams, + UpdatedTheRequestParams, + RemovedTheRequestParams, } from './types'; /* eslint-disable max-len */ @@ -530,6 +533,8 @@ export default { `eliminó ${valueName === 'comerciante' ? 'el' : 'la'} ${valueName} (previamente ${oldValueToDisplay})`, updatedTheRequest: ({valueName, newValueToDisplay, oldValueToDisplay}: UpdatedTheRequestParams) => `cambío ${valueName === 'comerciante' ? 'el' : 'la'} ${valueName} a ${newValueToDisplay} (previamente ${oldValueToDisplay})`, + threadRequestReportName: ({formattedAmount, comment}: ThreadRequestReportNameParams) => `Solicitud de ${formattedAmount}${comment ? ` para ${comment}` : ''}`, + threadSentMoneyReportName: ({formattedAmount, comment}: ThreadSentMoneyReportNameParams) => `${formattedAmount} enviado${comment ? ` para ${comment}` : ''}`, error: { invalidSplit: 'La suma de las partes no equivale al monto total', other: 'Error inesperado, por favor inténtalo más tarde', diff --git a/src/languages/types.ts b/src/languages/types.ts index 1acb8de864d8..059d944fd4ba 100644 --- a/src/languages/types.ts +++ b/src/languages/types.ts @@ -184,15 +184,12 @@ type OOOEventSummaryPartialDayParams = {summary: string; timePeriod: string; dat type ParentNavigationSummaryParams = {rootReportName: string; workspaceName: string}; -<<<<<<< HEAD -======= type SetTheRequestParams = {valueName: string; newValueToDisplay: string}; type RemovedTheRequestParams = {valueName: string; oldValueToDisplay: string}; type UpdatedTheRequestParams = {valueName: string; newValueToDisplay: string; oldValueToDisplay: string}; ->>>>>>> dac2d87957 (fix linting) export type { AddressLineParams, CharacterLimitParams, @@ -261,4 +258,7 @@ export type { OOOEventSummaryFullDayParams, OOOEventSummaryPartialDayParams, ParentNavigationSummaryParams, + SetTheRequestParams, + UpdatedTheRequestParams, + RemovedTheRequestParams, };