From ea05f91d8a611095a37d2ada4927ef6ff41e08ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E6=98=86?= Date: Mon, 6 Jun 2022 19:17:47 +0800 Subject: [PATCH] [+] add taro project --- app/client/public/Methodot_favicon.ico | Bin 23462 -> 0 bytes app/client/src/index.tsx | 14 +- app/server/.env | 29 - app/server/.gitignore | 2 +- app/taro/.editorconfig | 12 + app/taro/.eslintrc.js | 7 + app/taro/.gitignore | 7 + app/taro/README.md | 1 + app/taro/babel.config.js | 32 + app/taro/config/dev.js | 141 + app/taro/config/index.js | 128 + app/taro/config/postcss.pxtransform.js | 339 + app/taro/config/prod.js | 22 + app/taro/global.d.ts | 18 + app/taro/linaria.config.js | 12 + app/taro/package.json | 110 + app/taro/project.config.json | 47 + app/taro/project.private.config.json | 17 + app/taro/project.tt.json | 13 + app/taro/src/actions/actionActions.ts | 300 + app/taro/src/actions/apiPaneActions.ts | 81 + app/taro/src/actions/applicationActions.ts | 105 + app/taro/src/actions/authActions.ts | 5 + app/taro/src/actions/batchActions.ts | 13 + app/taro/src/actions/collectionAction.ts | 7 + app/taro/src/actions/controlActions.tsx | 95 + app/taro/src/actions/datasourceActions.ts | 239 + app/taro/src/actions/debuggerActions.ts | 49 + app/taro/src/actions/errorActions.ts | 16 + app/taro/src/actions/evaluationActions.ts | 82 + app/taro/src/actions/explorerActions.ts | 10 + app/taro/src/actions/helpActions.ts | 14 + app/taro/src/actions/initActions.ts | 26 + app/taro/src/actions/metaActions.ts | 44 + app/taro/src/actions/notificationActions.ts | 58 + app/taro/src/actions/onboardingActions.ts | 73 + app/taro/src/actions/orgActions.ts | 76 + app/taro/src/actions/pageActions.tsx | 366 + app/taro/src/actions/pluginActions.ts | 62 + app/taro/src/actions/propertyPaneActions.ts | 32 + app/taro/src/actions/providerActions.ts | 61 + app/taro/src/actions/queryPaneActions.ts | 29 + app/taro/src/actions/recentEntityActions.ts | 6 + app/taro/src/actions/releasesActions.ts | 5 + app/taro/src/actions/themeActions.ts | 7 + app/taro/src/actions/tourActions.ts | 22 + app/taro/src/actions/userActions.ts | 102 + app/taro/src/actions/utilActions.ts | 15 + app/taro/src/actions/websocketActions.ts | 25 + app/taro/src/actions/widgetActions.tsx | 148 + .../src/actions/widgetSelectionActions.ts | 71 + app/taro/src/actions/widgetSidebarActions.tsx | 33 + app/taro/src/api/ActionAPI.tsx | 188 + app/taro/src/api/Api.ts | 101 + app/taro/src/api/ApiResponses.tsx | 31 + app/taro/src/api/ApiUtils.ts | 147 + app/taro/src/api/ApplicationApi.tsx | 217 + app/taro/src/api/CollectionApi.ts | 12 + app/taro/src/api/DatasourcesApi.ts | 105 + app/taro/src/api/ImportApi.ts | 27 + app/taro/src/api/NotificationsAPI.tsx | 33 + app/taro/src/api/OrgApi.ts | 132 + app/taro/src/api/PageApi.tsx | 229 + app/taro/src/api/PluginApi.ts | 48 + app/taro/src/api/ProvidersApi.ts | 126 + app/taro/src/api/ReleasesAPI.tsx | 13 + app/taro/src/api/SaasApi.ts | 25 + app/taro/src/api/UserApi.tsx | 155 + app/taro/src/api/WidgetConfigsApi.tsx | 18 + app/taro/src/api/WidgetSidebarApi.tsx | 17 + app/taro/src/app.config.ts | 14 + app/taro/src/app.less | 17 + app/taro/src/app.tsx | 25 + .../src/assets/images/placeholder-image.svg | 1 + app/taro/src/components/common/AppPage.tsx | 35 + app/taro/src/components/common/AppViewer.tsx | 113 + .../common/AppViewerPageContainer.tsx | 85 + .../src/components/common/PageFactory.tsx | 33 + .../src/components/common/ReduxContext.ts | 15 + .../designSystems/appsmith/BaseComponent.tsx | 17 + .../appsmith/ContainerComponent.tsx | 47 + .../appsmith/PositionedContainer.tsx | 75 + .../appsmith/TableComponent/Constants.ts | 225 + .../appsmith/TableComponent/TableHelpers.ts | 50 + .../taro/ActionBar/ActionBar.tsx | 37 + .../taro/ActionBar/ActionBarButton.tsx | 63 + .../taro/ActionBar/ActionBarContext.ts | 9 + .../taro/ActionBar/ActionBarIcon.tsx | 38 + .../designSystems/taro/ActionBar/PropsType.ts | 45 + .../designSystems/taro/ActionBar/index.tsx | 12 + .../taro/ActionBar/style/index.less | 104 + .../taro/ActionBar/style/var.less | 17 + .../designSystems/taro/BottomBarComponent.tsx | 63 + .../designSystems/taro/ButtonComponent.tsx | 56 + .../designSystems/taro/CellComponent.tsx | 91 + .../designSystems/taro/EmptyContent.tsx | 64 + .../taro/FormComponent/AddressField.tsx | 113 + .../taro/FormComponent/CheckboxField.tsx | 36 + .../taro/FormComponent/InputField.tsx | 28 + .../taro/FormComponent/PickerField.tsx | 85 + .../taro/FormComponent/RadioField.tsx | 31 + .../taro/FormComponent/RateField.tsx | 21 + .../taro/FormComponent/StepperField.tsx | 21 + .../taro/FormComponent/SwitchField.tsx | 21 + .../taro/FormComponent/UploaderField.tsx | 47 + .../taro/FormComponent/index.tsx | 180 + .../designSystems/taro/GridComponent.tsx | 218 + .../designSystems/taro/ImageComponent.tsx | 36 + .../designSystems/taro/KVComponent.tsx | 139 + .../designSystems/taro/ListComponent.tsx | 376 + .../designSystems/taro/NavTabComponent.tsx | 53 + .../designSystems/taro/PickerComponent.tsx | 201 + .../designSystems/taro/PopoverComponent.tsx | 76 + .../taro/SkuComponent/PropsType.ts | 209 + .../designSystems/taro/SkuComponent/Sku.tsx | 565 + .../taro/SkuComponent/SkuRow.tsx | 44 + .../taro/SkuComponent/SkuRowItem.tsx | 94 + .../taro/SkuComponent/SkuRowPropItem.tsx | 52 + .../taro/SkuComponent/SkuStepper.tsx | 139 + .../designSystems/taro/SkuComponent/bem.ts | 45 + .../taro/SkuComponent/constants.ts | 20 + .../designSystems/taro/SkuComponent/index.ts | 5 + .../taro/SkuComponent/style/index.less | 324 + .../taro/SkuComponent/style/var.less | 6 + .../designSystems/taro/SkuComponent/utils.ts | 204 + .../designSystems/taro/SwiperComponent.tsx | 42 + .../components/designSystems/taro/TabBar.tsx | 56 + .../designSystems/taro/TextComponent.tsx | 85 + .../designSystems/taro/rvStyle/var.less | 88 + .../EditorContextProvider.tsx | 33 + .../editorComponents/ErrorBoundry.tsx | 56 + .../PreventInteractionsOverlay.tsx | 50 + .../components/formControls/BaseControl.tsx | 73 + app/taro/src/components/formControls/utils.ts | 147 + .../propertyControls/BaseControl.tsx | 53 + .../src/components/propertyControls/index.ts | 20 + app/taro/src/configs/index.ts | 28 + app/taro/src/configs/types.ts | 21 + app/taro/src/constants/ApiConstants.tsx | 31 + app/taro/src/constants/ApiEditorConstants.ts | 76 + app/taro/src/constants/AppConstants.ts | 25 + .../ActionConstants.tsx | 143 + .../formConfig/ApiDependencyConfigs.ts | 5 + .../formConfig/ApiEditorConfigs.ts | 92 + .../formConfig/ApiSettingsConfig.ts | 53 + .../formConfig/GoogleSheetsSettingsConfig.ts | 27 + .../formConfig/QuerySettingsConfig.ts | 38 + app/taro/src/constants/BindingsConstants.ts | 4 + app/taro/src/constants/Colors.tsx | 121 + app/taro/src/constants/CommentConstants.tsx | 9 + app/taro/src/constants/Currency.tsx | 1998 +++ .../src/constants/CustomChartConstants.ts | 118 + .../constants/DatasourceEditorConstants.ts | 5 + app/taro/src/constants/DefaultTheme.tsx | 16 + app/taro/src/constants/Explorer.ts | 2 + app/taro/src/constants/FieldExpectedValue.ts | 10 + app/taro/src/constants/Fonts.tsx | 4 + app/taro/src/constants/HelpConstants.ts | 6 + app/taro/src/constants/KeyboardShortcuts.ts | 7 + app/taro/src/constants/Layers.tsx | 57 + .../OmnibarDocumentationConstants.ts | 58 + .../src/constants/OnboardingConstants.tsx | 306 + .../constants/PropertyControlConstants.tsx | 94 + .../src/constants/QueryEditorConstants.ts | 10 + .../src/constants/ReduxActionConstants.tsx | 731 + app/taro/src/constants/SocialLogin.tsx | 44 + app/taro/src/constants/StyleConstants.tsx | 1 + .../src/constants/ThirdPartyConstants.tsx | 3 + app/taro/src/constants/TourSteps.tsx | 12 + app/taro/src/constants/WebsocketConstants.tsx | 17 + app/taro/src/constants/WidgetConstants.tsx | 163 + app/taro/src/constants/WidgetValidation.ts | 88 + .../src/constants/collectionsConstants.ts | 21 + app/taro/src/constants/defs/base64-js.json | 11 + app/taro/src/constants/defs/ecmascript.json | 1360 ++ app/taro/src/constants/defs/forge.json | 11263 +++++++++++++ app/taro/src/constants/defs/lodash.json | 1545 ++ app/taro/src/constants/defs/moment.json | 730 + app/taro/src/constants/defs/xmlParser.json | 13 + app/taro/src/constants/editorConstants.tsx | 8 + app/taro/src/constants/forms.ts | 24 + app/taro/src/constants/messages.test.ts | 9 + app/taro/src/constants/messages.ts | 397 + app/taro/src/constants/orgConstants.ts | 31 + app/taro/src/constants/providerConstants.ts | 98 + app/taro/src/constants/routes.ts | 236 + app/taro/src/constants/userConstants.ts | 37 + .../src/entities/Action/actionProperties.ts | 74 + app/taro/src/entities/Action/index.ts | 128 + app/taro/src/entities/App.ts | 4 + .../src/entities/AppsmithConsole/action.ts | 10 + .../src/entities/AppsmithConsole/binding.ts | 26 + app/taro/src/entities/AppsmithConsole/eval.ts | 10 + .../src/entities/AppsmithConsole/index.ts | 111 + .../src/entities/AppsmithConsole/logtype.ts | 11 + .../src/entities/AppsmithConsole/widget.ts | 1 + .../src/entities/DataTree/dataTreeAction.ts | 50 + .../src/entities/DataTree/dataTreeFactory.ts | 136 + .../src/entities/DataTree/dataTreeWidget.ts | 82 + .../src/entities/Datasource/RestAPIForm.ts | 81 + app/taro/src/entities/Datasource/index.ts | 103 + app/taro/src/entities/FeatureFlag.ts | 6 + app/taro/src/entities/Notification.ts | 12 + app/taro/src/entities/Tour/index.ts | 4 + app/taro/src/entities/Widget/utils.ts | 162 + app/taro/src/index.html | 19 + .../ApplicationsNewMockResponse.json | 422 + .../mockResponses/CommentApiMockResponse.tsx | 365 + .../CreateOrganisationMockResponse.json | 115 + .../src/mockResponses/PageMockResponse.tsx | 58 + .../mockResponses/WidgetConfigResponse.tsx | 446 + .../normalizers/CanvasWidgetsNormalizer.tsx | 27 + app/taro/src/pages/index/index.config.ts | 3 + app/taro/src/pages/index/index.less | 1 + app/taro/src/pages/index/index.tsx | 4 + app/taro/src/pages/page1/index.config.ts | 3 + app/taro/src/pages/page1/index.less | 1 + app/taro/src/pages/page1/index.tsx | 4 + .../entityReducers/actionsReducer.tsx | 372 + .../src/reducers/entityReducers/appReducer.ts | 101 + .../entityReducers/canvasWidgetsReducer.tsx | 44 + .../entityReducers/datasourceReducer.ts | 284 + app/taro/src/reducers/entityReducers/index.ts | 24 + .../entityReducers/jsExecutionsReducer.ts | 21 + .../reducers/entityReducers/metaReducer.ts | 91 + .../entityReducers/pageListReducer.tsx | 165 + .../reducers/entityReducers/pluginsReducer.ts | 114 + .../entityReducers/widgetConfigReducer.tsx | 84 + .../evaluationReducers/dependencyReducer.ts | 25 + .../src/reducers/evaluationReducers/index.ts | 10 + .../loadingEntitiesReducer.ts | 16 + .../evaluationReducers/treeReducer.ts | 45 + app/taro/src/reducers/index.tsx | 107 + .../reducers/uiReducers/appViewReducer.tsx | 44 + .../uiReducers/applicationsReducer.tsx | 408 + .../reducers/uiReducers/debuggerReducer.ts | 125 + .../src/reducers/uiReducers/editorReducer.tsx | 206 + .../src/reducers/uiReducers/errorReducer.tsx | 51 + app/taro/src/reducers/uiReducers/index.tsx | 22 + .../uiReducers/pageCanvasStructureReducer.ts | 65 + .../reducers/uiReducers/pageWidgetsReducer.ts | 43 + .../src/reducers/uiReducers/themeReducer.ts | 49 + app/taro/src/sagas/ActionExecutionSagas.ts | 919 ++ app/taro/src/sagas/ActionSagas.ts | 770 + app/taro/src/sagas/ApplicationSagas.tsx | 37 + app/taro/src/sagas/BatchSagas.tsx | 76 + app/taro/src/sagas/DebuggerSagas.ts | 324 + app/taro/src/sagas/ErrorSagas.tsx | 271 + app/taro/src/sagas/EvaluationsSaga.ts | 227 + app/taro/src/sagas/InitSagas.ts | 114 + app/taro/src/sagas/ModalSagas.ts | 198 + app/taro/src/sagas/PageSagas.tsx | 352 + app/taro/src/sagas/PostEvaluationSagas.ts | 216 + .../src/sagas/WidgetEnhancementHelpers.ts | 230 + app/taro/src/sagas/WidgetLoadingSaga.ts | 110 + app/taro/src/sagas/index.tsx | 44 + app/taro/src/sagas/selectors.tsx | 177 + app/taro/src/selectors/appViewSelectors.tsx | 46 + .../src/selectors/applicationSelectors.tsx | 148 + app/taro/src/selectors/authSelectors.tsx | 5 + app/taro/src/selectors/dataTreeSelectors.ts | 80 + app/taro/src/selectors/debuggerSelectors.tsx | 3 + app/taro/src/selectors/editorSelectors.tsx | 248 + app/taro/src/selectors/entitiesSelector.ts | 467 + app/taro/src/selectors/errorSelectors.tsx | 9 + app/taro/src/selectors/formSelectors.ts | 21 + app/taro/src/selectors/helpSelectors.tsx | 8 + .../src/selectors/notificationSelectors.ts | 13 + .../src/selectors/onboardingSelectors.tsx | 7 + .../src/selectors/organizationSelectors.tsx | 63 + app/taro/src/selectors/pageListSelectors.tsx | 11 + .../src/selectors/propertyPaneSelectors.tsx | 178 + .../src/selectors/tableFilterSelectors.tsx | 37 + app/taro/src/selectors/themeSelectors.tsx | 26 + app/taro/src/selectors/tourSelectors.tsx | 7 + app/taro/src/selectors/ui.tsx | 7 + app/taro/src/selectors/usersSelectors.tsx | 14 + .../selectors/widgetEnhancementSelectors.ts | 101 + app/taro/src/selectors/widgetSelectors.ts | 33 + app/taro/src/store.ts | 20 + app/taro/src/templates/default.ts | 19 + .../src/transformers/CurlImportTransformer.ts | 3 + .../RestAPIDatasourceFormTransformer.ts | 249 + .../src/transformers/RestActionTransformer.ts | 45 + app/taro/src/typings/worker-loader/index.d.ts | 7 + app/taro/src/utils/AnalyticsUtil.tsx | 149 + app/taro/src/utils/AppsmithConsole.ts | 40 + app/taro/src/utils/AppsmithUtils.tsx | 241 + app/taro/src/utils/DynamicBindingUtils.ts | 338 + app/taro/src/utils/EditorUtils.ts | 5 + app/taro/src/utils/TypeHelpers.ts | 39 + app/taro/src/utils/WidgetFactory.tsx | 237 + app/taro/src/utils/WidgetPropsUtils.tsx | 711 + app/taro/src/utils/WidgetRegistry.tsx | 383 + app/taro/src/utils/WorkerUtil.ts | 176 + .../utils/autocomplete/EntityDefinitions.ts | 67 + app/taro/src/utils/canvasStructureHelpers.ts | 44 + app/taro/src/utils/generators.tsx | 33 + app/taro/src/utils/helpers.tsx | 291 + app/taro/src/utils/hooks/use-ref-state.ts | 22 + app/taro/src/utils/hooks/use-set-state.ts | 26 + app/taro/src/utils/hooks/use-unmounted-ref.ts | 16 + .../src/utils/hooks/useDynamicAppLayout.tsx | 92 + .../IncorrectDynamicBindingPathLists.ts | 41 + app/taro/src/utils/migrations/TableWidget.ts | 300 + .../migrations/TextWidgetReplaceTextStyle.ts | 36 + app/taro/src/utils/validation/getIsSafeURL.ts | 37 + app/taro/src/widgets/BaseWidget.tsx | 376 + app/taro/src/widgets/CanvasWidget.tsx | 75 + app/taro/src/widgets/ContainerWidget.tsx | 149 + app/taro/src/widgets/FileDataTypes.ts | 7 + app/taro/src/widgets/MetaHOC.tsx | 194 + app/taro/src/widgets/SkeletonWidget.tsx | 31 + app/taro/src/widgets/taro/ActionBarWidget.tsx | 242 + app/taro/src/widgets/taro/BottomBarWidget.tsx | 101 + app/taro/src/widgets/taro/ButtonWidget.tsx | 187 + app/taro/src/widgets/taro/CellWidget.tsx | 295 + app/taro/src/widgets/taro/CheckboxWidget.tsx | 152 + app/taro/src/widgets/taro/FormWidget.tsx | 382 + app/taro/src/widgets/taro/GridWidget.tsx | 342 + app/taro/src/widgets/taro/HtmlWidget.tsx | 62 + app/taro/src/widgets/taro/ImageWidget.tsx | 125 + app/taro/src/widgets/taro/KVWidget.tsx | 306 + app/taro/src/widgets/taro/ListWidget.tsx | 480 + app/taro/src/widgets/taro/LoadingWidget.tsx | 85 + app/taro/src/widgets/taro/LoadingWrapper.tsx | 18 + app/taro/src/widgets/taro/PickerWidget.tsx | 80 + app/taro/src/widgets/taro/PopupWidget.tsx | 151 + app/taro/src/widgets/taro/SearchWidget.tsx | 198 + app/taro/src/widgets/taro/SkuWidget.tsx | 388 + app/taro/src/widgets/taro/SwiperWidget.tsx | 63 + app/taro/src/widgets/taro/TabsWidget.tsx | 281 + app/taro/src/widgets/taro/TextWidget.tsx | 200 + app/taro/src/worker/worker.js | 2 + app/taro/src/workers/DataTreeEvaluator.ts | 1209 ++ app/taro/src/workers/ast.ts | 11 + app/taro/src/workers/evaluate.ts | 211 + app/taro/src/workers/evaluation.worker.ts | 186 + .../src/workers/evaluationSubstitution.ts | 147 + app/taro/src/workers/evaluationUtils.ts | 596 + app/taro/src/workers/validations.ts | 585 + app/taro/tsconfig.json | 31 + app/taro/yarn.lock | 13153 ++++++++++++++++ cloudos_deploy/Dockerfile | 12 - cloudos_deploy/html/favicon.ico | Bin 23462 -> 0 bytes cloudos_deploy/html/index.html | 30 - cloudos_deploy/start-nginx.sh | 6 - .../templates/nginx-app.conf.template | 22 - .../templates/nginx-root.conf.template | 41 - 349 files changed, 65818 insertions(+), 154 deletions(-) delete mode 100644 app/client/public/Methodot_favicon.ico delete mode 100644 app/server/.env create mode 100644 app/taro/.editorconfig create mode 100644 app/taro/.eslintrc.js create mode 100644 app/taro/.gitignore create mode 100644 app/taro/README.md create mode 100644 app/taro/babel.config.js create mode 100644 app/taro/config/dev.js create mode 100644 app/taro/config/index.js create mode 100644 app/taro/config/postcss.pxtransform.js create mode 100644 app/taro/config/prod.js create mode 100644 app/taro/global.d.ts create mode 100644 app/taro/linaria.config.js create mode 100644 app/taro/package.json create mode 100644 app/taro/project.config.json create mode 100644 app/taro/project.private.config.json create mode 100644 app/taro/project.tt.json create mode 100644 app/taro/src/actions/actionActions.ts create mode 100644 app/taro/src/actions/apiPaneActions.ts create mode 100644 app/taro/src/actions/applicationActions.ts create mode 100644 app/taro/src/actions/authActions.ts create mode 100644 app/taro/src/actions/batchActions.ts create mode 100644 app/taro/src/actions/collectionAction.ts create mode 100644 app/taro/src/actions/controlActions.tsx create mode 100644 app/taro/src/actions/datasourceActions.ts create mode 100644 app/taro/src/actions/debuggerActions.ts create mode 100644 app/taro/src/actions/errorActions.ts create mode 100644 app/taro/src/actions/evaluationActions.ts create mode 100644 app/taro/src/actions/explorerActions.ts create mode 100644 app/taro/src/actions/helpActions.ts create mode 100644 app/taro/src/actions/initActions.ts create mode 100644 app/taro/src/actions/metaActions.ts create mode 100644 app/taro/src/actions/notificationActions.ts create mode 100644 app/taro/src/actions/onboardingActions.ts create mode 100644 app/taro/src/actions/orgActions.ts create mode 100644 app/taro/src/actions/pageActions.tsx create mode 100644 app/taro/src/actions/pluginActions.ts create mode 100644 app/taro/src/actions/propertyPaneActions.ts create mode 100644 app/taro/src/actions/providerActions.ts create mode 100644 app/taro/src/actions/queryPaneActions.ts create mode 100644 app/taro/src/actions/recentEntityActions.ts create mode 100644 app/taro/src/actions/releasesActions.ts create mode 100644 app/taro/src/actions/themeActions.ts create mode 100644 app/taro/src/actions/tourActions.ts create mode 100644 app/taro/src/actions/userActions.ts create mode 100644 app/taro/src/actions/utilActions.ts create mode 100644 app/taro/src/actions/websocketActions.ts create mode 100644 app/taro/src/actions/widgetActions.tsx create mode 100644 app/taro/src/actions/widgetSelectionActions.ts create mode 100644 app/taro/src/actions/widgetSidebarActions.tsx create mode 100644 app/taro/src/api/ActionAPI.tsx create mode 100644 app/taro/src/api/Api.ts create mode 100644 app/taro/src/api/ApiResponses.tsx create mode 100644 app/taro/src/api/ApiUtils.ts create mode 100644 app/taro/src/api/ApplicationApi.tsx create mode 100644 app/taro/src/api/CollectionApi.ts create mode 100644 app/taro/src/api/DatasourcesApi.ts create mode 100644 app/taro/src/api/ImportApi.ts create mode 100644 app/taro/src/api/NotificationsAPI.tsx create mode 100644 app/taro/src/api/OrgApi.ts create mode 100644 app/taro/src/api/PageApi.tsx create mode 100644 app/taro/src/api/PluginApi.ts create mode 100644 app/taro/src/api/ProvidersApi.ts create mode 100644 app/taro/src/api/ReleasesAPI.tsx create mode 100644 app/taro/src/api/SaasApi.ts create mode 100644 app/taro/src/api/UserApi.tsx create mode 100644 app/taro/src/api/WidgetConfigsApi.tsx create mode 100644 app/taro/src/api/WidgetSidebarApi.tsx create mode 100644 app/taro/src/app.config.ts create mode 100644 app/taro/src/app.less create mode 100644 app/taro/src/app.tsx create mode 100644 app/taro/src/assets/images/placeholder-image.svg create mode 100644 app/taro/src/components/common/AppPage.tsx create mode 100644 app/taro/src/components/common/AppViewer.tsx create mode 100644 app/taro/src/components/common/AppViewerPageContainer.tsx create mode 100644 app/taro/src/components/common/PageFactory.tsx create mode 100644 app/taro/src/components/common/ReduxContext.ts create mode 100644 app/taro/src/components/designSystems/appsmith/BaseComponent.tsx create mode 100644 app/taro/src/components/designSystems/appsmith/ContainerComponent.tsx create mode 100644 app/taro/src/components/designSystems/appsmith/PositionedContainer.tsx create mode 100644 app/taro/src/components/designSystems/appsmith/TableComponent/Constants.ts create mode 100644 app/taro/src/components/designSystems/appsmith/TableComponent/TableHelpers.ts create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/ActionBar.tsx create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/ActionBarButton.tsx create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/ActionBarContext.ts create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/ActionBarIcon.tsx create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/PropsType.ts create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/index.tsx create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/style/index.less create mode 100644 app/taro/src/components/designSystems/taro/ActionBar/style/var.less create mode 100644 app/taro/src/components/designSystems/taro/BottomBarComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/ButtonComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/CellComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/EmptyContent.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/AddressField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/CheckboxField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/InputField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/PickerField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/RadioField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/RateField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/StepperField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/SwitchField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/UploaderField.tsx create mode 100644 app/taro/src/components/designSystems/taro/FormComponent/index.tsx create mode 100644 app/taro/src/components/designSystems/taro/GridComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/ImageComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/KVComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/ListComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/NavTabComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/PickerComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/PopoverComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/PropsType.ts create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/Sku.tsx create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/SkuRow.tsx create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/SkuRowItem.tsx create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/SkuRowPropItem.tsx create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/SkuStepper.tsx create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/bem.ts create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/constants.ts create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/index.ts create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/style/index.less create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/style/var.less create mode 100644 app/taro/src/components/designSystems/taro/SkuComponent/utils.ts create mode 100644 app/taro/src/components/designSystems/taro/SwiperComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/TabBar.tsx create mode 100644 app/taro/src/components/designSystems/taro/TextComponent.tsx create mode 100644 app/taro/src/components/designSystems/taro/rvStyle/var.less create mode 100644 app/taro/src/components/editorComponents/EditorContextProvider.tsx create mode 100644 app/taro/src/components/editorComponents/ErrorBoundry.tsx create mode 100644 app/taro/src/components/editorComponents/PreventInteractionsOverlay.tsx create mode 100644 app/taro/src/components/formControls/BaseControl.tsx create mode 100644 app/taro/src/components/formControls/utils.ts create mode 100644 app/taro/src/components/propertyControls/BaseControl.tsx create mode 100644 app/taro/src/components/propertyControls/index.ts create mode 100644 app/taro/src/configs/index.ts create mode 100644 app/taro/src/configs/types.ts create mode 100644 app/taro/src/constants/ApiConstants.tsx create mode 100644 app/taro/src/constants/ApiEditorConstants.ts create mode 100644 app/taro/src/constants/AppConstants.ts create mode 100644 app/taro/src/constants/AppsmithActionConstants/ActionConstants.tsx create mode 100644 app/taro/src/constants/AppsmithActionConstants/formConfig/ApiDependencyConfigs.ts create mode 100644 app/taro/src/constants/AppsmithActionConstants/formConfig/ApiEditorConfigs.ts create mode 100644 app/taro/src/constants/AppsmithActionConstants/formConfig/ApiSettingsConfig.ts create mode 100644 app/taro/src/constants/AppsmithActionConstants/formConfig/GoogleSheetsSettingsConfig.ts create mode 100644 app/taro/src/constants/AppsmithActionConstants/formConfig/QuerySettingsConfig.ts create mode 100644 app/taro/src/constants/BindingsConstants.ts create mode 100644 app/taro/src/constants/Colors.tsx create mode 100644 app/taro/src/constants/CommentConstants.tsx create mode 100644 app/taro/src/constants/Currency.tsx create mode 100644 app/taro/src/constants/CustomChartConstants.ts create mode 100644 app/taro/src/constants/DatasourceEditorConstants.ts create mode 100644 app/taro/src/constants/DefaultTheme.tsx create mode 100644 app/taro/src/constants/Explorer.ts create mode 100644 app/taro/src/constants/FieldExpectedValue.ts create mode 100644 app/taro/src/constants/Fonts.tsx create mode 100644 app/taro/src/constants/HelpConstants.ts create mode 100644 app/taro/src/constants/KeyboardShortcuts.ts create mode 100644 app/taro/src/constants/Layers.tsx create mode 100644 app/taro/src/constants/OmnibarDocumentationConstants.ts create mode 100644 app/taro/src/constants/OnboardingConstants.tsx create mode 100644 app/taro/src/constants/PropertyControlConstants.tsx create mode 100644 app/taro/src/constants/QueryEditorConstants.ts create mode 100644 app/taro/src/constants/ReduxActionConstants.tsx create mode 100644 app/taro/src/constants/SocialLogin.tsx create mode 100644 app/taro/src/constants/StyleConstants.tsx create mode 100644 app/taro/src/constants/ThirdPartyConstants.tsx create mode 100644 app/taro/src/constants/TourSteps.tsx create mode 100644 app/taro/src/constants/WebsocketConstants.tsx create mode 100644 app/taro/src/constants/WidgetConstants.tsx create mode 100644 app/taro/src/constants/WidgetValidation.ts create mode 100644 app/taro/src/constants/collectionsConstants.ts create mode 100644 app/taro/src/constants/defs/base64-js.json create mode 100644 app/taro/src/constants/defs/ecmascript.json create mode 100644 app/taro/src/constants/defs/forge.json create mode 100644 app/taro/src/constants/defs/lodash.json create mode 100644 app/taro/src/constants/defs/moment.json create mode 100644 app/taro/src/constants/defs/xmlParser.json create mode 100644 app/taro/src/constants/editorConstants.tsx create mode 100644 app/taro/src/constants/forms.ts create mode 100644 app/taro/src/constants/messages.test.ts create mode 100644 app/taro/src/constants/messages.ts create mode 100644 app/taro/src/constants/orgConstants.ts create mode 100644 app/taro/src/constants/providerConstants.ts create mode 100644 app/taro/src/constants/routes.ts create mode 100644 app/taro/src/constants/userConstants.ts create mode 100644 app/taro/src/entities/Action/actionProperties.ts create mode 100644 app/taro/src/entities/Action/index.ts create mode 100644 app/taro/src/entities/App.ts create mode 100644 app/taro/src/entities/AppsmithConsole/action.ts create mode 100644 app/taro/src/entities/AppsmithConsole/binding.ts create mode 100644 app/taro/src/entities/AppsmithConsole/eval.ts create mode 100644 app/taro/src/entities/AppsmithConsole/index.ts create mode 100644 app/taro/src/entities/AppsmithConsole/logtype.ts create mode 100644 app/taro/src/entities/AppsmithConsole/widget.ts create mode 100644 app/taro/src/entities/DataTree/dataTreeAction.ts create mode 100644 app/taro/src/entities/DataTree/dataTreeFactory.ts create mode 100644 app/taro/src/entities/DataTree/dataTreeWidget.ts create mode 100644 app/taro/src/entities/Datasource/RestAPIForm.ts create mode 100644 app/taro/src/entities/Datasource/index.ts create mode 100644 app/taro/src/entities/FeatureFlag.ts create mode 100644 app/taro/src/entities/Notification.ts create mode 100644 app/taro/src/entities/Tour/index.ts create mode 100644 app/taro/src/entities/Widget/utils.ts create mode 100644 app/taro/src/index.html create mode 100644 app/taro/src/mockResponses/ApplicationsNewMockResponse.json create mode 100644 app/taro/src/mockResponses/CommentApiMockResponse.tsx create mode 100644 app/taro/src/mockResponses/CreateOrganisationMockResponse.json create mode 100644 app/taro/src/mockResponses/PageMockResponse.tsx create mode 100644 app/taro/src/mockResponses/WidgetConfigResponse.tsx create mode 100644 app/taro/src/normalizers/CanvasWidgetsNormalizer.tsx create mode 100644 app/taro/src/pages/index/index.config.ts create mode 100644 app/taro/src/pages/index/index.less create mode 100644 app/taro/src/pages/index/index.tsx create mode 100644 app/taro/src/pages/page1/index.config.ts create mode 100644 app/taro/src/pages/page1/index.less create mode 100644 app/taro/src/pages/page1/index.tsx create mode 100644 app/taro/src/reducers/entityReducers/actionsReducer.tsx create mode 100644 app/taro/src/reducers/entityReducers/appReducer.ts create mode 100644 app/taro/src/reducers/entityReducers/canvasWidgetsReducer.tsx create mode 100644 app/taro/src/reducers/entityReducers/datasourceReducer.ts create mode 100644 app/taro/src/reducers/entityReducers/index.ts create mode 100644 app/taro/src/reducers/entityReducers/jsExecutionsReducer.ts create mode 100644 app/taro/src/reducers/entityReducers/metaReducer.ts create mode 100644 app/taro/src/reducers/entityReducers/pageListReducer.tsx create mode 100644 app/taro/src/reducers/entityReducers/pluginsReducer.ts create mode 100644 app/taro/src/reducers/entityReducers/widgetConfigReducer.tsx create mode 100644 app/taro/src/reducers/evaluationReducers/dependencyReducer.ts create mode 100644 app/taro/src/reducers/evaluationReducers/index.ts create mode 100644 app/taro/src/reducers/evaluationReducers/loadingEntitiesReducer.ts create mode 100644 app/taro/src/reducers/evaluationReducers/treeReducer.ts create mode 100644 app/taro/src/reducers/index.tsx create mode 100644 app/taro/src/reducers/uiReducers/appViewReducer.tsx create mode 100644 app/taro/src/reducers/uiReducers/applicationsReducer.tsx create mode 100644 app/taro/src/reducers/uiReducers/debuggerReducer.ts create mode 100644 app/taro/src/reducers/uiReducers/editorReducer.tsx create mode 100644 app/taro/src/reducers/uiReducers/errorReducer.tsx create mode 100644 app/taro/src/reducers/uiReducers/index.tsx create mode 100644 app/taro/src/reducers/uiReducers/pageCanvasStructureReducer.ts create mode 100644 app/taro/src/reducers/uiReducers/pageWidgetsReducer.ts create mode 100644 app/taro/src/reducers/uiReducers/themeReducer.ts create mode 100644 app/taro/src/sagas/ActionExecutionSagas.ts create mode 100644 app/taro/src/sagas/ActionSagas.ts create mode 100644 app/taro/src/sagas/ApplicationSagas.tsx create mode 100644 app/taro/src/sagas/BatchSagas.tsx create mode 100644 app/taro/src/sagas/DebuggerSagas.ts create mode 100644 app/taro/src/sagas/ErrorSagas.tsx create mode 100644 app/taro/src/sagas/EvaluationsSaga.ts create mode 100644 app/taro/src/sagas/InitSagas.ts create mode 100644 app/taro/src/sagas/ModalSagas.ts create mode 100644 app/taro/src/sagas/PageSagas.tsx create mode 100644 app/taro/src/sagas/PostEvaluationSagas.ts create mode 100644 app/taro/src/sagas/WidgetEnhancementHelpers.ts create mode 100644 app/taro/src/sagas/WidgetLoadingSaga.ts create mode 100644 app/taro/src/sagas/index.tsx create mode 100644 app/taro/src/sagas/selectors.tsx create mode 100644 app/taro/src/selectors/appViewSelectors.tsx create mode 100644 app/taro/src/selectors/applicationSelectors.tsx create mode 100644 app/taro/src/selectors/authSelectors.tsx create mode 100644 app/taro/src/selectors/dataTreeSelectors.ts create mode 100644 app/taro/src/selectors/debuggerSelectors.tsx create mode 100644 app/taro/src/selectors/editorSelectors.tsx create mode 100644 app/taro/src/selectors/entitiesSelector.ts create mode 100644 app/taro/src/selectors/errorSelectors.tsx create mode 100644 app/taro/src/selectors/formSelectors.ts create mode 100644 app/taro/src/selectors/helpSelectors.tsx create mode 100644 app/taro/src/selectors/notificationSelectors.ts create mode 100644 app/taro/src/selectors/onboardingSelectors.tsx create mode 100644 app/taro/src/selectors/organizationSelectors.tsx create mode 100644 app/taro/src/selectors/pageListSelectors.tsx create mode 100644 app/taro/src/selectors/propertyPaneSelectors.tsx create mode 100644 app/taro/src/selectors/tableFilterSelectors.tsx create mode 100644 app/taro/src/selectors/themeSelectors.tsx create mode 100644 app/taro/src/selectors/tourSelectors.tsx create mode 100644 app/taro/src/selectors/ui.tsx create mode 100644 app/taro/src/selectors/usersSelectors.tsx create mode 100644 app/taro/src/selectors/widgetEnhancementSelectors.ts create mode 100644 app/taro/src/selectors/widgetSelectors.ts create mode 100644 app/taro/src/store.ts create mode 100644 app/taro/src/templates/default.ts create mode 100644 app/taro/src/transformers/CurlImportTransformer.ts create mode 100644 app/taro/src/transformers/RestAPIDatasourceFormTransformer.ts create mode 100644 app/taro/src/transformers/RestActionTransformer.ts create mode 100644 app/taro/src/typings/worker-loader/index.d.ts create mode 100644 app/taro/src/utils/AnalyticsUtil.tsx create mode 100644 app/taro/src/utils/AppsmithConsole.ts create mode 100644 app/taro/src/utils/AppsmithUtils.tsx create mode 100644 app/taro/src/utils/DynamicBindingUtils.ts create mode 100644 app/taro/src/utils/EditorUtils.ts create mode 100644 app/taro/src/utils/TypeHelpers.ts create mode 100644 app/taro/src/utils/WidgetFactory.tsx create mode 100644 app/taro/src/utils/WidgetPropsUtils.tsx create mode 100644 app/taro/src/utils/WidgetRegistry.tsx create mode 100644 app/taro/src/utils/WorkerUtil.ts create mode 100644 app/taro/src/utils/autocomplete/EntityDefinitions.ts create mode 100644 app/taro/src/utils/canvasStructureHelpers.ts create mode 100644 app/taro/src/utils/generators.tsx create mode 100644 app/taro/src/utils/helpers.tsx create mode 100644 app/taro/src/utils/hooks/use-ref-state.ts create mode 100644 app/taro/src/utils/hooks/use-set-state.ts create mode 100644 app/taro/src/utils/hooks/use-unmounted-ref.ts create mode 100644 app/taro/src/utils/hooks/useDynamicAppLayout.tsx create mode 100644 app/taro/src/utils/migrations/IncorrectDynamicBindingPathLists.ts create mode 100644 app/taro/src/utils/migrations/TableWidget.ts create mode 100644 app/taro/src/utils/migrations/TextWidgetReplaceTextStyle.ts create mode 100644 app/taro/src/utils/validation/getIsSafeURL.ts create mode 100644 app/taro/src/widgets/BaseWidget.tsx create mode 100644 app/taro/src/widgets/CanvasWidget.tsx create mode 100644 app/taro/src/widgets/ContainerWidget.tsx create mode 100644 app/taro/src/widgets/FileDataTypes.ts create mode 100644 app/taro/src/widgets/MetaHOC.tsx create mode 100644 app/taro/src/widgets/SkeletonWidget.tsx create mode 100644 app/taro/src/widgets/taro/ActionBarWidget.tsx create mode 100644 app/taro/src/widgets/taro/BottomBarWidget.tsx create mode 100644 app/taro/src/widgets/taro/ButtonWidget.tsx create mode 100644 app/taro/src/widgets/taro/CellWidget.tsx create mode 100644 app/taro/src/widgets/taro/CheckboxWidget.tsx create mode 100644 app/taro/src/widgets/taro/FormWidget.tsx create mode 100644 app/taro/src/widgets/taro/GridWidget.tsx create mode 100644 app/taro/src/widgets/taro/HtmlWidget.tsx create mode 100644 app/taro/src/widgets/taro/ImageWidget.tsx create mode 100644 app/taro/src/widgets/taro/KVWidget.tsx create mode 100644 app/taro/src/widgets/taro/ListWidget.tsx create mode 100644 app/taro/src/widgets/taro/LoadingWidget.tsx create mode 100644 app/taro/src/widgets/taro/LoadingWrapper.tsx create mode 100644 app/taro/src/widgets/taro/PickerWidget.tsx create mode 100644 app/taro/src/widgets/taro/PopupWidget.tsx create mode 100644 app/taro/src/widgets/taro/SearchWidget.tsx create mode 100644 app/taro/src/widgets/taro/SkuWidget.tsx create mode 100644 app/taro/src/widgets/taro/SwiperWidget.tsx create mode 100644 app/taro/src/widgets/taro/TabsWidget.tsx create mode 100644 app/taro/src/widgets/taro/TextWidget.tsx create mode 100644 app/taro/src/worker/worker.js create mode 100644 app/taro/src/workers/DataTreeEvaluator.ts create mode 100644 app/taro/src/workers/ast.ts create mode 100644 app/taro/src/workers/evaluate.ts create mode 100644 app/taro/src/workers/evaluation.worker.ts create mode 100644 app/taro/src/workers/evaluationSubstitution.ts create mode 100644 app/taro/src/workers/evaluationUtils.ts create mode 100644 app/taro/src/workers/validations.ts create mode 100644 app/taro/tsconfig.json create mode 100644 app/taro/yarn.lock delete mode 100644 cloudos_deploy/Dockerfile delete mode 100644 cloudos_deploy/html/favicon.ico delete mode 100644 cloudos_deploy/html/index.html delete mode 100644 cloudos_deploy/start-nginx.sh delete mode 100644 cloudos_deploy/templates/nginx-app.conf.template delete mode 100644 cloudos_deploy/templates/nginx-root.conf.template diff --git a/app/client/public/Methodot_favicon.ico b/app/client/public/Methodot_favicon.ico deleted file mode 100644 index 09995ddacf279abe102c2138467c6825e27f55d8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23462 zcmeI4O-vkR7{`aAqV@w#wANGw+s0O5mnw&9(nw<(P1&8Q2jW4~=%oiQc;m==ve86^ zva`_LrP`Pt)`KS1gVqR1i6Wh~(iFA9+Kuck^h^6?3oS7IpLb@KVY=+j?9LZOn%VjD z&il^$JimQEpBc(=75EnjaQLj{K7O6!R&yM;2?vrm0SBeiPx>{ETkn?-mf*1uDHOUR z8x`Kj#Drt%Sh)L4udvQzCc18p*wb@oIv(ByMkjGdnqwvt7Y>16qw7YxY`{n&aThVl z#)LmKe6*}oJxk2e@$TnbHres&Ck}kDJR1wQW}-s62qTr1_B@b@g?Yz~cDTZ`;qVG# zgm#oIfsvLM>0{I;r9`6AVK;28?!srCtKeH3jtdqr(la~3m|(u80ndvrZzj4`0yT^-Lmxd6OqVju-Sv-Uk4b?XBHRE(D!qC|3~*(>XgMd%f`BD zGVyQ+#_Vg3Gn&8FAbyv~mb3fAYb14>Hm-n_{-cg^gvpZL0WKRPZZ|rWXMtJu^r40-0FkX{?PB;4`}j z8R?lx7*`Kly%)&F!&_;Oaa-`Ybq*kgY%d^5QiZ7wrpe40#UkI`#*FlB&GcR%(<^L8 zUmILPjP%S#5!={J@efVY$w|bHmeHORe8eTpNY5;#-wULp!n0U|{PsVid9kw`w`^Q^ zM{QK3J;rGUW57kP*yKf4j1Sh>6gwX6?5tvOz-Z*S+sr)0DjG@BScv28iS8NuG_tl3mqORh#p5ff9Xd51 zxxi`wd&m}gu2qPGnQLsFgLbLxDQw$!ImGI6Ixh5#?ceJ&!=RMB;I&bS3t1jtw3*ci z*0pa_Un#}!a>}r{bxg=uIiA_TYKHdhwDvD&4_XcW73ZlALj zugNT6CDL5v#pfm&tk+!cgY20@IG*k8ddBUxQ>cEdORS2KT&MVNdSBNQYJJqk3VjdA ze+t*zXxvoGc=-%lj}-E!=rwwG0ME_FdpjT0`?&xsHdeDW(IR^ej&{{ol*g^{QA7Uf zSY4tu(Rgq7Q+lS0<#)`*-x_A6%uV#%&WL}E72;PE*P?e=jFjV3i z?PLv3Uo5~1&!UAcdah|_{fp_|*?8phd937^Z=2WOad3liCLTEmR;FVe7mOV$UT6#c;t99Kkt;NU{}mTLOwh8dhlsg*u z#8PFV_gk#rvHqw(_&(U2%kj~&@&~@ums!le_tkE@+l>7Z7g~1I7uYVM&4ABzenv{$ z^6_7pxwjYdj?}f>rRg)RMr<6c-}w;Av|$W7U67BqUHO9F7`e9>^N5WvJuLeh98>*G z`UAOVsrhV9`T~td8~7gNzpj=se&)Z=cTX>;k-r#s4~TyLhThM7tOhpjT!}Kfk#|_1 z-{kK{yv#+lZO&i*cp?9^tS}C(1EX%_$9%7u&q~((plXj7&$PZtHU#&IzThPz{%To~ zHd4k!9?@%za&wbEcnE&Xn(#%knbojYSPlDMU2S@9()A~sS^erZE6v<=%}g80m)B-i z>A@{KRyoa!){IGC@GbZ&=JUDKG@Dt`e&;f+IcOZUo7pc7!L`^&giz-K`-t-9D+gGq z`@BV2Iy}ruW#*Oh zpNQFQRmTX#wN`*>D~|L+Y?omADK_6WHs<|16N&|5O}7hNXm0n)_v*AACx}7cwrz&q zYo$Fo%|GCkTtdu-i4o1cYJW3xrnRxc?8n=c8TkA_K3ch_pz#g7DE8xYpRlREzyL8a z({{|}9opQy8Fe5oUF2DgXPFWs{spssmy>^}fv;1T*}8AFs2$UqAAO>EOF2H5TlU!I zS88DgJ)18(re+ZrZJ%X(D2n@)>!+3FDOQVd5-}vUFV@=YhMu8kzD~r>%3(+`6J;-V z-iCHkggbwO#)Y36nse_Bm*b05WrzJQE(a^x3*?^P+Q@E-Vz5K?FF)#(e|FTP*$ez` z11pMUbx;i14%^+jr)Do;#dCwp#E4=yZu#R>y%gJ{^>PXA>^#jM$9;kOowC&{^=S42 z#bTak*&K`aE4^a7TXq!K3rw&%wTx#OZuw+)y~(Y0aDW+$+>YSeBDsviF+toZFj;m4hEKIFZ^dxkJqLG~n;Do!Au3?(8Q-KuH zDLWM)je~yLQ_vw&99NyBN$B3br-LntXYeB+_f3-%~W%)F { defineCustomElements(window); }); // create taro runtime in React -import { createRouter } from "@tarojs/taro"; import { createReactApp } from "@tarojs/runtime"; class Empty extends React.Component { render() { @@ -49,18 +48,7 @@ class Empty extends React.Component { } } const inst = createReactApp(Empty, React, ReactDOM, {}); -// createRouter( -// inst, -// { -// routes: [], -// router: { -// mode: "browser", -// basename: "", -// pathname: "", -// }, -// }, -// "react", -// ); + // add touch emulator import "@vant/touch-emulator"; import "react-sortable-tree-patch-react-17/style.css"; diff --git a/app/server/.env b/app/server/.env deleted file mode 100644 index e62690de91..0000000000 --- a/app/server/.env +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh - -APPSMITH_MONGODB_URI="mongodb://10.10.13.50:27017/appsmith" - -APPSMITH_REDIS_URL="redis://10.10.13.50:63799" - -CLOUDOS_WECHAT_APPID="wx414ad0dbeda1a70b" -CLOUDOS_WECHAT_SECRET="d5289fd08b1fb31290f66ea2ce5ec7dc" - -APPSMITH_MAIL_ENABLED=false - -APPSMITH_ENCRYPTION_PASSWORD=abcd -APPSMITH_ENCRYPTION_SALT=abcd - -APPSMITH_CODEC_SIZE=10 - -#APPSMITH_CLOUD_SERVICES_BASE_URL="https://release-cs.appsmith.com" - -#APPSMITH_OAUTH2_GOOGLE_CLIENT_ID="" -#APPSMITH_OAUTH2_GOOGLE_CLIENT_SECRET="" - -#APPSMITH_OAUTH2_GITHUB_CLIENT_ID="" -#APPSMITH_OAUTH2_GITHUB_CLIENT_SECRET="" - -#APPSMITH_SENTRY_DSN= -#APPSMITH_SENTRY_ENVIRONMENT= - -#APPSMITH_RECAPTCHA_SITE_KEY="" -#APPSMITH_RECAPTCHA_SECRET_KEY="" diff --git a/app/server/.gitignore b/app/server/.gitignore index c8fe890a94..efc8776c80 100644 --- a/app/server/.gitignore +++ b/app/server/.gitignore @@ -12,5 +12,5 @@ node_modules **/.project **/.factorypath container-volumes -!.env +*.env dependency-reduced-pom.xml diff --git a/app/taro/.editorconfig b/app/taro/.editorconfig new file mode 100644 index 0000000000..5760be5836 --- /dev/null +++ b/app/taro/.editorconfig @@ -0,0 +1,12 @@ +# http://editorconfig.org +root = true + +[*] +indent_style = space +indent_size = 2 +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + +[*.md] +trim_trailing_whitespace = false diff --git a/app/taro/.eslintrc.js b/app/taro/.eslintrc.js new file mode 100644 index 0000000000..ca21b2a342 --- /dev/null +++ b/app/taro/.eslintrc.js @@ -0,0 +1,7 @@ +module.exports = { + "extends": ["taro/react"], + "rules": { + "react/jsx-uses-react": "off", + "react/react-in-jsx-scope": "off" + } +} diff --git a/app/taro/.gitignore b/app/taro/.gitignore new file mode 100644 index 0000000000..3dbf1fc0c6 --- /dev/null +++ b/app/taro/.gitignore @@ -0,0 +1,7 @@ +dist/ +deploy_versions/ +.temp/ +.rn_temp/ +node_modules/ +.DS_Store +.linaria-cache/ diff --git a/app/taro/README.md b/app/taro/README.md new file mode 100644 index 0000000000..c8e39d436c --- /dev/null +++ b/app/taro/README.md @@ -0,0 +1 @@ +# taro viewer for PagePlug 💖 diff --git a/app/taro/babel.config.js b/app/taro/babel.config.js new file mode 100644 index 0000000000..9978326729 --- /dev/null +++ b/app/taro/babel.config.js @@ -0,0 +1,32 @@ +// babel-preset-taro 更多选项和默认值: +// https://github.com/NervJS/taro/blob/next/packages/babel-preset-taro/README.md +module.exports = { + presets: [ + ['taro', { + framework: 'react', + ts: true + }], + 'linaria/babel' + ], + plugins: [ + [ + "import", + { + libraryName: "@taroify/core", + libraryDirectory: "", + style: true, + }, + "@taroify/core", + ], + [ + "import", + { + libraryName: "@taroify/icons", + libraryDirectory: "", + camel2DashComponentName: false, + style: () => "@taroify/icons/style", + }, + "@taroify/icons", + ], + ], +} diff --git a/app/taro/config/dev.js b/app/taro/config/dev.js new file mode 100644 index 0000000000..933c4f4811 --- /dev/null +++ b/app/taro/config/dev.js @@ -0,0 +1,141 @@ +// eslint-disable-next-line import/no-commonjs +const TerserPlugin = require("terser-webpack-plugin"); +const pxtransform = require("./postcss.pxtransform"); + +const transformEditorSize = (rule) => { + rule.oneOf('0').use('2').tap(options => ({ + ...options, + postcssOptions: { + plugins: [ + // transform PagePlug component px(based on 450) to weapp unit rpx(based on 750) + pxtransform(), + ...options.postcssOptions.plugins, + ] + } + })); +} + +module.exports = { + env: { + NODE_ENV: '"development"', + REACT_APP_CLIENT_LOG_LEVEL: '"error"', // debug or error + }, + defineConstants: { + // PagePlug 接口地址 + API_BASE_URL: '""', + // 默认应用ID + DEFAULT_APP: '""', + }, + mini: { + webpackChain(chain, webpack) { + // add postcss plugin + transformEditorSize(chain.module.rule("less")); + transformEditorSize(chain.module.rule("nomorlCss")); + + // lodash bundle reduction + // `shorthands`, `coercions`, `paths` are necessary to avoid some weird things + chain.plugin("lodash-webpack-plugin").use(require("lodash-webpack-plugin"), [ + { + shorthands: true, + cloning: true, + caching: true, + collections: true, + exotics: true, + guards: true, + memoizing: true, + coercions: true, + flattening: true, + paths: true, + }, + ]) + + chain.merge({ + resolve: { + modules: [ + './src', + ], + }, + optimization: { + splitChunks: { + // `all` or `initial`, `all` will have the smallest overall size, refer to + // https://stackoverflow.com/questions/50127185/webpack-what-is-the-difference-between-all-and-initial-options-in-optimizat + chunks: "all", + cacheGroups: { + lodash: { + name: "lodash", + priority: 100, + test(module) { + return /node_modules[\\/]lodash/.test(module.context) + }, + }, + taroify: { + name: "taroify", + test(module) { + if (/package[\\/](core|icons|hooks)/.test(module.resource)) { + return true + } + if (/bundles[\\/](core|icons|hooks)/.test(module.resource)) { + return true + } + return /node_modules[\\/]@taroify/.test(module.resource) + }, + // + // test: /node_modules[\\/]@taroify/, + // just higher than 10 will be fine, refer to + // https://github.com/NervJS/taro/blob/bc6af68bda2cbc9163fbda36c15878fc96aec8f1/packages/taro-mini-runner/src/webpack/build.conf.ts#L220-L254 + priority: 100, + }, + }, + }, + // turn on below `minimize`, `minimizer` settings if bundle size is way too large + // to do remote debug in wechatdevtools + minimize: true, + minimizer: [ + new TerserPlugin({ + // add those `bundle`s your want to do size reduction + // refer to https://webpack.js.org/plugins/terser-webpack-plugin/#test + test: ["common.js", "taro.js", "vendors.js", "lodash.js", "taroify.js", "app.js", "pages/index/index.js"], + parallel: true, + // minify: TerserPlugin.swcMinify, + cache: true, + // remove comments + terserOptions: { + output: { + comments: false, + }, + }, + extractComments: false, + // should work with `mini.sourceMapType='source-map'` + // refer to https://webpack.js.org/plugins/terser-webpack-plugin/#note-about-source-maps + sourceMap: true, + }), + ], + }, + }) + // enable webpack-bundle-analyzer + // if you would like to do some bundle reduction stuff + // chain.plugin("analyzer") + // .use(require("webpack-bundle-analyzer").BundleAnalyzerPlugin, [{ + // analyzerPort: "auto", + // generateStatsFile: true, + // }]) + + chain.module + .rule('script') + .use('linariaLoader') + .loader('linaria/loader') + .options({ + sourceMap: true, + }); + }, + commonChunks(commonChunks) { + commonChunks.push("lodash") + commonChunks.push("taroify") + return commonChunks + }, + // turn to source-map if TerserPlugin is on + // refer to http://taro-docs.jd.com/taro/docs/config-detail/#minisourcemaptype + sourceMapType: "source-map", + }, + h5: {} +} diff --git a/app/taro/config/index.js b/app/taro/config/index.js new file mode 100644 index 0000000000..81f0ae63fa --- /dev/null +++ b/app/taro/config/index.js @@ -0,0 +1,128 @@ +const pxtransform = require("./postcss.pxtransform"); + +const transformEditorSize = (rule) => { + rule.oneOf('0').use('2').tap(options => ({ + ...options, + postcssOptions: { + plugins: [ + // transform PagePlug component px(based on 450) to weapp unit rpx(based on 750) + pxtransform(), + ...options.postcssOptions.plugins, + ] + } + })); +} + +const config = { + projectName: 'b_d_m', + date: '2021-11-8', + designWidth: 750, + deviceRatio: { + 640: 2.34 / 2, + 750: 1, + 828: 1.81 / 2 + }, + sourceRoot: 'src', + outputRoot: 'dist', + plugins: [ + '@tarojs/plugin-html', + '@tarojs/plugin-sass', + ], + defineConstants: { + // PagePlug 接口地址 + API_BASE_URL: '""', + // 默认应用ID + DEFAULT_APP: '""', + // 默认空内容图片地址 + EMPTY_IMAGE_URL: '"https://img.icons8.com/stickers/344/aquarium.png"', + }, + copy: { + patterns: [ + { from: 'src/worker/', to: 'dist/worker/' }, + ], + options: { + } + }, + framework: 'react', + mini: { + postcss: { + pxtransform: { + enable: true, + config: {}, + }, + url: { + enable: true, + config: { + limit: 1024 // 设定转换尺寸上限 + } + }, + cssModules: { + enable: false, // 默认为 false,如需使用 css modules 功能,则设为 true + config: { + namingPattern: 'module', // 转换模式,取值为 global/module + generateScopedName: '[name]__[local]___[hash:base64:5]' + } + } + }, + webpackChain(chain, webpack) { + // add postcss plugin + transformEditorSize(chain.module.rule("less")); + transformEditorSize(chain.module.rule("nomorlCss")); + chain.merge({ + resolve: { + modules: [ + './src', + ], + } + }); + chain.module + .rule('script') + .use('linariaLoader') + .loader('linaria/loader') + .options({ + sourceMap: process.env.NODE_ENV !== 'production', + }); + } + }, + h5: { + publicPath: '/', + staticDirectory: 'static', + postcss: { + autoprefixer: { + enable: true, + config: { + } + }, + cssModules: { + enable: false, // 默认为 false,如需使用 css modules 功能,则设为 true + config: { + namingPattern: 'module', // 转换模式,取值为 global/module + generateScopedName: '[name]__[local]___[hash:base64:5]' + } + } + }, + webpackChain(chain, webpack) { + chain.merge({ + resolve: { + modules: [ + './src', + ], + } + }); + chain.module + .rule('script') + .use('linariaLoader') + .loader('linaria/loader') + .options({ + sourceMap: process.env.NODE_ENV !== 'production', + }); + } + } +} + +module.exports = function (merge) { + if (process.env.NODE_ENV === 'development') { + return merge({}, config, require('./dev')) + } + return merge({}, config, require('./prod')) +} diff --git a/app/taro/config/postcss.pxtransform.js b/app/taro/config/postcss.pxtransform.js new file mode 100644 index 0000000000..a764fcde91 --- /dev/null +++ b/app/taro/config/postcss.pxtransform.js @@ -0,0 +1,339 @@ +'use strict' + +const postcss = require('postcss') +const objectAssign = require('object-assign') +const pxRegex = /"[^"]+"|'[^']+'|url\([^\)]+\)|(\d*\.?\d+)px/g +/*eslint-disable*/ +const filterPropList = { + exact: function (list) { + return list.filter(function (m) { + return m.match(/^[^\*\!]+$/) + }) + }, + contain: function (list) { + return list.filter(function (m) { + return m.match(/^\*.+\*$/) + }).map(function (m) { + return m.substr(1, m.length - 2) + }) + }, + endWith: function (list) { + return list.filter(function (m) { + return m.match(/^\*[^\*]+$/) + }).map(function (m) { + return m.substr(1) + }) + }, + startWith: function (list) { + return list.filter(function (m) { + return m.match(/^[^\*\!]+\*$/) + }).map(function (m) { + return m.substr(0, m.length - 1) + }) + }, + notExact: function (list) { + return list.filter(function (m) { + return m.match(/^\![^\*].*$/) + }).map(function (m) { + return m.substr(1) + }) + }, + notContain: function (list) { + return list.filter(function (m) { + return m.match(/^\!\*.+\*$/) + }).map(function (m) { + return m.substr(2, m.length - 3) + }) + }, + notEndWith: function (list) { + return list.filter(function (m) { + return m.match(/^\!\*[^\*]+$/) + }).map(function (m) { + return m.substr(2) + }) + }, + notStartWith: function (list) { + return list.filter(function (m) { + return m.match(/^\![^\*]+\*$/) + }).map(function (m) { + return m.substr(1, m.length - 2) + }) + } +} + +const defaults = { + rootValue: 16, + unitPrecision: 5, + selectorBlackList: [], + propList: ['*'], + replace: true, + mediaQuery: false, + minPixelValue: 0 +} + +const legacyOptions = { + root_value: 'rootValue', + unit_precision: 'unitPrecision', + selector_black_list: 'selectorBlackList', + prop_white_list: 'propList', + media_query: 'mediaQuery', + propWhiteList: 'propList' +} + +const deviceRatio = { + 640: 2.34 / 2, + 750: 1, + 828: 1.81 / 2 +} + +// transform factor for fixed-width container +// (w / 320) * 20 * (pixels / rootValue) === (pixels / newRootValue) * 16 (default html font-size) +// so, newRootValue = (16 * 16 / w) * rootValue +const factor = 16 * 16 + +const baseFontSize = 40 + +const DEFAULT_WEAPP_OPTIONS = { + platform: 'weapp', + designWidth: 750, + deviceRatio, + h5Width: 450, +} + +let targetUnit + +module.exports = postcss.plugin('postcss-editorto', function (options) { + options = Object.assign(DEFAULT_WEAPP_OPTIONS, options || {}) + + switch (options.platform) { + case 'weapp': { + // pc editor px (450 based) => weapp rpx (750 based) + options.rootValue = (options.h5Width / options.designWidth) * (1 / options.deviceRatio[options.designWidth]) + targetUnit = 'rpx' + break + } + case 'h5': { + options.rootValue = (baseFontSize * options.designWidth / 640) * (factor / options.h5Width) + targetUnit = 'rem' + break + } + case 'rn': { + options.rootValue = options.deviceRatio[options.designWidth] * 2 + targetUnit = 'px' + break + } + } + + convertLegacyOptions(options) + + const opts = objectAssign({}, defaults, options) + const onePxTransform = typeof options.onePxTransform === 'undefined' ? true : options.onePxTransform + const pxReplace = createPxReplace(opts.rootValue, opts.unitPrecision, + opts.minPixelValue, onePxTransform) + + const satisfyPropList = createPropListMatcher(opts.propList) + + return function (css) { + const filePath = css.source.input.file; + + for (let i = 0; i < css.nodes.length; i++) { + if (css.nodes[i].type === 'comment') { + if (css.nodes[i].text === 'postcss-pxtransform disable') { + return + } else { + break + } + } + } + + // delete code between comment in RN + if (options.platform === 'rn') { + css.walkComments(comment => { + if (comment.text === 'postcss-pxtransform rn eject enable') { + let next = comment.next() + while (next) { + if (next.type === 'comment' && next.text === 'postcss-pxtransform rn eject disable') { + break + } + const temp = next.next() + next.remove() + next = temp + } + } + }) + } + + /* #ifdef %PLATFORM% */ + // 平台特有样式 + /* #endif */ + css.walkComments(comment => { + const wordList = comment.text.split(' ') + // 指定平台保留 + if (wordList.indexOf('#ifdef') > -1) { + // 非指定平台 + if (wordList.indexOf(options.platform) === -1) { + let next = comment.next() + while (next) { + if (next.type === 'comment' && next.text.trim() === '#endif') { + break + } + const temp = next.next() + next.remove() + next = temp + } + } + } + }) + + /* #ifndef %PLATFORM% */ + // 平台特有样式 + /* #endif */ + css.walkComments(comment => { + const wordList = comment.text.split(' ') + // 指定平台剔除 + if (wordList.indexOf('#ifndef') > -1) { + // 指定平台 + if (wordList.indexOf(options.platform) > -1) { + let next = comment.next() + while (next) { + if (next.type === 'comment' && next.text.trim() === '#endif') { + break + } + const temp = next.next() + next.remove() + next = temp + } + } + } + }) + + css.walkDecls(function (decl, i) { + // This should be the fastest test and will remove most declarations + if (decl.value.indexOf('px') === -1) return + + if (!satisfyPropList(decl.prop)) return + + if (blacklistedSelector(opts.selectorBlackList, + decl.parent.selector)) return + + const value = decl.value.replace(pxRegex, pxReplace) + + // if rem unit already exists, do not add or replace + if (declarationExists(decl.parent, decl.prop, value)) return + + if (opts.replace) { + decl.value = value + } else { + decl.parent.insertAfter(i, decl.clone({ value: value })) + } + }) + + if (opts.mediaQuery) { + css.walkAtRules('media', function (rule) { + if (rule.params.indexOf('px') === -1) return + rule.params = rule.params.replace(pxRegex, pxReplace) + }) + } + } +}) + +function convertLegacyOptions (options) { + if (typeof options !== 'object') return + if ( + ( + (typeof options.prop_white_list !== 'undefined' && + options.prop_white_list.length === 0) || + (typeof options.propWhiteList !== 'undefined' && + options.propWhiteList.length === 0) + ) && + typeof options.propList === 'undefined' + ) { + options.propList = ['*'] + delete options.prop_white_list + delete options.propWhiteList + } + Object.keys(legacyOptions).forEach(function (key) { + if (options.hasOwnProperty(key)) { + options[legacyOptions[key]] = options[key] + delete options[key] + } + }) +} + +function createPxReplace (rootValue, unitPrecision, minPixelValue, onePxTransform) { + return function (m, $1) { + if (!$1) return m + if (!onePxTransform && parseInt($1, 10) === 1) { + return m + } + const pixels = parseFloat($1) + if (pixels < minPixelValue) return m + const fixedVal = toFixed((pixels / rootValue), unitPrecision) + return (fixedVal === 0) ? '0' : fixedVal + targetUnit + } +} + +function toFixed (number, precision) { + const multiplier = Math.pow(10, precision + 1) + const wholeNumber = Math.floor(number * multiplier) + return Math.round(wholeNumber / 10) * 10 / multiplier +} + +function declarationExists (decls, prop, value) { + return decls.some(function (decl) { + return (decl.prop === prop && decl.value === value) + }) +} + +function blacklistedSelector (blacklist, selector) { + if (typeof selector !== 'string') return + return blacklist.some(function (regex) { + if (typeof regex === 'string') return selector.indexOf(regex) !== -1 + return selector.match(regex) + }) +} + +function createPropListMatcher (propList) { + const hasWild = propList.indexOf('*') > -1 + const matchAll = (hasWild && propList.length === 1) + const lists = { + exact: filterPropList.exact(propList), + contain: filterPropList.contain(propList), + startWith: filterPropList.startWith(propList), + endWith: filterPropList.endWith(propList), + notExact: filterPropList.notExact(propList), + notContain: filterPropList.notContain(propList), + notStartWith: filterPropList.notStartWith(propList), + notEndWith: filterPropList.notEndWith(propList) + } + return function (prop) { + if (matchAll) return true + return ( + ( + hasWild || + lists.exact.indexOf(prop) > -1 || + lists.contain.some(function (m) { + return prop.indexOf(m) > -1 + }) || + lists.startWith.some(function (m) { + return prop.indexOf(m) === 0 + }) || + lists.endWith.some(function (m) { + return prop.indexOf(m) === prop.length - m.length + }) + ) && + !( + lists.notExact.indexOf(prop) > -1 || + lists.notContain.some(function (m) { + return prop.indexOf(m) > -1 + }) || + lists.notStartWith.some(function (m) { + return prop.indexOf(m) === 0 + }) || + lists.notEndWith.some(function (m) { + return prop.indexOf(m) === prop.length - m.length + }) + ) + ) + } +} diff --git a/app/taro/config/prod.js b/app/taro/config/prod.js new file mode 100644 index 0000000000..88f98ecb97 --- /dev/null +++ b/app/taro/config/prod.js @@ -0,0 +1,22 @@ +module.exports = { + env: { + NODE_ENV: '"production"', + }, + defineConstants: { + // PagePlug 接口地址 + API_BASE_URL: '""', + // 默认应用ID + DEFAULT_APP: '""', + }, + mini: {}, + h5: { + /** + * 如果h5端编译后体积过大,可以使用webpack-bundle-analyzer插件对打包体积进行分析。 + * 参考代码如下: + * webpackChain (chain) { + * chain.plugin('analyzer') + * .use(require('webpack-bundle-analyzer').BundleAnalyzerPlugin, []) + * } + */ + } +} diff --git a/app/taro/global.d.ts b/app/taro/global.d.ts new file mode 100644 index 0000000000..97b3d3e083 --- /dev/null +++ b/app/taro/global.d.ts @@ -0,0 +1,18 @@ +declare module "*.png"; +declare module "*.gif"; +declare module "*.jpg"; +declare module "*.jpeg"; +declare module "*.svg"; +declare module "*.css"; +declare module "*.less"; +declare module "*.scss"; +declare module "*.sass"; +declare module "*.styl"; + +// @ts-ignore +declare const process: { + env: { + TARO_ENV: 'weapp' | 'swan' | 'alipay' | 'h5' | 'rn' | 'tt' | 'quickapp' | 'qq' | 'jd'; + [key: string]: any; + } +} diff --git a/app/taro/linaria.config.js b/app/taro/linaria.config.js new file mode 100644 index 0000000000..7e13a50134 --- /dev/null +++ b/app/taro/linaria.config.js @@ -0,0 +1,12 @@ +// linaria 配置详见 https://github.com/callstack/linaria/blob/master/docs/CONFIGURATION.md#options +module.exports = { + rules: [ + { + action: require("linaria/evaluators").shaker, + }, + { + test: /node_modules[\/\\](?!@tarojs|@taroify)/, + action: "ignore" + } + ] +} \ No newline at end of file diff --git a/app/taro/package.json b/app/taro/package.json new file mode 100644 index 0000000000..aba15ae015 --- /dev/null +++ b/app/taro/package.json @@ -0,0 +1,110 @@ +{ + "name": "b_d_m", + "version": "1.0.0", + "private": true, + "description": "PagePlug 跨端展示", + "templateInfo": { + "name": "redux", + "typescript": true, + "css": "less" + }, + "scripts": { + "build:weapp": "taro build --type weapp", + "build:swan": "taro build --type swan", + "build:alipay": "taro build --type alipay", + "build:tt": "taro build --type tt", + "build:h5": "taro build --type h5", + "build:rn": "taro build --type rn", + "build:qq": "taro build --type qq", + "build:jd": "taro build --type jd", + "build:quickapp": "taro build --type quickapp", + "dev:weapp": "npm run build:weapp -- --watch", + "dev:swan": "npm run build:swan -- --watch", + "dev:alipay": "npm run build:alipay -- --watch", + "dev:tt": "npm run build:tt -- --watch", + "dev:h5": "npm run build:h5 -- --watch", + "dev:rn": "npm run build:rn -- --watch", + "dev:qq": "npm run build:qq -- --watch", + "dev:jd": "npm run build:jd -- --watch", + "dev:quickapp": "npm run build:quickapp -- --watch" + }, + "browserslist": [ + "last 3 versions", + "Android >= 4.1", + "ios >= 8" + ], + "author": "", + "license": "MIT", + "dependencies": { + "@babel/runtime": "^7.7.7", + "@manaflair/redux-batch": "^1.0.0", + "@taroify/core": "0.0.28-alpha.1", + "@tarojs/components": "3.3.12", + "@tarojs/plugin-html": "3.3.12", + "@tarojs/react": "3.3.12", + "@tarojs/runtime": "3.3.12", + "@tarojs/taro": "3.3.12", + "@types/deep-diff": "^1.0.1", + "@types/downloadjs": "^1.4.2", + "@types/jshint": "^2.12.1", + "@types/nanoid": "^3.0.0", + "@types/toposort": "^2.0.3", + "astring": "^1.7.5", + "clsx": "^1.1.1", + "copy-to-clipboard": "^3.3.1", + "dayjs": "^1.10.7", + "deep-diff": "^1.0.2", + "downloadjs": "^1.4.7", + "eval5": "^1.4.7", + "fast-deep-equal": "^3.1.3", + "fast-xml-parser": "^3.21.1", + "fuse.js": "^6.4.6", + "immer": "^9.0.6", + "jshint": "^2.13.1", + "linaria": "^3.0.0-beta.17", + "lodash": "^4.17.21", + "loglevel": "^1.7.1", + "nanoid": "^3.1.30", + "node-forge": "^0.10.0", + "normalizr": "^3.6.1", + "path-to-regexp": "^6.2.0", + "react": "^17.0.0", + "react-dom": "^17.0.0", + "react-redux": "^7.2.0", + "redux": "^4.0.0", + "redux-form": "^8.3.7", + "redux-logger": "^3.0.6", + "redux-saga": "^1.1.3", + "reselect": "^4.1.2", + "shallowequal": "^1.1.0", + "taro-axios": "^1.1.1", + "tinycolor2": "^1.4.2", + "toposort": "^2.0.2", + "unescape-js": "^1.1.4", + "url-search-params-polyfill": "^8.1.1", + "worker-loader": "^3.0.8" + }, + "devDependencies": { + "@babel/core": "^7.8.0", + "@tarojs/mini-runner": "3.3.12", + "@tarojs/plugin-sass": "^2.2.10", + "@tarojs/webpack-runner": "3.3.12", + "@types/react": "^17.0.2", + "@types/webpack-env": "^1.13.6", + "@typescript-eslint/eslint-plugin": "^4.15.1", + "@typescript-eslint/parser": "^4.15.1", + "babel-plugin-import": "^1.13.3", + "babel-preset-taro": "3.3.12", + "eslint": "^6.8.0", + "eslint-config-taro": "3.3.12", + "eslint-plugin-import": "^2.12.0", + "eslint-plugin-react": "^7.8.2", + "eslint-plugin-react-hooks": "^4.2.0", + "lodash-webpack-plugin": "^0.11.6", + "redux-devtools-extension": "^2.13.9", + "stylelint": "9.3.0", + "terser-webpack-plugin": "4", + "typescript": "^4.1.0", + "webpack-bundle-analyzer": "^4.5.0" + } +} diff --git a/app/taro/project.config.json b/app/taro/project.config.json new file mode 100644 index 0000000000..743eae91f7 --- /dev/null +++ b/app/taro/project.config.json @@ -0,0 +1,47 @@ +{ + "miniprogramRoot": "dist/", + "projectname": "b_d_m", + "description": "PagePlug 跨端展示", + "appid": "", + "setting": { + "urlCheck": false, + "es6": false, + "enhance": false, + "postcss": false, + "preloadBackgroundData": false, + "minified": true, + "newFeature": false, + "coverView": true, + "nodeModules": false, + "autoAudits": false, + "showShadowRootInWxmlPanel": true, + "scopeDataCheck": false, + "uglifyFileName": false, + "checkInvalidKey": true, + "checkSiteMap": true, + "uploadWithSourceMap": true, + "compileHotReLoad": false, + "lazyloadPlaceholderEnable": false, + "useMultiFrameRuntime": true, + "useApiHook": true, + "useApiHostProcess": true, + "babelSetting": { + "ignore": [], + "disablePlugins": [], + "outputPath": "" + }, + "useIsolateContext": true, + "userConfirmedBundleSwitch": false, + "packNpmManually": false, + "packNpmRelationList": [], + "minifyWXSS": true, + "disableUseStrict": false, + "minifyWXML": true, + "showES6CompileOption": false, + "useCompilerPlugins": false, + "ignoreUploadUnusedFiles": true + }, + "compileType": "miniprogram", + "libVersion": "2.21.0", + "condition": {} +} \ No newline at end of file diff --git a/app/taro/project.private.config.json b/app/taro/project.private.config.json new file mode 100644 index 0000000000..178e7f0562 --- /dev/null +++ b/app/taro/project.private.config.json @@ -0,0 +1,17 @@ +{ + "setting": {}, + "condition": { + "plugin": { + "list": [] + }, + "game": { + "list": [] + }, + "gamePlugin": { + "list": [] + }, + "miniprogram": { + "list": [] + } + } +} \ No newline at end of file diff --git a/app/taro/project.tt.json b/app/taro/project.tt.json new file mode 100644 index 0000000000..6720eb9fd6 --- /dev/null +++ b/app/taro/project.tt.json @@ -0,0 +1,13 @@ +{ + "miniprogramRoot": "./", + "projectname": "b_d_m", + "description": "PagePlug 跨端展示", + "appid": "touristappid", + "setting": { + "urlCheck": true, + "es6": false, + "postcss": false, + "minified": false + }, + "compileType": "miniprogram" +} diff --git a/app/taro/src/actions/actionActions.ts b/app/taro/src/actions/actionActions.ts new file mode 100644 index 0000000000..5617464338 --- /dev/null +++ b/app/taro/src/actions/actionActions.ts @@ -0,0 +1,300 @@ +import { PaginationField, ActionResponse } from "api/ActionAPI"; +import { + ReduxActionTypes, + ReduxAction, + ReduxActionErrorTypes, + EvaluationReduxAction, + ReduxActionWithoutPayload, +} from "constants/ReduxActionConstants"; +import { Action } from "entities/Action"; +import { batchAction } from "actions/batchActions"; + +export const createActionRequest = (payload: Partial) => { + return { + type: ReduxActionTypes.CREATE_ACTION_INIT, + payload, + }; +}; + +export const createActionSuccess = (payload: Action) => { + return { + type: ReduxActionTypes.CREATE_ACTION_SUCCESS, + payload, + }; +}; + +export type FetchActionsPayload = { + applicationId: string; +}; + +export const fetchActions = ( + applicationId: string, + postEvalActions: Array | ReduxActionWithoutPayload>, +): EvaluationReduxAction => { + return { + type: ReduxActionTypes.FETCH_ACTIONS_INIT, + payload: { applicationId }, + postEvalActions, + }; +}; + +export const fetchActionsForView = ( + applicationId: string, +): ReduxAction => { + return { + type: ReduxActionTypes.FETCH_ACTIONS_VIEW_MODE_INIT, + payload: { applicationId }, + }; +}; + +export const fetchActionsForPage = ( + pageId: string, + postEvalActions: Array | ReduxActionWithoutPayload> = [], +): EvaluationReduxAction => { + return { + type: ReduxActionTypes.FETCH_ACTIONS_FOR_PAGE_INIT, + payload: { pageId }, + postEvalActions, + }; +}; + +export const fetchActionsForPageSuccess = ( + actions: Action[], + postEvalActions?: Array | ReduxActionWithoutPayload>, +): EvaluationReduxAction => { + return { + type: ReduxActionTypes.FETCH_ACTIONS_FOR_PAGE_SUCCESS, + payload: actions, + postEvalActions, + }; +}; + +export const setActionTabsInitialIndex = (index: number) => { + return { + type: ReduxActionTypes.SET_ACTION_TABS_INITIAL_INDEX, + payload: index, + }; +}; + +export const runActionViaShortcut = () => { + return { + type: ReduxActionTypes.RUN_ACTION_SHORTCUT_REQUEST, + }; +}; + +export const runAction = (id: string, paginationField?: PaginationField) => { + return { + type: ReduxActionTypes.RUN_ACTION_REQUEST, + payload: { + id, + paginationField, + }, + }; +}; + +export const runActionInit = ( + id: string, + paginationField?: PaginationField, +) => { + return { + type: ReduxActionTypes.RUN_ACTION_INIT, + payload: { + id, + paginationField, + }, + }; +}; + +export const showRunActionConfirmModal = (show: boolean) => { + return { + type: ReduxActionTypes.SHOW_RUN_ACTION_CONFIRM_MODAL, + payload: show, + }; +}; + +export const cancelRunActionConfirmModal = () => { + return { + type: ReduxActionTypes.CANCEL_RUN_ACTION_CONFIRM_MODAL, + }; +}; + +export const acceptRunActionConfirmModal = () => { + return { + type: ReduxActionTypes.ACCEPT_RUN_ACTION_CONFIRM_MODAL, + }; +}; + +export const updateAction = (payload: { id: string }) => { + return batchAction({ + type: ReduxActionTypes.UPDATE_ACTION_INIT, + payload, + }); +}; + +export const updateActionSuccess = (payload: { data: Action }) => { + return { + type: ReduxActionTypes.UPDATE_ACTION_SUCCESS, + payload, + }; +}; + +export const deleteAction = (payload: { + id: string; + name: string; + onSuccess?: () => void; +}) => { + return { + type: ReduxActionTypes.DELETE_ACTION_INIT, + payload, + }; +}; + +export const deleteActionSuccess = (payload: { id: string }) => { + return { + type: ReduxActionTypes.DELETE_ACTION_SUCCESS, + payload, + }; +}; + +export const moveActionRequest = (payload: { + id: string; + destinationPageId: string; + originalPageId: string; + name: string; +}) => { + return { + type: ReduxActionTypes.MOVE_ACTION_INIT, + payload, + }; +}; + +export const moveActionSuccess = (payload: Action) => { + return { + type: ReduxActionTypes.MOVE_ACTION_SUCCESS, + payload, + }; +}; + +export const moveActionError = (payload: { + id: string; + originalPageId: string; +}) => { + return { + type: ReduxActionErrorTypes.MOVE_ACTION_ERROR, + payload, + }; +}; + +export const copyActionRequest = (payload: { + id: string; + destinationPageId: string; + name: string; +}) => { + return { + type: ReduxActionTypes.COPY_ACTION_INIT, + payload, + }; +}; + +export const copyActionSuccess = (payload: Action) => { + return { + type: ReduxActionTypes.COPY_ACTION_SUCCESS, + payload, + }; +}; + +export const copyActionError = (payload: { + id: string; + destinationPageId: string; +}) => { + return { + type: ReduxActionErrorTypes.COPY_ACTION_ERROR, + payload, + }; +}; + +export const executeApiActionRequest = (payload: { id: string }) => ({ + type: ReduxActionTypes.EXECUTE_API_ACTION_REQUEST, + payload: payload, +}); + +export const executeApiActionSuccess = (payload: { + id: string; + response: ActionResponse; + isPageLoad?: boolean; +}) => ({ + type: ReduxActionTypes.EXECUTE_API_ACTION_SUCCESS, + payload: payload, +}); + +export const saveActionName = (payload: { id: string; name: string }) => ({ + type: ReduxActionTypes.SAVE_ACTION_NAME_INIT, + payload: payload, +}); + +export type SetActionPropertyPayload = { + actionId: string; + propertyName: string; + value: any; +}; + +export const setActionProperty = (payload: SetActionPropertyPayload) => ({ + type: ReduxActionTypes.SET_ACTION_PROPERTY, + payload, +}); + +export type UpdateActionPropertyActionPayload = { + id: string; + field: string; + value: any; +}; + +export const updateActionProperty = ( + payload: UpdateActionPropertyActionPayload, +) => { + return batchAction({ + type: ReduxActionTypes.UPDATE_ACTION_PROPERTY, + payload, + }); +}; + +export const executePageLoadActionsComplete = () => { + return { + type: ReduxActionTypes.EXECUTE_PAGE_LOAD_ACTIONS_COMPLETE, + }; +}; + +export const setActionsToExecuteOnPageLoad = ( + actions: Array<{ + executeOnLoad: boolean; + id: string; + name: string; + }>, +) => { + return { + type: ReduxActionTypes.SET_ACTION_TO_EXECUTE_ON_PAGELOAD, + payload: actions, + }; +}; + +export const bindDataOnCanvas = (payload: { + queryId: string; + applicationId: string; + pageId: string; +}) => { + return { + type: ReduxActionTypes.BIND_DATA_ON_CANVAS, + payload, + }; +}; + +export default { + createAction: createActionRequest, + fetchActions, + runAction: runAction, + deleteAction, + deleteActionSuccess, + updateAction, + updateActionSuccess, + bindDataOnCanvas, +}; diff --git a/app/taro/src/actions/apiPaneActions.ts b/app/taro/src/actions/apiPaneActions.ts new file mode 100644 index 0000000000..004b101d46 --- /dev/null +++ b/app/taro/src/actions/apiPaneActions.ts @@ -0,0 +1,81 @@ +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { EventLocation } from "utils/AnalyticsUtil"; +import { ApiContentTypes } from "constants/ApiEditorConstants"; + +export const changeApi = ( + id: string, + isSaas: boolean, + newApi?: boolean, +): ReduxAction<{ id: string; isSaas: boolean; newApi?: boolean }> => { + return { + type: ReduxActionTypes.API_PANE_CHANGE_API, + payload: { id, isSaas, newApi }, + }; +}; + +export const initApiPane = (urlId?: string): ReduxAction<{ id?: string }> => { + return { + type: ReduxActionTypes.INIT_API_PANE, + payload: { id: urlId }, + }; +}; + +export const setCurrentCategory = ( + category: string, +): ReduxAction<{ category: string }> => { + return { + type: ReduxActionTypes.SET_CURRENT_CATEGORY, + payload: { category }, + }; +}; + +export const setLastUsedEditorPage = ( + path: string, +): ReduxAction<{ path: string }> => { + return { + type: ReduxActionTypes.SET_LAST_USED_EDITOR_PAGE, + payload: { path }, + }; +}; + +export const setLastSelectedPage = ( + selectedPageId: string, +): ReduxAction<{ selectedPageId: string }> => { + return { + type: ReduxActionTypes.SET_LAST_SELECTED_PAGE_PAGE, + payload: { selectedPageId }, + }; +}; + +export const createNewApiAction = ( + pageId: string, + from: EventLocation, +): ReduxAction<{ pageId: string; from: EventLocation }> => ({ + type: ReduxActionTypes.CREATE_NEW_API_ACTION, + payload: { pageId, from }, +}); + +export const createNewQueryAction = ( + pageId: string, + from: EventLocation, +): ReduxAction<{ pageId: string; from: EventLocation }> => ({ + type: ReduxActionTypes.CREATE_NEW_QUERY_ACTION, + payload: { pageId, from }, +}); + +export const updateBodyContentType = ( + title: ApiContentTypes, + apiId: string, +): ReduxAction<{ title: ApiContentTypes; apiId: string }> => ({ + type: ReduxActionTypes.UPDATE_API_ACTION_BODY_CONTENT_TYPE, + payload: { title, apiId }, +}); + +export const redirectToNewIntegrations = ( + applicationId: string, + pageId: string, + params?: any, +): ReduxAction<{ applicationId: string; pageId: string; params: any }> => ({ + type: ReduxActionTypes.REDIRECT_TO_NEW_INTEGRATIONS, + payload: { applicationId, pageId, params }, +}); diff --git a/app/taro/src/actions/applicationActions.ts b/app/taro/src/actions/applicationActions.ts new file mode 100644 index 0000000000..7cfac9db1c --- /dev/null +++ b/app/taro/src/actions/applicationActions.ts @@ -0,0 +1,105 @@ +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { APP_MODE } from "entities/App"; +import { + UpdateApplicationPayload, + ImportApplicationRequest, +} from "api/ApplicationApi"; + +export const setDefaultApplicationPageSuccess = ( + pageId: string, + applicationId: string, +) => { + return { + type: ReduxActionTypes.SET_DEFAULT_APPLICATION_PAGE_SUCCESS, + payload: { + pageId, + applicationId, + }, + }; +}; + +export interface FetchApplicationPayload { + applicationId: string; + mode: APP_MODE; +} + +export const fetchApplication = ( + applicationId: string, + mode: APP_MODE, +): ReduxAction => { + return { + type: ReduxActionTypes.FETCH_APPLICATION_INIT, + payload: { + applicationId, + mode, + }, + }; +}; + +export const updateApplicationLayout = ( + id: string, + data: UpdateApplicationPayload, +) => { + return { + type: ReduxActionTypes.UPDATE_APP_LAYOUT, + payload: { + id, + ...data, + }, + }; +}; + +export const updateApplication = ( + id: string, + data: UpdateApplicationPayload, +) => { + return { + type: ReduxActionTypes.UPDATE_APPLICATION, + payload: { + id, + ...data, + }, + }; +}; + +export const publishApplication = (applicationId: string) => { + return { + type: ReduxActionTypes.PUBLISH_APPLICATION_INIT, + payload: { + applicationId, + }, + }; +}; + +export const duplicateApplication = (applicationId: string) => { + return { + type: ReduxActionTypes.DUPLICATE_APPLICATION_INIT, + payload: { + applicationId, + }, + }; +}; + +export const importApplication = (appDetails: ImportApplicationRequest) => { + return { + type: ReduxActionTypes.IMPORT_APPLICATION_INIT, + payload: appDetails, + }; +}; + +export const getAllApplications = () => { + return { + type: ReduxActionTypes.GET_ALL_APPLICATION_INIT, + }; +}; + +export const resetCurrentApplication = () => { + return { + type: ReduxActionTypes.RESET_CURRENT_APPLICATION, + }; +}; + +export const setShowAppInviteUsersDialog = (payload: boolean) => ({ + type: ReduxActionTypes.SET_SHOW_APP_INVITE_USERS_MODAL, + payload, +}); diff --git a/app/taro/src/actions/authActions.ts b/app/taro/src/actions/authActions.ts new file mode 100644 index 0000000000..22d7bb7d5a --- /dev/null +++ b/app/taro/src/actions/authActions.ts @@ -0,0 +1,5 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const getCurrentUser = () => ({ + type: ReduxActionTypes.FETCH_USER_INIT, +}); diff --git a/app/taro/src/actions/batchActions.ts b/app/taro/src/actions/batchActions.ts new file mode 100644 index 0000000000..76c42d6755 --- /dev/null +++ b/app/taro/src/actions/batchActions.ts @@ -0,0 +1,13 @@ +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const batchAction = (action: ReduxAction) => ({ + type: ReduxActionTypes.BATCHED_UPDATE, + payload: action, +}); + +export type BatchAction = ReduxAction>; + +export const batchActionSuccess = (actions: ReduxAction[]) => ({ + type: ReduxActionTypes.BATCH_UPDATES_SUCCESS, + payload: actions, +}); diff --git a/app/taro/src/actions/collectionAction.ts b/app/taro/src/actions/collectionAction.ts new file mode 100644 index 0000000000..9b2bbcd62e --- /dev/null +++ b/app/taro/src/actions/collectionAction.ts @@ -0,0 +1,7 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const fetchImportedCollections = () => { + return { + type: ReduxActionTypes.FETCH_IMPORTED_COLLECTIONS_INIT, + }; +}; diff --git a/app/taro/src/actions/controlActions.tsx b/app/taro/src/actions/controlActions.tsx new file mode 100644 index 0000000000..2880e30ac6 --- /dev/null +++ b/app/taro/src/actions/controlActions.tsx @@ -0,0 +1,95 @@ +import { ReduxActionTypes, ReduxAction } from "constants/ReduxActionConstants"; +import { RenderMode } from "constants/WidgetConstants"; +import { DynamicPath } from "utils/DynamicBindingUtils"; + +export const updateWidgetPropertyRequest = ( + widgetId: string, + propertyPath: string, + propertyValue: any, + renderMode: RenderMode, +): ReduxAction => { + return { + type: ReduxActionTypes.UPDATE_WIDGET_PROPERTY_REQUEST, + payload: { + widgetId, + propertyPath, + propertyValue, + renderMode, + }, + }; +}; + +export interface BatchPropertyUpdatePayload { + modify?: Record; //Key value pairs of paths and values to update + remove?: string[]; //Array of paths to delete + triggerPaths?: string[]; // Array of paths in the modify and remove list which are trigger paths +} + +export const batchUpdateWidgetProperty = ( + widgetId: string, + updates: BatchPropertyUpdatePayload, +): ReduxAction => ({ + type: ReduxActionTypes.BATCH_UPDATE_WIDGET_PROPERTY, + payload: { + widgetId, + updates, + }, +}); + +export const deleteWidgetProperty = ( + widgetId: string, + propertyPaths: string[], +): ReduxAction => ({ + type: ReduxActionTypes.DELETE_WIDGET_PROPERTY, + payload: { + widgetId, + propertyPaths, + }, +}); + +export const setWidgetDynamicProperty = ( + widgetId: string, + propertyPath: string, + isDynamic: boolean, +): ReduxAction => { + return { + type: ReduxActionTypes.SET_WIDGET_DYNAMIC_PROPERTY, + payload: { + widgetId, + propertyPath, + isDynamic, + }, + }; +}; + +export interface UpdateWidgetPropertyRequestPayload { + widgetId: string; + propertyPath: string; + propertyValue: any; + renderMode: RenderMode; +} + +export interface UpdateWidgetPropertyPayload { + widgetId: string; + updates: BatchPropertyUpdatePayload; + dynamicUpdates?: { + dynamicBindingPathList: DynamicPath[]; + dynamicTriggerPathList: DynamicPath[]; + }; +} + +export interface UpdateCanvasLayout { + width: number; + height: number; +} + +export interface SetWidgetDynamicPropertyPayload { + widgetId: string; + propertyPath: string; + isDynamic: boolean; +} + +export interface DeleteWidgetPropertyPayload { + widgetId: string; + propertyPaths: string[]; +} diff --git a/app/taro/src/actions/datasourceActions.ts b/app/taro/src/actions/datasourceActions.ts new file mode 100644 index 0000000000..131a626ec4 --- /dev/null +++ b/app/taro/src/actions/datasourceActions.ts @@ -0,0 +1,239 @@ +import { + ReduxAction, + ReduxActionTypes, + ReduxActionWithCallbacks, +} from "constants/ReduxActionConstants"; +import { CreateDatasourceConfig } from "api/DatasourcesApi"; +import { Datasource } from "entities/Datasource"; +import { PluginType } from "entities/Action"; +import { executeDatasourceQueryRequest } from "../api/DatasourcesApi"; +import { ResponseMeta } from "../api/ApiResponses"; + +export const createDatasourceFromForm = (payload: CreateDatasourceConfig) => { + return { + type: ReduxActionTypes.CREATE_DATASOURCE_FROM_FORM_INIT, + payload, + }; +}; + +export const updateDatasource = ( + payload: Datasource, + onSuccess?: ReduxAction, + onError?: ReduxAction, +): ReduxActionWithCallbacks => { + return { + type: ReduxActionTypes.UPDATE_DATASOURCE_INIT, + payload, + onSuccess, + onError, + }; +}; + +export type UpdateDatasourceSuccessAction = { + type: string; + payload: Datasource; + redirect: boolean; + queryParams?: Record; +}; + +export const updateDatasourceSuccess = ( + payload: Datasource, + redirect = true, + queryParams = {}, +): UpdateDatasourceSuccessAction => ({ + type: ReduxActionTypes.UPDATE_DATASOURCE_SUCCESS, + payload, + redirect, + queryParams, +}); + +export const redirectAuthorizationCode = ( + pageId: string, + datasourceId: string, + pluginType: PluginType, +) => { + return { + type: ReduxActionTypes.REDIRECT_AUTHORIZATION_CODE, + payload: { + pageId, + datasourceId, + pluginType, + }, + }; +}; + +export const fetchDatasourceStructure = (id: string, ignoreCache?: boolean) => { + return { + type: ReduxActionTypes.FETCH_DATASOURCE_STRUCTURE_INIT, + payload: { + id, + ignoreCache, + }, + }; +}; + +export const expandDatasourceEntity = (id: string) => { + return { + type: ReduxActionTypes.EXPAND_DATASOURCE_ENTITY, + payload: id, + }; +}; + +export const refreshDatasourceStructure = (id: string) => { + return { + type: ReduxActionTypes.REFRESH_DATASOURCE_STRUCTURE_INIT, + payload: { + id, + }, + }; +}; + +export const saveDatasourceName = (payload: { id: string; name: string }) => ({ + type: ReduxActionTypes.SAVE_DATASOURCE_NAME, + payload: payload, +}); + +export const changeDatasource = (payload: Datasource) => { + return { + type: ReduxActionTypes.CHANGE_DATASOURCE, + payload, + }; +}; + +export const switchDatasource = (id: string) => { + return { + type: ReduxActionTypes.SWITCH_DATASOURCE, + payload: { datasourceId: id }, + }; +}; + +export const testDatasource = (payload: Partial) => { + return { + type: ReduxActionTypes.TEST_DATASOURCE_INIT, + payload, + }; +}; + +export const deleteDatasource = ( + payload: Partial, + onSuccess?: ReduxAction, + onError?: ReduxAction, + onSuccessCallback?: () => void, +): ReduxActionWithCallbacks, unknown, unknown> => { + return { + type: ReduxActionTypes.DELETE_DATASOURCE_INIT, + payload, + onSuccess, + onError, + onSuccessCallback, + }; +}; + +export const setDatsourceEditorMode = (payload: { + id: string; + viewMode: boolean; +}) => { + return { + type: ReduxActionTypes.SET_DATASOURCE_EDITOR_MODE, + payload, + }; +}; + +export const fetchDatasources = () => { + return { + type: ReduxActionTypes.FETCH_DATASOURCES_INIT, + }; +}; + +export const fetchMockDatasources = () => { + return { + type: ReduxActionTypes.FETCH_MOCK_DATASOURCES_INIT, + }; +}; + +export interface addMockRequest + extends ReduxAction<{ + name: string; + organizationId: string; + pluginId: string; + packageName: string; + isGeneratePageMode?: string; + }> { + extraParams?: any; +} + +export const addMockDatasourceToOrg = ( + name: string, + organizationId: string, + pluginId: string, + packageName: string, + isGeneratePageMode?: string, +): addMockRequest => { + return { + type: ReduxActionTypes.ADD_MOCK_DATASOURCES_INIT, + payload: { name, packageName, pluginId, organizationId }, + extraParams: { isGeneratePageMode }, + }; +}; + +export const initDatasourcePane = ( + pluginType: string, + urlId?: string, +): ReduxAction<{ pluginType: string; id?: string }> => { + return { + type: ReduxActionTypes.INIT_DATASOURCE_PANE, + payload: { id: urlId, pluginType }, + }; +}; + +export const storeAsDatasource = () => { + return { + type: ReduxActionTypes.STORE_AS_DATASOURCE_INIT, + }; +}; + +export const getOAuthAccessToken = (datasourceId: string) => { + return { + type: ReduxActionTypes.SAAS_GET_OAUTH_ACCESS_TOKEN, + payload: { datasourceId }, + }; +}; + +export type executeDatasourceQuerySuccessPayload = { + responseMeta: ResponseMeta; + data: { + body: Array<{ id: string; name: string }>; + headers: Record; + statusCode: string; + isExecutionSuccess: boolean; + }; +}; +type errorPayload = unknown; + +export type executeDatasourceQueryReduxAction = ReduxActionWithCallbacks< + executeDatasourceQueryRequest, + executeDatasourceQuerySuccessPayload, + errorPayload +>; + +export const executeDatasourceQuery = ({ + onErrorCallback, + onSuccessCallback, + payload, +}: { + onErrorCallback?: (payload: errorPayload) => void; + onSuccessCallback?: (payload: executeDatasourceQuerySuccessPayload) => void; + payload: executeDatasourceQueryRequest; +}): executeDatasourceQueryReduxAction => { + return { + type: ReduxActionTypes.EXECUTE_DATASOURCE_QUERY_INIT, + payload, + onErrorCallback, + onSuccessCallback, + }; +}; + +export default { + fetchDatasources, + initDatasourcePane, +}; diff --git a/app/taro/src/actions/debuggerActions.ts b/app/taro/src/actions/debuggerActions.ts new file mode 100644 index 0000000000..ce7beb04cd --- /dev/null +++ b/app/taro/src/actions/debuggerActions.ts @@ -0,0 +1,49 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +import { Message, ENTITY_TYPE } from "entities/AppsmithConsole"; +import { EventName } from "utils/AnalyticsUtil"; + +export interface LogDebuggerErrorAnalyticsPayload { + entityName: string; + entityId: string; + entityType: ENTITY_TYPE; + eventName: EventName; + propertyPath: string; + errorMessages: { message: string }[]; +} + +export const debuggerLogInit = (payload: Message) => ({ + type: ReduxActionTypes.DEBUGGER_LOG_INIT, + payload, +}); + +export const debuggerLog = (payload: Message) => ({ + type: ReduxActionTypes.DEBUGGER_LOG, + payload, +}); + +export const clearLogs = () => ({ + type: ReduxActionTypes.CLEAR_DEBUGGER_LOGS, +}); + +export const showDebugger = (payload?: boolean) => ({ + type: ReduxActionTypes.SHOW_DEBUGGER, + payload, +}); + +export const errorLog = (payload: Message) => ({ + type: ReduxActionTypes.DEBUGGER_ERROR_LOG, + payload, +}); + +export const updateErrorLog = (payload: Message) => ({ + type: ReduxActionTypes.DEBUGGER_UPDATE_ERROR_LOG, + payload, +}); + +// Only used for analytics +export const logDebuggerErrorAnalytics = ( + payload: LogDebuggerErrorAnalyticsPayload, +) => ({ + type: ReduxActionTypes.DEBUGGER_ERROR_ANALYTICS, + payload, +}); diff --git a/app/taro/src/actions/errorActions.ts b/app/taro/src/actions/errorActions.ts new file mode 100644 index 0000000000..0bf6ad9a18 --- /dev/null +++ b/app/taro/src/actions/errorActions.ts @@ -0,0 +1,16 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const flushErrors = () => { + return { + type: ReduxActionTypes.FLUSH_ERRORS, + }; +}; + +export const flushErrorsAndRedirect = (url: string) => { + return { + type: ReduxActionTypes.FLUSH_AND_REDIRECT, + payload: { + url, + }, + }; +}; diff --git a/app/taro/src/actions/evaluationActions.ts b/app/taro/src/actions/evaluationActions.ts new file mode 100644 index 0000000000..c6111d88cc --- /dev/null +++ b/app/taro/src/actions/evaluationActions.ts @@ -0,0 +1,82 @@ +import { + ReduxAction, + ReduxActionErrorTypes, + ReduxActionTypes, +} from "../constants/ReduxActionConstants"; +import _ from "lodash"; +import { DataTree } from "../entities/DataTree/dataTreeFactory"; +import { DependencyMap } from "../utils/DynamicBindingUtils"; +import { Diff } from "deep-diff"; + +export const FIRST_EVAL_REDUX_ACTIONS = [ + // Pages + ReduxActionTypes.FETCH_PAGE_SUCCESS, + ReduxActionTypes.FETCH_PUBLISHED_PAGE_SUCCESS, +]; +export const EVALUATE_REDUX_ACTIONS = [ + ...FIRST_EVAL_REDUX_ACTIONS, + // Actions + ReduxActionTypes.FETCH_ACTIONS_SUCCESS, + ReduxActionTypes.FETCH_PLUGIN_FORM_CONFIGS_SUCCESS, + ReduxActionTypes.FETCH_ACTIONS_VIEW_MODE_SUCCESS, + ReduxActionErrorTypes.FETCH_ACTIONS_ERROR, + ReduxActionErrorTypes.FETCH_ACTIONS_VIEW_MODE_ERROR, + ReduxActionTypes.FETCH_ACTIONS_FOR_PAGE_SUCCESS, + ReduxActionTypes.SUBMIT_CURL_FORM_SUCCESS, + ReduxActionTypes.CREATE_ACTION_SUCCESS, + ReduxActionTypes.UPDATE_ACTION_PROPERTY, + ReduxActionTypes.DELETE_ACTION_SUCCESS, + ReduxActionTypes.COPY_ACTION_SUCCESS, + ReduxActionTypes.MOVE_ACTION_SUCCESS, + ReduxActionTypes.RUN_ACTION_SUCCESS, + ReduxActionErrorTypes.RUN_ACTION_ERROR, + ReduxActionTypes.EXECUTE_API_ACTION_SUCCESS, + ReduxActionErrorTypes.EXECUTE_ACTION_ERROR, + // App Data + ReduxActionTypes.SET_APP_MODE, + ReduxActionTypes.FETCH_USER_DETAILS_SUCCESS, + ReduxActionTypes.UPDATE_APP_PERSISTENT_STORE, + ReduxActionTypes.UPDATE_APP_TRANSIENT_STORE, + // Widgets + ReduxActionTypes.UPDATE_LAYOUT, + ReduxActionTypes.UPDATE_WIDGET_PROPERTY, + ReduxActionTypes.UPDATE_WIDGET_NAME_SUCCESS, + // Widget Meta + ReduxActionTypes.SET_META_PROP, + ReduxActionTypes.RESET_WIDGET_META, + // Batches + ReduxActionTypes.BATCH_UPDATES_SUCCESS, +]; +export const shouldProcessBatchedAction = (action: ReduxAction) => { + if ( + action.type === ReduxActionTypes.BATCH_UPDATES_SUCCESS && + Array.isArray(action.payload) + ) { + const batchedActionTypes = action.payload.map( + (batchedAction) => batchedAction.type, + ); + return ( + _.intersection(EVALUATE_REDUX_ACTIONS, batchedActionTypes).length > 0 + ); + } + return true; +}; + +export const setEvaluatedTree = ( + dataTree: DataTree, + updates: Diff[], +): ReduxAction<{ dataTree: DataTree; updates: Diff[] }> => { + return { + type: ReduxActionTypes.SET_EVALUATED_TREE, + payload: { dataTree, updates }, + }; +}; + +export const setDependencyMap = ( + inverseDependencyMap: DependencyMap, +): ReduxAction<{ inverseDependencyMap: DependencyMap }> => { + return { + type: ReduxActionTypes.SET_EVALUATION_INVERSE_DEPENDENCY_MAP, + payload: { inverseDependencyMap }, + }; +}; diff --git a/app/taro/src/actions/explorerActions.ts b/app/taro/src/actions/explorerActions.ts new file mode 100644 index 0000000000..4ccaaa134d --- /dev/null +++ b/app/taro/src/actions/explorerActions.ts @@ -0,0 +1,10 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const initExplorerEntityNameEdit = (actionId: string) => { + return { + type: ReduxActionTypes.INIT_EXPLORER_ENTITY_NAME_EDIT, + payload: { + id: actionId, + }, + }; +}; diff --git a/app/taro/src/actions/helpActions.ts b/app/taro/src/actions/helpActions.ts new file mode 100644 index 0000000000..cb05fbeb68 --- /dev/null +++ b/app/taro/src/actions/helpActions.ts @@ -0,0 +1,14 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const setHelpDefaultRefinement = (payload: string) => { + return { + type: ReduxActionTypes.SET_DEFAULT_REFINEMENT, + payload, + }; +}; +export const setHelpModalVisibility = (payload: boolean) => { + return { + type: ReduxActionTypes.SET_HELP_MODAL_OPEN, + payload, + }; +}; diff --git a/app/taro/src/actions/initActions.ts b/app/taro/src/actions/initActions.ts new file mode 100644 index 0000000000..473d4132d6 --- /dev/null +++ b/app/taro/src/actions/initActions.ts @@ -0,0 +1,26 @@ +import { + ReduxActionTypes, + ReduxAction, + InitializeEditorPayload, +} from "constants/ReduxActionConstants"; + +export const initEditor = ( + applicationId: string, + pageId: string, + queryParams: any, +): ReduxAction => ({ + type: ReduxActionTypes.INITIALIZE_EDITOR, + payload: { + applicationId, + pageId, + queryParams, + }, +}); + +export const resetEditorRequest = () => ({ + type: ReduxActionTypes.RESET_EDITOR_REQUEST, +}); + +export const resetEditorSuccess = () => ({ + type: ReduxActionTypes.RESET_EDITOR_SUCCESS, +}); diff --git a/app/taro/src/actions/metaActions.ts b/app/taro/src/actions/metaActions.ts new file mode 100644 index 0000000000..d08e5f0993 --- /dev/null +++ b/app/taro/src/actions/metaActions.ts @@ -0,0 +1,44 @@ +import { ReduxActionTypes, ReduxAction } from "constants/ReduxActionConstants"; +import { BatchAction, batchAction } from "actions/batchActions"; + +export interface UpdateWidgetMetaPropertyPayload { + widgetId: string; + propertyName: string; + propertyValue: any; +} +export const updateWidgetMetaProperty = ( + widgetId: string, + propertyName: string, + propertyValue: any, +): BatchAction => { + return batchAction({ + type: ReduxActionTypes.SET_META_PROP, + payload: { + widgetId, + propertyName, + propertyValue, + }, + }); +}; + +export const resetWidgetMetaProperty = ( + widgetId: string, +): BatchAction<{ widgetId: string }> => { + return batchAction({ + type: ReduxActionTypes.RESET_WIDGET_META, + payload: { + widgetId, + }, + }); +}; + +export const resetChildrenMetaProperty = ( + widgetId: string, +): ReduxAction<{ widgetId: string }> => { + return { + type: ReduxActionTypes.RESET_CHILDREN_WIDGET_META, + payload: { + widgetId, + }, + }; +}; diff --git a/app/taro/src/actions/notificationActions.ts b/app/taro/src/actions/notificationActions.ts new file mode 100644 index 0000000000..209c04504a --- /dev/null +++ b/app/taro/src/actions/notificationActions.ts @@ -0,0 +1,58 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +import { AppsmithNotification } from "entities/Notification"; + +export const fetchNotificationsRequest = (beforeTime?: string) => ({ + type: ReduxActionTypes.FETCH_NOTIFICATIONS_REQUEST, + payload: beforeTime, +}); + +export const fetchNotificationsSuccess = (payload: { + notifications: Array; +}) => ({ + type: ReduxActionTypes.FETCH_NOTIFICATIONS_SUCCESS, + payload, +}); + +export const newNotificationEvent = (payload: Notification) => ({ + type: ReduxActionTypes.NEW_NOTIFICATION_EVENT, + payload, +}); + +export const setIsNotificationsListVisible = (payload: boolean) => ({ + type: ReduxActionTypes.SET_IS_NOTIFICATIONS_LIST_VISIBLE, + payload, +}); + +export const markAllNotificationsAsReadRequest = () => ({ + type: ReduxActionTypes.MARK_ALL_NOTIFICATIONS_AS_READ_REQUEST, +}); + +export const markAllNotificationsAsReadSuccess = () => ({ + type: ReduxActionTypes.MARK_ALL_NOTIFICATIONS_AS_READ_SUCCESS, +}); + +export const resetNotifications = (payload: { + notifications: Array; +}) => ({ + type: ReduxActionTypes.RESET_NOTIFICATIONS, + payload, +}); + +export const fetchUnreadNotificationsCountRequest = () => ({ + type: ReduxActionTypes.FETCH_UNREAD_NOTIFICATIONS_COUNT_REQUEST, +}); + +export const fetchUnreadNotificationsCountSuccess = (payload: number) => ({ + type: ReduxActionTypes.FETCH_UNREAD_NOTIFICATIONS_COUNT_SUCCESS, + payload, +}); + +export const markNotificationAsReadRequest = (payload: string) => ({ + type: ReduxActionTypes.MARK_NOTIFICATION_AS_READ_REQUEST, + payload, +}); + +export const markNotificationAsReadSuccess = (payload: string) => ({ + type: ReduxActionTypes.MARK_NOTIFICATION_AS_READ_SUCCESS, + payload, +}); diff --git a/app/taro/src/actions/onboardingActions.ts b/app/taro/src/actions/onboardingActions.ts new file mode 100644 index 0000000000..8d73222924 --- /dev/null +++ b/app/taro/src/actions/onboardingActions.ts @@ -0,0 +1,73 @@ +import { + OnboardingHelperConfig, + OnboardingStep, +} from "constants/OnboardingConstants"; +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const showIndicator = (payload: OnboardingStep) => { + return { + type: ReduxActionTypes.SHOW_ONBOARDING_INDICATOR, + payload, + }; +}; + +export const endOnboarding = () => { + return { + type: ReduxActionTypes.END_ONBOARDING, + }; +}; + +export const setCurrentStep = (payload: number) => { + return { + type: ReduxActionTypes.SET_CURRENT_STEP, + payload, + }; +}; + +export const setOnboardingState = (payload: boolean) => { + return { + type: ReduxActionTypes.SET_ONBOARDING_STATE, + payload, + }; +}; + +export const showOnboardingHelper = (payload: boolean) => { + return { + type: ReduxActionTypes.SHOW_ONBOARDING_HELPER, + payload, + }; +}; + +export const setHelperConfig = (payload: OnboardingHelperConfig) => { + return { + type: ReduxActionTypes.SET_HELPER_CONFIG, + payload, + }; +}; + +export const setCurrentSubstep = (payload: number) => { + return { + type: ReduxActionTypes.SET_ONBOARDING_SUBSTEP, + payload, + }; +}; + +export const showWelcomeHelper = (payload: boolean) => { + return { + type: ReduxActionTypes.SHOW_ONBOARDING_WELCOME_HELPER, + payload, + }; +}; + +export const showOnboardingLoader = (payload: boolean) => { + return { + type: ReduxActionTypes.SHOW_ONBOARDING_LOADER, + payload, + }; +}; + +export const showEndOnboardingHelper = () => { + return { + type: ReduxActionTypes.SHOW_END_ONBOARDING_HELPER, + }; +}; diff --git a/app/taro/src/actions/orgActions.ts b/app/taro/src/actions/orgActions.ts new file mode 100644 index 0000000000..f789d0f483 --- /dev/null +++ b/app/taro/src/actions/orgActions.ts @@ -0,0 +1,76 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +import { SaveOrgLogo, SaveOrgRequest } from "api/OrgApi"; + +export const fetchOrg = (orgId: string, skipValidation?: boolean) => { + return { + type: ReduxActionTypes.FETCH_CURRENT_ORG, + payload: { + orgId, + skipValidation, + }, + }; +}; + +export const changeOrgUserRole = ( + orgId: string, + role: string, + username: string, +) => { + return { + type: ReduxActionTypes.CHANGE_ORG_USER_ROLE_INIT, + payload: { + orgId, + role, + username, + }, + }; +}; + +export const deleteOrgUser = (orgId: string, username: string) => { + return { + type: ReduxActionTypes.DELETE_ORG_USER_INIT, + payload: { + orgId, + username, + }, + }; +}; +export const fetchUsersForOrg = (orgId: string) => { + return { + type: ReduxActionTypes.FETCH_ALL_USERS_INIT, + payload: { + orgId, + }, + }; +}; +export const fetchRolesForOrg = (orgId: string) => { + return { + type: ReduxActionTypes.FETCH_ALL_ROLES_INIT, + payload: { + orgId, + }, + }; +}; + +export const saveOrg = (orgSettings: SaveOrgRequest) => { + return { + type: ReduxActionTypes.SAVE_ORG_INIT, + payload: orgSettings, + }; +}; + +export const uploadOrgLogo = (orgLogo: SaveOrgLogo) => { + return { + type: ReduxActionTypes.UPLOAD_ORG_LOGO, + payload: orgLogo, + }; +}; + +export const deleteOrgLogo = (id: string) => { + return { + type: ReduxActionTypes.REMOVE_ORG_LOGO, + payload: { + id: id, + }, + }; +}; diff --git a/app/taro/src/actions/pageActions.tsx b/app/taro/src/actions/pageActions.tsx new file mode 100644 index 0000000000..1d9f7e0372 --- /dev/null +++ b/app/taro/src/actions/pageActions.tsx @@ -0,0 +1,366 @@ +import { WidgetType } from "constants/WidgetConstants"; +import { + EvaluationReduxAction, + ReduxAction, + ReduxActionTypes, + ReduxActionWithoutPayload, + UpdateCanvasPayload, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; +import { WidgetOperation } from "widgets/BaseWidget"; +import { FetchPageRequest, PageLayout, SavePageResponse } from "api/PageApi"; +import { UrlDataState } from "reducers/entityReducers/appReducer"; +import { APP_MODE } from "entities/App"; +import { CanvasWidgetsReduxState } from "reducers/entityReducers/canvasWidgetsReducer"; +import { GenerateTemplatePageRequest } from "../api/PageApi"; +import { WidgetReduxActionTypes } from "../constants/ReduxActionConstants"; + +export interface FetchPageListPayload { + applicationId: string; + mode: APP_MODE; +} + +export const fetchPageList = ( + applicationId: string, + mode: APP_MODE +): ReduxAction => { + return { + type: ReduxActionTypes.FETCH_PAGE_LIST_INIT, + payload: { + applicationId, + mode, + }, + }; +}; + +export const fetchPage = ( + pageId: string, + isFirstLoad = false +): ReduxAction => { + return { + type: ReduxActionTypes.FETCH_PAGE_INIT, + payload: { + id: pageId, + isFirstLoad, + }, + }; +}; + +export const fetchPublishedPage = ( + pageId: string, + bustCache = false, + urlData?: UrlDataState +) => ({ + type: ReduxActionTypes.FETCH_PUBLISHED_PAGE_INIT, + payload: { + pageId, + bustCache, + urlData, + }, +}); + +export const fetchPageSuccess = ( + postEvalActions: Array | ReduxActionWithoutPayload> +): EvaluationReduxAction => { + return { + type: ReduxActionTypes.FETCH_PAGE_SUCCESS, + postEvalActions, + payload: undefined, + }; +}; + +export const fetchPublishedPageSuccess = ( + postEvalActions: Array | ReduxActionWithoutPayload> +): EvaluationReduxAction => ({ + type: ReduxActionTypes.FETCH_PUBLISHED_PAGE_SUCCESS, + postEvalActions, + payload: undefined, +}); + +export const updateCurrentPage = (id: string) => ({ + type: ReduxActionTypes.SWITCH_CURRENT_PAGE_ID, + payload: { id }, +}); + +export const initCanvasLayout = ( + payload: UpdateCanvasPayload +): ReduxAction => { + return { + type: ReduxActionTypes.INIT_CANVAS_LAYOUT, + payload, + }; +}; + +export const setLastUpdatedTime = (payload: number): ReduxAction => ({ + type: ReduxActionTypes.SET_LAST_UPDATED_TIME, + payload, +}); + +export const savePageSuccess = (payload: SavePageResponse) => { + return { + type: ReduxActionTypes.SAVE_PAGE_SUCCESS, + payload, + }; +}; + +export const updateWidgetNameSuccess = () => { + return { + type: ReduxActionTypes.UPDATE_WIDGET_NAME_SUCCESS, + }; +}; + +export const deletePageSuccess = () => { + return { + type: ReduxActionTypes.DELETE_PAGE_SUCCESS, + }; +}; + +export const updateAndSaveLayout = ( + widgets: CanvasWidgetsReduxState, + isRetry?: boolean +) => { + return { + type: ReduxActionTypes.UPDATE_LAYOUT, + payload: { widgets, isRetry }, + }; +}; + +export const saveLayout = (isRetry?: boolean) => { + return { + type: ReduxActionTypes.SAVE_PAGE_INIT, + payload: { isRetry }, + }; +}; + +export const createPage = ( + applicationId: string, + pageName: string, + layouts: Partial[] +) => { + return { + type: ReduxActionTypes.CREATE_PAGE_INIT, + payload: { + applicationId, + name: pageName, + layouts, + }, + }; +}; + +export const clonePageInit = (pageId: string) => { + return { + type: ReduxActionTypes.CLONE_PAGE_INIT, + payload: { + id: pageId, + }, + }; +}; + +export const clonePageSuccess = ( + pageId: string, + pageName: string, + layoutId: string +) => { + return { + type: ReduxActionTypes.CLONE_PAGE_SUCCESS, + payload: { + pageId, + pageName, + layoutId, + }, + }; +}; + +export const updatePage = (id: string, name: string, isHidden: boolean) => { + return { + type: ReduxActionTypes.UPDATE_PAGE_INIT, + payload: { + id, + name, + isHidden, + }, + }; +}; + +export type WidgetAddChild = { + widgetId: string; + widgetName?: string; + type: WidgetType; + leftColumn: number; + topRow: number; + columns: number; + rows: number; + parentRowSpace: number; + parentColumnSpace: number; + newWidgetId: string; + tabId: string; + props?: Record; +}; + +export type WidgetMove = { + widgetId: string; + leftColumn: number; + topRow: number; + parentId: string; + /* + If newParentId is different from what we have in redux store, + then we have to delete this, + as it has been dropped in another container somewhere. + */ + newParentId: string; +}; + +export type WidgetRemoveChild = { + widgetId: string; + childWidgetId: string; +}; + +export type WidgetDelete = { + widgetId?: string; + parentId?: string; + disallowUndo?: boolean; + isShortcut?: boolean; +}; + +export type MultipleWidgetDeletePayload = { + widgetIds: string[]; + disallowUndo?: boolean; + isShortcut?: boolean; +}; + +export type WidgetResize = { + widgetId: string; + leftColumn: number; + rightColumn: number; + topRow: number; + bottomRow: number; +}; + +export type WidgetAddChildren = { + widgetId: string; + children: Array<{ + type: WidgetType; + widgetId: string; + parentId: string; + parentRowSpace: number; + parentColumnSpace: number; + leftColumn: number; + rightColumn: number; + topRow: number; + bottomRow: number; + isLoading: boolean; + }>; +}; + +export type WidgetUpdateProperty = { + widgetId: string; + propertyPath: string; + propertyValue: any; +}; + +export const updateWidget = ( + operation: WidgetOperation, + widgetId: string, + payload: any +): ReduxAction< + | WidgetAddChild + | WidgetMove + | WidgetResize + | WidgetDelete + | WidgetAddChildren + | WidgetUpdateProperty +> => { + return { + type: WidgetReduxActionTypes["WIDGET_" + operation], + payload: { widgetId, ...payload }, + }; +}; + +export const setUrlData = ( + payload: UrlDataState +): ReduxAction => { + return { + type: ReduxActionTypes.SET_URL_DATA, + payload, + }; +}; + +export const setAppMode = (payload: APP_MODE): ReduxAction => { + return { + type: ReduxActionTypes.SET_APP_MODE, + payload, + }; +}; + +export const updateAppTransientStore = ( + payload: Record +): ReduxAction> => ({ + type: ReduxActionTypes.UPDATE_APP_TRANSIENT_STORE, + payload, +}); + +export const updateAppPersistentStore = ( + payload: Record +): ReduxAction> => { + return { + type: ReduxActionTypes.UPDATE_APP_PERSISTENT_STORE, + payload, + }; +}; + +export interface ReduxActionWithExtraParams extends ReduxAction { + extraParams: Record; +} + +export const generateTemplateSuccess = ({ + isNewPage, + layoutId, + pageId, + pageName, +}: { + layoutId: string; + pageId: string; + pageName: string; + isNewPage: boolean; +}) => { + return { + type: ReduxActionTypes.GENERATE_TEMPLATE_PAGE_SUCCESS, + payload: { + layoutId, + pageId, + pageName, + isNewPage, + }, + }; +}; + +export const generateTemplateError = () => { + return { + type: ReduxActionErrorTypes.GENERATE_TEMPLATE_PAGE_ERROR, + }; +}; + +export const generateTemplateToUpdatePage = ({ + applicationId, + columns, + datasourceId, + mode, + pageId, + searchColumn, + tableName, +}: GenerateTemplatePageRequest): ReduxActionWithExtraParams => { + return { + type: ReduxActionTypes.GENERATE_TEMPLATE_PAGE_INIT, + payload: { + pageId, + tableName, + datasourceId, + applicationId, + columns, + searchColumn, + }, + extraParams: { + mode, + }, + }; +}; diff --git a/app/taro/src/actions/pluginActions.ts b/app/taro/src/actions/pluginActions.ts new file mode 100644 index 0000000000..ae997d0244 --- /dev/null +++ b/app/taro/src/actions/pluginActions.ts @@ -0,0 +1,62 @@ +import { + ReduxAction, + ReduxActionTypes, + ReduxActionErrorTypes, + ReduxActionWithoutPayload, +} from "constants/ReduxActionConstants"; +import { PluginFormPayload } from "api/PluginApi"; +import { DependencyMap } from "utils/DynamicBindingUtils"; + +export const fetchPlugins = (): ReduxActionWithoutPayload => ({ + type: ReduxActionTypes.FETCH_PLUGINS_REQUEST, +}); + +export const fetchPluginFormConfigs = (): ReduxActionWithoutPayload => ({ + type: ReduxActionTypes.FETCH_PLUGIN_FORM_CONFIGS_REQUEST, +}); + +export type PluginFormsPayload = { + formConfigs: Record; + editorConfigs: Record; + settingConfigs: Record; + dependencies: Record; +}; + +export const fetchPluginFormConfigsSuccess = ( + payload: PluginFormsPayload, +): ReduxAction => ({ + type: ReduxActionTypes.FETCH_PLUGIN_FORM_CONFIGS_SUCCESS, + payload, +}); + +export interface PluginFormPayloadWithId extends PluginFormPayload { + id: string; +} + +export const fetchPluginFormConfigSuccess = ( + payload: PluginFormPayloadWithId, +): ReduxAction => ({ + type: ReduxActionTypes.FETCH_PLUGIN_FORM_SUCCESS, + payload, +}); + +export const fetchPluginFormConfigError = ( + payload: GetPluginFormConfigRequest, +): ReduxAction => ({ + type: ReduxActionErrorTypes.FETCH_PLUGIN_FORM_ERROR, + payload, +}); + +export interface GetPluginFormConfigRequest { + id: string; +} + +// To fetch plugin form config for individual plugin +export const fetchPluginFormConfig = ({ + pluginId: id, +}: { + pluginId: GetPluginFormConfigRequest; +}) => ({ + type: ReduxActionTypes.GET_PLUGIN_FORM_CONFIG_INIT, + payload: id, +}); diff --git a/app/taro/src/actions/propertyPaneActions.ts b/app/taro/src/actions/propertyPaneActions.ts new file mode 100644 index 0000000000..57551ab0cf --- /dev/null +++ b/app/taro/src/actions/propertyPaneActions.ts @@ -0,0 +1,32 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +export const updateWidgetName = (widgetId: string, newName: string) => { + return { + type: ReduxActionTypes.UPDATE_WIDGET_NAME_INIT, + payload: { + id: widgetId, + newName, + }, + }; +}; + +export const hidePropertyPane = () => { + return { + type: ReduxActionTypes.HIDE_PROPERTY_PANE, + }; +}; + +export const bindDataToWidget = (payload: { widgetId: string }) => { + return { + type: ReduxActionTypes.BIND_DATA_TO_WIDGET, + payload, + }; +}; + +export const setSnipingMode = (payload: boolean) => ({ + type: ReduxActionTypes.SET_SNIPING_MODE, + payload, +}); + +export const resetSnipingMode = () => ({ + type: ReduxActionTypes.RESET_SNIPING_MODE, +}); diff --git a/app/taro/src/actions/providerActions.ts b/app/taro/src/actions/providerActions.ts new file mode 100644 index 0000000000..3e250f705b --- /dev/null +++ b/app/taro/src/actions/providerActions.ts @@ -0,0 +1,61 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +import { + AddApiToPageRequest, + FetchProviderWithCategoryRequest, + SearchApiOrProviderRequest, +} from "api/ProvidersApi"; + +export const fetchProviders = () => { + return { + type: ReduxActionTypes.FETCH_PROVIDERS_INIT, + }; +}; + +export const searchApiOrProvider = (payload: SearchApiOrProviderRequest) => { + return { + type: ReduxActionTypes.SEARCH_APIORPROVIDERS_INIT, + payload, + }; +}; + +export const fetchProviderCategories = () => { + return { + type: ReduxActionTypes.FETCH_PROVIDERS_CATEGORIES_INIT, + }; +}; + +export const getProviderDetailsByProviderId = (providerId: string) => { + return { + type: ReduxActionTypes.FETCH_PROVIDER_DETAILS_BY_PROVIDER_ID_INIT, + payload: { providerId }, + }; +}; +export const fetchProviderTemplates = (providerId: string) => { + return { + type: ReduxActionTypes.FETCH_PROVIDER_TEMPLATES_INIT, + payload: { providerId }, + }; +}; + +export const addApiToPage = (payload: AddApiToPageRequest) => { + return { + type: ReduxActionTypes.ADD_API_TO_PAGE_INIT, + payload, + }; +}; + +export const fetchProvidersWithCategory = ( + payload: FetchProviderWithCategoryRequest, +) => { + return { + type: ReduxActionTypes.FETCH_PROVIDERS_WITH_CATEGORY_INIT, + payload, + }; +}; + +export const clearProviders = () => { + return { + type: ReduxActionTypes.CLEAR_PROVIDERS, + }; +}; diff --git a/app/taro/src/actions/queryPaneActions.ts b/app/taro/src/actions/queryPaneActions.ts new file mode 100644 index 0000000000..57394784f1 --- /dev/null +++ b/app/taro/src/actions/queryPaneActions.ts @@ -0,0 +1,29 @@ +import { ReduxActionTypes, ReduxAction } from "constants/ReduxActionConstants"; +import { Action } from "entities/Action"; + +export const createQueryRequest = (payload: Partial) => { + return { + type: ReduxActionTypes.CREATE_QUERY_INIT, + payload, + }; +}; + +export const initQueryPane = ( + pluginType: string, + urlId?: string, +): ReduxAction<{ pluginType: string; id?: string }> => { + return { + type: ReduxActionTypes.INIT_QUERY_PANE, + payload: { id: urlId, pluginType }, + }; +}; + +export const changeQuery = ( + id: string, + newQuery?: boolean, +): ReduxAction<{ id: string; newQuery?: boolean }> => { + return { + type: ReduxActionTypes.QUERY_PANE_CHANGE, + payload: { id, newQuery }, + }; +}; diff --git a/app/taro/src/actions/recentEntityActions.ts b/app/taro/src/actions/recentEntityActions.ts new file mode 100644 index 0000000000..5f3536a5f5 --- /dev/null +++ b/app/taro/src/actions/recentEntityActions.ts @@ -0,0 +1,6 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const handlePathUpdated = (location: typeof window.location) => ({ + type: ReduxActionTypes.HANDLE_PATH_UPDATED, + payload: { location }, +}); diff --git a/app/taro/src/actions/releasesActions.ts b/app/taro/src/actions/releasesActions.ts new file mode 100644 index 0000000000..34ab848418 --- /dev/null +++ b/app/taro/src/actions/releasesActions.ts @@ -0,0 +1,5 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const resetReleasesCount = () => ({ + type: ReduxActionTypes.RESET_UNREAD_RELEASES_COUNT, +}); diff --git a/app/taro/src/actions/themeActions.ts b/app/taro/src/actions/themeActions.ts new file mode 100644 index 0000000000..aef1a76957 --- /dev/null +++ b/app/taro/src/actions/themeActions.ts @@ -0,0 +1,7 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +import { ThemeMode } from "../selectors/themeSelectors"; + +export const setThemeMode = (mode: ThemeMode) => ({ + type: ReduxActionTypes.SET_THEME, + payload: mode, +}); diff --git a/app/taro/src/actions/tourActions.ts b/app/taro/src/actions/tourActions.ts new file mode 100644 index 0000000000..b32c709a4a --- /dev/null +++ b/app/taro/src/actions/tourActions.ts @@ -0,0 +1,22 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +import { TourType } from "entities/Tour"; + +export const setActiveTour = (tourType: TourType) => ({ + type: ReduxActionTypes.SET_ACTIVE_TOUR, + payload: tourType, +}); + +export const resetActiveTour = () => ({ + type: ReduxActionTypes.RESET_ACTIVE_TOUR, + payload: undefined, +}); + +export const setActiveTourIndex = (index: number) => ({ + type: ReduxActionTypes.SET_ACTIVE_TOUR_INDEX, + payload: index, +}); + +export const proceedToNextTourStep = () => ({ + type: ReduxActionTypes.PROCEED_TO_NEXT_TOUR_STEP, + payload: undefined, +}); diff --git a/app/taro/src/actions/userActions.ts b/app/taro/src/actions/userActions.ts new file mode 100644 index 0000000000..f3670ce6fa --- /dev/null +++ b/app/taro/src/actions/userActions.ts @@ -0,0 +1,102 @@ +import { + ReduxActionErrorTypes, + ReduxActionTypes, +} from "constants/ReduxActionConstants"; +import { CurrentUserDetailsRequestPayload } from "constants/userConstants"; +import { + TokenPasswordUpdateRequest, + UpdateUserRequest, + VerifyTokenRequest, +} from "api/UserApi"; + +export const logoutUser = (payload?: { redirectURL: string }) => ({ + type: ReduxActionTypes.LOGOUT_USER_INIT, + payload, +}); + +export const logoutUserSuccess = () => ({ + type: ReduxActionTypes.LOGOUT_USER_SUCCESS, +}); + +export const logoutUserError = (error: any) => ({ + type: ReduxActionErrorTypes.LOGOUT_USER_ERROR, + payload: { + error, + }, +}); +export const setCurrentUserDetails = () => ({ + type: ReduxActionTypes.SET_CURRENT_USER_INIT, + payload: CurrentUserDetailsRequestPayload, +}); + +export const verifyInviteSuccess = () => ({ + type: ReduxActionTypes.VERIFY_INVITE_SUCCESS, +}); + +export const verifyInvite = (payload: VerifyTokenRequest) => ({ + type: ReduxActionTypes.VERIFY_INVITE_INIT, + payload, +}); + +export const verifyInviteError = (error: any) => ({ + type: ReduxActionErrorTypes.VERIFY_INVITE_ERROR, + payload: { error }, +}); + +export const invitedUserSignup = ( + payload: TokenPasswordUpdateRequest & { resolve: any; reject: any }, +) => ({ + type: ReduxActionTypes.INVITED_USER_SIGNUP_INIT, + payload, +}); + +export const invitedUserSignupSuccess = () => ({ + type: ReduxActionTypes.INVITED_USER_SIGNUP_SUCCESS, +}); + +export const invitedUserSignupError = (error: any) => ({ + type: ReduxActionErrorTypes.INVITED_USER_SIGNUP_ERROR, + payload: { + error, + }, +}); + +export const updateUserDetails = (payload: UpdateUserRequest) => ({ + type: ReduxActionTypes.UPDATE_USER_DETAILS_INIT, + payload, +}); + +export const updatePhoto = (payload: { + file: File; + callback?: () => void; +}) => ({ + type: ReduxActionTypes.UPLOAD_PROFILE_PHOTO, + payload, +}); + +export const removePhoto = (callback: () => void) => ({ + type: ReduxActionTypes.REMOVE_PROFILE_PHOTO, + payload: { callback }, +}); + +export const leaveOrganization = (orgId: string) => { + return { + type: ReduxActionTypes.LEAVE_ORG_INIT, + payload: { + orgId, + }, + }; +}; + +export const fetchFeatureFlagsInit = () => ({ + type: ReduxActionTypes.FETCH_FEATURE_FLAGS_INIT, +}); + +export const fetchFeatureFlagsSuccess = () => ({ + type: ReduxActionTypes.FETCH_FEATURE_FLAGS_SUCCESS, +}); + +export const fetchFeatureFlagsError = (error: any) => ({ + type: ReduxActionErrorTypes.FETCH_FEATURE_FLAGS_ERROR, + payload: { error, show: false }, +}); diff --git a/app/taro/src/actions/utilActions.ts b/app/taro/src/actions/utilActions.ts new file mode 100644 index 0000000000..9597b4b119 --- /dev/null +++ b/app/taro/src/actions/utilActions.ts @@ -0,0 +1,15 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; + +export const historyPush = (url: string) => ({ + type: ReduxActionTypes.HISTORY_PUSH, + payload: { + url, + }, +}); + +export const windowRedirect = (url: string) => ({ + type: ReduxActionTypes.REDIRECT_WINDOW_LOCATION, + payload: { + url, + }, +}); diff --git a/app/taro/src/actions/websocketActions.ts b/app/taro/src/actions/websocketActions.ts new file mode 100644 index 0000000000..20a2c9e63e --- /dev/null +++ b/app/taro/src/actions/websocketActions.ts @@ -0,0 +1,25 @@ +import { + ReduxActionTypes, + ReduxSagaChannels, +} from "constants/ReduxActionConstants"; +import { reconnectWebsocketEvent } from "constants/WebsocketConstants"; + +export const setIsWebsocketConnected = (payload: boolean) => ({ + type: ReduxActionTypes.SET_IS_WEBSOCKET_CONNECTED, + payload, +}); + +export const websocketWriteEvent = (payload: { + type: string; + payload?: any; +}) => ({ + type: ReduxSagaChannels.WEBSOCKET_WRITE_CHANNEL, + payload, +}); + +export const reconnectWebsocket = () => + websocketWriteEvent(reconnectWebsocketEvent()); + +export const retrySocketConnection = () => ({ + type: ReduxActionTypes.RETRY_WEBSOCKET_CONNECTION, +}); diff --git a/app/taro/src/actions/widgetActions.tsx b/app/taro/src/actions/widgetActions.tsx new file mode 100644 index 0000000000..d27e3a4290 --- /dev/null +++ b/app/taro/src/actions/widgetActions.tsx @@ -0,0 +1,148 @@ +import { + ReduxActionTypes, + ReduxAction, + ReduxActionErrorTypes, + ReduxActionWithoutPayload, + WidgetReduxActionTypes, +} from "constants/ReduxActionConstants"; +import { + ExecuteActionPayload, + ExecuteErrorPayload, +} from "constants/AppsmithActionConstants/ActionConstants"; +import { BatchAction, batchAction } from "actions/batchActions"; +import { WidgetProps } from "widgets/BaseWidget"; + +export const executeAction = ( + payload: ExecuteActionPayload, +): BatchAction => + batchAction({ + type: ReduxActionTypes.EXECUTE_ACTION, + payload, + }); + +export const executeActionError = ( + executeErrorPayload: ExecuteErrorPayload, +): ReduxAction => { + return { + type: ReduxActionErrorTypes.EXECUTE_ACTION_ERROR, + payload: executeErrorPayload, + }; +}; + +export const executePageLoadActions = (): ReduxActionWithoutPayload => ({ + type: ReduxActionTypes.EXECUTE_PAGE_LOAD_ACTIONS, +}); + +export const disableDragAction = ( + isDraggingDisabled: boolean, +): ReduxAction<{ isDraggingDisabled: boolean }> => { + return { + type: ReduxActionTypes.DISABLE_WIDGET_DRAG, + payload: { + isDraggingDisabled, + }, + }; +}; + +export const createModalAction = ( + modalName: string, +): ReduxAction<{ modalName: string }> => { + return { + type: ReduxActionTypes.CREATE_MODAL_INIT, + payload: { + modalName, + }, + }; +}; + +export const focusWidget = ( + widgetId?: string, +): ReduxAction<{ widgetId?: string }> => ({ + type: ReduxActionTypes.FOCUS_WIDGET, + payload: { widgetId }, +}); + +export const showModal = (id: string) => { + return { + type: ReduxActionTypes.SHOW_MODAL, + payload: { + modalId: id, + }, + }; +}; + +export const closeAllModals = () => { + return { + type: ReduxActionTypes.CLOSE_MODAL, + payload: {}, + }; +}; + +export const forceOpenPropertyPane = (id: string) => { + return { + type: ReduxActionTypes.SHOW_PROPERTY_PANE, + payload: { + widgetId: id, + force: true, + }, + }; +}; + +export const closePropertyPane = () => { + return { + type: ReduxActionTypes.HIDE_PROPERTY_PANE, + payload: { + force: false, + }, + }; +}; + +export const closeTableFilterPane = () => { + return { + type: ReduxActionTypes.HIDE_TABLE_FILTER_PANE, + payload: { + force: false, + }, + }; +}; + +export const copyWidget = (isShortcut: boolean) => { + return { + type: ReduxActionTypes.COPY_SELECTED_WIDGET_INIT, + payload: { + isShortcut: !!isShortcut, + }, + }; +}; + +export const pasteWidget = () => { + return { + type: ReduxActionTypes.PASTE_COPIED_WIDGET_INIT, + }; +}; + +export const deleteSelectedWidget = ( + isShortcut: boolean, + disallowUndo = false, +) => { + return { + type: WidgetReduxActionTypes.WIDGET_DELETE, + payload: { + isShortcut, + disallowUndo, + }, + }; +}; + +export const cutWidget = () => { + return { + type: ReduxActionTypes.CUT_SELECTED_WIDGET, + }; +}; + +export const addSuggestedWidget = (payload: Partial) => { + return { + type: ReduxActionTypes.ADD_SUGGESTED_WIDGET, + payload, + }; +}; diff --git a/app/taro/src/actions/widgetSelectionActions.ts b/app/taro/src/actions/widgetSelectionActions.ts new file mode 100644 index 0000000000..c323a53128 --- /dev/null +++ b/app/taro/src/actions/widgetSelectionActions.ts @@ -0,0 +1,71 @@ +import { ReduxActionTypes, ReduxAction } from "constants/ReduxActionConstants"; +import { MAIN_CONTAINER_WIDGET_ID } from "constants/WidgetConstants"; + +export const selectWidgetAction = ( + widgetId?: string, + isMultiSelect?: boolean, +): ReduxAction<{ widgetId?: string; isMultiSelect?: boolean }> => ({ + type: ReduxActionTypes.SELECT_WIDGET, + payload: { widgetId, isMultiSelect }, +}); + +export const selectWidgetInitAction = ( + widgetId?: string, + isMultiSelect?: boolean, +): ReduxAction<{ widgetId?: string; isMultiSelect?: boolean }> => ({ + type: ReduxActionTypes.SELECT_WIDGET_INIT, + payload: { widgetId, isMultiSelect }, +}); + +export const selectMultipleWidgetsAction = ( + widgetIds?: string[], +): ReduxAction<{ widgetIds?: string[] }> => { + return { + type: ReduxActionTypes.SELECT_MULTIPLE_WIDGETS, + payload: { widgetIds }, + }; +}; + +export const silentAddSelectionsAction = ( + widgetIds?: string[], +): ReduxAction<{ widgetIds?: string[] }> => { + return { + type: ReduxActionTypes.SELECT_WIDGETS, + payload: { widgetIds }, + }; +}; + +export const deselectMultipleWidgetsAction = ( + widgetIds?: string[], +): ReduxAction<{ widgetIds?: string[] }> => { + return { + type: ReduxActionTypes.DESELECT_WIDGETS, + payload: { widgetIds }, + }; +}; + +export const selectAllWidgetsInCanvasInitAction = ( + canvasId = MAIN_CONTAINER_WIDGET_ID, +): ReduxAction<{ canvasId: string }> => { + return { + type: ReduxActionTypes.SELECT_ALL_WIDGETS_IN_CANVAS_INIT, + payload: { + canvasId, + }, + }; +}; + +export const selectMultipleWidgetsInitAction = (widgetIds: string[]) => { + return { + type: ReduxActionTypes.SELECT_MULTIPLE_WIDGETS_INIT, + payload: { widgetIds }, + }; +}; + +export const shiftSelectWidgetsEntityExplorerInitAction = ( + widgetId: string, + siblingWidgets: string[], +): ReduxAction<{ widgetId: string; siblingWidgets: string[] }> => ({ + type: ReduxActionTypes.SHIFT_SELECT_WIDGET_INIT, + payload: { widgetId, siblingWidgets }, +}); diff --git a/app/taro/src/actions/widgetSidebarActions.tsx b/app/taro/src/actions/widgetSidebarActions.tsx new file mode 100644 index 0000000000..aec2b71633 --- /dev/null +++ b/app/taro/src/actions/widgetSidebarActions.tsx @@ -0,0 +1,33 @@ +import { + ReduxActionTypes, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; +import { WidgetCardProps } from "widgets/BaseWidget"; + +export const fetchWidgetCards = () => { + return { + type: ReduxActionTypes.FETCH_WIDGET_CARDS, + }; +}; + +export const errorFetchingWidgetCards = (error: any) => { + return { + type: ReduxActionErrorTypes.FETCH_WIDGET_CARDS_ERROR, + error, + }; +}; + +export const successFetchingWidgetCards = (cards: { + [id: string]: WidgetCardProps[]; +}) => { + return { + type: ReduxActionTypes.FETCH_WIDGET_CARDS_SUCCESS, + cards, + }; +}; + +export default { + fetchWidgetCards, + errorFetchingWidgetCards, + successFetchingWidgetCards, +}; diff --git a/app/taro/src/api/ActionAPI.tsx b/app/taro/src/api/ActionAPI.tsx new file mode 100644 index 0000000000..26c86830d7 --- /dev/null +++ b/app/taro/src/api/ActionAPI.tsx @@ -0,0 +1,188 @@ +import API, { HttpMethod } from "api/Api"; +import { ApiResponse, GenericApiResponse, ResponseMeta } from "./ApiResponses"; +import { DEFAULT_EXECUTE_ACTION_TIMEOUT_MS } from "constants/ApiConstants"; +import axios, { AxiosPromise, CancelTokenSource } from "taro-axios"; +import { Action, ActionViewMode } from "entities/Action"; +import { APIRequest } from "constants/AppsmithActionConstants/ActionConstants"; +import { WidgetType } from "constants/WidgetConstants"; + +export interface CreateActionRequest extends APIRequest { + datasourceId: string; + pageId: string; + name: string; + actionConfiguration: T; +} + +export interface UpdateActionRequest extends CreateActionRequest { + actionId: string; +} + +export interface Property { + key: string; + value?: string; +} + +export interface BodyFormData { + editable: boolean; + mandatory: boolean; + description: string; + key: string; + value?: string; + type: string; +} + +export interface QueryConfig { + queryString: string; +} + +export interface ActionCreateUpdateResponse extends ApiResponse { + id: string; + jsonPathKeys: Record; +} + +export type PaginationField = "PREV" | "NEXT"; + +export interface ExecuteActionRequest extends APIRequest { + actionId: string; + params?: Property[]; + paginationField?: PaginationField; + viewMode: boolean; +} + +export interface ExecuteActionResponse extends ApiResponse { + actionId: string; + data: any; +} + +export interface ActionApiResponseReq { + headers: Record; + body: Record | null; + httpMethod: HttpMethod | ""; + url: string; +} + +export interface ActionExecutionResponse { + responseMeta: ResponseMeta; + data: { + body: Record | string; + headers: Record; + statusCode: string; + isExecutionSuccess: boolean; + request: ActionApiResponseReq; + }; + clientMeta: { + duration: string; + size: string; + }; +} + +export interface SuggestedWidget { + type: WidgetType; + bindingQuery: string; +} + +export interface ActionResponse { + body: unknown; + headers: Record; + request?: ActionApiResponseReq; + statusCode: string; + duration: string; + size: string; + isExecutionSuccess?: boolean; + suggestedWidgets?: SuggestedWidget[]; + messages?: Array; +} + +export interface MoveActionRequest { + action: Action; + destinationPageId: string; +} + +export interface CopyActionRequest { + action: Action; + pageId: string; +} + +export interface UpdateActionNameRequest { + pageId: string; + actionId: string; + layoutId: string; + newName: string; + oldName: string; +} + +class ActionAPI extends API { + static url = "v1/actions"; + static apiUpdateCancelTokenSource: CancelTokenSource; + static queryUpdateCancelTokenSource: CancelTokenSource; + + static createAction( + apiConfig: Partial, + ): AxiosPromise { + return API.post(ActionAPI.url, apiConfig); + } + + static fetchActions( + applicationId: string, + ): AxiosPromise> { + return API.get(ActionAPI.url, { applicationId }); + } + + static fetchActionsForViewMode( + applicationId: string, + ): AxiosPromise> { + return API.get(`${ActionAPI.url}/view`, { applicationId }); + } + + static fetchActionsByPageId( + pageId: string, + ): AxiosPromise> { + return API.get(ActionAPI.url, { pageId }); + } + + static updateAction( + apiConfig: Partial, + ): AxiosPromise { + if (ActionAPI.apiUpdateCancelTokenSource) { + ActionAPI.apiUpdateCancelTokenSource.cancel(); + } + ActionAPI.apiUpdateCancelTokenSource = axios.CancelToken.source(); + const action = Object.assign({}, apiConfig); + // While this line is not required, name can not be changed from this endpoint + delete action.name; + return API.put(`${ActionAPI.url}/${action.id}`, action, undefined, { + cancelToken: ActionAPI.apiUpdateCancelTokenSource.token, + }); + } + + static updateActionName(updateActionNameRequest: UpdateActionNameRequest) { + return API.put(ActionAPI.url + "/refactor", updateActionNameRequest); + } + + static deleteAction(id: string) { + return API.delete(`${ActionAPI.url}/${id}`); + } + + static executeAction( + executeAction: ExecuteActionRequest, + timeout?: number, + ): AxiosPromise { + return API.post(ActionAPI.url + "/execute", executeAction, undefined, { + timeout: timeout || DEFAULT_EXECUTE_ACTION_TIMEOUT_MS, + }); + } + + static moveAction(moveRequest: MoveActionRequest) { + return API.put(ActionAPI.url + "/move", moveRequest, undefined, { + timeout: DEFAULT_EXECUTE_ACTION_TIMEOUT_MS, + }); + } + + static toggleActionExecuteOnLoad(actionId: string, shouldExecute: boolean) { + return API.put(ActionAPI.url + `/executeOnLoad/${actionId}`, undefined, { + flag: shouldExecute.toString(), + }); + } +} + +export default ActionAPI; diff --git a/app/taro/src/api/Api.ts b/app/taro/src/api/Api.ts new file mode 100644 index 0000000000..cb851bd80a --- /dev/null +++ b/app/taro/src/api/Api.ts @@ -0,0 +1,101 @@ +import axios, { AxiosInstance, AxiosRequestConfig } from "taro-axios"; +import { REQUEST_TIMEOUT_MS } from "constants/ApiConstants"; +import { convertObjectToQueryParams } from "utils/AppsmithUtils"; +import { + apiFailureResponseInterceptor, + apiRequestInterceptor, + apiSuccessResponseInterceptor, +} from "api/ApiUtils"; +import { API_REQUEST_HEADERS } from "constants/AppsmithActionConstants/ActionConstants"; + +//TODO(abhinav): Refactor this to make more composable. +export const apiRequestConfig = { + baseURL: API_BASE_URL, + timeout: REQUEST_TIMEOUT_MS, + headers: API_REQUEST_HEADERS, + withCredentials: true, +}; + +const axiosInstance: AxiosInstance = axios.create(); + +axiosInstance.interceptors.request.use(apiRequestInterceptor); +axiosInstance.interceptors.response.use( + apiSuccessResponseInterceptor, + apiFailureResponseInterceptor, +); + +class Api { + static get( + url: string, + queryParams?: any, + config: Partial = {}, + ) { + return axiosInstance.get(url + convertObjectToQueryParams(queryParams), { + ...apiRequestConfig, + ...config, + }); + } + + static post( + url: string, + body?: any, + queryParams?: any, + config: Partial = {}, + ) { + return axiosInstance.post( + url + convertObjectToQueryParams(queryParams), + body, + { + ...apiRequestConfig, + ...config, + }, + ); + } + + static put( + url: string, + body?: any, + queryParams?: any, + config: Partial = {}, + ) { + return axiosInstance.put( + url + convertObjectToQueryParams(queryParams), + body, + { + ...apiRequestConfig, + ...config, + }, + ); + } + + static patch( + url: string, + body?: any, + queryParams?: any, + config: Partial = {}, + ) { + return axiosInstance.patch( + url + convertObjectToQueryParams(queryParams), + body, + { + ...apiRequestConfig, + ...config, + }, + ); + } + + static delete( + url: string, + queryParams?: any, + config: Partial = {}, + ) { + return axiosInstance.delete(url + convertObjectToQueryParams(queryParams), { + ...apiRequestConfig, + ...config, + }); + } +} + +export type HttpMethod = "GET" | "POST" | "PUT" | "DELETE" | "PATCH"; + +export default Api; diff --git a/app/taro/src/api/ApiResponses.tsx b/app/taro/src/api/ApiResponses.tsx new file mode 100644 index 0000000000..43c781e919 --- /dev/null +++ b/app/taro/src/api/ApiResponses.tsx @@ -0,0 +1,31 @@ +export type APIResponseError = { + code: number; + message: string; +}; + +export type ResponseMeta = { + status: number; + success: boolean; + error?: APIResponseError; +}; + +export type ApiResponse = { + responseMeta: ResponseMeta; + data: any; +}; + +export type GenericApiResponse = { + responseMeta: ResponseMeta; + data: T; +}; + +// NO_DATASOURCES_FOUND, 1000, "Unable to find {0} with id {1}" +// INVALID_PARAMTER, 4000, "Invalid parameter {0} provided in the input" +// PLUGIN_NOT_INSTALLED, 4001, "Plugin {0} not installed" +// MISSING_PLUGIN_ID, 4002, "Missing plugin id. Please input correct plugin id" +// MISSING_DATASOURCES_ID, 4003, "Missing datasource id. Please input correct datasource id" +// MISSING_PAGE_ID, 4004, "Missing page id. Pleaes input correct page id" +// PAGE_DOES_NOT_EXIST_IN_ORG, 4006, "Page {0} does not belong to the current user {1} organization." +// UNAUTHORIZED_DOMAIN, 4001, "Invalid email domain provided. Please sign in with a valid work email ID" +// INTERNAL_SERVER_ERROR, 5000, "Internal server error while processing request" +// REPOSITORY_SAVE_FAILED, 5001, "Repository save failed." diff --git a/app/taro/src/api/ApiUtils.ts b/app/taro/src/api/ApiUtils.ts new file mode 100644 index 0000000000..cce9f06a56 --- /dev/null +++ b/app/taro/src/api/ApiUtils.ts @@ -0,0 +1,147 @@ +import { + createMessage, + ERROR_0, + ERROR_500, + SERVER_API_TIMEOUT_ERROR, +} from "constants/messages"; +import axios, { AxiosRequestConfig, AxiosResponse } from "taro-axios"; +import { + API_STATUS_CODES, + ERROR_CODES, + SERVER_ERROR_CODES, +} from "constants/ApiConstants"; +import log from "loglevel"; +import { ActionExecutionResponse } from "api/ActionAPI"; +import { logoutUser } from "actions/userActions"; +import { AUTH_LOGIN_URL } from "constants/routes"; + +const executeActionRegex = /actions\/execute/; +const timeoutErrorRegex = /timeout of (\d+)ms exceeded/; +export const axiosConnectionAbortedCode = "ECONNABORTED"; + +// polyfill +const performance = Date; + +const makeExecuteActionResponse = (response: any): ActionExecutionResponse => ({ + ...response.data, + clientMeta: { + size: response.headers["content-length"], + duration: Number(performance.now() - response.config.timer).toFixed(), + }, +}); + +const is404orAuthPath = () => { + const pathName = window.location.pathname; + return /^\/404/.test(pathName) || /^\/user\/\w+/.test(pathName); +}; + +// Request interceptor will add a timer property to the request. +// this will be used to calculate the time taken for an action +// execution request +export const apiRequestInterceptor = (config: AxiosRequestConfig) => { + return { ...config, timer: performance.now() }; +}; + +// On success of an API, if the api is an action execution, +// add the client meta object with size and time taken info +// otherwise just return the data +export const apiSuccessResponseInterceptor = ( + response: AxiosResponse, +): AxiosResponse["data"] => { + if (response.config.url) { + if (response.config.url.match(executeActionRegex)) { + return makeExecuteActionResponse(response); + } + } + return response.data; +}; + +// Handle different api failure scenarios +export const apiFailureResponseInterceptor = (error: any) => { + // Return error when there is no internet + if (!window.navigator.onLine) { + return Promise.reject({ + ...error, + message: createMessage(ERROR_0), + }); + } + + // Return if the call was cancelled via cancel token + if (axios.isCancel(error)) { + return; + } + + // Return modified response if action execution failed + if (error.config && error.config.url.match(executeActionRegex)) { + return makeExecuteActionResponse(error.response); + } + // Return error if any timeout happened in other api calls + if ( + error.code === axiosConnectionAbortedCode && + error.message && + error.message.match(timeoutErrorRegex) + ) { + return Promise.reject({ + ...error, + message: createMessage(SERVER_API_TIMEOUT_ERROR), + code: ERROR_CODES.REQUEST_TIMEOUT, + }); + } + + if (error.response) { + if (error.response.status === API_STATUS_CODES.SERVER_ERROR) { + return Promise.reject({ + ...error, + code: ERROR_CODES.SERVER_ERROR, + message: createMessage(ERROR_500), + }); + } + + // The request was made and the server responded with a status code + // that falls out of the range of 2xx + if (!is404orAuthPath()) { + const currentUrl = `${window.location.href}`; + if (error.response.status === API_STATUS_CODES.REQUEST_NOT_AUTHORISED) { + // Redirect to login and set a redirect url. + console.log("redirect logout"); + // store.dispatch( + // logoutUser({ + // redirectURL: `${AUTH_LOGIN_URL}?redirectUrl=${encodeURIComponent( + // currentUrl, + // )}`, + // }), + // ); + return Promise.reject({ + code: ERROR_CODES.REQUEST_NOT_AUTHORISED, + message: "Unauthorized. Redirecting to login page...", + show: false, + }); + } + const errorData = error.response.data.responseMeta; + if ( + errorData.status === API_STATUS_CODES.RESOURCE_NOT_FOUND && + errorData.error.code === SERVER_ERROR_CODES.RESOURCE_NOT_FOUND + ) { + return Promise.reject({ + code: ERROR_CODES.PAGE_NOT_FOUND, + message: "Resource Not Found", + show: false, + }); + } + } + if (error.response.data.responseMeta) { + return Promise.resolve(error.response.data); + } + return Promise.reject(error.response.data); + } else if (error.request) { + // The request was made but no response was received + // `error.request` is an instance of XMLHttpRequest in the browser and an instance of + // http.ClientRequest in node.js + log.error(error.request); + } else { + // Something happened in setting up the request that triggered an Error + log.error("Error", error.message); + } + console.log(error.config); + return Promise.resolve(error); +}; diff --git a/app/taro/src/api/ApplicationApi.tsx b/app/taro/src/api/ApplicationApi.tsx new file mode 100644 index 0000000000..861148f0e9 --- /dev/null +++ b/app/taro/src/api/ApplicationApi.tsx @@ -0,0 +1,217 @@ +import Api from "api/Api"; +import { ApiResponse } from "./ApiResponses"; +import { AxiosPromise } from "taro-axios"; +import { AppLayoutConfig } from "reducers/entityReducers/pageListReducer"; + +export interface PublishApplicationRequest { + applicationId: string; +} + +export interface ChangeAppViewAccessRequest { + applicationId: string; + publicAccess: boolean; +} + +export interface PublishApplicationResponse extends ApiResponse { + data: unknown; +} + +export interface ApplicationPagePayload { + id: string; + name: string; + isDefault: boolean; +} + +export interface ApplicationResponsePayload { + id: string; + name: string; + organizationId: string; + pages?: ApplicationPagePayload[]; + appIsExample: boolean; + appLayout?: AppLayoutConfig; + unreadCommentThreads?: number; +} + +export interface FetchApplicationResponse extends ApiResponse { + data: ApplicationResponsePayload & { pages: ApplicationPagePayload[] }; +} + +export interface FetchApplicationsResponse extends ApiResponse { + data: Array; +} + +export interface SetDefaultPageRequest { + id: string; + applicationId: string; +} + +export interface DeleteApplicationRequest { + applicationId: string; +} + +export interface DuplicateApplicationRequest { + applicationId: string; +} + +export interface ForkApplicationRequest { + applicationId: string; + organizationId: string; +} + +export interface GetAllApplicationResponse extends ApiResponse { + data: Array; +} + +export type UpdateApplicationPayload = { + icon?: string; + color?: string; + name?: string; + currentApp?: boolean; + appLayout?: AppLayoutConfig; +}; + +export type UpdateApplicationRequest = UpdateApplicationPayload & { + id: string; +}; + +export interface ApplicationObject { + id: string; + name: string; + icon?: string; + color?: string; + organizationId: string; + pages: ApplicationPagePayload[]; + userPermissions: string[]; +} + +export interface UserRoles { + name: string; + roleName: string; + username: string; +} + +export interface OrganizationApplicationObject { + applications: Array; + organization: { + id: string; + name: string; + }; + userRoles: Array; +} +export interface FetchUsersApplicationsOrgsResponse extends ApiResponse { + data: { + organizationApplications: Array; + user: string; + newReleasesCount: string; + releaseItems: Array>; + }; +} + +export interface ImportApplicationRequest { + orgId: string; + applicationFile?: File; + progress?: (progressEvent: ProgressEvent) => void; + onSuccessCallback?: () => void; +} + +class ApplicationApi extends Api { + static baseURL = "v1/applications/"; + static publishURLPath = (applicationId: string) => `publish/${applicationId}`; + static createApplicationPath = (orgId: string) => `?orgId=${orgId}`; + static changeAppViewAccessPath = (applicationId: string) => + `${applicationId}/changeAccess`; + static setDefaultPagePath = (request: SetDefaultPageRequest) => + `${ApplicationApi.baseURL}${request.applicationId}/page/${request.id}/makeDefault`; + static publishApplication( + publishApplicationRequest: PublishApplicationRequest, + ): AxiosPromise { + return Api.post( + ApplicationApi.baseURL + + ApplicationApi.publishURLPath(publishApplicationRequest.applicationId), + undefined, + {}, + ); + } + static fetchApplications(): AxiosPromise { + return Api.get(ApplicationApi.baseURL); + } + + static getAllApplication(): AxiosPromise { + return Api.get(ApplicationApi.baseURL + "new"); + } + + static fetchApplication( + applicationId: string, + ): AxiosPromise { + return Api.get(ApplicationApi.baseURL + applicationId); + } + + static fetchApplicationForViewMode( + applicationId: string, + ): AxiosPromise { + return Api.get(ApplicationApi.baseURL + `view/${applicationId}`); + } + + static setDefaultApplicationPage( + request: SetDefaultPageRequest, + ): AxiosPromise { + return Api.put(ApplicationApi.setDefaultPagePath(request)); + } + + static changeAppViewAccess( + request: ChangeAppViewAccessRequest, + ): AxiosPromise { + return Api.put( + ApplicationApi.baseURL + + ApplicationApi.changeAppViewAccessPath(request.applicationId), + { publicAccess: request.publicAccess }, + ); + } + + static updateApplication( + request: UpdateApplicationRequest, + ): AxiosPromise { + const { id, ...rest } = request; + return Api.put(ApplicationApi.baseURL + id, rest); + } + + static deleteApplication( + request: DeleteApplicationRequest, + ): AxiosPromise { + return Api.delete(ApplicationApi.baseURL + request.applicationId); + } + + static duplicateApplication( + request: DuplicateApplicationRequest, + ): AxiosPromise { + return Api.post(ApplicationApi.baseURL + "clone/" + request.applicationId); + } + + static forkApplication( + request: ForkApplicationRequest, + ): AxiosPromise { + return Api.post( + "v1/applications/" + + request.applicationId + + "/fork/" + + request.organizationId, + ); + } + + static importApplicationToOrg( + request: ImportApplicationRequest, + ): AxiosPromise { + const formData = new FormData(); + if (request.applicationFile) { + formData.append("file", request.applicationFile); + } + return Api.post("v1/applications/import/" + request.orgId, formData, null, { + headers: { + "Content-Type": "multipart/form-data", + }, + onUploadProgress: request.progress, + }); + } +} + +export default ApplicationApi; diff --git a/app/taro/src/api/CollectionApi.ts b/app/taro/src/api/CollectionApi.ts new file mode 100644 index 0000000000..d8f9521f9d --- /dev/null +++ b/app/taro/src/api/CollectionApi.ts @@ -0,0 +1,12 @@ +import { AxiosPromise } from "taro-axios"; +import Api from "api/Api"; +import { ImportedCollections } from "constants/collectionsConstants"; + +class ImportedCollectionsApi extends Api { + static importedCollectionsURL = "v1/import/templateCollections"; + static fetchImportedCollections(): AxiosPromise { + return Api.get(ImportedCollectionsApi.importedCollectionsURL); + } +} + +export default ImportedCollectionsApi; diff --git a/app/taro/src/api/DatasourcesApi.ts b/app/taro/src/api/DatasourcesApi.ts new file mode 100644 index 0000000000..e8fc23aa7c --- /dev/null +++ b/app/taro/src/api/DatasourcesApi.ts @@ -0,0 +1,105 @@ +import { DEFAULT_TEST_DATA_SOURCE_TIMEOUT_MS } from "constants/ApiConstants"; +import API from "api/Api"; +import { GenericApiResponse } from "./ApiResponses"; +import { AxiosPromise } from "taro-axios"; + +import { DatasourceAuthentication, Datasource } from "entities/Datasource"; +export interface CreateDatasourceConfig { + name: string; + pluginId: string; + datasourceConfiguration: { + url: string; + databaseName?: string; + authentication?: DatasourceAuthentication; + }; + //Passed for logging purposes. + appName?: string; +} + +export interface EmbeddedRestDatasourceRequest { + datasourceConfiguration: { url: string }; + invalids: Array; + isValid: boolean; + name: string; + organizationId: string; + pluginId: string; +} + +type executeQueryData = Array<{ key: string; value?: string }>; + +export interface executeDatasourceQueryRequest { + datasourceId: string; + data: executeQueryData; +} + +class DatasourcesApi extends API { + static url = "v1/datasources"; + + static fetchDatasources( + orgId: string, + ): AxiosPromise> { + return API.get(DatasourcesApi.url + `?organizationId=${orgId}`); + } + + static createDatasource(datasourceConfig: Partial): Promise { + return API.post(DatasourcesApi.url, datasourceConfig); + } + + static testDatasource(datasourceConfig: Partial): Promise { + return API.post(`${DatasourcesApi.url}/test`, datasourceConfig, undefined, { + timeout: DEFAULT_TEST_DATA_SOURCE_TIMEOUT_MS, + }); + } + + static updateDatasource( + datasourceConfig: Partial, + id: string, + ): Promise { + return API.put(DatasourcesApi.url + `/${id}`, datasourceConfig); + } + + static deleteDatasource(id: string): Promise { + return API.delete(DatasourcesApi.url + `/${id}`); + } + + static fetchDatasourceStructure( + id: string, + ignoreCache = false, + ): Promise { + return API.get( + DatasourcesApi.url + `/${id}/structure?ignoreCache=${ignoreCache}`, + ); + } + + static fetchMockDatasources(): AxiosPromise< + GenericApiResponse + > { + return API.get(DatasourcesApi.url + "/mocks"); + } + + static addMockDbToDatasources( + name: string, + organizationId: string, + pluginId: string, + packageName: string, + ): Promise { + return API.post(DatasourcesApi.url + `/mocks`, { + name, + organizationId, + pluginId, + packageName, + }); + } + + static executeDatasourceQuery({ + data, + datasourceId, + }: executeDatasourceQueryRequest) { + return API.put( + DatasourcesApi.url + `/datasource-query` + `/${datasourceId}`, + data, + ); + } +} + +export default DatasourcesApi; diff --git a/app/taro/src/api/ImportApi.ts b/app/taro/src/api/ImportApi.ts new file mode 100644 index 0000000000..9a296b1240 --- /dev/null +++ b/app/taro/src/api/ImportApi.ts @@ -0,0 +1,27 @@ +import { AxiosPromise } from "taro-axios"; +import Api from "api/Api"; +import { ApiResponse } from "./ApiResponses"; + +export interface CurlImportRequest { + type: string; + pageId: string; + name: string; + curl: string; + organizationId: string; +} + +class CurlImportApi extends Api { + static curlImportURL = `v1/import`; + + static curlImport(request: CurlImportRequest): AxiosPromise { + const { curl, name, organizationId, pageId } = request; + return Api.post(CurlImportApi.curlImportURL, curl, { + type: "CURL", + pageId, + name, + organizationId, + }); + } +} + +export default CurlImportApi; diff --git a/app/taro/src/api/NotificationsAPI.tsx b/app/taro/src/api/NotificationsAPI.tsx new file mode 100644 index 0000000000..2d5e1f1139 --- /dev/null +++ b/app/taro/src/api/NotificationsAPI.tsx @@ -0,0 +1,33 @@ +import { AxiosPromise } from "taro-axios"; +import Api from "./Api"; +import { ApiResponse } from "./ApiResponses"; + +class NotificationsApi extends Api { + static baseURL = "v1/notifications"; + static markAsReadURL = `${NotificationsApi.baseURL}/isRead`; + static markAllAsReadURL = `${NotificationsApi.markAsReadURL}/all`; + static fetchUnreadNotificationsCountURL = `${NotificationsApi.baseURL}/count/unread`; + + static fetchNotifications(beforeDate?: string): AxiosPromise { + return Api.get(NotificationsApi.baseURL, beforeDate ? { beforeDate } : {}); + } + + static markAllNotificationsAsRead(): AxiosPromise { + return Api.patch(NotificationsApi.markAllAsReadURL, { isRead: true }); + } + + static fetchUnreadNotificationsCount(): AxiosPromise { + return Api.get(NotificationsApi.fetchUnreadNotificationsCountURL); + } + + static markNotificationsAsRead( + ids: Array, + ): AxiosPromise { + return Api.patch(NotificationsApi.markAsReadURL, { + isRead: true, + idList: ids, + }); + } +} + +export default NotificationsApi; diff --git a/app/taro/src/api/OrgApi.ts b/app/taro/src/api/OrgApi.ts new file mode 100644 index 0000000000..bc445aed05 --- /dev/null +++ b/app/taro/src/api/OrgApi.ts @@ -0,0 +1,132 @@ +import { AxiosPromise } from "taro-axios"; +import Api from "api/Api"; +import { ApiResponse } from "./ApiResponses"; +import { OrgRole, Org } from "constants/orgConstants"; + +export interface FetchOrgRolesResponse extends ApiResponse { + data: OrgRole[]; +} + +export interface FetchOrgsResponse extends ApiResponse { + data: Org[]; +} +export interface FetchOrgResponse extends ApiResponse { + data: Org; +} + +export interface FetchAllUsersResponse extends ApiResponse { + data: OrgRole[]; +} + +export interface FetchAllRolesResponse extends ApiResponse { + data: Org[]; +} + +export interface FetchOrgRequest { + orgId: string; + skipValidation?: boolean; +} + +export interface FetchAllUsersRequest { + orgId: string; +} + +export interface ChangeUserRoleRequest { + orgId: string; + role: string; + username: string; +} + +export interface DeleteOrgUserRequest { + orgId: string; + username: string; +} + +export interface FetchAllRolesRequest { + orgId: string; +} + +export interface SaveOrgRequest { + id: string; + name?: string; + website?: string; + email?: string; +} + +export interface SaveOrgLogo { + id: string; + logo: File; + progress: (progressEvent: ProgressEvent) => void; +} + +export interface CreateOrgRequest { + name: string; +} + +class OrgApi extends Api { + static rolesURL = "v1/groups"; + static orgsURL = "v1/organizations"; + static fetchRoles(): AxiosPromise { + return Api.get(OrgApi.rolesURL); + } + static fetchOrgs(): AxiosPromise { + return Api.get(OrgApi.orgsURL); + } + static fetchOrg(request: FetchOrgRequest): AxiosPromise { + return Api.get(OrgApi.orgsURL + "/" + request.orgId); + } + static saveOrg(request: SaveOrgRequest): AxiosPromise { + return Api.put(OrgApi.orgsURL + "/" + request.id, request); + } + static createOrg(request: CreateOrgRequest): AxiosPromise { + return Api.post(OrgApi.orgsURL, request); + } + static fetchAllUsers( + request: FetchAllUsersRequest, + ): AxiosPromise { + return Api.get(OrgApi.orgsURL + "/" + request.orgId + "/members"); + } + static fetchAllRoles( + request: FetchAllRolesRequest, + ): AxiosPromise { + return Api.get(OrgApi.orgsURL + `/roles?organizationId=${request.orgId}`); + } + static changeOrgUserRole( + request: ChangeUserRoleRequest, + ): AxiosPromise { + return Api.put(OrgApi.orgsURL + "/" + request.orgId + "/role", { + username: request.username, + roleName: request.role, + }); + } + static deleteOrgUser( + request: DeleteOrgUserRequest, + ): AxiosPromise { + return Api.put(OrgApi.orgsURL + "/" + request.orgId + "/role", { + username: request.username, + roleName: null, + }); + } + static saveOrgLogo(request: SaveOrgLogo): AxiosPromise { + const formData = new FormData(); + if (request.logo) { + formData.append("file", request.logo); + } + + return Api.post( + OrgApi.orgsURL + "/" + request.id + "/logo", + formData, + null, + { + headers: { + "Content-Type": "multipart/form-data", + }, + onUploadProgress: request.progress, + }, + ); + } + static deleteOrgLogo(request: { id: string }): AxiosPromise { + return Api.delete(OrgApi.orgsURL + "/" + request.id + "/logo"); + } +} +export default OrgApi; diff --git a/app/taro/src/api/PageApi.tsx b/app/taro/src/api/PageApi.tsx new file mode 100644 index 0000000000..feac337ac1 --- /dev/null +++ b/app/taro/src/api/PageApi.tsx @@ -0,0 +1,229 @@ +import Api from "api/Api"; +import { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { ApiResponse } from "./ApiResponses"; +import { WidgetProps } from "widgets/BaseWidget"; +import axios, { AxiosPromise, CancelTokenSource } from "taro-axios"; +import { PageAction } from "constants/AppsmithActionConstants/ActionConstants"; + +export interface FetchPageRequest { + id: string; + isFirstLoad?: boolean; +} + +export interface FetchPublishedPageRequest { + pageId: string; + bustCache?: boolean; +} + +export interface SavePageRequest { + dsl: ContainerWidgetProps; + layoutId: string; + pageId: string; +} + +export interface PageLayout { + id: string; + dsl: Partial>; + layoutOnLoadActions: PageAction[][]; + layoutActions: PageAction[]; +} + +export type FetchPageResponse = ApiResponse & { + data: { + id: string; + name: string; + applicationId: string; + layouts: Array; + }; +}; + +export type FetchPublishedPageResponse = ApiResponse & { + data: { + id: string; + dsl: Partial>; + pageId: string; + }; +}; + +export interface SavePageResponse extends ApiResponse { + data: { + id: string; + layoutOnLoadActions: PageAction[][]; + dsl: Partial>; + messages: string[]; + actionUpdates: Array<{ + executeOnLoad: boolean; + id: string; + name: string; + }>; + }; +} + +export interface CreatePageRequest { + applicationId: string; + name: string; + layouts: Partial[]; +} + +export interface UpdatePageRequest { + id: string; + name: string; + isHidden?: boolean; +} + +export interface CreatePageResponse extends ApiResponse { + data: unknown; +} + +export interface FetchPageListResponse extends ApiResponse { + data: { + pages: Array<{ + id: string; + name: string; + isDefault: boolean; + isHidden?: boolean; + layouts: Array; + icon?: string; + }>; + organizationId: string; + }; +} + +export interface DeletePageRequest { + id: string; +} + +export interface ClonePageRequest { + id: string; +} + +export interface UpdateWidgetNameRequest { + pageId: string; + layoutId: string; + newName: string; + oldName: string; +} + +export interface UpdateWidgetNameResponse extends ApiResponse { + data: PageLayout; +} + +export interface GenerateTemplatePageRequest { + pageId: string; + tableName: string; + datasourceId: string; + applicationId: string; + columns?: string[]; + searchColumn?: string; + mode?: string; +} + +export type GenerateTemplatePageRequestResponse = ApiResponse & { + data: { + id: string; + name: string; + applicationId: string; + layouts: Array; + }; +}; + +class PageApi extends Api { + static url = "v1/pages"; + static refactorLayoutURL = "v1/layouts/refactor"; + static pageUpdateCancelTokenSource?: CancelTokenSource = undefined; + static getLayoutUpdateURL = (pageId: string, layoutId: string) => { + return `v1/layouts/${layoutId}/pages/${pageId}`; + }; + + static getGenerateTemplateURL = (pageId?: string) => { + return `${PageApi.url}/crud-page${pageId ? `/${pageId}` : ""}`; + }; + + static getPublishedPageURL = (pageId: string, bustCache?: boolean) => { + const url = `v1/pages/${pageId}/view`; + return !!bustCache ? url + "?v=" + +new Date() : url; + }; + + static updatePageUrl = (pageId: string) => `${PageApi.url}/${pageId}`; + + static fetchPage( + pageRequest: FetchPageRequest, + ): AxiosPromise { + return Api.get(PageApi.url + "/" + pageRequest.id); + } + + static savePage( + savePageRequest: SavePageRequest, + ): AxiosPromise | undefined { + if (PageApi.pageUpdateCancelTokenSource) { + PageApi.pageUpdateCancelTokenSource.cancel(); + } + const body = { dsl: savePageRequest.dsl }; + PageApi.pageUpdateCancelTokenSource = axios.CancelToken.source(); + return Api.put( + PageApi.getLayoutUpdateURL( + savePageRequest.pageId, + savePageRequest.layoutId, + ), + body, + undefined, + { cancelToken: PageApi.pageUpdateCancelTokenSource.token }, + ); + } + + static fetchPublishedPage( + pageRequest: FetchPublishedPageRequest, + ): AxiosPromise { + return Api.get( + PageApi.getPublishedPageURL(pageRequest.pageId, pageRequest.bustCache), + ); + } + + static createPage( + createPageRequest: CreatePageRequest, + ): AxiosPromise { + return Api.post(PageApi.url, createPageRequest); + } + + static updatePage(request: UpdatePageRequest): AxiosPromise { + return Api.put(PageApi.updatePageUrl(request.id), request); + } + + static generateTemplatePage( + request: GenerateTemplatePageRequest, + ): AxiosPromise { + if (request.pageId) { + return Api.put(PageApi.getGenerateTemplateURL(request.pageId), request); + } else { + return Api.post(PageApi.getGenerateTemplateURL(), request); + } + } + + static fetchPageList( + applicationId: string, + ): AxiosPromise { + return Api.get(PageApi.url + "/application/" + applicationId); + } + + static fetchPageListViewMode( + applicationId: string, + ): AxiosPromise { + return Api.get(PageApi.url + "/view/application/" + applicationId); + } + + static deletePage(request: DeletePageRequest): AxiosPromise { + return Api.delete(PageApi.url + "/" + request.id); + } + + static clonePage(request: ClonePageRequest): AxiosPromise { + return Api.post(PageApi.url + "/clone/" + request.id); + } + + static updateWidgetName( + request: UpdateWidgetNameRequest, + ): AxiosPromise { + return Api.put(PageApi.refactorLayoutURL, request); + } +} + +export default PageApi; diff --git a/app/taro/src/api/PluginApi.ts b/app/taro/src/api/PluginApi.ts new file mode 100644 index 0000000000..a53d5d5204 --- /dev/null +++ b/app/taro/src/api/PluginApi.ts @@ -0,0 +1,48 @@ +import Api from "api/Api"; +import { AxiosPromise } from "taro-axios"; +import { GenericApiResponse } from "api/ApiResponses"; +import { PluginType } from "entities/Action"; +import { DependencyMap } from "utils/DynamicBindingUtils"; + +export type PluginId = string; +export type PluginPackageName = string; +export type GenerateCRUDEnabledPluginMap = Record; + +export interface Plugin { + id: string; + name: string; + type: PluginType; + packageName: string; + iconLocation?: string; + uiComponent: "ApiEditorForm" | "RapidApiEditorForm" | "DbEditorForm"; + datasourceComponent: "RestAPIDatasourceForm" | "AutoForm"; + allowUserDatasources?: boolean; + templates: Record; + responseType?: "TABLE" | "JSON"; + documentationLink?: string; + generateCRUDPageComponent?: string; +} + +export interface PluginFormPayload { + form: any[]; + editor: any[]; + setting: any[]; + dependencies: DependencyMap; +} + +class PluginsApi extends Api { + static url = "v1/plugins"; + static fetchPlugins( + orgId: string, + ): AxiosPromise> { + return Api.get(PluginsApi.url, { organizationId: orgId }); + } + + static fetchFormConfig( + id: string, + ): AxiosPromise> { + return Api.get(PluginsApi.url + `/${id}/form`); + } +} + +export default PluginsApi; diff --git a/app/taro/src/api/ProvidersApi.ts b/app/taro/src/api/ProvidersApi.ts new file mode 100644 index 0000000000..585198da48 --- /dev/null +++ b/app/taro/src/api/ProvidersApi.ts @@ -0,0 +1,126 @@ +import { AxiosPromise } from "taro-axios"; +import Api from "api/Api"; +import { ApiResponse } from "./ApiResponses"; +import { + Providers, + ProviderTemplates, + SearchResultsProviders, + ProvidersDataArray, +} from "constants/providerConstants"; + +export interface FetchProvidersResponse extends ApiResponse { + data: Providers; +} + +export interface FetchProviderDetailsResponse extends ApiResponse { + data: ProvidersDataArray; +} + +export interface FetchProviderCategoriesResponse extends ApiResponse { + data: string[]; +} + +export interface FetchProviderTemplateResponse extends ApiResponse { + data: ProviderTemplates[]; +} + +export interface SearchApiOrProviderResponse extends ApiResponse { + data: { + providers: SearchResultsProviders[]; + }; +} + +export interface FetchProviderTemplatesRequest { + providerId: string; +} + +export interface FetchProviderDetailsByProviderIdRequest { + providerId: string; +} + +export interface FetchProviderWithCategoryRequest { + category: string; + page: number; +} + +export interface SearchApiOrProviderRequest { + searchKey: string; +} + +export interface AddApiToPageRequest { + name: string; + pageId: string; + marketplaceElement: any; + organizationId?: string; + // Added for analytics + source?: string; +} + +export class ProvidersApi extends Api { + static providersURL = "v1/providers"; + static providerCategoriesURL = "v1/providers/categories"; + + static providerDetailsByIdURL = (providerId: string) => { + return `v1/marketplace/providers/${providerId}`; + }; + + static providerTemplateURL = (providerId: string) => { + return `v1/marketplace/templates?providerId=${providerId}`; + }; + + static searchApiOrProviderUrl = (searchKey: string) => { + return `v1/marketplace/search?searchKey=${searchKey}`; + }; + + static providersWithCategoryURL = (category: string, page: number) => { + return `v1/marketplace/providers?category=${category}&page=${page}&size=50`; + }; + + static addApiToPageURL = `v1/items/addToPage`; + + static fetchProviders(): AxiosPromise { + return Api.get(ProvidersApi.providersURL); + } + + static fetchProviderTemplates( + request: FetchProviderTemplatesRequest, + ): AxiosPromise { + const { providerId } = request; + return Api.get(ProvidersApi.providerTemplateURL(providerId)); + } + + static seachApiOrProvider( + request: SearchApiOrProviderRequest, + ): AxiosPromise { + const { searchKey } = request; + return Api.get(ProvidersApi.searchApiOrProviderUrl(searchKey)); + } + + static addApiToPage(request: AddApiToPageRequest): AxiosPromise { + return Api.post(ProvidersApi.addApiToPageURL, request); + } + + static fetchProvidersCategories(): AxiosPromise< + FetchProviderCategoriesResponse + > { + return Api.get(ProvidersApi.providerCategoriesURL); + } + + static fetchProvidersWithCategory( + request: FetchProviderWithCategoryRequest, + ): AxiosPromise { + const { page } = request; + return Api.get( + ProvidersApi.providersWithCategoryURL(request.category, page), + ); + } + + static fetchProviderDetailsByProviderId( + request: FetchProviderDetailsByProviderIdRequest, + ): AxiosPromise { + const { providerId } = request; + return Api.get(ProvidersApi.providerDetailsByIdURL(providerId)); + } +} + +export default ProvidersApi; diff --git a/app/taro/src/api/ReleasesAPI.tsx b/app/taro/src/api/ReleasesAPI.tsx new file mode 100644 index 0000000000..ab33ac312d --- /dev/null +++ b/app/taro/src/api/ReleasesAPI.tsx @@ -0,0 +1,13 @@ +import { AxiosPromise } from "taro-axios"; +import Api from "api/Api"; +import { ApiResponse } from "./ApiResponses"; + +class ReleasesAPI extends Api { + static markAsReadURL = `v1/users/setReleaseNotesViewed`; + + static markAsRead(): AxiosPromise { + return Api.put(ReleasesAPI.markAsReadURL); + } +} + +export default ReleasesAPI; diff --git a/app/taro/src/api/SaasApi.ts b/app/taro/src/api/SaasApi.ts new file mode 100644 index 0000000000..f2e6778484 --- /dev/null +++ b/app/taro/src/api/SaasApi.ts @@ -0,0 +1,25 @@ +import Api from "./Api"; +import { AxiosPromise } from "taro-axios"; +import { GenericApiResponse } from "api/ApiResponses"; +import { Datasource } from "entities/Datasource"; + +class SaasApi extends Api { + static url = "v1/saas"; + static getAppsmithToken( + datasourceId: string, + pageId: string, + ): AxiosPromise> { + return Api.post(`${SaasApi.url}/${datasourceId}/pages/${pageId}/oauth`); + } + + static getAccessToken( + datasourceId: string, + token: string, + ): AxiosPromise> { + return Api.post( + `${SaasApi.url}/${datasourceId}/token?appsmithToken=${token}`, + ); + } +} + +export default SaasApi; diff --git a/app/taro/src/api/UserApi.tsx b/app/taro/src/api/UserApi.tsx new file mode 100644 index 0000000000..8607b33094 --- /dev/null +++ b/app/taro/src/api/UserApi.tsx @@ -0,0 +1,155 @@ +import { AxiosPromise } from "taro-axios"; +import Api from "api/Api"; +import { ApiResponse } from "./ApiResponses"; + +export interface LoginUserRequest { + email: string; + password: string; +} + +export interface CreateUserRequest { + email: string; + password: string; +} + +export interface CreateUserResponse extends ApiResponse { + email: string; + id: string; +} + +export interface ForgotPasswordRequest { + email: string; +} + +export interface TokenPasswordUpdateRequest { + token: string; + password: string; + email: string; +} + +export interface VerifyTokenRequest { + email: string; + token: string; +} + +export interface FetchUserResponse extends ApiResponse { + id: string; +} + +export interface FetchUserRequest { + id: string; +} + +export interface LeaveOrgRequest { + orgId: string; +} + +export interface InviteUserRequest { + email: string; + groupIds: string[]; + status?: string; +} + +export interface UpdateUserRequest { + name?: string; + email?: string; +} + +class UserApi extends Api { + static usersURL = "v1/users"; + static forgotPasswordURL = `${UserApi.usersURL}/forgotPassword`; + static verifyResetPasswordTokenURL = `${UserApi.usersURL}/verifyPasswordResetToken`; + static resetPasswordURL = `${UserApi.usersURL}/resetPassword`; + static inviteUserURL = "v1/users/invite"; + static verifyInviteTokenURL = `${UserApi.inviteUserURL}/verify`; + static confirmUserInviteURL = `${UserApi.inviteUserURL}/confirm`; + static addOrgURL = `${UserApi.usersURL}/addOrganization`; + static leaveOrgURL = `${UserApi.usersURL}/leaveOrganization`; + static logoutURL = "v1/logout"; + static currentUserURL = "v1/users/me"; + static photoURL = "v1/users/photo"; + static featureFlagsURL = "v1/users/features"; + + static createUser( + request: CreateUserRequest, + ): AxiosPromise { + return Api.post(UserApi.usersURL, request); + } + + static updateUser(request: UpdateUserRequest): AxiosPromise { + return Api.put(UserApi.usersURL, request); + } + + static fetchUser(request: FetchUserRequest): AxiosPromise { + return Api.get(UserApi.usersURL + "/" + request.id); + } + + static getCurrentUser(): AxiosPromise { + return Api.get(UserApi.currentUserURL); + } + + static forgotPassword( + request: ForgotPasswordRequest, + ): AxiosPromise { + return Api.post(UserApi.forgotPasswordURL, request); + } + + static verifyResetPasswordToken( + request: VerifyTokenRequest, + ): AxiosPromise { + return Api.get(UserApi.verifyResetPasswordTokenURL, request); + } + + static resetPassword( + request: TokenPasswordUpdateRequest, + ): AxiosPromise { + return Api.put(UserApi.resetPasswordURL, request); + } + + static inviteUser(request: InviteUserRequest): AxiosPromise { + return Api.post(UserApi.inviteUserURL, request); + } + + static verifyUserInvite( + request: VerifyTokenRequest, + ): AxiosPromise { + return Api.get(UserApi.verifyInviteTokenURL, request); + } + + static confirmInvitedUserSignup( + request: TokenPasswordUpdateRequest, + ): AxiosPromise { + return Api.put(UserApi.confirmUserInviteURL, request); + } + + static logoutUser(): AxiosPromise { + return Api.post(UserApi.logoutURL); + } + + static uploadPhoto(request: { file: File }): AxiosPromise { + const formData = new FormData(); + if (request.file) { + formData.append("file", request.file); + } + + return Api.post(UserApi.photoURL, formData, null, { + headers: { + "Content-Type": "multipart/form-data", + }, + }); + } + + static deletePhoto(): AxiosPromise { + return Api.delete(UserApi.photoURL); + } + + static leaveOrg(request: LeaveOrgRequest): AxiosPromise { + return Api.put(UserApi.leaveOrgURL + "/" + request.orgId); + } + + static fetchFeatureFlags(): AxiosPromise { + return Api.get(UserApi.featureFlagsURL); + } +} + +export default UserApi; diff --git a/app/taro/src/api/WidgetConfigsApi.tsx b/app/taro/src/api/WidgetConfigsApi.tsx new file mode 100644 index 0000000000..4cc9fec12d --- /dev/null +++ b/app/taro/src/api/WidgetConfigsApi.tsx @@ -0,0 +1,18 @@ +import Api from "api/Api"; +import { WidgetType } from "constants/WidgetConstants"; +import { WidgetProps } from "widgets/BaseWidget"; +import { WidgetConfigProps } from "reducers/entityReducers/widgetConfigReducer"; +import { AxiosPromise } from "taro-axios"; + +export interface WidgetConfigsResponse { + config: Record & WidgetConfigProps>; +} + +class WidgetConfigsApi extends Api { + static url = "/widgetConfigs"; + static fetchWidgetConfigs(): AxiosPromise { + return Api.get(WidgetConfigsApi.url); + } +} + +export default WidgetConfigsApi; diff --git a/app/taro/src/api/WidgetSidebarApi.tsx b/app/taro/src/api/WidgetSidebarApi.tsx new file mode 100644 index 0000000000..563eca54ec --- /dev/null +++ b/app/taro/src/api/WidgetSidebarApi.tsx @@ -0,0 +1,17 @@ +import Api from "api/Api"; +import { WidgetCardProps } from "widgets/BaseWidget"; +import { AxiosPromise } from "taro-axios"; + +export interface WidgetSidebarResponse { + cards: { [id: string]: WidgetCardProps[] }; +} +// export interface WidgetCardsPaneRequest {} + +class WidgetSidebarApi extends Api { + static url = "/widgetCards"; + static fetchWidgetCards(): AxiosPromise { + return Api.get(WidgetSidebarApi.url); + } +} + +export default WidgetSidebarApi; diff --git a/app/taro/src/app.config.ts b/app/taro/src/app.config.ts new file mode 100644 index 0000000000..67f9a1a87b --- /dev/null +++ b/app/taro/src/app.config.ts @@ -0,0 +1,14 @@ +export default { + pages: [ + 'pages/index/index', + 'pages/page1/index', + ], + window: { + backgroundTextStyle: 'light', + navigationBarBackgroundColor: '#fff', + navigationBarTitleText: 'WeChat', + navigationBarTextStyle: 'black' + }, + workers: 'worker', + "lazyCodeLoading": "requiredComponents", +} diff --git a/app/taro/src/app.less b/app/taro/src/app.less new file mode 100644 index 0000000000..00aaa32c89 --- /dev/null +++ b/app/taro/src/app.less @@ -0,0 +1,17 @@ +.h5-span { + display: inline; +} + +view { + box-sizing: border-box; + line-height: 1.6; +} + +.rich-p { + margin: 0; + font-size: 0; +} + +.rich-img { + width: 100%; +} diff --git a/app/taro/src/app.tsx b/app/taro/src/app.tsx new file mode 100644 index 0000000000..d6462926f0 --- /dev/null +++ b/app/taro/src/app.tsx @@ -0,0 +1,25 @@ +import { Component } from "react"; +import { appInitializer } from "utils/AppsmithUtils"; + +import "./app.less"; + +// init +appInitializer(); + +class App extends Component { + componentDidMount() {} + + componentDidShow() {} + + componentDidHide() {} + + componentDidCatchError() {} + + // 在 App 类中的 render() 函数没有实际作用 + // 请勿修改此函数 + render() { + return this.props.children; + } +} + +export default App; diff --git a/app/taro/src/assets/images/placeholder-image.svg b/app/taro/src/assets/images/placeholder-image.svg new file mode 100644 index 0000000000..8c6be0447e --- /dev/null +++ b/app/taro/src/assets/images/placeholder-image.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/app/taro/src/components/common/AppPage.tsx b/app/taro/src/components/common/AppPage.tsx new file mode 100644 index 0000000000..c1ea63e1d0 --- /dev/null +++ b/app/taro/src/components/common/AppPage.tsx @@ -0,0 +1,35 @@ +import React, { useContext } from "react"; +import { styled } from "linaria/react"; +import { WidgetProps } from "widgets/BaseWidget"; +import { RenderModes } from "constants/WidgetConstants"; +import WidgetFactory from "utils/WidgetFactory"; +import { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { useDynamicAppLayout } from "utils/hooks/useDynamicAppLayout"; +import ReduxContext from "./ReduxContext"; + +const PageView = styled.div<{ width: number }>` + height: 100%; + position: relative; + width: ${(props) => props.width}px; + margin: 0 auto; +`; + +type AppPageProps = { + dsl: ContainerWidgetProps; + pageName?: string; + appName?: string; +}; + +export function AppPage(props: AppPageProps) { + const { useDispatch, useSelector, context } = useContext(ReduxContext); + const dispatch = useDispatch(); + useDynamicAppLayout(dispatch, useSelector); + return ( + + {props.dsl.widgetId && + WidgetFactory.createWidget({ ...props.dsl, context }, RenderModes.PAGE)} + + ); +} + +export default AppPage; diff --git a/app/taro/src/components/common/AppViewer.tsx b/app/taro/src/components/common/AppViewer.tsx new file mode 100644 index 0000000000..25289613d0 --- /dev/null +++ b/app/taro/src/components/common/AppViewer.tsx @@ -0,0 +1,113 @@ +import { useEffect, useContext } from "react"; +import { styled } from "linaria/react"; +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +import { getIsInitialized } from "selectors/appViewSelectors"; +import { executeAction } from "actions/widgetActions"; +import { ExecuteActionPayload } from "constants/AppsmithActionConstants/ActionConstants"; +import { + resetChildrenMetaProperty, + updateWidgetMetaProperty, +} from "actions/metaActions"; +import { getShowTabBar } from "selectors/editorSelectors"; +import { EditorContext } from "components/editorComponents/EditorContextProvider"; +import AppViewerPageContainer from "./AppViewerPageContainer"; +import { ConfigProvider } from "@taroify/core"; +import { taroifyTheme } from "constants/DefaultTheme"; +import TabBar from "components/designSystems/taro/TabBar"; +import Taro from "@tarojs/taro"; +import ReduxContext from "./ReduxContext"; +import { editorInitializer } from "utils/EditorUtils"; + +const AppViewerBody = styled.section<{ + showTabBar: boolean; +}>` + display: flex; + flex-direction: row; + align-items: stretch; + justify-content: flex-start; + height: calc( + 100vh - + ${(props) => + props.showTabBar ? "100rpx - constant(safe-area-inset-bottom)" : "0px"} + ); + height: calc( + 100vh - + ${(props) => + props.showTabBar ? "100rpx - env(safe-area-inset-bottom)" : "0px"} + ); +`; + +const ContainerWrapper = styled.div` + display: flex; + width: 100%; + height: 100%; + transform: translate(0, 0); +`; + +const AppViewerBodyContainer = styled.div` + flex: 1; + overflow: auto; + margin: 0 auto; +`; + +const LATEST_SCENE_APP_ID = "PAGEPLUG_LATEST_SCENE_APP_ID"; + +const AppViewer = () => { + const { useDispatch, useSelector } = useContext(ReduxContext); + const dispatch = useDispatch(); + const initializeAppViewer = (applicationId: string, pageId?: string) => { + dispatch({ + type: ReduxActionTypes.INITIALIZE_PAGE_VIEWER, + payload: { applicationId, pageId }, + }); + }; + const isInitialized = useSelector(getIsInitialized); + const showTabBar = useSelector(getShowTabBar); + + useEffect(() => { + const { applicationId, pageId, scene } = + Taro.getCurrentInstance().router?.params || {}; + editorInitializer(); + if (scene) { + Taro.setStorageSync(LATEST_SCENE_APP_ID, scene); + initializeAppViewer(scene); + } else if (applicationId) { + initializeAppViewer(applicationId, pageId); + } else { + const lastScene = Taro.getStorageSync(LATEST_SCENE_APP_ID); + initializeAppViewer(lastScene || DEFAULT_APP); + } + }, [dispatch]); + + return ( + + dispatch(executeAction(actionPayload)), + updateWidgetMetaProperty: ( + widgetId: string, + propertyName: string, + propertyValue: any + ) => + dispatch( + updateWidgetMetaProperty(widgetId, propertyName, propertyValue) + ), + resetChildrenMetaProperty: (widgetId: string) => + dispatch(resetChildrenMetaProperty(widgetId)), + }} + > + + + + + {isInitialized && } + + + + + + + ); +}; + +export default AppViewer; diff --git a/app/taro/src/components/common/AppViewerPageContainer.tsx b/app/taro/src/components/common/AppViewerPageContainer.tsx new file mode 100644 index 0000000000..87a47eabc8 --- /dev/null +++ b/app/taro/src/components/common/AppViewerPageContainer.tsx @@ -0,0 +1,85 @@ +import React, { useContext } from "react"; +import { getIsFetchingPage } from "selectors/appViewSelectors"; +import { styled } from "linaria/react"; +import { Loading, SafeArea } from "@taroify/core"; +import AppPage from "./AppPage"; +import { + getCanvasWidgetDsl, + getCurrentPageName, +} from "selectors/editorSelectors"; +import { getCurrentApplication } from "selectors/applicationSelectors"; +import ReduxContext from "./ReduxContext"; + +const LoadingContainer = styled.div` + display: flex; + justify-content: center; + align-items: center; + height: 100vh; + width: 100%; + + .taroify-loading { + color: var(--primary-color); + + .taroify-loading__text { + color: var(--primary-color); + } + } +`; + +const Section = styled.section` + background: #f6f6f6; + height: max-content; + min-height: 100%; + margin: 0 auto; + position: relative; + overflow-x: auto; + overflow-y: auto; +`; + +const SafeFixedArea = styled.div<{ + height: number; +}>` + margin-bottom: ${(props) => props.height}px; +`; + +const AppViewerPageContainer: any = () => { + const { useSelector } = useContext(ReduxContext); + const currentApp = useSelector(getCurrentApplication); + const widgets = useSelector(getCanvasWidgetDsl); + const isFetchingPage = useSelector(getIsFetchingPage); + const currentPageName = useSelector(getCurrentPageName); + const currentAppName = currentApp?.name; + const hasFixedWidget = widgets.children?.find( + (w) => w.type === "TARO_BOTTOM_BAR_WIDGET" + ); + + const pageNotFound =
页面空空如也😅
; + if (isFetchingPage) { + return ( + + + + ); + } else if ( + !isFetchingPage && + !(widgets && widgets.children && widgets.children.length > 0) + ) { + return pageNotFound; + } else if (!isFetchingPage && widgets) { + return ( +
+ + {hasFixedWidget ? ( + + ) : null} + +
+ ); + } +}; + +export default AppViewerPageContainer; diff --git a/app/taro/src/components/common/PageFactory.tsx b/app/taro/src/components/common/PageFactory.tsx new file mode 100644 index 0000000000..322263c89a --- /dev/null +++ b/app/taro/src/components/common/PageFactory.tsx @@ -0,0 +1,33 @@ +import React from "react"; +import { + Provider, + createStoreHook, + createDispatchHook, + createSelectorHook, +} from "react-redux"; +import { newStore } from "store"; +import AppViewer from "./AppViewer"; +import ReduxContext from "./ReduxContext"; + +const Page = () => { + const context: any = React.createContext(null); + const useStore = createStoreHook(context); + const useDispatch = createDispatchHook(context); + const useSelector = createSelectorHook(context); + const store = newStore(); + const contextValue = { + useStore, + useSelector, + useDispatch, + context, + }; + return ( + + + + + + ); +}; + +export default Page; diff --git a/app/taro/src/components/common/ReduxContext.ts b/app/taro/src/components/common/ReduxContext.ts new file mode 100644 index 0000000000..b71d2e98fc --- /dev/null +++ b/app/taro/src/components/common/ReduxContext.ts @@ -0,0 +1,15 @@ +import React from "react"; + +const noop = () => {}; +const ReduxContext = React.createContext<{ + useStore: any; + useSelector: any; + useDispatch: any; + context: any; +}>({ + useStore: noop, + useSelector: noop, + useDispatch: noop, + context: null, +}); +export default ReduxContext; diff --git a/app/taro/src/components/designSystems/appsmith/BaseComponent.tsx b/app/taro/src/components/designSystems/appsmith/BaseComponent.tsx new file mode 100644 index 0000000000..df8670eab4 --- /dev/null +++ b/app/taro/src/components/designSystems/appsmith/BaseComponent.tsx @@ -0,0 +1,17 @@ +import { Component } from "react"; +import { Color } from "constants/Colors"; + +/*** + * Components are responsible for binding render inputs to corresponding UI SDKs + */ +abstract class BaseComponent extends Component {} + +export interface ComponentProps { + widgetId: string; + widgetName?: string; + isDisabled?: boolean; + isVisible?: boolean; + backgroundColor?: Color; +} + +export default BaseComponent; diff --git a/app/taro/src/components/designSystems/appsmith/ContainerComponent.tsx b/app/taro/src/components/designSystems/appsmith/ContainerComponent.tsx new file mode 100644 index 0000000000..be005eaf6b --- /dev/null +++ b/app/taro/src/components/designSystems/appsmith/ContainerComponent.tsx @@ -0,0 +1,47 @@ +import React, { ReactNode, useRef, RefObject } from "react"; +import { styled } from "linaria/react"; +import { ComponentProps } from "./BaseComponent"; +import { Color } from "constants/Colors"; + +const StyledContainerComponent: any = styled.div` + height: 100%; + width: 100%; + background: ${(props) => props.backgroundColor || "unset"}; + opacity: ${(props) => (props.resizeDisabled ? "0.8" : "1")}; + position: relative; + box-shadow: ${(props) => + props.selected ? "0px 0px 0px 3px rgba(59,130,246,0.5)" : "none"}; + z-index: ${(props) => (props.focused ? "3" : props.selected ? "2" : "1")}; +`; + +function ContainerComponent(props: ContainerComponentProps) { + const containerStyle = props.containerStyle || "card"; + const containerRef: RefObject = useRef(null); + return ( + + {props.children} + + ); +} + +export type ContainerStyle = "border" | "card" | "rounded-border" | "none"; + +export interface ContainerComponentProps extends ComponentProps { + containerStyle?: ContainerStyle; + children?: ReactNode; + className?: string; + backgroundColor?: Color; + shouldScrollContents?: boolean; + resizeDisabled?: boolean; + selected?: boolean; + focused?: boolean; + minHeight?: number; +} + +export default ContainerComponent; diff --git a/app/taro/src/components/designSystems/appsmith/PositionedContainer.tsx b/app/taro/src/components/designSystems/appsmith/PositionedContainer.tsx new file mode 100644 index 0000000000..3d7f214dbf --- /dev/null +++ b/app/taro/src/components/designSystems/appsmith/PositionedContainer.tsx @@ -0,0 +1,75 @@ +import React, { CSSProperties, ReactNode, useMemo } from "react"; +import { BaseStyle } from "widgets/BaseWidget"; +import { WIDGET_PADDING } from "constants/WidgetConstants"; +import { generateClassName } from "utils/generators"; +import { styled } from 'linaria/react'; +import { Layers } from "constants/Layers"; + +const PositionedWidget = styled.div` + &:hover { + z-index: 2 !important; + } +`; +type PositionedContainerProps = { + style: BaseStyle; + children: ReactNode; + widgetId: string; + widgetType: string; + selected?: boolean; + focused?: boolean; + resizeDisabled?: boolean; +}; + +export function PositionedContainer(props: PositionedContainerProps) { + const x = props.style.xPosition + (props.style.xPositionUnit || "px"); + const y = props.style.yPosition + (props.style.yPositionUnit || "px"); + const padding = WIDGET_PADDING; + // memoized classname + const containerClassName = useMemo(() => { + return ( + generateClassName(props.widgetId) + + " positioned-widget " + + `t--widget-${props.widgetType + .split("_") + .join("") + .toLowerCase()}` + ); + }, [props.widgetType, props.widgetId]); + const containerStyle: CSSProperties = useMemo(() => { + return { + position: "absolute", + left: x, + top: y, + height: props.style.componentHeight + (props.style.heightUnit || "px"), + width: props.style.componentWidth + (props.style.widthUnit || "px"), + padding: padding + "px", + zIndex: + props.selected || props.focused + ? Layers.selectedWidget + : Layers.positionedWidget, + backgroundColor: "inherit", + }; + }, [props.style]); + + const stopEventPropagation = (e: any) => { + e.stopPropagation(); + }; + + return ( + + {props.children} + + ); +} + +PositionedContainer.padding = WIDGET_PADDING; + +export default PositionedContainer; diff --git a/app/taro/src/components/designSystems/appsmith/TableComponent/Constants.ts b/app/taro/src/components/designSystems/appsmith/TableComponent/Constants.ts new file mode 100644 index 0000000000..e031790926 --- /dev/null +++ b/app/taro/src/components/designSystems/appsmith/TableComponent/Constants.ts @@ -0,0 +1,225 @@ +import { isString } from "lodash"; +import dayjs from "dayjs"; +import { TextSize } from "constants/WidgetConstants"; + +export type TableSizes = { + COLUMN_HEADER_HEIGHT: number; + TABLE_HEADER_HEIGHT: number; + ROW_HEIGHT: number; + ROW_FONT_SIZE: number; +}; + +export enum CompactModeTypes { + SHORT = "SHORT", + DEFAULT = "DEFAULT", + TALL = "TALL", +} + +export enum CellAlignmentTypes { + LEFT = "LEFT", + RIGHT = "RIGHT", + CENTER = "CENTER", +} + +export enum VerticalAlignmentTypes { + TOP = "TOP", + BOTTOM = "BOTTOM", + CENTER = "CENTER", +} + +export const TABLE_SIZES: { [key: string]: TableSizes } = { + [CompactModeTypes.DEFAULT]: { + COLUMN_HEADER_HEIGHT: 32, + TABLE_HEADER_HEIGHT: 38, + ROW_HEIGHT: 40, + ROW_FONT_SIZE: 14, + }, + [CompactModeTypes.SHORT]: { + COLUMN_HEADER_HEIGHT: 32, + TABLE_HEADER_HEIGHT: 38, + ROW_HEIGHT: 20, + ROW_FONT_SIZE: 12, + }, + [CompactModeTypes.TALL]: { + COLUMN_HEADER_HEIGHT: 32, + TABLE_HEADER_HEIGHT: 38, + ROW_HEIGHT: 60, + ROW_FONT_SIZE: 18, + }, +}; + +export enum ColumnTypes { + DATE = "date", + VIDEO = "video", + IMAGE = "image", + TEXT = "text", + NUMBER = "number", + URL = "url", +} + +export enum OperatorTypes { + OR = "OR", + AND = "AND", +} + +export interface TableStyles { + cellBackground?: string; + textColor?: string; + textSize?: TextSize; + fontStyle?: string; + horizontalAlignment?: CellAlignment; + verticalAlignment?: VerticalAlignment; +} + +export type CompactMode = keyof typeof CompactModeTypes; +export type Condition = keyof typeof ConditionFunctions | ""; +export type Operator = keyof typeof OperatorTypes; +export type CellAlignment = keyof typeof CellAlignmentTypes; +export type VerticalAlignment = keyof typeof VerticalAlignmentTypes; + +export interface ReactTableFilter { + column: string; + operator: Operator; + condition: Condition; + value: any; +} + +export interface CellLayoutProperties { + horizontalAlignment?: CellAlignment; + verticalAlignment?: VerticalAlignment; + textSize?: TextSize; + fontStyle?: string; + textColor?: string; + cellBackground?: string; + buttonStyle?: string; + buttonLabelColor?: string; + buttonLabel?: string; + displayText?: string; +} + +export interface TableColumnMetaProps { + isHidden: boolean; + format?: string; + inputFormat?: string; + type: string; +} + +export interface TableColumnProps { + Header: string; + accessor: string; + width?: number; + minWidth: number; + draggable: boolean; + isHidden?: boolean; + isAscOrder?: boolean; + metaProperties?: TableColumnMetaProps; + isDerived?: boolean; + columnProperties: ColumnProperties; +} +export interface ReactTableColumnProps extends TableColumnProps { + Cell: (props: any) => JSX.Element; +} + +export interface ColumnProperties { + id: string; + label: string; + columnType: string; + isVisible: boolean; + index: number; + width: number; + cellBackground?: string; + horizontalAlignment?: CellAlignment; + verticalAlignment?: VerticalAlignment; + textSize?: TextSize; + fontStyle?: string; + textColor?: string; + enableFilter?: boolean; + enableSort?: boolean; + isDerived: boolean; + computedValue: string; + buttonLabel?: string; + buttonStyle?: string; + buttonLabelColor?: string; + onClick?: string; + outputFormat?: string; + inputFormat?: string; + dropdownOptions?: string; + onOptionChange?: string; + displayText?: string; +} + +export const ConditionFunctions: { + [key: string]: (a: any, b: any) => boolean; +} = { + isExactly: (a: any, b: any) => { + return a.toString() === b.toString(); + }, + empty: (a: any) => { + return a === "" || a === undefined || a === null; + }, + notEmpty: (a: any) => { + return a !== "" && a !== undefined && a !== null; + }, + notEqualTo: (a: any, b: any) => { + return a.toString() !== b.toString(); + }, + isEqualTo: (a: any, b: any) => { + return a.toString() === b.toString(); + }, + lessThan: (a: any, b: any) => { + const numericB = Number(b); + const numericA = Number(a); + return numericA < numericB; + }, + lessThanEqualTo: (a: any, b: any) => { + const numericB = Number(b); + const numericA = Number(a); + return numericA <= numericB; + }, + greaterThan: (a: any, b: any) => { + const numericB = Number(b); + const numericA = Number(a); + return numericA > numericB; + }, + greaterThanEqualTo: (a: any, b: any) => { + const numericB = Number(b); + const numericA = Number(a); + return numericA >= numericB; + }, + contains: (a: any, b: any) => { + if (isString(a) && isString(b)) { + return a.includes(b); + } + return false; + }, + doesNotContain: (a: any, b: any) => { + if (isString(a) && isString(b)) { + return !a.includes(b); + } + return false; + }, + startsWith: (a: any, b: any) => { + if (isString(a) && isString(b)) { + return a.indexOf(b) === 0; + } + return false; + }, + endsWith: (a: any, b: any) => { + if (isString(a) && isString(b)) { + return a.length === a.lastIndexOf(b) + b.length; + } + return false; + }, + is: (a: any, b: any) => { + return dayjs(a).isSame(dayjs(b), "day"); + }, + isNot: (a: any, b: any) => { + return !dayjs(a).isSame(dayjs(b), "day"); + }, + isAfter: (a: any, b: any) => { + return !dayjs(a).isAfter(dayjs(b), "day"); + }, + isBefore: (a: any, b: any) => { + return !dayjs(a).isBefore(dayjs(b), "day"); + }, +}; diff --git a/app/taro/src/components/designSystems/appsmith/TableComponent/TableHelpers.ts b/app/taro/src/components/designSystems/appsmith/TableComponent/TableHelpers.ts new file mode 100644 index 0000000000..60f988c5ed --- /dev/null +++ b/app/taro/src/components/designSystems/appsmith/TableComponent/TableHelpers.ts @@ -0,0 +1,50 @@ +import { uniq, without } from "lodash"; +import { ColumnProperties } from "./Constants"; + +export const removeSpecialChars = (value: string, limit?: number) => { + const separatorRegex = /\s/; + return value + .split(separatorRegex) + .join("_") + .slice(0, limit || 30); +}; + +export const getAllTableColumnKeys = ( + tableData?: Array>, +) => { + const columnKeys: string[] = []; + if (tableData) { + for (let i = 0, tableRowCount = tableData.length; i < tableRowCount; i++) { + const row = tableData[i]; + for (const key in row) { + // Replace all special characters to _, limit key length to 200 characters. + const sanitizedKey = removeSpecialChars(key, 200); + if (!columnKeys.includes(sanitizedKey)) { + columnKeys.push(sanitizedKey); + } + } + } + } + return columnKeys; +}; + +export const reorderColumns = ( + columns: Record, + columnOrder: string[], +) => { + const newColumnsInOrder: Record = {}; + uniq(columnOrder).forEach((id: string, index: number) => { + if (columns[id]) newColumnsInOrder[id] = { ...columns[id], index }; + }); + const remaining = without( + Object.keys(columns), + ...Object.keys(newColumnsInOrder), + ); + const len = Object.keys(newColumnsInOrder).length; + if (remaining && remaining.length > 0) { + remaining.forEach((id: string, index: number) => { + newColumnsInOrder[id] = { ...columns[id], index: len + index }; + }); + } + return newColumnsInOrder; +}; diff --git a/app/taro/src/components/designSystems/taro/ActionBar/ActionBar.tsx b/app/taro/src/components/designSystems/taro/ActionBar/ActionBar.tsx new file mode 100644 index 0000000000..26fa9ac0d5 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/ActionBar.tsx @@ -0,0 +1,37 @@ +import React, { useContext, useMemo } from "react"; +import clsx from "clsx"; +import { ActionBarProps } from "./PropsType"; +import ActionBarContext from "./ActionBarContext"; +import { BEM, createBEM } from "../SkuComponent/bem"; + +const ActionBar: React.FC = (props: any) => { + const bem = createBEM("rv-action-bar"); + const children = useMemo(() => React.Children.toArray(props.children), [ + props.children, + ]); + + return ( + +
+ {React.Children.toArray(props.children) + .filter(Boolean) + .map((child: any, index: number) => + React.cloneElement(child, { + index, + }), + )} +
+
+ ); +}; + +ActionBar.defaultProps = { + safeAreaInsetBottom: true, +}; + +export default ActionBar; diff --git a/app/taro/src/components/designSystems/taro/ActionBar/ActionBarButton.tsx b/app/taro/src/components/designSystems/taro/ActionBar/ActionBarButton.tsx new file mode 100644 index 0000000000..3cad97e1c0 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/ActionBarButton.tsx @@ -0,0 +1,63 @@ +import React, { useContext, useMemo } from "react"; +import clsx from "clsx"; +import { ActionBarButtonProps } from "./PropsType"; +import { Button } from "@taroify/core"; +import ActionBarContext from "./ActionBarContext"; +import { BEM, createBEM } from "../SkuComponent/bem"; + +const ActionBarButton: React.FC = (props) => { + const { type, icon, text, color, loading, disabled, index } = props; + const bem = createBEM("rv-action-bar-button"); + const { parent } = useContext(ActionBarContext); + + const isFirst = useMemo(() => { + if (parent && typeof index !== "undefined") { + const prev = parent.children[index - 1]; + return !(prev && "isButton" in prev.type); + } + return false; + }, [index, parent]); + + const isLast = useMemo(() => { + if (parent && typeof index !== "undefined") { + const next = parent.children[index + 1]; + return !(next && "isButton" in next.type); + } + return false; + }, [index, parent]); + + const style = { + "--rv-action-bar-theme-color": color || "unset", + ...props.style, + }; + + return ( + + ); +}; + +const ActionBarButtonNameSpace = Object.assign(ActionBarButton, { + isButton: true, +}); + +export default ActionBarButtonNameSpace; diff --git a/app/taro/src/components/designSystems/taro/ActionBar/ActionBarContext.ts b/app/taro/src/components/designSystems/taro/ActionBar/ActionBarContext.ts new file mode 100644 index 0000000000..aa2d225a04 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/ActionBarContext.ts @@ -0,0 +1,9 @@ +import { createContext, Context } from "react"; + +export interface ActionBarState { + parent?: Record; +} + +const ActionButtonContext: Context = createContext({}); + +export default ActionButtonContext; diff --git a/app/taro/src/components/designSystems/taro/ActionBar/ActionBarIcon.tsx b/app/taro/src/components/designSystems/taro/ActionBar/ActionBarIcon.tsx new file mode 100644 index 0000000000..8711f6f9a1 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/ActionBarIcon.tsx @@ -0,0 +1,38 @@ +import React, { isValidElement } from "react"; +import clsx from "clsx"; +import { ActionBarIconProps } from "./PropsType"; +import { createVanIconComponent } from "@taroify/icons/van"; +import { Badge } from "@taroify/core"; +import { BEM, createBEM } from "../SkuComponent/bem"; + +const ActionBarIcon: React.FC = (props) => { + const bem = createBEM("rv-action-bar-icon"); + + const renderIcon = () => { + const { badge, icon, color } = props; + let iconContent = icon; + if (typeof icon === "string") { + const Icon = createVanIconComponent(icon); + iconContent = ; + } + if (isValidElement(iconContent)) { + return {iconContent}; + } + return null; + }; + + return ( +
+ {renderIcon()} + {props.children || props.text} +
+ ); +}; + +export default ActionBarIcon; diff --git a/app/taro/src/components/designSystems/taro/ActionBar/PropsType.ts b/app/taro/src/components/designSystems/taro/ActionBar/PropsType.ts new file mode 100644 index 0000000000..40605a907c --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/PropsType.ts @@ -0,0 +1,45 @@ +import React, { CSSProperties } from "react"; + +export interface BaseTypeProps { + style?: CSSProperties | any; + className?: string; +} + +export interface ActionBarProps extends BaseTypeProps { + /** 是否开启底部安全区适配 */ + safeAreaInsetBottom?: boolean; +} + +export interface ActionBarIconProps extends BaseTypeProps { + /** 按钮文字 */ + text?: React.ReactNode; + /** 图标 */ + icon?: string | React.ReactNode; + /** 图标颜色 */ + color?: string; + /** 图标额外类名 */ + iconClass?: string; + /** 图标类名前缀,等同于 Icon 组件的 class-prefix 属性 */ + iconPrefix?: string; + /** 图标右上角徽标的内容 */ + badge?: any; + onClick?: (event: any) => void; +} + +export interface ActionBarButtonProps extends BaseTypeProps { + /** 按钮文字 */ + text?: React.ReactNode; + /** 按钮类型 */ + type?: any; + /** 按钮图标 */ + icon?: string | React.ReactNode; + /** 按钮颜色,支持传入 linear-gradient 渐变色 */ + color?: string; + /** 是否禁用按钮 */ + disabled?: boolean; + /** 是否显示为加载状态 */ + loading?: boolean; + onClick?: (event: any) => void; + /** @private */ + index?: number; +} diff --git a/app/taro/src/components/designSystems/taro/ActionBar/index.tsx b/app/taro/src/components/designSystems/taro/ActionBar/index.tsx new file mode 100644 index 0000000000..a6591a8f79 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/index.tsx @@ -0,0 +1,12 @@ +import ActionBar from "./ActionBar"; +import ActionBarIcon from "./ActionBarIcon"; +import ActionBarButton from "./ActionBarButton"; +import "./style/index.less"; + +const ActionBarNamespace = Object.assign(ActionBar, { + Icon: ActionBarIcon, + Button: ActionBarButton, +}); + +export { ActionBarNamespace as ActionBar, ActionBarIcon, ActionBarButton }; +export default ActionBarNamespace; diff --git a/app/taro/src/components/designSystems/taro/ActionBar/style/index.less b/app/taro/src/components/designSystems/taro/ActionBar/style/index.less new file mode 100644 index 0000000000..958b68ca54 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/style/index.less @@ -0,0 +1,104 @@ +@import './var.less'; + +.@{rv-prefix}-action-bar { + --rv-action-bar-theme-color: @red; + --rv-action-bar-background-color: @action-bar-background-color; + --rv-action-bar-height: @action-bar-height; + --rv-action-bar-button-height: @action-bar-button-height; + --rv-action-bar-icon-width: @action-bar-icon-width; + --rv-action-bar-icon-height: @action-bar-icon-height; + --rv-action-bar-icon-color: @action-bar-icon-color; + --rv-action-bar-icon-size: @action-bar-icon-size; + --rv-action-bar-icon-font-size: @action-bar-icon-font-size; + --rv-action-bar-icon-active-color: @action-bar-icon-active-color; + --rv-action-bar-icon-text-color: @action-bar-icon-text-color; + --rv-action-bar-icon-background-color: @action-bar-icon-background-color; + + position: absolute; + right: 0; + bottom: 0; + left: 0; + display: flex; + align-items: center; + box-sizing: content-box; + height: var(--rv-action-bar-height); + background-color: var(--rv-action-bar-background-color); +} + +.@{rv-prefix}-action-bar-button { + flex: 1; + height: var(--rv-action-bar-button-height); + font-weight: @font-weight-bold; + font-size: @font-size-md; + border: none; + border-radius: 0; + + &--first { + margin-left: 5 * @hd; + border-top-left-radius: @border-radius-max; + border-bottom-left-radius: @border-radius-max; + } + + &--last { + margin-right: 5 * @hd; + border-top-right-radius: @border-radius-max; + border-bottom-right-radius: @border-radius-max; + } + + &--warning { + background: transparent; + color: var(--rv-action-bar-theme-color); + + &::after { + position: absolute; + top: 50%; + left: 50%; + width: 100%; + height: 100%; + content: ' '; + transform: translate(-50%, -50%); + background: currentColor; + opacity: 0.2; + border-color: currentColor; + border-style: inherit; + border-width: inherit; + border-radius: inherit; + } + } + + &--danger { + background: var(--rv-action-bar-theme-color); + } + + @media (max-width: 321px) { + font-size: 13 * @hd; + } +} + +.@{rv-prefix}-action-bar-icon { + display: flex; + flex-direction: column; + justify-content: center; + min-width: var(--rv-action-bar-icon-width); + height: var(--rv-action-bar-icon-height); + color: var(--rv-action-bar-icon-text-color); + font-size: var(--rv-action-bar-icon-font-size); + line-height: 1; + text-align: center; + background-color: var(--rv-action-bar-icon-background-color); + cursor: pointer; + + & > .taroify-badge-wrapper { + align-self: center; + } + + &:active { + background-color: var(--rv-action-bar-icon-active-color); + } + + &__icon { + margin: 0 auto @padding-base; + color: var(--rv-action-bar-icon-color); + font-size: var(--rv-action-bar-icon-size); + } +} diff --git a/app/taro/src/components/designSystems/taro/ActionBar/style/var.less b/app/taro/src/components/designSystems/taro/ActionBar/style/var.less new file mode 100644 index 0000000000..55205d5528 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ActionBar/style/var.less @@ -0,0 +1,17 @@ +@import '../../rvStyle/var.less'; + +@action-bar-background-color: transparent; +@action-bar-height: 50 * @hd; + +@action-bar-button-height: 40 * @hd; +@action-bar-button-warning-color: @gradient-orange; +@action-bar-button-danger-color: @gradient-red; + +@action-bar-icon-width: 48 * @hd; +@action-bar-icon-height: 100%; +@action-bar-icon-color: @text-color; +@action-bar-icon-size: 18 * @hd; +@action-bar-icon-font-size: @font-size-xs; +@action-bar-icon-active-color: @active-color; +@action-bar-icon-text-color: @gray-7; +@action-bar-icon-background-color: transparent; diff --git a/app/taro/src/components/designSystems/taro/BottomBarComponent.tsx b/app/taro/src/components/designSystems/taro/BottomBarComponent.tsx new file mode 100644 index 0000000000..e93abaf1de --- /dev/null +++ b/app/taro/src/components/designSystems/taro/BottomBarComponent.tsx @@ -0,0 +1,63 @@ +import React, { ReactNode, useContext } from "react"; +import { styled } from "linaria/react"; +import { getCanvasClassName } from "utils/generators"; +import { Popup } from "@taroify/core"; +import { PopupProps } from "@taroify/core/popup/popup"; +import { getShowTabBar } from "selectors/editorSelectors"; +import ReduxContext from "components/common/ReduxContext"; +import { transformDynamicSize } from "utils/AppsmithUtils"; + +const Container = styled(Popup)< + { + height: number; + showTabBar: boolean; + } & PopupProps +>` + height: calc( + ${(props) => transformDynamicSize(props.height)} + + ${(props) => + props.showTabBar ? "0px" : "constant(safe-area-inset-bottom)"} + ); + height: calc( + ${(props) => transformDynamicSize(props.height)} + + ${(props) => (props.showTabBar ? "0px" : "env(safe-area-inset-bottom)")} + ); + max-height: 200px; + min-height: 80px; + overflow: visible; + background: #fff; + z-index: 1009; +`; + +const Content = styled.div` + width: 100%; + height: 100%; +`; + +export type BottomBarComponentProps = { + children: ReactNode; + className?: string; + height?: number; +}; + +/* eslint-disable react/display-name */ +export function BottomBarComponent(props: BottomBarComponentProps) { + const { useSelector } = useContext(ReduxContext); + const showTabBar = useSelector(getShowTabBar); + return ( + + + + {props.children} + + + ); +} + +export default BottomBarComponent; diff --git a/app/taro/src/components/designSystems/taro/ButtonComponent.tsx b/app/taro/src/components/designSystems/taro/ButtonComponent.tsx new file mode 100644 index 0000000000..620dc89fb5 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ButtonComponent.tsx @@ -0,0 +1,56 @@ +import React from "react"; +import { Button } from "@taroify/core"; +import { transformDynamicSize } from "utils/AppsmithUtils"; + +export enum FontWeight { + BOLD = "bold", + NORMAL = "normal", +} + +interface ButtonComponentProps { + text?: string; + color?: string; + textColor?: string; + fontSize?: string; + isBold?: boolean; + onClick?: any; + rounded?: boolean; + isDisabled?: boolean; + isLoading?: boolean; +} + +const ButtonComponent = ({ + text, + color, + textColor, + fontSize, + isBold, + onClick, + rounded, + isDisabled, + isLoading, +}: ButtonComponentProps) => { + const style = { + height: "100%", + backgroundColor: color || "var(--primary-color)", + color: textColor || "#fff", + fontSize: transformDynamicSize(parseInt(fontSize || "20px")), + fontWeight: isBold ? FontWeight.BOLD : undefined, + "--loading-color": textColor || "#fff", + }; + const shape = rounded ? "round" : "square"; + return ( + + ); +}; + +export default ButtonComponent; diff --git a/app/taro/src/components/designSystems/taro/CellComponent.tsx b/app/taro/src/components/designSystems/taro/CellComponent.tsx new file mode 100644 index 0000000000..629fafd65b --- /dev/null +++ b/app/taro/src/components/designSystems/taro/CellComponent.tsx @@ -0,0 +1,91 @@ +import React from "react"; +import { ScrollView, Text } from "@tarojs/components"; +import { Cell, Image } from "@taroify/core"; +import { Arrow, PhotoFail } from "@taroify/icons"; +import { createVanIconComponent } from "@taroify/icons/van"; +import _ from "lodash"; + +export interface CellComponentProps { + cells: Array<{ + id: string; + label: string; + widgetId: string; + picType: "none" | "icon" | "image" | "text"; + prefix?: string; + icon?: string; + iconColor?: string; + picSrc?: string; + isVisible?: boolean; + showArrow?: boolean; + content?: string; + brief?: string; + onClick?: string; + }>; + title?: string; + inset: boolean; + bordered: boolean; + runAction: (a: string) => void; +} + +const CellComponent = (props: CellComponentProps) => { + const { cells, title, inset, bordered, runAction } = props; + + const onClickCellItem = (action: string) => (e: any) => { + if (action) { + runAction(action); + } + }; + + return ( + + + {cells.map((cell, index) => { + let icon: any = null; + if (cell.picType === "image") { + icon = ( + } + /> + ); + } else if (cell.picType === "icon" && cell.icon) { + const Icon = createVanIconComponent(cell.icon); + icon = ; + } else if (cell.picType === "text") { + icon = ( + + {cell.prefix} + + ); + } + return ( + : null} + onClick={onClickCellItem(cell.onClick || "")} + > + {cell.content} + + ); + })} + + + ); +}; + +export default CellComponent; diff --git a/app/taro/src/components/designSystems/taro/EmptyContent.tsx b/app/taro/src/components/designSystems/taro/EmptyContent.tsx new file mode 100644 index 0000000000..59510f01fd --- /dev/null +++ b/app/taro/src/components/designSystems/taro/EmptyContent.tsx @@ -0,0 +1,64 @@ +import React from "react"; +import { styled } from "linaria/react"; +import { View } from "@tarojs/components"; +import { Image, Button } from "@taroify/core"; +import { PhotoFail } from "@taroify/icons"; + +const EmptyContainer = styled(View)` + width: 100%; + height: 100%; + display: flex; + align-items: center; + justify-content: center; + + .taroify-image { + width: 200px; + height: 200px; + } +`; + +const EmptyText = styled(View)` + text-align: center; + color: #666; + font-size: 16px; +`; + +const EmptyButton = styled(Button)` + margin-top: 8px; +`; + +export interface EmptyProps { + text?: string; + pic?: string; + enableButton?: boolean; + buttonText?: string; + onClick: () => void; +} + +const Empty = ({ + text, + pic, + enableButton, + buttonText, + onClick, +}: EmptyProps) => { + return ( + + + } + src={pic || EMPTY_IMAGE_URL} + /> + {text || "暂无数据"} + {enableButton ? ( + + {buttonText || "登录"} + + ) : null} + + + ); +}; + +export default Empty; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/AddressField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/AddressField.tsx new file mode 100644 index 0000000000..89631aec11 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/AddressField.tsx @@ -0,0 +1,113 @@ +import React, { useEffect, useRef, useState } from "react"; +import { ArrowRight } from "@taroify/icons"; +import { Form, AreaPicker, Input, Popup } from "@taroify/core"; +import { FormItemInstance } from "@taroify/core/form"; +import { areaList } from "@vant/area-data"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; + placeholder?: string; +} + +const provinceList: any = areaList.province_list; +const cityList: any = areaList.city_list; +const countyList: any = areaList.county_list; + +const hiddenStyle = { + height: 0, + padding: 0, +}; + +function PickerField({ label, name, required, placeholder }: FieldProps) { + const itemRef = useRef(); + const provinceNameRef = useRef(); + const cityNameRef = useRef(); + const countyNameRef = useRef(); + const [open, setOpen] = useState(false); + const [areaValue, setAreaValue] = useState(); + const current = itemRef.current?.getValue(); + + useEffect(() => { + if (current) { + const currentProvince = current.substr(0, 2) + "0000"; + const currentCity = current.substr(0, 4) + "00"; + setAreaValue([currentProvince, currentCity, current]); + } + }, [current]); + + return ( + <> + } + rules={[{ required, message: `请选择${label}` }]} + > + {label} + + {(props) => { + let currentLabel = ""; + const county = props.value; + if (county?.length === 6) { + const province = county.substr(0, 2) + "0000"; + const city = county.substr(0, 4) + "00"; + currentLabel = [ + provinceList[province], + cityList[city], + countyList[county], + ].join(""); + } + return ( + setOpen(true)} + value={currentLabel} + /> + ); + }} + + + + + + + + + + + + + setOpen(false)} + onConfirm={(newValue) => { + itemRef.current?.setValue(newValue[2]); + provinceNameRef.current?.setValue(provinceList[newValue[0]]); + cityNameRef.current?.setValue(cityList[newValue[1]]); + countyNameRef.current?.setValue(countyList[newValue[2]]); + setOpen(false); + }} + > + + 取消 + 确认 + + {areaList} + + + + ); +} + +export default PickerField; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/CheckboxField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/CheckboxField.tsx new file mode 100644 index 0000000000..87d9d93dec --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/CheckboxField.tsx @@ -0,0 +1,36 @@ +import React from "react"; +import { Form, Checkbox } from "@taroify/core"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; + options: Array<{ + label: string; + value: string; + }>; +} + +function Field({ label, name, required, options }: FieldProps) { + return ( + + {label} + + + {options?.map((o, index) => ( + + {o.label} + + ))} + + + + ); +} + +export default Field; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/InputField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/InputField.tsx new file mode 100644 index 0000000000..f3ae9c3806 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/InputField.tsx @@ -0,0 +1,28 @@ +import React from "react"; +import { Form, Input } from "@taroify/core"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; + inputType: "text" | "number" | "idcard" | "digit" | "password"; + placeholder?: string; +} + +function Field({ label, name, required, inputType, placeholder }: FieldProps) { + const isPassword = inputType === "password"; + return ( + + {label} + + + + + ); +} + +export default Field; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/PickerField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/PickerField.tsx new file mode 100644 index 0000000000..6e441a9d79 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/PickerField.tsx @@ -0,0 +1,85 @@ +import React, { useRef, useState } from "react"; +import { ArrowRight } from "@taroify/icons"; +import { Form, Picker, Input, Popup } from "@taroify/core"; +import { FormItemInstance } from "@taroify/core/form"; +import _ from "lodash"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; + options: Array<{ + label: string; + value: string; + }>; + placeholder?: string; +} + +function PickerField({ + label, + name, + required, + options, + placeholder, +}: FieldProps) { + const itemRef = useRef(); + const [open, setOpen] = useState(false); + + const current = itemRef.current?.getValue(); + let currentLabel: any = undefined; + if (current?.length === 1) { + currentLabel = _.find(options, { value: current[0] })?.label; + } + + return ( + <> + } + rules={[{ required, message: `请选择${label}` }]} + > + {label} + + setOpen(true)} + value={currentLabel} + /> + + + + setOpen(false)} + onConfirm={(v) => { + itemRef.current?.setValue(v); + setOpen(false); + }} + > + + 取消 + 确认 + + + {options?.map((o, index) => ( + + {o.label} + + ))} + + + + + ); +} + +export default PickerField; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/RadioField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/RadioField.tsx new file mode 100644 index 0000000000..cab27971be --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/RadioField.tsx @@ -0,0 +1,31 @@ +import React from "react"; +import { Form, Radio } from "@taroify/core"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; + options: Array<{ + label: string; + value: string; + }>; +} + +function Field({ label, name, required, options }: FieldProps) { + return ( + + {label} + + + {options?.map((o, index) => ( + + {o.label} + + ))} + + + + ); +} + +export default Field; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/RateField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/RateField.tsx new file mode 100644 index 0000000000..a0a2db0995 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/RateField.tsx @@ -0,0 +1,21 @@ +import React from "react"; +import { Form, Rate } from "@taroify/core"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; +} + +function Field({ label, name, required }: FieldProps) { + return ( + + {label} + + + + + ); +} + +export default Field; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/StepperField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/StepperField.tsx new file mode 100644 index 0000000000..4f4b5a3eed --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/StepperField.tsx @@ -0,0 +1,21 @@ +import React from "react"; +import { Form, Stepper } from "@taroify/core"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; +} + +function Field({ label, name, required }: FieldProps) { + return ( + + {label} + + + + + ); +} + +export default Field; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/SwitchField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/SwitchField.tsx new file mode 100644 index 0000000000..85c201a0ad --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/SwitchField.tsx @@ -0,0 +1,21 @@ +import React from "react"; +import { Form, Switch } from "@taroify/core"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; +} + +function Field({ label, name }: FieldProps) { + return ( + + {label} + + + + + ); +} + +export default Field; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/UploaderField.tsx b/app/taro/src/components/designSystems/taro/FormComponent/UploaderField.tsx new file mode 100644 index 0000000000..f6cdfa0178 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/UploaderField.tsx @@ -0,0 +1,47 @@ +import React, { useRef } from "react"; +import { chooseImage } from "@tarojs/taro"; +import { Form, Uploader } from "@taroify/core"; +import { FormItemInstance } from "@taroify/core/form"; + +export interface FieldProps { + label: string; + name: string; + required: boolean; + uploadMax: number; +} + +function UploaderField({ label, name, required, uploadMax }: FieldProps) { + const itemRef = useRef(); + + function onUpload() { + chooseImage({ + count: 1, + sizeType: ["original", "compressed"], + sourceType: ["album", "camera"], + }).then(({ tempFiles }) => { + itemRef.current?.setValue([ + ...(itemRef.current?.getValue() || []), + { + url: tempFiles[0].path, + type: tempFiles[0].type, + name: tempFiles[0].originalFileObj?.name, + }, + ]); + }); + } + + return ( + + {label} + + + + + ); +} + +export default UploaderField; diff --git a/app/taro/src/components/designSystems/taro/FormComponent/index.tsx b/app/taro/src/components/designSystems/taro/FormComponent/index.tsx new file mode 100644 index 0000000000..3d926fb33b --- /dev/null +++ b/app/taro/src/components/designSystems/taro/FormComponent/index.tsx @@ -0,0 +1,180 @@ +import React, { useEffect, useRef, useState } from "react"; +import { View } from "@tarojs/components"; +import { Form, Button, Cell } from "@taroify/core"; +import { FormInstance } from "@taroify/core/form"; +import { styled } from "linaria/react"; +import { taroifyTheme } from "constants/DefaultTheme"; +import _ from "lodash"; +import PickerField from "./PickerField"; +import InputField from "./InputField"; +import SwitchField from "./SwitchField"; +import RateField from "./RateField"; +import StepperField from "./StepperField"; +import RadioField from "./RadioField"; +import CheckboxField from "./CheckboxField"; +import AddressField from "./AddressField"; +import UploaderField from "./UploaderField"; + +const ThemedForm = styled(Form)<{ + color?: string; +}>` + width: 100%; + height: 100%; + + --primary-color: ${(props) => props.color || taroifyTheme.primaryColor}; + --rate-icon-full-color: ${(props) => + props.color || taroifyTheme.primaryColor}; + --loading-color: #fff; + + .taroify-button__loading--right { + margin-right: 24px; + } +`; + +export interface FormComponentProps { + fields: Array<{ + id: string; + label: string; + widgetId: string; + name: string; + required: boolean; + fieldType: + | "input" + | "switch" + | "radio" + | "checkbox" + | "picker" + | "address" + | "stepper" + | "rate" + | "uploader"; + inputType?: "input" | "password"; + options?: Array<{ + label: string; + value: string; + }>; + placeholder?: string; + uploadMax?: number; + }>; + inset?: boolean; + buttonText?: string; + themeColor?: string; + defaultValues?: Record; + onFormSubmit: (data: any) => void; + isLoading: boolean; +} + +const FormComponent = (props: FormComponentProps) => { + const { + fields, + buttonText, + inset, + themeColor, + onFormSubmit, + defaultValues, + isLoading, + } = props; + const formRef = useRef(); + const [updateKey, setUpdateKey] = useState(0); + + useEffect(() => { + if (defaultValues) { + formRef.current?.setValues(defaultValues); + } else { + formRef.current?.reset(); + setUpdateKey(updateKey + 1); + } + }, [defaultValues]); + + return ( + onFormSubmit(e.detail.value)} + > + + {fields.map((field, index) => { + const { + label, + name, + required, + fieldType, + inputType, + options, + placeholder, + uploadMax, + } = field; + let props: any = { label, name, required, placeholder, key: index }; + if (fieldType === "input") { + props = { + label, + name, + required, + inputType, + placeholder, + key: index, + }; + return ; + } else if (fieldType === "switch") { + return ; + } else if (fieldType === "rate") { + return ; + } else if (fieldType === "stepper") { + return ; + } else if (fieldType === "radio") { + props = { + label, + name, + required, + placeholder, + options, + key: index, + }; + return ; + } else if (fieldType === "checkbox") { + props = { + label, + name, + required, + placeholder, + options, + key: index, + }; + return ; + } else if (fieldType === "address") { + return ; + } else if (fieldType === "picker") { + props = { + label, + name, + required, + placeholder, + options, + key: index, + }; + return ; + } else if (fieldType === "uploader") { + props = { label, name, required, uploadMax, key: index }; + return ; + } + return null; + })} + + + + + + ); +}; + +export default FormComponent; diff --git a/app/taro/src/components/designSystems/taro/GridComponent.tsx b/app/taro/src/components/designSystems/taro/GridComponent.tsx new file mode 100644 index 0000000000..820bb73d1a --- /dev/null +++ b/app/taro/src/components/designSystems/taro/GridComponent.tsx @@ -0,0 +1,218 @@ +import React from "react"; +import { Text, View, ScrollView } from "@tarojs/components"; +import { Grid, Image, Button } from "@taroify/core"; +import { PhotoOutlined, ShoppingCartOutlined, PhotoFail } from "@taroify/icons"; +import _ from "lodash"; +import { styled } from "linaria/react"; +import Empty from "./EmptyContent"; +import { transformDynamicSize } from "utils/AppsmithUtils"; + +export interface GridComponentProps { + list: any[]; + gridType: "I_N" | "I_N_D" | "I_N_D_B"; + urlKey: string; + titleKey: string; + badgeKey?: string; + descriptionKey?: string; + asPrice?: boolean; + priceUnit?: string; + buttonText?: string; + width?: string; + height?: string; + cols?: number; + gutter?: string; + bordered?: boolean; + titleColor?: string; + descriptionColor?: string; + buttonColor?: string; + onItemClicked: (item: any, type: "ITEM" | "BUTTON") => void; + runAction: (acton: string) => void; + emptyPic?: string; + emptyText?: string; + enableEmptyButton?: boolean; + emptyButtonText?: string; + emptyButtonAction?: string; +} + +const freeSize = (n: string, defaultValue: string) => { + if (n.toLowerCase().endsWith("px")) { + return transformDynamicSize(parseInt(n)); + } else { + return n || defaultValue; + } +}; + +const SameHeightImage = styled(Image)<{ + width?: string; + height?: string; +}>` + height: ${(props) => freeSize(props.height, "auto")}; + width: ${(props) => freeSize(props.width, "100%")}; + overflow: visible; +`; + +const Title = styled(Text)<{ + color?: string; +}>` + color: ${(props) => props.color || "#646566"}; + font-size: 16px; +`; + +const Container = styled(View)<{ + isBetween: boolean; +}>` + display: flex; + align-items: center; + justify-content: ${(props) => + props.isBetween ? "space-between" : "space-around"}; + margin-top: 8px; +`; + +const Price = styled(Text)<{ + color?: string; +}>` + color: ${(props) => props.color || "#DD4B34"}; + font-size: 14px; +`; + +const BuyButton = styled(Button)<{ + bgColor?: string; +}>` + background-color: ${(props) => props.bgColor || "#03b365"}; + color: #fff; + font-size: 14px; + padding: 0 8px; +`; + +const ColorGrid = styled(Grid)<{ + textColor?: string; +}>` + --grid-item-text-color: ${(props) => props.textColor}; +`; + +const GridComponent = (props: GridComponentProps) => { + const { + list, + gridType, + urlKey, + titleKey, + descriptionKey, + badgeKey, + asPrice, + priceUnit, + buttonText, + width, + height, + cols, + gutter, + bordered, + titleColor, + descriptionColor, + buttonColor, + onItemClicked, + runAction, + emptyPic, + emptyText, + enableEmptyButton, + emptyButtonText, + emptyButtonAction, + } = props; + const items = _.isArray(list) ? list : []; + const key = urlKey + titleKey + items.length; + const isSimple = gridType === "I_N"; + + const onClickButton = (item: any) => (e: any) => { + e.stopPropagation(); + onItemClicked(item, "BUTTON"); + }; + + const onClickGridItem = (item: any) => (e: any) => { + onItemClicked(item, "ITEM"); + }; + + if (!items.length) { + return ( + runAction(emptyButtonAction || "")} + /> + ); + } + + return ( + + + {items.map((item, index) => { + const url = item?.[urlKey]; + const title = item?.[titleKey] || ""; + const badge = item?.[badgeKey || ""] || ""; + + const image = url ? ( + } + /> + ) : ( + + ); + + if (isSimple) { + return ( + + ); + } + + const description = item?.[descriptionKey || ""] || "描述"; + const price = asPrice ? priceUnit + description : description; + const priceView = {price}; + return ( + + {image} + + {title} + + {priceView} + {gridType === "I_N_D_B" ? ( + + {buttonText || } + + ) : null} + + + + ); + })} + + + ); +}; + +export default GridComponent; diff --git a/app/taro/src/components/designSystems/taro/ImageComponent.tsx b/app/taro/src/components/designSystems/taro/ImageComponent.tsx new file mode 100644 index 0000000000..4b53a46dbf --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ImageComponent.tsx @@ -0,0 +1,36 @@ +import React from "react"; +import { Image } from "@taroify/core"; +import { PhotoFail } from "@taroify/icons"; + +interface ImageComponentProps { + imageUrl: string; + mode: any; + onClick?: any; + radius?: string; +} + +const hasNoUnit = (d: string) => /^\d+$/g.test(d); + +const ImageComponent = ({ + imageUrl, + mode, + onClick, + radius = "0", +}: ImageComponentProps) => { + const style = { + height: "100%", + width: "100%", + borderRadius: hasNoUnit(radius) ? `${radius}px` : radius, + }; + return ( + } + /> + ); +}; + +export default ImageComponent; diff --git a/app/taro/src/components/designSystems/taro/KVComponent.tsx b/app/taro/src/components/designSystems/taro/KVComponent.tsx new file mode 100644 index 0000000000..93975f8778 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/KVComponent.tsx @@ -0,0 +1,139 @@ +import React, { CSSProperties } from "react"; +import { Text, View, ScrollView } from "@tarojs/components"; +import _ from "lodash"; +import { styled } from "linaria/react"; +import { TextSize, TEXT_SIZES } from "constants/WidgetConstants"; +import { transformDynamicSize } from "utils/AppsmithUtils"; + +export interface ListComponentProps { + list: any[]; + kKey: string; + vKey: string; + inset?: boolean; + layout: "h" | "hb" | "v"; + kColor: string; + kSize: TextSize; + kBold: boolean; + kAlign: string; + vColor: string; + vSize: TextSize; + vBold: boolean; + vAlign: string; + style?: CSSProperties; +} + +const Container = styled(View)<{ + inset?: boolean; +}>` + border-radius: ${(props) => (props.inset ? "0.6rem" : "unset")}; + margin: ${(props) => (props.inset ? "0 1.2rem" : "0")}; + background: #fff; + padding: 12px 20px; +`; + +const HItem = styled(View)` + display: flex; + flex-direction: row; + margin: 12px 0; + + & > text:first-child { + margin-right: 12px; + width: 25%; + flex-shrink: 0; + } +`; + +const HBItem = styled(View)` + display: flex; + flex-direction: row; + margin: 12px 0; + justify-content: space-between; + + & > text:first-child { + flex-shrink: 0; + margin-right: 12px; + max-width: 50%; + } +`; + +const VItem = styled(View)` + display: flex; + flex-direction: column; + margin: 16px 0; + + & > text:first-child { + margin-bottom: 4px; + } +`; + +const StyledText = styled(Text)<{ + color: string; + size: TextSize; + bold: boolean; + align: string; +}>` + color: ${(props) => props.color}; + font-size: ${(props) => + transformDynamicSize(parseInt(TEXT_SIZES[props.size]))}; + font-weight: ${(props) => (props.bold ? "bold" : "normal")}; + text-align: ${(props) => props.align}; +`; + +const ListComponent = (props: ListComponentProps) => { + const { + list, + kKey, + vKey, + layout, + inset, + kColor, + kSize, + kBold, + kAlign, + vColor, + vSize, + vBold, + vAlign, + style, + } = props; + const items = _.isArray(list) ? list : []; + let Item = HItem; + if (layout === "hb") { + Item = HBItem; + } else if (layout === "v") { + Item = VItem; + } + + return ( + + + {items.map((item, index) => { + const k = item?.[kKey]; + const v = item?.[vKey]; + return ( + + + {k + ""} + + + {v + ""} + + + ); + })} + + + ); +}; + +export default ListComponent; diff --git a/app/taro/src/components/designSystems/taro/ListComponent.tsx b/app/taro/src/components/designSystems/taro/ListComponent.tsx new file mode 100644 index 0000000000..6a3f5e4a4b --- /dev/null +++ b/app/taro/src/components/designSystems/taro/ListComponent.tsx @@ -0,0 +1,376 @@ +import React, { useCallback, useState } from "react"; +import { Text, View, ScrollView } from "@tarojs/components"; +import { + Cell, + Image, + Button, + Checkbox, + SwipeCell, + Stepper, +} from "@taroify/core"; +import { PhotoOutlined, ShoppingCartOutlined, PhotoFail } from "@taroify/icons"; +import _ from "lodash"; +import { styled } from "linaria/react"; +import Empty from "./EmptyContent"; +import { transformDynamicSize } from "utils/AppsmithUtils"; + +export interface ListComponentProps { + enableCheckbox: boolean; + enableSwipe: boolean; + list: any[]; + contentType: "I_N_D_P_B" | "I_N_D" | "I_N_D_P"; + urlKey: string; + titleKey: string; + descriptionKey: string; + priceKey?: string; + checkedKey?: string; + controlType?: "TEXT" | "BUTTON" | "STEPPER"; + controlTextKey?: string; + buttonText?: string; + defaultNumKey?: string; + inset?: boolean; + width: string; + height: string; + titleColor?: string; + descriptionColor?: string; + priceColor?: string; + textColor?: string; + buttonColor?: string; + onItemClicked: ( + item: any, + type: "ITEM" | "BUTTON" | "STEPPER" | "CHECKBOX" | "DELETE" + ) => void; + runAction: (acton: string) => void; + emptyPic?: string; + emptyText?: string; + enableEmptyButton?: boolean; + emptyButtonText?: string; + emptyButtonAction?: string; +} + +const freeSize = (n: string) => { + if (n.toLowerCase().endsWith("px")) { + return transformDynamicSize(parseInt(n)); + } else { + return n; + } +}; + +const ColCell = styled(Cell)` + & .taroify-cell__value { + display: flex; + flex: 1; + } + + & .taroify-checkbox { + margin-right: 10px; + } +`; + +const FreeImage = styled(Image)<{ + width: string; + height: string; +}>` + width: ${(props) => freeSize(props.width)}; + height: ${(props) => freeSize(props.height)}; + pointer-events: none; +`; + +const RowCenter = styled(View)` + flex: 1; + display: flex; + height: 100%; + flex-direction: column; + justify-content: center; + margin-left: 8px; +`; + +const Title = styled(Text)<{ + color?: string; +}>` + color: ${(props) => props.color || "#646566"}; + font-size: 16px; +`; + +const Description = styled(Text)<{ + color?: string; +}>` + color: ${(props) => props.color || "#646566"}; + font-size: 14px; +`; + +const Container = styled(View)` + display: flex; + align-items: center; + justify-content: space-between; + margin-top: 8px; +`; + +const Price = styled(Text)<{ + color?: string; +}>` + color: ${(props) => props.color || "#DD4B34"}; + font-size: 14px; +`; + +const ControlText = styled(Text)<{ + color?: string; +}>` + color: ${(props) => props.color || "#333"}; + font-size: 16px; +`; + +const BuyButton = styled(Button)<{ + bgColor?: string; +}>` + background-color: ${(props) => props.bgColor || "#03b365"}; + color: #fff; + font-size: 14px; + padding: 0 8px; + + & .taroify-button__icon--right { + margin-right: 0; + } +`; + +const SwipeCellContainer = styled.div` + & .taroify-swipe-cell__actions { + right: -1px; + + .taroify-button { + height: 100%; + } + } +`; + +const Center = styled(View)` + align-self: center; +`; + +const ListComponent = (props: ListComponentProps) => { + const { + enableCheckbox, + enableSwipe, + list, + contentType, + urlKey, + titleKey, + descriptionKey, + priceKey, + checkedKey, + buttonText, + controlType, + controlTextKey, + defaultNumKey, + inset, + width, + height, + titleColor, + descriptionColor, + priceColor, + buttonColor, + textColor, + onItemClicked, + runAction, + emptyPic, + emptyText, + enableEmptyButton, + emptyButtonText, + emptyButtonAction, + } = props; + const items = _.isArray(list) ? list : []; + const noPrice = contentType === "I_N_D"; + const hasControl = contentType === "I_N_D_P_B"; + + const onClickButton = (item: any) => (e: any) => { + e.stopPropagation(); + onItemClicked(item, "BUTTON"); + }; + + const onClickItem = (item: any) => (e: any) => { + onItemClicked(item, "ITEM"); + }; + + const onStepperChanged = (item: any) => (v: any) => { + if (defaultNumKey) { + onItemClicked( + { + ...item, + [defaultNumKey]: v, + }, + "STEPPER" + ); + } + }; + + const onCheckChanged = (item: any) => (v: any) => { + if (checkedKey) { + onItemClicked( + { + ...item, + [checkedKey]: v, + }, + "CHECKBOX" + ); + } + }; + + const stopPropagation = useCallback((e: any) => { + e.stopPropagation(); + }, []); + + const notMe = { + onTouchStart: stopPropagation, + onTouchEnd: stopPropagation, + onTouchMove: stopPropagation, + }; + + const makeCell = (item: any, index: number) => { + const url = item?.[urlKey]; + const image = url ? ( + } + /> + ) : ( + width ? height : width} + style={{ height, width }} + /> + ); + + const title = item?.[titleKey] || ""; + let description = item?.[descriptionKey] || "描述"; + description = _.isArray(description) ? description.join(", ") : description; + const price = `¥${item?.[priceKey || ""] || "168"}`; + const controlText = item?.[controlTextKey || ""] || "x 3"; + const defaultNum = item?.[defaultNumKey || ""] || 1; + const priceView = {price}; + const checked = item?.[checkedKey || ""] || false; + const checkbox = enableCheckbox ? ( + + ) : null; + let control: any = null; + switch (controlType) { + case "TEXT": + control = {controlText}; + break; + case "BUTTON": + control = ( + + {buttonText || } + + ); + break; + case "STEPPER": + control = ( + + ); + break; + } + return ( + +
{checkbox}
+ {image} + + {title} + + {description} + + {noPrice ? null : ( + + {priceView} + {hasControl ? {control} : null} + + )} + +
+ ); + }; + + const onClickDelete = (item: any) => (e: any) => { + e.stopPropagation(); + onItemClicked(item, "DELETE"); + }; + + const makeSwipe = (content: React.ReactNode, item: any, index: number) => { + return ( + + + {content} + + + + + + ); + }; + + const makeCheckboxGroup = (content: React.ReactNode) => { + if (enableCheckbox) { + return {content}; + } + return content; + }; + + const cellGroup = ( + + {items.map((item, index) => { + let content = makeCell(item, index); + if (enableSwipe) { + content = makeSwipe(content, item, index); + } + return content; + })} + + ); + + if (!items.length) { + return ( + runAction(emptyButtonAction || "")} + /> + ); + } + + return ( + + {makeCheckboxGroup(cellGroup)} + + ); +}; + +export default ListComponent; diff --git a/app/taro/src/components/designSystems/taro/NavTabComponent.tsx b/app/taro/src/components/designSystems/taro/NavTabComponent.tsx new file mode 100644 index 0000000000..1d33e2430c --- /dev/null +++ b/app/taro/src/components/designSystems/taro/NavTabComponent.tsx @@ -0,0 +1,53 @@ +import React from "react"; +import { ScrollView } from "@tarojs/components"; +import { Sidebar, Tabs } from "@taroify/core"; +import _ from "lodash"; +import { styled } from 'linaria/react'; + +const FillTabs = styled(Tabs)` + height: 100%; + --tabs-line-height: 100%; +`; + +const FillSideBar = styled(Sidebar)` + --sidebar-width: 100%; +`; + +export interface ListComponentProps { + list: any[]; + nameKey: string; + selectedIndex: number; + layout: "v" | "h"; + onTabSelected: (index: number) => void; +} + +const ListComponent = (props: ListComponentProps) => { + const { list, nameKey, selectedIndex, layout, onTabSelected } = props; + + const listRender = list.map((item, index) => { + const name = item?.[nameKey]; + return layout === "h" ? ( + + ) : ( + {name} + ); + }); + + if (layout === "h") { + return ( + + {listRender} + + ); + } + + return ( + + + {listRender} + + + ); +}; + +export default ListComponent; diff --git a/app/taro/src/components/designSystems/taro/PickerComponent.tsx b/app/taro/src/components/designSystems/taro/PickerComponent.tsx new file mode 100644 index 0000000000..87100e3411 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/PickerComponent.tsx @@ -0,0 +1,201 @@ +import React, { useState } from "react"; +import { View, Text } from "@tarojs/components"; +import Taro from "@tarojs/taro"; +import { + Uploader, + Cell, + Button, + Image, + Toast, + Checkbox, + Field, + NoticeBar, + Flex, + Dialog, +} from "@taroify/core"; +import { Arrow } from "@taroify/icons"; + +interface PickerComponentProps { + title?: string; + onButtonClick?: (e: any) => void; +} + +function buildData(offset = 0) { + return Array(100) + .fill(0) + .map((_, i) => i + offset); +} + +const Row = React.memo(({ id, index, style, data }: any) => { + return ( + + Row {index} : {data[index]} + + ); +}); +Row.displayName = "Row"; + +const PickerComponent = (props: PickerComponentProps) => { + const { title, onButtonClick } = props; + + const [loading, setLoading] = useState(false); + const [data, setData] = useState(buildData(0)); + const listReachBottom = () => { + // 如果 loading 与视图相关,那它就应该放在 `this.state` 里 + // 我们这里使用的是一个同步的 API 调用 loading,所以不需要 + setLoading(true); + setTimeout(() => { + setData(data.concat(buildData(data.length))); + setLoading(false); + }, 1000); + }; + const dataLen = data.length; + const itemSize = 100; + + const [open, setOpen] = useState(false); + const [value, setValue] = useState(); + const [text, setText] = useState(""); + const [idcard, setIdcard] = useState(""); + const [number, setNumber] = useState(""); + const [digit, setDigit] = useState(""); + const [password, setPassword] = useState(""); + + const [file, setFile] = useState(); + + const onUpload = () => { + Taro.chooseImage({ + count: 1, + sizeType: ["original", "compressed"], + sourceType: ["album", "camera"], + }).then(({ tempFiles }) => { + setFile({ + url: tempFiles[0].path, + type: tempFiles[0].type, + name: tempFiles[0].originalFileObj?.name, + }); + }); + }; + + const show = () => { + Taro.showToast({ + title: "生活愉快!", + icon: "success", + duration: 2000, + }); + }; + + return ( + + + + + + + + + } + clickable + onClick={() => setOpen(true)} + > + 内容 + + + + } clickable> + 内容 + + + + + + + + + + + 复选框 a + 复选框 b + + +
+ +
+ + + setText(e.detail.value)} + /> + setIdcard(e.detail.value)} + /> + setNumber(e.detail.value)} + /> + setDigit(e.detail.value)} + /> + setPassword(e.detail.value)} + /> + + + + {title} + + + + {title} + + 代码是写出来给人看的,附带能在机器上运行 + + + + + + + +
+ ); +}; + +export default PickerComponent; diff --git a/app/taro/src/components/designSystems/taro/PopoverComponent.tsx b/app/taro/src/components/designSystems/taro/PopoverComponent.tsx new file mode 100644 index 0000000000..f32eda0724 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/PopoverComponent.tsx @@ -0,0 +1,76 @@ +import React, { ReactNode, useEffect, useContext } from "react"; +import { styled } from "linaria/react"; +import { getCanvasClassName } from "utils/generators"; +import { Popup } from "@taroify/core"; +import { Cross } from "@taroify/icons"; +import { PopupProps } from "@taroify/core/popup/popup"; +import { getShowTabBar } from "selectors/editorSelectors"; +import ReduxContext from "components/common/ReduxContext"; +import { transformDynamicSize } from "utils/AppsmithUtils"; + +const PopupContainer = styled(Popup)< + { + height?: number; + showTabBar?: boolean; + } & PopupProps +>` + height: calc( + ${(props) => transformDynamicSize(props.height)}px + + ${(props) => + props.showTabBar ? "0px" : "constant(safe-area-inset-bottom)"} + ); + height: calc( + ${(props) => transformDynamicSize(props.height)}px + + ${(props) => (props.showTabBar ? "0px" : "env(safe-area-inset-bottom)")} + ); + overflow: visible; + width: 100%; + background: #fff; +`; + +const Content = styled.div` + width: 100%; + height: 100%; +`; + +export type ModalComponentProps = { + isOpen: boolean; + onClose: (e: any) => void; + onModalClose?: () => void; + children: ReactNode; + className?: string; + canOutsideClickClose: boolean; + rounded?: boolean; + height?: number; +}; + +/* eslint-disable react/display-name */ +export function ModalComponent(props: ModalComponentProps) { + const { useSelector } = useContext(ReduxContext); + const showTabBar = useSelector(getShowTabBar); + useEffect(() => { + return () => { + if (props.onModalClose) props.onModalClose(); + }; + }, []); + return ( + + + + + + + {props.children} + + + ); +} + +export default ModalComponent; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/PropsType.ts b/app/taro/src/components/designSystems/taro/SkuComponent/PropsType.ts new file mode 100644 index 0000000000..4d7696882b --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/PropsType.ts @@ -0,0 +1,209 @@ +import React from "react"; + +export type SkuData = { + price: string | number; + none_sku: boolean; + stock_num: number; + hide_stock?: boolean; + collection_id?: number; + tree: SkuTreeItemData[]; + list: SkuListItemData[]; + properties?: SkuPropItemData[]; +}; + +export type SkuTreeItemData = { + k: string | number; + v: SkuTreeItemValueData[]; + k_s: string | number; + is_multiple?: boolean; +}; + +export type SkuTreeItemValueData = { + id: string | number; + name: string | number; + imgUrl?: string; + img_url?: string; + previewImgUrl?: string; +}; + +export type SkuPropItemData = { + k: number | string; + v: SkuPropItemValueData[]; + k_id: string | number; + is_multiple?: boolean; + is_necessary?: boolean; +}; + +export type SkuPropItemValueData = { + id: number | string; + name: string; + price?: string | number; +}; + +export type SkuListItemData = { + id: number; + s1: string; + s2: string; + s3: string; + price: number; + stock_num: number; +}; + +export type SkuMessageData = { + name: string; + type: string; + required?: string; + datetime?: string; + multiple?: string; + placeholder?: string; +}; + +export type SkuGoodsData = { + title: string; + picture: string; +}; + +export type SelectedSkuData = Record; + +export type SkuValueType = Record; + +export type SkuFieldNames = { + text?: string; + value?: string; + children?: string; +}; + +export type SkuActionType = "add-cart" | "buy-clicked"; + +export type SkuStateType = { + selectedSku?: Record; + selectedProp?: Record; + selectedNum?: number; +}; +export interface SkuProps { + /** 商品sku数据 */ + sku: any; + /** 商品信息 */ + goods: Record; + /** 商品id */ + goodsId?: number | string; + /** 显示在价格后面的标签 */ + priceTag?: React.ReactNode; + /** 是否显示限购提示 */ + hideQuotaText?: boolean; + /** 是否隐藏已选提示 */ + hideSelectedText?: boolean; + /** 是否显示商品剩余库存 */ + hideStock?: boolean; + /** 库存阈值。低于这个值会把库存数高亮显示 */ + stockThreshold?: number; + /** 是否显示加入购物车按钮 */ + showAddCartBtn?: boolean; + /** 购买按钮文字 */ + buyText?: string; + /** 加入购物车按钮文字 */ + addCartText?: string; + /** 限购数,0 表示不限购 */ + quota?: number; + /** 已经购买过的数量 */ + quotaUsed?: number; + /** 隐藏时重置状态 */ + resetOnHide?: boolean; + /** 是否禁用步进器输入 */ + disableStepperInput?: boolean; + /** 是否在点击遮罩层后关闭 */ + closeOnClickOverlay?: boolean; + /** 数量选择组件左侧文案 */ + stepperTitle?: React.ReactNode; + /** 步进器相关自定义配置 */ + customStepperConfig?: any; + /** 指定挂载的节点 */ + getContainer?: any; + /** 默认选中的 sku */ + initialSku?: SkuStateType; + /** 是否展示售罄的 sku,默认展示并置灰 */ + showSoldoutSku?: boolean; + /** 是否禁用售罄的 sku */ + disableSoldoutSku?: boolean; + /** 是否开启底部安全区适配 */ + safeAreaInsetBottom?: boolean; + /** 起售数量 */ + startSaleNum?: number; + /** 商品属性 */ + properties?: SkuPropItemData[]; + /** 自定义预览icon */ + previewIcon?: React.ReactNode; + /** 是否在点击商品图片时自动预览 */ + previewOnClickImage?: boolean; + /** 是否展示头部图片 */ + showHeaderImage?: boolean; + /** 是否开启图片懒加载 */ + lazyload?: boolean; + /** + * sku距视窗顶部距离 + * @default 200 + */ + bodyOffsetTop?: number; + /** 商品信息展示区,包含商品图片、名称、价格等信息 */ + skuHeader?: React.ReactNode; + /** 自定义 sku 头部价格展示 */ + skuHeaderPriceRender?: (price: number) => React.ReactNode; + /** 自定义 sku 头部原价展示 */ + skuHeaderOriginPrice?: React.ReactNode; + /** 额外 sku 头部区域 */ + skuHeaderExtra?: React.ReactNode; + /** 自定义 sku 头部图片额外的展示 */ + skuHeaderImageExtra?: React.ReactNode; + /** sku 展示区上方的内容,无默认展示内容,按需使用 */ + skuBodyTop?: React.ReactNode; + /** 自定义商品 sku 展示区 */ + skuGroup?: React.ReactNode; + /** 额外商品 sku 展示区,一般用不到 */ + skuGroupExtra?: React.ReactNode; + /** 自定义商品数量选择区 */ + skuStepper?: React.ReactNode; + /** 操作按钮区顶部内容,无默认展示内容,按需使用 */ + skuActionsTop?: React.ReactNode; + /** 操作按钮区底部内容,无默认展示内容,按需使用 */ + skuActionsBottom?: React.ReactNode; + /** 自定义操作按钮区 */ + skuActions?: React.ReactNode; + /** 自定义库存渲染方法 */ + stockRender?: (stock: number) => React.ReactNode; + /** 自定义sku校验规则 */ + customSkuValidator?: ( + actionType: SkuActionType, + selectedSku: SkuValueType, + ) => void | boolean | Promise; + /** 点击添加购物车回调 */ + onAddCart?: (value: SkuValueType) => void; + /** 点击购买回调 */ + onBuyClicked?: (value: SkuValueType) => void; + /** 购买数量变化时触发 */ + onStepperChange?: (value: number) => void; + /** 切换规格类目时触发 */ + onSkuSelected?: (value: any) => void; + /** 切换商品属性时触发 */ + onSkuPropSelected?: (value: any) => void; + /** 打开商品图片预览时触发 */ + onOpenPreview?: (data: any) => void; + /** 关闭商品图片预览时触发 */ + onClosePreview?: (data: any) => void; + /** 主题色 */ + color?: string; + /** 加入购物车按钮加载中 */ + addCartLoading?: boolean; + /** 立即购买按钮加载中 */ + buyLoading?: boolean; +} + +export type SkuInstance = { + /** 重置Sku到初始状态 */ + reset: () => void; + /** 打开Sku,支持设置默认值 */ + show: (initialValue?: SkuStateType) => void; + /** 更新Sku设置 */ + update: (initialValue: SkuStateType) => void; + /** 获取当前 skuData */ + getSkuData: () => SkuStateType; +}; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/Sku.tsx b/app/taro/src/components/designSystems/taro/SkuComponent/Sku.tsx new file mode 100644 index 0000000000..31d9d70c23 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/Sku.tsx @@ -0,0 +1,565 @@ +/* eslint-disable react/no-array-index-key */ +import React, { + forwardRef, + useCallback, + useEffect, + useImperativeHandle, + useMemo, + useRef, +} from "react"; +import cls from "clsx"; +import { SkuActionType, SkuInstance, SkuProps } from "./PropsType"; +import ActionBar from "../ActionBar"; +import { Image } from "@taroify/core"; +import { ScrollView } from "@tarojs/components"; +import { PhotoFail } from "@taroify/icons"; +import useSetState from "utils/hooks/use-set-state"; +import { createBEM } from "./bem"; +import { + getSelectedProperties, + getSelectedPropValues, + getSelectedSkuValues, + getSkuComb, + getSkuImgValue, + isAllSelected, + SelectedValueType, +} from "./utils"; +import { + LIMIT_TYPE, + UNSELECTED_SKU_VALUE_ID, + BORDER_BOTTOM, +} from "./constants"; +import SkuRow from "./SkuRow"; +import SkuRowItem from "./SkuRowItem"; +import SkuRowPropItem from "./SkuRowPropItem"; +import SkuStepper from "./SkuStepper"; +import Taro from "@tarojs/taro"; + +const { QUOTA_LIMIT } = LIMIT_TYPE; + +const Sku = forwardRef((props, ref) => { + const bem = createBEM("rv-sku"); + const stepperError = useRef(false); + const [state, updateState]: any[] = useSetState({ + selectedSku: {}, + selectedProp: {}, + selectedNum: props.startSaleNum, + }); + + const { sku, properties = [] } = props; + const { tree = [] } = sku; + + const hasSku = useMemo(() => !sku.none_sku, [sku.none_sku]); + const hasSkuOrAttr = useMemo(() => hasSku || properties.length > 0, [ + hasSku, + properties, + ]); + + const isSkuCombSelected = useMemo(() => { + // SKU 未选完 + if (hasSku && !isAllSelected(tree, state.selectedSku)) { + return false; + } + + // 属性未全选 + return !properties + .filter((i) => i.is_necessary !== false) + .some((i) => (state.selectedProp[i.k_id] || []).length === 0); + }, [hasSku, state]); + + const selectedSkuValues = useMemo(() => { + return getSelectedSkuValues(tree, state.selectedSku); + }, [tree, state.selectedSku]); + + const selectedPropValues = useMemo(() => { + return getSelectedPropValues(properties, state.selectedProp); + }, [properties, state.selectedProp]); + + const selectedSkuComb = useMemo(() => { + let skuComb: any = null; + if (isSkuCombSelected) { + if (hasSku) { + skuComb = getSkuComb(sku.list, state.selectedSku); + } else { + skuComb = { + id: sku.collection_id, + price: Math.round(+sku.price * 100), + stock_num: sku.stock_num, + }; + } + + if (skuComb) { + skuComb.properties = getSelectedProperties( + properties, + state.selectedProp, + ); + skuComb.property_price = selectedPropValues.reduce( + (acc: any, cur: any) => acc + (cur.price || 0), + 0, + ); + } + } + return skuComb; + }, [ + isSkuCombSelected, + hasSku, + JSON.stringify(sku), + JSON.stringify(state), + properties, + selectedPropValues, + ]); + + const unselectedSku = useMemo(() => { + return tree + .filter((item: any) => !state.selectedSku[item.k_s]) + .map((item: any) => item.k); + }, [tree, state.selectedSku]); + + const getUnselectedProp = useCallback( + (isNecessary?: boolean) => { + return properties + .filter((item) => (isNecessary ? item.is_necessary !== false : true)) + .filter((item) => (state.selectedProp[item.k_id] || []).length < 1) + .map((item) => item.k); + }, + [properties, state.selectedProp], + ); + + const selectedText = useMemo(() => { + if (selectedSkuComb) { + const values = selectedSkuValues.concat(selectedPropValues); + return `已选 ${values.map((item: any) => item.name).join(" ")}`; + } + + return `请选择 ${unselectedSku.concat(getUnselectedProp()).join(" ")}`; + }, [ + unselectedSku, + getUnselectedProp, + selectedSkuComb, + selectedSkuValues, + selectedPropValues, + ]); + + const price = useMemo(() => { + if (selectedSkuComb) { + return selectedSkuComb.price + selectedSkuComb.property_price; + } + // sku.price是一个格式化好的价格区间 + return sku.price; + }, [JSON.stringify(selectedSkuComb), sku.price]); + + const stock = useMemo(() => { + const { stockNum } = props.customStepperConfig; + if (stockNum !== undefined) { + return stockNum; + } + if (selectedSkuComb) { + return selectedSkuComb.stock_num; + } + return sku.stock_num; + }, [sku.stock_num, JSON.stringify(selectedSkuComb)]); + + const stockContent = useMemo(() => { + if (props.stockRender) { + return props.stockRender(stock); + } + return ( + <> + 剩余 + + {stock} + + 件 + + ); + }, [stock]); + + const onSelect = (skuValue: any) => { + // 点击已选中的sku时则取消选中 + const selectedSku = + state.selectedSku[skuValue.skuKeyStr] === skuValue.id + ? { + ...state.selectedSku, + [skuValue.skuKeyStr]: UNSELECTED_SKU_VALUE_ID, + } + : { ...state.selectedSku, [skuValue.skuKeyStr]: skuValue.id }; + + updateState({ selectedSku, selectedNum: props.startSaleNum }); + if (props.onSkuSelected) { + props.onSkuSelected({ + skuValue, + selectedSku: state.selectedSku, + selectedSkuComb, + }); + } + }; + + const onPropSelect = (propValue: any) => { + const arr = state.selectedProp[propValue.skuKeyStr] || []; + const pos = arr.indexOf(propValue.id); + + if (pos > -1) { + arr.splice(pos, 1); + } else if (propValue.multiple) { + arr.push(propValue.id); + } else { + arr.splice(0, 1, propValue.id); + } + const selectedProp = { + ...state.selectedProp, + [propValue.skuKeyStr]: arr, + }; + + updateState({ selectedProp }); + + if (props.onSkuPropSelected) { + props.onSkuPropSelected({ + propValue, + selectedProp: state.selectedProp, + selectedSkuComb, + }); + } + }; + + const onOverLimit = (data: any) => { + const { action, limitType, quota, quotaUsed } = data; + const { handleOverLimit } = props.customStepperConfig; + + if (handleOverLimit) { + handleOverLimit(data); + return; + } + + if (action === "minus") { + if (props.startSaleNum && props.startSaleNum > 1) { + Taro.showToast({ + title: `${props.startSaleNum}件起售`, + icon: "none", + }); + } else { + Taro.showToast({ + title: "至少选择一件", + icon: "none", + }); + } + } else if (action === "plus") { + if (limitType === QUOTA_LIMIT) { + if (quotaUsed > 0) { + Taro.showToast({ + title: `每人限购${quota}件,你已购买${quotaUsed}件`, + icon: "none", + }); + } else { + Taro.showToast({ + title: `每人限购${quota}件`, + icon: "none", + }); + } + } else { + Taro.showToast({ + title: "库存不足", + icon: "none", + }); + } + } + }; + + const onStepperState = (data: any) => { + stepperError.current = data.valid + ? null + : { + ...data, + action: "plus", + }; + }; + + const validateSku = () => { + if (state.selectedNum === 0) { + return "商品已经无法购买啦"; + } + + if (isSkuCombSelected) { + return ""; + } + + return `请选择 ${unselectedSku.concat(getUnselectedProp(true)).join(" ")}`; + }; + + const getSkuData = () => { + return { + goodsId: props.goodsId, + selectedNum: state.selectedNum, + selectedSkuComb, + }; + }; + + const onAddCart = (data: any) => { + props.onAddCart?.(data); + }; + const onBuyClicked = (data: any) => { + props.onBuyClicked?.(data); + }; + + const onBuyOrAddCart = async (type: SkuActionType) => { + // sku 不符合购买条件 + if (stepperError.current) { + onOverLimit(stepperError.current); + return; + } + + if (props.customSkuValidator) { + if ( + !(await props.customSkuValidator(type, { + ...state.selectedSku, + ...state.selectedProp, + })) + ) { + return; + } + } else { + const error = validateSku(); + if (error) { + Taro.showToast({ + title: error, + icon: "none", + }); + return; + } + } + + const data = getSkuData(); + if (type === "add-cart") { + onAddCart(data); + } else { + onBuyClicked(data); + } + }; + + const show = (initialValue?: typeof state) => { + if (initialValue) { + updateState(initialValue); + } + }; + + const reset = () => { + updateState({ + selectedSku: {}, + selectedProp: {}, + selectedNum: props.startSaleNum, + }); + }; + + const renderHeaderInfo = () => { + return ( + <> + {props.skuHeaderPriceRender?.(price) || ( +
+ + {price} + {props.priceTag && ( + {props.priceTag} + )} +
+ )} + {props.skuHeaderOriginPrice && ( +
+ {props.skuHeaderOriginPrice} +
+ )} + {!props.hideStock && ( +
+ {stockContent} +
+ )} + {!props.hideSelectedText && ( +
{selectedText}
+ )} + + ); + }; + + const renderHeader = () => { + if (props.skuHeader) return props.skuHeader; + const selectedValue = getSkuImgValue(sku, state.selectedSku); + const imgUrl = selectedValue + ? selectedValue.imgUrl + : (props.goods.picture as string); + return ( +
+ {props.showHeaderImage && ( + } + /> + )} +
+ {renderHeaderInfo()} + {props.skuHeaderExtra} +
+
+ ); + }; + + const renderGroup = () => { + return ( + props.skuGroup || + (hasSkuOrAttr && ( +
+ {tree.map((skuTreeItem: any, i: number) => ( + + {skuTreeItem.v.map((skuValue: any, idx: number) => ( + + ))} + + ))} + + {properties.map((skuTreeItem, i) => ( + + {skuTreeItem.v.map((skuValue, idx) => ( + + ))} + + ))} +
+ )) + ); + }; + + const renderStepper = () => + props.skuStepper || ( + { + updateState({ selectedNum: parseInt(`${currentValue}`, 10) }); + if (props.onStepperChange) props.onStepperChange(currentValue); + }} + stock={stock} + quota={props.quota || 0} + quotaUsed={props.quotaUsed || 0} + startSaleNum={props.startSaleNum || 1} + disableStepperInput={props.disableStepperInput} + customStepperConfig={props.customStepperConfig} + stepperTitle={props.stepperTitle} + hideQuotaText={props.hideQuotaText} + onSkuStepperState={onStepperState} + onSkuOverLimit={onOverLimit} + /> + ); + + const renderBody = () => { + return ( + + {props.skuBodyTop} + {renderGroup()} + {props.skuGroupExtra} + {renderStepper()} + + ); + }; + + const renderActions = () => { + return ( + props.skuActions || ( +
+ + {props.showAddCartBtn && ( + onBuyOrAddCart("add-cart")} + loading={props.addCartLoading} + /> + )} + onBuyOrAddCart("buy-clicked")} + loading={props.buyLoading} + /> + +
+ ) + ); + }; + + useEffect(() => { + if (props.initialSku) { + updateState(props.initialSku); + } + }, [JSON.stringify(props.initialSku)]); + + useImperativeHandle(ref, () => ({ + reset, + getSkuData, + show, + update: updateState, + })); + + return ( +
+ {renderHeader()} + {renderBody()} + {props.skuActionsTop} + {renderActions()} + {props.skuActionsBottom} +
+ ); +}); + +// defaultProps defined if need +Sku.defaultProps = { + stepperTitle: "购买数量", + properties: [], + showAddCartBtn: true, + disableSoldoutSku: true, + showHeaderImage: true, + previewOnClickImage: true, + showSoldoutSku: true, + resetOnHide: true, + safeAreaInsetBottom: true, + quota: 0, + quotaUsed: 0, + startSaleNum: 1, + stockThreshold: 50, + bodyOffsetTop: 200, + customStepperConfig: {}, +}; + +export default Sku; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/SkuRow.tsx b/app/taro/src/components/designSystems/taro/SkuComponent/SkuRow.tsx new file mode 100644 index 0000000000..bcdab34a49 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/SkuRow.tsx @@ -0,0 +1,44 @@ +import React, { useContext } from "react"; +import cls from "clsx"; +import { BEM, createBEM } from "./bem"; +import { BORDER_BOTTOM } from "./constants"; + +type SkuRowProps = { + skuRow: Record; +}; + +const SkuRow: React.FC = (props) => { + const bem = createBEM("rv-sku-row"); + const { skuRow } = props; + + const renderTitle = () => { + return ( +
+ {skuRow.k} + {skuRow.is_multiple && ( + (可多选) + )} +
+ ); + }; + + const renderContent = () => { + const { largeImageMode } = skuRow; + return largeImageMode ? ( +
+
{props.children}
+
+ ) : ( + props.children + ); + }; + + return ( +
+ {renderTitle()} + {renderContent()} +
+ ); +}; + +export default SkuRow; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/SkuRowItem.tsx b/app/taro/src/components/designSystems/taro/SkuComponent/SkuRowItem.tsx new file mode 100644 index 0000000000..8051de6ba5 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/SkuRowItem.tsx @@ -0,0 +1,94 @@ +import React, { useMemo } from "react"; +import cls from "clsx"; +import { Image } from "@taroify/core"; +import { PhotoFail } from "@taroify/icons"; +import { createBEM } from "./bem"; +import { isSkuChoosable } from "./utils"; + +type SkuRowItemProps = { + lazyload?: boolean; + skuValue: Record; + skuKeyStr: string; + selectedSku: Record; + largeImageMode: boolean; + disableSoldoutSku: boolean; + skuList: any[]; + previewIcon?: React.ReactNode; + onSkuSelected?: (params: any) => void; + onSkuPreviewImage?: (params: any) => void; +}; + +const SkuRowItem: React.FC = (props) => { + const bem = createBEM("rv-sku-row"); + const classPrefix = props.largeImageMode ? "image-item" : "item"; + + const imgUrl = useMemo(() => { + const url = props.skuValue.imgUrl || props.skuValue.img_url; + return props.largeImageMode + ? url || + "https://img01.yzcdn.cn/upload_files/2020/06/24/FmKWDg0bN9rMcTp9ne8MXiQWGtLn.png" + : url; + }, [props.skuValue]); + + const choosable = useMemo(() => { + if (!props.disableSoldoutSku) { + return true; + } + return isSkuChoosable(props.skuList, props.selectedSku, { + key: props.skuKeyStr, + valueId: props.skuValue.id, + }); + }, [ + JSON.stringify(props.skuList), + JSON.stringify(props.selectedSku), + props.skuKeyStr, + ]); + + const imageRender = () => { + if (imgUrl) { + return ( + } + /> + ); + } + return null; + }; + + const onSelect = () => { + if (choosable && props.onSkuSelected) { + props.onSkuSelected({ ...props.skuValue, skuKeyStr: props.skuKeyStr }); + } + }; + + const choosed = props.skuValue.id === props.selectedSku[props.skuKeyStr]; + + return ( + + {imageRender()} +
+ {props.largeImageMode ? ( + + {props.skuValue?.name} + + ) : ( + props.skuValue?.name + )} +
+
+ ); +}; + +export default SkuRowItem; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/SkuRowPropItem.tsx b/app/taro/src/components/designSystems/taro/SkuComponent/SkuRowPropItem.tsx new file mode 100644 index 0000000000..81bbe7e3b6 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/SkuRowPropItem.tsx @@ -0,0 +1,52 @@ +import React, { useMemo } from "react"; +import cls from "clsx"; +import { BEM, createBEM } from "./bem"; + +type SkuRowPropItemProps = { + multiple?: boolean; + skuValue: Record; + selectedProp: Record; + skuKeyStr: string; + onSkuPropSelected: (params: any) => void; +}; + +const SkuRowPropItem: React.FC = (props) => { + const bem = createBEM("rv-sku-row"); + + const choosed = useMemo(() => { + const { selectedProp, skuKeyStr, skuValue } = props; + + if (selectedProp && selectedProp[skuKeyStr]) { + return selectedProp[skuKeyStr].indexOf(skuValue.id) > -1; + } + + return false; + }, [ + JSON.stringify(props.selectedProp), + JSON.stringify(props.skuValue), + props.skuKeyStr, + ]); + + const onSelect = () => { + props.onSkuPropSelected({ + ...props.skuValue, + skuKeyStr: props.skuKeyStr, + multiple: props.multiple, + }); + }; + + return ( + + {props.skuValue?.name} + + ); +}; + +export default SkuRowPropItem; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/SkuStepper.tsx b/app/taro/src/components/designSystems/taro/SkuComponent/SkuStepper.tsx new file mode 100644 index 0000000000..8d8cf27766 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/SkuStepper.tsx @@ -0,0 +1,139 @@ +import React, { useContext, useMemo, useState } from "react"; +import cls from "clsx"; +import { BEM, createBEM } from "./bem"; +import { LIMIT_TYPE } from "./constants"; +import { Stepper } from "@taroify/core"; + +type SkuStepperProps = { + currentNum: number; + onChange: (v: number) => void; + onSkuStepperState: (v: any) => void; + onSkuOverLimit?: (v: any) => void; + stock: number; + stepperTitle?: React.ReactNode; + disableStepperInput?: boolean; + hideQuotaText?: boolean; + quota: number | string; + quotaUsed: number | string; + startSaleNum: number | string; + customStepperConfig?: any; +}; + +const { QUOTA_LIMIT, STOCK_LIMIT } = LIMIT_TYPE; + +const SkuStepper: React.FC = (props) => { + const bem = createBEM("rv-sku"); + const [limitType, setLimitType] = useState(STOCK_LIMIT); + const [updateKey, setUpdateKey] = useState(0); + + const stepperLimit = useMemo(() => { + const quotaLimit = +props.quota - +props.quotaUsed; + let limit; + let currentLimitType; + + // 无限购时直接取库存,有限购时取限购数和库存数中小的那个 + if (+props.quota > 0 && quotaLimit <= props.stock) { + // 修正负的limit + limit = quotaLimit < 0 ? 0 : quotaLimit; + currentLimitType = QUOTA_LIMIT; + } else { + limit = props.stock; + currentLimitType = STOCK_LIMIT; + } + + setLimitType(currentLimitType); + + return limit; + }, [props.quota, props.quotaUsed, props.stock]); + + const stepperMinLimit = useMemo(() => { + return +props.startSaleNum < 1 ? 1 : +props.startSaleNum; + }, [props.startSaleNum]); + + const quotaContent = useMemo(() => { + const { quotaText, hideQuotaText } = props.customStepperConfig; + if (hideQuotaText) return ""; + + let text = ""; + + if (quotaText) { + text = quotaText; + } else { + const textArr: any[] = []; + if (+props.startSaleNum > 1) { + textArr.push(`${props.startSaleNum}件起售`); + } + if (+props.quota > 0) { + textArr.push(`限购${+props.quota}件`); + } + text = textArr.join(","); + } + + return text; + }, [ + JSON.stringify(props.customStepperConfig), + props.startSaleNum, + props.quota, + ]); + + const checkState = (min: number, max: number) => { + // 如果选择小于起售,则强制变为起售 + if (props.currentNum < min || min > max) { + props.onChange(min); + } else if (props.currentNum > max) { + // 当前选择数量大于最大可选时,需要重置已选数量 + props.onChange(max); + } + props.onSkuStepperState({ + valid: min <= max, + min, + max, + limitType, + quota: props.quota, + quotaUsed: props.quotaUsed, + startSaleNum: props.startSaleNum, + }); + }; + + const setCurrentNum = (num: number) => { + props.onChange(num); + checkState(stepperMinLimit, stepperLimit); + }; + + const onChange = (currentValue: any) => { + // setUpdateKey(updateKey + 1); + const intValue = parseInt(currentValue, 10); + const { handleStepperChange } = props.customStepperConfig; + if (handleStepperChange) handleStepperChange(intValue); + setCurrentNum(currentValue); + }; + + return ( +
+
{props.stepperTitle}
+ + + + + + {!props.hideQuotaText && quotaContent && ( + {quotaContent} + )} +
+ ); +}; + +SkuStepper.defaultProps = { + quota: 0, + quotaUsed: 0, + startSaleNum: 1, + customStepperConfig: {}, +}; + +export default SkuStepper; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/bem.ts b/app/taro/src/components/designSystems/taro/SkuComponent/bem.ts new file mode 100644 index 0000000000..ef984bcfa7 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/bem.ts @@ -0,0 +1,45 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ +/* eslint-disable no-param-reassign */ +/** + * bem helper + * b() // 'button' + * b('text') // 'button__text' + * b({ disabled }) // 'button button--disabled' + * b('text', { disabled }) // 'button__text button__text--disabled' + * b(['disabled', 'primary']) // 'button button--disabled button--primary' + */ + +export type Mod = string | { [key: string]: any }; +export type Mods = Mod | Mod[]; + +function gen(name: string, mods?: Mods): string { + if (!mods) { + return ""; + } + + if (typeof mods === "string") { + return ` ${name}--${mods}`; + } + + if (Array.isArray(mods)) { + return mods.reduce((ret, item) => ret + gen(name, item), ""); + } + return Object.keys(mods).reduce( + (ret, key) => ret + (mods[key] ? gen(name, key) : ""), + "", + ); +} + +export function createBEM(name: string) { + return (el?: Mods, mods?: Mods): Mods => { + if (el && typeof el !== "string") { + mods = el; + el = ""; + } + + el = el ? `${name}__${el}` : name; + return `${el}${gen(el, mods)}`; + }; +} + +export type BEM = ReturnType; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/constants.ts b/app/taro/src/components/designSystems/taro/SkuComponent/constants.ts new file mode 100644 index 0000000000..5a3eca1bb8 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/constants.ts @@ -0,0 +1,20 @@ +export const LIMIT_TYPE = { + QUOTA_LIMIT: 0, + STOCK_LIMIT: 1, +}; + +export const UNSELECTED_SKU_VALUE_ID = ""; + +export const BORDER = "rv-hairline"; +export const BORDER_TOP = `${BORDER}--top`; +export const BORDER_LEFT = `${BORDER}--left`; +export const BORDER_RIGHT = `${BORDER}--right`; +export const BORDER_BOTTOM = `${BORDER}--bottom`; +export const BORDER_SURROUND = `${BORDER}--surround`; +export const BORDER_TOP_BOTTOM = `${BORDER}--top-bottom`; +export const BORDER_UNSET_TOP_BOTTOM = `${BORDER}-unset--top-bottom`; + +export default { + LIMIT_TYPE, + UNSELECTED_SKU_VALUE_ID, +}; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/index.ts b/app/taro/src/components/designSystems/taro/SkuComponent/index.ts new file mode 100644 index 0000000000..c6af2f36fa --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/index.ts @@ -0,0 +1,5 @@ +import Sku from "./Sku"; +import "./style/index.less"; + +export default Sku; +export { Sku }; diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/style/index.less b/app/taro/src/components/designSystems/taro/SkuComponent/style/index.less new file mode 100644 index 0000000000..9479e31eed --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/style/index.less @@ -0,0 +1,324 @@ +@import './var.less'; + +.@{rv-prefix}-sku { + + &__container { + display: flex; + flex-direction: column; + align-items: stretch; + height: 100%; + overflow-y: visible; + font-size: @font-size-md; + } + + &__body { + flex: 1 1 auto; + min-height: 44px; + } + + &__header { + display: flex; + flex-shrink: 0; + margin: 0 @padding-md; + + &__img-wrap { + flex-shrink: 0; + width: 96px; + height: 96px; + margin: @padding-sm @padding-sm @padding-sm 0; + overflow: hidden; + border-radius: @border-radius-md; + } + + &__goods-info { + display: flex; + flex-direction: column; + justify-content: flex-end; + padding: @padding-sm 20px @padding-sm 0; + } + } + + &__header-item { + margin-top: @padding-xs; + color: @gray-6; + font-size: @font-size-sm; + line-height: 16px; + } + + &__price-symbol { + font-size: @font-size-lg; + vertical-align: bottom; + } + + &__price-num { + font-weight: @font-weight-bold; + font-size: 22px; + vertical-align: bottom; + word-wrap: break-word; + } + + &__goods-price { + // for price align + margin-left: -2px; + color: @sku-theme-color; + } + + &__price-tag { + position: relative; + display: inline-block; + margin-left: @padding-xs; + padding: 0 5px; + overflow: hidden; + color: @sku-theme-color; + font-size: @font-size-sm; + line-height: 16px; + border-radius: 8px; + + &::before { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background: currentColor; + opacity: 0.1; + content: ''; + } + } + + &__group-container { + padding-top: @padding-sm; + + &--hide-soldout { + .@{rv-prefix}-sku-row__item--disabled { + display: none; + } + } + } + + /* sku row */ + &-row { + margin: 0 @padding-md @padding-sm; + + &:last-child { + margin-bottom: 0; + } + + &__item, + &__image-item { + position: relative; + overflow: hidden; + color: @text-color; + border-radius: @border-radius-md; + cursor: pointer; + + &::before { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background: @sku-item-background-color; + content: ''; + } + + &--active { + color: @sku-theme-color; + + &::before { + background: currentColor; + opacity: 0.1; + } + } + } + + &__item { + display: inline-flex; + align-items: center; + justify-content: center; + min-width: 40px; + margin: 0 @padding-sm @padding-sm 0; + font-size: 13px; + line-height: 16px; + vertical-align: middle; + + &-img { + z-index: 1; + width: 24px; + height: 24px; + margin: 4px 0 4px 4px; + object-fit: cover; + border-radius: @border-radius-sm; + } + + &-name { + z-index: 1; + padding: @padding-xs; + } + + &--disabled { + color: @gray-5; + background: @active-color; + cursor: not-allowed; + + .@{rv-prefix}-sku-row__item-img { + opacity: 0.3; + } + } + } + + &__image { + margin-right: 0; + + &-item { + display: flex; + flex-direction: column; + width: 110px; + margin: 0 4px 4px 0; + border: 1px solid transparent; + + &:last-child { + margin-right: 0; + } + + &-img { + width: 100%; + height: 110px; + + &-icon { + position: absolute; + top: 0; + right: 0; + z-index: 3; + width: 18px; + height: 18px; + color: #fff; + line-height: 18px; + text-align: center; + background-color: rgba(0, 0, 0, 0.4); + border-bottom-left-radius: @border-radius-md; + } + } + + &-name { + position: relative; + display: flex; + align-items: center; + justify-content: center; + box-sizing: border-box; + height: 40px; + padding: @padding-base; + font-size: 12px; + line-height: 16px; + + span { + word-wrap: break-word; + } + } + + &--active { + border-color: currentColor; + } + + &--disabled { + color: @gray-5; + cursor: not-allowed; + + &::before { + z-index: 2; + background: @active-color; + opacity: 0.4; + } + } + } + } + + &__title { + padding-bottom: @padding-sm; + } + + &__title-multiple { + color: @gray-6; + } + + &__scroller { + margin: 0 -@padding-md; + overflow-x: scroll; + overflow-y: hidden; + -webkit-overflow-scrolling: touch; + + &::-webkit-scrollbar { + display: none; + } + } + + &__row { + display: inline-flex; + margin-bottom: 4px; + padding: 0 @padding-md; + } + + &__indicator { + width: 40px; + height: 4px; + background: @gray-3; + border-radius: 2px; + + &-wrapper { + display: flex; + justify-content: center; + padding-bottom: 16px; + } + + &-slider { + width: 50%; + height: 100%; + background-color: @red; + border-radius: 2px; + } + } + } + + &__stepper-stock { + padding: @padding-sm @padding-md; + overflow: hidden; + line-height: 30px; + } + + &__stepper { + float: right; + padding-left: @padding-base; + + &-title { + float: left; + } + + &-quota { + float: right; + color: @red; + font-size: @font-size-sm; + } + } + + &__stock { + display: inline-block; + margin-right: @padding-xs; + color: @gray-6; + font-size: @font-size-sm; + + &-num--highlight { + color: @red; + } + } + + &__actions { + flex-shrink: 0; + padding: 0 @padding-md; + .@{rv-prefix}-action-bar { + position: relative; + .@{rv-prefix}-button { + margin: 0; + } + } + } +} diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/style/var.less b/app/taro/src/components/designSystems/taro/SkuComponent/style/var.less new file mode 100644 index 0000000000..7e16f60fcd --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/style/var.less @@ -0,0 +1,6 @@ +@import '../../rvStyle/var.less'; + +@sku-theme-color: var(--sku-theme-color, @red); +@sku-item-background-color: @gray-1; +@sku-icon-gray-color: @gray-4; +@sku-upload-mask-color: rgba(50, 50, 50, 0.8); diff --git a/app/taro/src/components/designSystems/taro/SkuComponent/utils.ts b/app/taro/src/components/designSystems/taro/SkuComponent/utils.ts new file mode 100644 index 0000000000..1f86db156e --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SkuComponent/utils.ts @@ -0,0 +1,204 @@ +import { UNSELECTED_SKU_VALUE_ID } from "./constants"; +import { SelectedSkuData, SkuData } from "./PropsType"; + +export type SelectedValueType = { + ks: string; + imgUrl: string; + position: number; +}; + +export function getSkuImgValue( + sku: SkuData, + selectedSku: SelectedSkuData, +): SelectedValueType | undefined { + let imgValue; + + sku.tree.some((item) => { + const id = selectedSku[item.k_s]; + + if (id && item.v) { + const matchedSkuIdx = item.v.findIndex((skuValue) => skuValue.id === id); + const matchedSku = item.v[matchedSkuIdx]; + + const img = + matchedSku?.previewImgUrl || matchedSku?.imgUrl || matchedSku?.img_url; + if (img) { + imgValue = { + ...matchedSku, + ks: item.k_s, + imgUrl: img, + position: matchedSkuIdx, + }; + return true; + } + } + + return false; + }); + + return imgValue; +} + +/* + normalize sku tree + + [ + { + count: 2, + k: "品种", // 规格名称 skuKeyName + k_id: "1200", // skuKeyId + k_s: "s1" // skuKeyStr + v: [ // skuValues + { // skuValue + id: "1201", // skuValueId + name: "萌" // 具体的规格值 skuValueName + }, { + id: "973", + name: "帅" + } + ] + }, + ... + ] + | + v + { + s1: [{ + id: "1201", + name: "萌" + }, { + id: "973", + name: "帅" + }], + ... + } + */ +export const normalizeSkuTree = (skuTree: any) => { + const normalizedTree: any = {}; + skuTree.forEach((treeItem: any) => { + normalizedTree[treeItem.k_s] = treeItem.v; + }); + return normalizedTree; +}; + +export const normalizePropList = (propList: any) => { + const normalizedProp: any = {}; + propList.forEach((item: any) => { + const itemObj: any = {}; + item.v.forEach((it: any) => { + itemObj[it.id] = it; + }); + normalizedProp[item.k_id] = itemObj; + }); + return normalizedProp; +}; + +// 判断是否所有的sku都已经选中 +export const isAllSelected = (skuTree: any, selectedSku: any) => { + // 筛选selectedSku对象中key值不为空的值 + const selected = Object.keys(selectedSku).filter( + (skuKeyStr) => selectedSku[skuKeyStr] !== UNSELECTED_SKU_VALUE_ID, + ); + return skuTree.length === selected.length; +}; + +// 根据已选择的 sku 获取 skuComb +export const getSkuComb = (skuList: any, selectedSku: any) => { + const skuComb = skuList.filter((item: any) => + Object.keys(selectedSku).every( + (skuKeyStr) => String(item[skuKeyStr]) === String(selectedSku[skuKeyStr]), + ), + ); + return skuComb[0]; +}; + +// 获取已选择的sku名称 +export const getSelectedSkuValues = (skuTree: any, selectedSku: any) => { + const normalizedTree = normalizeSkuTree(skuTree); + return Object.keys(selectedSku).reduce((selectedValues: any, skuKeyStr) => { + const skuValues = normalizedTree[skuKeyStr]; + const skuValueId = selectedSku[skuKeyStr]; + + if (skuValueId !== UNSELECTED_SKU_VALUE_ID) { + const skuValue = skuValues.filter( + (value: any) => value.id === skuValueId, + )[0]; + // eslint-disable-next-line @typescript-eslint/no-unused-expressions + skuValue && selectedValues.push(skuValue); + } + return selectedValues; + }, []); +}; + +// 判断sku是否可选 +export const isSkuChoosable = ( + skuList: any, + selectedSku: any, + skuToChoose: any, +) => { + const { key, valueId } = skuToChoose; + + // 先假设sku已选中,拼入已选中sku对象中 + const matchedSku = { + ...selectedSku, + [key]: valueId, + }; + + // 再判断剩余sku是否全部不可选,若不可选则当前sku不可选中 + const skusToCheck = Object.keys(matchedSku).filter( + (skuKey) => matchedSku[skuKey] !== UNSELECTED_SKU_VALUE_ID, + ); + + const filteredSku = skuList.filter((sku: any) => + skusToCheck.every( + (skuKey) => String(matchedSku[skuKey]) === String(sku[skuKey]), + ), + ); + + const stock = filteredSku.reduce((total: any, sku: any) => { + total += sku.stock_num; + return total; + }, 0); + return stock > 0; +}; + +export const getSelectedPropValues = (propList: any, selectedProp: any) => { + const normalizeProp: any = normalizePropList(propList); + return Object.keys(selectedProp).reduce((acc: any, cur) => { + selectedProp[cur].forEach((it: any) => { + acc.push({ + ...normalizeProp[cur][it], + }); + }); + return acc; + }, []); +}; + +export const getSelectedProperties = (propList: any, selectedProp: any) => { + const list: any = []; + (propList || []).forEach((prop: any) => { + if (selectedProp[prop.k_id] && selectedProp[prop.k_id].length > 0) { + const v: any = []; + prop.v.forEach((it: any) => { + if (selectedProp[prop.k_id].indexOf(it.id) > -1) { + v.push({ ...it }); + } + }); + list.push({ + ...prop, + v, + }); + } + }); + return list; +}; + +export default { + normalizeSkuTree, + getSkuComb, + getSelectedSkuValues, + isAllSelected, + isSkuChoosable, + getSelectedPropValues, + getSelectedProperties, +}; diff --git a/app/taro/src/components/designSystems/taro/SwiperComponent.tsx b/app/taro/src/components/designSystems/taro/SwiperComponent.tsx new file mode 100644 index 0000000000..e906e1f4f5 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/SwiperComponent.tsx @@ -0,0 +1,42 @@ +import React from "react"; +import { Swiper, Image } from "@taroify/core"; +import { PhotoFail } from "@taroify/icons"; +import _ from "lodash"; +import { styled } from "linaria/react"; + +interface SwiperComponentProps { + list: any[]; + urlKey: string; +} + +const Empty = styled.div` + display: flex; + align-items: center; + justify-content: center; + font-size: 32px; + color: #fff; + background: var(--primary-color); + height: 100%; +`; + +const SwiperComponent = (props: SwiperComponentProps) => { + const { list, urlKey } = props; + const items = _.isArray(list) ? list : []; + const key = urlKey + items.length; + return ( + + + {items.map((item, index) => { + const url = _.isString(item) ? item : item?.[urlKey]; + const content = url ? ( + } /> + ) : ( + {index + 1} + ); + return {content}; + })} + + ); +}; + +export default SwiperComponent; diff --git a/app/taro/src/components/designSystems/taro/TabBar.tsx b/app/taro/src/components/designSystems/taro/TabBar.tsx new file mode 100644 index 0000000000..55700fa609 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/TabBar.tsx @@ -0,0 +1,56 @@ +import React, { useContext } from "react"; +import { styled } from "linaria/react"; +import { + getViewModePageList, + getCurrentPageId, + getShowTabBar, +} from "selectors/editorSelectors"; +import { PageListPayload } from "constants/ReduxActionConstants"; +import { Tabbar, SafeArea } from "@taroify/core"; +import { createVanIconComponent } from "@taroify/icons/van"; +import { fetchPublishedPage } from "actions/pageActions"; +import ReduxContext from "components/common/ReduxContext"; + +const TabBarContainer = styled.div` + position: fixed; + left: 0; + right: 0; + bottom: 0; +`; + +const TabBar = () => { + const { useDispatch, useSelector } = useContext(ReduxContext); + const dispatch = useDispatch(); + const pages: PageListPayload = useSelector(getViewModePageList)?.filter( + (p: any) => !!p.icon + ); + const currentPageId = useSelector(getCurrentPageId); + const showTabBar = useSelector(getShowTabBar); + + const jumpTo = (target: string) => { + dispatch(fetchPublishedPage(target, false)); + }; + + if (!showTabBar) { + return null; + } + + return ( + + + {pages.map((page: any) => { + const { pageName, pageId, icon } = page; + const Icon = createVanIconComponent(icon as any); + return ( + } key={pageId} value={pageId}> + {pageName} + + ); + })} + + + + ); +}; + +export default TabBar; diff --git a/app/taro/src/components/designSystems/taro/TextComponent.tsx b/app/taro/src/components/designSystems/taro/TextComponent.tsx new file mode 100644 index 0000000000..977b8fc134 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/TextComponent.tsx @@ -0,0 +1,85 @@ +import * as React from "react"; +import { Text, View } from "@tarojs/components"; +import { styled } from "linaria/react"; +import { ComponentProps } from "components/designSystems/appsmith/BaseComponent"; +import { + FontStyleTypes, + TextSize, + TEXT_SIZES, +} from "constants/WidgetConstants"; +import { transformDynamicSize } from "utils/AppsmithUtils"; + +export const TextContainer = styled(View)` + height: 100%; + width: 100%; +`; + +export const StyledText = styled(Text)<{ + scroll: boolean; + textAlign: string; + backgroundColor?: string; + textColor?: string; + fontStyle?: string; + fontSize?: TextSize; +}>` + height: 100%; + overflow-y: ${(props) => (props.scroll ? "auto" : "hidden")}; + text-overflow: ellipsis; + text-align: ${(props) => props.textAlign.toLowerCase()}; + display: flex; + width: 100%; + justify-content: ${(props) => + props.textAlign === "LEFT" + ? "flex-start" + : props.textAlign === "RIGHT" + ? "flex-end" + : "center"}; + align-items: ${(props) => (props.scroll ? "flex-start" : "center")}; + background: ${(props) => props?.backgroundColor}; + color: ${(props) => props?.textColor}; + font-style: ${(props) => + props?.fontStyle?.includes(FontStyleTypes.ITALIC) ? "italic" : ""}; + text-decoration: ${(props) => + props?.fontStyle?.includes(FontStyleTypes.LINETHROUGH) + ? "line-through" + : ""}; + font-weight: ${(props) => + props?.fontStyle?.includes(FontStyleTypes.BOLD) ? "bold" : "normal"}; + font-size: ${(props) => transformDynamicSize(parseInt(TEXT_SIZES[props?.fontSize]))}; +`; + +export type TextAlign = "LEFT" | "CENTER" | "RIGHT" | "JUSTIFY"; + +export interface TextComponentProps extends ComponentProps { + text?: string; + textAlign: TextAlign; + fontSize?: TextSize; + isLoading: boolean; + shouldScroll?: boolean; + backgroundColor?: string; + textColor?: string; + fontStyle?: string; +} + +class TextComponent extends React.Component { + render() { + const { backgroundColor, fontSize, fontStyle, text, textAlign, textColor } = + this.props; + return ( + + + {text} + + + ); + } +} + +export default TextComponent; diff --git a/app/taro/src/components/designSystems/taro/rvStyle/var.less b/app/taro/src/components/designSystems/taro/rvStyle/var.less new file mode 100644 index 0000000000..ca41afd009 --- /dev/null +++ b/app/taro/src/components/designSystems/taro/rvStyle/var.less @@ -0,0 +1,88 @@ +// 基本单位 +@hd: 1px; + +// 全局/品牌色 +@brand-color: #3f45ff; + +// Color Palette +@black: #000; +@white: #fff; +@gray-1: #f7f8fa; +@gray-2: #f2f3f5; +@gray-3: #ebedf0; +@gray-4: #dcdee0; +@gray-5: #c8c9cc; +@gray-6: #969799; +@gray-7: #646566; +@gray-8: #323233; +@blue: @brand-color; +@red: #f44336; +@orange: #ff976a; +@orange-dark: #ff590d; +@orange-light: #fffbe8; +@green: #00c853; + +// The prefix to use on all css classes from react-vant. +@rv-prefix: rv; + +// Grid system +@grid-columns: 24; + +// Gradient Colors +@gradient-red: linear-gradient(to right, #ff6034, #ee0a24); +@gradient-orange: linear-gradient(to right, #ffd01e, #ff8917); + +// Component Colors +@primary-color: @blue; +@success-color: @green; +@danger-color: @red; +@warning-color: @orange; +@text-color: @gray-8; +@active-color: @gray-2; +@active-opacity: 0.7; +@disabled-opacity: 0.5; +@background-color: @gray-1; +@background-color-light: #fafafa; +@text-link-color: #576b95; + +// Padding +@padding-base: 4 * @hd; +@padding-xs: @padding-base * 2; +@padding-sm: @padding-base * 3; +@padding-md: @padding-base * 4; +@padding-lg: @padding-base * 6; +@padding-xl: @padding-base * 8; + +// Font +@font-size-xs: 10 * @hd; +@font-size-sm: 12 * @hd; +@font-size-md: 14 * @hd; +@font-size-lg: 16 * @hd; +@font-size-xl: 18 * @hd; +@font-size-xxl: 20 * @hd; +@font-size-xxxl: 24 * @hd; +@font-weight-bold: 500; +@line-height-xs: 14 * @hd; +@line-height-sm: 18 * @hd; +@line-height-md: 20 * @hd; +@line-height-lg: 22 * @hd; +@line-height-xl: 24 * @hd; +@line-height-xxl: 28 * @hd; +@line-height-xxxl: 32 * @hd; +@base-font-family: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Helvetica, Segoe UI, Arial, + Roboto, 'PingFang SC', 'miui', 'Hiragino Sans GB', 'Microsoft Yahei', sans-serif; +@price-integer-font-family: Avenir-Heavy, PingFang SC, Helvetica Neue, Arial, sans-serif; + +// Animation +@animation-duration-base: 0.3s; +@animation-duration-fast: 0.2s; +@animation-timing-function-enter: ease-out; +@animation-timing-function-leave: ease-in; + +// Border +@border-color: @gray-3; +@border-width-base: 1 * @hd; +@border-radius-sm: 2 * @hd; +@border-radius-md: 4 * @hd; +@border-radius-lg: 8 * @hd; +@border-radius-max: 999 * @hd; diff --git a/app/taro/src/components/editorComponents/EditorContextProvider.tsx b/app/taro/src/components/editorComponents/EditorContextProvider.tsx new file mode 100644 index 0000000000..87cd8bfe54 --- /dev/null +++ b/app/taro/src/components/editorComponents/EditorContextProvider.tsx @@ -0,0 +1,33 @@ +import React, { Context, createContext } from "react"; +import { WidgetOperation } from "widgets/BaseWidget"; +import { BatchPropertyUpdatePayload } from "actions/controlActions"; +import { ExecuteActionPayload } from "constants/AppsmithActionConstants/ActionConstants"; +import { OccupiedSpace } from "constants/editorConstants"; + +export type EditorContextType = { + executeAction?: (actionPayloads: ExecuteActionPayload) => void; + updateWidget?: ( + operation: WidgetOperation, + widgetId: string, + payload: any + ) => void; + updateWidgetProperty?: ( + widgetId: string, + propertyName: string, + propertyValue: any + ) => void; + updateWidgetMetaProperty?: ( + widgetId: string, + propertyName: string, + propertyValue: any + ) => void; + resetChildrenMetaProperty?: (widgetId: string) => void; + disableDrag?: (disable: boolean) => void; + occupiedSpaces?: { [containerWidgetId: string]: OccupiedSpace[] }; + deleteWidgetProperty?: (widgetId: string, propertyPaths: string[]) => void; + batchUpdateWidgetProperty?: ( + widgetId: string, + updates: BatchPropertyUpdatePayload + ) => void; +}; +export const EditorContext: Context = createContext({}); diff --git a/app/taro/src/components/editorComponents/ErrorBoundry.tsx b/app/taro/src/components/editorComponents/ErrorBoundry.tsx new file mode 100644 index 0000000000..993b7d43a4 --- /dev/null +++ b/app/taro/src/components/editorComponents/ErrorBoundry.tsx @@ -0,0 +1,56 @@ +import React, { ReactNode } from "react"; +import { styled } from 'linaria/react'; + +type Props = { children: ReactNode }; +type State = { hasError: boolean }; + +const ErrorBoundaryContainer = styled.div` + height: 100%; + width: 100%; + + > div { + height: 100%; + width: 100%; + } +`; + +const RetryLink = styled.span` + color: #000; + cursor: pointer; +`; + +class ErrorBoundary extends React.Component { + constructor(props: Props) { + super(props); + this.state = { hasError: false }; + } + + static getDerivedStateFromError() { + // Update state so the next render will show the fallback UI. + return { hasError: true }; + } + + componentDidCatch(error: any, errorInfo: any) { + console.error({ error, errorInfo }); + } + + render() { + return ( + + {this.state.hasError ? ( +

+ 出现错误了 +
+ this.setState({ hasError: false })}> + 点击重试 + +

+ ) : ( + this.props.children + )} +
+ ); + } +} + +export default ErrorBoundary; diff --git a/app/taro/src/components/editorComponents/PreventInteractionsOverlay.tsx b/app/taro/src/components/editorComponents/PreventInteractionsOverlay.tsx new file mode 100644 index 0000000000..1152426df0 --- /dev/null +++ b/app/taro/src/components/editorComponents/PreventInteractionsOverlay.tsx @@ -0,0 +1,50 @@ +import React from "react"; +import { styled } from 'linaria/react'; + +const StyledPreventInteractionsOverlay = styled.div` + position: absolute; + left: 0; + right: 0; + bottom: 0; + top: 0; +`; + +const Container = styled.div` + width: 100%; + height: 100%; + position: relative; + + > div { + height: 100%; + } +`; + +type Props = { + children: React.ReactNode; + widgetType: string; +}; + +const preventInteractionsBlacklist = [ + "CONTAINER_WIDGET", + "CANVAS_WIDGET", + "TABS_WIDGET", + "FORM_WIDGET", +]; + +/** + * Prevent interactions with the component + */ +function PreventInteractionsOverlay({ children, widgetType }: Props) { + const isComponentBlacklisted = + preventInteractionsBlacklist.indexOf(widgetType) !== -1; + const shouldPreventInteraction = !isComponentBlacklisted; + + return ( + + {children} + {shouldPreventInteraction && } + + ); +} + +export default PreventInteractionsOverlay; diff --git a/app/taro/src/components/formControls/BaseControl.tsx b/app/taro/src/components/formControls/BaseControl.tsx new file mode 100644 index 0000000000..4fb0c69e84 --- /dev/null +++ b/app/taro/src/components/formControls/BaseControl.tsx @@ -0,0 +1,73 @@ +import { Component } from "react"; +import { ControlType } from "constants/PropertyControlConstants"; + +export const InputTypes = { + TEXT: "TEXT", + NUMBER: "NUMBER", + INTEGER: "INTEGER", + PHONE_NUMBER: "PHONE_NUMBER", + EMAIL: "EMAIL", + PASSWORD: "PASSWORD", + CURRENCY: "CURRENCY", + SEARCH: "SEARCH", +}; +export type InputType = typeof InputTypes[keyof typeof InputTypes]; + +// eslint-disable-next-line @typescript-eslint/ban-types +abstract class BaseControl

extends Component< + P, + S +> { + abstract getControlType(): ControlType; +} + +export type ComparisonOperations = + | "EQUALS" + | "NOT_EQUALS" + | "LESSER" + | "GREATER" + | "IN" + | "NOT_IN"; + +export type HiddenType = boolean | Condition | ConditionObject; + +export type ConditionObject = { conditionType: string; conditions: Conditions }; + +export type Condition = { + path: string; + comparison: ComparisonOperations; + value: any; +}; + +export type Conditions = Array | ConditionObject; +export interface ControlBuilder { + buildPropertyControl(controlProps: T): JSX.Element; +} + +export interface ControlProps extends ControlData, ControlFunctions { + key?: string; + extraData?: ControlData[]; + formName: string; +} + +export interface ControlData { + id: string; + label: string; + configProperty: string; + controlType: ControlType; + propertyValue?: any; + isValid: boolean; + validationMessage?: string; + validationRegex?: string; + dataType?: InputType; + isRequired?: boolean; + hidden?: HiddenType; + placeholderText?: string; + schema?: any; +} + +export interface ControlFunctions { + onPropertyChange?: (propertyName: string, propertyValue: string) => void; +} + +export default BaseControl; diff --git a/app/taro/src/components/formControls/utils.ts b/app/taro/src/components/formControls/utils.ts new file mode 100644 index 0000000000..9f46143ffa --- /dev/null +++ b/app/taro/src/components/formControls/utils.ts @@ -0,0 +1,147 @@ +import { isBoolean, get, map, set } from "lodash"; +import { HiddenType } from "./BaseControl"; + +export const evaluateCondtionWithType = ( + conditions: Array | undefined, + type: string | undefined, +) => { + if (conditions) { + let flag; + //this is where each conditions gets evaluated + if (conditions.length > 1) { + if (type === "AND") { + flag = conditions.reduce((acc: any, item: boolean) => { + return acc && item; + }, conditions[0]); + } else if (type === "OR") { + flag = conditions.reduce((acc: any, item: boolean) => { + return acc || item; + }, undefined); + } + } else { + flag = conditions[0]; + } + return flag; + } +}; + +export const isHiddenConditionsEvaluation = ( + values: any, + hidden?: HiddenType, +): any => { + if (!!hidden && !isBoolean(hidden)) { + //if nested condtions are there recursively from bottom to top call this function on each condtion + let conditionType, conditions; + if ("conditionType" in hidden) { + conditionType = hidden.conditionType; + } + if ("conditions" in hidden) { + conditions = hidden.conditions; + } + if (Array.isArray(conditions)) { + conditions = conditions.map((rule: any) => { + return isHiddenConditionsEvaluation(values, rule); + }); + } else { + return caculateIsHidden(values, hidden); + } + return evaluateCondtionWithType(conditions, conditionType); + } +}; + +export const caculateIsHidden = (values: any, hiddenConfig?: HiddenType) => { + if (!!hiddenConfig && !isBoolean(hiddenConfig)) { + let valueAtPath; + let value, comparison; + if ("path" in hiddenConfig) { + valueAtPath = get(values, hiddenConfig.path); + } + if ("value" in hiddenConfig) { + value = hiddenConfig.value; + } + if ("comparison" in hiddenConfig) { + comparison = hiddenConfig.comparison; + } + + switch (comparison) { + case "EQUALS": + return valueAtPath === value; + case "NOT_EQUALS": + return valueAtPath !== value; + case "GREATER": + return valueAtPath > value; + case "LESSER": + return valueAtPath < value; + case "IN": + return Array.isArray(value) && value.includes(valueAtPath); + case "NOT_IN": + return Array.isArray(value) && !value.includes(valueAtPath); + default: + return true; + } + } +}; + +export const isHidden = (values: any, hiddenConfig?: HiddenType) => { + if (!!hiddenConfig && !isBoolean(hiddenConfig)) { + if ("conditionType" in hiddenConfig) { + //check if nested conditions exist + return isHiddenConditionsEvaluation(values, hiddenConfig); + } else { + return caculateIsHidden(values, hiddenConfig); + } + } + return !!hiddenConfig; +}; + +export const getConfigInitialValues = (config: Record[]) => { + const configInitialValues = {}; + if (!Array.isArray(config)) return configInitialValues; + + const parseConfig = (section: any): any => { + return map(section.children, (subSection: any) => { + if ("children" in subSection) { + return parseConfig(subSection); + } + + if ("initialValue" in subSection) { + if (subSection.controlType === "KEYVALUE_ARRAY") { + subSection.initialValue.forEach( + (initialValue: string | number, index: number) => { + const configProperty = subSection.configProperty.replace( + "*", + index, + ); + + set(configInitialValues, configProperty, initialValue); + }, + ); + } else { + set( + configInitialValues, + subSection.configProperty, + subSection.initialValue, + ); + } + } + }); + }; + + config.forEach((section: any) => { + parseConfig(section); + }); + + return configInitialValues; +}; + +export const actionPathFromName = ( + actionName: string, + name: string, +): string => { + const ActionConfigStarts = "actionConfiguration."; + let path = name; + if (path.startsWith(ActionConfigStarts)) { + path = "config." + path.substr(ActionConfigStarts.length); + } + return `${actionName}.${path}`; +}; diff --git a/app/taro/src/components/propertyControls/BaseControl.tsx b/app/taro/src/components/propertyControls/BaseControl.tsx new file mode 100644 index 0000000000..2862bf5bc5 --- /dev/null +++ b/app/taro/src/components/propertyControls/BaseControl.tsx @@ -0,0 +1,53 @@ +/*** + * Controls are rendered in the property panel from the property config + * Controls are higher order components that update a widgets property + */ +import { Component } from "react"; +import _ from "lodash"; +import { PropertyPaneControlConfig } from "constants/PropertyControlConstants"; + +// eslint-disable-next-line @typescript-eslint/ban-types +abstract class BaseControl

extends Component< + P, + S +> { + updateProperty(propertyName: string, propertyValue: any) { + if (!_.isNil(this.props.onPropertyChange)) + this.props.onPropertyChange(propertyName, propertyValue); + } + deleteProperties(propertyPaths: string[]) { + if (this.props.deleteProperties) { + this.props.deleteProperties(propertyPaths); + } + } +} + +export interface ControlBuilder { + buildPropertyControl(controlProps: T): JSX.Element; +} + +export interface ControlProps extends ControlData, ControlFunctions { + key?: string; + additionalAutoComplete?: Record>; +} +export interface ControlData + extends Omit { + propertyValue?: any; + errorMessage?: string; + expected?: any; + evaluatedValue: any; + widgetProperties: any; + useValidationMessage?: boolean; + parentPropertyName: string; + parentPropertyValue: unknown; + additionalDynamicData: Record>; +} +export interface ControlFunctions { + onPropertyChange?: (propertyName: string, propertyValue: string) => void; + openNextPanel: (props: any) => void; + deleteProperties: (propertyPaths: string[]) => void; + theme: any; + hideEvaluatedValue?: boolean; +} + +export default BaseControl; diff --git a/app/taro/src/components/propertyControls/index.ts b/app/taro/src/components/propertyControls/index.ts new file mode 100644 index 0000000000..db06e34671 --- /dev/null +++ b/app/taro/src/components/propertyControls/index.ts @@ -0,0 +1,20 @@ +import BaseControl, { + ControlProps, +} from "components/propertyControls/BaseControl"; + +export const PropertyControls = { +}; + +export type PropertyControlPropsType = + | ControlProps; + +export const getPropertyControlTypes = (): { [key: string]: string } => { + const _types: { [key: string]: string } = {}; + Object.values(PropertyControls).forEach( + (Control: typeof BaseControl & { getControlType: () => string }) => { + const controlType = Control.getControlType(); + _types[controlType] = controlType; + }, + ); + return _types; +}; diff --git a/app/taro/src/configs/index.ts b/app/taro/src/configs/index.ts new file mode 100644 index 0000000000..fcb36fab71 --- /dev/null +++ b/app/taro/src/configs/index.ts @@ -0,0 +1,28 @@ +import { AppsmithUIConfigs } from "./types"; + +export type INJECTED_CONFIGS = { + logLevel: "debug" | "error"; +}; +declare global { + interface Window { + APPSMITH_FEATURE_CONFIGS: INJECTED_CONFIGS; + Intercom: any; + } +} + +const getConfigsFromEnvVars = (): INJECTED_CONFIGS => { + return { + logLevel: + (process.env.REACT_APP_CLIENT_LOG_LEVEL as + | "debug" + | "error" + | undefined) || "error", + }; +}; + +export const getAppsmithConfigs = (): AppsmithUIConfigs => { + const ENV_CONFIG = getConfigsFromEnvVars(); + return { + logLevel: ENV_CONFIG.logLevel, + }; +}; diff --git a/app/taro/src/configs/types.ts b/app/taro/src/configs/types.ts new file mode 100644 index 0000000000..0558db8697 --- /dev/null +++ b/app/taro/src/configs/types.ts @@ -0,0 +1,21 @@ +import { LogLevelDesc } from "loglevel"; + +export type SentryConfig = { + dsn: string; + environment: string; +}; + +export enum FeatureFlagsEnum {} + +export type FeatureFlags = Record; + +export type FeatureFlagConfig = { + remoteConfig?: { + optimizely: string; + }; + default: FeatureFlags; +}; + +export type AppsmithUIConfigs = { + logLevel: LogLevelDesc; +}; diff --git a/app/taro/src/constants/ApiConstants.tsx b/app/taro/src/constants/ApiConstants.tsx new file mode 100644 index 0000000000..eac8f9f405 --- /dev/null +++ b/app/taro/src/constants/ApiConstants.tsx @@ -0,0 +1,31 @@ +export const REQUEST_TIMEOUT_MS = 20000; +export const DEFAULT_ACTION_TIMEOUT = 10000; +export const DEFAULT_EXECUTE_ACTION_TIMEOUT_MS = 15000; +export const DEFAULT_TEST_DATA_SOURCE_TIMEOUT_MS = 30000; + +export enum API_STATUS_CODES { + REQUEST_NOT_AUTHORISED = 401, + RESOURCE_NOT_FOUND = 404, + SERVER_ERROR = 502, + SERVER_UNAVAILABLE = 503, +} + +export enum SERVER_ERROR_CODES { + INCORRECT_BINDING_LIST_OF_WIDGET = 4022, + RESOURCE_NOT_FOUND = 4028, +} + +export enum ERROR_CODES { + PAGE_NOT_FOUND = "PAGE_NOT_FOUND", + SERVER_ERROR = "SERVER_ERROR", + REQUEST_NOT_AUTHORISED = "REQUEST_NOT_AUTHORIZED", + REQUEST_TIMEOUT = "REQUEST_TIMEOUT", + FAILED_TO_CORRECT_BINDING = "FAILED_TO_CORRECT_BINDING", +} + +export const OAuthURL = "/oauth2/authorization"; +export const GoogleOAuthURL = `${OAuthURL}/google`; +export const GithubOAuthURL = `${OAuthURL}/github`; + +export const LOGIN_SUBMIT_PATH = "login"; +export const SIGNUP_SUBMIT_PATH = "users"; diff --git a/app/taro/src/constants/ApiEditorConstants.ts b/app/taro/src/constants/ApiEditorConstants.ts new file mode 100644 index 0000000000..61d22b5f6c --- /dev/null +++ b/app/taro/src/constants/ApiEditorConstants.ts @@ -0,0 +1,76 @@ +import { ApiActionConfig } from "entities/Action"; +import { DEFAULT_ACTION_TIMEOUT } from "constants/ApiConstants"; +import { zipObject } from "lodash"; + +export const HTTP_METHODS = ["GET", "POST", "PUT", "DELETE", "PATCH"]; +const HTTP_METHOD_COLORS = [ + "#457AE6", + "#EABB0C", + "#5BB749", + "#E22C2C", + "#6D6D6D", +]; + +export const HTTP_METHOD_COLOR_MAP = zipObject( + HTTP_METHODS, + HTTP_METHOD_COLORS, +); + +export const HTTP_METHOD_OPTIONS = HTTP_METHODS.map((method) => ({ + value: method, +})); + +export const REST_PLUGIN_PACKAGE_NAME = "restapi-plugin"; + +export const EMPTY_KEY_VALUE_PAIRS = [ + { key: "", value: "" }, + { key: "", value: "" }, +]; + +export const DEFAULT_API_ACTION_CONFIG: ApiActionConfig = { + timeoutInMillisecond: DEFAULT_ACTION_TIMEOUT, + encodeParamsToggle: true, + httpMethod: HTTP_METHODS[0], + headers: EMPTY_KEY_VALUE_PAIRS.slice(), + queryParameters: EMPTY_KEY_VALUE_PAIRS.slice(), + body: "", + pluginSpecifiedTemplates: [ + { + // JSON smart substitution + value: true, + }, + ], +}; + +export const DEFAULT_PROVIDER_OPTION = "Business Software"; +export const CONTENT_TYPE_HEADER_KEY = "content-type"; + +export enum ApiContentTypes { + JSON = "json", + FORM_URLENCODED = "x-www-form-urlencoded", + MULTIPART_FORM_DATA = "form-data", + RAW = "raw", +} + +export const POST_BODY_FORMAT_OPTIONS: Array<{ + label: ApiContentTypes; + value: string; +}> = [ + { label: ApiContentTypes.JSON, value: "application/json" }, + { + label: ApiContentTypes.FORM_URLENCODED, + value: "application/x-www-form-urlencoded", + }, + { label: ApiContentTypes.MULTIPART_FORM_DATA, value: "multipart/form-data" }, + { label: ApiContentTypes.RAW, value: "raw" }, +]; + +export const POST_BODY_FORMATS = POST_BODY_FORMAT_OPTIONS.map((option) => { + return option.value; +}); + +export const POST_BODY_FORMAT_TITLES = POST_BODY_FORMAT_OPTIONS.map( + (option) => { + return { title: option.label, key: option.value }; + }, +); diff --git a/app/taro/src/constants/AppConstants.ts b/app/taro/src/constants/AppConstants.ts new file mode 100644 index 0000000000..cd0dec2728 --- /dev/null +++ b/app/taro/src/constants/AppConstants.ts @@ -0,0 +1,25 @@ +import Taro from "@tarojs/taro"; + +export const CANVAS_DEFAULT_HEIGHT_PX = 1292; +export const CANVAS_DEFAULT_GRID_HEIGHT_PX = 1; +export const CANVAS_DEFAULT_GRID_WIDTH_PX = 1; +export const CANVAS_BACKGROUND_COLOR = "#FFFFFF"; + +const APP_STORE_NAMESPACE = "APPSMITH_LOCAL_STORE"; + +export const getAppStoreName = (appId: string) => + `${APP_STORE_NAMESPACE}-${appId}`; + +export const getPersistentAppStore = (appId: string) => { + const appStoreName = getAppStoreName(appId); + let storeString = "{}"; + const appStore = Taro.getStorageSync(appStoreName); + if (appStore) storeString = appStore; + let store; + try { + store = JSON.parse(storeString); + } catch (e) { + store = {}; + } + return store; +}; diff --git a/app/taro/src/constants/AppsmithActionConstants/ActionConstants.tsx b/app/taro/src/constants/AppsmithActionConstants/ActionConstants.tsx new file mode 100644 index 0000000000..a0d09ed1f9 --- /dev/null +++ b/app/taro/src/constants/AppsmithActionConstants/ActionConstants.tsx @@ -0,0 +1,143 @@ +import { ErrorActionPayload } from "sagas/ErrorSagas"; +import { ActionResponse } from "api/ActionAPI"; +import { PluginType } from "entities/Action"; +import queryActionSettingsConfig from "constants/AppsmithActionConstants/formConfig/QuerySettingsConfig"; +import apiActionSettingsConfig from "constants/AppsmithActionConstants/formConfig/ApiSettingsConfig"; +import apiActionEditorConfig from "constants/AppsmithActionConstants/formConfig/ApiEditorConfigs"; +import saasActionSettingsConfig from "constants/AppsmithActionConstants/formConfig/GoogleSheetsSettingsConfig"; +import apiActionDependencyConfig from "constants/AppsmithActionConstants/formConfig/ApiDependencyConfigs"; + +export type ExecuteActionPayloadEvent = { + type: EventType; + callback?: (result: ExecutionResult) => void; +}; + +export type ExecutionResult = { + success: boolean; +}; + +export type ExecuteActionPayload = { + dynamicString: string; + event: ExecuteActionPayloadEvent; + responseData?: Array; +}; + +// triggerPropertyName was added as a requirement for logging purposes +export type WidgetExecuteActionPayload = ExecuteActionPayload & { + triggerPropertyName?: string; +}; + +export type ContentType = + | "application/json" + | "application/x-www-form-urlencoded"; + +export interface APIHeaders { + "Content-Type": ContentType; + Accept?: string; +} + +export interface APIRequest { + requestId?: string; +} + +export enum EventType { + ON_RESET = "ON_RESET", + ON_PAGE_LOAD = "ON_PAGE_LOAD", + ON_PREV_PAGE = "ON_PREV_PAGE", + ON_NEXT_PAGE = "ON_NEXT_PAGE", + ON_PAGE_SIZE_CHANGE = "ON_PAGE_SIZE_CHANGE", + ON_ERROR = "ON_ERROR", + ON_SUCCESS = "ON_SUCCESS", + ON_ROW_SELECTED = "ON_ROW_SELECTED", + ON_SEARCH = "ON_SEARCH", + ON_CLICK = "ON_CLICK", + ON_DATA_POINT_CLICK = "ON_DATA_POINT_CLICK", + ON_FILES_SELECTED = "ON_FILES_SELECTED", + ON_HOVER = "ON_HOVER", + ON_TOGGLE = "ON_TOGGLE", + ON_LOAD = "ON_LOAD", + ON_MODAL_CLOSE = "ON_MODAL_CLOSE", + ON_TEXT_CHANGE = "ON_TEXT_CHANGE", + ON_SUBMIT = "ON_SUBMIT", + ON_CHECK_CHANGE = "ON_CHECK_CHANGE", + ON_SWITCH_CHANGE = "ON_SWITCH_CHANGE", + ON_SELECT = "ON_SELECT", + ON_DATE_SELECTED = "ON_DATE_SELECTED", + ON_DATE_RANGE_SELECTED = "ON_DATE_RANGE_SELECTED", + ON_OPTION_CHANGE = "ON_OPTION_CHANGE", + ON_MARKER_CLICK = "ON_MARKER_CLICK", + ON_CREATE_MARKER = "ON_CREATE_MARKER", + ON_TAB_CHANGE = "ON_TAB_CHANGE", + ON_VIDEO_START = "ON_VIDEO_START", + ON_VIDEO_END = "ON_VIDEO_END", + ON_VIDEO_PLAY = "ON_VIDEO_PLAY", + ON_VIDEO_PAUSE = "ON_VIDEO_PAUSE", + ON_RATE_CHANGED = "ON_RATE_CHANGED", + ON_IFRAME_URL_CHANGED = "ON_IFRAME_URL_CHANGED", + ON_IFRAME_MESSAGE_RECEIVED = "ON_IFRAME_MESSAGE_RECEIVED", + ON_FORM_SUBMIT = "ON_FORM_SUBMIT", + ON_ADD_CART = "ON_ADD_CART", + ON_BUY = "ON_BUY", +} + +export type ActionType = + | "API" + | "QUERY" + | "NAVIGATION" + | "ALERT" + | "JS_FUNCTION" + | "SET_VALUE" + | "DOWNLOAD"; + +export type DownloadFiletype = "CSV" | "XLS" | "JSON" | "TXT"; + +export interface PageAction { + id: string; + pluginType: PluginType; + name: string; + jsonPathKeys: string[]; + timeoutInMillisecond: number; +} + +export interface ExecuteErrorPayload extends ErrorActionPayload { + actionId: string; + isPageLoad?: boolean; + data: ActionResponse; +} + +// Group 1 = datasource (https://www.domain.com) +// Group 2 = path (/nested/path) +// Group 3 = params (?param=123¶m2=12) +export const urlGroupsRegexExp = /^(https?:\/{2}\S+?)(\/[\s\S]*?)(\?(?![^{]*})[\s\S]*)?$/; + +export const EXECUTION_PARAM_KEY = "executionParams"; +export const EXECUTION_PARAM_REFERENCE_REGEX = /this.params/g; + +export const RESP_HEADER_DATATYPE = "X-APPSMITH-DATATYPE"; +export const API_REQUEST_HEADERS: APIHeaders = { + "Content-Type": "application/json", +}; +export const POSTMAN = "POSTMAN"; +export const CURL = "CURL"; +export const Swagger = "Swagger"; + +export const defaultActionSettings: Record = { + [PluginType.API]: apiActionSettingsConfig, + [PluginType.DB]: queryActionSettingsConfig, + [PluginType.SAAS]: saasActionSettingsConfig, +}; + +export const defaultActionEditorConfigs: Record = { + [PluginType.API]: apiActionEditorConfig, + [PluginType.DB]: [], + [PluginType.SAAS]: [], +}; + +export const defaultActionDependenciesConfig: Record< + PluginType, + Record +> = { + [PluginType.API]: apiActionDependencyConfig, + [PluginType.DB]: {}, + [PluginType.SAAS]: {}, +}; diff --git a/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiDependencyConfigs.ts b/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiDependencyConfigs.ts new file mode 100644 index 0000000000..85ee182931 --- /dev/null +++ b/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiDependencyConfigs.ts @@ -0,0 +1,5 @@ +export default { + "actionConfiguration.body": [ + "actionConfiguration.pluginSpecifiedTemplates[0].value", + ], +}; diff --git a/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiEditorConfigs.ts b/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiEditorConfigs.ts new file mode 100644 index 0000000000..4f16a95228 --- /dev/null +++ b/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiEditorConfigs.ts @@ -0,0 +1,92 @@ +export default [ + { + sectionName: "", + id: 1, + children: [ + { + label: "Path", + configProperty: "actionConfiguration.path", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + }, + { + label: "Body", + configProperty: "actionConfiguration.body", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + evaluationSubstitutionType: "SMART_SUBSTITUTE", + hidden: { + path: "actionConfiguration.pluginSpecifiedTemplates[0].value", + comparison: "EQUALS", + value: false, + }, + }, + { + label: "Body", + configProperty: "actionConfiguration.body", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + evaluationSubstitutionType: "TEMPLATE", + hidden: { + path: "actionConfiguration.pluginSpecifiedTemplates[0].value", + comparison: "EQUALS", + value: true, + }, + }, + { + label: "Query Parameters", + configProperty: "actionConfiguration.queryParameters", + controlType: "ARRAY_FIELD", + schema: [ + { + label: "Key", + key: "key", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + placeholderText: "Key", + }, + { + label: "Value", + key: "value", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + placeholderText: "Value", + }, + ], + }, + { + label: "Headers", + configProperty: "actionConfiguration.headers", + controlType: "ARRAY_FIELD", + schema: [ + { + label: "Key", + key: "key", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + placeholderText: "Key", + }, + { + label: "Value", + key: "value", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + placeholderText: "Value", + }, + ], + }, + { + label: "Form data", + configProperty: "actionConfiguration.bodyFormData", + controlType: "ARRAY_FIELD", + schema: [ + { + label: "Key", + key: "key", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + placeholderText: "Key", + }, + { + label: "Value", + key: "value", + controlType: "QUERY_DYNAMIC_INPUT_TEXT", + placeholderText: "Value", + }, + ], + }, + ], + }, +]; diff --git a/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiSettingsConfig.ts b/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiSettingsConfig.ts new file mode 100644 index 0000000000..e8bd302a02 --- /dev/null +++ b/app/taro/src/constants/AppsmithActionConstants/formConfig/ApiSettingsConfig.ts @@ -0,0 +1,53 @@ +export default [ + { + sectionName: "", + id: 1, + children: [ + { + label: "Run API on Page load", + configProperty: "executeOnLoad", + controlType: "CHECKBOX", + info: "Will refresh data each time the page is loaded", + }, + { + label: "Request confirmation before running API", + configProperty: "confirmBeforeExecute", + controlType: "CHECKBOX", + info: "Ask confirmation from the user each time before refreshing data", + }, + { + label: "Encode query params", + configProperty: "actionConfiguration.encodeParamsToggle", + controlType: "CHECKBOX", + info: + "Encode query params for all APIs. Also encode form body when Content-Type header is set to x-www-form-encoded", + }, + { + label: "Smart JSON Substitution", + configProperty: "actionConfiguration.pluginSpecifiedTemplates[0].value", + controlType: "CHECKBOX", + info: + "Turning on this property fixes the JSON substitution of bindings in API body by adding/removing quotes intelligently and reduces developer errors", + initialValue: true, + }, + // { + // label: "Cache response", + // configProperty: "shouldCacheResponse", + // controlType: "SWITCH", + // }, + // { + // label: "Cache timeout (in milliseconds)", + // configProperty: "cacheTimeout", + // controlType: "INPUT_TEXT", + // dataType: "NUMBER", + // }, + { + label: "API timeout (in milliseconds)", + info: "Maximum time after which the API will return", + configProperty: "actionConfiguration.timeoutInMillisecond", + controlType: "NUMBER_INPUT", + dataType: "number", + }, + ], + }, +]; diff --git a/app/taro/src/constants/AppsmithActionConstants/formConfig/GoogleSheetsSettingsConfig.ts b/app/taro/src/constants/AppsmithActionConstants/formConfig/GoogleSheetsSettingsConfig.ts new file mode 100644 index 0000000000..eb875985ff --- /dev/null +++ b/app/taro/src/constants/AppsmithActionConstants/formConfig/GoogleSheetsSettingsConfig.ts @@ -0,0 +1,27 @@ +export default [ + { + sectionName: "", + id: 1, + children: [ + { + label: "Run API on Page load", + configProperty: "executeOnLoad", + controlType: "SWITCH", + info: "Will refresh data each time the page is loaded", + }, + { + label: "Request confirmation before running API", + configProperty: "confirmBeforeExecute", + controlType: "SWITCH", + info: "Ask confirmation from the user each time before refreshing data", + }, + { + label: "API timeout (in milliseconds)", + info: "Maximum time after which the API will return", + configProperty: "actionConfiguration.timeoutInMillisecond", + controlType: "INPUT_TEXT", + dataType: "NUMBER", + }, + ], + }, +]; diff --git a/app/taro/src/constants/AppsmithActionConstants/formConfig/QuerySettingsConfig.ts b/app/taro/src/constants/AppsmithActionConstants/formConfig/QuerySettingsConfig.ts new file mode 100644 index 0000000000..8c185c1f2f --- /dev/null +++ b/app/taro/src/constants/AppsmithActionConstants/formConfig/QuerySettingsConfig.ts @@ -0,0 +1,38 @@ +export default [ + { + sectionName: "", + id: 1, + children: [ + { + label: "Run query on page load", + configProperty: "executeOnLoad", + controlType: "SWITCH", + info: "Will refresh data each time the page is loaded", + }, + { + label: "Request confirmation before running query", + configProperty: "confirmBeforeExecute", + controlType: "SWITCH", + info: "Ask confirmation from the user each time before refreshing data", + }, + // { + // label: "Cache response", + // configProperty: "shouldCacheResponse", + // controlType: "SWITCH", + // }, + // { + // label: "Cache timeout (in milliseconds)", + // configProperty: "cacheTimeout", + // controlType: "INPUT_TEXT", + // dataType: "NUMBER", + // }, + { + label: "Query timeout (in milliseconds)", + info: "Maximum time after which the query will return", + configProperty: "actionConfiguration.timeoutInMillisecond", + controlType: "INPUT_TEXT", + dataType: "NUMBER", + }, + ], + }, +]; diff --git a/app/taro/src/constants/BindingsConstants.ts b/app/taro/src/constants/BindingsConstants.ts new file mode 100644 index 0000000000..325bb59e7e --- /dev/null +++ b/app/taro/src/constants/BindingsConstants.ts @@ -0,0 +1,4 @@ +export const DATA_BIND_REGEX = /{{([\s\S]*?)}}/; +export const DATA_BIND_REGEX_GLOBAL = /{{([\s\S]*?)}}/g; +export const AUTOCOMPLETE_MATCH_REGEX = /{{\s*.*?\s*}}/g; +export const QUOTED_BINDING_REGEX = /["']({{[\s\S]*?}})["']/g; diff --git a/app/taro/src/constants/Colors.tsx b/app/taro/src/constants/Colors.tsx new file mode 100644 index 0000000000..ac39c49be8 --- /dev/null +++ b/app/taro/src/constants/Colors.tsx @@ -0,0 +1,121 @@ +// Color Names generated from http://chir.ag/projects/name-that-color +import tinycolor from "tinycolor2"; +const primaryColor = "#2CBBA6"; + +const lighten = (color: string, p: number) => { + return new tinycolor(color).lighten(p).toString(); +}; +const darken = (color: string, p: number) => { + return new tinycolor(color).darken(p).toString(); +}; +const desaturate = (color: string, p: number) => { + return new tinycolor(color).desaturate(p).toString(); +}; + +export const Colors = { + WHITE: "#FFFFFF", + WHITE_SMOKE: "#F4F4F4", + POLAR: "#E9FAF3", + GEYSER: "#D3DEE3", + GEYSER_LIGHT: "#E7E7E7", + ATHENS_GRAY: "#EBEFF2", + CONCRETE: "#F3F3F3", + MYSTIC: "#E1E8ED", + AQUA_HAZE: "#EEF2F5", + GRAY_CHATEAU: "#A2A6A8", + DARK_GRAY: "#A9A7A7", + LIGHT_GREYISH_BLUE: "#B0BFCB", + SUNGLOW: "#FFCB33", + SOFT_ORANGE: "#f7c75b", + BINDING_COLOR: "#ffcc99", + BINDING_COLOR_LT: "#063289", + PURE_ORANGE: "#ffb100", + WHITE_CLOUD: "#D3DEE3", + GOLD: "#FFD300", + + BLACK: "#000000", + BLACK_PEARL: "#040627", + CODE_GRAY: "#090707", + SHARK: "#21282C", + SHARK2: "#232324", + MINE_SHAFT: "#262626", + DEEP_SPACE: "#272E32", + OUTER_SPACE: "#363E44", + TUNDORA: "#404040", + DOVE_GRAY: "#6D6D6D", + SLATE_GRAY: "#768896", + SILVER_CHALICE: "#A9A7A7", + PORCELAIN: "#EBEEF0", + HIT_GRAY: "#A1ACB3", + JUNGLE_MIST: "#BCCCD9", + MERCURY: "#E8E8E8", + MAKO: "#464D53", + ALTO: "#DFDFDF", + + GREEN: primaryColor, + JUNGLE_GREEN: "#24BA91", + JUNGLE_GREEN_DARKER: "#30A481", + EUCALYPTUS: "#218358", + RED: "#B30338", + ERROR_RED: "#E22C2C", + PURPLE: "#6871EF", + OXFORD_BLUE: "#2E3D49", + FRENCH_PASS: "#BBE8FE", + CADET_BLUE: "#A3B3BF", + JAFFA: "#F2994A", + BLUE_BAYOUX: "#4E5D78", + MINT_TULIP: "#B5F1F1", + AZURE_RADIANCE: "#0384FE", + OCEAN_GREEN: "#36AB80", + BUTTER_CUP: "#F7AF22", + BLUE_CHARCOAL: "#23292E", + TROUT: "#4C565E", + JAFFA_DARK: "#EF7541", + BURNING_ORANGE: "#FF7742", + TIA_MARIA: "#CB4810", + SOLID_MERCURY: "#E5E5E5", + TROUT_DARK: "#535B62", + ALABASTER: "#F9F8F8", + WATUSI: "#FFE0D2", + GRAY: "#858282", + GRAY2: "#939090", + DOVE_GRAY2: "#716E6E", + ATHENS_GRAY_DARKER: "#F8F9FA", + POMEGRANATE: "#F44336", + POMEGRANATE2: "#F22B2B", + RIVER_BED: "#4A545B", + BALTIC_SEA: "#1A191C", + THUNDER: "#231F20", + WHITE_SNOW: "#F7F7F7", + NERO: "#2B2B2B", + CHARCOAL: "#4B4848", + LIGHT_GREY: "#D4D4D4", + Gallery: "#F0F0F0", + Galliano: "#E0B30E", + ROYAL_BLUE: "#457AE6", + ALTO2: "#E0DEDE", + SEA_SHELL: "#F1F1F1", + DANUBE: "#6A86CE", + FAIR_PINK: "#FFE9E9", + OPAQ_BLUE: "rgba(106, 134, 206, 0.1)", + RATE_ACTIVE: "#FFCB45", + RATE_INACTIVE: "#F2F2F2", + SELECT_DISABLED: "#ced9e080", + // new colors + MINT_GREEN: primaryColor, + MINT_GREEN_LIGHT: lighten(primaryColor, 38), + MINT_GREEN_DARK: darken(primaryColor, 10), + MINT_GREEN_DARKER: darken(primaryColor, 20), + MINT_GREEN_DARKEST: desaturate(lighten(primaryColor, 30), 50), + MINT_ORANGE: "#FF6A00", + MINT_ORANGE_LIGHT: "#FFE8D7", + MINT_BLUE: "#3C6DC1", + MINT_BLUE_LIGHT: "#CFDCF1", + MINT_YELLOW: "#FFB93C", + MINT_YELLOW_LIGHT: "#FFF1D7", + MINT_RED: "#F93B4D", + MINT_RED_LIGHT: "#FED6DA", + MINT_BLACK: "#232323", + MINT_GRAY: "#f6f6f6", +}; +export type Color = typeof Colors[keyof typeof Colors]; diff --git a/app/taro/src/constants/CommentConstants.tsx b/app/taro/src/constants/CommentConstants.tsx new file mode 100644 index 0000000000..db76d6891f --- /dev/null +++ b/app/taro/src/constants/CommentConstants.tsx @@ -0,0 +1,9 @@ +export const COMMENT_EVENTS_CHANNEL = "COMMENTS_EVENTS_CHANNEL"; + +export const COMMENT_EVENTS = { + SET_COMMENTS: "SET_COMMENTS", + INSERT_COMMENT_THREAD: "insert:commentThread", + INSERT_COMMENT: "insert:comment", + UPDATE_COMMENT_THREAD: "update:commentThread", + UPDATE_COMMENT: "update:comment", +}; diff --git a/app/taro/src/constants/Currency.tsx b/app/taro/src/constants/Currency.tsx new file mode 100644 index 0000000000..6a8cbae061 --- /dev/null +++ b/app/taro/src/constants/Currency.tsx @@ -0,0 +1,1998 @@ +// 20210608001520 +// https://gist.githubusercontent.com/somangshu/93c83900714d14fe86502be6c48738c7/raw/5ebdc149d599f5661d2c87c59f23d6889cc93129/country.json + +export interface CurrencyOptionProps { + code: string; + currency: string; + currency_name: string; + label: string; + phone: string; + symbol_native: string; +} + +export const CurrencyTypeOptions: Array = [ + { + code: "AD", + currency: "EUR", + currency_name: "Euro", + label: "Andorra", + phone: "376", + symbol_native: "€", + }, + { + code: "AE", + currency: "AED", + currency_name: "United Arab Emirates Dirham", + label: "United Arab Emirates", + phone: "971", + symbol_native: "د.إ.‏", + }, + { + code: "AF", + currency: "AFN", + currency_name: "Afghan Afghani", + label: "Afghanistan", + phone: "93", + symbol_native: "؋", + }, + // { + // code: "AG", + // currency: "XCD", + // currency_name: null, + // label: "Antigua and Barbuda", + // phone: "1-268", + // symbol_native: null, + // }, + // { + // code: "AI", + // currency: "XCD", + // currency_name: null, + // label: "Anguilla", + // phone: "1-264", + // symbol_native: null, + // }, + { + code: "AL", + currency: "ALL", + currency_name: "Albanian Lek", + label: "Albania", + phone: "355", + symbol_native: "Lek", + }, + { + code: "AM", + currency: "AMD", + currency_name: "Armenian Dram", + label: "Armenia", + phone: "374", + symbol_native: "դր.", + }, + // { + // code: "AO", + // currency: "AOA", + // currency_name: null, + // label: "Angola", + // phone: "244", + // symbol_native: null, + // }, + // { + // code: "AQ", + // currency: "", + // currency_name: null, + // label: "Antarctica", + // phone: "672", + // symbol_native: null, + // }, + { + code: "AR", + currency: "ARS", + currency_name: "Argentine Peso", + label: "Argentina", + phone: "54", + symbol_native: "$", + }, + { + code: "AS", + currency: "USD", + currency_name: "US Dollar", + label: "American Samoa", + phone: "1-684", + symbol_native: "$", + }, + { + code: "AT", + currency: "EUR", + currency_name: "Euro", + label: "Austria", + phone: "43", + symbol_native: "€", + }, + { + code: "AU", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Australia", + phone: "61", + symbol_native: "$", + }, + // { + // code: "AW", + // currency: "AWG", + // currency_name: null, + // label: "Aruba", + // phone: "297", + // symbol_native: null, + // }, + { + code: "AX", + currency: "EUR", + currency_name: "Euro", + label: "Alland Islands", + phone: "358", + symbol_native: "€", + }, + { + code: "AZ", + currency: "AZN", + currency_name: "Azerbaijani Manat", + label: "Azerbaijan", + phone: "994", + symbol_native: "ман.", + }, + { + code: "BA", + currency: "BAM", + currency_name: "Bosnia-Herzegovina Convertible Mark", + label: "Bosnia and Herzegovina", + phone: "387", + symbol_native: "KM", + }, + // { + // code: "BB", + // currency: "BBD", + // currency_name: null, + // label: "Barbados", + // phone: "1-246", + // symbol_native: null, + // }, + { + code: "BD", + currency: "BDT", + currency_name: "Bangladeshi Taka", + label: "Bangladesh", + phone: "880", + symbol_native: "৳", + }, + { + code: "BE", + currency: "EUR", + currency_name: "Euro", + label: "Belgium", + phone: "32", + symbol_native: "€", + }, + { + code: "BF", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Burkina Faso", + phone: "226", + symbol_native: "CFA", + }, + { + code: "BG", + currency: "BGN", + currency_name: "Bulgarian Lev", + label: "Bulgaria", + phone: "359", + symbol_native: "лв.", + }, + { + code: "BH", + currency: "BHD", + currency_name: "Bahraini Dinar", + label: "Bahrain", + phone: "973", + symbol_native: "د.ب.‏", + }, + { + code: "BI", + currency: "BIF", + currency_name: "Burundian Franc", + label: "Burundi", + phone: "257", + symbol_native: "FBu", + }, + { + code: "BJ", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Benin", + phone: "229", + symbol_native: "CFA", + }, + { + code: "BL", + currency: "EUR", + currency_name: "Euro", + label: "Saint Barthelemy", + phone: "590", + symbol_native: "€", + }, + // { + // code: "BM", + // currency: "BMD", + // currency_name: null, + // label: "Bermuda", + // phone: "1-441", + // symbol_native: null, + // }, + { + code: "BN", + currency: "BND", + currency_name: "Brunei Dollar", + label: "Brunei Darussalam", + phone: "673", + symbol_native: "$", + }, + { + code: "BO", + currency: "BOB", + currency_name: "Bolivian Boliviano", + label: "Bolivia", + phone: "591", + symbol_native: "Bs", + }, + { + code: "BR", + currency: "BRL", + currency_name: "Brazilian Real", + label: "Brazil", + phone: "55", + symbol_native: "R$", + }, + // { + // code: "BS", + // currency: "BSD", + // currency_name: null, + // label: "Bahamas", + // phone: "1-242", + // symbol_native: null, + // }, + // { + // code: "BT", + // currency: "BTN", + // currency_name: null, + // label: "Bhutan", + // phone: "975", + // symbol_native: null, + // }, + { + code: "BV", + currency: "NOK", + currency_name: "Norwegian Krone", + label: "Bouvet Island", + phone: "47", + symbol_native: "kr", + }, + { + code: "BW", + currency: "BWP", + currency_name: "Botswanan Pula", + label: "Botswana", + phone: "267", + symbol_native: "P", + }, + { + code: "BY", + currency: "BYR", + currency_name: "Belarusian Ruble", + label: "Belarus", + phone: "375", + symbol_native: "BYR", + }, + { + code: "BZ", + currency: "BZD", + currency_name: "Belize Dollar", + label: "Belize", + phone: "501", + symbol_native: "$", + }, + { + code: "CA", + currency: "CAD", + currency_name: "Canadian Dollar", + label: "Canada", + phone: "1", + symbol_native: "$", + }, + { + code: "CC", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Cocos (Keeling) Islands", + phone: "61", + symbol_native: "$", + }, + { + code: "CD", + currency: "CDF", + currency_name: "Congolese Franc", + label: "Congo, Democratic Republic of the", + phone: "243", + symbol_native: "FrCD", + }, + { + code: "CF", + currency: "XAF", + currency_name: "CFA Franc BEAC", + label: "Central African Republic", + phone: "236", + symbol_native: "FCFA", + }, + { + code: "CG", + currency: "XAF", + currency_name: "CFA Franc BEAC", + label: "Congo, Republic of the", + phone: "242", + symbol_native: "FCFA", + }, + { + code: "CH", + currency: "CHF", + currency_name: "Swiss Franc", + label: "Switzerland", + phone: "41", + symbol_native: "CHF", + }, + { + code: "CI", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Cote d'Ivoire", + phone: "225", + symbol_native: "CFA", + }, + { + code: "CK", + currency: "NZD", + currency_name: "New Zealand Dollar", + label: "Cook Islands", + phone: "682", + symbol_native: "$", + }, + { + code: "CL", + currency: "CLP", + currency_name: "Chilean Peso", + label: "Chile", + phone: "56", + symbol_native: "$", + }, + { + code: "CM", + currency: "XAF", + currency_name: "CFA Franc BEAC", + label: "Cameroon", + phone: "237", + symbol_native: "FCFA", + }, + { + code: "CN", + currency: "CNY", + currency_name: "Chinese Yuan", + label: "China", + phone: "86", + symbol_native: "CN¥", + }, + { + code: "CO", + currency: "COP", + currency_name: "Colombian Peso", + label: "Colombia", + phone: "57", + symbol_native: "$", + }, + { + code: "CR", + currency: "CRC", + currency_name: "Costa Rican Colón", + label: "Costa Rica", + phone: "506", + symbol_native: "₡", + }, + // { + // code: "CU", + // currency: "CUP", + // currency_name: null, + // label: "Cuba", + // phone: "53", + // symbol_native: null, + // }, + { + code: "CV", + currency: "CVE", + currency_name: "Cape Verdean Escudo", + label: "Cape Verde", + phone: "238", + symbol_native: "CV$", + }, + // { + // code: "CW", + // currency: "ANG", + // currency_name: null, + // label: "Curacao", + // phone: "599", + // symbol_native: null, + // }, + { + code: "CX", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Christmas Island", + phone: "61", + symbol_native: "$", + }, + { + code: "CY", + currency: "EUR", + currency_name: "Euro", + label: "Cyprus", + phone: "357", + symbol_native: "€", + }, + { + code: "CZ", + currency: "CZK", + currency_name: "Czech Republic Koruna", + label: "Czech Republic", + phone: "420", + symbol_native: "Kč", + }, + { + code: "DE", + currency: "EUR", + currency_name: "Euro", + label: "Germany", + phone: "49", + symbol_native: "€", + }, + { + code: "DJ", + currency: "DJF", + currency_name: "Djiboutian Franc", + label: "Djibouti", + phone: "253", + symbol_native: "Fdj", + }, + { + code: "DK", + currency: "DKK", + currency_name: "Danish Krone", + label: "Denmark", + phone: "45", + symbol_native: "kr", + }, + // { + // code: "DM", + // currency: "XCD", + // currency_name: null, + // label: "Dominica", + // phone: "1-767", + // symbol_native: null, + // }, + { + code: "DO", + currency: "DOP", + currency_name: "Dominican Peso", + label: "Dominican Republic", + phone: "1-809", + symbol_native: "RD$", + }, + { + code: "DZ", + currency: "DZD", + currency_name: "Algerian Dinar", + label: "Algeria", + phone: "213", + symbol_native: "د.ج.‏", + }, + { + code: "EC", + currency: "USD", + currency_name: "US Dollar", + label: "Ecuador", + phone: "593", + symbol_native: "$", + }, + { + code: "EE", + currency: "EUR", + currency_name: "Euro", + label: "Estonia", + phone: "372", + symbol_native: "€", + }, + { + code: "EG", + currency: "EGP", + currency_name: "Egyptian Pound", + label: "Egypt", + phone: "20", + symbol_native: "ج.م.‏", + }, + { + code: "EH", + currency: "MAD", + currency_name: "Moroccan Dirham", + label: "Western Sahara", + phone: "212", + symbol_native: "د.م.‏", + }, + { + code: "ER", + currency: "ERN", + currency_name: "Eritrean Nakfa", + label: "Eritrea", + phone: "291", + symbol_native: "Nfk", + }, + { + code: "ES", + currency: "EUR", + currency_name: "Euro", + label: "Spain", + phone: "34", + symbol_native: "€", + }, + { + code: "ET", + currency: "ETB", + currency_name: "Ethiopian Birr", + label: "Ethiopia", + phone: "251", + symbol_native: "Br", + }, + { + code: "FI", + currency: "EUR", + currency_name: "Euro", + label: "Finland", + phone: "358", + symbol_native: "€", + }, + // { + // code: "FJ", + // currency: "FJD", + // currency_name: null, + // label: "Fiji", + // phone: "679", + // symbol_native: null, + // }, + // { + // code: "FK", + // currency: "FKP", + // currency_name: null, + // label: "Falkland Islands (Malvinas)", + // phone: "500", + // symbol_native: null, + // }, + { + code: "FM", + currency: "USD", + currency_name: "US Dollar", + label: "Micronesia, Federated States of", + phone: "691", + symbol_native: "$", + }, + { + code: "FO", + currency: "DKK", + currency_name: "Danish Krone", + label: "Faroe Islands", + phone: "298", + symbol_native: "kr", + }, + { + code: "FR", + currency: "EUR", + currency_name: "Euro", + label: "France", + phone: "33", + symbol_native: "€", + }, + { + code: "GA", + currency: "XAF", + currency_name: "CFA Franc BEAC", + label: "Gabon", + phone: "241", + symbol_native: "FCFA", + }, + { + code: "GB", + currency: "GBP", + currency_name: "British Pound Sterling", + label: "United Kingdom", + phone: "44", + symbol_native: "£", + }, + // { + // code: "GD", + // currency: "XCD", + // currency_name: null, + // label: "Grenada", + // phone: "1-473", + // symbol_native: null, + // }, + { + code: "GE", + currency: "GEL", + currency_name: "Georgian Lari", + label: "Georgia", + phone: "995", + symbol_native: "GEL", + }, + { + code: "GF", + currency: "EUR", + currency_name: "Euro", + label: "French Guiana", + phone: "594", + symbol_native: "€", + }, + { + code: "GG", + currency: "GBP", + currency_name: "British Pound Sterling", + label: "Guernsey", + phone: "44", + symbol_native: "£", + }, + { + code: "GH", + currency: "GHS", + currency_name: "Ghanaian Cedi", + label: "Ghana", + phone: "233", + symbol_native: "GH₵", + }, + // { + // code: "GI", + // currency: "GIP", + // currency_name: null, + // label: "Gibraltar", + // phone: "350", + // symbol_native: null, + // }, + { + code: "GL", + currency: "DKK", + currency_name: "Danish Krone", + label: "Greenland", + phone: "299", + symbol_native: "kr", + }, + // { + // code: "GM", + // currency: "GMD", + // currency_name: null, + // label: "Gambia", + // phone: "220", + // symbol_native: null, + // }, + { + code: "GN", + currency: "GNF", + currency_name: "Guinean Franc", + label: "Guinea", + phone: "224", + symbol_native: "FG", + }, + { + code: "GP", + currency: "EUR", + currency_name: "Euro", + label: "Guadeloupe", + phone: "590", + symbol_native: "€", + }, + { + code: "GQ", + currency: "XAF", + currency_name: "CFA Franc BEAC", + label: "Equatorial Guinea", + phone: "240", + symbol_native: "FCFA", + }, + { + code: "GR", + currency: "EUR", + currency_name: "Euro", + label: "Greece", + phone: "30", + symbol_native: "€", + }, + { + code: "GS", + currency: "GBP", + currency_name: "British Pound Sterling", + label: "South Georgia and the South Sandwich Islands", + phone: "500", + symbol_native: "£", + }, + { + code: "GT", + currency: "GTQ", + currency_name: "Guatemalan Quetzal", + label: "Guatemala", + phone: "502", + symbol_native: "Q", + }, + { + code: "GU", + currency: "USD", + currency_name: "US Dollar", + label: "Guam", + phone: "1-671", + symbol_native: "$", + }, + { + code: "GW", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Guinea-Bissau", + phone: "245", + symbol_native: "CFA", + }, + // { + // code: "GY", + // currency: "GYD", + // currency_name: null, + // label: "Guyana", + // phone: "592", + // symbol_native: null, + // }, + { + code: "HK", + currency: "HKD", + currency_name: "Hong Kong Dollar", + label: "Hong Kong", + phone: "852", + symbol_native: "$", + }, + { + code: "HM", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Heard Island and McDonald Islands", + phone: "672", + symbol_native: "$", + }, + { + code: "HN", + currency: "HNL", + currency_name: "Honduran Lempira", + label: "Honduras", + phone: "504", + symbol_native: "L", + }, + { + code: "HR", + currency: "HRK", + currency_name: "Croatian Kuna", + label: "Croatia", + phone: "385", + symbol_native: "kn", + }, + // { + // code: "HT", + // currency: "HTG", + // currency_name: null, + // label: "Haiti", + // phone: "509", + // symbol_native: null, + // }, + { + code: "HU", + currency: "HUF", + currency_name: "Hungarian Forint", + label: "Hungary", + phone: "36", + symbol_native: "Ft", + }, + { + code: "ID", + currency: "IDR", + currency_name: "Indonesian Rupiah", + label: "Indonesia", + phone: "62", + symbol_native: "Rp", + }, + { + code: "IE", + currency: "EUR", + currency_name: "Euro", + label: "Ireland", + phone: "353", + symbol_native: "€", + }, + { + code: "IL", + currency: "ILS", + currency_name: "Israeli New Sheqel", + label: "Israel", + phone: "972", + symbol_native: "₪", + }, + { + code: "IM", + currency: "GBP", + currency_name: "British Pound Sterling", + label: "Isle of Man", + phone: "44", + symbol_native: "£", + }, + { + code: "IN", + currency: "INR", + currency_name: "Indian Rupee", + label: "India", + phone: "91", + symbol_native: "₹", + }, + { + code: "IO", + currency: "USD", + currency_name: "US Dollar", + label: "British Indian Ocean Territory", + phone: "246", + symbol_native: "$", + }, + { + code: "IQ", + currency: "IQD", + currency_name: "Iraqi Dinar", + label: "Iraq", + phone: "964", + symbol_native: "د.ع.‏", + }, + { + code: "IR", + currency: "IRR", + currency_name: "Iranian Rial", + label: "Iran, Islamic Republic of", + phone: "98", + symbol_native: "﷼", + }, + { + code: "IS", + currency: "ISK", + currency_name: "Icelandic Króna", + label: "Iceland", + phone: "354", + symbol_native: "kr", + }, + { + code: "IT", + currency: "EUR", + currency_name: "Euro", + label: "Italy", + phone: "39", + symbol_native: "€", + }, + { + code: "JE", + currency: "GBP", + currency_name: "British Pound Sterling", + label: "Jersey", + phone: "44", + symbol_native: "£", + }, + { + code: "JM", + currency: "JMD", + currency_name: "Jamaican Dollar", + label: "Jamaica", + phone: "1-876", + symbol_native: "$", + }, + { + code: "JO", + currency: "JOD", + currency_name: "Jordanian Dinar", + label: "Jordan", + phone: "962", + symbol_native: "د.أ.‏", + }, + { + code: "JP", + currency: "JPY", + currency_name: "Japanese Yen", + label: "Japan", + phone: "81", + symbol_native: "¥", + }, + { + code: "KE", + currency: "KES", + currency_name: "Kenyan Shilling", + label: "Kenya", + phone: "254", + symbol_native: "Ksh", + }, + // { + // code: "KG", + // currency: "KGS", + // currency_name: null, + // label: "Kyrgyzstan", + // phone: "996", + // symbol_native: null, + // }, + { + code: "KH", + currency: "KHR", + currency_name: "Cambodian Riel", + label: "Cambodia", + phone: "855", + symbol_native: "៛", + }, + { + code: "KI", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Kiribati", + phone: "686", + symbol_native: "$", + }, + { + code: "KM", + currency: "KMF", + currency_name: "Comorian Franc", + label: "Comoros", + phone: "269", + symbol_native: "FC", + }, + // { + // code: "KN", + // currency: "XCD", + // currency_name: null, + // label: "Saint Kitts and Nevis", + // phone: "1-869", + // symbol_native: null, + // }, + // { + // code: "KP", + // currency: "KPW", + // currency_name: null, + // label: "Korea, Democratic People's Republic of", + // phone: "850", + // symbol_native: null, + // }, + { + code: "KR", + currency: "KRW", + currency_name: "South Korean Won", + label: "Korea, Republic of", + phone: "82", + symbol_native: "₩", + }, + { + code: "KW", + currency: "KWD", + currency_name: "Kuwaiti Dinar", + label: "Kuwait", + phone: "965", + symbol_native: "د.ك.‏", + }, + // { + // code: "KY", + // currency: "KYD", + // currency_name: null, + // label: "Cayman Islands", + // phone: "1-345", + // symbol_native: null, + // }, + { + code: "KZ", + currency: "KZT", + currency_name: "Kazakhstani Tenge", + label: "Kazakhstan", + phone: "7", + symbol_native: "тңг.", + }, + // { + // code: "LA", + // currency: "LAK", + // currency_name: null, + // label: "Lao People's Democratic Republic", + // phone: "856", + // symbol_native: null, + // }, + { + code: "LB", + currency: "LBP", + currency_name: "Lebanese Pound", + label: "Lebanon", + phone: "961", + symbol_native: "ل.ل.‏", + }, + // { + // code: "LC", + // currency: "XCD", + // currency_name: null, + // label: "Saint Lucia", + // phone: "1-758", + // symbol_native: null, + // }, + { + code: "LI", + currency: "CHF", + currency_name: "Swiss Franc", + label: "Liechtenstein", + phone: "423", + symbol_native: "CHF", + }, + { + code: "LK", + currency: "LKR", + currency_name: "Sri Lankan Rupee", + label: "Sri Lanka", + phone: "94", + symbol_native: "SL Re", + }, + // { + // code: "LR", + // currency: "LRD", + // currency_name: null, + // label: "Liberia", + // phone: "231", + // symbol_native: null, + // }, + // { + // code: "LS", + // currency: "LSL", + // currency_name: null, + // label: "Lesotho", + // phone: "266", + // symbol_native: null, + // }, + { + code: "LT", + currency: "LTL", + currency_name: "Lithuanian Litas", + label: "Lithuania", + phone: "370", + symbol_native: "Lt", + }, + { + code: "LU", + currency: "EUR", + currency_name: "Euro", + label: "Luxembourg", + phone: "352", + symbol_native: "€", + }, + { + code: "LV", + currency: "EUR", + currency_name: "Euro", + label: "Latvia", + phone: "371", + symbol_native: "€", + }, + { + code: "LY", + currency: "LYD", + currency_name: "Libyan Dinar", + label: "Libya", + phone: "218", + symbol_native: "د.ل.‏", + }, + { + code: "MA", + currency: "MAD", + currency_name: "Moroccan Dirham", + label: "Morocco", + phone: "212", + symbol_native: "د.م.‏", + }, + { + code: "MC", + currency: "EUR", + currency_name: "Euro", + label: "Monaco", + phone: "377", + symbol_native: "€", + }, + { + code: "MD", + currency: "MDL", + currency_name: "Moldovan Leu", + label: "Moldova, Republic of", + phone: "373", + symbol_native: "MDL", + }, + { + code: "ME", + currency: "EUR", + currency_name: "Euro", + label: "Montenegro", + phone: "382", + symbol_native: "€", + }, + { + code: "MF", + currency: "EUR", + currency_name: "Euro", + label: "Saint Martin (French part)", + phone: "590", + symbol_native: "€", + }, + { + code: "MG", + currency: "MGA", + currency_name: "Malagasy Ariary", + label: "Madagascar", + phone: "261", + symbol_native: "MGA", + }, + { + code: "MH", + currency: "USD", + currency_name: "US Dollar", + label: "Marshall Islands", + phone: "692", + symbol_native: "$", + }, + { + code: "MK", + currency: "MKD", + currency_name: "Macedonian Denar", + label: "Macedonia, the Former Yugoslav Republic of", + phone: "389", + symbol_native: "MKD", + }, + { + code: "ML", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Mali", + phone: "223", + symbol_native: "CFA", + }, + { + code: "MM", + currency: "MMK", + currency_name: "Myanma Kyat", + label: "Myanmar", + phone: "95", + symbol_native: "K", + }, + // { + // code: "MN", + // currency: "MNT", + // currency_name: null, + // label: "Mongolia", + // phone: "976", + // symbol_native: null, + // }, + { + code: "MO", + currency: "MOP", + currency_name: "Macanese Pataca", + label: "Macao", + phone: "853", + symbol_native: "MOP$", + }, + { + code: "MP", + currency: "USD", + currency_name: "US Dollar", + label: "Northern Mariana Islands", + phone: "1-670", + symbol_native: "$", + }, + { + code: "MQ", + currency: "EUR", + currency_name: "Euro", + label: "Martinique", + phone: "596", + symbol_native: "€", + }, + // { + // code: "MR", + // currency: "MRO", + // currency_name: null, + // label: "Mauritania", + // phone: "222", + // symbol_native: null, + // }, + // { + // code: "MS", + // currency: "XCD", + // currency_name: null, + // label: "Montserrat", + // phone: "1-664", + // symbol_native: null, + // }, + { + code: "MT", + currency: "EUR", + currency_name: "Euro", + label: "Malta", + phone: "356", + symbol_native: "€", + }, + { + code: "MU", + currency: "MUR", + currency_name: "Mauritian Rupee", + label: "Mauritius", + phone: "230", + symbol_native: "MURs", + }, + // { + // code: "MV", + // currency: "MVR", + // currency_name: null, + // label: "Maldives", + // phone: "960", + // symbol_native: null, + // }, + // { + // code: "MW", + // currency: "MWK", + // currency_name: null, + // label: "Malawi", + // phone: "265", + // symbol_native: null, + // }, + { + code: "MX", + currency: "MXN", + currency_name: "Mexican Peso", + label: "Mexico", + phone: "52", + symbol_native: "$", + }, + { + code: "MY", + currency: "MYR", + currency_name: "Malaysian Ringgit", + label: "Malaysia", + phone: "60", + symbol_native: "RM", + }, + { + code: "MZ", + currency: "MZN", + currency_name: "Mozambican Metical", + label: "Mozambique", + phone: "258", + symbol_native: "MTn", + }, + { + code: "NA", + currency: "NAD", + currency_name: "Namibian Dollar", + label: "Namibia", + phone: "264", + symbol_native: "N$", + }, + // { + // code: "NC", + // currency: "XPF", + // currency_name: null, + // label: "New Caledonia", + // phone: "687", + // symbol_native: null, + // }, + { + code: "NE", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Niger", + phone: "227", + symbol_native: "CFA", + }, + { + code: "NF", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Norfolk Island", + phone: "672", + symbol_native: "$", + }, + { + code: "NG", + currency: "NGN", + currency_name: "Nigerian Naira", + label: "Nigeria", + phone: "234", + symbol_native: "₦", + }, + { + code: "NI", + currency: "NIO", + currency_name: "Nicaraguan Córdoba", + label: "Nicaragua", + phone: "505", + symbol_native: "C$", + }, + { + code: "NL", + currency: "EUR", + currency_name: "Euro", + label: "Netherlands", + phone: "31", + symbol_native: "€", + }, + { + code: "NO", + currency: "NOK", + currency_name: "Norwegian Krone", + label: "Norway", + phone: "47", + symbol_native: "kr", + }, + { + code: "NP", + currency: "NPR", + currency_name: "Nepalese Rupee", + label: "Nepal", + phone: "977", + symbol_native: "नेरू", + }, + { + code: "NR", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Nauru", + phone: "674", + symbol_native: "$", + }, + { + code: "NU", + currency: "NZD", + currency_name: "New Zealand Dollar", + label: "Niue", + phone: "683", + symbol_native: "$", + }, + { + code: "NZ", + currency: "NZD", + currency_name: "New Zealand Dollar", + label: "New Zealand", + phone: "64", + symbol_native: "$", + }, + { + code: "OM", + currency: "OMR", + currency_name: "Omani Rial", + label: "Oman", + phone: "968", + symbol_native: "ر.ع.‏", + }, + { + code: "PA", + currency: "PAB", + currency_name: "Panamanian Balboa", + label: "Panama", + phone: "507", + symbol_native: "B/.", + }, + { + code: "PE", + currency: "PEN", + currency_name: "Peruvian Nuevo Sol", + label: "Peru", + phone: "51", + symbol_native: "S/.", + }, + // { + // code: "PF", + // currency: "XPF", + // currency_name: null, + // label: "French Polynesia", + // phone: "689", + // symbol_native: null, + // }, + // { + // code: "PG", + // currency: "PGK", + // currency_name: null, + // label: "Papua New Guinea", + // phone: "675", + // symbol_native: null, + // }, + { + code: "PH", + currency: "PHP", + currency_name: "Philippine Peso", + label: "Philippines", + phone: "63", + symbol_native: "₱", + }, + { + code: "PK", + currency: "PKR", + currency_name: "Pakistani Rupee", + label: "Pakistan", + phone: "92", + symbol_native: "₨", + }, + { + code: "PL", + currency: "PLN", + currency_name: "Polish Zloty", + label: "Poland", + phone: "48", + symbol_native: "zł", + }, + { + code: "PM", + currency: "EUR", + currency_name: "Euro", + label: "Saint Pierre and Miquelon", + phone: "508", + symbol_native: "€", + }, + { + code: "PN", + currency: "NZD", + currency_name: "New Zealand Dollar", + label: "Pitcairn", + phone: "870", + symbol_native: "$", + }, + { + code: "PR", + currency: "USD", + currency_name: "US Dollar", + label: "Puerto Rico", + phone: "1", + symbol_native: "$", + }, + { + code: "PS", + currency: "ILS", + currency_name: "Israeli New Sheqel", + label: "Palestine, State of", + phone: "970", + symbol_native: "₪", + }, + { + code: "PT", + currency: "EUR", + currency_name: "Euro", + label: "Portugal", + phone: "351", + symbol_native: "€", + }, + { + code: "PW", + currency: "USD", + currency_name: "US Dollar", + label: "Palau", + phone: "680", + symbol_native: "$", + }, + { + code: "PY", + currency: "PYG", + currency_name: "Paraguayan Guarani", + label: "Paraguay", + phone: "595", + symbol_native: "₲", + }, + { + code: "QA", + currency: "QAR", + currency_name: "Qatari Rial", + label: "Qatar", + phone: "974", + symbol_native: "ر.ق.‏", + }, + { + code: "RE", + currency: "EUR", + currency_name: "Euro", + label: "Reunion", + phone: "262", + symbol_native: "€", + }, + { + code: "RO", + currency: "RON", + currency_name: "Romanian Leu", + label: "Romania", + phone: "40", + symbol_native: "RON", + }, + { + code: "RS", + currency: "RSD", + currency_name: "Serbian Dinar", + label: "Serbia", + phone: "381", + symbol_native: "дин.", + }, + { + code: "RU", + currency: "RUB", + currency_name: "Russian Ruble", + label: "Russian Federation", + phone: "7", + symbol_native: "руб.", + }, + { + code: "RW", + currency: "RWF", + currency_name: "Rwandan Franc", + label: "Rwanda", + phone: "250", + symbol_native: "FR", + }, + { + code: "SA", + currency: "SAR", + currency_name: "Saudi Riyal", + label: "Saudi Arabia", + phone: "966", + symbol_native: "ر.س.‏", + }, + // { + // code: "SB", + // currency: "SBD", + // currency_name: null, + // label: "Solomon Islands", + // phone: "677", + // symbol_native: null, + // }, + // { + // code: "SC", + // currency: "SCR", + // currency_name: null, + // label: "Seychelles", + // phone: "248", + // symbol_native: null, + // }, + { + code: "SD", + currency: "SDG", + currency_name: "Sudanese Pound", + label: "Sudan", + phone: "249", + symbol_native: "SDG", + }, + { + code: "SE", + currency: "SEK", + currency_name: "Swedish Krona", + label: "Sweden", + phone: "46", + symbol_native: "kr", + }, + { + code: "SG", + currency: "SGD", + currency_name: "Singapore Dollar", + label: "Singapore", + phone: "65", + symbol_native: "$", + }, + // { + // code: "SH", + // currency: "SHP", + // currency_name: null, + // label: "Saint Helena", + // phone: "290", + // symbol_native: null, + // }, + { + code: "SI", + currency: "EUR", + currency_name: "Euro", + label: "Slovenia", + phone: "386", + symbol_native: "€", + }, + { + code: "SJ", + currency: "NOK", + currency_name: "Norwegian Krone", + label: "Svalbard and Jan Mayen", + phone: "47", + symbol_native: "kr", + }, + { + code: "SK", + currency: "EUR", + currency_name: "Euro", + label: "Slovakia", + phone: "421", + symbol_native: "€", + }, + // { + // code: "SL", + // currency: "SLL", + // currency_name: null, + // label: "Sierra Leone", + // phone: "232", + // symbol_native: null, + // }, + { + code: "SM", + currency: "EUR", + currency_name: "Euro", + label: "San Marino", + phone: "378", + symbol_native: "€", + }, + { + code: "SN", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Senegal", + phone: "221", + symbol_native: "CFA", + }, + { + code: "SO", + currency: "SOS", + currency_name: "Somali Shilling", + label: "Somalia", + phone: "252", + symbol_native: "Ssh", + }, + // { + // code: "SR", + // currency: "SRD", + // currency_name: null, + // label: "Suriname", + // phone: "597", + // symbol_native: null, + // }, + // { + // code: "SS", + // currency: "SSP", + // currency_name: null, + // label: "South Sudan", + // phone: "211", + // symbol_native: null, + // }, + // { + // code: "ST", + // currency: "STD", + // currency_name: null, + // label: "Sao Tome and Principe", + // phone: "239", + // symbol_native: null, + // }, + { + code: "SV", + currency: "USD", + currency_name: "US Dollar", + label: "El Salvador", + phone: "503", + symbol_native: "$", + }, + // { + // code: "SX", + // currency: "ANG", + // currency_name: null, + // label: "Sint Maarten (Dutch part)", + // phone: "1-721", + // symbol_native: null, + // }, + { + code: "SY", + currency: "SYP", + currency_name: "Syrian Pound", + label: "Syrian Arab Republic", + phone: "963", + symbol_native: "ل.س.‏", + }, + // { + // code: "SZ", + // currency: "SZL", + // currency_name: null, + // label: "Swaziland", + // phone: "268", + // symbol_native: null, + // }, + { + code: "TC", + currency: "USD", + currency_name: "US Dollar", + label: "Turks and Caicos Islands", + phone: "1-649", + symbol_native: "$", + }, + { + code: "TD", + currency: "XAF", + currency_name: "CFA Franc BEAC", + label: "Chad", + phone: "235", + symbol_native: "FCFA", + }, + { + code: "TF", + currency: "EUR", + currency_name: "Euro", + label: "French Southern Territories", + phone: "262", + symbol_native: "€", + }, + { + code: "TG", + currency: "XOF", + currency_name: "CFA Franc BCEAO", + label: "Togo", + phone: "228", + symbol_native: "CFA", + }, + { + code: "TH", + currency: "THB", + currency_name: "Thai Baht", + label: "Thailand", + phone: "66", + symbol_native: "฿", + }, + // { + // code: "TJ", + // currency: "TJS", + // currency_name: null, + // label: "Tajikistan", + // phone: "992", + // symbol_native: null, + // }, + { + code: "TK", + currency: "NZD", + currency_name: "New Zealand Dollar", + label: "Tokelau", + phone: "690", + symbol_native: "$", + }, + { + code: "TL", + currency: "USD", + currency_name: "US Dollar", + label: "Timor-Leste", + phone: "670", + symbol_native: "$", + }, + // { + // code: "TM", + // currency: "TMT", + // currency_name: null, + // label: "Turkmenistan", + // phone: "993", + // symbol_native: null, + // }, + { + code: "TN", + currency: "TND", + currency_name: "Tunisian Dinar", + label: "Tunisia", + phone: "216", + symbol_native: "د.ت.‏", + }, + { + code: "TO", + currency: "TOP", + currency_name: "Tongan Paʻanga", + label: "Tonga", + phone: "676", + symbol_native: "T$", + }, + { + code: "TR", + currency: "TRY", + currency_name: "Turkish Lira", + label: "Turkey", + phone: "90", + symbol_native: "TL", + }, + { + code: "TT", + currency: "TTD", + currency_name: "Trinidad and Tobago Dollar", + label: "Trinidad and Tobago", + phone: "1-868", + symbol_native: "$", + }, + { + code: "TV", + currency: "AUD", + currency_name: "Australian Dollar", + label: "Tuvalu", + phone: "688", + symbol_native: "$", + }, + { + code: "TW", + currency: "TWD", + currency_name: "New Taiwan Dollar", + label: "Taiwan, Province of China", + phone: "886", + symbol_native: "NT$", + }, + { + code: "TZ", + currency: "TZS", + currency_name: "Tanzanian Shilling", + label: "United Republic of Tanzania", + phone: "255", + symbol_native: "TSh", + }, + { + code: "UA", + currency: "UAH", + currency_name: "Ukrainian Hryvnia", + label: "Ukraine", + phone: "380", + symbol_native: "₴", + }, + { + code: "UG", + currency: "UGX", + currency_name: "Ugandan Shilling", + label: "Uganda", + phone: "256", + symbol_native: "USh", + }, + { + code: "US", + currency: "USD", + currency_name: "US Dollar", + label: "United States", + phone: "1", + symbol_native: "$", + }, + { + code: "UY", + currency: "UYU", + currency_name: "Uruguayan Peso", + label: "Uruguay", + phone: "598", + symbol_native: "$", + }, + { + code: "UZ", + currency: "UZS", + currency_name: "Uzbekistan Som", + label: "Uzbekistan", + phone: "998", + symbol_native: "UZS", + }, + { + code: "VA", + currency: "EUR", + currency_name: "Euro", + label: "Holy See (Vatican City State)", + phone: "379", + symbol_native: "€", + }, + // { + // code: "VC", + // currency: "XCD", + // currency_name: null, + // label: "Saint Vincent and the Grenadines", + // phone: "1-784", + // symbol_native: null, + // }, + { + code: "VE", + currency: "VEF", + currency_name: "Venezuelan Bolívar", + label: "Venezuela", + phone: "58", + symbol_native: "Bs.F.", + }, + { + code: "VG", + currency: "USD", + currency_name: "US Dollar", + label: "British Virgin Islands", + phone: "1-284", + symbol_native: "$", + }, + { + code: "VI", + currency: "USD", + currency_name: "US Dollar", + label: "US Virgin Islands", + phone: "1-340", + symbol_native: "$", + }, + { + code: "VN", + currency: "VND", + currency_name: "Vietnamese Dong", + label: "Vietnam", + phone: "84", + symbol_native: "₫", + }, + // { + // code: "VU", + // currency: "VUV", + // currency_name: null, + // label: "Vanuatu", + // phone: "678", + // symbol_native: null, + // }, + // { + // code: "WF", + // currency: "XPF", + // currency_name: null, + // label: "Wallis and Futuna", + // phone: "681", + // symbol_native: null, + // }, + // { + // code: "WS", + // currency: "WST", + // currency_name: null, + // label: "Samoa", + // phone: "685", + // symbol_native: null, + // }, + { + code: "XK", + currency: "EUR", + currency_name: "Euro", + label: "Kosovo", + phone: "383", + symbol_native: "€", + }, + { + code: "YE", + currency: "YER", + currency_name: "Yemeni Rial", + label: "Yemen", + phone: "967", + symbol_native: "ر.ي.‏", + }, + { + code: "YT", + currency: "EUR", + currency_name: "Euro", + label: "Mayotte", + phone: "262", + symbol_native: "€", + }, + { + code: "ZA", + currency: "ZAR", + currency_name: "South African Rand", + label: "South Africa", + phone: "27", + symbol_native: "R", + }, + { + code: "ZM", + currency: "ZMK", + currency_name: "Zambian Kwacha", + label: "Zambia", + phone: "260", + symbol_native: "ZK", + }, + // { + // code: "ZW", + // currency: "ZWL", + // currency_name: null, + // label: "Zimbabwe", + // phone: "263", + // symbol_native: null, + // }, +]; diff --git a/app/taro/src/constants/CustomChartConstants.ts b/app/taro/src/constants/CustomChartConstants.ts new file mode 100644 index 0000000000..6b51653a59 --- /dev/null +++ b/app/taro/src/constants/CustomChartConstants.ts @@ -0,0 +1,118 @@ +export const CUSTOM_CHART_TYPES = [ + "area2d", + "bar2d", + "bar3d", + "boxandwhisker2d", + "candlestick", + "chord", + "dragnode", + "dragarea", + "dragcolumn2d", + "dragline", + "errorbar2d", + "errorline", + "errorscatter", + "funnel", + "gantt", + "heatmap", + "hbullet", + "hled", + "InverseMSArea", + "InverseMSColumn2D", + "InverseMSLine", + "LogMSColumn2D", + "LogMSLine", + "MultiAxisLine", + "multilevelpie", + "overlappedcolumn2d", + "overlappedbar2d", + "pyramid", + "radar", + "angulargauge", + "realtimearea", + "bulb", + "realtimecolumn", + "cylinder", + "HLinearGauge", + "realtimeline", + "realtimelinedy", + "realtimestackedarea", + "realtimestackedcolumn", + "thermometer", + "sankey", + "selectscatter", + "sparkcolumn", + "sparkline", + "sparkwinloss", + "msstepline", + "sunburst", + "treemap", + "vbullet", + "vled", + "waterfall2d", + "zoomline", + "zoomlinedy", + "zoomscatter", + "column2d", + "column3d", + "line", + "area", + "bar2d", + "bar3d", + "pie2d", + "pie3d", + "doughnut2d", + "doughnut3d", + "pareto2d", + "pareto3d", + "scrollcombidy2d", + "scrollcombi2d", + "scrollstackedcolumn2d", + "scrollmsstackedcolumn2d", + "scrollmsstackedcolumn2dlinedy", + "scrollstackedbar2d", + "scrollarea2d", + "scrollline2d", + "scrollcolumn2d", + "scrollbar2d", + "bubble", + "scatter", + "msstackedcolumn2d", + "stackedarea2d", + "stackedbar3d", + "stackedbar2d", + "stackedcolumn3d", + "stackedcolumn2d", + "msstackedcolumn2dlinedy", + "stackedcolumn3dlinedy", + "mscolumn3dlinedy", + "mscombidy2d", + "mscombidy3d", + "stackedcolumn3dline", + "stackedcolumn2dline", + "mscolumnline3d", + "mscombi3d", + "mscombi2d", + "marimekko", + "MSArea", + "msbar3d", + "msbar2d", + "msline", + "mscolumn3d", + "mscolumn2d", + "spline", + "splinearea", + "msspline", + "mssplinedy", + "mssplinearea", + "stackedcolumn2dlinedy", + "stackedarea2dlinedy", +]; + +export const CUSTOM_CHART_DEFAULT_PARSED = { + type: "", + dataSource: { + chart: {}, + data: [], + }, +}; diff --git a/app/taro/src/constants/DatasourceEditorConstants.ts b/app/taro/src/constants/DatasourceEditorConstants.ts new file mode 100644 index 0000000000..8d794db207 --- /dev/null +++ b/app/taro/src/constants/DatasourceEditorConstants.ts @@ -0,0 +1,5 @@ +export const DATASOURCE_CONSTANT = "DATASOURCE"; +export const APPSMITH_IP_ADDRESSES = ["18.223.74.85", "3.131.104.27"]; + +export const PRIMARY_KEY = "primary key"; +export const FOREIGN_KEY = "foreign key"; diff --git a/app/taro/src/constants/DefaultTheme.tsx b/app/taro/src/constants/DefaultTheme.tsx new file mode 100644 index 0000000000..13ab0b42e0 --- /dev/null +++ b/app/taro/src/constants/DefaultTheme.tsx @@ -0,0 +1,16 @@ +import { styled } from "linaria/react"; +import { Colors } from "./Colors"; + +export const dark: any = {} +export const light: any = {} + +export const theme: any = { + smallHeaderHeight: "35px", +}; + +export const taroifyTheme = { + primaryColor: Colors.MINT_GREEN, + cellIconMarginLeft: "12rpx", +}; + +export default styled; diff --git a/app/taro/src/constants/Explorer.ts b/app/taro/src/constants/Explorer.ts new file mode 100644 index 0000000000..94f482e1a5 --- /dev/null +++ b/app/taro/src/constants/Explorer.ts @@ -0,0 +1,2 @@ +export const ENTITY_EXPLORER_SEARCH_ID = "entity-explorer-search"; +export const WIDGETS_SEARCH_ID = "#widgets-search"; diff --git a/app/taro/src/constants/FieldExpectedValue.ts b/app/taro/src/constants/FieldExpectedValue.ts new file mode 100644 index 0000000000..99f9c56f2e --- /dev/null +++ b/app/taro/src/constants/FieldExpectedValue.ts @@ -0,0 +1,10 @@ +const FIELD_VALUES: Record<"API_ACTION", Record> = { + API_ACTION: { + body: "JSON", + params: "string", + headers: "string", + path: "string", + }, +}; + +export default FIELD_VALUES; diff --git a/app/taro/src/constants/Fonts.tsx b/app/taro/src/constants/Fonts.tsx new file mode 100644 index 0000000000..cb2614f6fb --- /dev/null +++ b/app/taro/src/constants/Fonts.tsx @@ -0,0 +1,4 @@ +export const TextFonts = + "-apple-system, BlinkMacSystemFont, “Segoe UI”, “Roboto”, “Oxygen”, “Ubuntu”, “Cantarell”, “Fira Sans”, “Droid Sans”, “Helvetica Neue”, sans-serif"; +export const CodeFonts = + 'Consolas, Monaco, "Andale Mono", "Ubuntu Mono", monospace'; diff --git a/app/taro/src/constants/HelpConstants.ts b/app/taro/src/constants/HelpConstants.ts new file mode 100644 index 0000000000..da016f8efc --- /dev/null +++ b/app/taro/src/constants/HelpConstants.ts @@ -0,0 +1,6 @@ +export const HelpMap = {}; + +export const HelpBaseURL = "https://docs.appsmith.com"; + +export const HELP_MODAL_WIDTH = 240; +export const HELP_MODAL_HEIGHT = 206; diff --git a/app/taro/src/constants/KeyboardShortcuts.ts b/app/taro/src/constants/KeyboardShortcuts.ts new file mode 100644 index 0000000000..3bb8e2a6a9 --- /dev/null +++ b/app/taro/src/constants/KeyboardShortcuts.ts @@ -0,0 +1,7 @@ +export default { + CodeEditor: { + OpenAutocomplete: "Ctrl-Space", + ShowTypeAndInfo: "Ctrl-I", + OpenDocsLink: "Ctrl-O", + }, +}; diff --git a/app/taro/src/constants/Layers.tsx b/app/taro/src/constants/Layers.tsx new file mode 100644 index 0000000000..603ce8019a --- /dev/null +++ b/app/taro/src/constants/Layers.tsx @@ -0,0 +1,57 @@ +import React from "react"; + +export enum Indices { + Layer0, + Layer1, + Layer2, + Layer3, + Layer4, + Layer5, + Layer6, + Layer7, + Layer8, + Layer9, + Layer10, + Layer21 = 21, + LayerMax = 99999, +} + +export const Layers = { + dropZone: Indices.Layer0, + + dragPreview: Indices.Layer1, + // All Widgets Parent layer + positionedWidget: Indices.Layer1, + // Modal needs to higher than other widgets. + modalWidget: Indices.Layer2, + // Dropdown portaled to the canvas + dropdownWidget: Indices.Layer2, + // dropdown portaled to Modal Container with higher index than Overlay + dropdownModalWidget: Indices.Layer21, + selectedWidget: Indices.Layer2, + // Layers when dragging + animatedSnappingDropZone: Indices.Layer2, + + animatedDropZone: Indices.Layer3, + // Must be higher than any widget + widgetName: Indices.Layer3, + apiPane: Indices.Layer3, + // Propane needs to match sidebar to show propane on top side bar. + // Sidebar needs to be more than modal so that u can use side bar whilst u have the modal showing up on the canvas. + sideBar: Indices.Layer3, + propertyPane: Indices.Layer3, + tableFilterPane: Indices.Layer6, + + help: Indices.Layer4, + contextMenu: Indices.Layer4, + dynamicAutoComplete: Indices.Layer5, + debugger: Indices.Layer6, + productUpdates: Indices.Layer7, + portals: Indices.Layer8, + header: Indices.Layer9, + snipeableZone: Indices.Layer10, + appComments: Indices.Layer7, + max: Indices.LayerMax, +}; + +export const LayersContext = React.createContext(Layers); diff --git a/app/taro/src/constants/OmnibarDocumentationConstants.ts b/app/taro/src/constants/OmnibarDocumentationConstants.ts new file mode 100644 index 0000000000..9c301368fa --- /dev/null +++ b/app/taro/src/constants/OmnibarDocumentationConstants.ts @@ -0,0 +1,58 @@ +import { includes, some } from "lodash"; + +const omnibarDocumentationHelper = (linkURL: string) => { + const documentationHeaders = [ + { + text: ["mongodb", "mongo-plugin"], + query: "MongoDB", + }, + { + text: ["redis"], + query: "redis", + }, + { + text: ["redshift"], + query: "redshift", + }, + { + text: ["amazon-s3"], + query: "Amazon S3", + }, + { + text: ["querying-firestore"], + query: "Firestore", + }, + { + text: ["querying-mysql"], + query: "Mysql", + }, + { + text: ["querying-mssql"], + query: "Mssql", + }, + { + text: ["querying-elasticsearch"], + query: "elasticsearch", + }, + { + text: ["querying-postgres", "postgres-plugin"], + query: "postgres", + }, + { + text: ["querying-dynamodb"], + query: "dynamodb", + }, + ]; + const doc = documentationHeaders.find((headerItem) => + some(headerItem.text, (el) => + includes(linkURL.toLowerCase(), el.toLowerCase()), + ), + ); + if (doc) { + return doc.query; + } else { + return ""; + } +}; + +export { omnibarDocumentationHelper }; diff --git a/app/taro/src/constants/OnboardingConstants.tsx b/app/taro/src/constants/OnboardingConstants.tsx new file mode 100644 index 0000000000..79f54afd94 --- /dev/null +++ b/app/taro/src/constants/OnboardingConstants.tsx @@ -0,0 +1,306 @@ +import { ReduxActionTypes } from "./ReduxActionConstants"; +import { Dispatch } from "redux"; +// import { setOnboardingWelcomeState } from "utils/storage"; +// import AnalyticsUtil from "utils/AnalyticsUtil"; +import { showOnboardingLoader } from "actions/onboardingActions"; + +const HandwaveGif = ""; +const DeployGif = ""; +const InputDragGif = ""; +const SuperHeroGif = ""; + +export enum OnboardingStep { + NONE = -1, + WELCOME = 0, + EXAMPLE_DATABASE = 1, + RUN_QUERY_SUCCESS = 2, + SUCCESSFUL_BINDING = 3, + ADD_INPUT_WIDGET = 4, + DEPLOY = 5, + FINISH = 6, +} + +export type OnboardingHelperConfig = { + step?: number; + title: string; + description?: string; + subSteps?: { description: string }[]; + skipLabel?: string; + hint?: { + description: string; + snippet: string; + }; + image?: { + src: string; + }; + action?: { + label: string; + // action to be dispatched + action?: (dispatch?: Dispatch) => void; + initialStep?: boolean; + }; + secondaryAction?: { + label: string; + action?: { type: string; payload?: any }; + }; + cheatAction?: { + label: string; + action: { type: string; payload?: any }; + }; +}; + +export type OnboardingStepConfig = { + name: string; + setup: () => { type: string; payload?: any }[]; + helper?: OnboardingHelperConfig; +}; + +export const OnboardingConfig: Record = { + [OnboardingStep.NONE]: { + name: "NONE", + setup: () => { + return []; + }, + }, + [OnboardingStep.WELCOME]: { + name: "WELCOME", + setup: () => { + // To setup the state if any + // Return action that needs to be dispatched + return [showOnboardingLoader(true)]; + }, + helper: { + title: "👋 Welcome to Appsmith!", + description: + "We'd like to show you around! Let's build an app for remote teams to do async meeting updates.", + skipLabel: "No thanks", + image: { + src: HandwaveGif, + }, + action: { + label: "Let’s go", + action: (dispatch) => { + if (dispatch) { + dispatch({ + type: ReduxActionTypes.ONBOARDING_CREATE_APPLICATION, + }); + } + // setOnboardingWelcomeState(false); + }, + initialStep: true, + }, + }, + }, + [OnboardingStep.EXAMPLE_DATABASE]: { + name: "EXAMPLE_DATABASE", + setup: () => { + return [ + { + type: ReduxActionTypes.CREATE_ONBOARDING_DBQUERY_INIT, + }, + { + type: ReduxActionTypes.LISTEN_FOR_CREATE_ACTION, + }, + ]; + }, + helper: { + step: 1, + title: "Query the Super Updates DB", + subSteps: [ + { + description: + "Create a new query that can fetch standup updates from across the multiverse", + }, + { + description: "Hit Run to check it's response", + }, + ], + image: { + src: + "https://res.cloudinary.com/drako999/image/upload/v1611839705/Appsmith/Onboarding/new_query.gif", + }, + skipLabel: "Skip tour", + cheatAction: { + label: "Do it for me", + action: { + type: ReduxActionTypes.ONBOARDING_CREATE_QUERY, + }, + }, + }, + }, + [OnboardingStep.RUN_QUERY_SUCCESS]: { + name: "RUN_QUERY_SUCCESS", + setup: () => { + return [ + { + type: ReduxActionTypes.LISTEN_FOR_ADD_WIDGET, + }, + { + type: ReduxActionTypes.LISTEN_FOR_TABLE_WIDGET_BINDING, + }, + ]; + }, + helper: { + step: 2, + title: "Build the Standup Dashboard", + subSteps: [ + { + description: "Click the add widget button to open the widgets panel", + }, + { + description: + "Drag a table so that heroes can view each other's updates.", + }, + ], + image: { + src: + "https://res.cloudinary.com/drako999/image/upload/v1611839705/Appsmith/Onboarding/addwidget.gif", + }, + skipLabel: "Skip tour", + cheatAction: { + label: "Do it for me", + action: { + type: ReduxActionTypes.ONBOARDING_ADD_TABLE_WIDGET, + }, + }, + }, + }, + [OnboardingStep.SUCCESSFUL_BINDING]: { + name: "SUCCESSFUL_BINDING", + setup: () => { + return []; + }, + helper: { + step: 3, + title: "Connect Real Data", + subSteps: [ + { + description: + "Use your javascript superpowers to populate the static TableData with live query results.", + }, + ], + hint: { + description: "Use the snippet below inside TableData", + snippet: "{{fetch_standup_updates.data}}", + }, + image: { + src: + "https://res.cloudinary.com/drako999/image/upload/v1611906837/Appsmith/Onboarding/property_pane.gif", + }, + skipLabel: "Skip tour", + action: { + label: "Show me how", + action: () => { + // AnalyticsUtil.logEvent("ONBOARDING_BINDING_HINT"); + }, + }, + cheatAction: { + label: "Do it for me", + action: { + type: ReduxActionTypes.ONBOARDING_ADD_TABLEDATA_BINDING, + }, + }, + }, + }, + [OnboardingStep.ADD_INPUT_WIDGET]: { + name: "ADD_INPUT_WIDGET", + setup: () => [ + { + type: ReduxActionTypes.LISTEN_ADD_INPUT_WIDGET, + }, + ], + helper: { + step: 4, + title: "Capture Hero Updates", + subSteps: [ + { + description: + "Drag an input so that heroes can enter their daily updates.", + }, + { + description: + "Create a query in the OnSubmit action to insert a standup_update.", + }, + ], + image: { + src: InputDragGif, + }, + skipLabel: "Skip tour", + cheatAction: { + label: "Do it for me", + action: { + type: ReduxActionTypes.ONBOARDING_ADD_INPUT_WIDGET, + }, + }, + }, + }, + [OnboardingStep.DEPLOY]: { + name: "DEPLOY", + setup: () => { + return [ + { + type: ReduxActionTypes.LISTEN_FOR_DEPLOY, + }, + ]; + }, + helper: { + step: 5, + title: "Deploy the Standup Dashboard to save the world from meetings!", + image: { + src: DeployGif, + }, + skipLabel: "Skip tour", + cheatAction: { + label: "Do it for me", + action: { + type: ReduxActionTypes.ONBOARDING_DEPLOY, + }, + }, + }, + }, + // Final step + [OnboardingStep.FINISH]: { + name: "FINISH", + setup: () => { + return []; + }, + helper: { + title: + "Great Job! You built an app that saves your team from boring meetings", + description: "WHAT YOU’VE LEARNT", + subSteps: [ + { + description: "Query a database directly", + }, + { + description: "Build a dashboard without HTML/CSS", + }, + { + description: "Read/Write data to the UI using JS", + }, + { + description: "Deploy an app with a Click", + }, + ], + image: { + src: SuperHeroGif, + }, + secondaryAction: { + label: "Back Home", + action: { + type: ReduxActionTypes.ONBOARDING_RETURN_HOME, + }, + }, + action: { + label: "Next Mission", + action: () => { + window.open( + "https://docs.appsmith.com/v/v1.2.1/tutorial-1", + "_blank", + ); + // AnalyticsUtil.logEvent("ONBOARDING_NEXT_MISSION"); + }, + }, + }, + }, +}; diff --git a/app/taro/src/constants/PropertyControlConstants.tsx b/app/taro/src/constants/PropertyControlConstants.tsx new file mode 100644 index 0000000000..24d9a4db0e --- /dev/null +++ b/app/taro/src/constants/PropertyControlConstants.tsx @@ -0,0 +1,94 @@ +import { getPropertyControlTypes } from "components/propertyControls"; +import { + ValidationResponse, + ValidationTypes, +} from "constants/WidgetValidation"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import { CodeEditorExpected } from "components/editorComponents/CodeEditor"; +const ControlTypes = getPropertyControlTypes(); +export type ControlType = typeof ControlTypes[keyof typeof ControlTypes]; + +export type PropertyPaneSectionConfig = { + sectionName: string; + id?: string; + children: PropertyPaneConfig[]; + hidden?: (props: any, propertyPath: string) => boolean; + propertySectionPath?: string; +}; + +export type PanelConfig = { + editableTitle: boolean; + titlePropertyName: string; + panelIdPropertyName: string; + children: PropertyPaneConfig[]; + updateHook: ( + props: any, + propertyPath: string, + propertyValue: any, + ) => Array<{ propertyPath: string; propertyValue: any }> | undefined; +}; + +export type PropertyPaneControlConfig = { + id?: string; + label: string; + propertyName: string; + helpText?: string; + isJSConvertible?: boolean; + customJSControl?: string; + controlType: ControlType; + validationMessage?: string; + dataTreePath?: string; + children?: PropertyPaneConfig[]; + panelConfig?: PanelConfig; + updateHook?: ( + props: any, + propertyName: string, + propertyValue: any, + ) => Array<{ propertyPath: string; propertyValue: any }> | undefined; + hidden?: (props: any, propertyPath: string) => boolean; + isBindProperty: boolean; + isTriggerProperty: boolean; + validation?: ValidationConfig; + useValidationMessage?: boolean; + additionalAutoComplete?: ( + props: any, + ) => Record>; + evaluationSubstitutionType?: EvaluationSubstitutionType; + dependencies?: string[]; + expected?: CodeEditorExpected; +}; + +type ValidationConfigParams = { + min?: number; // min allowed for a number + max?: number; // max allowed for a number + natural?: boolean; // is a positive integer + default?: unknown; // default for any type + unique?: boolean | string[]; // unique in an array (string if a particular path is unique) + required?: boolean; // required type + regex?: RegExp; // validator regex for text type + allowedKeys?: Array<{ + // Allowed keys in an object type + name: string; + type: ValidationTypes; + params?: ValidationConfigParams; + }>; + allowedValues?: unknown[]; // Allowed values in a string and array type + children?: ValidationConfig; // Children configurations in an ARRAY or OBJECT_ARRAY type + fn?: ( + value: unknown, + props: any, + _?: any, + moment?: any, + ) => ValidationResponse; // Function in a FUNCTION type + fnString?: string; // AUTO GENERATED, SHOULD NOT BE SET BY WIDGET DEVELOPER + expected?: CodeEditorExpected; // FUNCTION type expected type and example +}; + +export type ValidationConfig = { + type: ValidationTypes; + params?: ValidationConfigParams; +}; + +export type PropertyPaneConfig = + | PropertyPaneSectionConfig + | PropertyPaneControlConfig; diff --git a/app/taro/src/constants/QueryEditorConstants.ts b/app/taro/src/constants/QueryEditorConstants.ts new file mode 100644 index 0000000000..5bfd35913e --- /dev/null +++ b/app/taro/src/constants/QueryEditorConstants.ts @@ -0,0 +1,10 @@ +export const PLUGIN_NAME_POSTGRES = "PostgresDbPlugin"; +export const PLUGIN_NAME_MONGODB = " MongoDBPlugin"; +export const PLUGIN_NAME_DBS = [PLUGIN_NAME_POSTGRES, PLUGIN_NAME_MONGODB]; +export const QUERY_BODY_FIELD = "actionConfiguration.body"; +export const PLUGIN_PACKAGE_POSTGRES = "postgres-plugin"; +export const PLUGIN_PACKAGE_MONGO = "mongo-plugin"; +export const PLUGIN_PACKAGE_DBS = [ + PLUGIN_PACKAGE_POSTGRES, + PLUGIN_PACKAGE_MONGO, +]; diff --git a/app/taro/src/constants/ReduxActionConstants.tsx b/app/taro/src/constants/ReduxActionConstants.tsx new file mode 100644 index 0000000000..dd23d1d7c2 --- /dev/null +++ b/app/taro/src/constants/ReduxActionConstants.tsx @@ -0,0 +1,731 @@ +import { WidgetCardProps, WidgetProps } from "widgets/BaseWidget"; +import { PageAction } from "constants/AppsmithActionConstants/ActionConstants"; +import { Org } from "./orgConstants"; +import { ERROR_CODES } from "constants/ApiConstants"; +import { AppLayoutConfig } from "reducers/entityReducers/pageListReducer"; + +export const ReduxSagaChannels: { [key: string]: string } = { + WEBSOCKET_WRITE_CHANNEL: "WEBSOCKET_WRITE_CHANNEL", +}; + +export const ReduxActionTypes = { + FETCH_FEATURE_FLAGS_INIT: "FETCH_FEATURE_FLAGS_INIT", + FETCH_FEATURE_FLAGS_SUCCESS: "FETCH_FEATURE_FLAGS_SUCCESS", + BIND_DATA_TO_WIDGET: "BIND_DATA_TO_WIDGET", + BIND_DATA_ON_CANVAS: "BIND_DATA_ON_CANVAS", + INCREMENT_COMMENT_THREAD_UNREAD_COUNT: + "INCREMENT_COMMENT_THREAD_UNREAD_COUNT", + DECREMENT_COMMENT_THREAD_UNREAD_COUNT: + "DECREMENT_COMMENT_THREAD_UNREAD_COUNT", + FETCH_UNREAD_COMMENT_THREADS_COUNT_REQUEST: + "FETCH_UNREAD_COMMENT_THREADS_COUNT_REQUEST", + FETCH_UNREAD_COMMENT_THREADS_COUNT_SUCCESS: + "FETCH_UNREAD_COMMENT_THREADS_COUNT_SUCCESS", + MARK_NOTIFICATION_AS_READ_REQUEST: "MARK_NOTIFICATION_AS_READ_REQUEST", + MARK_NOTIFICATION_AS_READ_SUCCESS: "MARK_NOTIFICATION_AS_READ_SUCCESS", + FETCH_UNREAD_NOTIFICATIONS_COUNT_REQUEST: + "FETCH_UNREAD_NOTIFICATIONS_COUNT_REQUEST", + FETCH_UNREAD_NOTIFICATIONS_COUNT_SUCCESS: + "FETCH_UNREAD_NOTIFICATIONS_COUNT_SUCCESS", + RESET_NOTIFICATIONS: "RESET_NOTIFICATIONS", + MARK_ALL_NOTIFICATIONS_AS_READ_REQUEST: + "MARK_ALL_NOTIFICATIONS_AS_READ_REQUEST", + MARK_ALL_NOTIFICATIONS_AS_READ_SUCCESS: + "MARK_ALL_NOTIFICATIONS_AS_READ_SUCCESS", + SET_IS_NOTIFICATIONS_LIST_VISIBLE: "SET_IS_NOTIFICATIONS_LIST_VISIBLE", + NEW_NOTIFICATION_EVENT: "NEW_NOTIFICATION_EVENT", + FETCH_NOTIFICATIONS_REQUEST: "FETCH_NOTIFICATIONS_REQUEST", + FETCH_NOTIFICATIONS_SUCCESS: "FETCH_NOTIFICATIONS_SUCCESS", + SET_SHOW_APP_INVITE_USERS_MODAL: "SET_SHOW_APP_INVITE_USERS_MODAL", + UPDATE_COMMENT_EVENT: "UPDATE_COMMENT_EVENT", + ADD_COMMENT_REACTION: "ADD_COMMENT_REACTION", + REMOVE_COMMENT_REACTION: "REMOVE_COMMENT_REACTION", + UPLOAD_PROFILE_PHOTO: "UPLOAD_PROFILE_PHOTO", + REMOVE_PROFILE_PHOTO: "REMOVE_PROFILE_PHOTO", + HIDE_COMMENTS_INTRO_CAROUSEL: "HIDE_COMMENTS_INTRO_CAROUSEL", + SHOW_COMMENTS_INTRO_CAROUSEL: "SHOW_COMMENTS_INTRO_CAROUSEL", + PROCEED_TO_NEXT_TOUR_STEP: "PROCEED_TO_NEXT_TOUR_STEP", + SET_ACTIVE_TOUR: "SET_ACTIVE_TOUR", + RESET_ACTIVE_TOUR: "RESET_ACTIVE_TOUR", + SET_ACTIVE_TOUR_INDEX: "SET_ACTIVE_TOUR_INDEX", + SET_ARE_COMMENTS_ENABLED: "SET_ARE_COMMENTS_ENABLED", + DELETE_THREAD_REQUEST: "DELETE_THREAD_REQUEST", + DELETE_THREAD_SUCCESS: "DELETE_THREAD_SUCCESS", + EDIT_COMMENT_REQUEST: "EDIT_COMMENT_REQUEST", + EDIT_COMMENT_SUCCESS: "EDIT_COMMENT_SUCCESS", + MARK_THREAD_AS_READ_REQUEST: "MARK_THREAD_AS_READ_REQUEST", + SET_VISIBLE_THREAD: "SET_VISIBLE_THREAD", + RESET_VISIBLE_THREAD: "RESET_VISIBLE_THREAD", + SET_APP_COMMENTS_FILTER: "SET_APP_COMMENTS_FILTER", + SET_SHOULD_SHOW_RESOLVED_COMMENTS: "SET_SHOULD_SHOW_RESOLVED_COMMENTS", + DELETE_COMMENT_REQUEST: "DELETE_COMMENT_REQUEST", + DELETE_COMMENT_SUCCESS: "DELETE_COMMENT_SUCCESS", + PIN_COMMENT_THREAD_REQUEST: "PIN_COMMENT_THREAD_REQUEST", + PIN_COMMENT_THREAD_SUCCESS: "PIN_COMMENT_THREAD_SUCCESS", + RETRY_WEBSOCKET_CONNECTION: "RETRY_WEBSOCKET_CONNECTION", + SET_IS_WEBSOCKET_CONNECTED: "SET_IS_WEBSOCKET_CONNECTED", + UPDATE_COMMENT_THREAD_EVENT: "UPDATE_COMMENT_THREAD_EVENT", + UPDATE_COMMENT_THREAD_SUCCESS: "UPDATE_COMMENT_THREAD_SUCCESS", + SET_COMMENT_THREAD_RESOLUTION_REQUEST: + "SET_COMMENT_THREAD_RESOLUTION_REQUEST", + SET_COMMENT_THREAD_RESOLUTION_SUCCESS: + "SET_COMMENT_THREAD_RESOLUTION_SUCCESS", + NEW_COMMENT_EVENT: "NEW_COMMENT_EVENT", + NEW_COMMENT_THREAD_EVENT: "NEW_COMMENT_THREAD_EVENT", + FETCH_APPLICATION_COMMENTS_SUCCESS: "FETCH_APPLICATION_COMMENTS_SUCCESS", + FETCH_APPLICATION_COMMENTS_REQUEST: "FETCH_APPLICATION_COMMENTS_REQUEST", + UNRESOLVE_COMMENT_THREAD: "UNRESOLVE_COMMENT_THREAD", + RESOLVE_COMMENT_THREAD: "RESOLVE_COMMENT_THREAD", + SET_IS_COMMENT_THREAD_VISIBLE: "SET_IS_COMMENT_THREAD_VISIBLE", + SET_COMMENT_MODE: "SET_COMMENT_MODE", + SET_SNIPING_MODE: "SET_SNIPING_MODE", + RESET_SNIPING_MODE: "RESET_SNIPING_MODE", + HANDLE_PATH_UPDATED: "HANDLE_PATH_UPDATED", + RESET_EDITOR_REQUEST: "RESET_EDITOR_REQUEST", + RESET_EDITOR_SUCCESS: "RESET_EDITOR_SUCCESS", + ADD_COMMENT_TO_THREAD_SUCCESS: "ADD_COMMENT_TO_THREAD_SUCCESS", + ADD_COMMENT_TO_THREAD_REQUEST: "ADD_COMMENT_TO_THREAD_REQUEST", + CREATE_COMMENT_THREAD_REQUEST: "CREATE_COMMENT_THREAD_REQUEST", + CREATE_COMMENT_THREAD_SUCCESS: "CREATE_COMMENT_THREAD_SUCCESS", + UNSUBSCRIBE_COMMENT_THREAD_REQUEST: "UNSUBSCRIBE_COMMENT_THREAD_REQUEST", + UNSUBSCRIBE_COMMENT_THREAD_SUCCESS: "UNSUBSCRIBE_COMMENT_THREAD_SUCCESS", + REMOVE_UNPUBLISHED_COMMENT_THREAD_REQUEST: + "REMOVE_UNPUBLISHED_COMMENT_THREAD_REQUEST", + CREATE_UNPUBLISHED_COMMENT_THREAD_REQUEST: + "CREATE_UNPUBLISHED_COMMENT_THREAD_REQUEST", + CREATE_UNPUBLISHED_COMMENT_THREAD_SUCCESS: + "CREATE_UNPUBLISHED_COMMENT_THREAD_SUCCESS", + SET_COMMENT_THREADS_SUCCESS: "SET_COMMENT_THREADS_SUCCESS", // todo remove (for dev) + SET_COMMENT_THREADS_REQUEST: "SET_COMMENT_THREADS_REQUEST", // todo remove (for dev) + INIT_COMMENT_THREADS: "INIT_COMMENT_THREADS", // todo remove (for dev) + INITIALIZE_EDITOR: "INITIALIZE_EDITOR", + INITIALIZE_EDITOR_SUCCESS: "INITIALIZE_EDITOR_SUCCESS", + REPORT_ERROR: "REPORT_ERROR", + FLUSH_ERRORS: "FLUSH_ERRORS", + FLUSH_AND_REDIRECT: "FLUSH_AND_REDIRECT", + REDIRECT_TO_NEW_INTEGRATIONS: "REDIRECT_TO_NEW_INTEGRATIONS", + SAFE_CRASH_APPSMITH: "SAFE_CRASH_APPSMITH", + SAFE_CRASH_APPSMITH_REQUEST: "SAFE_CRASH_APPSMITH_REQUEST", + INIT_CANVAS_LAYOUT: "INIT_CANVAS_LAYOUT", + FETCH_CANVAS: "FETCH_CANVAS", + CLEAR_CANVAS: "CLEAR_CANVAS", + FETCH_PAGE_INIT: "FETCH_PAGE_INIT", + FETCH_PAGE_SUCCESS: "FETCH_PAGE_SUCCESS", + DROP_WIDGET_CANVAS: "DROP_WIDGET_CANVAS", + REMOVE_WIDGET_CANVAS: "REMOVE_WIDGET_CANVAS", + LOAD_WIDGET_PANE: "LOAD_WIDGET_PANE", + ZOOM_IN_CANVAS: "ZOOM_IN_CANVAS", + ZOOM_OUT_CANVAS: "ZOOM_OUT_CANVAS", + START_CANVAS_SELECTION: "START_CANVAS_SELECTION", + STOP_CANVAS_SELECTION: "STOP_CANVAS_SELECTION", + UNDO_CANVAS_ACTION: "UNDO_CANVAS_ACTION", + REDO_CANVAS_ACTION: "REDO_CANVAS_ACTION", + LOAD_WIDGET_CONFIG: "LOAD_WIDGET_CONFIG", + LOAD_PROPERTY_CONFIG: "LOAD_PROPERTY_CONFIG", + UPDATE_APPLICATION: "UPDATE_APPLICATION", + UPDATE_APP_LAYOUT: "UPDATE_APP_LAYOUT", + UPDATE_APPLICATION_SUCCESS: "UPDATE_APPLICATION_SUCCESS", + PUBLISH: "PUBLISH", + DEBUGGER_LOG: "DEBUGGER_LOG", + DEBUGGER_LOG_INIT: "DEBUGGER_LOG_INIT", + DEBUGGER_ERROR_LOG: "DEBUGGER_ERROR_LOG", + DEBUGGER_UPDATE_ERROR_LOG: "DEBUGGER_UPDATE_ERROR_LOG", + DEBUGGER_UPDATE_ERROR_LOGS: "DEBUGGER_UPDATE_ERROR_LOGS", + DEBUGGER_ERROR_ANALYTICS: "DEBUGGER_ERROR_ANALYTICS", + CLEAR_DEBUGGER_LOGS: "CLEAR_DEBUGGER_LOGS", + SHOW_DEBUGGER: "SHOW_DEBUGGER", + SET_ACTION_TABS_INITIAL_INDEX: "SET_ACTION_TABS_INITIAL_INDEX", + SET_THEME: "SET_THEME", + FETCH_WIDGET_CARDS: "FETCH_WIDGET_CARDS", + FETCH_WIDGET_CARDS_SUCCESS: "FETCH_WIDGET_CARDS_SUCCESS", + ADD_PAGE_WIDGET: "ADD_PAGE_WIDGET", + REMOVE_PAGE_WIDGET: "REMOVE_PAGE_WIDGET", + LOAD_API_RESPONSE: "LOAD_API_RESPONSE", + LOAD_QUERY_RESPONSE: "LOAD_QUERY_RESPONSE", + RUN_ACTION_SHORTCUT_REQUEST: "RUN_ACTION_SHORTCUT_REQUEST", + RUN_ACTION_INIT: "RUN_ACTION_INIT", + RUN_ACTION_REQUEST: "RUN_ACTION_REQUEST", + RUN_ACTION_SUCCESS: "RUN_ACTION_SUCCESS", + INIT_API_PANE: "INIT_API_PANE", + API_PANE_CHANGE_API: "API_PANE_CHANGE_API", + EXECUTE_ACTION: "EXECUTE_ACTION", + EXECUTE_ACTION_SUCCESS: "EXECUTE_ACTION_SUCCESS", + LOAD_CANVAS_ACTIONS: "LOAD_CANVAS_ACTIONS", + SAVE_PAGE_INIT: "SAVE_PAGE_INIT", + SAVE_PAGE_SUCCESS: "SAVE_PAGE_SUCCESS", + UPDATE_LAYOUT: "UPDATE_LAYOUT", + SHOW_PROPERTY_PANE: "SHOW_PROPERTY_PANE", + UPDATE_CANVAS_LAYOUT: "UPDATE_CANVAS_LAYOUT", + UPDATE_WIDGET_PROPERTY_REQUEST: "UPDATE_WIDGET_PROPERTY_REQUEST", + UPDATE_WIDGET_PROPERTY: "UPDATE_WIDGET_PROPERTY", + UPDATE_WIDGET_DYNAMIC_PROPERTY: "UPDATE_WIDGET_DYNAMIC_PROPERTY", + BATCH_UPDATE_WIDGET_PROPERTY: "BATCH_UPDATE_WIDGET_PROPERTY", + DELETE_WIDGET_PROPERTY: "DELETE_WIDGET_PROPERTY", + FETCH_PROPERTY_PANE_CONFIGS_INIT: "FETCH_PROPERTY_PANE_CONFIGS_INIT", + FETCH_PROPERTY_PANE_CONFIGS_SUCCESS: "FETCH_PROPERTY_PANE_CONFIGS_SUCCESS", + FETCH_CONFIGS_INIT: "FETCH_CONFIGS_INIT", + ADD_WIDGET_REF: "ADD_WIDGET_REF", + CREATE_ACTION_INIT: "CREATE_ACTION_INIT", + CREATE_ACTION_SUCCESS: "CREATE_ACTION_SUCCESS", + FETCH_ACTIONS_INIT: "FETCH_ACTIONS_INIT", + FETCH_ACTIONS_SUCCESS: "FETCH_ACTIONS_SUCCESS", + UPDATE_ACTION_INIT: "UPDATE_ACTION_INIT", + UPDATE_ACTION_SUCCESS: "UPDATE_ACTION_SUCCESS", + DELETE_ACTION_INIT: "DELETE_ACTION_INIT", + SET_DATASOURCE_EDITOR_MODE: "SET_DATASOURCE_EDITOR_MODE", + DELETE_ACTION_SUCCESS: "DELETE_ACTION_SUCCESS", + SHOW_RUN_ACTION_CONFIRM_MODAL: "SHOW_RUN_ACTION_CONFIRM_MODAL", + CANCEL_RUN_ACTION_CONFIRM_MODAL: "CANCEL_RUN_ACTION_CONFIRM_MODAL", + ACCEPT_RUN_ACTION_CONFIRM_MODAL: "ACCEPT_RUN_ACTION_CONFIRM_MODAL", + CREATE_QUERY_INIT: "CREATE_QUERY_INIT", + CREATE_ONBOARDING_DBQUERY_SUCCESS: "CREATE_ONBOARDING_DBQUERY_SUCCESS", + END_ONBOARDING: "END_ONBOARDING", + SET_CURRENT_STEP: "SET_CURRENT_STEP", + SET_ONBOARDING_SUBSTEP: "SET_ONBOARDING_SUBSTEP", + SET_ONBOARDING_STATE: "SET_ONBOARDING_STATE", + NEXT_ONBOARDING_STEP: "NEXT_ONBOARDING_STEP", + SHOW_ONBOARDING_HELPER: "SHOW_ONBOARDING_HELPER", + ONBOARDING_RETURN_HOME: "ONBOARDING_RETURN_HOME", + SET_HELPER_CONFIG: "SET_HELPER_CONFIG", + INCREMENT_STEP: "INCREMENT_STEP", + SHOW_ONBOARDING_LOADER: "SHOW_ONBOARDING_LOADER", + SHOW_END_ONBOARDING_HELPER: "SHOW_END_ONBOARDING_HELPER", + ONBOARDING_CREATE_QUERY: "ONBOARDING_CREATE_QUERY", + ONBOARDING_RUN_QUERY: "ONBOARDING_RUN_QUERY", + ONBOARDING_ADD_TABLE_WIDGET: "ONBOARDING_ADD_TABLE_WIDGET", + ONBOARDING_ADD_INPUT_WIDGET: "ONBOARDING_ADD_INPUT_WIDGET", + ONBOARDING_ADD_ONSUBMIT_BINDING: "ONBOARDING_ADD_ONSUBMIT_BINDING", + ONBOARDING_ADD_TABLEDATA_BINDING: "ONBOARDING_ADD_TABLEDATA_BINDING", + ONBOARDING_DEPLOY: "ONBOARDING_DEPLOY", + ONBOARDING_CREATE_APPLICATION: "ONBOARDING_CREATE_APPLICATION", + FETCH_DATASOURCES_INIT: "FETCH_DATASOURCES_INIT", + FETCH_DATASOURCES_SUCCESS: "FETCH_DATASOURCES_SUCCESS", + FETCH_MOCK_DATASOURCES_INIT: "FETCH_MOCK_DATASOURCES_INIT", + FETCH_MOCK_DATASOURCES_SUCCESS: "FETCH_MOCK_DATASOURCES_SUCCESS", + ADD_MOCK_DATASOURCES_INIT: "ADD_MOCK_DATASOURCES_INIT", + ADD_MOCK_DATASOURCES_SUCCESS: "ADD_MOCK_DATASOURCES_SUCCESS", + SAVE_DATASOURCE_NAME: "SAVE_DATASOURCE_NAME", + SAVE_DATASOURCE_NAME_SUCCESS: "SAVE_DATASOURCE_NAME_SUCCESS", + CREATE_DATASOURCE_INIT: "CREATE_DATASOURCE_INIT", + CREATE_DATASOURCE_SUCCESS: "CREATE_DATASOURCE_SUCCESS", + CREATE_DATASOURCE_FROM_FORM_INIT: "CREATE_DATASOURCE_FROM_FORM_INIT", + UPDATE_DATASOURCE_INIT: "UPDATE_DATASOURCE_INIT", + UPDATE_DATASOURCE_SUCCESS: "UPDATE_DATASOURCE_SUCCESS", + CHANGE_DATASOURCE: "CHANGE_DATASOURCE", + FETCH_DATASOURCE_STRUCTURE_INIT: "FETCH_DATASOURCE_STRUCTURE_INIT", + FETCH_DATASOURCE_STRUCTURE_SUCCESS: "FETCH_DATASOURCE_STRUCTURE_SUCCESS", + REFRESH_DATASOURCE_STRUCTURE_INIT: "REFRESH_DATASOURCE_STRUCTURE_INIT", + REFRESH_DATASOURCE_STRUCTURE_SUCCESS: "REFRESH_DATASOURCE_STRUCTURE_SUCCESS", + EXPAND_DATASOURCE_ENTITY: "EXPAND_DATASOURCE_ENTITY", + TEST_DATASOURCE_INIT: "TEST_DATASOURCE_INIT", + TEST_DATASOURCE_SUCCESS: "TEST_DATASOURCE_SUCCESS", + DELETE_DATASOURCE_DRAFT: "DELETE_DATASOURCE_DRAFT", + UPDATE_DATASOURCE_DRAFT: "UPDATE_DATASOURCE_DRAFT", + SHOW_ONBOARDING_INDICATOR: "SHOW_ONBOARDING_INDICATOR", + SHOW_ONBOARDING_WELCOME_HELPER: "SHOW_ONBOARDING_WELCOME_HELPER", + CREATE_ONBOARDING_DBQUERY_INIT: "CREATE_ONBOARDING_DBQUERY_INIT", + ADD_WIDGET_COMPLETE: "ADD_WIDGET_COMPLETE", + LISTEN_FOR_ADD_WIDGET: "LISTEN_FOR_ADD_WIDGET", + LISTEN_FOR_CREATE_ACTION: "LISTEN_FOR_CREATE_ACTION", + LISTEN_FOR_WIDGET_UNSELECTION: "LISTEN_FOR_WIDGET_UNSELECTION", + LISTEN_FOR_DEPLOY: "LISTEN_FOR_DEPLOY", + LISTEN_FOR_TABLE_WIDGET_BINDING: "LISTEN_FOR_TABLE_WIDGET_BINDING", + LISTEN_ADD_INPUT_WIDGET: "LISTEN_ADD_INPUT_WIDGET", + FETCH_PUBLISHED_PAGE_INIT: "FETCH_PUBLISHED_PAGE_INIT", + FETCH_PUBLISHED_PAGE_SUCCESS: "FETCH_PUBLISHED_PAGE_SUCCESS", + REDIRECT_AUTHORIZATION_CODE: "REDIRECT_AUTHORIZATION_CODE", + REDIRECT_WINDOW_LOCATION: "REDIRECT_WINDOW_LOCATION", + HISTORY_PUSH: "HISTORY_PUSH", + DELETE_DATASOURCE_INIT: "DELETE_DATASOURCE_INIT", + DELETE_DATASOURCE_SUCCESS: "DELETE_DATASOURCE_SUCCESS", + STORE_AS_DATASOURCE_INIT: "STORE_AS_DATASOURCE_INIT", + STORE_AS_DATASOURCE_UPDATE: "STORE_AS_DATASOURCE_UPDATE", + STORE_AS_DATASOURCE_COMPLETE: "STORE_AS_DATASOURCE_COMPLETE", + PUBLISH_APPLICATION_INIT: "PUBLISH_APPLICATION_INIT", + PUBLISH_APPLICATION_SUCCESS: "PUBLISH_APPLICATION_SUCCESS", + CHANGE_APPVIEW_ACCESS_INIT: "CHANGE_APPVIEW_ACCESS_INIT", + CHANGE_APPVIEW_ACCESS_SUCCESS: "CHANGE_APPVIEW_ACCESS_SUCCESS", + CREATE_PAGE_INIT: "CREATE_PAGE_INIT", + CREATE_PAGE_SUCCESS: "CREATE_PAGE_SUCCESS", + FETCH_PAGE_LIST_INIT: "FETCH_PAGE_LIST_INIT", + FETCH_PAGE_LIST_SUCCESS: "FETCH_PAGE_LIST_SUCCESS", + INITIALIZE_PAGE_VIEWER: "INITIALIZE_PAGE_VIEWER", + INITIALIZE_PAGE_VIEWER_SUCCESS: "INITIALIZE_PAGE_VIEWER_SUCCESS", + FETCH_APPLICATION_INIT: "FETCH_APPLICATION_INIT", + FETCH_APPLICATION_SUCCESS: "FETCH_APPLICATION_SUCCESS", + CREATE_APPLICATION_INIT: "CREATE_APPLICATION_INIT", + CREATE_APPLICATION_SUCCESS: "CREATE_APPLICATION_SUCCESS", + UPDATE_WIDGET_PROPERTY_VALIDATION: "UPDATE_WIDGET_PROPERTY_VALIDATION", + HIDE_PROPERTY_PANE: "HIDE_PROPERTY_PANE", + INIT_DATASOURCE_PANE: "INIT_DATASOURCE_PANE", + INIT_QUERY_PANE: "INIT_QUERY_PANE", + QUERY_PANE_CHANGE: "QUERY_PANE_CHANGE", + UPDATE_ROUTES_PARAMS: "UPDATE_ROUTES_PARAMS", + SET_EXTRA_FORMDATA: "SET_EXTRA_FORMDATA", + PERSIST_USER_SESSION: "PERSIST_USER_SESSION", + LOGIN_USER_INIT: "LOGIN_USER_INIT", + LOGIN_USER_SUCCESS: "LOGIN_USER_SUCCESS", + CREATE_USER_INIT: "CREATE_USER_INIT", + CREATE_USER_SUCCESS: "CREATE_USER_SUCCESS", + RESET_USER_PASSWORD_INIT: "RESET_USER_PASSWORD_INIT", + RESET_USER_PASSWORD_SUCCESS: "RESET_USER_PASSWORD_SUCCESS", + FETCH_PLUGINS_REQUEST: "FETCH_PLUGINS_REQUEST", + FETCH_PLUGINS_SUCCESS: "FETCH_PLUGINS_SUCCESS", + FETCH_PLUGIN_FORM_CONFIGS_REQUEST: "FETCH_PLUGIN_FORM_CONFIGS_REQUEST", + FETCH_PLUGIN_FORM_CONFIGS_SUCCESS: "FETCH_PLUGIN_FORM_CONFIGS_SUCCESS", + FETCH_PLUGIN_FORM_SUCCESS: "FETCH_PLUGIN_FORM_SUCCESS", + INVITE_USERS_TO_ORG_INIT: "INVITE_USERS_TO_ORG_INIT", + INVITE_USERS_TO_ORG_SUCCESS: "INVITE_USERS_TO_ORG_SUCCESS", + FORGOT_PASSWORD_INIT: "FORGOT_PASSWORD_INIT", + FORGOT_PASSWORD_SUCCESS: "FORGOT_PASSWORD_SUCCESS", + RESET_PASSWORD_VERIFY_TOKEN_SUCCESS: "RESET_PASSWORD_VERIFY_TOKEN_SUCCESS", + RESET_PASSWORD_VERIFY_TOKEN_INIT: "RESET_PASSWORD_VERIFY_TOKEN_INIT", + EXECUTE_PAGE_LOAD_ACTIONS: "EXECUTE_PAGE_LOAD_ACTIONS", + EXECUTE_PAGE_LOAD_ACTIONS_COMPLETE: "EXECUTE_PAGE_LOAD_ACTIONS_COMPLETE", + SWITCH_ORGANIZATION_INIT: "SWITCH_ORGANIZATION_INIT", + SWITCH_ORGANIZATION_SUCCESS: "SWITCH_ORGANIZATION_SUCCESS", + FETCH_ORG_ROLES_INIT: "FETCH_ORG_ROLES_INIT", + FETCH_ORG_ROLES_SUCCESS: "FETCH_ORG_ROLES_SUCCESS", + FETCH_ORG_INIT: "FETCH_ORG_INIT", + FETCH_ORG_SUCCESS: "FETCH_ORG_SUCCESS", + FETCH_ORGS_SUCCESS: "FETCH_ORGS_SUCCES", + FETCH_ORGS_INIT: "FETCH_ORGS_INIT", + SAVE_ORG_INIT: "SAVE_ORG_INIT", + SAVE_ORG_SUCCESS: "SAVE_ORG_SUCCESS", + UPLOAD_ORG_LOGO: "UPLOAD_ORG_LOGO", + REMOVE_ORG_LOGO: "REMOVE_ORG_LOGO", + SAVING_ORG_INFO: "SAVING_ORG_INFO", + SET_LAST_UPDATED_TIME: "SET_LAST_UPDATED_TIME", + SET_CURRENT_ORG: "SET_CURRENT_ORG", + SET_CURRENT_ORG_ID: "SET_CURRENT_ORG_ID", + FETCH_CURRENT_ORG: "FETCH_CURRENT_ORG", + STORE_DATASOURCE_REFS: "STORE_DATASOURCE_REFS", + UPDATE_DATASOURCE_REFS: "UPDATE_DATASOURCE_REFS", + FETCH_USER_INIT: "FETCH_USER_INIT", + PROP_PANE_MOVED: "PROP_PANE_MOVED", + FETCH_USER_SUCCESS: "FETCH_USER_SUCCESS", + SET_CURRENT_USER_INIT: "SET_CURRENT_USER_INIT", + SET_CURRENT_USER_SUCCESS: "SET_CURRENT_USER_SUCCESS", + LOGOUT_USER_INIT: "LOGOUT_USER_INIT", + LOGOUT_USER_SUCCESS: "LOGOUT_USER_SUCCESS", + VERIFY_INVITE_INIT: "VERIFY_INVITE_INIT", + VERIFY_INVITE_SUCCESS: "VERIFY_INVITE_SUCCESS", + INVITED_USER_SIGNUP_SUCCESS: "INVITED_USER_SIGNUP_SUCCESS", + INVITED_USER_SIGNUP_INIT: "INVITED_USER_SIGNUP_INIT", + DISABLE_WIDGET_DRAG: "DISABLE_WIDGET_DRAG", + SELECT_WIDGET_INIT: "SELECT_WIDGET_INIT", + SHIFT_SELECT_WIDGET_INIT: "SHIFT_SELECT_WIDGET_INIT", + SELECT_WIDGET: "SELECT_WIDGET", + SELECT_MULTIPLE_WIDGETS: "SELECT_MULTIPLE_WIDGETS", + SELECT_MULTIPLE_WIDGETS_INIT: "SELECT_MULTIPLE_WIDGETS_INIT", + SELECT_ALL_WIDGETS_IN_CANVAS_INIT: "SELECT_ALL_WIDGETS_IN_CANVAS_INIT", + DESELECT_WIDGETS: "DESELECT_WIDGETS", + SELECT_WIDGETS: "SELECT_WIDGETS", + FOCUS_WIDGET: "FOCUS_WIDGET", + SET_WIDGET_DRAGGING: "SET_WIDGET_DRAGGING", + SET_WIDGET_RESIZING: "SET_WIDGET_RESIZING", + ADD_SUGGESTED_WIDGET: "ADD_SUGGESTED_WIDGET", + SEARCH_APPLICATIONS: "SEARCH_APPLICATIONS", + UPDATE_PAGE_INIT: "UPDATE_PAGE_INIT", + UPDATE_PAGE_SUCCESS: "UPDATE_PAGE_SUCCESS", + MOVE_ACTION_INIT: "MOVE_ACTION_INIT", + MOVE_ACTION_SUCCESS: "MOVE_ACTION_SUCCESS", + COPY_ACTION_INIT: "COPY_ACTION_INIT", + COPY_ACTION_SUCCESS: "COPY_ACTION_SUCCESS", + DELETE_APPLICATION_INIT: "DELETE_APPLICATION_INIT", + DELETE_APPLICATION_SUCCESS: "DELETE_APPLICATION_SUCCESS", + DUPLICATE_APPLICATION_INIT: "DUPLICATE_APPLICATION_INIT", + DUPLICATE_APPLICATION_SUCCESS: "DUPLICATE_APPLICATION_SUCCESS", + DELETE_PAGE_INIT: "DELETE_PAGE_INIT", + DELETE_PAGE_SUCCESS: "DELETE_PAGE_SUCCESS", + CLONE_PAGE_INIT: "CLONE_PAGE_INIT", + CLONE_PAGE_SUCCESS: "CLONE_PAGE_SUCCESS", + SET_DEFAULT_APPLICATION_PAGE_INIT: "SET_DEFAULT_APPLICATION_PAGE_INIT", + SET_DEFAULT_APPLICATION_PAGE_SUCCESS: "SET_DEFAULT_APPLICATION_PAGE_SUCCESS", + CREATE_ORGANIZATION_INIT: "CREATE_ORGANIZATION_INIT", + CREATE_ORGANIZATION_SUCCESS: "CREATE_ORGANIZATION_SUCCESS", + ADD_USER_TO_ORG_INIT: "ADD_USER_TO_ORG_INIT", + ADD_USER_TO_ORG_SUCCESS: "ADD_USER_TO_ORG_ERROR", + SET_META_PROP: "SET_META_PROP", + RESET_CHILDREN_WIDGET_META: "RESET_CHILDREN_WIDGET_META", + RESET_WIDGET_META: "RESET_WIDGET_META", + UPDATE_WIDGET_NAME_INIT: "UPDATE_WIDGET_NAME_INIT", + UPDATE_WIDGET_NAME_SUCCESS: "UPDATE_WIDGET_NAME_SUCCESS", + FETCH_ACTIONS_FOR_PAGE_INIT: "FETCH_ACTIONS_FOR_PAGE_INIT", + FETCH_ACTIONS_FOR_PAGE_SUCCESS: "FETCH_ACTIONS_FOR_PAGE_SUCCESS", + EXECUTE_API_ACTION_REQUEST: "EXECUTE_API_ACTION_REQUEST", + EXECUTE_API_ACTION_SUCCESS: "EXECUTE_API_ACTION_SUCCESS", + FETCH_IMPORTED_COLLECTIONS_INIT: "FETCH_IMPORTED_COLLECTIONS_INIT", + FETCH_IMPORTED_COLLECTIONS_SUCCESS: "FETCH_IMPORTED_COLLECTIONS_SUCCESS", + SEARCH_APIORPROVIDERS_INIT: "SEARCH_APIORPROVIDERS_INIT", + SEARCH_APIORPROVIDERS_SUCCESS: "SEARCH_APIORPROVIDERS_SUCCESS", + FETCH_PROVIDERS_INIT: "FETCH_PROVIDERS_INIT", + FETCH_PROVIDERS_SUCCESS: "FETCH_PROVIDERS_SUCCESS", + SUBMIT_CURL_FORM_INIT: "SUBMIT_CURL_FORM_INIT", + SUBMIT_CURL_FORM_SUCCESS: "SUBMIT_CURL_FORM_SUCCESS", + SET_WIDGET_DYNAMIC_PROPERTY: "SET_WIDGET_DYNAMIC_PROPERTY", + FETCH_PROVIDER_TEMPLATES_INIT: "FETCH_PROVIDER_TEMPLATES_INIT", + FETCH_PROVIDER_TEMPLATES_SUCCESS: "FETCH_PROVIDER_TEMPLATES_SUCCESS", + ADD_API_TO_PAGE_INIT: "ADD_API_TO_PAGE_INIT", + ADD_API_TO_PAGE_SUCCESS: "ADD_API_TO_PAGE_SUCCESS", + CLEAR_PREVIOUSLY_EXECUTED_QUERY: "CLEAR_PREVIOUSLY_EXECUTED_QUERY", + FETCH_PROVIDERS_CATEGORIES_INIT: "FETCH_PROVIDERS_CATEGORIES_INIT", + FETCH_PROVIDERS_CATEGORIES_SUCCESS: "FETCH_PROVIDERS_CATEGORIES_SUCCESS", + FETCH_PROVIDERS_WITH_CATEGORY_INIT: "FETCH_PROVIDERS_WITH_CATEGORY_INIT", + FETCH_PROVIDERS_WITH_CATEGORY_SUCCESS: + "FETCH_PROVIDERS_WITH_CATEGORY_SUCCESS", + SHOW_MODAL: "SHOW_MODAL", + SHOW_MODAL_BY_NAME: "SHOW_MODAL_BY_NAME", + CLOSE_MODAL: "CLOSE_MODAL", + CREATE_MODAL_INIT: "CREATE_MODAL_INIT", + CREATE_MODAL_SUCCESS: "CREATE_MODAL_SUCCESS", + UPDATE_CANVAS_SIZE: "UPDATE_CANVAS_SIZE", + SWITCH_CURRENT_PAGE_ID: "SWITCH_CURRENT_PAGE_ID", + CLEAR_PROVIDERS: "CLEAR_PROVIDERS", + BATCHED_UPDATE: "BATCHED_UPDATE", + EXECUTE_BATCH: "EXECUTE_BATCH", + FETCH_ALL_PUBLISHED_PAGES: "FETCH_ALL_PUBLISHED_PAGES", + CREATE_NEW_API_ACTION: "CREATE_NEW_API_ACTION", + CREATE_NEW_QUERY_ACTION: "CREATE_NEW_QUERY_ACTION", + SET_CURRENT_CATEGORY: "SET_CURRENT_CATEGORY", + SET_LAST_USED_EDITOR_PAGE: "SET_LAST_USED_EDITOR_PAGE", + SET_LAST_SELECTED_PAGE_PAGE: "SET_LAST_SELECTED_PAGE_PAGE", + FETCH_PROVIDER_DETAILS_BY_PROVIDER_ID_INIT: + "FETCH_PROVIDER_DETAILS_BY_PROVIDER_ID_INIT", + FETCH_PROVIDER_DETAILS_BY_PROVIDER_ID_SUCCESS: + "FETCH_PROVIDER_DETAILS_BY_PROVIDER_ID_SUCCESS", + SET_PROVIDERS_LENGTH: "SET_PROVIDERS_LENGTH", + GET_ALL_APPLICATION_INIT: "GET_ALL_APPLICATION_INIT", + FETCH_USER_APPLICATIONS_ORGS_SUCCESS: "FETCH_USER_APPLICATIONS_ORGS_SUCCESS", + FETCH_USER_DETAILS_SUCCESS: "FETCH_USER_DETAILS_SUCCESS", + FETCH_ALL_USERS_SUCCESS: "FETCH_ALL_USERS_SUCCESS", + FETCH_ALL_USERS_INIT: "FETCH_ALL_USERS_INIT", + FETCH_ALL_ROLES_SUCCESS: "FETCH_ALL_ROLES_SUCCESS", + FETCH_ALL_ROLES_INIT: "FETCH_ALL_ROLES_INIT", + DELETE_ORG_USER_INIT: "DELETE_ORG_USER_INIT", + DELETE_ORG_USER_SUCCESS: "DELETE_ORG_USER_SUCCESS", + LEAVE_ORG_INIT: "LEAVE_ORG_INIT", + CHANGE_ORG_USER_ROLE_INIT: "CHANGE_ORG_USER_ROLE_INIT", + CHANGE_ORG_USER_ROLE_SUCCESS: "CHANGE_ORG_USER_ROLE_SUCCESS", + UPDATE_USER_DETAILS_INIT: "UPDATE_USER_DETAILS_INIT", + UPDATE_USER_DETAILS_SUCCESS: "UPDATE_USER_DETAILS_SUCCESS", + SET_DEFAULT_REFINEMENT: "SET_DEFAULT_REFINEMENT", + SET_HELP_MODAL_OPEN: "SET_HELP_MODAL_OPEN", + SAVE_ACTION_NAME_INIT: "SAVE_ACTION_NAME_INIT", + SAVE_ACTION_NAME_SUCCESS: "SAVE_ACTION_NAME_SUCCESS", + UPDATE_API_NAME_DRAFT: "UPDATE_API_NAME_DRAFT", + SET_ACTION_PROPERTY: "SET_ACTION_PROPERTY", + UPDATE_ACTION_PROPERTY: "UPDATE_ACTION_PROPERTY", + SWITCH_DATASOURCE: "SWITCH_DATASOURCE", + INIT_EXPLORER_ENTITY_NAME_EDIT: "INIT_EXPLORER_ENTITY_NAME_EDIT", + FETCH_ACTIONS_VIEW_MODE_INIT: "FETCH_ACTIONS_VIEW_MODE_INIT", + FETCH_ACTIONS_VIEW_MODE_SUCCESS: "FETCH_ACTIONS_VIEW_MODE_SUCCESS", + END_EXPLORER_ENTITY_NAME_EDIT: "END_EXPLORER_ENTITY_NAME_EDIT", + POPULATE_PAGEDSLS_INIT: "POPULATE_PAGEDSLS_INIT", + POPULATE_PAGEDSLS_SUCCESS: "POPULATE_PAGEDSLS_SUCCESS", + FETCH_PAGE_DSLS_SUCCESS: "FETCH_PAGE_DSLS_SUCCESS", + FETCH_PAGE_DSL_SUCCESS: "FETCH_PAGE_DSL_SUCCESS", + SET_URL_DATA: "SET_URL_DATA", + SET_APP_MODE: "SET_APP_MODE", + TOGGLE_PROPERTY_PANE_WIDGET_NAME_EDIT: + "TOGGLE_PROPERTY_PANE_WIDGET_NAME_EDIT", + UPDATE_APP_PERSISTENT_STORE: "UPDATE_APP_PERSISTENT_STORE", + UPDATE_APP_TRANSIENT_STORE: "UPDATE_APP_TRANSIENT_STORE", + SET_ACTION_TO_EXECUTE_ON_PAGELOAD: "SET_ACTION_TO_EXECUTE_ON_PAGELOAD", + TOGGLE_ACTION_EXECUTE_ON_LOAD_SUCCESS: + "TOGGLE_ACTION_EXECUTE_ON_LOAD_SUCCESS", + TOGGLE_ACTION_EXECUTE_ON_LOAD_INIT: "TOGGLE_ACTION_EXECUTE_ON_LOAD_INIT", + COPY_SELECTED_WIDGET_SUCCESS: "COPY_SELECTED_WIDGET_SUCCESS", + COPY_SELECTED_WIDGET_INIT: "COPY_SELECTED_WIDGET_INIT", + ADD_CANVAS_WIDGET: "ADD_CANVAS_WIDGET", + PASTE_COPIED_WIDGET_INIT: "PASTE_COPIED_WIDGET_INIT", + PASTE_COPIED_WIDGET_SUCCESS: "PASTE_COPIED_WIDGET_SUCCESS", + UNDO_DELETE_WIDGET: "UNDO_DELETE_WIDGET", + CUT_SELECTED_WIDGET: "CUT_SELECTED_WIDGET", + SET_EVALUATED_TREE: "SET_EVALUATED_TREE", + SET_EVALUATION_INVERSE_DEPENDENCY_MAP: + "SET_EVALUATION_INVERSE_DEPENDENCY_MAP", + BATCH_UPDATES_SUCCESS: "BATCH_UPDATES_SUCCESS", + UPDATE_CANVAS_STRUCTURE: "UPDATE_CANVAS_STRUCTURE", + SET_SELECTED_WIDGET_ANCESTORY: "SET_SELECTED_WIDGET_ANCESTORY", + START_EVALUATION: "START_EVALUATION", + CURRENT_APPLICATION_NAME_UPDATE: "CURRENT_APPLICATION_NAME_UPDATE", + CURRENT_APPLICATION_LAYOUT_UPDATE: "CURRENT_APPLICATION_LAYOUT_UPDATE", + FORK_APPLICATION_INIT: "FORK_APPLICATION_INIT", + FORK_APPLICATION_SUCCESS: "FORK_APPLICATION_SUCCESS", + IMPORT_APPLICATION_INIT: "IMPORT_APPLICATION_INIT", + IMPORT_APPLICATION_SUCCESS: "IMPORT_APPLICATION_SUCCESS", + SET_WIDGET_LOADING: "SET_WIDGET_LOADING", + SET_GLOBAL_SEARCH_QUERY: "SET_GLOBAL_SEARCH_QUERY", + TOGGLE_SHOW_GLOBAL_SEARCH_MODAL: "TOGGLE_SHOW_GLOBAL_SEARCH_MODAL", + FETCH_RELEASES_SUCCESS: "FETCH_RELEASES_SUCCESS", + RESET_UNREAD_RELEASES_COUNT: "RESET_UNREAD_RELEASES_COUNT", + SET_LOADING_ENTITIES: "SET_LOADING_ENTITIES", + RESET_CURRENT_APPLICATION: "RESET_CURRENT_APPLICATION", + SELECT_WIDGETS_IN_AREA: "SELECT_WIDGETS_IN_AREA", + RESET_APPLICATION_WIDGET_STATE_REQUEST: + "RESET_APPLICATION_WIDGET_STATE_REQUEST", + SAAS_GET_OAUTH_ACCESS_TOKEN: "SAAS_GET_OAUTH_ACCESS_TOKEN", + UPDATE_RECENT_ENTITY: "UPDATE_RECENT_ENTITY", + RESTORE_RECENT_ENTITIES_REQUEST: "RESTORE_RECENT_ENTITIES_REQUEST", + RESTORE_RECENT_ENTITIES_SUCCESS: "RESTORE_RECENT_ENTITIES_SUCCESS", + SET_RECENT_ENTITIES: "SET_RECENT_ENTITIES", + RESET_RECENT_ENTITIES: "RESET_RECENT_ENTITIES", + UPDATE_API_ACTION_BODY_CONTENT_TYPE: "UPDATE_API_ACTION_BODY_CONTENT_TYPE", + GENERATE_TEMPLATE_PAGE_INIT: "GENERATE_TEMPLATE_PAGE_INIT", + GENERATE_TEMPLATE_PAGE_SUCCESS: "GENERATE_TEMPLATE_PAGE_SUCCESS", + SHOW_TABLE_FILTER_PANE: "SHOW_TABLE_FILTER_PANE", + HIDE_TABLE_FILTER_PANE: "HIDE_TABLE_FILTER_PANE", + TABLE_PANE_MOVED: "TABLE_PANE_MOVED", + EXECUTE_COMMAND: "EXECUTE_COMMAND", + GET_PLUGIN_FORM_CONFIG_INIT: "GET_PLUGIN_FORM_CONFIG_INIT", + EXECUTE_DATASOURCE_QUERY_INIT: "EXECUTE_DATASOURCE_QUERY_INIT", + EXECUTE_DATASOURCE_QUERY_SUCCESS: "EXECUTE_DATASOURCE_QUERY_SUCCESS", +}; + +export type ReduxActionType = typeof ReduxActionTypes[keyof typeof ReduxActionTypes]; + +export const ReduxActionErrorTypes = { + FETCH_FEATURE_FLAGS_ERROR: "FETCH_FEATURE_FLAGS_ERROR", + FETCH_NOTIFICATIONS_ERROR: "FETCH_NOTIFICATIONS_ERROR", + MARK_ALL_NOTIFICAIONS_AS_READ_ERROR: "MARK_ALL_NOTIFICAIONS_AS_READ_ERROR", + FETCH_UNREAD_NOTIFICATIONS_COUNT_ERROR: + "FETCH_UNREAD_NOTIFICATIONS_COUNT_ERROR", + MARK_NOTIFICATION_AS_READ_ERROR: "MARK_NOTIFICATION_AS_READ_ERROR", + CREATE_COMMENT_THREAD_ERROR: "CREATE_COMMENT_THREAD_ERROR", + ADD_COMMENT_TO_THREAD_ERROR: "ADD_COMMENT_TO_THREAD_ERROR", + FETCH_APPLICATION_COMMENTS_ERROR: "FETCH_APPLICATION_COMMENTS_ERROR", + SET_COMMENT_RESOLUTION_ERROR: "SET_COMMENT_RESOLUTION_ERROR", + PIN_COMMENT_THREAD_ERROR: "PIN_COMMENT_THREAD_ERROR", + DELETE_COMMENT_ERROR: "DELETE_COMMENT_ERROR", + MARK_THREAD_AS_READ_ERROR: "MARK_THREAD_AS_READ_ERROR", + EDIT_COMMENT_ERROR: "EDIT_COMMENT_ERROR", + DELETE_COMMENT_THREAD_ERROR: "DELETE_COMMENT_THREAD_ERROR", + ADD_COMMENT_REACTION_ERROR: "ADD_COMMENT_REACTION_ERROR", + DELETE_COMMENT_REACTION_ERROR: "DELETE_COMMENT_REACTION_ERROR", + INITIALIZE_APPSMITH_ERROR: "INITIALIZE_APPSMITH_ERROR", + API_ERROR: "API_ERROR", + WIDGET_DELETE_ERROR: "WIDGET_DELETE_ERROR", + UPDATE_APPLICATION_ERROR: "UPDATE_APPLICATION_ERROR", + UPDATE_APP_LAYOUT_ERROR: "UPDATE_APP_LAYOUT_ERROR", + WIDGET_MOVE_ERROR: "WIDGET_MOVE_ERROR", + WIDGET_RESIZE_ERROR: "WIDGET_RESIZE_ERROR", + WIDGET_REMOVE_CHILD_ERROR: "WIDGET_REMOVE_CHILD_ERROR", + WIDGET_ADD_CHILD_ERROR: "WIDGET_ADD_CHILD_ERROR", + FETCH_PAGE_ERROR: "FETCH_PAGE_ERROR", + SAVE_PAGE_ERROR: "SAVE_PAGE_ERROR", + FETCH_WIDGET_CARDS_ERROR: "FETCH_WIDGET_CARDS_ERROR", + WIDGET_OPERATION_ERROR: "WIDGET_OPERATION_ERROR", + FETCH_PROPERTY_PANE_CONFIGS_ERROR: "FETCH_PROPERTY_PANE_CONFIGS_ERROR", + FETCH_CONFIGS_ERROR: "FETCH_CONFIGS_ERROR", + PROPERTY_PANE_ERROR: "PROPERTY_PANE_ERROR", + FETCH_ACTIONS_ERROR: "FETCH_ACTIONS_ERROR", + UPDATE_WIDGET_PROPERTY_ERROR: "UPDATE_WIDGET_PROPERTY_ERROR", + CREATE_ACTION_ERROR: "CREATE_ACTION_ERROR", + UPDATE_ACTION_ERROR: "UPDATE_ACTION_ERROR", + DELETE_ACTION_ERROR: "DELETE_ACTION_ERROR", + RUN_ACTION_ERROR: "RUN_ACTION_ERROR", + EXECUTE_ACTION_ERROR: "EXECUTE_ACTION_ERROR", + FETCH_DATASOURCES_ERROR: "FETCH_DATASOURCES_ERROR", + FETCH_MOCK_DATASOURCES_ERROR: "FETCH_MOCK_DATASOURCES_ERROR", + ADD_MOCK_DATASOURCES_ERROR: "ADD_MOCK_DATASOURCES_ERROR", + SEARCH_APIORPROVIDERS_ERROR: "SEARCH_APIORPROVIDERS_ERROR", + UPDATE_DATASOURCE_ERROR: "UPDATE_DATASOURCE_ERROR", + SAVE_DATASOURCE_NAME_ERROR: "SAVE_DATASOURCE_NAME_ERROR", + CREATE_DATASOURCE_ERROR: "CREATE_DATASOURCE_ERROR", + DELETE_DATASOURCE_ERROR: "DELETE_DATASOURCE_ERROR", + FETCH_DATASOURCE_STRUCTURE_ERROR: "FETCH_DATASOURCE_STRUCTURE_ERROR", + REFRESH_DATASOURCE_STRUCTURE_ERROR: "REFRESH_DATASOURCE_STRUCTURE_ERROR", + CREATE_ONBOARDING_DBQUERY_ERROR: "CREATE_ONBOARDING_DBQUERY_ERROR", + FETCH_PUBLISHED_PAGE_ERROR: "FETCH_PUBLISHED_PAGE_ERROR", + PUBLISH_APPLICATION_ERROR: "PUBLISH_APPLICATION_ERROR", + FETCH_USER_DETAILS_ERROR: "FETCH_USER_DETAILS_ERROR", + CREATE_PAGE_ERROR: "CREATE_PAGE_ERROR", + FETCH_PAGE_LIST_ERROR: "FETCH_PAGE_LIST_ERROR", + FETCH_APPLICATION_ERROR: "FETCH_APPLICATION_ERROR", + CREATE_APPLICATION_ERROR: "CREATE_APPLICATION_ERROR", + LOGIN_USER_ERROR: "LOGIN_USER_ERROR", + CREATE_USER_ERROR: "CREATE_USER_ERROR", + RESET_USER_PASSWORD_ERROR: "RESET_USER_PASSWORD_ERROR", + CHANGE_ORG_USER_ROLE_ERROR: "CHANGE_ORG_USER_ROLE_ERROR", + SAVE_JS_EXECUTION_RECORD: "SAVE_JS_EXECUTION_RECORD", + FETCH_PLUGINS_ERROR: "FETCH_PLUGINS_ERROR", + FETCH_PLUGIN_FORM_CONFIGS_ERROR: "FETCH_PLUGIN_FORM_CONFIGS_ERROR", + UPDATE_ORG_NAME_ERROR: "UPDATE_ORG_NAME_ERROR", + SWITCH_ORGANIZATION_ERROR: "SWITCH_ORGANIZATION_ERROR", + TEST_DATASOURCE_ERROR: "TEST_DATASOURCE_ERROR", + FORGOT_PASSWORD_ERROR: "FORGOT_PASSWORD_ERROR", + RESET_PASSWORD_VERIFY_TOKEN_ERROR: "RESET_PASSWORD_VERIFY_TOKEN_ERROR", + FETCH_ORG_ROLES_ERROR: "FETCH_ORG_ROLES_ERROR", + INVITE_USERS_TO_ORG_ERROR: "INVITE_USERS_TO_ORG_ERROR", + SAVE_ORG_ERROR: "SAVE_ORG_ERROR", + FETCH_ORG_ERROR: "FETCH_ORG_ERROR", + FETCH_ORGS_ERROR: "FETCH_ORGS_ERROR", + FETCH_USER_ERROR: "FETCH_USER_ERROR", + SET_CURRENT_USER_ERROR: "SET_CURRENT_USER_ERROR", + LOGOUT_USER_ERROR: "LOGOUT_USER_ERROR", + VERIFY_INVITE_ERROR: "VERIFY_INVITE_ERROR", + UPDATE_PAGE_ERROR: "UPDATE_PAGE_ERROR", + MOVE_ACTION_ERROR: "MOVE_ACTION_ERROR", + COPY_ACTION_ERROR: "COPY_ACTION_ERROR", + DELETE_PAGE_ERROR: "DELETE_PAGE_ERROR", + CLONE_PAGE_ERROR: "CLONE_PAGE_ERROR", + DELETE_APPLICATION_ERROR: "DELETE_APPLICATION_ERROR", + DUPLICATE_APPLICATION_ERROR: "DUPLICATE_APPLICATION_ERROR", + SET_DEFAULT_APPLICATION_PAGE_ERROR: "SET_DEFAULT_APPLICATION_PAGE_ERROR", + CREATE_ORGANIZATION_ERROR: "CREATE_ORGANIZATION_ERROR", + ADD_USER_TO_ORG_ERROR: "ADD_USER_TO_ORG_ERROR", + UPDATE_WIDGET_NAME_ERROR: "UPDATE_WIDGET_NAME_ERROR", + FETCH_ACTIONS_FOR_PAGE_ERROR: "FETCH_ACTIONS_FOR_PAGE_ERROR", + EXECUTE_API_ACTION_ERROR: "EXECUTE_API_ACTION_ERROR", + FETCH_IMPORTED_COLLECTIONS_ERROR: "FETCH_IMPORTED_COLLECTIONS_ERROR", + FETCH_PROVIDERS_ERROR: "FETCH_PROVIDERS_ERROR", + SUBMIT_CURL_FORM_ERROR: "SUBMIT_CURL_FORM_ERROR", + FETCH_PROVIDER_TEMPLATES_ERROR: "FETCH_PROVIDER_TEMPLATES_ERROR", + ADD_API_TO_PAGE_ERROR: "ADD_API_TO_PAGE_ERROR", + FETCH_PROVIDERS_CATEGORIES_ERROR: "FETCH_PROVIDERS_CATEGORIES_ERROR", + FETCH_PROVIDERS_WITH_CATEGORY_ERROR: "FETCH_PROVIDERS_WITH_CATEGORY_ERROR", + CREATE_MODAL_ERROR: "CREATE_MODAL_ERROR", + FETCH_PROVIDER_DETAILS_BY_PROVIDER_ID_ERROR: + "FETCH_PROVIDER_DETAILS_BY_PROVIDER_ID_ERROR", + SAVE_ACTION_NAME_ERROR: "SAVE_ACTION_NAME_ERROR", + FETCH_USER_APPLICATIONS_ORGS_ERROR: "FETCH_USER_APPLICATIONS_ORGS_ERROR", + FORK_APPLICATION_ERROR: "FORK_APPLICATION_ERROR", + IMPORT_APPLICATION_ERROR: "IMPORT_APPLICATION_ERROR", + FETCH_ALL_USERS_ERROR: "FETCH_ALL_USERS_ERROR", + FETCH_ALL_ROLES_ERROR: "FETCH_ALL_ROLES_ERROR", + UPDATE_USER_DETAILS_ERROR: "UPDATE_USER_DETAILS_ERROR", + FETCH_ACTIONS_VIEW_MODE_ERROR: "FETCH_ACTION_VIEW_MODE_ERROR", + SAVE_API_NAME_ERROR: "SAVE_API_NAME_ERROR", + POPULATE_PAGEDSLS_ERROR: "POPULATE_PAGEDSLS_ERROR", + FETCH_PAGE_DSL_ERROR: "FETCH_PAGE_DSL_ERROR", + TOGGLE_ACTION_EXECUTE_ON_LOAD_ERROR: "TOGGLE_ACTION_EXECUTE_ON_LOAD_ERROR", + COPY_SELECTED_WIDGET_ERROR: "COPY_SELECTED_WIDGET_ERROR", + PASTE_COPIED_WIDGET_ERROR: "PASTE_COPIED_WIDGET_ERROR", + WIDGET_ADD_CHILDREN_ERROR: "WIDGET_ADD_CHILDREN_ERROR", + FAILED_CORRECTING_BINDING_PATHS: "FAILED_CORRECTING_BINDING_PATHS", + DELETE_ORG_USER_ERROR: "DELETE_ORG_USER_ERROR", + CHANGE_APPVIEW_ACCESS_ERROR: "CHANGE_APPVIEW_ACCESS_ERROR", + GENERATE_TEMPLATE_PAGE_ERROR: "GENERATE_TEMPLATE_PAGE_ERROR", + FETCH_PLUGIN_FORM_ERROR: "FETCH_PLUGIN_FORM_ERROR", + EXECUTE_DATASOURCE_QUERY_ERROR: "EXECUTE_DATASOURCE_QUERY_ERROR", + INVITED_USER_SIGNUP_ERROR: "INVITED_USER_SIGNUP_ERROR", +}; + +export const WidgetReduxActionTypes: { [key: string]: string } = { + WIDGET_ADD_CHILD: "WIDGET_ADD_CHILD", + WIDGET_CHILD_ADDED: "WIDGET_CHILD_ADDED", + WIDGET_REMOVE_CHILD: "WIDGET_REMOVE_CHILD", + WIDGET_MOVE: "WIDGET_MOVE", + WIDGET_RESIZE: "WIDGET_RESIZE", + WIDGET_DELETE: "WIDGET_DELETE", + WIDGET_BULK_DELETE: "WIDGET_BULK_DELETE", + WIDGET_SINGLE_DELETE: "WIDGET_SINGLE_DELETE", + WIDGET_ADD_CHILDREN: "WIDGET_ADD_CHILDREN", + WIDGET_UPDATE_PROPERTY: "WIDGET_UPDATE_PROPERTY", +}; + +export type ReduxActionErrorType = typeof ReduxActionErrorTypes[keyof typeof ReduxActionErrorTypes]; + +export interface ReduxAction { + type: ReduxActionType | ReduxActionErrorType; + payload: T; +} + +export type ReduxActionWithoutPayload = Pick, "type">; + +export interface ReduxActionWithMeta extends ReduxAction { + meta: M; +} + +export interface ReduxActionWithCallbacks extends ReduxAction { + onSuccess?: ReduxAction; + onError?: ReduxAction; + onSuccessCallback?: (response: S) => void; + onErrorCallback?: (error: E) => void; +} + +export interface EvaluationReduxAction extends ReduxAction { + postEvalActions?: Array | ReduxActionWithoutPayload>; +} + +export interface PromisePayload { + reject: any; + resolve: any; +} +export interface ReduxActionWithPromise extends ReduxAction { + payload: T & PromisePayload; +} + +export interface ReduxActionErrorPayload { + message: string; + source?: string; + code?: ERROR_CODES; +} + +export interface UpdateCanvasPayload { + pageWidgetId: string; + widgets: { [widgetId: string]: WidgetProps }; + currentLayoutId: string; + currentPageId: string; + currentPageName: string; + currentApplicationId: string; + pageActions: PageAction[][]; +} + +export interface ShowPropertyPanePayload { + widgetId: string; + callForDragOrResize: boolean; + force: boolean; +} + +export interface Page { + pageName: string; + pageId: string; + isDefault: boolean; + latest?: boolean; + isHidden?: boolean; + icon?: string; +} + +export interface ClonePageSuccessPayload { + pageName: string; + pageId: string; + layoutId: string; + isDefault: boolean; +} + +export type PageListPayload = Array; + +export type ApplicationPayload = { + id: string; + name: string; + color?: string; + icon?: string; + organizationId: string; + defaultPageId?: string; + isPublic?: boolean; + userPermissions?: string[]; + appIsExample: boolean; + forkingEnabled?: boolean; + appLayout?: AppLayoutConfig; +}; + +export type OrganizationDetails = { + organization: Org; + applications: any[]; +}; + +export interface LoadWidgetEditorPayload { + widgets: WidgetProps[]; +} + +export interface LoadWidgetSidebarPayload { + cards: { [id: string]: WidgetCardProps[] }; +} + +export type InitializeEditorPayload = { + applicationId: string; + pageId: string; + queryParams: URLSearchParams; +}; diff --git a/app/taro/src/constants/SocialLogin.tsx b/app/taro/src/constants/SocialLogin.tsx new file mode 100644 index 0000000000..ad8f0c55d3 --- /dev/null +++ b/app/taro/src/constants/SocialLogin.tsx @@ -0,0 +1,44 @@ +import { GoogleOAuthURL, GithubOAuthURL } from "constants/ApiConstants"; + +const GithubLogo = ""; +const GoogleLogo = ""; + +export type SocialLoginButtonProps = { + url: string; + name: string; + logo: string; +}; + +export const GoogleSocialLoginButtonProps: SocialLoginButtonProps = { + url: GoogleOAuthURL, + name: "Google", + logo: GoogleLogo, +}; + +export const GithubSocialLoginButtonProps: SocialLoginButtonProps = { + url: GithubOAuthURL, + name: "Github", + logo: GithubLogo, +}; + +export const SocialLoginButtonPropsList: Record< + string, + SocialLoginButtonProps +> = { + google: GoogleSocialLoginButtonProps, + github: GithubSocialLoginButtonProps, +}; + +export type SocialLoginType = keyof typeof SocialLoginButtonPropsList; + +export const getSocialLoginButtonProps = ( + logins: SocialLoginType[], +): SocialLoginButtonProps[] => { + return logins.map((login) => { + const socialLoginButtonProps = SocialLoginButtonPropsList[login]; + if (!socialLoginButtonProps) { + throw Error("Social login not registered: " + login); + } + return socialLoginButtonProps; + }); +}; diff --git a/app/taro/src/constants/StyleConstants.tsx b/app/taro/src/constants/StyleConstants.tsx new file mode 100644 index 0000000000..ff8b4c5632 --- /dev/null +++ b/app/taro/src/constants/StyleConstants.tsx @@ -0,0 +1 @@ +export default {}; diff --git a/app/taro/src/constants/ThirdPartyConstants.tsx b/app/taro/src/constants/ThirdPartyConstants.tsx new file mode 100644 index 0000000000..c9f8112d05 --- /dev/null +++ b/app/taro/src/constants/ThirdPartyConstants.tsx @@ -0,0 +1,3 @@ +export type ENVIRONMENT = "PRODUCTION" | "STAGING" | "LOCAL"; +export const S3_BUCKET_URL = + "https://s3.us-east-2.amazonaws.com/assets.appsmith.com"; diff --git a/app/taro/src/constants/TourSteps.tsx b/app/taro/src/constants/TourSteps.tsx new file mode 100644 index 0000000000..1fe3c71390 --- /dev/null +++ b/app/taro/src/constants/TourSteps.tsx @@ -0,0 +1,12 @@ +import { TourType } from "entities/Tour"; +import { + commentsTourStepsEditMode, + commentsTourStepsPublishedMode, +} from "comments/tour/commentsTourSteps"; + +const TourStepsByType = { + [TourType.COMMENTS_TOUR_EDIT_MODE]: commentsTourStepsEditMode, + [TourType.COMMENTS_TOUR_PUBLISHED_MODE]: commentsTourStepsPublishedMode, +}; + +export default TourStepsByType; diff --git a/app/taro/src/constants/WebsocketConstants.tsx b/app/taro/src/constants/WebsocketConstants.tsx new file mode 100644 index 0000000000..ca1112a931 --- /dev/null +++ b/app/taro/src/constants/WebsocketConstants.tsx @@ -0,0 +1,17 @@ +export const WEBSOCKET_EVENTS = { + RECONNECT: "RECONNECT", + DISCONNECTED: "DISCONNECTED", + CONNECTED: "CONNECTED", +}; + +export const reconnectWebsocketEvent = () => ({ + type: WEBSOCKET_EVENTS.RECONNECT, +}); + +export const websocketDisconnectedEvent = () => ({ + type: WEBSOCKET_EVENTS.DISCONNECTED, +}); + +export const websocketConnectedEvent = () => ({ + type: WEBSOCKET_EVENTS.CONNECTED, +}); diff --git a/app/taro/src/constants/WidgetConstants.tsx b/app/taro/src/constants/WidgetConstants.tsx new file mode 100644 index 0000000000..06da8f3790 --- /dev/null +++ b/app/taro/src/constants/WidgetConstants.tsx @@ -0,0 +1,163 @@ +import { SupportedLayouts } from "reducers/entityReducers/pageListReducer"; + +export enum WidgetTypes { + CONTAINER_WIDGET = "CONTAINER_WIDGET", + CANVAS_WIDGET = "CANVAS_WIDGET", + SKELETON_WIDGET = "SKELETON_WIDGET", + TARO_PICKER_WIDGET = "TARO_PICKER_WIDGET", + TARO_SWIPER_WIDGET = "TARO_SWIPER_WIDGET", + TARO_GRID_WIDGET = "TARO_GRID_WIDGET", + TARO_TEXT_WIDGET = "TARO_TEXT_WIDGET", + TARO_LIST_WIDGET = "TARO_LIST_WIDGET", + TARO_POPUP_WIDGET = "TARO_POPUP_WIDGET", + TARO_IMAGE_WIDGET = "TARO_IMAGE_WIDGET", + TARO_BUTTON_WIDGET = "TARO_BUTTON_WIDGET", + TARO_CELL_WIDGET = "TARO_CELL_WIDGET", + TARO_HTML_WIDGET = "TARO_HTML_WIDGET", + TARO_SKU_WIDGET = "TARO_SKU_WIDGET", + TARO_KV_WIDGET = "TARO_KV_WIDGET", + TARO_TABS_WIDGET = "TARO_TABS_WIDGET", + TARO_BOTTOM_BAR_WIDGET = "TARO_BOTTOM_BAR_WIDGET", + TARO_ACTION_BAR_WIDGET = "TARO_ACTION_BAR_WIDGET", + TARO_SEARCH_WIDGET = "TARO_SEARCH_WIDGET", + TARO_LOADING_WIDGET = "TARO_LOADING_WIDGET", + TARO_CHECKBOX_WIDGET = "TARO_CHECKBOX_WIDGET", + TARO_FORM_WIDGET = "TARO_FORM_WIDGET", +} + +export type WidgetType = keyof typeof WidgetTypes; + +export type ContainerOrientation = "HORIZONTAL" | "VERTICAL"; + +export const PositionTypes: { [id: string]: string } = { + ABSOLUTE: "ABSOLUTE", + CONTAINER_DIRECTION: "CONTAINER_DIRECTION", +}; +export type PositionType = typeof PositionTypes[keyof typeof PositionTypes]; + +export type CSSUnit = + | "px" + | "cm" + | "mm" + | "in" + | "pt" + | "pc" + | "em" + | "ex" + | "ch" + | "rem" + | "vw" + | "vh" + | "vmin" + | "vmax" + | "%"; + +export type RenderMode = + | "COMPONENT_PANE" + | "CANVAS" + | "PAGE" + | "CANVAS_SELECTED"; + +export const RenderModes: { [id: string]: RenderMode } = { + COMPONENT_PANE: "COMPONENT_PANE", + CANVAS: "CANVAS", + PAGE: "PAGE", + CANVAS_SELECTED: "CANVAS_SELECTED", +}; + +export const CSSUnits: { [id: string]: CSSUnit } = { + PIXEL: "px", + RELATIVE_FONTSIZE: "rem", + RELATIVE_PARENT: "%", +}; + +interface LayoutConfig { + minWidth: number; + maxWidth: number; +} + +type LayoutConfigurations = Record; +export const DefaultLayoutType: SupportedLayouts = "DESKTOP"; +export const layoutConfigurations: LayoutConfigurations = { + TABLET_LARGE: { + minWidth: 960, + maxWidth: 1080, + }, + MOBILE: { + minWidth: 350, + maxWidth: 450, + }, + DESKTOP: { minWidth: 1160, maxWidth: 1280 }, + TABLET: { minWidth: 650, maxWidth: 800 }, + FLUID: { minWidth: -1, maxWidth: -1 }, + MOBILE_FLUID: { minWidth: -1, maxWidth: -1 }, +}; + +export const LATEST_PAGE_VERSION = 30; + +export const GridDefaults = { + DEFAULT_CELL_SIZE: 1, + DEFAULT_WIDGET_WIDTH: 200, + DEFAULT_WIDGET_HEIGHT: 100, + DEFAULT_GRID_COLUMNS: 64, + DEFAULT_GRID_ROW_HEIGHT: 10, + CANVAS_EXTENSION_OFFSET: 2, +}; + +// Note: Widget Padding + Container Padding === DEFAULT_GRID_ROW_HEIGHT to gracefully lose one row when a container is used, +// which wud allow the user to place elements centered inside a container(columns are rendered proportionaly so it take cares of itselves). + +export const CONTAINER_GRID_PADDING = + GridDefaults.DEFAULT_GRID_ROW_HEIGHT * 0.6; + +export const WIDGET_PADDING = GridDefaults.DEFAULT_GRID_ROW_HEIGHT * 0.4; + +export const WIDGET_CLASSNAME_PREFIX = "WIDGET_"; +export const MAIN_CONTAINER_WIDGET_ID = "0"; +export const MAIN_CONTAINER_WIDGET_NAME = "MainContainer"; +export const MODAL_PORTAL_CLASSNAME = "bp3-modal-widget"; +export const CANVAS_CLASSNAME = "appsmith_widget_0"; + +export const WIDGET_DELETE_UNDO_TIMEOUT = 7000; + +export const DEFAULT_CENTER = { lat: -34.397, lng: 150.644 }; + +export enum FontStyleTypes { + BOLD = "BOLD", + ITALIC = "ITALIC", + REGULAR = "REGULAR", + UNDERLINE = "UNDERLINE", + LINETHROUGH = "LINETHROUGH", +} + +export enum TextSizes { + HEADING1 = "HEADING1", + HEADING2 = "HEADING2", + HEADING3 = "HEADING3", + PARAGRAPH = "PARAGRAPH", + PARAGRAPH2 = "PARAGRAPH2", +} + +export const TEXT_SIZES = { + HEADING1: "24px", + HEADING2: "18px", + HEADING3: "16px", + PARAGRAPH: "14px", + PARAGRAPH2: "12px", +}; + +export type TextSize = keyof typeof TextSizes; + +export enum RateSizes { + SMALL = "SMALL", + MEDIUM = "MEDIUM", + LARGE = "LARGE", +} + +export const RATE_SIZES = { + SMALL: 12, + MEDIUM: 16, + LARGE: 21, +}; + +export type RateSize = keyof typeof RateSizes; diff --git a/app/taro/src/constants/WidgetValidation.ts b/app/taro/src/constants/WidgetValidation.ts new file mode 100644 index 0000000000..18cf347f03 --- /dev/null +++ b/app/taro/src/constants/WidgetValidation.ts @@ -0,0 +1,88 @@ +import { EXECUTION_PARAM_KEY } from "constants/AppsmithActionConstants/ActionConstants"; +import { ValidationConfig } from "./PropertyControlConstants"; + +// Always add a validator function in ./worker/validation for these types +export enum ValidationTypes { + TEXT = "TEXT", + REGEX = "REGEX", + NUMBER = "NUMBER", + BOOLEAN = "BOOLEAN", + OBJECT = "OBJECT", + ARRAY = "ARRAY", + OBJECT_ARRAY = "OBJECT_ARRAY", + DATE_ISO_STRING = "DATE_ISO_STRING", + IMAGE_URL = "IMAGE_URL", + FUNCTION = "FUNCTION", + SAFE_URL = "SAFE_URL", +} + +export type ValidationResponse = { + isValid: boolean; + parsed: any; + message?: string; + transformed?: any; +}; + +export type Validator = ( + config: ValidationConfig, + value: unknown, + props: Record, +) => ValidationResponse; + +export const ISO_DATE_FORMAT = "YYYY-MM-DDTHH:mm:ss.sssZ"; + +export const JAVASCRIPT_KEYWORDS = { + true: "true", + await: "await", + break: "break", + case: "case", + catch: "catch", + class: "class", + const: "const", + continue: "continue", + debugger: "debugger", + default: "default", + delete: "delete", + do: "do", + else: "else", + enum: "enum", + export: "export", + extends: "extends", + false: "false", + finally: "finally", + for: "for", + function: "function", + if: "if", + implements: "implements", + import: "import", + in: "in", + instanceof: "instanceof", + interface: "interface", + let: "let", + new: "new", + null: "null", + package: "package", + private: "private", + protected: "protected", + public: "public", + return: "return", + static: "static", + super: "super", + switch: "switch", + this: "this", + throw: "throw", + try: "try", + typeof: "typeof", + var: "var", + void: "void", + while: "while", + with: "with", + yield: "yield", +}; + +export const DATA_TREE_KEYWORDS = { + actionPaths: "actionPaths", + global: "global", + pageList: "pageList", + [EXECUTION_PARAM_KEY]: EXECUTION_PARAM_KEY, +}; diff --git a/app/taro/src/constants/collectionsConstants.ts b/app/taro/src/constants/collectionsConstants.ts new file mode 100644 index 0000000000..a1a0e6e66a --- /dev/null +++ b/app/taro/src/constants/collectionsConstants.ts @@ -0,0 +1,21 @@ +import { ApiResponse } from "api/ApiResponses"; + +export type TemplateList = { + id: string; + delete: boolean; + name: string; + providerId: string; + publisher: string; + packageName: string; + versionId: string; +}; + +export type CollectionDataArray = { + id: string; + deleted: boolean; + apiTemplateList: Array; +}; + +export type ImportedCollections = ApiResponse & { + data: Array; +}; diff --git a/app/taro/src/constants/defs/base64-js.json b/app/taro/src/constants/defs/base64-js.json new file mode 100644 index 0000000000..848abbf2bd --- /dev/null +++ b/app/taro/src/constants/defs/base64-js.json @@ -0,0 +1,11 @@ +{ + "!name": "base64-js", + "btoa": { + "!doc": "creates a base-64 encoded ASCII string from a \"string\" of binary data", + "!type": "fn(aString: string) -> string" + }, + "atob": { + "!doc": "decodes a base64 encoded string", + "!type": "fn(bString: string) -> string" + } +} diff --git a/app/taro/src/constants/defs/ecmascript.json b/app/taro/src/constants/defs/ecmascript.json new file mode 100644 index 0000000000..4885178a32 --- /dev/null +++ b/app/taro/src/constants/defs/ecmascript.json @@ -0,0 +1,1360 @@ +{ + "!name": "ecmascript", + "!define": { + "Error.prototype": "Error.prototype", + "propertyDescriptor": { + "enumerable": "bool", + "configurable": "bool", + "value": "?", + "writable": "bool", + "get": "fn() -> ?", + "set": "fn(value: ?)" + } + }, + "Infinity": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Infinity", + "!doc": "A numeric value representing infinity." + }, + "undefined": { + "!type": "?", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/undefined", + "!doc": "The value undefined." + }, + "NaN": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/NaN", + "!doc": "A value representing Not-A-Number." + }, + "Object": { + "!type": "fn()", + "create": { + "!type": "fn(proto: ?) -> !custom:Object_create", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/create", + "!doc": "Creates a new object with the specified prototype object and properties." + }, + "keys": { + "!type": "fn(obj: ?) -> [string]", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/keys", + "!doc": "Returns an array of a given object's own enumerable properties, in the same order as that provided by a for-in loop (the difference being that a for-in loop enumerates properties in the prototype chain as well)." + }, + "seal": { + "!type": "fn(obj: ?)", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/seal", + "!doc": "Seals an object, preventing new properties from being added to it and marking all existing properties as non-configurable. Values of present properties can still be changed as long as they are writable." + }, + "isSealed": { + "!type": "fn(obj: ?) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/isSealed", + "!doc": "Determine if an object is sealed." + }, + "freeze": { + "!type": "fn(obj: ?) -> !0", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/freeze", + "!doc": "Freezes an object: that is, prevents new properties from being added to it; prevents existing properties from being removed; and prevents existing properties, or their enumerability, configurability, or writability, from being changed. In essence the object is made effectively immutable. The method returns the object being frozen." + }, + "isFrozen": { + "!type": "fn(obj: ?) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/isFrozen", + "!doc": "Determine if an object is frozen." + }, + "preventExtensions": { + "!type": "fn(obj: ?)", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/preventExtensions", + "!doc": "Prevents new properties from ever being added to an object." + }, + "isExtensible": { + "!type": "fn(obj: ?) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/isExtensible", + "!doc": "The Object.isExtensible() method determines if an object is extensible (whether it can have new properties added to it)." + }, + "assign": { + "!type": "fn(target: ?, source: ?, source?: ?) -> !0", + "!effects": ["copy !1 !0", "copy !2 !0", "copy !3 !0"], + "!doc": "The Object.assign() method is used to copy the values of all enumerable own properties from one or more source objects to a target object. It will return the target object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign" + }, + "is": { + "!type": "fn(value1: ?, value2: ?) -> bool", + "!doc": "The Object.is() method determines whether two values are the same value.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is" + }, + "prototype": { + "!stdProto": "Object", + "toString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/toString", + "!doc": "Returns a string representing the object." + }, + "toLocaleString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/toLocaleString", + "!doc": "Returns a string representing the object. This method is meant to be overriden by derived objects for locale-specific purposes." + }, + "valueOf": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/valueOf", + "!doc": "Returns the primitive value of the specified object" + }, + "hasOwnProperty": { + "!type": "fn(prop: string) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/hasOwnProperty", + "!doc": "Returns a boolean indicating whether the object has the specified property." + }, + "propertyIsEnumerable": { + "!type": "fn(prop: string) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/propertyIsEnumerable", + "!doc": "Returns a Boolean indicating whether the specified property is enumerable." + }, + "isPrototypeOf": { + "!type": "fn(obj: ?) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/isPrototypeOf", + "!doc": "Tests for an object in another object's prototype chain." + } + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object", + "!doc": "Creates an object wrapper." + }, + "Function": { + "!type": "fn(body: string) -> fn()", + "prototype": { + "!stdProto": "Function", + "apply": { + "!type": "fn(this: ?, args: [?])", + "!effects": [ + "call and return !this this=!0 !1. !1. !1." + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function/apply", + "!doc": "Calls a function with a given this value and arguments provided as an array (or an array like object)." + }, + "call": { + "!type": "fn(this: ?, args?: ?) -> !this.!ret", + "!effects": [ + "call and return !this this=!0 !1 !2 !3 !4" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function/call", + "!doc": "Calls a function with a given this value and arguments provided individually." + }, + "bind": { + "!type": "fn(this: ?, args?: ?) -> !custom:Function_bind", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function/bind", + "!doc": "Creates a new function that, when called, has its this keyword set to the provided value, with a given sequence of arguments preceding any provided when the new function was called." + }, + "prototype": "?" + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function", + "!doc": "Every function in JavaScript is actually a Function object." + }, + "Array": { + "!type": "fn(size: number) -> !custom:Array_ctor", + "isArray": { + "!type": "fn(value: ?) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/isArray", + "!doc": "Returns true if an object is an array, false if it is not." + }, + "from": { + "!type": "fn(arrayLike: ?, mapFn?: fn(elt: ?, i: number) -> ?, thisArg?: ?) -> [!0.]", + "!effects": [ + "call !1 this=!2 !0. number" + ], + "!doc": "The Array.from() method creates a new Array instance from an array-like or iterable object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/from" + }, + "of": { + "!type": "fn(elementN: ?) -> [!0]", + "!doc": "The Array.of() method creates a new Array instance with a variable number of arguments, regardless of number or type of the arguments.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/of" + }, + "prototype": { + "!stdProto": "Array", + "length": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/length", + "!doc": "An unsigned, 32-bit integer that specifies the number of elements in an array." + }, + "concat": { + "!type": "fn(other: [?]) -> !this", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/concat", + "!doc": "Returns a new array comprised of this array joined with other array(s) and/or value(s)." + }, + "join": { + "!type": "fn(separator?: string) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/join", + "!doc": "Joins all elements of an array into a string." + }, + "splice": { + "!type": "fn(pos: number, amount: number, newelt?: ?) -> [?]", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/splice", + "!doc": "Changes the content of an array, adding new elements while removing old elements." + }, + "pop": { + "!type": "fn() -> !this.", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/pop", + "!doc": "Removes the last element from an array and returns that element." + }, + "push": { + "!type": "fn(newelt: ?) -> number", + "!effects": [ + "propagate !0 !this." + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/push", + "!doc": "Mutates an array by appending the given elements and returning the new length of the array." + }, + "shift": { + "!type": "fn() -> !this.", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/shift", + "!doc": "Removes the first element from an array and returns that element. This method changes the length of the array." + }, + "unshift": { + "!type": "fn(newelt: ?) -> number", + "!effects": [ + "propagate !0 !this." + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/unshift", + "!doc": "Adds one or more elements to the beginning of an array and returns the new length of the array." + }, + "slice": { + "!type": "fn(from?: number, to?: number) -> !this", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/slice", + "!doc": "Returns a shallow copy of a portion of an array." + }, + "reverse": { + "!type": "fn()", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/reverse", + "!doc": "Reverses an array in place. The first array element becomes the last and the last becomes the first." + }, + "sort": { + "!type": "fn(compare?: fn(a: ?, b: ?) -> number)", + "!effects": [ + "call !0 !this. !this." + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/sort", + "!doc": "Sorts the elements of an array in place and returns the array." + }, + "indexOf": { + "!type": "fn(elt: ?, from?: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/indexOf", + "!doc": "Returns the first index at which a given element can be found in the array, or -1 if it is not present." + }, + "lastIndexOf": { + "!type": "fn(elt: ?, from?: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/lastIndexOf", + "!doc": "Returns the last index at which a given element can be found in the array, or -1 if it is not present. The array is searched backwards, starting at fromIndex." + }, + "every": { + "!type": "fn(test: fn(elt: ?, i: number, array: +Array) -> bool, context?: ?) -> bool", + "!effects": [ + "call !0 this=!1 !this. number !this" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/every", + "!doc": "Tests whether all elements in the array pass the test implemented by the provided function." + }, + "some": { + "!type": "fn(test: fn(elt: ?, i: number, array: +Array) -> bool, context?: ?) -> bool", + "!effects": [ + "call !0 this=!1 !this. number !this" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/some", + "!doc": "Tests whether some element in the array passes the test implemented by the provided function." + }, + "filter": { + "!type": "fn(test: fn(elt: ?, i: number, array: +Array) -> bool, context?: ?) -> !this", + "!effects": [ + "call !0 this=!1 !this. number !this" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/filter", + "!doc": "Creates a new array with all elements that pass the test implemented by the provided function." + }, + "forEach": { + "!type": "fn(f: fn(elt: ?, i: number, array: +Array), context?: ?)", + "!effects": [ + "call !0 this=!1 !this. number !this" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/forEach", + "!doc": "Executes a provided function once per array element." + }, + "map": { + "!type": "fn(f: fn(elt: ?, i: number, array: +Array) -> ?, context?: ?) -> [!0.!ret]", + "!effects": [ + "call !0 this=!1 !this. number !this" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/map", + "!doc": "Creates a new array with the results of calling a provided function on every element in this array." + }, + "reduce": { + "!type": "fn(combine: fn(sum: ?, elt: ?, i: number, array: +Array) -> ?, init?: ?) -> !0.!ret", + "!effects": [ + "call !0 !1 !this. number !this" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/Reduce", + "!doc": "Apply a function against an accumulator and each value of the array (from left-to-right) as to reduce it to a single value." + }, + "reduceRight": { + "!type": "fn(combine: fn(sum: ?, elt: ?, i: number, array: +Array) -> ?, init?: ?) -> !0.!ret", + "!effects": [ + "call !0 !1 !this. number !this" + ], + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/ReduceRight", + "!doc": "Apply a function simultaneously against two values of the array (from right-to-left) as to reduce it to a single value." + }, + "copyWithin": { + "!type": "fn(target: number, start: number, end?: number) -> !this", + "!doc": "The copyWithin() method copies the sequence of array elements within the array to the position starting at target. The copy is taken from the index positions of the second and third arguments start and end.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/copyWithin" + }, + "entries": { + "!type": "fn() -> +iter[:t=[number, !this.]]", + "!doc": "The entries() method returns a new Array Iterator object that contains the key/value pairs for each index in the array.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/entries" + }, + "fill": { + "!type": "fn(value: ?, start?: number, end?: number) -> !this", + "!doc": "The fill() method fills all the elements of an array from a start index to an end index with a static value.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/fill" + }, + "find": { + "!type": "fn(callback: fn(element: ?, index: number, array: [?]) -> bool, thisArg?: ?) -> !this.", + "!effects": ["call !0 this=!2 !this. number"], + "!doc": "The find() method returns a value in the array, if an element in the array satisfies the provided testing function. Otherwise undefined is returned.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/find" + }, + "findIndex": { + "!type": "fn(callback: fn(element: ?, index: number, array: [?]), thisArg?: ?) -> number", + "!effects": ["call !0 this=!2 !this. number"], + "!doc": "The findIndex() method returns an index in the array, if an element in the array satisfies the provided testing function. Otherwise -1 is returned.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/findIndex" + }, + "keys": { + "!type": "fn() -> +iter[:t=number]", + "!doc": "The keys() method returns a new Array Iterator that contains the keys for each index in the array.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/keys" + }, + "values": { + "!type": "fn() -> +iter[:t=!this.]", + "!doc": "The values() method returns a new Array Iterator object that contains the values for each index in the array.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/values" + }, + ":Symbol.iterator": { + "!type": "fn() -> +iter[:t=!this.]", + "!doc": "Returns a new Array Iterator object that contains the values for each index in the array.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/@@iterator" + }, + "includes": { + "!type": "fn(value: ?) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/includes", + "!doc": "Determines whether an array includes a certain element, returning true or false as appropriate." + } + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array", + "!doc": "The JavaScript Array global object is a constructor for arrays, which are high-level, list-like objects." + }, + "String": { + "!type": "fn(value: ?) -> string", + "fromCharCode": { + "!type": "fn(code: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/fromCharCode", + "!doc": "Returns a string created by using the specified sequence of Unicode values." + }, + "fromCodePoint": { + "!type": "fn(point: number, point?: number) -> string", + "!doc": "The static String.fromCodePoint() method returns a string created by using the specified sequence of code points.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/fromCodePoint" + }, + "raw": { + "!type": "fn(template: [string], substitutions: ?, templateString: ?) -> string", + "!doc": "The static String.raw() method is a tag function of template strings, used to get the raw string form of template strings.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/raw" + }, + "prototype": { + "!stdProto": "String", + "length": { + "!type": "number", + "!url": "https://developer.mozilla.org/en/docs/JavaScript/Reference/Global_Objects/String/length", + "!doc": "Represents the length of a string." + }, + "": "string", + "charAt": { + "!type": "fn(i: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/charAt", + "!doc": "Returns the specified character from a string." + }, + "charCodeAt": { + "!type": "fn(i: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/charCodeAt", + "!doc": "Returns the numeric Unicode value of the character at the given index (except for unicode codepoints > 0x10000)." + }, + "indexOf": { + "!type": "fn(char: string, from?: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/indexOf", + "!doc": "Returns the index within the calling String object of the first occurrence of the specified value, starting the search at fromIndex,\nreturns -1 if the value is not found." + }, + "lastIndexOf": { + "!type": "fn(char: string, from?: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/lastIndexOf", + "!doc": "Returns the index within the calling String object of the last occurrence of the specified value, or -1 if not found. The calling string is searched backward, starting at fromIndex." + }, + "substring": { + "!type": "fn(from: number, to?: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/substring", + "!doc": "Returns a subset of a string between one index and another, or through the end of the string." + }, + "substr": { + "!type": "fn(from: number, length?: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/substr", + "!doc": "Returns the characters in a string beginning at the specified location through the specified number of characters." + }, + "slice": { + "!type": "fn(from: number, to?: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/slice", + "!doc": "Extracts a section of a string and returns a new string." + }, + "trim": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/Trim", + "!doc": "Removes whitespace from both ends of the string." + }, + "toUpperCase": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toUpperCase", + "!doc": "Returns the calling string value converted to uppercase." + }, + "toLowerCase": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toLowerCase", + "!doc": "Returns the calling string value converted to lowercase." + }, + "toLocaleUpperCase": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toLocaleUpperCase", + "!doc": "Returns the calling string value converted to upper case, according to any locale-specific case mappings." + }, + "toLocaleLowerCase": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toLocaleLowerCase", + "!doc": "Returns the calling string value converted to lower case, according to any locale-specific case mappings." + }, + "split": { + "!type": "fn(pattern?: string|+RegExp, limit?: number) -> [string]", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/split", + "!doc": "Splits a String object into an array of strings by separating the string into substrings." + }, + "concat": { + "!type": "fn(other: string) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/concat", + "!doc": "Combines the text of two or more strings and returns a new string." + }, + "localeCompare": { + "!type": "fn(other: string) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/localeCompare", + "!doc": "Returns a number indicating whether a reference string comes before or after or is the same as the given string in sort order." + }, + "match": { + "!type": "fn(pattern: +RegExp) -> [string]", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/match", + "!doc": "Used to retrieve the matches when matching a string against a regular expression." + }, + "replace": { + "!type": "fn(pattern: string|+RegExp, replacement: string) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/replace", + "!doc": "Returns a new string with some or all matches of a pattern replaced by a replacement. The pattern can be a string or a RegExp, and the replacement can be a string or a function to be called for each match." + }, + "search": { + "!type": "fn(pattern: +RegExp) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/search", + "!doc": "Executes the search for a match between a regular expression and this String object." + }, + "codePointAt": { + "!type": "fn(pos: number) -> number", + "!doc": "The codePointAt() method returns a non-negative integer that is the UTF-16 encoded code point value.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/codePointAt" + }, + "endsWith": { + "!type": "fn(searchString: string, position?: number) -> bool", + "!doc": "The endsWith() method determines whether a string ends with the characters of another string, returning true or false as appropriate.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/endsWith" + }, + "includes": { + "!type": "fn(searchString: string, position?: number) -> bool", + "!doc": "The includes() method determines whether one string may be found within another string, returning true or false as appropriate.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/contains" + }, + "normalize": { + "!type": "fn(form: string) -> string", + "!doc": "The normalize() method returns the Unicode Normalization Form of a given string (if the value isn't a string, it will be converted to one first).", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/normalize" + }, + "repeat": { + "!type": "fn(count: number) -> string", + "!doc": "The repeat() method constructs and returns a new string which contains the specified number of copies of the string on which it was called, concatenated together.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/repeat" + }, + "startsWith": { + "!type": "fn(searchString: string, position?: number) -> bool", + "!doc": "The startsWith() method determines whether a string begins with the characters of another string, returning true or false as appropriate.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/startsWith" + }, + ":Symbol.iterator": { + "!type": "fn() -> +iter[:t=string]", + "!doc": "Returns a new Iterator object that iterates over the code points of a String value, returning each code point as a String value.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/@@iterator" + } + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String", + "!doc": "The String global object is a constructor for strings, or a sequence of characters." + }, + "Number": { + "!type": "fn(value: ?) -> number", + "MAX_VALUE": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/MAX_VALUE", + "!doc": "The maximum numeric value representable in JavaScript." + }, + "MIN_VALUE": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/MIN_VALUE", + "!doc": "The smallest positive numeric value representable in JavaScript." + }, + "POSITIVE_INFINITY": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/POSITIVE_INFINITY", + "!doc": "A value representing the positive Infinity value." + }, + "NEGATIVE_INFINITY": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/NEGATIVE_INFINITY", + "!doc": "A value representing the negative Infinity value." + }, + "prototype": { + "!stdProto": "Number", + "toString": { + "!type": "fn(radix?: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toString", + "!doc": "Returns a string representing the specified Number object" + }, + "toFixed": { + "!type": "fn(digits: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toFixed", + "!doc": "Formats a number using fixed-point notation" + }, + "toExponential": { + "!type": "fn(digits: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toExponential", + "!doc": "Returns a string representing the Number object in exponential notation" + }, + "toPrecision": { + "!type": "fn(digits: number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toPrecision", + "!doc": "The toPrecision() method returns a string representing the number to the specified precision." + } + }, + "EPSILON": { + "!type": "number", + "!doc": "The Number.EPSILON property represents the difference between one and the smallest value greater than one that can be represented as a Number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/EPSILON" + }, + "MAX_SAFE_INTEGER": { + "!type": "number", + "!doc": "The Number.MAX_SAFE_INTEGER constant represents the maximum safe integer in JavaScript (253 - 1).", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/MAX_SAFE_INTEGER" + }, + "MIN_SAFE_INTEGER": { + "!type": "number", + "!doc": "The Number.MIN_SAFE_INTEGER constant represents the minimum safe integer in JavaScript (-(253 - 1)).", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/MIN_SAFE_INTEGER" + }, + "isFinite": { + "!type": "fn(testValue: ?) -> bool", + "!doc": "The Number.isFinite() method determines whether the passed value is finite.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isFinite" + }, + "isInteger": { + "!type": "fn(testValue: ?) -> bool", + "!doc": "The Number.isInteger() method determines whether the passed value is an integer.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isInteger" + }, + "isNaN": { + "!type": "fn(testValue: ?) -> bool", + "!doc": "The Number.isNaN() method determines whether the passed value is NaN. More robust version of the original global isNaN().", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isNaN" + }, + "isSafeInteger": { + "!type": "fn(testValue: ?) -> bool", + "!doc": "The Number.isSafeInteger() method determines whether the provided value is a number that is a safe integer. A safe integer is an integer that", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isSafeInteger" + }, + "parseFloat": { + "!type": "fn(string: string) -> number", + "!doc": "The Number.parseFloat() method parses a string argument and returns a floating point number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/parseFloat" + }, + "parseInt": { + "!type": "fn(string: string, radix?: number) -> number", + "!doc": "The Number.parseInt() method parses a string argument and returns an integer of the specified radix or base.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/parseInt" + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number", + "!doc": "The Number JavaScript object is a wrapper object allowing you to work with numerical values. A Number object is created using the Number() constructor." + }, + "Boolean": { + "!type": "fn(value: ?) -> bool", + "prototype": { + "!stdProto": "Boolean" + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Boolean", + "!doc": "The Boolean object is an object wrapper for a boolean value." + }, + "RegExp": { + "!type": "fn(source: string, flags?: string)", + "prototype": { + "!stdProto": "RegExp", + "exec": { + "!type": "fn(input: string) -> [string]", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/exec", + "!doc": "Executes a search for a match in a specified string. Returns a result array, or null." + }, + "test": { + "!type": "fn(input: string) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/test", + "!doc": "Executes the search for a match between a regular expression and a specified string. Returns true or false." + }, + "global": { + "!type": "bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp", + "!doc": "Creates a regular expression object for matching text with a pattern." + }, + "ignoreCase": { + "!type": "bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp", + "!doc": "Creates a regular expression object for matching text with a pattern." + }, + "multiline": { + "!type": "bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/multiline", + "!doc": "Reflects whether or not to search in strings across multiple lines.\n" + }, + "source": { + "!type": "string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/source", + "!doc": "A read-only property that contains the text of the pattern, excluding the forward slashes.\n" + }, + "lastIndex": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/lastIndex", + "!doc": "A read/write integer property that specifies the index at which to start the next match." + }, + "flags": { + "!type": "string", + "!doc": "The flags property returns a string consisting of the flags of the current regular expression object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp/flags" + }, + "sticky": { + "!type": "bool", + "!doc": "The sticky property reflects whether or not the search is sticky (searches in strings only from the index indicated by the lastIndex property of this regular expression). sticky is a read-only property of an individual regular expression object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp/sticky" + }, + "unicode": { + "!type": "bool", + "!doc": "The 'u' flag enables various Unicode-related features.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp/unicode" + } + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp", + "!doc": "Creates a regular expression object for matching text with a pattern." + }, + "Date": { + "!type": "fn(ms: number)", + "parse": { + "!type": "fn(source: string) -> +Date", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/parse", + "!doc": "Parses a string representation of a date, and returns the number of milliseconds since January 1, 1970, 00:00:00 UTC." + }, + "UTC": { + "!type": "fn(year: number, month: number, date: number, hour?: number, min?: number, sec?: number, ms?: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/UTC", + "!doc": "Accepts the same parameters as the longest form of the constructor, and returns the number of milliseconds in a Date object since January 1, 1970, 00:00:00, universal time." + }, + "now": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/now", + "!doc": "Returns the number of milliseconds elapsed since 1 January 1970 00:00:00 UTC." + }, + "prototype": { + "toUTCString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toUTCString", + "!doc": "Converts a date to a string, using the universal time convention." + }, + "toISOString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toISOString", + "!doc": "JavaScript provides a direct way to convert a date object into a string in ISO format, the ISO 8601 Extended Format." + }, + "toDateString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toDateString", + "!doc": "Returns the date portion of a Date object in human readable form in American English." + }, + "toTimeString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toTimeString", + "!doc": "Returns the time portion of a Date object in human readable form in American English." + }, + "toLocaleDateString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toLocaleDateString", + "!doc": "Converts a date to a string, returning the \"date\" portion using the operating system's locale's conventions.\n" + }, + "toLocaleTimeString": { + "!type": "fn() -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toLocaleTimeString", + "!doc": "Converts a date to a string, returning the \"time\" portion using the current locale's conventions." + }, + "getTime": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getTime", + "!doc": "Returns the numeric value corresponding to the time for the specified date according to universal time." + }, + "getFullYear": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getFullYear", + "!doc": "Returns the year of the specified date according to local time." + }, + "getYear": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getYear", + "!doc": "Returns the year in the specified date according to local time." + }, + "getMonth": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getMonth", + "!doc": "Returns the month in the specified date according to local time." + }, + "getUTCMonth": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCMonth", + "!doc": "Returns the month of the specified date according to universal time.\n" + }, + "getDate": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getDate", + "!doc": "Returns the day of the month for the specified date according to local time." + }, + "getUTCDate": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCDate", + "!doc": "Returns the day (date) of the month in the specified date according to universal time.\n" + }, + "getDay": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getDay", + "!doc": "Returns the day of the week for the specified date according to local time." + }, + "getUTCDay": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCDay", + "!doc": "Returns the day of the week in the specified date according to universal time.\n" + }, + "getHours": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getHours", + "!doc": "Returns the hour for the specified date according to local time." + }, + "getUTCHours": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCHours", + "!doc": "Returns the hours in the specified date according to universal time.\n" + }, + "getMinutes": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getMinutes", + "!doc": "Returns the minutes in the specified date according to local time." + }, + "getUTCMinutes": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date", + "!doc": "Creates JavaScript Date instances which let you work with dates and times." + }, + "getSeconds": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getSeconds", + "!doc": "Returns the seconds in the specified date according to local time." + }, + "getUTCSeconds": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCSeconds", + "!doc": "Returns the seconds in the specified date according to universal time.\n" + }, + "getMilliseconds": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getMilliseconds", + "!doc": "Returns the milliseconds in the specified date according to local time." + }, + "getUTCMilliseconds": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCMilliseconds", + "!doc": "Returns the milliseconds in the specified date according to universal time.\n" + }, + "getTimezoneOffset": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getTimezoneOffset", + "!doc": "Returns the time-zone offset from UTC, in minutes, for the current locale." + }, + "setTime": { + "!type": "fn(date: +Date) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setTime", + "!doc": "Sets the Date object to the time represented by a number of milliseconds since January 1, 1970, 00:00:00 UTC.\n" + }, + "setFullYear": { + "!type": "fn(year: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setFullYear", + "!doc": "Sets the full year for a specified date according to local time.\n" + }, + "setUTCFullYear": { + "!type": "fn(year: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCFullYear", + "!doc": "Sets the full year for a specified date according to universal time.\n" + }, + "setMonth": { + "!type": "fn(month: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setMonth", + "!doc": "Set the month for a specified date according to local time." + }, + "setUTCMonth": { + "!type": "fn(month: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCMonth", + "!doc": "Sets the month for a specified date according to universal time.\n" + }, + "setDate": { + "!type": "fn(day: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setDate", + "!doc": "Sets the day of the month for a specified date according to local time." + }, + "setUTCDate": { + "!type": "fn(day: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCDate", + "!doc": "Sets the day of the month for a specified date according to universal time.\n" + }, + "setHours": { + "!type": "fn(hour: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setHours", + "!doc": "Sets the hours for a specified date according to local time, and returns the number of milliseconds since 1 January 1970 00:00:00 UTC until the time represented by the updated Date instance." + }, + "setUTCHours": { + "!type": "fn(hour: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCHours", + "!doc": "Sets the hour for a specified date according to universal time.\n" + }, + "setMinutes": { + "!type": "fn(min: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setMinutes", + "!doc": "Sets the minutes for a specified date according to local time." + }, + "setUTCMinutes": { + "!type": "fn(min: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCMinutes", + "!doc": "Sets the minutes for a specified date according to universal time.\n" + }, + "setSeconds": { + "!type": "fn(sec: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setSeconds", + "!doc": "Sets the seconds for a specified date according to local time." + }, + "setUTCSeconds": { + "!type": "fn(sec: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCSeconds", + "!doc": "Sets the seconds for a specified date according to universal time.\n" + }, + "setMilliseconds": { + "!type": "fn(ms: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setMilliseconds", + "!doc": "Sets the milliseconds for a specified date according to local time.\n" + }, + "setUTCMilliseconds": { + "!type": "fn(ms: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCMilliseconds", + "!doc": "Sets the milliseconds for a specified date according to universal time.\n" + }, + "toJSON": { + "!type": "fn() -> string", + "!doc": "Returns a string (using toISOString()) representing the Date object's value.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toJSON" + } + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date", + "!doc": "Creates JavaScript Date instances which let you work with dates and times." + }, + "parseInt": { + "!type": "fn(string: string, radix?: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/parseInt", + "!doc": "Parses a string argument and returns an integer of the specified radix or base." + }, + "parseFloat": { + "!type": "fn(string: string) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/parseFloat", + "!doc": "Parses a string argument and returns a floating point number." + }, + "isNaN": { + "!type": "fn(value: number) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/isNaN", + "!doc": "Determines whether a value is NaN or not. Be careful, this function is broken. You may be interested in ECMAScript 6 Number.isNaN." + }, + "isFinite": { + "!type": "fn(value: number) -> bool", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/isFinite", + "!doc": "Determines whether the passed value is a finite number." + }, + "encodeURI": { + "!type": "fn(uri: string) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/encodeURI", + "!doc": "Encodes a Uniform Resource Identifier (URI) by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character (will only be four escape sequences for characters composed of two \"surrogate\" characters)." + }, + "encodeURIComponent": { + "!type": "fn(uri: string) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/encodeURIComponent", + "!doc": "Encodes a Uniform Resource Identifier (URI) component by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character (will only be four escape sequences for characters composed of two \"surrogate\" characters)." + }, + "decodeURI": { + "!type": "fn(uri: string) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/decodeURI", + "!doc": "Decodes a Uniform Resource Identifier (URI) previously created by encodeURI or by a similar routine." + }, + "decodeURIComponent": { + "!type": "fn(uri: string) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/decodeURIComponent", + "!doc": "Decodes a Uniform Resource Identifier (URI) component previously created by encodeURIComponent or by a similar routine." + }, + "Math": { + "E": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/E", + "!doc": "The base of natural logarithms, e, approximately 2.718." + }, + "LN2": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LN2", + "!doc": "The natural logarithm of 2, approximately 0.693." + }, + "LN10": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LN10", + "!doc": "The natural logarithm of 10, approximately 2.302." + }, + "LOG2E": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LOG2E", + "!doc": "The base 2 logarithm of E (approximately 1.442)." + }, + "LOG10E": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LOG10E", + "!doc": "The base 10 logarithm of E (approximately 0.434)." + }, + "SQRT1_2": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/SQRT1_2", + "!doc": "The square root of 1/2; equivalently, 1 over the square root of 2, approximately 0.707." + }, + "SQRT2": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/SQRT2", + "!doc": "The square root of 2, approximately 1.414." + }, + "PI": { + "!type": "number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/PI", + "!doc": "The ratio of the circumference of a circle to its diameter, approximately 3.14159." + }, + "abs": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/abs", + "!doc": "Returns the absolute value of a number." + }, + "cos": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/cos", + "!doc": "Returns the cosine of a number." + }, + "sin": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/sin", + "!doc": "Returns the sine of a number." + }, + "tan": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/tan", + "!doc": "Returns the tangent of a number." + }, + "acos": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/acos", + "!doc": "Returns the arccosine (in radians) of a number." + }, + "asin": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/asin", + "!doc": "Returns the arcsine (in radians) of a number." + }, + "atan": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/atan", + "!doc": "Returns the arctangent (in radians) of a number." + }, + "atan2": { + "!type": "fn(y: number, x: number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/atan2", + "!doc": "Returns the arctangent of the quotient of its arguments." + }, + "ceil": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/ceil", + "!doc": "Returns the smallest integer greater than or equal to a number." + }, + "floor": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/floor", + "!doc": "Returns the largest integer less than or equal to a number." + }, + "round": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/round", + "!doc": "Returns the value of a number rounded to the nearest integer." + }, + "exp": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/exp", + "!doc": "Returns Ex, where x is the argument, and E is Euler's constant, the base of the natural logarithms." + }, + "log": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/log", + "!doc": "Returns the natural logarithm (base E) of a number." + }, + "sqrt": { + "!type": "fn(number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/sqrt", + "!doc": "Returns the square root of a number." + }, + "pow": { + "!type": "fn(number, number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/pow", + "!doc": "Returns base to the exponent power, that is, baseexponent." + }, + "max": { + "!type": "fn(number, number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/max", + "!doc": "Returns the largest of zero or more numbers." + }, + "min": { + "!type": "fn(number, number) -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/min", + "!doc": "Returns the smallest of zero or more numbers." + }, + "random": { + "!type": "fn() -> number", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/random", + "!doc": "Returns a floating-point, pseudo-random number in the range [0, 1) that is, from 0 (inclusive) up to but not including 1 (exclusive), which you can then scale to your desired range." + }, + "acosh": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.acosh() function returns the hyperbolic arc-cosine of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/acosh" + }, + "asinh": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.asinh() function returns the hyperbolic arcsine of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/asinh" + }, + "atanh": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.atanh() function returns the hyperbolic arctangent of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/atanh" + }, + "cbrt": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.cbrt() function returns the cube root of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/cbrt" + }, + "clz32": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.clz32() function returns the number of leading zero bits in the 32-bit binary representation of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/clz32" + }, + "cosh": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.cosh() function returns the hyperbolic cosine of a number, that can be expressed using the constant e:", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/cosh" + }, + "expm1": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.expm1() function returns ex - 1, where x is the argument, and e the base of the natural logarithms.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/expm1" + }, + "fround": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.fround() function returns the nearest single precision float representation of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/fround" + }, + "hypot": { + "!type": "fn(value: number) -> number", + "!doc": "The Math.hypot() function returns the square root of the sum of squares of its arguments.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/hypot" + }, + "imul": { + "!type": "fn(a: number, b: number) -> number", + "!doc": "The Math.imul() function returns the result of the C-like 32-bit multiplication of the two parameters.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/imul" + }, + "log10": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.log10() function returns the base 10 logarithm of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/log10" + }, + "log1p": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.log1p() function returns the natural logarithm (base e) of 1 + a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/log1p" + }, + "log2": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.log2() function returns the base 2 logarithm of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/log2" + }, + "sign": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.sign() function returns the sign of a number, indicating whether the number is positive, negative or zero.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/sign" + }, + "sinh": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.sinh() function returns the hyperbolic sine of a number, that can be expressed using the constant e:", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/sinh" + }, + "tanh": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.tanh() function returns the hyperbolic tangent of a number.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/tanh" + }, + "trunc": { + "!type": "fn(x: number) -> number", + "!doc": "The Math.trunc() function returns the integral part of a number by removing any fractional digits. It does not round any numbers. The function can be expressed with the floor() and ceil() function:", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/trunc" + }, + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math", + "!doc": "A built-in object that has properties and methods for mathematical constants and functions." + }, + "JSON": { + "parse": { + "!type": "fn(json: string, reviver?: fn(key: string, value: ?) -> ?) -> ?", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/JSON/parse", + "!doc": "Parse a string as JSON, optionally transforming the value produced by parsing." + }, + "stringify": { + "!type": "fn(value: ?, replacer?: fn(key: string, value: ?) -> ?, space?: string|number) -> string", + "!url": "https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/JSON/stringify", + "!doc": "Convert a value to JSON, optionally replacing values if a replacer function is specified, or optionally including only the specified properties if a replacer array is specified." + }, + "!url": "https://developer.mozilla.org/en-US/docs/JSON", + "!doc": "JSON (JavaScript Object Notation) is a data-interchange format. It closely resembles a subset of JavaScript syntax, although it is not a strict subset. (See JSON in the JavaScript Reference for full details.) It is useful when writing any kind of JavaScript-based application, including websites and browser extensions. For example, you might store user information in JSON format in a cookie, or you might store extension preferences in JSON in a string-valued browser preference." + }, + "Map": { + "!type": "fn(iterable?: [?])", + "!doc": "The Map object is a simple key/value map. Any value (both objects and primitive values) may be used as either a key or a value.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map", + "prototype": { + "clear": { + "!type": "fn()", + "!doc": "The clear() method removes all elements from a Map object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/clear" + }, + "delete": { + "!type": "fn(key: ?)", + "!doc": "The delete() method removes the specified element from a Map object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/delete" + }, + "entries": { + "!type": "fn() -> +iter[:t=[!this.:key, !this.:value]]", + "!doc": "The entries() method returns a new Iterator object that contains the [key, value] pairs for each element in the Map object in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/entries" + }, + "forEach": { + "!type": "fn(callback: fn(value: ?, key: ?, map: +Map), thisArg?: ?)", + "!effects": ["call !0 this=!1 !this.:value !this.:key !this"], + "!doc": "The forEach() method executes a provided function once per each key/value pair in the Map object, in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/forEach" + }, + "get": { + "!type": "fn(key: ?) -> !this.:value", + "!doc": "The get() method returns a specified element from a Map object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/get" + }, + "has": { + "!type": "fn(key: ?) -> bool", + "!doc": "The has() method returns a boolean indicating whether an element with the specified key exists or not.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/has" + }, + "keys": { + "!type": "fn() -> +iter[:t=!this.:key]", + "!doc": "The keys() method returns a new Iterator object that contains the keys for each element in the Map object in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/keys" + }, + "set": { + "!type": "fn(key: ?, value: ?) -> !this", + "!effects": ["propagate !0 !this.:key", "propagate !1 !this.:value"], + "!doc": "The set() method adds a new element with a specified key and value to a Map object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/set" + }, + "size": { + "!type": "number", + "!doc": "The size accessor property returns the number of elements in a Map object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/size" + }, + "values": { + "!type": "fn() -> +iter[:t=!this.:value]", + "!doc": "The values() method returns a new Iterator object that contains the values for each element in the Map object in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/values" + }, + ":Symbol.iterator": { + "!type": "fn() -> +iter[:t=[!this.:key, !this.:value]]", + "!doc": "Returns a new Iterator object that contains the [key, value] pairs for each element in the Map object in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/@@iterator" + } + } + }, + "Set": { + "!type": "fn(iterable?: [?])", + "!doc": "The Set object lets you store unique values of any type, whether primitive values or object references.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set", + "prototype": { + "add": { + "!type": "fn(value: ?) -> !this", + "!effects": ["propagate !0 !this.:t"], + "!doc": "The add() method appends a new element with a specified value to the end of a Set object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/add" + }, + "clear": { + "!type": "fn()", + "!doc": "The clear() method removes all elements from a Set object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/clear" + }, + "delete": { + "!type": "fn(value: ?) -> bool", + "!doc": "The delete() method removes the specified element from a Set object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/delete" + }, + "entries": { + "!type": "fn() -> +iter[:t=[!this.:t]]", + "!doc": "The entries() method returns a new Iterator object that contains an array of [value, value] for each element in the Set object, in insertion order. For Set objects there is no key like in Map objects. However, to keep the API similar to the Map object, each entry has the same value for its key and value here, so that an array [value, value] is returned.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/entries" + }, + "forEach": { + "!type": "fn(callback: fn(value: ?, value2: ?, set: +Set), thisArg?: ?)", + "!effects": ["call !0 this=!1 !this.:t number !this"], + "!doc": "The forEach() method executes a provided function once per each value in the Set object, in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/forEach" + }, + "has": { + "!type": "fn(value: ?) -> bool", + "!doc": "The has() method returns a boolean indicating whether an element with the specified value exists in a Set object or not.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/has" + }, + "keys": { + "!type": "fn() -> +iter[:t=!this.:t]", + "!doc": "The values() method returns a new Iterator object that contains the values for each element in the Set object in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/keys" + }, + "size": { + "!type": "number", + "!doc": "The size accessor property returns the number of elements in a Set object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/size" + }, + "values": { + "!type": "fn() -> +iter[:t=!this.:t]", + "!doc": "The values() method returns a new Iterator object that contains the values for each element in the Set object in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/values" + }, + ":Symbol.iterator": { + "!type": "fn() -> +iter[:t=!this.:t]", + "!doc": "Returns a new Iterator object that contains the values for each element in the Set object in insertion order.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/@@iterator" + } + } + }, + "Symbol": { + "!type": "fn(description?: string) -> !custom:getSymbol", + "!doc": "A symbol is a unique and immutable data type and may be used as an identifier for object properties. The symbol object is an implicit object wrapper for the symbol primitive data type.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol", + "for": { + "!type": "fn(key: string) -> !custom:getSymbol", + "!doc": "The Symbol.for(key) method searches for existing symbols in a runtime-wide symbol registry with the given key and returns it if found. Otherwise a new symbol gets created in the global symbol registry with this key.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/for" + }, + "keyFor": { + "!type": "fn(sym: +Symbol) -> string", + "!doc": "The Symbol.keyFor(sym) method retrieves a shared symbol key from the global symbol registry for the given symbol.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/keyFor" + }, + "hasInstance": ":Symbol.hasInstance", + "isConcatSpreadable": ":Symbol.isConcatSpreadable", + "iterator": ":Symbol.iterator", + "match": ":Symbol.match", + "replace": ":Symbol.replace", + "search": ":Symbol.search", + "species": ":Symbol.species", + "split": ":Symbol.split", + "toStringTag": ":Symbol.toStringTag", + "unscopables": ":Symbol.unscopables", + "prototype": { + "!stdProto": "Symbol" + } + }, + "WeakMap": { + "!type": "fn(iterable?: [?])", + "!doc": "The WeakMap object is a collection of key/value pairs in which the keys are objects and the values can be arbitrary values.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap", + "prototype": { + "delete": { + "!type": "fn(key: ?) -> bool", + "!doc": "The delete() method removes the specified element from a WeakMap object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/delete" + }, + "get": { + "!type": "fn(key: ?) -> !this.:value", + "!doc": "The get() method returns a specified element from a WeakMap object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/get" + }, + "has": { + "!type": "fn(key: ?) -> bool", + "!doc": "The has() method returns a boolean indicating whether an element with the specified key exists in the WeakMap object or not.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/has" + }, + "set": { + "!type": "fn(key: ?, value: ?)", + "!effects": ["propagate !0 !this.:key", "propagate !1 !this.:value"], + "!doc": "The set() method adds a new element with a specified key and value to a WeakMap object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/set" + } + } + }, + "WeakSet": { + "!type": "fn(iterable?: [?])", + "!doc": "The WeakSet object lets you store weakly held objects in a collection.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet", + "prototype": { + "add": { + "!type": "fn(value: ?)", + "!doc": "The add() method appends a new object to the end of a WeakSet object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet/add" + }, + "delete": { + "!type": "fn(value: ?) -> bool", + "!doc": "The delete() method removes the specified element from a WeakSet object.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet/delete" + }, + "has": { + "!type": "fn(value: ?) -> bool", + "!doc": "The has() method returns a boolean indicating whether an object exists in a WeakSet or not.", + "!url": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet/has" + } + } + } +} diff --git a/app/taro/src/constants/defs/forge.json b/app/taro/src/constants/defs/forge.json new file mode 100644 index 0000000000..6cd3204c7d --- /dev/null +++ b/app/taro/src/constants/defs/forge.json @@ -0,0 +1,11263 @@ +{ + "!name": "LIB/node-forge", + "!define": { + "forge.aes.Algorithm.prototype.initialize.!0": { + "key": { + "!type": "string", + "!span": "2009[76:4]-2012[76:7]" + }, + "decrypt": { + "!type": "bool", + "!span": "2023[77:4]-2030[77:11]" + } + }, + "forge.aes.Algorithm.!1": { + "prototype": { + "encrypt": {}, + "afterFinish": {}, + "generateHashTable": {}, + "generateSubHashTable": {}, + "start": "modes.gcm.prototype.start", + "decrypt": "modes.gcm.prototype.decrypt", + "multiply": "modes.gcm.prototype.multiply", + "pow": "modes.gcm.prototype.pow", + "tableMultiply": "modes.gcm.prototype.tableMultiply", + "ghash": "modes.gcm.prototype.ghash" + } + }, + "forge.aes.Algorithm.!1.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "forge.aes.Algorithm.!1.prototype.afterFinish.!1": { + "decrypt": { + "!type": "bool", + "!span": "6102[201:10]-6109[201:17]" + }, + "overflow": { + "!type": "number", + "!span": "6182[204:10]-6190[204:18]", + "!doc": "get # of bytes that won't fill a block" + } + }, + "forge.aes.Algorithm.!1.!0": { + "blockSize": { + "!type": "number", + "!span": "4691[159:4]-4700[159:13]" + }, + "cipher": { + "encrypt": "modes.gcm.cipher.encrypt", + "decrypt": "modes.gcm.cipher.decrypt" + } + }, + "forge.asn1.create.!ret": { + "tagClass": { + "!type": "number", + "!span": "8212[212:4]-8220[212:12]" + }, + "type": { + "!type": "number", + "!span": "8236[213:4]-8240[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8252[214:4]-8263[214:15]" + }, + "composed": { + "!type": "bool", + "!span": "8282[215:4]-8290[215:12]" + }, + "read": { + "!type": "number", + "!span": "19652[653:42]-19656[655:1]" + }, + "original": "_fromDer.!ret" + }, + "forge.asn1.validate.!1": { + "name": { + "!type": "string", + "!span": "12601[409:2]-12605[409:6]" + }, + "tagClass": { + "!type": "number", + "!span": "12637[410:2]-12645[410:10]" + }, + "type": { + "!type": "number", + "!span": "12671[411:2]-12675[411:6]" + }, + "constructed": { + "!type": "bool", + "!span": "12699[412:2]-12710[412:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "12720[413:2]-12731[413:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "12777[415:4]-12781[415:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12823[416:4]-12831[416:12]" + }, + "type": { + "!type": "number", + "!span": "12859[417:4]-12863[417:8]" + }, + "constructed": { + "!type": "bool", + "!span": "12888[418:4]-12899[418:15]" + }, + "capture": { + "!type": "string", + "!span": "12912[419:4]-12919[419:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13002[422:4]-13006[422:8]", + "!doc": "Name (subject) (RDNSequence)" + }, + "tagClass": { + "!type": "number", + "!span": "13048[423:4]-13056[423:12]" + }, + "type": { + "!type": "number", + "!span": "13084[424:4]-13088[424:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13114[425:4]-13125[425:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "13137[426:4]-13148[426:15]" + } + }, + "2": { + "name": { + "!type": "string", + "!span": "6195[231:2]-6199[231:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6227[232:2]-6235[232:10]" + }, + "type": { + "!type": "number", + "!span": "6261[233:2]-6265[233:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6289[234:2]-6300[234:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6310[235:2]-6321[235:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + } + } + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + } + } + } + } + } + }, + "3": { + "name": { + "!type": "string", + "!span": "13245[431:4]-13249[431:8]" + }, + "tagClass": { + "!type": "number", + "!span": "13294[432:4]-13302[432:12]" + }, + "type": { + "!type": "number", + "!span": "13337[433:4]-13341[433:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13350[434:4]-13361[434:15]" + }, + "optional": { + "!type": "bool", + "!span": "13373[435:4]-13381[435:12]" + }, + "capture": { + "!type": "string", + "!span": "13393[436:4]-13400[436:11]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "13460[438:6]-13464[438:10]" + }, + "tagClass": { + "!type": "number", + "!span": "13511[439:6]-13519[439:14]" + }, + "type": { + "!type": "number", + "!span": "13549[440:6]-13553[440:10]" + }, + "constructed": { + "!type": "bool", + "!span": "13581[441:6]-13592[441:17]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "13624[443:8]-13628[443:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13682[444:8]-13690[444:16]" + }, + "type": { + "!type": "number", + "!span": "13722[445:8]-13726[445:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13751[446:8]-13762[446:19]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13789[448:8]-13793[448:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13848[449:8]-13856[449:16]" + }, + "type": { + "!type": "number", + "!span": "13888[450:8]-13892[450:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13917[451:8]-13928[451:19]" + } + } + } + } + } + } + } + }, + "forge.asn1.prettyPrint.!0": { + "tagClass": { + "!type": "number", + "!span": "9228[254:4]-9236[254:12]" + }, + "type": { + "!type": "number", + "!span": "9256[255:4]-9260[255:8]" + }, + "constructed": { + "!type": "bool", + "!span": "9276[256:4]-9287[256:15]" + }, + "composed": { + "!type": "bool", + "!span": "9310[257:4]-9318[257:12]" + } + }, + "forge.cipher.algorithms..!ret": "+forge.des.Algorithm", + "forge.cipher.BlockCipher.!0": { + "key": { + "!type": "string", + "!span": "2009[76:4]-2012[76:7]" + }, + "decrypt": { + "!type": "bool", + "!span": "2023[77:4]-2030[77:11]" + } + }, + "forge.cipher.modes.ecb.prototype.unpad.!1": { + "decrypt": { + "!type": "bool", + "!span": "6102[201:10]-6109[201:17]" + }, + "overflow": { + "!type": "number", + "!span": "6182[204:10]-6190[204:18]", + "!doc": "get # of bytes that won't fill a block" + } + }, + "forge.cipher.modes.ecb.!0": { + "blockSize": { + "!type": "number", + "!span": "4691[159:4]-4700[159:13]" + }, + "cipher": { + "encrypt": "modes.gcm.cipher.encrypt", + "decrypt": "modes.gcm.cipher.decrypt" + } + }, + "forge.cipher.modes.cfb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "6987[257:10]-6991[257:14]" + } + }, + "forge.cipher.modes.cfb.prototype.decrypt.!0": { + "read": { + "!type": "number", + "!span": "8719[317:10]-8723[317:14]" + } + }, + "forge.cipher.modes.ofb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "11014[400:10]-11018[400:14]" + } + }, + "forge.cipher.modes.ctr.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "13308[482:12]-13312[482:16]" + } + }, + "forge.cipher.modes.gcm.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "forge.des.Algorithm.prototype.initialize.!0": { + "plugin": { + "md": { + "create": {} + }, + "formatKey": "forge.random.plugin.formatKey", + "formatSeed": "forge.random.plugin.formatSeed", + "cipher": "forge.random.plugin.cipher", + "increment": "forge.random.plugin.increment" + }, + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pools": { + "": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + } + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "seed": "forge.random.seed", + "generate": "forge.random.generate", + "generateSync": "forge.random.generateSync", + "seedFile": "forge.random.seedFile", + "seedFileSync": "forge.random.seedFileSync", + "collect": "forge.random.collect", + "collectInt": "forge.random.collectInt", + "registerWorker": "forge.random.registerWorker", + "getBytes": "forge.random.getBytes", + "getBytesSync": "forge.random.getBytesSync", + "createInstance": "forge.random.createInstance" + }, + "forge.des.Algorithm.prototype.initialize.!0.plugin.md.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + }, + "forge.pki.ed25519.generateKeyPair.!0": { + "seed": { + "!type": "+Float32Array", + "!span": "5339[164:43]-5343[164:47]" + } + }, + "forge.pki.pbe.generatePkcs12Key.!5": { + "algorithm": { + "!type": "string", + "!span": "2315[98:4]-2324[98:13]", + "!doc": "SHA-512 => sha512" + }, + "blockLength": { + "!type": "number", + "!span": "2372[99:4]-2383[99:15]" + }, + "digestLength": { + "!type": "number", + "!span": "2394[100:4]-2406[100:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "2611[106:4]-2628[106:21]", + "!doc": "size of message length in bytes" + }, + "messageLength128": "_createKDF.!1.fullMessageLength", + "fullMessageLength": "_createKDF.!1.fullMessageLength", + "start": "_createKDF.!1.start", + "update": "_createKDF.!1.update", + "digest": "_createKDF.!1.digest" + }, + "forge.pki.pbe.opensslDeriveBytes.!3": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "hash.!0.fullMessageLength", + "fullMessageLength": "hash.!0.fullMessageLength", + "start": "hash.!0.start", + "update": "hash.!0.update", + "digest": "hash.!0.digest" + }, + "forge.pki.encryptPrivateKeyInfo.!2": { + "legacy": { + "!type": "bool", + "!span": "4915[152:5]-4921[152:11]" + }, + "algorithm": { + "!type": "string", + "!span": "4929[152:19]-4938[152:28]" + }, + "saltSize": { + "!type": "number", + "!span": "6295[196:28]-6303[196:36]" + }, + "count": { + "!type": "number", + "!span": "6339[198:30]-6344[198:35]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[202:5]-6445[202:17]" + } + }, + "forge.pki.encryptedPrivateKeyFromPem.!0": { + "encode": {}, + "decode": {} + }, + "forge.pki.encryptedPrivateKeyFromPem.!0.encode.!0": { + "type": { + "!type": "string", + "!span": "27457[901:4]-27461[901:8]" + } + }, + "forge.pki.encryptedPrivateKeyFromPem.!0.decode.!ret": { + "": { + "type": { + "!type": "string", + "!span": "3012[109:6]-3016[109:10]" + }, + "procType": { + "version": { + "!type": "string", + "!span": "4449[158:26]-4456[158:33]" + }, + "type": { + "!type": "string", + "!span": "4469[158:46]-4473[158:50]" + } + }, + "contentDomain": { + "!type": "string", + "!span": "3056[111:6]-3069[111:19]", + "!doc": "special-case Content-Domain" + }, + "dekInfo": { + "algorithm": { + "!type": "string", + "!span": "4967[168:25]-4976[168:34]" + }, + "parameters": { + "!type": "string", + "!span": "4989[168:47]-4999[168:57]" + } + }, + "headers": { + "": { + "name": { + "!type": "string", + "!span": "3797[143:22]-3801[143:26]" + }, + "values": "pem.decode.!ret..headers..values" + } + }, + "body": { + "!type": "string", + "!span": "3123[114:6]-3127[114:10]" + } + } + }, + "forge.pki.privateKeyFromPem.!0": { + "read": { + "!type": "number", + "!span": "19652[656:10]-19656[656:14]" + }, + "e": "+BigInteger", + "d": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "n": "+BigInteger", + "decrypt": "_modPow.!1.decrypt", + "sign": "_modPow.!1.sign" + }, + "forge.pki.rsa.createKeyPairGenerationState.!ret": { + "algorithm": { + "!type": "string", + "!span": "18660[622:6]-18669[622:15]" + }, + "state": { + "!type": "number", + "!span": "18688[623:6]-18693[623:11]" + }, + "bits": { + "!type": "number", + "!span": "18704[624:6]-18708[624:10]" + }, + "eInt": { + "!type": "number", + "!span": "18738[626:6]-18742[626:10]" + }, + "qBits": { + "!type": "number", + "!span": "18823[630:6]-18828[630:11]" + }, + "pBits": { + "!type": "number", + "!span": "18847[631:6]-18852[631:11]" + }, + "pqState": { + "!type": "number", + "!span": "18880[632:6]-18887[632:13]", + "!doc": "store p or q" + }, + "e": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "num": "+BigInteger", + "keys": { + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "p1": "+BigInteger", + "q1": "+BigInteger", + "phi": "+BigInteger", + "n": "+BigInteger", + "rng": { + "nextBytes": "_generateKeyPair.!0.rng.nextBytes" + } + }, + "forge.pki.RDNAttributesAsArray.!1": { + "algorithm": { + "!type": "string", + "!span": "753[36:4]-762[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "776[37:4]-787[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "797[38:4]-809[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1004[44:4]-1021[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "rsa_mgf1.!2.fullMessageLength", + "fullMessageLength": "rsa_mgf1.!2.fullMessageLength", + "start": "rsa_mgf1.!2.start", + "update": "rsa_mgf1.!2.update", + "digest": "rsa_mgf1.!2.digest" + }, + "forge.pki.RDNAttributesAsArray.!ret": { + "": { + "type": { + "!type": "string", + "!span": "15894[517:10]-15898[517:14]" + }, + "name": { + "!type": "string", + "!span": "16121[522:12]-16125[522:16]" + } + } + }, + "forge.pki.CRIAttributesAsArray.!ret": { + "": { + "type": { + "!type": "string", + "!span": "17085[558:10]-17089[558:14]" + }, + "name": { + "!type": "string", + "!span": "17276[563:12]-17280[563:16]" + }, + "extensions": { + "": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "altNames": { + "": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + } + } + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + } + } + } + } + }, + "forge.pki.certificateFromPem.!ret": { + "version": { + "!type": "number", + "!span": "27761[914:7]-27768[914:14]" + }, + "serialNumber": { + "!type": "string", + "!span": "27784[915:7]-27796[915:19]" + }, + "signatureOid": { + "!type": "string", + "!span": "27812[916:7]-27824[916:19]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "27894[919:15]-27906[919:27]" + }, + "parameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + } + }, + "issuer": { + "hash": { + "!type": "string", + "!span": "28288[933:14]-28292[933:18]" + }, + "getField": {}, + "attributes": "pki.RDNAttributesAsArray.!ret", + "addField": "pki.certificateFromPem.!ret.issuer.addField" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "28580[944:15]-28584[944:19]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "pki.certificateFromPem.!ret.subject.getField", + "addField": "pki.certificateFromPem.!ret.subject.addField" + }, + "extensions": { + "": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "altNames": { + "": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + } + } + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + } + } + }, + "sign": {}, + "signatureParameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + }, + "read": { + "!type": "number", + "!span": "19652[645:18]-19656[645:22]" + }, + "validity": { + "notBefore": "+Date", + "notAfter": "+Date" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "md": "_createKDF.!1", + "tbsCertificate": "_fromDer.!ret", + "setSubject": "pki.certificateFromPem.!ret.setSubject", + "setIssuer": "pki.certificateFromPem.!ret.setIssuer", + "setExtensions": "pki.certificateFromPem.!ret.setExtensions", + "getExtension": "pki.certificateFromPem.!ret.getExtension", + "verify": "pki.certificateFromPem.!ret.verify", + "isIssuer": "pki.certificateFromPem.!ret.isIssuer", + "issued": "pki.certificateFromPem.!ret.issued", + "generateSubjectKeyIdentifier": "pki.certificateFromPem.!ret.generateSubjectKeyIdentifier", + "verifySubjectKeyIdentifier": "pki.certificateFromPem.!ret.verifySubjectKeyIdentifier" + }, + "forge.pki.certificateFromPem.!ret.sign.!0": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret", + "signatureParameters": "_readSignatureParameters.!ret", + "getAttribute": "_getAttribute.!0.getAttribute", + "addAttribute": "_getAttribute.!0.addAttribute", + "setSubject": "_getAttribute.!0.setSubject", + "setAttributes": "_getAttribute.!0.setAttributes", + "sign": "_getAttribute.!0.sign", + "verify": "_getAttribute.!0.verify" + }, + "forge.pki.getPublicKeyFingerprint.!1": { + "type": { + "!type": "string", + "!span": "37654[1236:56]-37658[1236:60]" + } + }, + "forge.pki.certificationRequestFromPem.!ret": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "getAttribute": {}, + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret", + "signatureParameters": "_readSignatureParameters.!ret", + "addAttribute": "_getAttribute.!0.addAttribute", + "setSubject": "_getAttribute.!0.setSubject", + "setAttributes": "_getAttribute.!0.setAttributes", + "sign": "_getAttribute.!0.sign", + "verify": "_getAttribute.!0.verify" + }, + "forge.pki.certificateExtensionsFromAsn1.!0": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + } + }, + "forge.pki.certificateExtensionsFromAsn1.!ret": { + "": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + }, + "altNames": { + "": "pki.certificateExtensionsFromAsn1.!0" + } + } + }, + "forge.pki.certificateExtensionFromAsn1.!ret": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + }, + "altNames": { + "": "pki.certificateExtensionsFromAsn1.!0" + } + }, + "forge.http.createClient.!0": { + "url": { + "!type": "string", + "!span": "12551[397:8]-12554[397:11]" + }, + "socketPool": { + "sockets": { + "": { + "connected": {}, + "closed": {}, + "data": {}, + "error": {}, + "connect": {}, + "options": { + "request": { + "version": { + "!type": "string", + "!span": "25249[872:10]-25256[872:17]" + }, + "body": { + "!type": "string", + "!span": "25382[875:10]-25386[875:14]", + "!doc": "inflate using flash api" + }, + "bodyDeflated": { + "!type": "bool", + "!span": "25421[876:10]-25433[876:22]" + }, + "addCookie": {}, + "code": { + "!type": "number", + "!span": "28698[994:11]-28702[994:15]" + }, + "message": { + "!type": "string", + "!span": "28719[995:11]-28726[995:18]" + }, + "headerReceived": { + "!type": "bool", + "!span": "28770[997:11]-28784[997:25]", + "!doc": "handle final line, end of header" + }, + "bodyReceived": { + "!type": "bool", + "!span": "28805[998:11]-28817[998:23]", + "!doc": "body received" + }, + "readBodyUntilClose": { + "!type": "bool", + "!span": "34861[1193:15]-34879[1193:33]" + }, + "time": { + "!type": "number", + "!span": "35036[1201:15]-35040[1201:19]" + }, + "aborted": { + "!type": "bool", + "!span": "17397[562:23]-17404[562:30]" + }, + "connectTime": { + "!type": "number", + "!span": "3048[106:13]-3059[106:24]" + }, + "getCookies": {}, + "fields": { + "": "net.socketPools..sockets..options.request.fields." + }, + "setField": "net.socketPools..sockets..options.request.setField", + "appendField": "net.socketPools..sockets..options.request.appendField", + "getField": "net.socketPools..sockets..options.request.getField", + "toString": "net.socketPools..sockets..options.request.toString", + "readHeader": "net.socketPools..sockets..options.request.readHeader", + "readBody": "net.socketPools..sockets..options.request.readBody", + "abort": "net.socketPools..sockets..options.request.abort" + }, + "error": {}, + "headerReady": {}, + "bodyReady": {}, + "response": "net.socketPools..sockets..options.request", + "connected": "net.socketPools..sockets..options.connected", + "closed": "net.socketPools..sockets..options.closed" + }, + "sending": { + "!type": "bool", + "!span": "5219[171:3]-5226[171:10]" + }, + "retries": { + "!type": "number", + "!span": "4067[126:57]-4074[128:3]" + }, + "buffer": "+ByteBuffer", + "destroy": "net.socketPools..sockets..destroy", + "close": "net.socketPools..sockets..close", + "isConnected": "net.socketPools..sockets..isConnected", + "send": "net.socketPools..sockets..send", + "receive": "net.socketPools..sockets..receive", + "bytesAvailable": "net.socketPools..sockets..bytesAvailable" + } + }, + "policyPort": { + "!type": "number", + "!span": "1268[47:4]-1278[47:14]", + "!doc": "default policy port" + }, + "handler": "net.socketPools..handler", + "destroy": "net.socketPools..destroy", + "createSocket": "net.socketPools..createSocket" + }, + "policyPort": { + "!type": "number", + "!span": "12602[399:8]-12612[399:18]" + }, + "connections": { + "!type": "number", + "!span": "12709[401:8]-12720[401:19]" + }, + "persistCookies": { + "!type": "bool", + "!span": "12848[404:8]-12862[404:22]" + }, + "primeTlsSockets": { + "!type": "bool", + "!span": "12904[405:8]-12919[405:23]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!0.socketPool.sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..options.request.addCookie.!0": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.http.createClient.!0.socketPool.sockets..options.error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret": { + "url": { + "scheme": { + "!type": "string", + "!span": "59506[2274:4]-59512[2274:10]" + }, + "host": { + "!type": "string", + "!span": "59524[2275:4]-59528[2275:8]" + }, + "path": { + "!type": "string", + "!span": "59556[2277:4]-59560[2277:8]" + }, + "fullHost": { + "!type": "string", + "!span": "59592[2280:8]-59600[2280:16]" + } + }, + "policyPort": { + "!type": "number", + "!span": "13207[467:4]-13217[467:14]", + "!doc": "the policy port to use" + }, + "requests": { + "": { + "request": { + "version": { + "!type": "string", + "!span": "25249[872:10]-25256[872:17]" + }, + "body": { + "!type": "string", + "!span": "25382[875:10]-25386[875:14]", + "!doc": "inflate using flash api" + }, + "bodyDeflated": { + "!type": "bool", + "!span": "25421[876:10]-25433[876:22]" + }, + "addCookie": {}, + "code": { + "!type": "number", + "!span": "28698[994:11]-28702[994:15]" + }, + "message": { + "!type": "string", + "!span": "28719[995:11]-28726[995:18]" + }, + "headerReceived": { + "!type": "bool", + "!span": "28770[997:11]-28784[997:25]", + "!doc": "handle final line, end of header" + }, + "bodyReceived": { + "!type": "bool", + "!span": "28805[998:11]-28817[998:23]", + "!doc": "body received" + }, + "readBodyUntilClose": { + "!type": "bool", + "!span": "34861[1193:15]-34879[1193:33]" + }, + "time": { + "!type": "number", + "!span": "35036[1201:15]-35040[1201:19]" + }, + "aborted": { + "!type": "bool", + "!span": "17397[562:23]-17404[562:30]" + }, + "connectTime": { + "!type": "number", + "!span": "3048[106:13]-3059[106:24]" + }, + "getCookies": {}, + "fields": { + "": "net.socketPools..sockets..options.request.fields." + }, + "setField": "net.socketPools..sockets..options.request.setField", + "appendField": "net.socketPools..sockets..options.request.appendField", + "getField": "net.socketPools..sockets..options.request.getField", + "toString": "net.socketPools..sockets..options.request.toString", + "readHeader": "net.socketPools..sockets..options.request.readHeader", + "readBody": "net.socketPools..sockets..options.request.readBody", + "abort": "net.socketPools..sockets..options.request.abort" + }, + "error": {}, + "headerReady": {}, + "bodyReady": {}, + "response": "net.socketPools..sockets..options.request", + "connected": "net.socketPools..sockets..options.connected", + "closed": "net.socketPools..sockets..options.closed" + } + }, + "sockets": { + "": { + "connected": {}, + "closed": {}, + "data": {}, + "error": {}, + "connect": {}, + "sending": { + "!type": "bool", + "!span": "5219[171:3]-5226[171:10]" + }, + "retries": { + "!type": "number", + "!span": "4067[126:57]-4074[128:3]" + }, + "options": "net.socketPools..sockets..options", + "buffer": "+ByteBuffer", + "destroy": "net.socketPools..sockets..destroy", + "close": "net.socketPools..sockets..close", + "isConnected": "net.socketPools..sockets..isConnected", + "send": "net.socketPools..sockets..send", + "receive": "net.socketPools..sockets..receive", + "bytesAvailable": "net.socketPools..sockets..bytesAvailable" + } + }, + "secure": { + "!type": "bool", + "!span": "13475[477:4]-13481[477:10]", + "!doc": "whether or not the connections are secure" + }, + "cookies": { + "": { + "": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + } + } + }, + "persistCookies": { + "!type": "bool", + "!span": "13717[482:4]-13731[482:18]", + "!doc": "default to flash storage of cookies" + }, + "getCookie": {}, + "socketPool": "net.socketPools.", + "idle": { + "": "net.socketPools..sockets." + }, + "send": {}, + "destroy": "_getStorageId.!0.destroy", + "setCookie": "_getStorageId.!0.setCookie", + "removeCookie": "_getStorageId.!0.removeCookie", + "clearCookies": "_getStorageId.!0.clearCookies" + }, + "forge.http.createClient.!ret.requests..request.addCookie.!0": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.http.createClient.!ret.requests..error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + } + }, + "forge.http.createClient.!ret.sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + } + }, + "forge.http.createClient.!ret.sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + } + }, + "forge.http.createClient.!ret.sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + } + }, + "forge.http.createClient.!ret.getCookie.!ret": { + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]" + }, + "maxAge": { + "!type": "number", + "!span": "20252[674:15]-20258[674:21]" + }, + "secure": { + "!type": "bool", + "!span": "20296[675:15]-20302[675:21]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[677:15]-20402[677:23]" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.http.createRequest.!ret": { + "version": { + "!type": "string", + "!span": "25249[872:10]-25256[872:17]" + }, + "body": { + "!type": "string", + "!span": "25382[875:10]-25386[875:14]", + "!doc": "inflate using flash api" + }, + "bodyDeflated": { + "!type": "bool", + "!span": "25421[876:10]-25433[876:22]" + }, + "code": { + "!type": "number", + "!span": "28698[994:11]-28702[994:15]" + }, + "message": { + "!type": "string", + "!span": "28719[995:11]-28726[995:18]" + }, + "headerReceived": { + "!type": "bool", + "!span": "28770[997:11]-28784[997:25]", + "!doc": "handle final line, end of header" + }, + "bodyReceived": { + "!type": "bool", + "!span": "28805[998:11]-28817[998:23]", + "!doc": "body received" + }, + "readBodyUntilClose": { + "!type": "bool", + "!span": "34861[1193:15]-34879[1193:33]" + }, + "time": { + "!type": "number", + "!span": "35036[1201:15]-35040[1201:19]" + }, + "aborted": { + "!type": "bool", + "!span": "17397[562:23]-17404[562:30]" + }, + "connectTime": { + "!type": "number", + "!span": "3048[106:13]-3059[106:24]" + }, + "getCookies": {}, + "fields": { + "": "net.socketPools..sockets..options.request.fields." + }, + "setField": "net.socketPools..sockets..options.request.setField", + "appendField": "net.socketPools..sockets..options.request.appendField", + "getField": "net.socketPools..sockets..options.request.getField", + "addCookie": "net.socketPools..sockets..options.request.addCookie", + "toString": "net.socketPools..sockets..options.request.toString", + "readHeader": "net.socketPools..sockets..options.request.readHeader", + "readBody": "net.socketPools..sockets..options.request.readBody", + "abort": "net.socketPools..sockets..options.request.abort" + }, + "forge.http.parseUrl.!ret": { + "scheme": { + "!type": "string", + "!span": "59506[2274:4]-59512[2274:10]" + }, + "host": { + "!type": "string", + "!span": "59524[2275:4]-59528[2275:8]" + }, + "path": { + "!type": "string", + "!span": "59556[2277:4]-59560[2277:8]" + }, + "fullHost": { + "!type": "string", + "!span": "59592[2280:8]-59600[2280:16]" + } + }, + "forge.http.withinCookieDomain.!1": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "forge.kem.rsa.create.!0": { + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pools": { + "": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + } + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "seed": "forge.random.seed", + "plugin": { + "md": { + "create": "sha256.create" + }, + "formatKey": "forge.random.plugin.formatKey", + "formatSeed": "forge.random.plugin.formatSeed", + "cipher": "forge.random.plugin.cipher", + "increment": "forge.random.plugin.increment" + }, + "generate": "forge.random.generate", + "generateSync": "forge.random.generateSync", + "seedFile": "forge.random.seedFile", + "seedFileSync": "forge.random.seedFileSync", + "collect": "forge.random.collect", + "collectInt": "forge.random.collectInt", + "registerWorker": "forge.random.registerWorker", + "getBytes": "forge.random.getBytes", + "getBytesSync": "forge.random.getBytesSync", + "createInstance": "forge.random.createInstance" + }, + "forge.kem.rsa.create.!ret": { + "encrypt": { + "!type": "fn(publicKey: ?, keyLength: ?) -> forge.kem.rsa.create.!ret.encrypt.!ret", + "!span": "1730[54:6]-1737[54:13]", + "!doc": "Generates a secret key and its encapsulation.\n\n@param publicKey the RSA public key to encrypt with.\n@param keyLength the length, in bytes, of the secret key to generate.\n\n@return an object with:\n encapsulation: the ciphertext for generating the secret key, as a\n binary-encoded string of bytes.\n key: the secret key to use for encrypting a message." + }, + "decrypt": { + "!type": "fn(privateKey: ?, encapsulation: ?, keyLength: ?)", + "!span": "2879[90:6]-2886[90:13]", + "!doc": "Decrypts an encapsulated secret key.\n\n@param privateKey the RSA private key to decrypt with.\n@param encapsulation the ciphertext for generating the secret key, as\n a binary-encoded string of bytes.\n@param keyLength the length, in bytes, of the secret key to generate.\n\n@return the secret key as a binary-encoded string of bytes." + }, + "!span": "1310[41:12]-1312[41:14]" + }, + "forge.kem.rsa.create.!ret.encrypt.!ret": { + "!span": "2438[77:11]-2478[77:51]" + }, + "forge.kem.kdf1.!0": { + "algorithm": { + "!type": "string", + "!span": "2315[98:4]-2324[98:13]", + "!doc": "SHA-512 => sha512" + }, + "blockLength": { + "!type": "number", + "!span": "2372[99:4]-2383[99:15]" + }, + "digestLength": { + "!type": "number", + "!span": "2394[100:4]-2406[100:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "2611[106:4]-2628[106:21]", + "!doc": "size of message length in bytes" + }, + "messageLength128": "_createKDF.!1.fullMessageLength", + "fullMessageLength": "_createKDF.!1.fullMessageLength", + "start": "_createKDF.!1.start", + "update": "_createKDF.!1.update", + "digest": "_createKDF.!1.digest" + }, + "forge.log.logMessage.!0": { + "level": { + "!type": "string", + "!span": "4854[155:10]-4859[155:15]" + }, + "standard": { + "!type": "string", + "!span": "3143[102:12]-3151[102:20]" + }, + "standardFull": { + "!type": "string", + "!span": "4125[136:12]-4137[136:24]" + }, + "timestamp": "+Date", + "arguments": "f.!1.arguments" + }, + "forge.log.prepareFull.!0": { + "full": { + "!type": "string", + "!span": "3723[122:12]-3727[122:16]", + "!doc": "format the message" + } + }, + "forge.log.makeLogger.!0": {}, + "forge.log.makeLogger.!0.!0": { + "flags": { + "!type": "number", + "!span": "5727[190:4]-5732[190:9]" + }, + "level": { + "!type": "string", + "!span": "6301[212:15]-6306[212:20]", + "!doc": "set level" + }, + "f": "f" + }, + "forge.log.makeLogger.!ret": { + "flags": { + "!type": "number", + "!span": "5727[190:4]-5732[190:9]" + }, + "level": { + "!type": "string", + "!span": "6301[212:15]-6306[212:20]", + "!doc": "set level" + }, + "f": "f" + }, + "forge.md.algorithms.sha256.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + }, + "forge.md.sha256.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "forge.random.pools..fullMessageLength", + "fullMessageLength": "forge.random.pools..fullMessageLength", + "start": "forge.random.pools..start", + "update": "forge.random.pools..update", + "digest": "forge.random.pools..digest" + }, + "forge.md5.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "hash.!0.fullMessageLength", + "fullMessageLength": "hash.!0.fullMessageLength", + "start": "hash.!0.start", + "update": "hash.!0.update", + "digest": "hash.!0.digest" + }, + "forge.pem.encode.!0": { + "type": { + "!type": "string", + "!span": "27457[901:4]-27461[901:8]" + } + }, + "forge.pem.decode.!ret": { + "": { + "type": { + "!type": "string", + "!span": "3012[109:6]-3016[109:10]" + }, + "procType": { + "version": { + "!type": "string", + "!span": "4449[158:26]-4456[158:33]" + }, + "type": { + "!type": "string", + "!span": "4469[158:46]-4473[158:50]" + } + }, + "contentDomain": { + "!type": "string", + "!span": "3056[111:6]-3069[111:19]", + "!doc": "special-case Content-Domain" + }, + "dekInfo": { + "algorithm": { + "!type": "string", + "!span": "4967[168:25]-4976[168:34]" + }, + "parameters": { + "!type": "string", + "!span": "4989[168:47]-4999[168:57]" + } + }, + "headers": { + "": { + "name": { + "!type": "string", + "!span": "3797[143:22]-3801[143:26]" + }, + "values": "pem.decode.!ret..headers..values" + } + }, + "body": { + "!type": "string", + "!span": "3123[114:6]-3127[114:10]" + } + } + }, + "forge.pkcs12.pkcs12FromAsn1.!ret": { + "safeContents": { + "": { + "encrypted": { + "!type": "bool", + "!span": "15681[541:6]-15690[541:15]" + }, + "safeBags": { + "": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + } + } + } + }, + "getBags": {}, + "getBagsByFriendlyName": {}, + "getBagsByLocalKeyId": "_decodeAuthenticatedSafe.!0.getBagsByLocalKeyId" + }, + "forge.pkcs12.toPkcs12Asn1.!3": { + "saltSize": { + "!type": "number", + "!span": "24053[798:10]-24061[798:18]" + }, + "count": { + "!type": "number", + "!span": "24097[799:10]-24102[799:15]" + }, + "algorithm": { + "!type": "string", + "!span": "24138[800:10]-24147[800:19]" + }, + "useMac": { + "!type": "bool", + "!span": "24248[802:12]-24254[802:18]" + }, + "generateLocalKeyId": { + "!type": "bool", + "!span": "24392[808:12]-24410[808:30]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[245:5]-6445[245:17]" + } + }, + "forge.pkcs7.messageFromPem.!ret": { + "version": { + "!type": "number", + "!span": "18359[589:4]-18366[589:11]" + }, + "recipients": { + "": { + "version": { + "!type": "number", + "!span": "21713[700:8]-21720[700:15]" + }, + "encryptedContent": "_recipientsFromAsn1.!ret..encryptedContent" + } + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "37653[1185:6]-37662[1185:15]", + "!doc": "Keep a copy of the key & IV in the object, so the caller can\nuse it for whatever reason." + }, + "parameter": "+ByteBuffer", + "content": "+ByteBuffer", + "key": "+ByteBuffer" + }, + "findRecipient": {}, + "decrypt": {}, + "content": "+ByteBuffer", + "fromAsn1": "_fromAsn1.!0.fromAsn1", + "toAsn1": "_fromAsn1.!0.toAsn1", + "addRecipient": "_fromAsn1.!0.addRecipient", + "encrypt": "_fromAsn1.!0.encrypt", + "rawCapture": "_fromAsn1.!ret" + }, + "forge.pkcs7.messageFromPem.!ret.findRecipient.!ret": { + "serialNumber": { + "!type": "string", + "!span": "26217[836:4]-26229[836:16]" + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "26310[838:6]-26319[838:15]" + } + }, + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "forge.pkcs7.messageFromPem.!ret.decrypt.!0": { + "version": { + "!type": "number", + "!span": "3313[125:4]-3320[125:11]" + }, + "signers": { + "": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret", + "authenticatedAttributes": "_signerToAsn1.!0.authenticatedAttributes", + "unauthenticatedAttributes": "_signerToAsn1.!0.unauthenticatedAttributes" + } + }, + "certificates": { + "": "pki.certificateFromPem.!ret" + }, + "digestAlgorithmIdentifiers": { + "": "_fromDer.!ret" + }, + "contentInfo": "_fromDer.!ret", + "signerInfos": { + "": "_fromDer.!ret" + }, + "detachedContent": "_fromDer.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret", + "crls": "p7.createSignedData.!ret.crls", + "fromAsn1": "p7.createSignedData.!ret.fromAsn1", + "toAsn1": "p7.createSignedData.!ret.toAsn1", + "addSigner": "p7.createSignedData.!ret.addSigner", + "sign": "p7.createSignedData.!ret.sign", + "verify": "p7.createSignedData.!ret.verify", + "addCertificate": "p7.createSignedData.!ret.addCertificate", + "addCertificateRevokationList": "p7.createSignedData.!ret.addCertificateRevokationList" + }, + "forge.pkcs7.createSignedData.!ret": { + "version": { + "!type": "number", + "!span": "3313[125:4]-3320[125:11]" + }, + "signers": { + "": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret", + "authenticatedAttributes": "_signerToAsn1.!0.authenticatedAttributes", + "unauthenticatedAttributes": "_signerToAsn1.!0.unauthenticatedAttributes" + } + }, + "certificates": { + "": "pki.certificateFromPem.!ret" + }, + "digestAlgorithmIdentifiers": { + "": "_fromDer.!ret" + }, + "contentInfo": "_fromDer.!ret", + "signerInfos": { + "": "_fromDer.!ret" + }, + "detachedContent": "_fromDer.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret", + "crls": "p7.createSignedData.!ret.crls", + "fromAsn1": "p7.createSignedData.!ret.fromAsn1", + "toAsn1": "p7.createSignedData.!ret.toAsn1", + "addSigner": "p7.createSignedData.!ret.addSigner", + "sign": "p7.createSignedData.!ret.sign", + "verify": "p7.createSignedData.!ret.verify", + "addCertificate": "p7.createSignedData.!ret.addCertificate", + "addCertificateRevokationList": "p7.createSignedData.!ret.addCertificateRevokationList" + }, + "forge.pkcs7.createEncryptedData.!ret": { + "version": { + "!type": "number", + "!span": "17467[550:4]-17474[550:11]" + }, + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret", + "fromAsn1": "p7.createEncryptedData.!ret.fromAsn1", + "decrypt": "p7.createEncryptedData.!ret.decrypt" + }, + "forge.prime.generateProbablePrime.!1": { + "algorithm": { + "name": { + "!type": "string", + "!span": "50978[1628:6]-50982[1628:10]" + }, + "options": { + "workers": { + "!type": "number", + "!span": "51042[1630:8]-51049[1630:15]" + }, + "workLoad": { + "!type": "number", + "!span": "51081[1631:8]-51089[1631:16]" + }, + "!span": "51023[1629:6]-51030[1629:13]" + }, + "!span": "50959[1627:4]-50968[1627:13]" + }, + "!span": "50953[1626:13]-51176[1635:3]" + }, + "forge.prng.create.!ret": { + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "plugin": "forge.random.plugin", + "seed": "forge.random.seed", + "pools": { + "": "forge.random.pools." + }, + "generate": "forge.random.generate", + "generateSync": "forge.random.generateSync", + "seedFile": "forge.random.seedFile", + "seedFileSync": "forge.random.seedFileSync", + "collect": "forge.random.collect", + "collectInt": "forge.random.collectInt", + "registerWorker": "forge.random.registerWorker", + "getBytes": "forge.random.getBytes", + "getBytesSync": "forge.random.getBytesSync", + "createInstance": "forge.random.createInstance" + }, + "forge.random.pools.": { + "algorithm": { + "!type": "string", + "!span": "808[38:4]-817[38:13]" + }, + "blockLength": { + "!type": "number", + "!span": "833[39:4]-844[39:15]" + }, + "digestLength": { + "!type": "number", + "!span": "854[40:4]-866[40:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "993[44:4]-1010[44:21]", + "!doc": "full message length (set md.messageLength64 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1061[46:4]-1078[46:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> forge.random.pools.", + "!span": "1167[54:5]-1172[54:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: ?) -> forge.random.pools.", + "!span": "2229[90:5]-2235[90:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "3144[125:5]-3150[125:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "802[37:11]-1085[47:3]", + "!doc": "message digest object", + "messageLength64": "forge.random.pools..fullMessageLength" + }, + "forge.random.seedFile.!1": { + "!type": "fn(err: ?, bytes: ?)", + "!span": "12058[407:47]-12167[409:11]" + }, + "forge.rsa.createKeyPairGenerationState.!ret": { + "algorithm": { + "!type": "string", + "!span": "18660[622:6]-18669[622:15]" + }, + "state": { + "!type": "number", + "!span": "18688[623:6]-18693[623:11]" + }, + "bits": { + "!type": "number", + "!span": "18704[624:6]-18708[624:10]" + }, + "eInt": { + "!type": "number", + "!span": "18738[626:6]-18742[626:10]" + }, + "qBits": { + "!type": "number", + "!span": "18823[630:6]-18828[630:11]" + }, + "pBits": { + "!type": "number", + "!span": "18847[631:6]-18852[631:11]" + }, + "pqState": { + "!type": "number", + "!span": "18880[632:6]-18887[632:13]", + "!doc": "store p or q" + }, + "e": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "num": "+BigInteger", + "keys": "_generateKeyPair.!0.keys", + "p1": "+BigInteger", + "q1": "+BigInteger", + "phi": "+BigInteger", + "n": "+BigInteger", + "rng": { + "nextBytes": "_generateKeyPair.!0.rng.nextBytes" + } + }, + "forge.net.socketPools..sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "socket": "net.socketPools..sockets." + }, + "forge.net.socketPools..sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + } + }, + "forge.net.socketPools..sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + } + }, + "forge.net.socketPools..sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + } + }, + "forge.net.socketPools..sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + } + }, + "forge.net.socketPools..sockets..options.error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.net.createSocketPool.!0": { + "policyPort": { + "!type": "number", + "!span": "4170[131:4]-4180[131:14]" + }, + "msie": { + "!type": "bool", + "!span": "4226[133:4]-4230[133:8]" + } + }, + "forge.task.start.!0": { + "type": { + "!type": "string", + "!span": "7567[280:8]-7571[280:12]" + }, + "!span": "7557[279:23]-7802[290:7]", + "run": "Task.!0.run", + "success": "Task.successCallback", + "failure": "Task.failureCallback" + }, + "forge.task.createCondition.!ret": { + "tasks": { + "!span": "19063[693:4]-19068[693:9]", + "!doc": "all tasks that are blocked" + }, + "wait": { + "!type": "fn(task: ?)", + "!span": "19283[702:7]-19287[702:11]", + "!doc": "Causes the given task to block until notify is called. If the task\nis already waiting on this condition then this is a no-op.\n\n@param task the task to cause to wait." + }, + "notify": { + "!type": "fn()", + "!span": "19496[713:7]-19502[713:13]", + "!doc": "Notifies all waiting tasks to wake up." + }, + "!span": "19023[691:13]-19076[694:3]" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "455[21:7]-476[21:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "515[22:7]-526[22:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "558[23:7]-572[23:21]" + }, + "block_length": { + "!type": "number", + "!span": "586[24:7]-598[24:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "612[25:7]-627[25:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "641[26:7]-657[26:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "671[27:7]-684[27:20]" + }, + "mac_length": { + "!type": "number", + "!span": "722[28:7]-732[28:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "746[29:7]-760[29:21]" + } + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!1": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + } + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "sessionCache": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "getSession": {}, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "sp": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "version": "initConnectionState.!1.version" + }, + "cache": "tls.createSessionCache.!0", + "order": "tls.createSessionCache.!0.order", + "setSession": "tls.createSessionCache.!0.setSession" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "error": {}, + "record": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "session": { + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + } + }, + "sp": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "certificateRequest": { + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "extensions": { + "server_name": { + "serverNameList": "initConnectionState.!1.session.extensions.server_name.serverNameList" + } + } + }, + "state": { + "pending": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "compressFunction": "deflate", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update" + }, + "write": "deflate.!2" + }, + "current": "tls.createConnectionState.!ret" + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "records": { + "": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + } + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "fragmented": "hmac_sha1.!2", + "cipherSuites": "initConnectionState.!1.cipherSuites", + "connected": "initConnectionState.!1.connected", + "verify": "initConnectionState.!1.verify", + "getSignature": "initConnectionState.!1.getSignature", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "reset": "initConnectionState.!1.reset", + "handshake": "initConnectionState.!1.handshake", + "process": "initConnectionState.!1.process", + "prepare": "initConnectionState.!1.prepare", + "prepareHeartbeatRequest": "initConnectionState.!1.prepareHeartbeatRequest", + "close": "initConnectionState.!1.close" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!1.sessionCache.getSession.!ret": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "sp": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "version": "initConnectionState.!1.version" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!1.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + } + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + } + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initConnectionState.!2": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "forge.tls.CipherSuites.TLS_RSA_WITH_AES_256_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "979[37:7]-1000[37:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "1039[38:7]-1050[38:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "1082[39:7]-1096[39:21]" + }, + "block_length": { + "!type": "number", + "!span": "1110[40:7]-1122[40:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "1136[41:7]-1151[41:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "1165[42:7]-1181[42:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "1195[43:7]-1208[43:20]" + }, + "mac_length": { + "!type": "number", + "!span": "1246[44:7]-1256[44:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "1270[45:7]-1284[45:21]" + } + }, + "forge.tls.handleUnexpected.!0": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + } + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "sessionCache": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "version": "initConnectionState.!1.version", + "sp": "initConnectionState.!2" + }, + "cache": "tls.createSessionCache.!0", + "order": "tls.createSessionCache.!0.order", + "getSession": "tls.createSessionCache.!0.getSession", + "setSession": "tls.createSessionCache.!0.setSession" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "error": {}, + "record": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "session": { + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + } + }, + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "certificateRequest": { + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "sp": "initConnectionState.!2", + "extensions": { + "server_name": { + "serverNameList": "initConnectionState.!1.session.extensions.server_name.serverNameList" + } + } + }, + "state": { + "pending": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "compressFunction": "deflate", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update" + }, + "write": "deflate.!2" + }, + "current": "tls.createConnectionState.!ret" + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "records": { + "": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + } + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "fragmented": "hmac_sha1.!2", + "cipherSuites": "initConnectionState.!1.cipherSuites", + "connected": "initConnectionState.!1.connected", + "verify": "initConnectionState.!1.verify", + "getSignature": "initConnectionState.!1.getSignature", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "reset": "initConnectionState.!1.reset", + "handshake": "initConnectionState.!1.handshake", + "process": "initConnectionState.!1.process", + "prepare": "initConnectionState.!1.prepare", + "prepareHeartbeatRequest": "initConnectionState.!1.prepareHeartbeatRequest", + "close": "initConnectionState.!1.close" + }, + "forge.tls.handleUnexpected.!0.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + } + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + } + }, + "forge.tls.handleUnexpected.!1": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "forge.tls.parseHelloMessage.!ret": { + "version": { + "major": { + "!type": "number", + "!span": "23963[804:8]-23968[804:13]" + }, + "minor": { + "!type": "number", + "!span": "23991[805:8]-23996[805:13]" + } + }, + "random": "+ByteBuffer", + "session_id": "+ByteBuffer", + "extensions": { + "": { + "data": "+ByteBuffer", + "type": "tls.parseHelloMessage.!ret.extensions..type" + } + }, + "cipher_suites": "+ByteBuffer", + "compression_methods": "+ByteBuffer" + }, + "forge.tls.handleServerHelloDone.!1": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + }, + "forge.tls.generateKeys.!1": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "forge.tls.createConnectionState.!ret": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "compressFunction": "deflate", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update" + }, + "write": "deflate.!2" + }, + "forge.tls.createRecord.!1": { + "type": { + "!type": "number", + "!span": "125363[4108:6]-125367[4108:10]" + }, + "data": "+ByteBuffer" + }, + "forge.tls.createAlert.!1": { + "level": { + "!type": "number", + "!span": "95276[3096:10]-95281[3096:15]" + }, + "description": { + "!type": "number", + "!span": "95316[3097:10]-95327[3097:21]" + } + }, + "forge.tls.createSessionCache.!0": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "version": "initConnectionState.!1.version", + "sp": "initConnectionState.!2" + }, + "cache": "tls.createSessionCache.!0", + "order": "tls.createSessionCache.!0.order", + "getSession": "tls.createSessionCache.!0.getSession", + "setSession": "tls.createSessionCache.!0.setSession" + }, + "forge.tls.createConnection.!0": { + "server": { + "!type": "bool", + "!span": "1668[49:4]-1674[49:10]" + }, + "virtualHost": { + "!type": "string", + "!span": "1861[54:4]-1872[54:15]" + }, + "sessionCache": "tls.createSessionCache.!0", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "connected": "initConnectionState.!1.connected", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "error": "tls.createConnection.!0.error" + }, + "forge.tls.wrapSocket.!0": { + "virtualHost": { + "!type": "string", + "!span": "8112[302:6]-8123[302:17]" + }, + "!span": "7955[296:34]-8413[309:5]", + "sessionCache": "tls.createSessionCache.!0", + "caStore": "_initSocket.!2.caStore", + "socket": "net.socketPools..sockets.", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate" + }, + "forge.tls.wrapSocket.!ret": { + "connected": { + "!type": "fn(e: net.socketPools..sockets..connected.!0)", + "!span": "1417[41:4]-1426[41:13]", + "!doc": "handle doing handshake after connecting" + }, + "closed": { + "!type": "fn(e: net.socketPools..sockets..closed.!0)", + "!span": "1468[42:4]-1474[42:10]", + "!doc": "handle closing TLS connection" + }, + "data": { + "!type": "fn(e: net.socketPools..sockets..data.!0)", + "!span": "1513[43:4]-1517[43:8]" + }, + "error": { + "!type": "fn(e: ?)", + "!span": "1554[44:4]-1559[44:9]", + "!doc": "handle error on socket" + }, + "destroy": { + "!type": "fn()", + "!span": "4398[160:12]-4405[160:19]", + "!doc": "Destroys this socket." + }, + "setSessionCache": { + "!type": "fn(cache: ?)", + "!span": "4867[174:12]-4882[174:27]", + "!doc": "Sets this socket's TLS session cache. This should be called before\nthe socket is connected or after it is closed.\n\nThe cache is an object mapping session IDs to internal opaque state.\nAn application might need to change the cache used by a particular\ntlsSocket between connections if it accesses multiple TLS hosts.\n\n@param cache the session cache to use." + }, + "connect": { + "!type": "fn(options: ?)", + "!span": "5314[188:12]-5321[188:19]", + "!doc": "Connects this socket.\n\n@param options:\n host: the host to connect to.\n port: the port to connect to.\n policyPort: the policy port to use (if non-default), 0 to\n use the flash default.\n policyUrl: the policy file URL to use (instead of port)." + }, + "close": { + "!type": "fn()", + "!span": "5428[195:12]-5433[195:17]", + "!doc": "Closes this socket." + }, + "isConnected": { + "!type": "fn() -> bool", + "!span": "5596[204:12]-5607[204:23]", + "!doc": "Determines if the socket is connected or not.\n\n@return true if connected, false if not." + }, + "send": { + "!type": "fn(bytes: string)", + "!span": "5847[215:12]-5851[215:16]", + "!doc": "Writes bytes to this socket.\n\n@param bytes the bytes (as a string) to write.\n\n@return true on success, false on failure." + }, + "receive": { + "!type": "fn(count: number) -> ?", + "!span": "6655[234:12]-6662[234:19]", + "!doc": "Reads bytes from this socket (non-blocking). Fewer than the number of\nbytes requested may be read if enough bytes are not available.\n\nThis method should be called from the data handler if there are enough\nbytes available. To see how many bytes are available, check the\n'bytesAvailable' property on the event in the data handler or call the\nbytesAvailable() function on the socket. If the browser is msie, then the\nbytesAvailable() function should be used to avoid race conditions.\nOtherwise, using the property on the data handler's event may be quicker.\n\n@param count the maximum number of bytes to read.\n\n@return the bytes read (as a string) or null on error." + }, + "bytesAvailable": { + "!type": "fn() -> number", + "!span": "6880[243:12]-6894[243:26]", + "!doc": "Gets the number of bytes available for receiving on the socket.\n\n@return the number of bytes available for receiving." + }, + "sending": { + "!type": "bool", + "!span": "5219[185:36]-5226[186:2]" + }, + "retries": { + "!type": "number", + "!span": "4067[146:1]-4074[146:8]" + }, + "!span": "1372[38:18]-1595[45:3]", + "!doc": "get raw socket", + "options": "net.socketPools..sockets..options", + "buffer": "+ByteBuffer" + }, + "forge.tls.wrapSocket.!ret.closed.!0": { + "type": { + "!type": "string", + "!span": "3524[121:6]-3528[121:10]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3545[122:6]-3559[122:20]" + }, + "!span": "3495[119:21]-3568[123:5]" + }, + "forge.util.parseFragment.!ret": { + "queryString": { + "!type": "string", + "!span": "63008[2417:4]-63019[2417:15]" + }, + "query": "?" + }, + "forge.util.makeRequest.!ret": { + "query": { + "!type": "string", + "!span": "64119[2448:4]-64124[2448:9]", + "!doc": "full query string" + }, + "getQueryLast": {}, + "getPath": "util.makeRequest.!ret.getPath", + "getQuery": "util.makeRequest.!ret.getQuery" + }, + "forge.xhr.setCookie.!0": { + "maxAge": { + "!type": "number", + "!span": "6000[192:9]-6006[192:15]", + "!doc": "default cookie expiration to never" + }, + "comment": { + "!type": "string", + "!span": "20205[658:0]-20212[659:6]" + }, + "secure": { + "!type": "bool", + "!span": "20296[663:3]-20302[663:9]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[666:0]-20402[666:8]" + }, + "path": { + "!type": "string", + "!span": "20445[668:25]-20449[669:0]" + }, + "created": { + "!type": "number", + "!span": "20583[673:4]-20590[673:11]" + } + }, + "forge.xhr.create.!ret": { + "readyState": { + "!type": "number", + "!span": "11722[366:4]-11732[366:14]", + "!doc": "7. set state to UNSENT" + }, + "responseText": { + "!type": "string", + "!span": "11792[368:4]-11804[368:16]", + "!doc": "3. set response to null" + }, + "responseXML": { + "async": { + "!type": "bool", + "!span": "18241[587:16]-18246[587:21]" + } + }, + "status": { + "!type": "number", + "!span": "11952[372:4]-11958[372:10]", + "!doc": "custom: reset status and statusText" + }, + "statusText": { + "!type": "string", + "!span": "12035[374:4]-12045[374:14]", + "!doc": "readonly, returns the HTTP status message (i.e. 'Not Found')" + }, + "cookies": "_getStorageId.!0.cookies", + "open": "xhrApi.create.!ret.open", + "setRequestHeader": "xhrApi.create.!ret.setRequestHeader", + "send": "xhrApi.create.!ret.send", + "abort": "xhrApi.create.!ret.abort", + "getAllResponseHeaders": "xhrApi.create.!ret.getAllResponseHeaders", + "getResponseHeader": "xhrApi.create.!ret.getResponseHeader" + }, + "mix.": "[number]", + "imix.": "[number]", + "_updateBlock.!2": "[number|_fromDer.!ret]", + "_createCipher.!0": { + "decrypt": { + "!type": "bool", + "!span": "4357[142:4]-4364[142:11]" + }, + "!span": "4319[139:23]-4390[144:3]" + }, + "_createCipher.!ret": "+BlockCipher", + "tls.CipherSuites.TLS_RSA_WITH_AES_128_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "455[21:7]-476[21:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "515[22:7]-526[22:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "558[23:7]-572[23:21]" + }, + "block_length": { + "!type": "number", + "!span": "586[24:7]-598[24:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "612[25:7]-627[25:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "641[26:7]-657[26:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "671[27:7]-684[27:20]" + }, + "mac_length": { + "!type": "number", + "!span": "722[28:7]-732[28:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "746[29:7]-760[29:21]" + } + }, + "tls.CipherSuites.TLS_RSA_WITH_AES_256_CBC_SHA.initSecurityParameters.!0": { + "bulk_cipher_algorithm": { + "!type": "number", + "!span": "979[37:7]-1000[37:28]" + }, + "cipher_type": { + "!type": "number", + "!span": "1039[38:7]-1050[38:18]" + }, + "enc_key_length": { + "!type": "number", + "!span": "1082[39:7]-1096[39:21]" + }, + "block_length": { + "!type": "number", + "!span": "1110[40:7]-1122[40:19]" + }, + "fixed_iv_length": { + "!type": "number", + "!span": "1136[41:7]-1151[41:22]" + }, + "record_iv_length": { + "!type": "number", + "!span": "1165[42:7]-1181[42:23]" + }, + "mac_algorithm": { + "!type": "number", + "!span": "1195[43:7]-1208[43:20]" + }, + "mac_length": { + "!type": "number", + "!span": "1246[44:7]-1256[44:17]" + }, + "mac_key_length": { + "!type": "number", + "!span": "1270[45:7]-1284[45:21]" + } + }, + "tls.handleUnexpected.!0": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + } + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "error": {}, + "session": { + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + } + }, + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "certificateRequest": { + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "sp": "initConnectionState.!2", + "extensions": { + "server_name": { + "serverNameList": "initConnectionState.!1.session.extensions.server_name.serverNameList" + } + } + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "sessionCache": "tls.createSessionCache.!0", + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "record": "hmac_sha1.!2", + "state": { + "pending": "tls.createConnectionState.!ret", + "current": "tls.createConnectionState.!ret" + }, + "fragmented": "hmac_sha1.!2", + "records": { + "": "H5.!1" + }, + "cipherSuites": "initConnectionState.!1.cipherSuites", + "connected": "initConnectionState.!1.connected", + "verify": "initConnectionState.!1.verify", + "getSignature": "initConnectionState.!1.getSignature", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "reset": "initConnectionState.!1.reset", + "handshake": "initConnectionState.!1.handshake", + "process": "initConnectionState.!1.process", + "prepare": "initConnectionState.!1.prepare", + "prepareHeartbeatRequest": "initConnectionState.!1.prepareHeartbeatRequest", + "close": "initConnectionState.!1.close" + }, + "tls.handleUnexpected.!0.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + } + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + } + }, + "tls.handleUnexpected.!1": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + } + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "fragment": "+ByteBuffer" + }, + "tls.parseHelloMessage.!ret": { + "version": { + "major": { + "!type": "number", + "!span": "23963[804:8]-23968[804:13]" + }, + "minor": { + "!type": "number", + "!span": "23991[805:8]-23996[805:13]" + }, + "!span": "23944[803:6]-23951[803:13]" + }, + "extensions": { + "!type": "[tls.parseHelloMessage.!ret.extensions.]", + "!span": "24116[809:6]-24126[809:16]" + }, + "!span": "23936[802:10]-24136[810:5]", + "random": "+ByteBuffer", + "session_id": "+ByteBuffer", + "cipher_suites": "+ByteBuffer", + "compression_methods": "+ByteBuffer" + }, + "tls.parseHelloMessage.!ret.extensions.": { + "type": { + "!type": "[number, number]", + "!span": "24628[826:10]-24632[826:14]" + }, + "!span": "24616[825:28]-24713[828:9]", + "data": "+ByteBuffer" + }, + "tls.handleServerHelloDone.!1": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + } + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "fragment": "+ByteBuffer" + }, + "tls.generateKeys.!1": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "keys": "tls.generateKeys.!ret" + }, + "tls.generateKeys.!ret": { + "!span": "73404[2401:13]-73632[2406:3]", + "!doc": "split the key material into the MAC and encryption keys" + }, + "tls.createConnectionState.!ret": { + "read": { + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "sequenceNumber": "deflate.!2.sequenceNumber", + "cipherFunction": "deflate.!2.cipherFunction", + "updateSequenceNumber": "deflate.!2.updateSequenceNumber", + "update": "deflate.!2.update", + "compressFunction": "deflate" + }, + "!span": "75794[2472:14]-75847[2475:3]", + "!doc": "create pending state", + "write": "deflate.!2" + }, + "tls.createRecord.!1": { + "type": { + "!type": "number", + "!span": "125363[4108:6]-125367[4108:10]" + }, + "!span": "125355[4107:37]-125510[4111:5]", + "data": "+ByteBuffer" + }, + "tls.createAlert.!1": { + "level": { + "!type": "number", + "!span": "95276[3096:10]-95281[3096:15]" + }, + "description": { + "!type": "number", + "!span": "95316[3097:10]-95327[3097:21]" + }, + "!span": "95264[3095:15]-95375[3098:9]" + }, + "tls.getClientSignature.!1": { + "!type": "fn(c: ?, signature: +ByteBuffer)", + "!span": "49436[1670:17]-50425[1706:3]", + "!doc": "create callback to handle client signature (for client-certs)" + }, + "tls.verifyCertificateChain.!1": "[+ByteBuffer|pki.certificateFromPem.!ret]", + "tls.createSessionCache.!0": { + "capacity": { + "!type": "number", + "!span": "111111[249:104144]-111119[249:104152]" + }, + "order": { + "!type": "[tls.createSessionCache.!0.|string]", + "!span": "111161[249:104194]-111166[249:104199]" + }, + "getSession": { + "!type": "fn(sessionId: string) -> tls.createSessionCache.!0.", + "!span": "111457[249:104490]-111467[249:104500]", + "!doc": "get a session from a session ID (or get any session)" + }, + "setSession": { + "!type": "fn(sessionId: string, session: tls.createSessionCache.!0.)", + "!span": "112168[249:105201]-112178[249:105211]", + "!doc": "set a session in the cache" + }, + "": { + "id": { + "!type": "string", + "!span": "125917[4125:8]-125919[4125:10]" + }, + "!span": "112513[249:105546]-112516[249:105549]", + "!doc": "only need to preserve session ID, version, and security params", + "version": "initConnectionState.!1.version", + "sp": "initConnectionState.!2" + }, + "!span": "8000[298:20]-8002[298:22]", + "cache": "tls.createSessionCache.!0" + }, + "tls.createConnection.!0": { + "server": { + "!type": "bool", + "!span": "1668[49:4]-1674[49:10]" + }, + "virtualHost": { + "!type": "string", + "!span": "1861[54:4]-1872[54:15]" + }, + "error": { + "!type": "fn(c: ?, e: ?)", + "!span": "2775[87:4]-2780[87:9]" + }, + "!span": "1662[48:37]-3019[98:3]", + "sessionCache": "tls.createSessionCache.!0", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate", + "connected": "initConnectionState.!1.connected", + "tlsDataReady": "initConnectionState.!1.tlsDataReady", + "dataReady": "initConnectionState.!1.dataReady", + "closed": "initConnectionState.!1.closed" + }, + "initConnectionState.!0": "+DataBuffer", + "initConnectionState.!1": { + "version": { + "major": { + "!type": "number", + "!span": "115468[3775:17]-115473[3775:22]" + }, + "minor": { + "!type": "number", + "!span": "115494[3775:43]-115499[3775:48]" + }, + "!span": "113691[3718:4]-113698[3718:11]", + "!doc": "only update version on connection, session version not yet set" + }, + "entity": { + "!type": "number", + "!span": "113758[3719:4]-113764[3719:10]" + }, + "cipherSuites": { + "!type": "[?]", + "!span": "113866[3723:4]-113878[3723:16]", + "!doc": "setup default cipher suites" + }, + "connected": { + "!type": "fn(c: ?|initConnectionState.!1)", + "!span": "113898[3724:4]-113907[3724:13]" + }, + "virtualHost": { + "!type": "string", + "!span": "113932[3725:4]-113943[3725:15]" + }, + "verifyClient": { + "!type": "bool", + "!span": "113978[3726:4]-113990[3726:16]" + }, + "verify": { + "!type": "fn(c: ?|initConnectionState.!1, verified: ?, depth: number, certs: [+ByteBuffer|pki.certificateFromPem.!ret]) -> !1", + "!span": "114027[3727:4]-114033[3727:10]", + "!doc": "A default certificate verify function that checks a certificate common\nname against the client's URL host.\n\n@param c the TLS connection.\n@param verified true if cert is verified, otherwise alert number.\n@param depth the chain depth.\n@param certs the cert chain.\n\n@return true if verified and the common name matches the host, error\n otherwise." + }, + "getSignature": { + "!type": "fn(c: ?, b: ?, callback: fn(c: ?, signature: +ByteBuffer))", + "!span": "114251[3731:4]-114263[3731:16]", + "!doc": "create default signing function as necessary" + }, + "tlsDataReady": { + "!type": "fn(c: ?)", + "!span": "114414[3735:4]-114426[3735:16]" + }, + "dataReady": { + "!type": "fn(c: initConnectionState.!1)", + "!span": "114454[3736:4]-114463[3736:13]" + }, + "closed": { + "!type": "fn(c: initConnectionState.!1)", + "!span": "114538[3738:4]-114544[3738:10]" + }, + "error": { + "!type": "fn(c: ?, ex: ?)", + "!span": "114566[3739:4]-114571[3739:9]" + }, + "deflate": { + "!type": "fn(bytes: ?)", + "!span": "115188[3765:4]-115195[3765:11]" + }, + "inflate": { + "!type": "fn(bytes: ?) -> string", + "!span": "115226[3766:4]-115233[3766:11]" + }, + "session": { + "extensions": { + "server_name": { + "serverNameList": { + "!type": "[?]", + "!span": "59895[2038:12]-59909[2038:26]" + }, + "!span": "59868[2037:10]-59879[2037:21]" + }, + "!span": "59844[2036:8]-59854[2036:18]" + }, + "compressionMethod": { + "!type": "number", + "!span": "59972[2042:8]-59989[2042:25]", + "!doc": "no compression" + }, + "resuming": { + "!type": "bool", + "!span": "30337[1016:14]-30345[1016:22]" + }, + "id": { + "!type": "string", + "!span": "30684[1030:12]-30686[1030:14]", + "!doc": "update session" + }, + "certificateRequest": { + "!span": "44644[1500:12]-44662[1500:30]", + "!doc": "save certificate request in session", + "certificate_types": "+ByteBuffer", + "certificate_authorities": "+ByteBuffer" + }, + "clientHelloVersion": { + "major": { + "!type": "number", + "!span": "82459[2709:4]-82464[2709:9]" + }, + "minor": { + "!type": "number", + "!span": "82487[2710:4]-82492[2710:9]" + }, + "!span": "32145[1080:12]-32163[1080:30]", + "!doc": "save hello version" + }, + "!span": "115548[3777:6]-115555[3777:13]", + "!doc": "set up session", + "version": "initConnectionState.!1.version", + "md5": "hash.!0", + "sha1": "rsa_mgf1.!2", + "sp": "initConnectionState.!2" + }, + "state": { + "!span": "115600[3779:6]-115605[3779:11]", + "pending": "tls.createConnectionState.!ret", + "current": "tls.createConnectionState.!ret" + }, + "expect": { + "!type": "number", + "!span": "115664[3783:6]-115670[3783:12]", + "!doc": "expect application data next" + }, + "records": { + "!type": "[H5.!1]", + "!span": "115757[3785:6]-115764[3785:13]" + }, + "open": { + "!type": "bool", + "!span": "115777[3786:6]-115781[3786:10]", + "!doc": "connection no longer open, clear input" + }, + "handshakes": { + "!type": "number", + "!span": "115797[3787:6]-115807[3787:16]" + }, + "handshaking": { + "!type": "bool", + "!span": "115819[3788:6]-115830[3788:17]", + "!doc": "now handshaking" + }, + "isConnected": { + "!type": "bool", + "!span": "115846[3789:6]-115857[3789:17]", + "!doc": "now connected" + }, + "fail": { + "!type": "bool", + "!span": "115873[3790:6]-115877[3790:10]", + "!doc": "set fail flag" + }, + "reset": { + "!type": "fn(clearFail: bool)", + "!span": "115421[3774:4]-115426[3774:9]", + "!doc": "Resets a closed TLS connection for reuse. Called in c.close().\n\n@param clearFail true to clear the fail flag (default: true)." + }, + "handshake": { + "!type": "fn(sessionId: string)", + "!span": "120270[3937:4]-120279[3937:13]", + "!doc": "Performs a handshake using the TLS Handshake Protocol, as a client.\n\nThis method should only be called if the connection is in client mode.\n\n@param sessionId the session ID to use, null to start a new one." + }, + "process": { + "!type": "fn(data: string) -> number", + "!span": "122850[4029:4]-122857[4029:11]", + "!doc": "Called when TLS protocol data has been received from somewhere and should\nbe processed by the TLS engine.\n\n@param data the TLS protocol data, as a string, to process.\n\n@return 0 if the data could be processed, otherwise the number of bytes\n required for data to be processed." + }, + "prepare": { + "!type": "fn(data: string)", + "!span": "124204[4076:4]-124211[4076:11]", + "!doc": "Requests that application data be packaged into a TLS record. The\ntlsDataReady handler will be called when the TLS record(s) have been\nprepared.\n\n@param data the application data, as a raw 'binary' encoded string, to\n be sent; to send utf-16/utf-8 string data, use the return value\n of util.encodeUtf8(str).\n\n@return true on success, false on failure." + }, + "prepareHeartbeatRequest": { + "!type": "fn(payload: ?, payloadLength: ?)", + "!span": "125034[4099:4]-125057[4099:27]", + "!doc": "Requests that a heartbeat request be packaged into a TLS record for\ntransmission. The tlsDataReady handler will be called when TLS record(s)\nhave been prepared.\n\nWhen a heartbeat response has been received, the heartbeatReceived\nhandler will be called with the matching payload. This handler can\nbe used to clear a retransmission timer, etc.\n\n@param payload the heartbeat data to send as the payload in the message.\n@param [payloadLength] the payload length to use, defaults to the\n actual payload length.\n\n@return true on success, false on failure." + }, + "close": { + "!type": "fn(clearFail: bool)", + "!span": "125690[4120:4]-125695[4120:9]", + "!doc": "Closes the connection (sends a close_notify alert).\n\n@param clearFail true to clear the fail flag (default: true)." + }, + "!span": "113685[3717:10]-115262[3767:3]", + "!doc": "create TLS connection", + "sessionCache": "tls.createSessionCache.!0", + "input": "+ByteBuffer", + "tlsData": "+ByteBuffer", + "data": "+ByteBuffer", + "record": "hmac_sha1.!2", + "fragmented": "hmac_sha1.!2" + }, + "initConnectionState.!1.error.!1": { + "send": { + "!type": "bool", + "!span": "110177[3577:8]-110181[3577:12]" + }, + "alert": { + "level": { + "!type": "number", + "!span": "110432[3589:8]-110437[3589:13]" + }, + "!span": "110197[3578:8]-110202[3578:13]" + }, + "origin": { + "!type": "string", + "!span": "114631[3741:9]-114637[3741:15]", + "!doc": "set origin if not set" + }, + "!span": "110167[3576:12]-110312[3582:7]", + "!doc": "build tls error if not already customized" + }, + "initConnectionState.!2": { + "entity": { + "!type": "number", + "!span": "28164[939:4]-28170[939:10]" + }, + "prf_algorithm": { + "!type": "number", + "!span": "28186[940:4]-28199[940:17]" + }, + "compression_algorithm": { + "!type": "number", + "!span": "28472[950:4]-28493[950:25]" + }, + "!span": "28158[938:17]-28636[955:3]", + "!doc": "create new security parameters", + "keys": "tls.generateKeys.!ret" + }, + "encrypt_aes_cbc_sha1.!0": {}, + "decrypt_aes_cbc_sha1.!0": { + "fragment": "+ByteBuffer" + }, + "asn1.create.!4": { + "!span": "20489[621:61]-20535[623:3]", + "!doc": "add BIT STRING contents if available" + }, + "asn1.create.!ret": { + "tagClass": { + "!type": "number", + "!span": "8212[212:4]-8220[212:12]" + }, + "type": { + "!type": "number", + "!span": "8236[213:4]-8240[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8252[214:4]-8263[214:15]" + }, + "composed": { + "!type": "bool", + "!span": "8282[215:4]-8290[215:12]" + }, + "read": { + "!type": "number", + "!span": "19652[653:42]-19656[655:1]" + }, + "original": "_fromDer.!ret" + }, + "asn1.validate.!1": { + "name": { + "!type": "string", + "!span": "12601[409:2]-12605[409:6]" + }, + "tagClass": { + "!type": "number", + "!span": "12637[410:2]-12645[410:10]" + }, + "type": { + "!type": "number", + "!span": "12671[411:2]-12675[411:6]" + }, + "constructed": { + "!type": "bool", + "!span": "12699[412:2]-12710[412:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "12720[413:2]-12731[413:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "12777[415:4]-12781[415:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12823[416:4]-12831[416:12]" + }, + "type": { + "!type": "number", + "!span": "12859[417:4]-12863[417:8]" + }, + "constructed": { + "!type": "bool", + "!span": "12888[418:4]-12899[418:15]" + }, + "capture": { + "!type": "string", + "!span": "12912[419:4]-12919[419:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13002[422:4]-13006[422:8]", + "!doc": "Name (subject) (RDNSequence)" + }, + "tagClass": { + "!type": "number", + "!span": "13048[423:4]-13056[423:12]" + }, + "type": { + "!type": "number", + "!span": "13084[424:4]-13088[424:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13114[425:4]-13125[425:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "13137[426:4]-13148[426:15]" + } + }, + "2": "publicKeyValidator", + "3": { + "name": { + "!type": "string", + "!span": "13245[431:4]-13249[431:8]" + }, + "tagClass": { + "!type": "number", + "!span": "13294[432:4]-13302[432:12]" + }, + "type": { + "!type": "number", + "!span": "13337[433:4]-13341[433:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13350[434:4]-13361[434:15]" + }, + "optional": { + "!type": "bool", + "!span": "13373[435:4]-13381[435:12]" + }, + "capture": { + "!type": "string", + "!span": "13393[436:4]-13400[436:11]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "13460[438:6]-13464[438:10]" + }, + "tagClass": { + "!type": "number", + "!span": "13511[439:6]-13519[439:14]" + }, + "type": { + "!type": "number", + "!span": "13549[440:6]-13553[440:10]" + }, + "constructed": { + "!type": "bool", + "!span": "13581[441:6]-13592[441:17]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "13624[443:8]-13628[443:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13682[444:8]-13690[444:16]" + }, + "type": { + "!type": "number", + "!span": "13722[445:8]-13726[445:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13751[446:8]-13762[446:19]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "13789[448:8]-13793[448:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13848[449:8]-13856[449:16]" + }, + "type": { + "!type": "number", + "!span": "13888[450:8]-13892[450:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13917[451:8]-13928[451:19]" + } + } + } + } + } + } + } + }, + "asn1.validate.!2": { + "!span": "51043[1649:16]-51045[1649:18]", + "!doc": "validate certification request and capture data" + }, + "asn1.validate.!3": "[string]", + "asn1.prettyPrint.!0": { + "tagClass": { + "!type": "number", + "!span": "9228[254:4]-9236[254:12]" + }, + "type": { + "!type": "number", + "!span": "9256[255:4]-9260[255:8]" + }, + "constructed": { + "!type": "bool", + "!span": "9276[256:4]-9287[256:15]" + }, + "composed": { + "!type": "bool", + "!span": "9310[257:4]-9318[257:12]" + }, + "!span": "9222[253:9]-9378[259:3]" + }, + "_fromDer.!ret": { + "tagClass": { + "!type": "number", + "!span": "8212[212:4]-8220[212:12]" + }, + "type": { + "!type": "number", + "!span": "8236[213:4]-8240[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8252[214:4]-8263[214:15]" + }, + "composed": { + "!type": "bool", + "!span": "8282[215:4]-8290[215:12]" + }, + "read": { + "!type": "number", + "!span": "19652[653:42]-19656[655:1]" + }, + "!span": "8206[211:12]-8354[217:3]", + "!doc": "TODO: add readonly flag to avoid this overhead\nsave copy to detect changes", + "original": "_fromDer.!ret" + }, + "BlockCipher.!0": { + "key": { + "!type": "string", + "!span": "2009[76:4]-2012[76:7]" + }, + "decrypt": { + "!type": "bool", + "!span": "2023[77:4]-2030[77:11]" + }, + "!span": "1983[74:38]-2040[78:3]" + }, + "modes.ecb.prototype.unpad.!1": { + "decrypt": { + "!type": "bool", + "!span": "6102[201:10]-6109[201:17]" + }, + "overflow": { + "!type": "number", + "!span": "6182[204:10]-6190[204:18]", + "!doc": "get # of bytes that won't fill a block" + }, + "!span": "6088[200:16]-6090[200:18]", + "!doc": "build options for padding and afterFinish functions" + }, + "modes.ecb.!0": { + "blockSize": { + "!type": "number", + "!span": "4691[159:4]-4700[159:13]" + }, + "!span": "4685[158:23]-4968[168:3]", + "cipher": { + "encrypt": "modes.gcm.cipher.encrypt", + "decrypt": "modes.gcm.cipher.decrypt" + } + }, + "modes.cfb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "6987[257:10]-6991[257:14]" + } + }, + "modes.cfb.prototype.decrypt.!0": { + "read": { + "!type": "number", + "!span": "8719[317:10]-8723[317:14]" + } + }, + "modes.ofb.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "11014[400:10]-11018[400:14]" + } + }, + "modes.ctr.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "13308[482:12]-13312[482:16]" + } + }, + "modes.gcm.prototype.encrypt.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "modes.gcm.prototype.multiply.!0": "[number]", + "modes.gcm.prototype.multiply.!ret": "[number]", + "modes.gcm.prototype.pow.!1": "[number]", + "modes.gcm.prototype.ghash.!1": "[number]", + "publicKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "!type": "[publicKeyValidator.value.0.value.]", + "!span": "6506[241:4]-6511[241:9]" + }, + "!span": "6357[236:10]-6692[248:3]" + }, + "publicKeyValidator.value.0.value.": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + }, + "!span": "6514[241:12]-6687[247:5]" + }, + "publicKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "!type": "[publicKeyValidator.value.1.value.]", + "!span": "6866[254:4]-6871[254:9]" + }, + "!span": "6694[248:5]-7125[263:3]" + }, + "publicKeyValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + }, + "!span": "6874[254:12]-7120[262:5]" + }, + "privateKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "2795[103:4]-2799[103:8]", + "!doc": "Version (INTEGER)" + }, + "tagClass": { + "!type": "number", + "!span": "2831[104:4]-2839[104:12]" + }, + "type": { + "!type": "number", + "!span": "2867[105:4]-2871[105:8]" + }, + "constructed": { + "!type": "bool", + "!span": "2896[106:4]-2907[106:15]" + }, + "capture": { + "!type": "string", + "!span": "2920[107:4]-2927[107:11]" + }, + "!span": "2764[101:10]-2952[108:3]" + }, + "privateKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "2987[110:4]-2991[110:8]", + "!doc": "privateKeyAlgorithm" + }, + "tagClass": { + "!type": "number", + "!span": "3035[111:4]-3043[111:12]" + }, + "type": { + "!type": "number", + "!span": "3071[112:4]-3075[112:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3101[113:4]-3112[113:15]" + }, + "value": { + "!type": "[privateKeyValidator.value.1.value.]", + "!span": "3124[114:4]-3129[114:9]" + }, + "!span": "2954[108:5]-3311[121:3]" + }, + "privateKeyValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "3140[115:6]-3144[115:10]" + }, + "tagClass": { + "!type": "number", + "!span": "3185[116:6]-3193[116:14]" + }, + "type": { + "!type": "number", + "!span": "3223[117:6]-3227[117:10]" + }, + "constructed": { + "!type": "bool", + "!span": "3250[118:6]-3261[118:17]" + }, + "capture": { + "!type": "string", + "!span": "3276[119:6]-3283[119:13]" + }, + "!span": "3132[114:12]-3306[120:5]" + }, + "privateKeyValidator.value.2": { + "name": { + "!type": "string", + "!span": "3337[123:4]-3341[123:8]", + "!doc": "PrivateKey" + }, + "tagClass": { + "!type": "number", + "!span": "3365[124:4]-3373[124:12]" + }, + "type": { + "!type": "number", + "!span": "3401[125:4]-3405[125:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3434[126:4]-3445[126:15]" + }, + "capture": { + "!type": "string", + "!span": "3458[127:4]-3465[127:11]" + }, + "!span": "3313[121:5]-3483[128:3]" + }, + "ed25519.generateKeyPair.!0": { + "!span": "5338[164:42]-5356[164:60]", + "seed": "+Float32Array" + }, + "ed25519.generateKeyPair.!ret": { + "!span": "2129[66:9]-2160[66:40]", + "publicKey": "+Float32Array", + "privateKey": "+Float32Array" + }, + "ed25519.privateKeyFromAsn1.!ret": { + "!span": "3458[102:9]-3492[102:43]" + }, + "add.!0": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "cswap.!0": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "cswap.!1": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "pack.!1": "[+Float32Array, +Float32Array, +Float32Array, +Float32Array]", + "gf.!0": "[number]", + "form.serialize.!ret": { + "!span": "3658[137:13]-3660[137:15]" + }, + "hmac.create.!ret": { + "start": { + "!type": "fn(md: string|hash.!0, key: ?)", + "!span": "1135[45:6]-1140[45:11]", + "!doc": "Starts or restarts the HMAC with the given key and message digest.\n\n@param md the message digest to use, null to reuse the previous one,\n a string to use builtin 'sha1', 'md5', 'sha256'.\n@param key the key to use as a string, array of bytes, byte buffer,\n or null to reuse the previous key." + }, + "update": { + "!type": "fn(bytes: ?)", + "!span": "3312[123:6]-3318[123:12]", + "!doc": "Updates the HMAC with the given message bytes.\n\n@param bytes the bytes to update with." + }, + "getMac": { + "!type": "fn() -> +ByteBuffer", + "!span": "3500[132:6]-3506[132:12]", + "!doc": "Produces the Message Authentication Code (MAC).\n\n@return a byte buffer containing the digest value." + }, + "!span": "774[35:12]-776[35:14]", + "!doc": "hmac context", + "digest": "hmac.create.!ret.getMac" + }, + "http.createClient.!0": { + "url": { + "!type": "string", + "!span": "12551[397:8]-12554[397:11]" + }, + "policyPort": { + "!type": "number", + "!span": "12602[399:8]-12612[399:18]" + }, + "connections": { + "!type": "number", + "!span": "12709[401:8]-12720[401:19]" + }, + "persistCookies": { + "!type": "bool", + "!span": "12848[404:8]-12862[404:22]" + }, + "primeTlsSockets": { + "!type": "bool", + "!span": "12904[405:8]-12919[405:23]" + }, + "!span": "12541[396:40]-13131[410:7]", + "socketPool": "net.socketPools." + }, + "http.createClient.!ret": { + "policyPort": { + "!type": "number", + "!span": "13207[467:4]-13217[467:14]", + "!doc": "the policy port to use" + }, + "secure": { + "!type": "bool", + "!span": "13475[477:4]-13481[477:10]", + "!doc": "whether or not the connections are secure" + }, + "persistCookies": { + "!type": "bool", + "!span": "13717[482:4]-13731[482:18]", + "!doc": "default to flash storage of cookies" + }, + "getCookie": {}, + "url": "http.parseUrl.!ret", + "socketPool": "net.socketPools.", + "requests": { + "": "net.socketPools..sockets..options" + }, + "sockets": { + "": "net.socketPools..sockets." + }, + "idle": { + "": "net.socketPools..sockets." + }, + "cookies": "_getStorageId.!0.cookies", + "send": {}, + "destroy": "_getStorageId.!0.destroy", + "setCookie": "_getStorageId.!0.setCookie", + "removeCookie": "_getStorageId.!0.removeCookie", + "clearCookies": "_getStorageId.!0.clearCookies" + }, + "http.createClient.!ret.getCookie.!ret": { + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]" + }, + "maxAge": { + "!type": "number", + "!span": "20252[674:15]-20258[674:21]" + }, + "secure": { + "!type": "bool", + "!span": "20296[675:15]-20302[675:21]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[677:15]-20402[677:23]" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "http.createRequest.!0": { + "!span": "14846[469:40]-14891[472:5]" + }, + "http.parseUrl.!ret": { + "scheme": { + "!type": "string", + "!span": "59506[2274:4]-59512[2274:10]" + }, + "host": { + "!type": "string", + "!span": "59524[2275:4]-59528[2275:8]" + }, + "path": { + "!type": "string", + "!span": "59556[2277:4]-59560[2277:8]" + }, + "fullHost": { + "!type": "string", + "!span": "59592[2280:8]-59600[2280:16]" + }, + "!span": "59485[2272:34]-59570[2278:3]", + "!doc": "url" + }, + "http.withinCookieDomain.!1": { + "name": { + "!type": "string", + "!span": "36485[1250:22]-36489[1250:26]" + }, + "value": { + "!type": "string", + "!span": "36520[1251:22]-36525[1251:27]" + }, + "maxAge": { + "!type": "number", + "!span": "36921[1261:24]-36927[1261:30]" + }, + "secure": { + "!type": "bool", + "!span": "37142[1267:24]-37148[1267:30]" + }, + "httpOnly": { + "!type": "bool", + "!span": "37237[1270:24]-37245[1270:32]" + }, + "": { + "!type": "string", + "!span": "37363[1274:26]-37367[1274:30]" + }, + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]", + "!doc": "set cookie defaults" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + }, + "!span": "36239[1241:22]-36241[1241:24]", + "!doc": "cookie may be null, a cookie object, or a domain string" + }, + "_getStorageId.!0": { + "policyPort": { + "!type": "number", + "!span": "13207[467:4]-13217[467:14]", + "!doc": "the policy port to use" + }, + "requests": { + "!type": "[net.socketPools..sockets..options]", + "!span": "13338[471:4]-13346[471:12]", + "!doc": "clear pending requests, close and destroy sockets" + }, + "sockets": { + "!type": "[net.socketPools..sockets.|forge.tls.wrapSocket.!ret]", + "!span": "13375[473:4]-13382[473:11]", + "!doc": "all sockets" + }, + "idle": { + "!type": "[net.socketPools..sockets.|forge.tls.wrapSocket.!ret]", + "!span": "13412[475:4]-13416[475:8]", + "!doc": "idle sockets" + }, + "secure": { + "!type": "bool", + "!span": "13475[477:4]-13481[477:10]", + "!doc": "whether or not the connections are secure" + }, + "cookies": { + "": { + "!span": "21338[702:25]-21349[702:36]", + "!doc": "get cookie paths", + "": "http.withinCookieDomain.!1" + }, + "!span": "13657[480:4]-13664[480:11]", + "!doc": "cookie jar (key'd off of name and then path, there is only 1 domain\nand one setting for secure per client so name+path is unique)" + }, + "persistCookies": { + "!type": "bool", + "!span": "13717[482:4]-13731[482:18]", + "!doc": "default to flash storage of cookies" + }, + "send": { + "!type": "fn(options: _getStorageId.!0.send.!0)", + "!span": "16404[562:9]-16408[562:13]", + "!doc": "Sends a request. A method 'abort' will be set on the request that\ncan be called to attempt to abort the request.\n\n@param options:\n request: the request to send.\n connected: a callback for when the connection is open.\n closed: a callback for when the connection is closed.\n headerReady: a callback for when the response header arrives.\n bodyReady: a callback for when the response body arrives.\n error: a callback for if an error occurs." + }, + "destroy": { + "!type": "fn()", + "!span": "18426[630:9]-18433[630:16]", + "!doc": "Destroys this client." + }, + "setCookie": { + "!type": "fn(cookie: http.withinCookieDomain.!1) -> bool", + "!span": "19861[664:9]-19870[664:18]", + "!doc": "Sets a cookie for use with all connections made by this client. Any\ncookie with the same name will be replaced. If the cookie's value\nis undefined, null, or the blank string, the cookie will be removed.\n\nIf the cookie's domain doesn't match this client's url host or the\ncookie's secure flag doesn't match this client's url scheme, then\nsetting the cookie will fail with an exception.\n\n@param cookie the cookie with parameters:\n name: the name of the cookie.\n value: the value of the cookie.\n comment: an optional comment string.\n maxAge: the age of the cookie in seconds relative to created time.\n secure: true if the cookie must be sent over a secure protocol.\n httpOnly: true to restrict access to the cookie from javascript\n (inaffective since the cookies are stored in javascript).\n path: the path for the cookie.\n domain: optional domain the cookie belongs to (must start with dot).\n version: optional version of the cookie.\n created: creation time, in UTC seconds, of the cookie." + }, + "getCookie": { + "!type": "fn(name: ?, path: ?) -> _getStorageId.!0.getCookie.!ret", + "!span": "21837[724:9]-21846[724:18]", + "!doc": "Gets a cookie by its name.\n\n@param name the name of the cookie to retrieve.\n@param path an optional path for the cookie (if there are multiple\n cookies with the same name but different paths).\n\n@return the cookie or null if not found." + }, + "removeCookie": { + "!type": "fn(name: ?, path: string) -> bool", + "!span": "22547[754:9]-22559[754:21]", + "!doc": "Removes a cookie.\n\n@param name the name of the cookie to remove.\n@param path an optional path for the cookie (if there are multiple\n cookies with the same name but different paths).\n\n@return true if a cookie was removed, false if not." + }, + "clearCookies": { + "!type": "fn()", + "!span": "23383[789:9]-23395[789:21]", + "!doc": "Clears all cookies stored in this client." + }, + "!span": "13107[461:15]-13823[484:3]", + "url": "http.parseUrl.!ret", + "socketPool": "net.socketPools." + }, + "_getStorageId.!0.send.!0": { + "headerReady": { + "!type": "fn(e: net.socketPools..sockets..options.headerReady.!0)", + "!span": "17078[553:12]-17089[553:23]" + }, + "!span": "17024[551:18]-17026[551:20]", + "!doc": "create send options", + "request": "net.socketPools..sockets..options.request", + "bodyReady": "net.socketPools..sockets..options.bodyReady", + "error": "net.socketPools..sockets..options.error" + }, + "_getStorageId.!0.getCookie.!ret": { + "comment": { + "!type": "string", + "!span": "20205[673:15]-20212[673:22]" + }, + "maxAge": { + "!type": "number", + "!span": "20252[674:15]-20258[674:21]" + }, + "secure": { + "!type": "bool", + "!span": "20296[675:15]-20302[675:21]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[677:15]-20402[677:23]" + }, + "path": { + "!type": "string", + "!span": "20445[678:15]-20449[678:19]" + }, + "created": { + "!type": "number", + "!span": "20583[681:15]-20590[681:22]" + } + }, + "_initSocket.!2": { + "caStore": { + "certs": { + "!span": "83747[2749:4]-83752[2749:9]", + "!doc": "stored certificates" + }, + "getIssuer": { + "!type": "fn(cert: +ByteBuffer|pki.certificateFromPem.!ret) -> [?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret", + "!span": "83997[2760:10]-84006[2760:19]", + "!doc": "Gets the certificate that issued the passed certificate or its\n'parent'.\n\n@param cert the certificate to get the parent for.\n\n@return the parent certificate or null if none was found." + }, + "addCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret)", + "!span": "84709[2781:10]-84723[2781:24]", + "!doc": "Adds a trusted certificate to the store.\n\n@param cert the certificate to add as a trusted certificate (either a\n pki.certificate object or a PEM-formatted certificate)." + }, + "hasCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret|+ByteBuffer) -> bool", + "!span": "85652[2812:10]-85666[2812:24]", + "!doc": "Checks to see if the given certificate is in the store.\n\n@param cert the certificate to check (either a pki.certificate or a\n PEM-formatted certificate).\n\n@return true if the certificate is in the store, false if not." + }, + "listAllCertificates": { + "!type": "fn() -> [[?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret]", + "!span": "86435[2841:10]-86454[2841:29]", + "!doc": "Lists all of the certificates kept in the store.\n\n@return an array of all of the pki.certificate objects in the store." + }, + "removeCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret) -> [?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret", + "!span": "87156[2869:10]-87173[2869:27]", + "!doc": "Removes a certificate from the store.\n\n@param cert the certificate to remove (either a pki.certificate or a\n PEM-formatted certificate).\n\n@return the certificate that was removed or null if the certificate\n wasn't in store." + }, + "!span": "14916[523:6]-14923[523:13]", + "!doc": "create CA store" + }, + "virtualHost": { + "!type": "string", + "!span": "14990[525:6]-15001[525:17]" + }, + "prime": { + "!type": "bool", + "!span": "15257[530:6]-15262[530:11]" + }, + "!span": "14908[522:17]-15302[531:5]", + "!doc": "determine if TLS is used", + "verify": "initConnectionState.!1.verify", + "deflate": "initConnectionState.!1.deflate", + "inflate": "initConnectionState.!1.inflate" + }, + "_initSocket.!2.caStore.listAllCertificates.!ret": "[[?|pki.certificateFromPem.!ret]|pki.certificateFromPem.!ret]", + "_hasCookieExpired.!0": { + "maxAge": { + "!type": "number", + "!span": "6000[192:9]-6006[192:15]", + "!doc": "default cookie expiration to never" + }, + "comment": { + "!type": "string", + "!span": "20205[658:0]-20212[659:6]" + }, + "secure": { + "!type": "bool", + "!span": "20296[663:3]-20302[663:9]" + }, + "httpOnly": { + "!type": "bool", + "!span": "20394[666:0]-20402[666:8]" + }, + "path": { + "!type": "string", + "!span": "20445[668:25]-20449[669:0]" + }, + "created": { + "!type": "number", + "!span": "20583[673:4]-20590[673:11]" + } + }, + "bnpExp.!1": "+NullExp", + "bnToByteArray.!ret": "[number]", + "bnpBitwiseTo.!1": { + "!type": "fn(x: number, y: number) -> number", + "!span": "20730[689:14]-20760[689:44]" + }, + "bnDivideAndRemainder.!ret": "[+BigInteger]", + "bnGetPrng.!ret": { + "nextBytes": { + "!type": "fn(x: [number])", + "!span": "32791[1198:4]-32800[1198:13]", + "!doc": "x is an array to fill with bytes" + }, + "!span": "32745[1196:9]-32926[1203:3]" + }, + "bnGetPrng.!ret.nextBytes.!0": { + "!type": "[number]", + "!doc": "new BigInteger(int,RNG)" + }, + "_createKDF.!1": { + "algorithm": { + "!type": "string", + "!span": "2315[98:4]-2324[98:13]", + "!doc": "SHA-512 => sha512" + }, + "blockLength": { + "!type": "number", + "!span": "2372[99:4]-2383[99:15]" + }, + "digestLength": { + "!type": "number", + "!span": "2394[100:4]-2406[100:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "2543[104:4]-2560[104:21]", + "!doc": "full message length (set md.messageLength128 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "2611[106:4]-2628[106:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> _createKDF.!1", + "!span": "2718[114:5]-2723[114:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: string) -> _createKDF.!1", + "!span": "3705[144:5]-3711[144:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "4616[179:5]-4622[179:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "2284[96:11]-2636[107:3]", + "!doc": "message digest object", + "messageLength128": "_createKDF.!1.fullMessageLength" + }, + "sConsoleLogger.f.!1": { + "level": { + "!type": "string", + "!span": "4854[155:10]-4859[155:15]" + }, + "standard": { + "!type": "string", + "!span": "3143[102:12]-3151[102:20]" + }, + "standardFull": { + "!type": "string", + "!span": "4125[136:12]-4137[136:24]" + }, + "timestamp": "+Date", + "arguments": "f.!1.arguments" + }, + "f.!1": { + "level": { + "!type": "string", + "!span": "4854[155:10]-4859[155:15]" + }, + "arguments": { + "!type": "[?]", + "!span": "4936[158:10]-4947[158:21]", + "!doc": "convert arguments to real array, remove category and message" + }, + "standard": { + "!type": "string", + "!span": "3143[102:12]-3151[102:20]" + }, + "standardFull": { + "!type": "string", + "!span": "4125[136:12]-4137[136:24]" + }, + "!span": "4809[153:18]-5031[162:9]", + "!doc": "create message object\nNote: interpolation and standard formatting is done lazily", + "timestamp": "+Date" + }, + "md5.create.!ret": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "hash.!0.fullMessageLength", + "fullMessageLength": "hash.!0.fullMessageLength", + "start": "hash.!0.start", + "update": "hash.!0.update", + "digest": "hash.!0.digest" + }, + "_update.!1": { + "!type": "[[number]|number]", + "!doc": "used for 64-bit word storage" + }, + "mgf1.create.!ret": { + "generate": { + "!type": "fn(seed: string, maskLen: ?) -> string", + "!span": "833[31:4]-841[31:12]", + "!doc": "Generate mask of specified length.\n\n@param {String} seed The seed for mask generation.\n@param maskLen Number of bytes to generate.\n@return {String} The generated mask." + }, + "!span": "609[23:12]-1625[53:3]" + }, + "pki.encryptPrivateKeyInfo.!2": { + "legacy": { + "!type": "bool", + "!span": "4915[152:5]-4921[152:11]" + }, + "algorithm": { + "!type": "string", + "!span": "4929[152:19]-4938[152:28]" + }, + "saltSize": { + "!type": "number", + "!span": "6295[196:28]-6303[196:36]" + }, + "count": { + "!type": "number", + "!span": "6339[198:30]-6344[198:35]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[202:5]-6445[202:17]" + }, + "!span": "4914[152:4]-4949[152:39]" + }, + "pki.privateKeyFromPem.!0": { + "read": { + "!type": "number", + "!span": "19652[656:10]-19656[656:14]" + }, + "n": "+BigInteger", + "e": "+BigInteger", + "d": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "decrypt": "_modPow.!1.decrypt", + "sign": "_modPow.!1.sign" + }, + "pki.RDNAttributesAsArray.!1": { + "algorithm": { + "!type": "string", + "!span": "753[36:4]-762[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "776[37:4]-787[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "797[38:4]-809[38:16]" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1004[44:4]-1021[44:21]", + "!doc": "size of message length in bytes" + }, + "messageLength64": "rsa_mgf1.!2.fullMessageLength", + "fullMessageLength": "rsa_mgf1.!2.fullMessageLength", + "start": "rsa_mgf1.!2.start", + "update": "rsa_mgf1.!2.update", + "digest": "rsa_mgf1.!2.digest" + }, + "pki.RDNAttributesAsArray.!ret": "[pki.RDNAttributesAsArray.!ret.]", + "pki.RDNAttributesAsArray.!ret.": { + "type": { + "!type": "string", + "!span": "15894[517:10]-15898[517:14]" + }, + "name": { + "!type": "string", + "!span": "16121[522:12]-16125[522:16]" + }, + "!span": "15853[515:12]-15855[515:14]", + "!doc": "iterate over attributes" + }, + "pki.CRIAttributesAsArray.!0": "[?]", + "pki.CRIAttributesAsArray.!ret": { + "": { + "type": { + "!type": "string", + "!span": "17085[558:10]-17089[558:14]" + }, + "name": { + "!type": "string", + "!span": "17276[563:12]-17280[563:16]" + }, + "extensions": { + "": "pki.certificateExtensionFromAsn1.!ret" + } + }, + "!type": "[_getAttribute.!ret]", + "!doc": "each attribute has a sequence with a type and a set of values" + }, + "pki.certificateFromPem.!ret": { + "version": { + "!type": "number", + "!span": "27761[914:7]-27768[914:14]" + }, + "serialNumber": { + "!type": "string", + "!span": "27784[915:7]-27796[915:19]" + }, + "signatureOid": { + "!type": "string", + "!span": "27812[916:7]-27824[916:19]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "27894[919:15]-27906[919:27]" + }, + "!span": "27865[918:7]-27872[918:14]", + "parameters": "_readSignatureParameters.!ret" + }, + "validity": { + "!span": "27922[920:7]-27930[920:15]", + "notBefore": "+Date", + "notAfter": "+Date" + }, + "issuer": { + "getField": { + "!type": "fn(sn: ?) -> _getAttribute.!ret", + "!span": "28051[925:14]-28059[925:22]" + }, + "addField": { + "!type": "fn(attr: ?)", + "!span": "28139[928:14]-28147[928:22]" + }, + "hash": { + "!type": "string", + "!span": "28288[933:14]-28292[933:18]" + }, + "!span": "28024[924:7]-28030[924:13]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "subject": { + "getField": { + "!type": "fn(sn: string) -> _getAttribute.!ret", + "!span": "28338[936:15]-28346[936:23]" + }, + "addField": { + "!type": "fn(attr: ?)", + "!span": "28428[939:15]-28436[939:23]" + }, + "hash": { + "!type": "string", + "!span": "28580[944:15]-28584[944:19]" + }, + "!span": "28309[935:7]-28316[935:14]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "setSubject": { + "!type": "fn(attrs: ?, uniqueId: ?)", + "!span": "28840[956:7]-28850[956:17]", + "!doc": "Sets the subject of this certificate.\n\n@param attrs the array of subject attributes to use.\n@param uniqueId an optional a unique ID to use." + }, + "setIssuer": { + "!type": "fn(attrs: ?, uniqueId: ?)", + "!span": "29346[974:7]-29355[974:16]", + "!doc": "Sets the issuer of this certificate.\n\n@param attrs the array of issuer attributes to use.\n@param uniqueId an optional a unique ID to use." + }, + "setExtensions": { + "!type": "fn(exts: ?)", + "!span": "29790[991:7]-29803[991:20]", + "!doc": "Sets the extensions of this certificate.\n\n@param exts the array of extensions to use." + }, + "getExtension": { + "!type": "fn(options: ?|string) -> pki.certificateExtensionFromAsn1.!ret", + "!span": "30233[1008:7]-30245[1008:19]", + "!doc": "Gets an extension by its name or id.\n\n@param options the name to use or an object with:\n name the name to use.\n id the id to use.\n\n@return the extension or null if not found." + }, + "sign": { + "!type": "fn(key: ?, md: ?)", + "!span": "30873[1032:7]-30877[1032:11]", + "!doc": "Signs this certificate using the given private key.\n\n@param key the private key to sign with.\n@param md the message digest object to use (defaults to forge.md.sha1)." + }, + "verify": { + "!type": "fn(child: +ByteBuffer|pki.certificateFromPem.!ret) -> bool", + "!span": "31818[1061:7]-31824[1061:13]", + "!doc": "Attempts verify the signature on the passed certificate using this\ncertificate's public key.\n\n@param child the certificate to verify.\n\n@return true if verified, false if not." + }, + "isIssuer": { + "!type": "fn(parent: ?) -> bool", + "!span": "35605[1176:7]-35613[1176:15]", + "!doc": "Returns true if this certificate's issuer matches the passed\ncertificate's subject. Note that no signature check is performed.\n\n@param parent the certificate to check.\n\n@return true if this certificate's issuer matches the passed certificate's\n subject." + }, + "issued": { + "!type": "fn(child: +ByteBuffer|pki.certificateFromPem.!ret) -> bool", + "!span": "36593[1211:7]-36599[1211:13]", + "!doc": "Returns true if this certificate's subject matches the issuer of the\ngiven certificate). Note that not signature check is performed.\n\n@param child the certificate to check.\n\n@return true if this certificate's subject matches the passed\n certificate's issuer." + }, + "generateSubjectKeyIdentifier": { + "!type": "fn() -> ?", + "!span": "36835[1220:7]-36863[1220:35]", + "!doc": "Generates the subjectKeyIdentifier for this certificate as byte buffer.\n\n@return the subjectKeyIdentifier for this certificate as byte buffer." + }, + "verifySubjectKeyIdentifier": { + "!type": "fn() -> bool", + "!span": "37913[1246:7]-37939[1246:33]", + "!doc": "Verifies the subjectKeyIdentifier extension value for this certificate\nagainst its public key. If no extension is found, false will be\nreturned.\n\n@return true if verified, false if not." + }, + "signatureParameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + }, + "read": { + "!type": "number", + "!span": "19652[645:18]-19656[645:22]" + }, + "!span": "27750[913:13]-27752[913:15]", + "!doc": "create certificate", + "extensions": "pki.certificateExtensionsFromAsn1.!ret", + "publicKey": "_publicKeyFromJwk.!ret", + "md": "_createKDF.!1", + "tbsCertificate": "_fromDer.!ret" + }, + "pki.getPublicKeyFingerprint.!1": { + "type": { + "!type": "string", + "!span": "37654[1236:56]-37658[1236:60]" + }, + "!span": "37653[1236:55]-37675[1236:77]" + }, + "pki.certificationRequestFromPem.!ret": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "getAttribute": {}, + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret", + "signatureParameters": "_readSignatureParameters.!ret", + "addAttribute": "_getAttribute.!0.addAttribute", + "setSubject": "_getAttribute.!0.setSubject", + "setAttributes": "_getAttribute.!0.setAttributes", + "sign": "_getAttribute.!0.sign", + "verify": "_getAttribute.!0.verify" + }, + "pki.certificateExtensionsFromAsn1.!0": { + "type": { + "!type": "number", + "!span": "49364[1597:10]-49368[1597:14]" + }, + "ip": { + "!type": "string", + "!span": "49804[1614:20]-49806[1614:22]", + "!doc": "convert to IPv4/IPv6 string representation" + }, + "oid": { + "!type": "string", + "!span": "49924[1618:20]-49927[1618:23]" + }, + "!span": "49352[1596:22]-49414[1599:9]" + }, + "pki.certificateExtensionsFromAsn1.!ret": { + "!type": "[pki.certificateExtensionFromAsn1.!ret]", + "!span": "28601[946:7]-28611[946:17]", + "!doc": "set new extensions" + }, + "pki.certificateExtensionFromAsn1.!ret": { + "id": { + "!type": "string", + "!span": "45973[1496:4]-45975[1496:6]" + }, + "critical": { + "!type": "bool", + "!span": "46017[1497:4]-46025[1497:12]" + }, + "name": { + "!type": "string", + "!span": "46294[1506:6]-46298[1506:10]" + }, + "digitalSignature": { + "!type": "bool", + "!span": "46788[1522:8]-46804[1522:24]", + "!doc": "set flags" + }, + "nonRepudiation": { + "!type": "bool", + "!span": "46837[1523:8]-46851[1523:22]" + }, + "keyEncipherment": { + "!type": "bool", + "!span": "46884[1524:8]-46899[1524:23]" + }, + "dataEncipherment": { + "!type": "bool", + "!span": "46932[1525:8]-46948[1525:24]" + }, + "keyAgreement": { + "!type": "bool", + "!span": "46981[1526:8]-46993[1526:20]" + }, + "keyCertSign": { + "!type": "bool", + "!span": "47026[1527:8]-47037[1527:19]" + }, + "cRLSign": { + "!type": "bool", + "!span": "47070[1528:8]-47077[1528:15]" + }, + "encipherOnly": { + "!type": "bool", + "!span": "47110[1529:8]-47122[1529:20]" + }, + "decipherOnly": { + "!type": "bool", + "!span": "47155[1530:8]-47167[1530:20]" + }, + "cA": { + "!type": "bool", + "!span": "47475[1537:10]-47477[1537:12]" + }, + "pathLenConstraint": { + "!type": "number", + "!span": "47857[1549:10]-47874[1549:27]" + }, + "": { + "!type": "bool", + "!span": "48199[1558:12]-48208[1558:21]" + }, + "client": { + "!type": "bool", + "!span": "48680[1575:8]-48686[1575:14]", + "!doc": "set flags" + }, + "server": { + "!type": "bool", + "!span": "48719[1576:8]-48725[1576:14]" + }, + "email": { + "!type": "bool", + "!span": "48758[1577:8]-48763[1577:13]" + }, + "objsign": { + "!type": "bool", + "!span": "48796[1578:8]-48803[1578:15]" + }, + "reserved": { + "!type": "bool", + "!span": "48836[1579:8]-48844[1579:16]" + }, + "sslCA": { + "!type": "bool", + "!span": "48877[1580:8]-48882[1580:13]" + }, + "emailCA": { + "!type": "bool", + "!span": "48915[1581:8]-48922[1581:15]" + }, + "objCA": { + "!type": "bool", + "!span": "48955[1582:8]-48960[1582:13]" + }, + "altNames": { + "!type": "[pki.certificateExtensionsFromAsn1.!0]", + "!span": "49126[1587:8]-49134[1587:16]", + "!doc": "handle subjectAltName/issuerAltName" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "50253[1628:8]-50273[1628:28]" + }, + "!span": "45965[1495:10]-45967[1495:12]", + "!doc": "an extension has:\n[0] extnID OBJECT IDENTIFIER\n[1] critical BOOLEAN DEFAULT FALSE\n[2] extnValue OCTET STRING" + }, + "pki.distinguishedNameToAsn1.!0": { + "!span": "30074[961:40]-30098[961:64]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "pki.verifyCertificateChain.!2": { + "verify": { + "!type": "fn(vfd: bool|string, depth: number, chain: [+ByteBuffer|pki.certificateFromPem.!ret]) -> bool|string", + "!span": "108939[3537:12]-108945[3537:18]" + }, + "!span": "108834[3532:18]-108836[3532:20]", + "!doc": "Make a copy of c.verifyOptions so that we can modify options.verify\nwithout modifying c.verifyOptions." + }, + "encryptedPrivateKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "1319[52:4]-1323[52:8]" + }, + "tagClass": { + "!type": "number", + "!span": "1376[53:4]-1384[53:12]" + }, + "type": { + "!type": "number", + "!span": "1412[54:4]-1416[54:8]" + }, + "constructed": { + "!type": "bool", + "!span": "1442[55:4]-1453[55:15]" + }, + "value": { + "!type": "[encryptedPrivateKeyValidator.value.0.value.0, encryptedPrivateKeyValidator.value.0.value.1]", + "!span": "1465[56:4]-1470[56:9]" + }, + "!span": "1313[51:10]-1840[69:3]" + }, + "encryptedPrivateKeyValidator.value.0.value.0": { + "name": { + "!type": "string", + "!span": "1481[57:6]-1485[57:10]" + }, + "tagClass": { + "!type": "number", + "!span": "1526[58:6]-1534[58:14]" + }, + "type": { + "!type": "number", + "!span": "1564[59:6]-1568[59:10]" + }, + "constructed": { + "!type": "bool", + "!span": "1591[60:6]-1602[60:17]" + }, + "capture": { + "!type": "string", + "!span": "1617[61:6]-1624[61:13]" + }, + "!span": "1473[56:12]-1647[62:5]" + }, + "encryptedPrivateKeyValidator.value.0.value.1": { + "name": { + "!type": "string", + "!span": "1657[63:6]-1661[63:10]" + }, + "tagClass": { + "!type": "number", + "!span": "1703[64:6]-1711[64:14]" + }, + "type": { + "!type": "number", + "!span": "1741[65:6]-1745[65:10]" + }, + "constructed": { + "!type": "bool", + "!span": "1773[66:6]-1784[66:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "1798[67:6]-1809[67:17]" + }, + "!span": "1649[62:7]-1835[68:5]" + }, + "encryptedPrivateKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "1869[71:4]-1873[71:8]", + "!doc": "encryptedData" + }, + "tagClass": { + "!type": "number", + "!span": "1920[72:4]-1928[72:12]" + }, + "type": { + "!type": "number", + "!span": "1956[73:4]-1960[73:8]" + }, + "constructed": { + "!type": "bool", + "!span": "1989[74:4]-2000[74:15]" + }, + "capture": { + "!type": "string", + "!span": "2013[75:4]-2020[75:11]" + }, + "!span": "1842[69:5]-2041[76:3]" + }, + "PBES2AlgorithmsValidator.value.0": { + "name": { + "!type": "string", + "!span": "2315[87:4]-2319[87:8]" + }, + "tagClass": { + "!type": "number", + "!span": "2362[88:4]-2370[88:12]" + }, + "type": { + "!type": "number", + "!span": "2398[89:4]-2402[89:8]" + }, + "constructed": { + "!type": "bool", + "!span": "2428[90:4]-2439[90:15]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.0.value.0, PBES2AlgorithmsValidator.value.0.value.1]", + "!span": "2451[91:4]-2456[91:9]" + }, + "!span": "2309[86:10]-3813[137:3]" + }, + "PBES2AlgorithmsValidator.value.0.value.0": { + "name": { + "!type": "string", + "!span": "2467[92:6]-2471[92:10]" + }, + "tagClass": { + "!type": "number", + "!span": "2520[93:6]-2528[93:14]" + }, + "type": { + "!type": "number", + "!span": "2558[94:6]-2562[94:10]" + }, + "constructed": { + "!type": "bool", + "!span": "2585[95:6]-2596[95:17]" + }, + "capture": { + "!type": "string", + "!span": "2611[96:6]-2618[96:13]" + }, + "!span": "2459[91:12]-2634[97:5]" + }, + "PBES2AlgorithmsValidator.value.0.value.1": { + "name": { + "!type": "string", + "!span": "2644[98:6]-2648[98:10]" + }, + "tagClass": { + "!type": "number", + "!span": "2682[99:6]-2690[99:14]" + }, + "type": { + "!type": "number", + "!span": "2720[100:6]-2724[100:10]" + }, + "constructed": { + "!type": "bool", + "!span": "2752[101:6]-2763[101:17]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.0.value.1.value.0, PBES2AlgorithmsValidator.value.0.value.1.value.1, PBES2AlgorithmsValidator.value.0.value.1.value.2, PBES2AlgorithmsValidator.value.0.value.1.value.3]", + "!span": "2777[102:6]-2782[102:11]" + }, + "!span": "2636[97:7]-3808[136:5]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.0": { + "name": { + "!type": "string", + "!span": "2795[103:8]-2799[103:12]" + }, + "tagClass": { + "!type": "number", + "!span": "2840[104:8]-2848[104:16]" + }, + "type": { + "!type": "number", + "!span": "2880[105:8]-2884[105:12]" + }, + "constructed": { + "!type": "bool", + "!span": "2917[106:8]-2928[106:19]" + }, + "capture": { + "!type": "string", + "!span": "2945[107:8]-2952[107:15]" + }, + "!span": "2785[102:14]-2971[108:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.1": { + "name": { + "!type": "string", + "!span": "2983[109:8]-2987[109:12]" + }, + "tagClass": { + "!type": "number", + "!span": "3038[110:8]-3046[110:16]" + }, + "type": { + "!type": "number", + "!span": "3078[111:8]-3082[111:12]" + }, + "constructed": { + "!type": "bool", + "!span": "3111[112:8]-3122[112:19]" + }, + "capture": { + "!type": "string", + "!span": "3139[113:8]-3146[113:15]" + }, + "!span": "2973[108:9]-3175[114:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.2": { + "name": { + "!type": "string", + "!span": "3187[115:8]-3191[115:12]" + }, + "tagClass": { + "!type": "number", + "!span": "3237[116:8]-3245[116:16]" + }, + "type": { + "!type": "number", + "!span": "3277[117:8]-3281[117:12]" + }, + "constructed": { + "!type": "bool", + "!span": "3310[118:8]-3321[118:19]" + }, + "optional": { + "!type": "bool", + "!span": "3338[119:8]-3346[119:16]" + }, + "capture": { + "!type": "string", + "!span": "3362[120:8]-3369[120:15]" + }, + "!span": "3177[114:9]-3390[121:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.3": { + "name": { + "!type": "string", + "!span": "3417[123:8]-3421[123:12]", + "!doc": "prf" + }, + "tagClass": { + "!type": "number", + "!span": "3461[124:8]-3469[124:16]" + }, + "type": { + "!type": "number", + "!span": "3501[125:8]-3505[125:12]" + }, + "constructed": { + "!type": "bool", + "!span": "3535[126:8]-3546[126:19]" + }, + "optional": { + "!type": "bool", + "!span": "3562[127:8]-3570[127:16]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.0.value.1.value.3.value.]", + "!span": "3586[128:8]-3591[128:13]" + }, + "!span": "3392[121:9]-3801[135:7]" + }, + "PBES2AlgorithmsValidator.value.0.value.1.value.3.value.": { + "name": { + "!type": "string", + "!span": "3606[129:10]-3610[129:14]" + }, + "tagClass": { + "!type": "number", + "!span": "3662[130:10]-3670[130:18]" + }, + "type": { + "!type": "number", + "!span": "3704[131:10]-3708[131:14]" + }, + "constructed": { + "!type": "bool", + "!span": "3735[132:10]-3746[132:21]" + }, + "capture": { + "!type": "string", + "!span": "3765[133:10]-3772[133:17]" + }, + "!span": "3594[128:16]-3792[134:9]" + }, + "PBES2AlgorithmsValidator.value.1": { + "name": { + "!type": "string", + "!span": "3821[138:4]-3825[138:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3867[139:4]-3875[139:12]" + }, + "type": { + "!type": "number", + "!span": "3903[140:4]-3907[140:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3933[141:4]-3944[141:15]" + }, + "value": { + "!type": "[PBES2AlgorithmsValidator.value.1.value.0, PBES2AlgorithmsValidator.value.1.value.1]", + "!span": "3956[142:4]-3961[142:9]" + }, + "!span": "3815[137:5]-4325[155:3]" + }, + "PBES2AlgorithmsValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "3972[143:6]-3976[143:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4024[144:6]-4032[144:14]" + }, + "type": { + "!type": "number", + "!span": "4062[145:6]-4066[145:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4089[146:6]-4100[146:17]" + }, + "capture": { + "!type": "string", + "!span": "4115[147:6]-4122[147:13]" + }, + "!span": "3964[142:12]-4138[148:5]" + }, + "PBES2AlgorithmsValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "4148[149:6]-4152[149:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4199[150:6]-4207[150:14]" + }, + "type": { + "!type": "number", + "!span": "4237[151:6]-4241[151:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4272[152:6]-4283[152:17]" + }, + "capture": { + "!type": "string", + "!span": "4298[153:6]-4305[153:13]" + }, + "!span": "4140[148:7]-4320[154:5]" + }, + "pkcs12PbeParamsValidator.value.0": { + "name": { + "!type": "string", + "!span": "4491[164:4]-4495[164:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4526[165:4]-4534[165:12]" + }, + "type": { + "!type": "number", + "!span": "4562[166:4]-4566[166:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4595[167:4]-4606[167:15]" + }, + "capture": { + "!type": "string", + "!span": "4619[168:4]-4626[168:11]" + }, + "!span": "4485[163:10]-4638[169:3]" + }, + "pkcs12PbeParamsValidator.value.1": { + "name": { + "!type": "string", + "!span": "4646[170:4]-4650[170:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4687[171:4]-4695[171:12]" + }, + "type": { + "!type": "number", + "!span": "4723[172:4]-4727[172:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4752[173:4]-4763[173:15]" + }, + "capture": { + "!type": "string", + "!span": "4776[174:4]-4783[174:11]" + }, + "!span": "4640[169:5]-4801[175:3]" + }, + "hash.!0": { + "algorithm": { + "!type": "string", + "!span": "746[36:4]-755[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "768[37:4]-779[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "789[38:4]-801[38:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "928[42:4]-945[42:21]", + "!doc": "full message length (set md.messageLength64 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "996[44:4]-1013[44:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> hash.!0", + "!span": "1102[52:5]-1107[52:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: ?) -> hash.!0", + "!span": "2076[84:5]-2082[84:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "2989[119:5]-2995[119:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "740[35:11]-1020[45:3]", + "!doc": "message digest object", + "messageLength64": "hash.!0.fullMessageLength" + }, + "pem.encode.!0": { + "type": { + "!type": "string", + "!span": "27457[901:4]-27461[901:8]" + }, + "!span": "27451[900:12]-27558[903:3]", + "!doc": "convert to ASN.1, then DER, then PEM-encode" + }, + "pem.encode.!1": { + "!span": "27591[904:31]-27609[904:49]" + }, + "pem.decode.!ret": "[pem.decode.!ret.]", + "pem.decode.!ret.": { + "type": { + "!type": "string", + "!span": "3012[109:6]-3016[109:10]" + }, + "procType": { + "version": { + "!type": "string", + "!span": "4449[158:26]-4456[158:33]" + }, + "type": { + "!type": "string", + "!span": "4469[158:46]-4473[158:50]" + }, + "!span": "3034[110:6]-3042[110:14]" + }, + "contentDomain": { + "!type": "string", + "!span": "3056[111:6]-3069[111:19]", + "!doc": "special-case Content-Domain" + }, + "dekInfo": { + "algorithm": { + "!type": "string", + "!span": "4967[168:25]-4976[168:34]" + }, + "parameters": { + "!type": "string", + "!span": "4989[168:47]-4999[168:57]" + }, + "!span": "3083[112:6]-3090[112:13]" + }, + "headers": { + "!type": "[pem.decode.!ret..headers.]", + "!span": "3104[113:6]-3111[113:13]" + }, + "body": { + "!type": "string", + "!span": "3123[114:6]-3127[114:10]" + }, + "!span": "3004[108:14]-3164[115:5]" + }, + "pem.decode.!ret..headers.": { + "name": { + "!type": "string", + "!span": "3797[143:22]-3801[143:26]" + }, + "values": { + "!type": "[string]", + "!span": "3813[143:38]-3819[143:44]" + }, + "!span": "3796[143:21]-3824[143:49]" + }, + "foldHeader.!0": { + "name": { + "!type": "string", + "!span": "1829[61:14]-1833[61:18]" + }, + "values": { + "!type": "[string]", + "!span": "1847[61:32]-1853[61:38]" + }, + "!span": "1828[61:13]-1879[61:64]", + "!doc": "encode special headers" + }, + "rsa_mgf1.!2": { + "algorithm": { + "!type": "string", + "!span": "753[36:4]-762[36:13]" + }, + "blockLength": { + "!type": "number", + "!span": "776[37:4]-787[37:15]" + }, + "digestLength": { + "!type": "number", + "!span": "797[38:4]-809[38:16]" + }, + "fullMessageLength": { + "!type": "[number]", + "!span": "936[42:4]-953[42:21]", + "!doc": "full message length (set md.messageLength64 for backwards-compatibility)" + }, + "messageLengthSize": { + "!type": "number", + "!span": "1004[44:4]-1021[44:21]", + "!doc": "size of message length in bytes" + }, + "start": { + "!type": "fn() -> rsa_mgf1.!2", + "!span": "1110[52:5]-1115[52:10]", + "!doc": "Starts the digest.\n\n@return this digest object." + }, + "update": { + "!type": "fn(msg: ?, encoding: string) -> rsa_mgf1.!2", + "!span": "2106[85:5]-2112[85:11]", + "!doc": "Updates the digest with the given message input. The given input can\ntreated as raw input (no encoding will be applied) or an encoding of\n'utf8' maybe given to encode the input using UTF-8.\n\n@param msg the message input to update with.\n@param encoding the encoding to use (default: 'raw', other: 'utf8').\n\n@return this digest object." + }, + "digest": { + "!type": "fn() -> +ByteBuffer", + "!span": "3021[120:5]-3027[120:11]", + "!doc": "Produces the digest.\n\n@return a byte buffer containing the digest value." + }, + "!span": "747[35:11]-1028[45:3]", + "!doc": "message digest object", + "messageLength64": "rsa_mgf1.!2.fullMessageLength" + }, + "p12.pkcs12FromAsn1.!ret": { + "safeContents": { + "": { + "encrypted": { + "!type": "bool", + "!span": "15681[541:6]-15690[541:15]" + }, + "safeBags": { + "": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + } + } + } + }, + "getBags": {}, + "getBagsByFriendlyName": {}, + "getBagsByLocalKeyId": "_decodeAuthenticatedSafe.!0.getBagsByLocalKeyId" + }, + "p12.toPkcs12Asn1.!3": { + "saltSize": { + "!type": "number", + "!span": "24053[798:10]-24061[798:18]" + }, + "count": { + "!type": "number", + "!span": "24097[799:10]-24102[799:15]" + }, + "algorithm": { + "!type": "string", + "!span": "24138[800:10]-24147[800:19]" + }, + "useMac": { + "!type": "bool", + "!span": "24248[802:12]-24254[802:18]" + }, + "generateLocalKeyId": { + "!type": "bool", + "!span": "24392[808:12]-24410[808:30]" + }, + "prfAlgorithm": { + "!type": "string", + "!span": "6433[245:5]-6445[245:17]" + }, + "!span": "24039[797:23]-24041[797:25]", + "!doc": "set default options" + }, + "contentInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "3818[127:4]-3822[127:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3855[128:4]-3863[128:12]" + }, + "type": { + "!type": "number", + "!span": "3891[129:4]-3895[129:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3916[130:4]-3927[130:15]" + }, + "capture": { + "!type": "string", + "!span": "3940[131:4]-3947[131:11]" + }, + "!span": "3812[126:10]-3966[132:3]" + }, + "contentInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "3974[133:4]-3978[133:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4007[134:4]-4015[134:12]" + }, + "type": { + "!type": "number", + "!span": "4050[135:4]-4054[135:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4063[136:4]-4074[136:15]" + }, + "optional": { + "!type": "bool", + "!span": "4086[137:4]-4094[137:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4106[138:4]-4117[138:15]" + }, + "!span": "3968[132:5]-4132[139:3]" + }, + "pfxValidator.value.0": { + "name": { + "!type": "string", + "!span": "3726[139:4]-3730[139:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3751[140:4]-3759[140:12]" + }, + "type": { + "!type": "number", + "!span": "3787[141:4]-3791[141:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3816[142:4]-3827[142:15]" + }, + "capture": { + "!type": "string", + "!span": "3840[143:4]-3847[143:11]" + }, + "!span": "3720[138:10]-3862[144:3]" + }, + "pfxValidator.value.2": { + "name": { + "!type": "string", + "!span": "3894[146:4]-3898[146:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3919[147:4]-3927[147:12]" + }, + "type": { + "!type": "number", + "!span": "3955[148:4]-3959[148:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3985[149:4]-3996[149:15]" + }, + "optional": { + "!type": "bool", + "!span": "4008[150:4]-4016[150:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4028[151:4]-4039[151:15]" + }, + "value": { + "!type": "[pfxValidator.value.2.value.0, pfxValidator.value.2.value.1, pfxValidator.value.2.value.2]", + "!span": "4052[152:4]-4057[152:9]" + }, + "!span": "3888[145:24]-5358[194:3]" + }, + "pfxValidator.value.2.value.0": { + "name": { + "!type": "string", + "!span": "4068[153:6]-4072[153:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4099[154:6]-4107[154:14]" + }, + "type": { + "!type": "number", + "!span": "4137[155:6]-4141[155:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4184[156:6]-4195[156:17]" + }, + "value": { + "!type": "[pfxValidator.value.2.value.0.value.0, pfxValidator.value.2.value.0.value.1]", + "!span": "4209[157:6]-4214[157:11]" + }, + "!span": "4060[152:12]-4990[180:5]" + }, + "pfxValidator.value.2.value.0.value.0": { + "name": { + "!type": "string", + "!span": "4227[158:8]-4231[158:12]" + }, + "tagClass": { + "!type": "number", + "!span": "4276[159:8]-4284[159:16]" + }, + "type": { + "!type": "number", + "!span": "4316[160:8]-4320[160:12]" + }, + "constructed": { + "!type": "bool", + "!span": "4380[161:8]-4391[161:19]" + }, + "value": { + "!type": "[pfxValidator.value.2.value.0.value.0.value.0, pfxValidator.value.2.value.0.value.0.value.1]", + "!span": "4407[162:8]-4412[162:13]" + }, + "!span": "4217[157:14]-4798[173:7]" + }, + "pfxValidator.value.2.value.0.value.0.value.0": { + "name": { + "!type": "string", + "!span": "4427[163:10]-4431[163:14]" + }, + "tagClass": { + "!type": "number", + "!span": "4488[164:10]-4496[164:18]" + }, + "type": { + "!type": "number", + "!span": "4530[165:10]-4534[165:14]" + }, + "constructed": { + "!type": "bool", + "!span": "4561[166:10]-4572[166:21]" + }, + "capture": { + "!type": "string", + "!span": "4591[167:10]-4598[167:17]" + }, + "!span": "4415[162:16]-4624[168:9]" + }, + "pfxValidator.value.2.value.0.value.0.value.1": { + "name": { + "!type": "string", + "!span": "4638[169:10]-4642[169:14]" + }, + "tagClass": { + "!type": "number", + "!span": "4700[170:10]-4708[170:18]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4742[171:10]-4753[171:21]" + }, + "!span": "4626[168:11]-4789[172:9]" + }, + "pfxValidator.value.2.value.0.value.1": { + "name": { + "!type": "string", + "!span": "4810[174:8]-4814[174:12]" + }, + "tagClass": { + "!type": "number", + "!span": "4850[175:8]-4858[175:16]" + }, + "type": { + "!type": "number", + "!span": "4890[176:8]-4894[176:12]" + }, + "constructed": { + "!type": "bool", + "!span": "4927[177:8]-4938[177:19]" + }, + "capture": { + "!type": "string", + "!span": "4955[178:8]-4962[178:15]" + }, + "!span": "4800[173:9]-4983[179:7]" + }, + "pfxValidator.value.2.value.1": { + "name": { + "!type": "string", + "!span": "5000[181:6]-5004[181:10]" + }, + "tagClass": { + "!type": "number", + "!span": "5035[182:6]-5043[182:14]" + }, + "type": { + "!type": "number", + "!span": "5073[183:6]-5077[183:10]" + }, + "constructed": { + "!type": "bool", + "!span": "5108[184:6]-5119[184:17]" + }, + "capture": { + "!type": "string", + "!span": "5134[185:6]-5141[185:13]" + }, + "!span": "4992[180:7]-5158[186:5]" + }, + "pfxValidator.value.2.value.2": { + "name": { + "!type": "string", + "!span": "5168[187:6]-5172[187:10]" + }, + "tagClass": { + "!type": "number", + "!span": "5206[188:6]-5214[188:14]" + }, + "type": { + "!type": "number", + "!span": "5244[189:6]-5248[189:10]" + }, + "constructed": { + "!type": "bool", + "!span": "5275[190:6]-5286[190:17]" + }, + "optional": { + "!type": "bool", + "!span": "5301[191:6]-5309[191:14]" + }, + "capture": { + "!type": "string", + "!span": "5323[192:6]-5330[192:13]" + }, + "!span": "5160[186:7]-5353[193:5]" + }, + "safeBagValidator.value.0": { + "name": { + "!type": "string", + "!span": "5507[203:4]-5511[203:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5534[204:4]-5542[204:12]" + }, + "type": { + "!type": "number", + "!span": "5570[205:4]-5574[205:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5595[206:4]-5606[206:15]" + }, + "capture": { + "!type": "string", + "!span": "5619[207:4]-5626[207:11]" + }, + "!span": "5501[202:10]-5639[208:3]" + }, + "safeBagValidator.value.1": { + "name": { + "!type": "string", + "!span": "5647[209:4]-5651[209:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5677[210:4]-5685[210:12]" + }, + "constructed": { + "!type": "bool", + "!span": "5720[211:4]-5731[211:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "5743[212:4]-5754[212:15]" + }, + "!span": "5641[208:5]-5770[213:3]" + }, + "safeBagValidator.value.2": { + "name": { + "!type": "string", + "!span": "5778[214:4]-5782[214:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5813[215:4]-5821[215:12]" + }, + "type": { + "!type": "number", + "!span": "5849[216:4]-5853[216:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5874[217:4]-5885[217:15]" + }, + "optional": { + "!type": "bool", + "!span": "5897[218:4]-5905[218:12]" + }, + "capture": { + "!type": "string", + "!span": "5917[219:4]-5924[219:11]" + }, + "!span": "5772[213:5]-5945[220:3]" + }, + "attributeValidator.value.0": { + "name": { + "!type": "string", + "!span": "6098[229:4]-6102[229:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6128[230:4]-6136[230:12]" + }, + "type": { + "!type": "number", + "!span": "6164[231:4]-6168[231:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6189[232:4]-6200[232:15]" + }, + "capture": { + "!type": "string", + "!span": "6213[233:4]-6220[233:11]" + }, + "!span": "6092[228:10]-6231[234:3]" + }, + "attributeValidator.value.1": { + "name": { + "!type": "string", + "!span": "6239[235:4]-6243[235:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6273[236:4]-6281[236:12]" + }, + "type": { + "!type": "number", + "!span": "6309[237:4]-6313[237:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6334[238:4]-6345[238:15]" + }, + "capture": { + "!type": "string", + "!span": "6357[239:4]-6364[239:11]" + }, + "!span": "6233[234:5]-6378[240:3]" + }, + "certBagValidator.value.0": { + "name": { + "!type": "string", + "!span": "6527[249:4]-6531[249:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6555[250:4]-6563[250:12]" + }, + "type": { + "!type": "number", + "!span": "6591[251:4]-6595[251:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6616[252:4]-6627[252:15]" + }, + "capture": { + "!type": "string", + "!span": "6640[253:4]-6647[253:11]" + }, + "!span": "6521[248:10]-6661[254:3]" + }, + "certBagValidator.value.1": { + "name": { + "!type": "string", + "!span": "6669[255:4]-6673[255:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6700[256:4]-6708[256:12]" + }, + "constructed": { + "!type": "bool", + "!span": "6743[257:4]-6754[257:15]" + }, + "value": { + "!type": "[certBagValidator.value.1.value.]", + "!span": "6892[260:4]-6897[260:9]", + "!doc": "So far we only support X.509 certificates (which are wrapped in\nan OCTET STRING, hence hard code that here)." + }, + "!span": "6663[254:5]-7070[267:3]" + }, + "certBagValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "6908[261:6]-6912[261:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6944[262:6]-6952[262:14]" + }, + "constructed": { + "!type": "bool", + "!span": "7018[264:6]-7029[264:17]" + }, + "capture": { + "!type": "string", + "!span": "7044[265:6]-7051[265:13]" + }, + "!span": "6900[260:12]-7065[266:5]" + }, + "_getBagsByAttribute.!0": { + "!type": "[_getBagsByAttribute.!0.]", + "!span": "9004[336:4]-9016[336:16]" + }, + "_getBagsByAttribute.!0.": { + "encrypted": { + "!type": "bool", + "!span": "15681[541:6]-15690[541:15]" + }, + "safeBags": { + "": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + } + }, + "!span": "15673[540:14]-15703[542:5]" + }, + "_getBagsByAttribute.!ret": { + "!type": "[_getBagsByAttribute.!ret.]", + "!span": "10006[364:13]-10020[364:27]" + }, + "_getBagsByAttribute.!ret.": { + "type": { + "!type": "string", + "!span": "19026[652:6]-19030[652:10]" + }, + "!span": "19018[651:14]-19129[654:5]", + "!doc": "Create bag object and push to result array.", + "key": "_modPow.!1", + "asn1": "_fromDer.!ret", + "cert": "pki.certificateFromPem.!ret", + "attributes": { + "": "_decodeBagAttributes.!ret." + } + }, + "_decodePkcs7Data.!0": { + "constructed": { + "!type": "bool", + "!span": "14440[502:25]-14451[502:36]" + }, + "composed": { + "!type": "bool", + "!span": "14424[502:9]-14432[502:17]" + } + }, + "_decodeAuthenticatedSafe.!0": { + "getBags": { + "!type": "fn(filter: ?) -> _decodeAuthenticatedSafe.!0.getBags.!ret", + "!span": "9595[351:4]-9602[351:11]", + "!doc": "Gets bags with matching attributes.\n\n@param filter the attributes to filter by:\n [localKeyId] the localKeyId to search for.\n [localKeyIdHex] the localKeyId in hex to search for.\n [friendlyName] the friendly name to search for.\n [bagType] bag type to narrow each attribute search by.\n\n@return a map of attribute type to an array of matching bags or, if no\n attribute was given but a bag type, the map key will be the\n bag type." + }, + "getBagsByFriendlyName": { + "!type": "fn(friendlyName: ?, bagType: ?) -> [_getBagsByAttribute.!ret.]", + "!span": "10819[392:4]-10840[392:25]", + "!doc": "DEPRECATED: use getBags() instead.\n\nGet bags with matching friendlyName attribute.\n\n@param friendlyName the friendly name to search for.\n@param [bagType] bag type to narrow search by.\n\n@return an array of bags with matching friendlyName attribute." + }, + "getBagsByLocalKeyId": { + "!type": "fn(localKeyId: ?, bagType: ?) -> [_getBagsByAttribute.!ret.]", + "!span": "11296[407:4]-11315[407:23]", + "!doc": "DEPRECATED: use getBags() instead.\n\nGet bags with matching localKeyId attribute.\n\n@param localKeyId the localKeyId to search for.\n@param [bagType] bag type to narrow search by.\n\n@return an array of bags with matching localKeyId attribute." + }, + "!span": "8954[334:12]-11454[411:3]", + "safeContents": "_getBagsByAttribute.!0" + }, + "_decodeAuthenticatedSafe.!0.getBags.!ret": { + "!span": "9640[352:17]-9642[352:19]", + "": "_getBagsByAttribute.!ret", + "localKeyId": "_getBagsByAttribute.!ret", + "friendlyName": "_getBagsByAttribute.!ret" + }, + "_decodeSafeContents.!ret": { + "!type": "[_getBagsByAttribute.!ret.]", + "!span": "16404[563:8]-16412[563:16]" + }, + "_decodeBagAttributes.!ret": { + "": { + "!type": "[?]", + "!span": "22423[756:19]-22436[756:32]" + }, + "!span": "21904[738:21]-21906[738:23]" + }, + "p7.messageFromPem.!ret": { + "version": { + "!type": "number", + "!span": "18359[589:4]-18366[589:11]" + }, + "recipients": { + "": { + "version": { + "!type": "number", + "!span": "21713[700:8]-21720[700:15]" + }, + "encryptedContent": "_recipientsFromAsn1.!ret..encryptedContent" + } + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "37653[1185:6]-37662[1185:15]", + "!doc": "Keep a copy of the key & IV in the object, so the caller can\nuse it for whatever reason." + }, + "parameter": "+ByteBuffer", + "content": "+ByteBuffer", + "key": "+ByteBuffer" + }, + "findRecipient": {}, + "content": "+ByteBuffer", + "fromAsn1": "_fromAsn1.!0.fromAsn1", + "toAsn1": "_fromAsn1.!0.toAsn1", + "decrypt": "_fromAsn1.!0.decrypt", + "addRecipient": "_fromAsn1.!0.addRecipient", + "encrypt": "_fromAsn1.!0.encrypt", + "rawCapture": "_fromAsn1.!ret" + }, + "p7.messageFromPem.!ret.findRecipient.!ret": { + "serialNumber": { + "!type": "string", + "!span": "26217[836:4]-26229[836:16]" + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "26310[838:6]-26319[838:15]" + } + }, + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "p7.createSignedData.!ret": { + "version": { + "!type": "number", + "!span": "3313[125:4]-3320[125:11]" + }, + "certificates": { + "!type": "[pki.certificateFromPem.!ret]", + "!span": "3329[126:4]-3341[126:16]" + }, + "crls": { + "!type": "[?]", + "!span": "3351[127:4]-3355[127:8]" + }, + "signers": { + "": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret", + "authenticatedAttributes": "_signerToAsn1.!0.authenticatedAttributes", + "unauthenticatedAttributes": "_signerToAsn1.!0.unauthenticatedAttributes" + } + }, + "digestAlgorithmIdentifiers": { + "!type": "[_fromDer.!ret]", + "!span": "3464[131:4]-3490[131:30]", + "!doc": "add unique digest algorithm identifiers" + }, + "fromAsn1": { + "!type": "fn(obj: ?)", + "!span": "3545[135:4]-3553[135:12]" + }, + "toAsn1": { + "!type": "fn() -> _fromDer.!ret", + "!span": "4114[154:4]-4120[154:10]" + }, + "addSigner": { + "!type": "fn(signer: ?)", + "!span": "7603[248:4]-7612[248:13]", + "!doc": "Add (another) entity to list of signers.\n\nNote: If authenticatedAttributes are provided, then, per RFC 2315,\nthey must include at least two attributes: content type and\nmessage digest. The message digest attribute value will be\nauto-calculated during signing and will be ignored if provided.\n\nHere's an example of providing these two attributes:\n\nforge.pkcs7.createSignedData();\np7.addSigner({\n issuer: cert.issuer.attributes,\n serialNumber: cert.serialNumber,\n key: privateKey,\n digestAlgorithm: forge.pki.oids.sha1,\n authenticatedAttributes: [{\n type: forge.pki.oids.contentType,\n value: forge.pki.oids.data\n }, {\n type: forge.pki.oids.messageDigest\n }]\n});\n\nTODO: Support [subjectKeyIdentifier] as signer's ID.\n\n@param signer the signer information:\n key the signer's private key.\n [certificate] a certificate containing the public key\n associated with the signer's private key; use this option as\n an alternative to specifying signer.issuer and\n signer.serialNumber.\n [issuer] the issuer attributes (eg: cert.issuer.attributes).\n [serialNumber] the signer's certificate's serial number in\n hexadecimal (eg: cert.serialNumber).\n [digestAlgorithm] the message digest OID, as a string, to use\n (eg: forge.pki.oids.sha1).\n [authenticatedAttributes] an optional array of attributes\n to also sign along with the content." + }, + "sign": { + "!type": "fn(options: ?)", + "!span": "10457[333:4]-10461[333:8]", + "!doc": "Signs the content.\n@param options Options to apply when signing:\n [detached] boolean. If signing should be done in detached mode. Defaults to false." + }, + "verify": { + "!type": "fn()", + "!span": "12010[379:4]-12016[379:10]" + }, + "addCertificate": { + "!type": "fn(cert: pki.certificateFromPem.!ret)", + "!span": "12212[388:4]-12226[388:18]", + "!doc": "Add a certificate.\n\n@param cert the certificate to add." + }, + "addCertificateRevokationList": { + "!type": "fn(crl: ?)", + "!span": "12537[401:4]-12565[401:32]", + "!doc": "Add a certificate revokation list.\n\n@param crl the certificate revokation list to add." + }, + "!span": "3270[123:8]-12658[404:3]", + "contentInfo": "_fromDer.!ret", + "signerInfos": { + "": "_fromDer.!ret" + }, + "detachedContent": "_fromDer.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret" + }, + "p7.createEncryptedData.!ret": { + "version": { + "!type": "number", + "!span": "17467[550:4]-17474[550:11]" + }, + "fromAsn1": { + "!type": "fn(obj: ?)", + "!span": "17724[560:4]-17732[560:12]", + "!doc": "Reads an EncryptedData content block (in ASN.1 format)\n\n@param obj The ASN.1 representation of the EncryptedData content block" + }, + "decrypt": { + "!type": "fn(key: ?)", + "!span": "17996[570:4]-18003[570:11]", + "!doc": "Decrypt encrypted content\n\n@param key The (symmetric) key as a byte buffer" + }, + "!span": "17421[548:8]-18136[576:3]", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret" + }, + "_recipientFromAsn1.!ret": { + "serialNumber": { + "!type": "string", + "!span": "26217[836:4]-26229[836:16]" + }, + "encryptedContent": { + "algorithm": { + "!type": "string", + "!span": "26310[838:6]-26319[838:15]" + }, + "!span": "26284[837:4]-26300[837:20]" + }, + "!span": "26107[833:9]-26442[842:3]", + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "_recipientsFromAsn1.!ret": { + "!type": "[_recipientFromAsn1.!ret]", + "!span": "18375[590:4]-18385[590:14]" + }, + "_recipientsFromAsn1.!ret.": { + "version": { + "!type": "number", + "!span": "21713[700:8]-21720[700:15]" + }, + "encryptedContent": { + "!span": "21814[703:8]-21830[703:24]" + }, + "!span": "21703[699:26]-22137[710:7]" + }, + "_recipientsToAsn1.!ret": "[_fromDer.!ret]", + "_signerFromAsn1.!ret": { + "serialNumber": { + "!type": "string", + "!span": "29019[930:4]-29031[930:16]" + }, + "digestAlgorithm": { + "!type": "string", + "!span": "29086[931:4]-29101[931:19]" + }, + "signatureAlgorithm": { + "!type": "string", + "!span": "29147[932:4]-29165[932:22]" + }, + "authenticatedAttributes": { + "!type": "[?]", + "!span": "29248[934:4]-29271[934:27]" + }, + "unauthenticatedAttributes": { + "!type": "[?]", + "!span": "29281[935:4]-29306[935:29]" + }, + "!span": "28909[927:13]-29314[936:3]", + "issuer": "pki.RDNAttributesAsArray.!ret" + }, + "_signerToAsn1.!0": { + "version": { + "!type": "number", + "!span": "9954[317:8]-9961[317:15]" + }, + "serialNumber": { + "!type": "string", + "!span": "9998[319:8]-10010[319:20]" + }, + "authenticatedAttributes": { + "!type": "[?]", + "!span": "10159[323:8]-10182[323:31]", + "!doc": "if authenticatedAttributes is present, then the attributes\nmust contain at least PKCS #9 content-type and message-digest" + }, + "unauthenticatedAttributes": { + "!type": "[?]", + "!span": "10217[324:8]-10242[324:33]" + }, + "!span": "9926[315:23]-10254[325:7]", + "key": "_modPow.!1", + "issuer": "pki.RDNAttributesAsArray.!ret", + "authenticatedAttributesAsn1": "_fromDer.!ret" + }, + "_signersFromAsn1.!ret": "[_signerFromAsn1.!ret]", + "_signersToAsn1.!0": { + "!type": "[_signerToAsn1.!0]", + "!span": "3416[129:4]-3423[129:11]", + "!doc": "TODO: add json-formatted signer stuff here?" + }, + "_signersToAsn1.!ret": { + "!type": "[_fromDer.!ret]", + "!span": "3523[133:4]-3534[133:15]", + "!doc": "add signer info" + }, + "_attributeToAsn1.!0": { + "value": "+Date" + }, + "_encryptedContentToAsn1.!0": { + "algorithm": { + "!type": "string", + "!span": "37653[1185:6]-37662[1185:15]", + "!doc": "Keep a copy of the key & IV in the object, so the caller can\nuse it for whatever reason." + }, + "!span": "37645[1184:27]-37824[1188:5]", + "parameter": "+ByteBuffer", + "content": "+ByteBuffer", + "key": "+ByteBuffer" + }, + "_encryptedContentToAsn1.!ret": "[_fromDer.!ret, _fromDer.!ret, _fromDer.!ret]", + "_fromAsn1.!0": { + "version": { + "!type": "number", + "!span": "18359[589:4]-18366[589:11]" + }, + "fromAsn1": { + "!type": "fn(obj: ?)", + "!span": "18637[600:4]-18645[600:12]", + "!doc": "Reads an EnvelopedData content block (in ASN.1 format)\n\n@param obj the ASN.1 representation of the EnvelopedData content block." + }, + "toAsn1": { + "!type": "fn() -> _fromDer.!ret", + "!span": "18885[606:4]-18891[606:10]" + }, + "findRecipient": { + "!type": "fn(cert: ?) -> _recipientsFromAsn1.!ret.", + "!span": "19996[636:4]-20009[636:17]", + "!doc": "Find recipient by X.509 certificate's issuer.\n\n@param cert the certificate with the issuer to look for.\n\n@return the recipient object." + }, + "decrypt": { + "!type": "fn(recipient: ?, privKey: ?)", + "!span": "20858[674:4]-20865[674:11]", + "!doc": "Decrypt enveloped content\n\n@param recipient The recipient object related to the private key\n@param privKey The (RSA) private key object" + }, + "addRecipient": { + "!type": "fn(cert: ?)", + "!span": "21646[698:4]-21658[698:16]", + "!doc": "Add (another) entity to list of recipients.\n\n@param cert The certificate of the entity to add." + }, + "encrypt": { + "!type": "fn(key: +ByteBuffer, cipher: string)", + "!span": "22745[726:4]-22752[726:11]", + "!doc": "Encrypt enveloped content.\n\nThis function supports two optional arguments, cipher and key, which\ncan be used to influence symmetric encryption. Unless cipher is\nprovided, the cipher specified in encryptedContent.algorithm is used\n(defaults to AES-256-CBC). If no key is provided, encryptedContent.key\nis (re-)used. If that one's not set, a random key will be generated\nautomatically.\n\n@param [key] The key to be used for symmetric encryption.\n@param [cipher] The OID of the symmetric cipher to use." + }, + "!span": "18313[587:8]-25560[811:3]", + "recipients": "_recipientsFromAsn1.!ret", + "encryptedContent": "_encryptedContentToAsn1.!0", + "content": "+ByteBuffer", + "rawCapture": "_fromAsn1.!ret" + }, + "_fromAsn1.!ret": { + "!span": "36582[1155:16]-36584[1155:18]", + "!doc": "validate EnvelopedData content block and capture data" + }, + "p7v.envelopedDataValidator.value.0": { + "name": { + "!type": "string", + "!span": "6217[211:4]-6221[211:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6252[212:4]-6260[212:12]" + }, + "type": { + "!type": "number", + "!span": "6288[213:4]-6292[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6317[214:4]-6328[214:15]" + }, + "capture": { + "!type": "string", + "!span": "6341[215:4]-6348[215:11]" + }, + "!span": "6211[210:10]-6363[216:3]" + }, + "p7v.envelopedDataValidator.value.1": { + "name": { + "!type": "string", + "!span": "6371[217:4]-6375[217:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6413[218:4]-6421[218:12]" + }, + "type": { + "!type": "number", + "!span": "6449[219:4]-6453[219:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6474[220:4]-6485[220:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6497[221:4]-6508[221:15]" + }, + "!span": "6365[216:5]-6530[222:3]" + }, + "p7v.encryptedDataValidator.value.": { + "name": { + "!type": "string", + "!span": "6729[231:4]-6733[231:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6764[232:4]-6772[232:12]" + }, + "type": { + "!type": "number", + "!span": "6800[233:4]-6804[233:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6829[234:4]-6840[234:15]" + }, + "capture": { + "!type": "string", + "!span": "6853[235:4]-6860[235:11]" + }, + "!span": "6723[230:10]-6875[236:3]" + }, + "p7v.recipientInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "10109[361:4]-10113[361:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10144[362:4]-10152[362:12]" + }, + "type": { + "!type": "number", + "!span": "10180[363:4]-10184[363:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10209[364:4]-10220[364:15]" + }, + "capture": { + "!type": "string", + "!span": "10233[365:4]-10240[365:11]" + }, + "!span": "10103[360:10]-10255[366:3]" + }, + "p7v.recipientInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "10263[367:4]-10267[367:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10306[368:4]-10314[368:12]" + }, + "type": { + "!type": "number", + "!span": "10342[369:4]-10346[369:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10372[370:4]-10383[370:15]" + }, + "value": { + "!type": "[p7v.recipientInfoValidator.value.1.value.0, p7v.recipientInfoValidator.value.1.value.1]", + "!span": "10395[371:4]-10400[371:9]" + }, + "!span": "10257[366:5]-10776[384:3]" + }, + "p7v.recipientInfoValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "10411[372:6]-10415[372:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[373:6]-10471[373:14]" + }, + "type": { + "!type": "number", + "!span": "10501[374:6]-10505[374:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10533[375:6]-10544[375:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "10558[376:6]-10569[376:17]" + }, + "!span": "10403[371:12]-10585[377:5]" + }, + "p7v.recipientInfoValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "10595[378:6]-10599[378:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10653[379:6]-10661[379:14]" + }, + "type": { + "!type": "number", + "!span": "10691[380:6]-10695[380:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10722[381:6]-10733[381:17]" + }, + "capture": { + "!type": "string", + "!span": "10748[382:6]-10755[382:13]" + }, + "!span": "10587[377:7]-10771[383:5]" + }, + "p7v.recipientInfoValidator.value.2": { + "name": { + "!type": "string", + "!span": "10784[385:4]-10788[385:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10834[386:4]-10842[386:12]" + }, + "type": { + "!type": "number", + "!span": "10870[387:4]-10874[387:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10900[388:4]-10911[388:15]" + }, + "value": { + "!type": "[p7v.recipientInfoValidator.value.2.value.0, p7v.recipientInfoValidator.value.2.value.1]", + "!span": "10923[389:4]-10928[389:9]" + }, + "!span": "10778[384:5]-11295[401:3]" + }, + "p7v.recipientInfoValidator.value.2.value.0": { + "name": { + "!type": "string", + "!span": "10939[390:6]-10943[390:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11001[391:6]-11009[391:14]" + }, + "type": { + "!type": "number", + "!span": "11039[392:6]-11043[392:10]" + }, + "constructed": { + "!type": "bool", + "!span": "11066[393:6]-11077[393:17]" + }, + "capture": { + "!type": "string", + "!span": "11092[394:6]-11099[394:13]" + }, + "!span": "10931[389:12]-11121[395:5]" + }, + "p7v.recipientInfoValidator.value.2.value.1": { + "name": { + "!type": "string", + "!span": "11131[396:6]-11135[396:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11193[397:6]-11201[397:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11231[398:6]-11242[398:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "11257[399:6]-11268[399:17]" + }, + "!span": "11123[395:7]-11290[400:5]" + }, + "p7v.recipientInfoValidator.value.3": { + "name": { + "!type": "string", + "!span": "11303[402:4]-11307[402:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11343[403:4]-11351[403:12]" + }, + "type": { + "!type": "number", + "!span": "11379[404:4]-11383[404:8]" + }, + "constructed": { + "!type": "bool", + "!span": "11412[405:4]-11423[405:15]" + }, + "capture": { + "!type": "string", + "!span": "11436[406:4]-11443[406:11]" + }, + "!span": "11297[401:5]-11457[407:3]" + }, + "encryptedContentInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "4356[149:4]-4360[149:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4402[150:4]-4410[150:12]" + }, + "type": { + "!type": "number", + "!span": "4438[151:4]-4442[151:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4463[152:4]-4474[152:15]" + }, + "capture": { + "!type": "string", + "!span": "4487[153:4]-4494[153:11]" + }, + "!span": "4350[148:10]-4513[154:3]" + }, + "encryptedContentInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "4521[155:4]-4525[155:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4582[156:4]-4590[156:12]" + }, + "type": { + "!type": "number", + "!span": "4618[157:4]-4622[157:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4648[158:4]-4659[158:15]" + }, + "value": { + "!type": "[encryptedContentInfoValidator.value.1.value.0, encryptedContentInfoValidator.value.1.value.1]", + "!span": "4671[159:4]-4676[159:9]" + }, + "!span": "4515[154:5]-5039[170:3]" + }, + "encryptedContentInfoValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "4687[160:6]-4691[160:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4760[161:6]-4768[161:14]" + }, + "type": { + "!type": "number", + "!span": "4798[162:6]-4802[162:10]" + }, + "constructed": { + "!type": "bool", + "!span": "4825[163:6]-4836[163:17]" + }, + "capture": { + "!type": "string", + "!span": "4851[164:6]-4858[164:13]" + }, + "!span": "4679[159:12]-4880[165:5]" + }, + "encryptedContentInfoValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "4890[166:6]-4894[166:10]" + }, + "tagClass": { + "!type": "number", + "!span": "4963[167:6]-4971[167:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "5001[168:6]-5012[168:17]" + }, + "!span": "4882[165:7]-5034[169:5]" + }, + "encryptedContentInfoValidator.value.2": { + "name": { + "!type": "string", + "!span": "5047[171:4]-5051[171:8]" + }, + "tagClass": { + "!type": "number", + "!span": "5098[172:4]-5106[172:12]" + }, + "type": { + "!type": "number", + "!span": "5141[173:4]-5145[173:8]" + }, + "capture": { + "!type": "string", + "!span": "5984[200:4]-5991[200:11]", + "!doc": "The PKCS#7 structure output by OpenSSL somewhat differs from what\nother implementations do generate.\n\nOpenSSL generates a structure like this:\nSEQUENCE {\n ...\n [0]\n 26 DA 67 D2 17 9C 45 3C B1 2A A8 59 2F 29 33 38\n C3 C3 DF 86 71 74 7A 19 9F 40 D0 29 BE 85 90 45\n ...\n}\n\nWhereas other implementations (and this PKCS#7 module) generate:\nSEQUENCE {\n ...\n [0] {\n OCTET STRING\n 26 DA 67 D2 17 9C 45 3C B1 2A A8 59 2F 29 33 38\n C3 C3 DF 86 71 74 7A 19 9F 40 D0 29 BE 85 90 45\n ...\n }\n}\n\nIn order to support both, we just capture the context specific\nfield here. The OCTET STRING bit is removed below." + }, + "captureAsn1": { + "!type": "string", + "!span": "6017[201:4]-6028[201:15]" + }, + "!span": "5041[170:5]-6056[202:3]" + }, + "signerValidator.value.": { + "name": { + "!type": "string", + "!span": "8776[305:4]-8780[305:8]" + }, + "tagClass": { + "!type": "number", + "!span": "8826[306:4]-8834[306:12]" + }, + "type": { + "!type": "number", + "!span": "8869[307:4]-8873[307:8]" + }, + "constructed": { + "!type": "bool", + "!span": "8882[308:4]-8893[308:15]" + }, + "optional": { + "!type": "bool", + "!span": "8905[309:4]-8913[309:12]" + }, + "capture": { + "!type": "string", + "!span": "8925[310:4]-8932[310:11]" + }, + "!span": "8770[304:5]-8965[311:3]" + }, + "findPrime.!0": { + "hex": { + "!type": "string", + "!span": "7507[242:8]-7510[242:11]" + }, + "workLoad": { + "!type": "number", + "!span": "7525[243:8]-7533[243:16]" + }, + "!span": "7497[241:27]-7551[244:7]" + }, + "findPrime.!ret": { + "found": { + "!type": "bool", + "!span": "2181[54:10]-2186[54:15]" + }, + "!span": "2180[54:9]-2194[54:23]" + }, + "getPrng.!ret": { + "nextBytes": { + "!type": "fn(x: [number])", + "!span": "4032[136:4]-4041[136:13]", + "!doc": "x is an array to fill with bytes" + }, + "!span": "3986[134:9]-4165[141:3]" + }, + "pss.create.!0": { + "!span": "1211[36:14]-1298[40:5]" + }, + "pss.create.!ret": { + "encode": { + "!type": "fn(md: ?, modBits: ?) -> string", + "!span": "2345[81:9]-2351[81:15]", + "!doc": "Encodes a PSS signature.\n\nThis function implements EMSA-PSS-ENCODE as per RFC 3447, section 9.1.1.\n\n@param md the message digest object with the hash to sign.\n@param modsBits the length of the RSA modulus in bits.\n\n@return the encoded message as a binary-encoded string of length\n ceil((modBits - 1) / 8)." + }, + "verify": { + "!type": "fn(mHash: ?, em: ?, modBits: number) -> bool", + "!span": "4914[159:9]-4920[159:15]", + "!doc": "Verifies a PSS signature.\n\nThis function implements EMSA-PSS-VERIFY as per RFC 3447, section 9.1.2.\n\n@param mHash the message digest hash, as a binary-encoded string, to\n compare against the signature.\n@param em the encoded message, as a binary-encoded string\n (RSA decryption result).\n@param modsBits the length of the RSA modulus in bits.\n\n@return true if the signature was verified, false if not." + }, + "!span": "1962[68:15]-1964[68:17]" + }, + "createCipher.!ret": { + "start": { + "!type": "fn(iv: +ByteBuffer|string, output: ?)", + "!span": "7536[243:4]-7541[243:9]", + "!doc": "Starts or restarts the encryption or decryption process, whichever\nwas previously configured.\n\nTo use the cipher in CBC mode, iv may be given either as a string\nof bytes, or as a byte buffer. For ECB mode, give null as iv.\n\n@param iv the initialization vector to use, null for ECB mode.\n@param output the output the buffer to write to, null to create one." + }, + "update": { + "!type": "fn(input: +ByteBuffer)", + "!span": "7985[264:4]-7991[264:10]", + "!doc": "Updates the next block.\n\n@param input the buffer to read from." + }, + "finish": { + "!type": "fn(pad: ?) -> bool", + "!span": "8624[289:4]-8630[289:10]", + "!doc": "Finishes encrypting or decrypting.\n\n@param pad a padding function to use, null for PKCS#7 padding,\n signature(blockSize, buffer, decrypt).\n\n@return true if successful, false on error." + }, + "!span": "7103[232:11]-9727[332:3]", + "!doc": "Create cipher object", + "output": "+ByteBuffer" + }, + "util.nextTick.!0": { + "!type": "fn()", + "!span": "3394[115:35]-3445[117:9]" + }, + "util.parseFragment.!ret": { + "queryString": { + "!type": "string", + "!span": "63008[2417:4]-63019[2417:15]" + }, + "!span": "62982[2415:9]-63061[2420:3]", + "query": "?" + }, + "util.makeRequest.!ret": { + "query": { + "!type": "string", + "!span": "64119[2448:4]-64124[2448:9]", + "!doc": "full query string" + }, + "getPath": { + "!type": "fn(i: ?)", + "!span": "64302[2456:4]-64309[2456:11]", + "!doc": "Get path or element in path.\n\n@param i optional path index.\n\n@return path or part of path if i provided." + }, + "getQuery": { + "!type": "fn(k: ?, i: ?) -> ?|[?]", + "!span": "64641[2467:4]-64649[2467:12]", + "!doc": "Get query, values for a key, or value for a key index.\n\n@param k optional query key.\n@param i optional query key index.\n\n@return query, values for a key, or value for a key index." + }, + "getQueryLast": { + "!type": "fn(k: ?, _default: ?) -> !1", + "!span": "64917[2479:4]-64929[2479:16]" + }, + "!span": "64037[2444:12]-65136[2489:3]" + }, + "util.makeRequest.!ret.getQueryLast.!1": "[?]", + "util.estimateCores.!0": { + "!type": "fn(err: ?, cores: number)", + "!span": "5386[168:36]-5529[175:5]" + }, + "rsaPrivateKeyValidator.value.": { + "name": { + "!type": "string", + "!span": "5282[196:4]-5286[196:8]", + "!doc": "coefficient ((inverse of q) mod p)" + }, + "tagClass": { + "!type": "number", + "!span": "5321[197:4]-5329[197:12]" + }, + "type": { + "!type": "number", + "!span": "5357[198:4]-5361[198:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5386[199:4]-5397[199:15]" + }, + "capture": { + "!type": "string", + "!span": "5410[200:4]-5417[200:11]" + }, + "!span": "5234[194:5]-5446[201:3]" + }, + "rsaPublicKeyValidator.value.0": { + "name": { + "!type": "string", + "!span": "5677[213:4]-5681[213:8]", + "!doc": "modulus (n)" + }, + "tagClass": { + "!type": "number", + "!span": "5711[214:4]-5719[214:12]" + }, + "type": { + "!type": "number", + "!span": "5747[215:4]-5751[215:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5776[216:4]-5787[216:15]" + }, + "capture": { + "!type": "string", + "!span": "5800[217:4]-5807[217:11]" + }, + "!span": "5652[211:10]-5831[218:3]" + }, + "rsaPublicKeyValidator.value.1": { + "name": { + "!type": "string", + "!span": "5865[220:4]-5869[220:8]", + "!doc": "publicExponent (e)" + }, + "tagClass": { + "!type": "number", + "!span": "5900[221:4]-5908[221:12]" + }, + "type": { + "!type": "number", + "!span": "5936[222:4]-5940[222:8]" + }, + "constructed": { + "!type": "bool", + "!span": "5965[223:4]-5976[223:15]" + }, + "capture": { + "!type": "string", + "!span": "5989[224:4]-5996[224:11]" + }, + "!span": "5833[218:5]-6021[225:3]" + }, + "_modPow.!1": { + "decrypt": { + "!type": "fn(data: ?, scheme: ?, schemeOptions: ?) -> ?", + "!span": "36684[1174:6]-36691[1174:13]", + "!doc": "Decrypts the given data with this private key. The decryption scheme\nmust match the one used to encrypt the data.\n\n@param data the byte string to decrypt.\n@param scheme the decryption scheme to use:\n 'RSAES-PKCS1-V1_5' (default),\n 'RSA-OAEP',\n 'RAW', 'NONE', or null to perform raw RSA decryption.\n@param schemeOptions any scheme-specific options.\n\n@return the decrypted byte string." + }, + "sign": { + "!type": "fn(md: +ByteBuffer, scheme: ?) -> ?", + "!span": "38365[1221:6]-38369[1221:10]", + "!doc": "Signs the given digest, producing a signature.\n\nPKCS#1 supports multiple (currently two) signature schemes:\nRSASSA-PKCS1-V1_5 and RSASSA-PSS.\n\nBy default this implementation uses the \"old scheme\", i.e.\nRSASSA-PKCS1-V1_5. In order to generate a PSS signature, provide\nan instance of Forge PSS object as the scheme parameter.\n\n@param md the message digest object with the hash to sign.\n@param scheme the signature scheme to use:\n 'RSASSA-PKCS1-V1_5' or undefined for RSASSA PKCS#1 v1.5,\n a Forge PSS object for RSASSA-PSS,\n 'NONE' or null for none, DigestInfo will not be used but\n PKCS#1 v1.5 padding will still be used.\n\n@return the signature as a byte string." + }, + "read": { + "!type": "number", + "!span": "19652[656:10]-19656[656:14]" + }, + "!span": "36108[1150:12]-36202[1159:3]", + "n": "+BigInteger", + "e": "+BigInteger", + "d": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger" + }, + "_generateKeyPair.!0": { + "algorithm": { + "!type": "string", + "!span": "18660[622:6]-18669[622:15]" + }, + "state": { + "!type": "number", + "!span": "18688[623:6]-18693[623:11]" + }, + "bits": { + "!type": "number", + "!span": "18704[624:6]-18708[624:10]" + }, + "rng": { + "nextBytes": { + "!type": "fn(x: [number])", + "!span": "18345[608:4]-18354[608:13]", + "!doc": "x is an array to fill with bytes" + }, + "!span": "18722[625:6]-18725[625:9]" + }, + "eInt": { + "!type": "number", + "!span": "18738[626:6]-18742[626:10]" + }, + "qBits": { + "!type": "number", + "!span": "18823[630:6]-18828[630:11]" + }, + "pBits": { + "!type": "number", + "!span": "18847[631:6]-18852[631:11]" + }, + "pqState": { + "!type": "number", + "!span": "18880[632:6]-18887[632:13]", + "!doc": "store p or q" + }, + "keys": { + "!span": "18915[634:6]-18919[634:10]", + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "!span": "18652[621:11]-18931[635:5]", + "!doc": "create PRIMEINC algorithm state", + "e": "+BigInteger", + "p": "+BigInteger", + "q": "+BigInteger", + "num": "+BigInteger", + "p1": "+BigInteger", + "q1": "+BigInteger", + "phi": "+BigInteger", + "n": "+BigInteger" + }, + "_publicKeyFromJwk.!ret": { + "encrypt": { + "!type": "fn(data: ?, scheme: ?, schemeOptions: ?) -> ?", + "!span": "32241[1036:6]-32248[1036:13]", + "!doc": "Encrypts the given data with this public key. Newer applications\nshould use the 'RSA-OAEP' decryption scheme, 'RSAES-PKCS1-V1_5' is for\nlegacy applications.\n\n@param data the byte string to encrypt.\n@param scheme the encryption scheme to use:\n 'RSAES-PKCS1-V1_5' (default),\n 'RSA-OAEP',\n 'RAW', 'NONE', or null to perform raw RSA encryption,\n an object with an 'encode' property set to a function\n with the signature 'function(data, key)' that returns\n a binary-encoded string representing the encoded data.\n@param schemeOptions any scheme-specific options.\n\n@return the encrypted byte string." + }, + "verify": { + "!type": "fn(digest: ?, signature: ?, scheme: ?) -> bool", + "!span": "34488[1097:6]-34494[1097:12]", + "!doc": "Verifies the given signature against the given digest.\n\nPKCS#1 supports multiple (currently two) signature schemes:\nRSASSA-PKCS1-V1_5 and RSASSA-PSS.\n\nBy default this implementation uses the \"old scheme\", i.e.\nRSASSA-PKCS1-V1_5, in which case once RSA-decrypted, the\nsignature is an OCTET STRING that holds a DigestInfo.\n\nDigestInfo ::= SEQUENCE {\n digestAlgorithm DigestAlgorithmIdentifier,\n digest Digest\n}\nDigestAlgorithmIdentifier ::= AlgorithmIdentifier\nDigest ::= OCTET STRING\n\nTo perform PSS signature verification, provide an instance\nof Forge PSS object as the scheme parameter.\n\n@param digest the message digest hash to compare against the signature,\n as a binary-encoded string.\n@param signature the signature to verify, as a binary-encoded string.\n@param scheme signature verification scheme to use:\n 'RSASSA-PKCS1-V1_5' or undefined for RSASSA PKCS#1 v1.5,\n a Forge PSS object for RSASSA-PSS,\n 'NONE' or null for none, DigestInfo will not be expected, but\n PKCS#1 v1.5 padding will still be used.\n\n@return true if the signature was verified, false if not." + }, + "!span": "31482[1014:12]-31506[1017:3]", + "n": "+BigInteger", + "e": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger" + }, + "_states.SHA-512.": "[number]", + "_states.SHA-384.": "[number]", + "_states.SHA-512/256.": "[number]", + "_states.SHA-512/224.": "[number]", + "net.socketPools..sockets..connected.!0": { + "type": { + "!type": "string", + "!span": "2282[66:10]-2286[66:14]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2309[67:10]-2323[67:24]" + }, + "!span": "2245[64:28]-2350[68:9]", + "socket": "net.socketPools..sockets." + }, + "net.socketPools..sockets..closed.!0": { + "type": { + "!type": "string", + "!span": "5447[189:9]-5451[189:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "5471[190:9]-5485[190:23]" + }, + "!span": "5412[187:21]-5497[191:8]" + }, + "net.socketPools..sockets..data.!0": { + "type": { + "!type": "string", + "!span": "2617[79:8]-2621[79:12]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "2645[80:8]-2659[80:22]" + }, + "!span": "2584[77:21]-2684[81:7]" + }, + "net.socketPools..sockets..error.!0": { + "type": { + "!type": "string", + "!span": "3698[131:6]-3702[131:10]" + }, + "message": { + "!type": "string", + "!span": "3718[132:6]-3725[132:13]" + }, + "bytesAvailable": { + "!type": "number", + "!span": "3744[133:6]-3758[133:20]" + }, + "!span": "3669[129:20]-3767[134:5]" + }, + "net.socketPools..sockets..connect.!0": { + "host": { + "!type": "string", + "!span": "3256[129:6]-3260[129:10]" + }, + "policyPort": { + "!type": "number", + "!span": "3314[131:6]-3324[131:16]" + }, + "!span": "3248[128:19]-3384[133:5]" + }, + "net.socketPools..sockets..options.request.getCookies.!ret": "[http.withinCookieDomain.!1]", + "net.socketPools..sockets..options.headerReady.!0": { + "!span": "6721[253:39]-6846[257:13]", + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "net.socketPools..sockets..options.bodyReady.!0": { + "!span": "7060[264:35]-7177[268:11]", + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "net.socketPools..sockets..options.error.!0": { + "type": { + "!type": "string", + "!span": "7702[285:6]-7706[285:10]" + }, + "message": { + "!type": "string", + "!span": "7722[286:6]-7729[286:13]" + }, + "!span": "7694[284:25]-7848[290:5]", + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "net.createSocketPool.!0": { + "policyPort": { + "!type": "number", + "!span": "4170[131:4]-4180[131:14]" + }, + "msie": { + "!type": "bool", + "!span": "4226[133:4]-4230[133:8]" + }, + "!span": "4134[129:29]-4257[134:3]" + }, + "Task.prototype.fail.!0": { + "error": { + "!type": "bool", + "!span": "11925[445:9]-11930[445:14]", + "!doc": "propagate task info" + }, + "swapTime": { + "!type": "number", + "!span": "11954[446:9]-11962[446:17]" + }, + "state": { + "!type": "string", + "!span": "14796[557:7]-14801[557:12]" + } + }, + "Task.!0": { + "run": { + "!type": "fn(task: +Task)", + "!span": "17750[647:4]-17753[647:7]", + "!doc": "save run function" + }, + "name": { + "!type": "string", + "!span": "17772[648:4]-17776[648:8]" + }, + "!span": "17744[646:22]-17809[649:3]" + }, + "hmac_sha1.!1": { + "!type": "[http.withinCookieDomain.!1|hmac_sha1.!1, http.withinCookieDomain.!1]", + "!doc": "get cookie from default domain" + }, + "hmac_sha1.!2": { + "type": { + "!type": "number", + "!span": "117286[3841:8]-117290[3841:12]" + }, + "version": { + "major": { + "!type": "number", + "!span": "117334[3843:10]-117339[3843:15]" + }, + "minor": { + "!type": "number", + "!span": "117364[3844:10]-117369[3844:15]" + }, + "!span": "117313[3842:8]-117320[3842:15]" + }, + "length": { + "!type": "number", + "!span": "117402[3846:8]-117408[3846:14]" + }, + "ready": { + "!type": "bool", + "!span": "117477[3848:8]-117482[3848:13]", + "!doc": "record is now ready" + }, + "!span": "117276[3840:17]-117497[3849:7]", + "!doc": "cache the record, clear its fragment, and reset the buffer read\npointer before the type and length were read", + "fragment": "+ByteBuffer" + }, + "deflate.!2": { + "sequenceNumber": { + "!type": "[number]", + "!span": "75257[2453:6]-75271[2453:20]", + "!doc": "two 32-bit numbers, first is most significant" + }, + "macLength": { + "!type": "number", + "!span": "75307[2455:6]-75316[2455:15]" + }, + "cipherFunction": { + "!type": "fn(record: hmac_sha1.!2) -> bool", + "!span": "75377[2458:6]-75391[2458:20]" + }, + "updateSequenceNumber": { + "!type": "fn()", + "!span": "75519[2461:6]-75539[2461:26]" + }, + "update": { + "!type": "fn(c: ?, record: hmac_sha1.!2) -> bool", + "!span": "75935[2478:13]-75941[2478:19]", + "!doc": "update function in write mode will compress then encrypt a record" + }, + "!span": "75194[2451:15]-75756[2469:5]", + "!doc": "change current write state to pending write state", + "compressFunction": "deflate" + }, + "ctTable.": { + "!type": "[[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number, fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number]]", + "!doc": "map server current expect state and content type to function" + }, + "ctTable..": "[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number, fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2), fn(c: initConnectionState.!1, record: hmac_sha1.!2) -> number]", + "H5.!1": { + "type": { + "!type": "number", + "!span": "79837[2609:4]-79841[2609:8]" + }, + "version": { + "major": { + "!type": "number", + "!span": "79878[2611:6]-79883[2611:11]" + }, + "minor": { + "!type": "number", + "!span": "79908[2612:6]-79913[2612:11]" + }, + "!span": "79861[2610:4]-79868[2610:11]" + }, + "length": { + "!type": "number", + "!span": "79942[2614:4]-79948[2614:10]" + }, + "!span": "79831[2608:15]-80003[2616:3]", + "!doc": "create client key exchange message", + "fragment": "+ByteBuffer" + }, + "hsTable.": "[[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2)|fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2, length: ?)]|[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2)]]", + "hsTable..": "[fn(c: ?|initConnectionState.!1, record: ?|hmac_sha1.!2)]", + "_getStorageObject.!ret": { + "!span": "54204[2065:10]-54206[2065:12]", + "!doc": "json-encode and base64-encode object" + }, + "_callStorageFunction.!1": "[string]", + "x509CertificateValidator.value.0": { + "name": { + "!type": "string", + "!span": "4613[156:4]-4617[156:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4653[157:4]-4661[157:12]" + }, + "type": { + "!type": "number", + "!span": "4689[158:4]-4693[158:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4719[159:4]-4730[159:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4742[160:4]-4753[160:15]" + }, + "value": { + "!type": "[?]", + "!span": "4777[161:4]-4782[161:9]" + }, + "!span": "4607[155:10]-9333[294:3]" + }, + "x509CertificateValidator.value.1": { + "name": { + "!type": "string", + "!span": "9390[296:4]-9394[296:8]", + "!doc": "AlgorithmIdentifier (signature algorithm)" + }, + "tagClass": { + "!type": "number", + "!span": "9434[297:4]-9442[297:12]" + }, + "type": { + "!type": "number", + "!span": "9470[298:4]-9474[298:8]" + }, + "constructed": { + "!type": "bool", + "!span": "9500[299:4]-9511[299:15]" + }, + "value": { + "!type": "[x509CertificateValidator.value.1.value.0, x509CertificateValidator.value.1.value.1]", + "!span": "9523[300:4]-9528[300:9]" + }, + "!span": "9335[294:5]-9916[313:3]" + }, + "x509CertificateValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "9558[302:6]-9562[302:10]", + "!doc": "algorithm" + }, + "tagClass": { + "!type": "number", + "!span": "9614[303:6]-9622[303:14]" + }, + "type": { + "!type": "number", + "!span": "9652[304:6]-9656[304:10]" + }, + "constructed": { + "!type": "bool", + "!span": "9679[305:6]-9690[305:17]" + }, + "capture": { + "!type": "string", + "!span": "9705[306:6]-9712[306:13]" + }, + "!span": "9531[300:12]-9738[307:5]" + }, + "x509CertificateValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "9748[308:6]-9752[308:10]" + }, + "tagClass": { + "!type": "number", + "!span": "9811[309:6]-9819[309:14]" + }, + "optional": { + "!type": "bool", + "!span": "9849[310:6]-9857[310:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "9871[311:6]-9882[311:17]" + }, + "!span": "9740[307:7]-9911[312:5]" + }, + "x509CertificateValidator.value.2": { + "name": { + "!type": "string", + "!span": "9946[315:4]-9950[315:8]", + "!doc": "SignatureValue" + }, + "tagClass": { + "!type": "number", + "!span": "9986[316:4]-9994[316:12]" + }, + "type": { + "!type": "number", + "!span": "10022[317:4]-10026[317:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10053[318:4]-10064[318:15]" + }, + "captureBitStringValue": { + "!type": "string", + "!span": "10077[319:4]-10098[319:25]" + }, + "!span": "9918[313:5]-10119[320:3]" + }, + "rsassaPssParameterValidator.value.0": { + "name": { + "!type": "string", + "!span": "10278[329:4]-10282[329:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10312[330:4]-10320[330:12]" + }, + "type": { + "!type": "number", + "!span": "10355[331:4]-10359[331:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10368[332:4]-10379[332:15]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.0.value.]", + "!span": "10391[333:4]-10396[333:9]" + }, + "!span": "10272[328:10]-10863[348:3]" + }, + "rsassaPssParameterValidator.value.0.value.": { + "name": { + "!type": "string", + "!span": "10407[334:6]-10411[334:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[335:6]-10471[335:14]" + }, + "constructed": { + "!type": "bool", + "!span": "10534[337:6]-10545[337:17]" + }, + "optional": { + "!type": "bool", + "!span": "10559[338:6]-10567[338:14]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.0.value..value.]", + "!span": "10581[339:6]-10586[339:11]" + }, + "!span": "10399[333:12]-10858[347:5]" + }, + "rsassaPssParameterValidator.value.0.value..value.": { + "name": { + "!type": "string", + "!span": "10599[340:8]-10603[340:12]" + }, + "tagClass": { + "!type": "number", + "!span": "10667[341:8]-10675[341:16]" + }, + "type": { + "!type": "number", + "!span": "10707[342:8]-10711[342:12]" + }, + "constructed": { + "!type": "bool", + "!span": "10736[343:8]-10747[343:19]" + }, + "capture": { + "!type": "string", + "!span": "10764[344:8]-10771[344:15]" + }, + "!span": "10589[339:14]-10851[346:7]" + }, + "rsassaPssParameterValidator.value.1": { + "name": { + "!type": "string", + "!span": "10871[349:4]-10875[349:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10908[350:4]-10916[350:12]" + }, + "type": { + "!type": "number", + "!span": "10951[351:4]-10955[351:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10964[352:4]-10975[352:15]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.1.value.]", + "!span": "10987[353:4]-10992[353:9]" + }, + "!span": "10865[348:5]-11898[380:3]" + }, + "rsassaPssParameterValidator.value.1.value.": { + "name": { + "!type": "string", + "!span": "11003[354:6]-11007[354:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11062[355:6]-11070[355:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11133[357:6]-11144[357:17]" + }, + "optional": { + "!type": "bool", + "!span": "11158[358:6]-11166[358:14]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.1.value..value.0, rsassaPssParameterValidator.value.1.value..value.1]", + "!span": "11180[359:6]-11185[359:11]" + }, + "!span": "10995[353:12]-11893[379:5]" + }, + "rsassaPssParameterValidator.value.1.value..value.0": { + "name": { + "!type": "string", + "!span": "11198[360:8]-11202[360:12]" + }, + "tagClass": { + "!type": "number", + "!span": "11269[361:8]-11277[361:16]" + }, + "type": { + "!type": "number", + "!span": "11309[362:8]-11313[362:12]" + }, + "constructed": { + "!type": "bool", + "!span": "11338[363:8]-11349[363:19]" + }, + "capture": { + "!type": "string", + "!span": "11366[364:8]-11373[364:15]" + }, + "!span": "11188[359:14]-11395[365:7]" + }, + "rsassaPssParameterValidator.value.1.value..value.1": { + "name": { + "!type": "string", + "!span": "11407[366:8]-11411[366:12]" + }, + "tagClass": { + "!type": "number", + "!span": "11475[367:8]-11483[367:16]" + }, + "type": { + "!type": "number", + "!span": "11515[368:8]-11519[368:12]" + }, + "constructed": { + "!type": "bool", + "!span": "11549[369:8]-11560[369:19]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.1.value..value.1.value.]", + "!span": "11576[370:8]-11581[370:13]" + }, + "!span": "11397[365:9]-11886[378:7]" + }, + "rsassaPssParameterValidator.value.1.value..value.1.value.": { + "name": { + "!type": "string", + "!span": "11596[371:10]-11600[371:14]" + }, + "tagClass": { + "!type": "number", + "!span": "11676[372:10]-11684[372:18]" + }, + "type": { + "!type": "number", + "!span": "11718[373:10]-11722[373:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11749[374:10]-11760[374:21]" + }, + "capture": { + "!type": "string", + "!span": "11779[375:10]-11786[375:17]" + }, + "!span": "11584[370:16]-11877[377:9]" + }, + "rsassaPssParameterValidator.value.2": { + "name": { + "!type": "string", + "!span": "11906[381:4]-11910[381:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11937[382:4]-11945[382:12]" + }, + "type": { + "!type": "number", + "!span": "11980[383:4]-11984[383:8]" + }, + "optional": { + "!type": "bool", + "!span": "11993[384:4]-12001[384:12]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.2.value.]", + "!span": "12013[385:4]-12018[385:9]" + }, + "!span": "11900[380:5]-12201[392:3]" + }, + "rsassaPssParameterValidator.value.2.value.": { + "name": { + "!type": "string", + "!span": "12029[386:6]-12033[386:10]" + }, + "tagClass": { + "!type": "number", + "!span": "12073[387:6]-12081[387:14]" + }, + "constructed": { + "!type": "bool", + "!span": "12143[389:6]-12154[389:17]" + }, + "capture": { + "!type": "string", + "!span": "12169[390:6]-12176[390:13]" + }, + "!span": "12021[385:12]-12196[391:5]" + }, + "rsassaPssParameterValidator.value.3": { + "name": { + "!type": "string", + "!span": "12209[393:4]-12213[393:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12242[394:4]-12250[394:12]" + }, + "type": { + "!type": "number", + "!span": "12285[395:4]-12289[395:8]" + }, + "optional": { + "!type": "bool", + "!span": "12298[396:4]-12306[396:12]" + }, + "value": { + "!type": "[rsassaPssParameterValidator.value.3.value.]", + "!span": "12318[397:4]-12323[397:9]" + }, + "!span": "12203[392:5]-12497[404:3]" + }, + "rsassaPssParameterValidator.value.3.value.": { + "name": { + "!type": "string", + "!span": "12334[398:6]-12338[398:10]" + }, + "tagClass": { + "!type": "number", + "!span": "12372[399:6]-12380[399:14]" + }, + "constructed": { + "!type": "bool", + "!span": "12442[401:6]-12453[401:17]" + }, + "capture": { + "!type": "string", + "!span": "12468[402:6]-12475[402:13]" + }, + "!span": "12326[397:12]-12492[403:5]" + }, + "certificationRequestInfoValidator.value.0": { + "name": { + "!type": "string", + "!span": "12777[415:4]-12781[415:8]" + }, + "tagClass": { + "!type": "number", + "!span": "12823[416:4]-12831[416:12]" + }, + "type": { + "!type": "number", + "!span": "12859[417:4]-12863[417:8]" + }, + "constructed": { + "!type": "bool", + "!span": "12888[418:4]-12899[418:15]" + }, + "capture": { + "!type": "string", + "!span": "12912[419:4]-12919[419:11]" + }, + "!span": "12771[414:10]-12958[420:3]" + }, + "certificationRequestInfoValidator.value.1": { + "name": { + "!type": "string", + "!span": "13002[422:4]-13006[422:8]", + "!doc": "Name (subject) (RDNSequence)" + }, + "tagClass": { + "!type": "number", + "!span": "13048[423:4]-13056[423:12]" + }, + "type": { + "!type": "number", + "!span": "13084[424:4]-13088[424:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13114[425:4]-13125[425:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "13137[426:4]-13148[426:15]" + }, + "!span": "12960[420:5]-13187[427:3]" + }, + "certificationRequestInfoValidator.value.3": { + "name": { + "!type": "string", + "!span": "13245[431:4]-13249[431:8]" + }, + "tagClass": { + "!type": "number", + "!span": "13294[432:4]-13302[432:12]" + }, + "type": { + "!type": "number", + "!span": "13337[433:4]-13341[433:8]" + }, + "constructed": { + "!type": "bool", + "!span": "13350[434:4]-13361[434:15]" + }, + "optional": { + "!type": "bool", + "!span": "13373[435:4]-13381[435:12]" + }, + "capture": { + "!type": "string", + "!span": "13393[436:4]-13400[436:11]" + }, + "value": { + "!type": "[certificationRequestInfoValidator.value.3.value.]", + "!span": "13444[437:4]-13449[437:9]" + }, + "!span": "13239[430:2]-13954[454:3]" + }, + "certificationRequestInfoValidator.value.3.value.": { + "name": { + "!type": "string", + "!span": "13460[438:6]-13464[438:10]" + }, + "tagClass": { + "!type": "number", + "!span": "13511[439:6]-13519[439:14]" + }, + "type": { + "!type": "number", + "!span": "13549[440:6]-13553[440:10]" + }, + "constructed": { + "!type": "bool", + "!span": "13581[441:6]-13592[441:17]" + }, + "value": { + "!type": "[certificationRequestInfoValidator.value.3.value..value.0, certificationRequestInfoValidator.value.3.value..value.1]", + "!span": "13606[442:6]-13611[442:11]" + }, + "!span": "13452[437:12]-13949[453:5]" + }, + "certificationRequestInfoValidator.value.3.value..value.0": { + "name": { + "!type": "string", + "!span": "13624[443:8]-13628[443:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13682[444:8]-13690[444:16]" + }, + "type": { + "!type": "number", + "!span": "13722[445:8]-13726[445:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13751[446:8]-13762[446:19]" + }, + "!span": "13614[442:14]-13777[447:7]" + }, + "certificationRequestInfoValidator.value.3.value..value.1": { + "name": { + "!type": "string", + "!span": "13789[448:8]-13793[448:12]" + }, + "tagClass": { + "!type": "number", + "!span": "13848[449:8]-13856[449:16]" + }, + "type": { + "!type": "number", + "!span": "13888[450:8]-13892[450:12]" + }, + "constructed": { + "!type": "bool", + "!span": "13917[451:8]-13928[451:19]" + }, + "!span": "13779[447:9]-13942[452:7]" + }, + "certificationRequestValidator.value.1": { + "name": { + "!type": "string", + "!span": "14294[467:6]-14298[467:10]", + "!doc": "AlgorithmIdentifier (signature algorithm)" + }, + "tagClass": { + "!type": "number", + "!span": "14349[468:6]-14357[468:14]" + }, + "type": { + "!type": "number", + "!span": "14387[469:6]-14391[469:10]" + }, + "constructed": { + "!type": "bool", + "!span": "14419[470:6]-14430[470:17]" + }, + "value": { + "!type": "[certificationRequestValidator.value.1.value.0, certificationRequestValidator.value.1.value.1]", + "!span": "14444[471:6]-14449[471:11]" + }, + "!span": "14235[465:39]-14873[484:5]" + }, + "certificationRequestValidator.value.1.value.0": { + "name": { + "!type": "string", + "!span": "14483[473:8]-14487[473:12]", + "!doc": "algorithm" + }, + "tagClass": { + "!type": "number", + "!span": "14550[474:8]-14558[474:16]" + }, + "type": { + "!type": "number", + "!span": "14590[475:8]-14594[475:12]" + }, + "constructed": { + "!type": "bool", + "!span": "14619[476:8]-14630[476:19]" + }, + "capture": { + "!type": "string", + "!span": "14647[477:8]-14654[477:15]" + }, + "!span": "14452[471:14]-14681[478:7]" + }, + "certificationRequestValidator.value.1.value.1": { + "name": { + "!type": "string", + "!span": "14693[479:8]-14697[479:12]" + }, + "tagClass": { + "!type": "number", + "!span": "14761[480:8]-14769[480:16]" + }, + "optional": { + "!type": "bool", + "!span": "14801[481:8]-14809[481:16]" + }, + "captureAsn1": { + "!type": "string", + "!span": "14825[482:8]-14836[482:19]" + }, + "!span": "14683[478:9]-14866[483:7]" + }, + "certificationRequestValidator.value.2": { + "name": { + "!type": "string", + "!span": "14902[486:6]-14906[486:10]", + "!doc": "signature" + }, + "tagClass": { + "!type": "number", + "!span": "14948[487:6]-14956[487:14]" + }, + "type": { + "!type": "number", + "!span": "14986[488:6]-14990[488:10]" + }, + "constructed": { + "!type": "bool", + "!span": "15019[489:6]-15030[489:17]" + }, + "captureBitStringValue": { + "!type": "string", + "!span": "15045[490:6]-15066[490:27]" + }, + "!span": "14875[484:7]-15088[491:5]" + }, + "_getAttribute.!0": { + "version": { + "!type": "number", + "!span": "54558[1755:6]-54565[1755:13]" + }, + "signatureOid": { + "!type": "string", + "!span": "54580[1756:6]-54592[1756:18]" + }, + "siginfo": { + "algorithmOid": { + "!type": "string", + "!span": "54659[1759:14]-54671[1759:26]" + }, + "!span": "54631[1758:6]-54638[1758:13]", + "parameters": "_readSignatureParameters.!ret" + }, + "subject": { + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "attributes": "pki.RDNAttributesAsArray.!ret", + "getField": "_dnToAsn1.!0.getField", + "addField": "_dnToAsn1.!0.addField" + }, + "getAttribute": { + "!type": "fn(sn: ?) -> _getAttribute.!ret", + "!span": "55019[1774:6]-55031[1774:18]", + "!doc": "convert attributes from ASN.1" + }, + "addAttribute": { + "!type": "fn(attr: ?)", + "!span": "55095[1777:6]-55107[1777:18]" + }, + "setSubject": { + "!type": "fn(attrs: ?)", + "!span": "55347[1788:6]-55357[1788:16]", + "!doc": "Sets the subject of this certification request.\n\n@param attrs the array of subject attributes to use." + }, + "setAttributes": { + "!type": "fn(attrs: ?)", + "!span": "55635[1800:6]-55648[1800:19]", + "!doc": "Sets the attributes of this certification request.\n\n@param attrs the array of attributes to use." + }, + "sign": { + "!type": "fn(key: ?, md: ?)", + "!span": "55973[1812:6]-55977[1812:10]", + "!doc": "Signs this certification request using the given private key.\n\n@param key the private key to sign with.\n@param md the message digest object to use (defaults to forge.md.sha1)." + }, + "verify": { + "!type": "fn() -> bool", + "!span": "57085[1844:6]-57091[1844:12]", + "!doc": "Attempts verify the signature on the passed certification request using\nits public key.\n\nA CSR that has been exported to a file in PEM format can be verified using\nOpenSSL using this command:\n\nopenssl req -in -verify -noout -text\n\n@return true if verified, false if not." + }, + "signatureParameters": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + } + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + } + } + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + } + }, + "!span": "54548[1754:12]-54550[1754:14]", + "!doc": "create certification request", + "publicKey": "_publicKeyFromJwk.!ret", + "attributes": "pki.CRIAttributesAsArray.!ret", + "md": "_createKDF.!1", + "certificationRequestInfo": "_fromDer.!ret" + }, + "_getAttribute.!1": { + "!span": "18162[595:14]-18182[595:34]", + "shortName": "_getAttribute.!1" + }, + "_getAttribute.!ret": { + "type": { + "!type": "string", + "!span": "17085[558:10]-17089[558:14]" + }, + "name": { + "!type": "string", + "!span": "17276[563:12]-17280[563:16]" + }, + "extensions": { + "!type": "[pki.certificateExtensionFromAsn1.!ret]", + "!span": "17489[570:12]-17499[570:22]" + }, + "!span": "17071[557:16]-17073[557:18]" + }, + "_readSignatureParameters.!ret": { + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19751[652:8]-19763[652:20]" + }, + "!span": "19735[651:6]-19739[651:10]" + }, + "mgf": { + "algorithmOid": { + "!type": "string", + "!span": "19808[655:8]-19820[655:20]" + }, + "hash": { + "algorithmOid": { + "!type": "string", + "!span": "19862[657:10]-19874[657:22]" + }, + "!span": "19844[656:8]-19848[656:12]" + }, + "!span": "19793[654:6]-19796[654:9]" + }, + "saltLength": { + "!type": "number", + "!span": "19914[660:6]-19924[660:16]" + }, + "!span": "19727[650:13]-19934[661:5]" + }, + "_dnToAsn1.!0": { + "getField": { + "!type": "fn(sn: ?) -> _getAttribute.!ret", + "!span": "54715[1762:14]-54723[1762:22]" + }, + "addField": { + "!type": "fn(attr: ?)", + "!span": "54803[1765:14]-54811[1765:22]" + }, + "hash": { + "!type": "string", + "!span": "54952[1770:14]-54956[1770:18]" + }, + "!span": "54697[1761:16]-54699[1761:18]", + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "_getAttributesAsJson.!ret": { + "": { + "!type": "[_getAttributesAsJson.!ret., ?]", + "!span": "62302[2012:13]-62316[2012:27]" + }, + "!span": "61856[2000:13]-61858[2000:15]" + }, + "_fillMissingFields.!0": "[?]", + "_fillMissingExtensionFields.!0": { + "name": { + "!type": "string", + "!span": "64592[2096:8]-64596[2096:12]" + }, + "id": { + "!type": "string", + "!span": "64734[2103:8]-64736[2103:10]" + }, + "subjectKeyIdentifier": { + "!type": "string", + "!span": "69648[2290:6]-69668[2290:26]" + }, + "value": "_fromDer.!ret" + }, + "_fillMissingExtensionFields.!1": { + "!span": "29909[993:43]-29921[993:55]", + "cert": "pki.certificateFromPem.!ret" + }, + "xhrApi.create.!ret": { + "readyState": { + "!type": "number", + "!span": "11722[366:4]-11732[366:14]", + "!doc": "7. set state to UNSENT" + }, + "responseText": { + "!type": "string", + "!span": "11792[368:4]-11804[368:16]", + "!doc": "3. set response to null" + }, + "responseXML": { + "async": { + "!type": "bool", + "!span": "18241[587:16]-18246[587:21]" + }, + "!span": "11872[370:4]-11883[370:15]", + "!doc": "a Document for response entity-bodies that are XML" + }, + "status": { + "!type": "number", + "!span": "11952[372:4]-11958[372:10]", + "!doc": "custom: reset status and statusText" + }, + "statusText": { + "!type": "string", + "!span": "12035[374:4]-12045[374:14]", + "!doc": "readonly, returns the HTTP status message (i.e. 'Not Found')" + }, + "open": { + "!type": "fn(method: ?, url: ?, async: ?, user: ?, password: ?)", + "!span": "13513[424:6]-13517[424:10]", + "!doc": "Opens the request. This method will create the HTTP request to send.\n\n@param method the HTTP method (i.e. 'GET').\n@param url the relative url (the HTTP request path).\n@param async always true, ignored.\n@param user always null, ignored.\n@param password always null, ignored." + }, + "setRequestHeader": { + "!type": "fn(header: ?, value: ?)", + "!span": "15241[489:6]-15257[489:22]", + "!doc": "Adds an HTTP header field to the request.\n\n@param header the name of the header field.\n@param value the value of the header field." + }, + "send": { + "!type": "fn(data: ?)", + "!span": "15747[506:6]-15751[506:10]", + "!doc": "Sends the request and any associated data.\n\n@param data a string or Document object to send, null to send no data." + }, + "abort": { + "!type": "fn()", + "!span": "20103[654:6]-20108[654:11]", + "!doc": "Aborts the request." + }, + "getAllResponseHeaders": { + "!type": "fn() -> string", + "!span": "21224[699:6]-21245[699:27]", + "!doc": "Gets all response headers as a string.\n\n@return the HTTP-encoded response header fields." + }, + "getResponseHeader": { + "!type": "fn(header: ?) -> [string]|string", + "!span": "21758[719:6]-21775[719:23]", + "!doc": "Gets a single header field value or, if there are multiple\nfields with the same name, a comma-separated list of header\nvalues.\n\n@return the header field value(s) or null." + }, + "!span": "11622[362:12]-12053[375:3]", + "!doc": "create public xhr interface", + "cookies": "_getStorageId.!0.cookies" + }, + "BlockCipher._op.!0": { + "read": { + "!type": "number", + "!span": "19360[681:12]-19364[681:16]" + } + }, + "BlockCipher.start.!1": { + "!span": "20298[486:16]-20300[486:18]", + "output": "BlockCipher.start.!1" + }, + "modes.gcm._m.": "[[number]]", + "modes.gcm._m..": "[number, number, number, number]", + "forge.aes.Algorithm.!1.prototype.generateHashTable.!ret": { + "": { + "": "modes.gcm._m.." + } + }, + "forge.aes.Algorithm.!1.prototype.generateSubHashTable.!ret": { + "": "modes.gcm._m.." + }, + "forge.cipher.modes.cbc.prototype.start.!0": { + "output": "BlockCipher.start.!1" + }, + "forge.cipher.modes.gcm.prototype.generateHashTable.!ret": { + "": { + "": "modes.gcm._m.." + } + }, + "forge.cipher.modes.gcm.prototype.generateSubHashTable.!ret": { + "": "modes.gcm._m.." + }, + "forge.pki.ed25519.generateKeyPair.!ret": { + "publicKey": "+Float32Array", + "privateKey": "+Float32Array" + }, + "forge.pki.pbe.getCipher.!ret": { + "output": "+ByteBuffer", + "start": "createCipher.!ret.start", + "update": "createCipher.!ret.update", + "finish": "createCipher.!ret.finish" + }, + "forge.pki.setRsaPublicKey.!ret": { + "n": "+BigInteger", + "e": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "encrypt": "_publicKeyFromJwk.!ret.encrypt", + "verify": "_publicKeyFromJwk.!ret.verify" + }, + "forge.pki.rsa.generateKeyPair.!ret": { + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "forge.pki.certificateFromPem.!ret.issuer.getField.!0": { + "shortName": "_getAttribute.!1" + }, + "forge.pki.certificationRequestFromPem.!ret.getAttribute.!0": { + "shortName": "_getAttribute.!1" + }, + "forge.pki.distinguishedNameToAsn1.!0": { + "attributes": "pki.RDNAttributesAsArray.!ret" + }, + "forge.pki.verifyCertificateChain.!1": { + "": "pki.certificateFromPem.!ret" + }, + "forge.ed25519.generateKeyPair.!0": { + "seed": "+Float32Array" + }, + "forge.ed25519.generateKeyPair.!ret": { + "publicKey": "+Float32Array", + "privateKey": "+Float32Array" + }, + "forge.hmac.create.!ret": { + "digest": "hmac.create.!ret.getMac", + "start": "hmac.create.!ret.start", + "update": "hmac.create.!ret.update", + "getMac": "hmac.create.!ret.getMac" + }, + "forge.http.createClient.!0.socketPool.sockets..options.request.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.http.createClient.!0.socketPool.sockets..options.headerReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!0.socketPool.sockets..options.bodyReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.requests..request.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.http.createClient.!ret.requests..headerReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.requests..bodyReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.http.createClient.!ret.send.!0": { + "request": "net.socketPools..sockets..options.request", + "bodyReady": "net.socketPools..sockets..options.bodyReady", + "error": "net.socketPools..sockets..options.error", + "headerReady": "_getStorageId.!0.send.!0.headerReady" + }, + "forge.http.createRequest.!ret.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.jsbn.BigInteger.prototype.divideAndRemainder.!ret": { + "": "+BigInteger" + }, + "forge.mgf.mgf1.create.!ret": { + "generate": "mgf1.create.!ret.generate" + }, + "forge.pbe.getCipher.!ret": { + "output": "+ByteBuffer", + "start": "createCipher.!ret.start", + "update": "createCipher.!ret.update", + "finish": "createCipher.!ret.finish" + }, + "forge.pkcs12.pkcs12FromAsn1.!ret.getBags.!ret": { + "": { + "": "_getBagsByAttribute.!ret." + }, + "localKeyId": "_getBagsByAttribute.!ret", + "friendlyName": "_getBagsByAttribute.!ret" + }, + "forge.pkcs12.pkcs12FromAsn1.!ret.getBagsByFriendlyName.!ret": { + "": "_getBagsByAttribute.!ret." + }, + "forge.prng.create.!0": { + "md": "sha256", + "formatKey": "forge.random.plugin.formatKey", + "formatSeed": "forge.random.plugin.formatSeed", + "cipher": "forge.random.plugin.cipher", + "increment": "forge.random.plugin.increment" + }, + "forge.rsa.generateKeyPair.!ret": { + "privateKey": "_modPow.!1", + "publicKey": "_publicKeyFromJwk.!ret" + }, + "forge.net.socketPools..sockets..options.request.getCookies.!ret": { + "": "http.withinCookieDomain.!1" + }, + "forge.net.socketPools..sockets..options.headerReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.net.socketPools..sockets..options.bodyReady.!0": { + "request": "net.socketPools..sockets..options.request", + "response": "net.socketPools..sockets..options.request", + "socket": "net.socketPools..sockets." + }, + "forge.tls.hmac_sha1.!1": { + "1": "http.withinCookieDomain.!1" + }, + "forge.util.setItem.!3": { + "": { + "": "http.withinCookieDomain.!1" + } + }, + "forge.util.makeRequest.!ret.getQueryLast.!1": { + "": "util.makeRequest.!ret.getQueryLast.!1" + }, + "forge.util.deflate.!0": { + "encode": "api.encode", + "decode": "api.decode" + }, + "modes.cbc.prototype.start.!0": { + "output": "BlockCipher.start.!1" + }, + "modes.gcm.prototype.generateHashTable.!ret": { + "": { + "": "modes.gcm._m.." + } + }, + "modes.gcm.prototype.generateSubHashTable.!ret": { + "": "modes.gcm._m.." + }, + "BigInteger.prototype.divideAndRemainder.!ret": { + "": "+BigInteger" + }, + "http.createClient.!ret.send.!0": { + "request": "net.socketPools..sockets..options.request", + "bodyReady": "net.socketPools..sockets..options.bodyReady", + "error": "net.socketPools..sockets..options.error", + "headerReady": "_getStorageId.!0.send.!0.headerReady" + }, + "forge.pki.createCaStore.!ret": { + "certs": "_initSocket.!2.caStore.certs", + "getIssuer": "_initSocket.!2.caStore.getIssuer", + "addCertificate": "_initSocket.!2.caStore.addCertificate", + "hasCertificate": "_initSocket.!2.caStore.hasCertificate", + "listAllCertificates": "_initSocket.!2.caStore.listAllCertificates", + "removeCertificate": "_initSocket.!2.caStore.removeCertificate" + }, + "forge.mgf1.create.!ret": { + "generate": "mgf1.create.!ret.generate" + }, + "pki.setRsaPublicKey.!ret": { + "n": "+BigInteger", + "e": "+BigInteger", + "dP": "+BigInteger", + "dQ": "+BigInteger", + "qInv": "+BigInteger", + "encrypt": "_publicKeyFromJwk.!ret.encrypt", + "verify": "_publicKeyFromJwk.!ret.verify" + }, + "pki.certificationRequestFromPem.!ret.getAttribute.!0": { + "shortName": "_getAttribute.!1" + }, + "forge.pki.verifyCertificateChain.!2": { + "verify": "pki.verifyCertificateChain.!2.verify" + }, + "p12.pkcs12FromAsn1.!ret.getBags.!ret": { + "": "_getBagsByAttribute.!ret", + "localKeyId": "_getBagsByAttribute.!ret", + "friendlyName": "_getBagsByAttribute.!ret" + }, + "p12.pkcs12FromAsn1.!ret.getBagsByFriendlyName.!ret": { + "": "_getBagsByAttribute.!ret." + }, + "forge.pss.create.!ret": { + "encode": "pss.create.!ret.encode", + "verify": "pss.create.!ret.verify" + }, + "_getAttribute.!0.getAttribute.!0": { + "shortName": "_getAttribute.!1" + } + }, + "forge": { + "aes": { + "startEncrypting": { + "!type": "fn(key: ?, iv: ?, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "1267[44:10]-1282[44:25]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('AES-', key);\ncipher.start({iv: iv});\n\nCreates an AES cipher object to encrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as a string of bytes, an array of bytes,\na byte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "createEncryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: string) -> ?|+BlockCipher", + "!span": "1900[70:10]-1922[70:32]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('AES-', key);\n\nCreates an AES cipher object to encrypt data using the given symmetric key.\n\nThe key may be given as a string of bytes, an array of bytes, a\nbyte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "startDecrypting": { + "!type": "fn(key: ?, iv: ?, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "2707[98:10]-2722[98:25]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('AES-', key);\ndecipher.start({iv: iv});\n\nCreates an AES cipher object to decrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as a string of bytes, an array of bytes,\na byte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "createDecryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: ?) -> ?|+BlockCipher", + "!span": "3343[124:10]-3365[124:32]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('AES-', key);\n\nCreates an AES cipher object to decrypt data using the given symmetric key.\n\nThe key may be given as a string of bytes, an array of bytes, a\nbyte buffer, or an array of 32-bit words.\n\n@param key the symmetric key to use.\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "Algorithm": { + "prototype": { + "initialize": { + "!type": "fn(options: ?)", + "!span": "4425[169:30]-4435[169:40]", + "!doc": "Initializes this AES algorithm by expanding its key.\n\n@param options the options to use.\n key the key to use with this algorithm.\n decrypt true if the algorithm should be initialized for decryption,\n false for encryption." + } + }, + "!type": "fn(name: string, mode: fn(options: ?))", + "!span": "3682[141:10]-3691[141:19]", + "!doc": "Creates a new AES cipher algorithm object.\n\n@param name the name of the algorithm.\n@param mode the mode factory function.\n\n@return the AES algorithm object." + }, + "_expandKey": { + "!type": "fn(key: [?]|string, decrypt: bool) -> ?", + "!span": "6340[234:10]-6350[234:20]", + "!doc": "Expands a key. Typically only used for testing.\n\n@param key the symmetric key to expand, as an array of 32-bit words.\n@param decrypt true to expand for decryption, false for encryption.\n\n@return the expanded key." + }, + "!span": "591[23:23]-594[23:26]", + "!doc": "AES API", + "_updateBlock": "_updateBlock" + }, + "asn1": { + "Class": { + "UNIVERSAL": { + "!type": "number", + "!span": "6382[146:2]-6391[146:11]" + }, + "APPLICATION": { + "!type": "number", + "!span": "6408[147:2]-6419[147:13]" + }, + "CONTEXT_SPECIFIC": { + "!type": "number", + "!span": "6434[148:2]-6450[148:18]" + }, + "PRIVATE": { + "!type": "number", + "!span": "6460[149:2]-6467[149:9]" + } + }, + "Type": { + "NONE": { + "!type": "number", + "!span": "6646[157:2]-6650[157:6]" + }, + "BOOLEAN": { + "!type": "number", + "!span": "6669[158:2]-6676[158:9]" + }, + "INTEGER": { + "!type": "number", + "!span": "6692[159:2]-6699[159:9]" + }, + "BITSTRING": { + "!type": "number", + "!span": "6715[160:2]-6724[160:11]" + }, + "OCTETSTRING": { + "!type": "number", + "!span": "6738[161:2]-6749[161:13]" + }, + "NULL": { + "!type": "number", + "!span": "6761[162:2]-6765[162:6]" + }, + "OID": { + "!type": "number", + "!span": "6784[163:2]-6787[163:5]" + }, + "ODESC": { + "!type": "number", + "!span": "6807[164:2]-6812[164:7]" + }, + "EXTERNAL": { + "!type": "number", + "!span": "6830[165:2]-6838[165:10]" + }, + "REAL": { + "!type": "number", + "!span": "6853[166:2]-6857[166:6]" + }, + "ENUMERATED": { + "!type": "number", + "!span": "6876[167:2]-6886[167:12]" + }, + "EMBEDDED": { + "!type": "number", + "!span": "6899[168:2]-6907[168:10]" + }, + "UTF8": { + "!type": "number", + "!span": "6922[169:2]-6926[169:6]" + }, + "ROID": { + "!type": "number", + "!span": "6945[170:2]-6949[170:6]" + }, + "SEQUENCE": { + "!type": "number", + "!span": "6968[171:2]-6976[171:10]" + }, + "SET": { + "!type": "number", + "!span": "6991[172:2]-6994[172:5]" + }, + "PRINTABLESTRING": { + "!type": "number", + "!span": "7014[173:2]-7029[173:17]" + }, + "IA5STRING": { + "!type": "number", + "!span": "7037[174:2]-7046[174:11]" + }, + "UTCTIME": { + "!type": "number", + "!span": "7060[175:2]-7067[175:9]" + }, + "GENERALIZEDTIME": { + "!type": "number", + "!span": "7083[176:2]-7098[176:17]" + }, + "BMPSTRING": { + "!type": "number", + "!span": "7106[177:2]-7115[177:11]" + } + }, + "create": {}, + "validate": {}, + "prettyPrint": {}, + "copy": "asn1.copy", + "equals": "asn1.equals", + "getBerValueLength": "asn1.getBerValueLength", + "fromDer": "asn1.fromDer", + "toDer": "asn1.toDer", + "oidToDer": "asn1.oidToDer", + "derToOid": "asn1.derToOid", + "utcTimeToDate": "asn1.utcTimeToDate", + "generalizedTimeToDate": "asn1.generalizedTimeToDate", + "dateToUtcTime": "asn1.dateToUtcTime", + "dateToGeneralizedTime": "asn1.dateToGeneralizedTime", + "integerToDer": "asn1.integerToDer", + "derToInteger": "asn1.derToInteger" + }, + "cipher": { + "algorithms": { + "": { + "!type": "fn() -> +forge.des.Algorithm", + "!span": "2382[90:26]-2386[90:30]" + }, + "!span": "249[13:22]-259[13:32]", + "!doc": "registered algorithms" + }, + "createCipher": { + "!type": "fn(algorithm: string, key: string) -> +BlockCipher", + "!span": "781[30:15]-793[30:27]", + "!doc": "Creates a cipher object that can be used to encrypt data using the given\nalgorithm and key. The algorithm may be provided as a string value for a\npreviously registered algorithm or it may be given as a cipher algorithm\nAPI object.\n\n@param algorithm the algorithm to use, either a string or an algorithm API\n object.\n@param key the key to use, as a binary-encoded string of bytes or a\n byte buffer.\n\n@return the cipher." + }, + "createDecipher": { + "!type": "fn(algorithm: string, key: string) -> +BlockCipher", + "!span": "1658[67:0]-1672[69:10]", + "!doc": "Creates a decipher object that can be used to decrypt data using the given\nalgorithm and key. The algorithm may be provided as a string value for a\npreviously registered algorithm or it may be given as a cipher algorithm\nAPI object.\n\n@param algorithm the algorithm to use, either a string or an algorithm API\n object.\n@param key the key to use, as a binary-encoded string of bytes or a\n byte buffer.\n\n@return the cipher." + }, + "registerAlgorithm": { + "!type": "fn(name: string, algorithm: fn() -> +forge.des.Algorithm)", + "!span": "2279[87:29]-2296[88:8]", + "!doc": "Registers an algorithm by name. If the name was already registered, the\nalgorithm API object will be overwritten.\n\n@param name the name of the algorithm.\n@param algorithm the algorithm API object." + }, + "getAlgorithm": { + "!type": "fn(name: ?) -> fn() -> +forge.des.Algorithm", + "!span": "2563[102:30]-2575[102:42]", + "!doc": "Gets a registered algorithm by name.\n\n@param name the name of the algorithm.\n\n@return the algorithm, if found, null if not." + }, + "BlockCipher": { + "prototype": { + "start": "BlockCipher.prototype.start", + "update": "BlockCipher.prototype.update", + "finish": "BlockCipher.prototype.finish" + } + }, + "modes": { + "ecb": { + "prototype": { + "unpad": {}, + "start": "modes.ecb.prototype.start", + "encrypt": "modes.ecb.prototype.encrypt", + "decrypt": "modes.ecb.prototype.decrypt", + "pad": "modes.ecb.prototype.pad" + } + }, + "cfb": { + "prototype": { + "encrypt": {}, + "decrypt": {}, + "start": "modes.cfb.prototype.start" + } + }, + "ofb": { + "prototype": { + "encrypt": {}, + "decrypt": "modes.ofb.prototype.encrypt", + "start": "modes.ofb.prototype.start" + } + }, + "ctr": { + "prototype": { + "encrypt": {}, + "decrypt": "modes.ctr.prototype.encrypt", + "start": "modes.ctr.prototype.start" + } + }, + "gcm": { + "prototype": { + "encrypt": {}, + "generateHashTable": {}, + "generateSubHashTable": {}, + "start": "modes.gcm.prototype.start", + "decrypt": "modes.gcm.prototype.decrypt", + "afterFinish": "modes.gcm.prototype.afterFinish", + "multiply": "modes.gcm.prototype.multiply", + "pow": "modes.gcm.prototype.pow", + "tableMultiply": "modes.gcm.prototype.tableMultiply", + "ghash": "modes.gcm.prototype.ghash" + } + }, + "cbc": { + "prototype": { + "start": {}, + "encrypt": "modes.cbc.prototype.encrypt", + "decrypt": "modes.cbc.prototype.decrypt", + "pad": "modes.cbc.prototype.pad", + "unpad": "modes.cbc.prototype.unpad" + } + } + }, + "!span": "181[10:23]-187[10:29]" + }, + "des": { + "startEncrypting": { + "!type": "fn(key: ?, iv: ?, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "2115[59:10]-2130[59:25]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('DES-', key);\ncipher.start({iv: iv});\n\nCreates an DES cipher object to encrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as binary-encoded strings of bytes or\nbyte buffers.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC' if IV is\n given, 'ECB' if null).\n\n@return the cipher." + }, + "createEncryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: ?) -> ?|+BlockCipher", + "!span": "2764[84:10]-2786[84:32]", + "!doc": "Deprecated. Instead, use:\n\nvar cipher = forge.cipher.createCipher('DES-', key);\n\nCreates an DES cipher object to encrypt data using the given symmetric key.\n\nThe key may be given as a binary-encoded string of bytes or a byte buffer.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "startDecrypting": { + "!type": "fn(key: +ByteBuffer, iv: +ByteBuffer, output: ?, mode: ?) -> ?|+BlockCipher", + "!span": "3597[113:10]-3612[113:25]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('DES-', key);\ndecipher.start({iv: iv});\n\nCreates an DES cipher object to decrypt data using the given symmetric key.\nThe output will be stored in the 'output' member of the returned cipher.\n\nThe key and iv may be given as binary-encoded strings of bytes or\nbyte buffers.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n@param mode the cipher mode to use (default: 'CBC' if IV is\n given, 'ECB' if null).\n\n@return the cipher." + }, + "createDecryptionCipher": { + "!type": "fn(key: string|+ByteBuffer, mode: ?) -> ?|+BlockCipher", + "!span": "4249[138:10]-4271[138:32]", + "!doc": "Deprecated. Instead, use:\n\nvar decipher = forge.cipher.createDecipher('DES-', key);\n\nCreates an DES cipher object to decrypt data using the given symmetric key.\n\nThe key may be given as a binary-encoded string of bytes or a byte buffer.\n\n@param key the symmetric key to use (64 or 192 bits).\n@param mode the cipher mode to use (default: 'CBC').\n\n@return the cipher." + }, + "Algorithm": { + "prototype": { + "initialize": { + "!type": "fn(options: ?)", + "!span": "5300[180:30]-5310[180:40]", + "!doc": "Initializes this DES algorithm by expanding its key.\n\n@param options the options to use.\n key the key to use with this algorithm.\n decrypt true if the algorithm should be initialized for decryption,\n false for encryption." + } + }, + "!type": "fn(name: string, mode: fn(options: ?))", + "!span": "4588[155:10]-4597[155:19]", + "!doc": "Creates a new DES cipher algorithm object.\n\n@param name the name of the algorithm.\n@param mode the mode factory function.\n\n@return the DES algorithm object.", + "_keys": { + "!type": "[number]", + "!span": "5647[193:7]-5652[193:12]", + "!doc": "do key expansion to 16 or 48 subkeys (single or triple DES)" + }, + "_init": { + "!type": "bool", + "!span": "5680[194:7]-5685[194:12]" + }, + "name": { + "!type": "string", + "!span": "4649[157:7]-4653[157:11]" + } + }, + "!span": "1413[37:23]-1416[37:26]", + "!doc": "DES API" + }, + "pki": { + "ed25519": { + "constants": { + "PUBLIC_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1017[35:18]-1039[35:40]" + }, + "PRIVATE_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1064[36:18]-1087[36:41]" + }, + "SEED_BYTE_LENGTH": { + "!type": "number", + "!span": "1112[37:18]-1128[37:34]" + }, + "SIGN_BYTE_LENGTH": { + "!type": "number", + "!span": "1153[38:18]-1169[38:34]" + }, + "HASH_BYTE_LENGTH": { + "!type": "number", + "!span": "1194[39:18]-1210[39:34]" + } + }, + "generateKeyPair": {}, + "privateKeyFromAsn1": "ed25519.privateKeyFromAsn1", + "publicKeyFromAsn1": "ed25519.publicKeyFromAsn1", + "publicKeyFromPrivateKey": "ed25519.publicKeyFromPrivateKey", + "sign": "ed25519.sign", + "verify": "ed25519.verify" + }, + "oids": { + "": { + "!type": "string", + "!span": "331[14:7]-333[14:9]" + } + }, + "pbe": { + "generatePkcs12Key": {}, + "opensslDeriveBytes": {}, + "getCipher": {}, + "getCipherForPBES2": "forge.pbe.getCipherForPBES2", + "getCipherForPKCS12PBE": "forge.pbe.getCipherForPKCS12PBE" + }, + "encryptPrivateKeyInfo": {}, + "encryptedPrivateKeyFromPem": {}, + "privateKeyFromPem": {}, + "rsa": { + "publicKeyValidator": { + "name": { + "!type": "string", + "!span": "6195[231:2]-6199[231:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6227[232:2]-6235[232:10]" + }, + "type": { + "!type": "number", + "!span": "6261[233:2]-6265[233:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6289[234:2]-6300[234:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6310[235:2]-6321[235:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + } + } + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + } + } + } + } + } + }, + "createKeyPairGenerationState": {}, + "generateKeyPair": {}, + "setPublicKey": "pki.setRsaPublicKey", + "setPrivateKey": "pki.setRsaPrivateKey", + "encrypt": "forge.rsa.encrypt", + "decrypt": "forge.rsa.decrypt", + "stepKeyPairGenerationState": "forge.rsa.stepKeyPairGenerationState" + }, + "RDNAttributesAsArray": {}, + "CRIAttributesAsArray": {}, + "certificateFromPem": {}, + "getPublicKeyFingerprint": {}, + "certificationRequestFromPem": {}, + "certificateExtensionsFromAsn1": {}, + "certificateExtensionFromAsn1": {}, + "certificateError": { + "bad_certificate": { + "!type": "string", + "!span": "88809[2935:2]-88824[2935:17]" + }, + "unsupported_certificate": { + "!type": "string", + "!span": "88856[2936:2]-88879[2936:25]" + }, + "certificate_revoked": { + "!type": "string", + "!span": "88919[2937:2]-88938[2937:21]" + }, + "certificate_expired": { + "!type": "string", + "!span": "88974[2938:2]-88993[2938:21]" + }, + "certificate_unknown": { + "!type": "string", + "!span": "89029[2939:2]-89048[2939:21]" + }, + "unknown_ca": { + "!type": "string", + "!span": "89084[2940:2]-89094[2940:12]" + } + }, + "setRsaPublicKey": {}, + "privateKeyToAsn1": "pki.privateKeyToRSAPrivateKey", + "publicKeyToAsn1": "pki.publicKeyToSubjectPublicKeyInfo", + "distinguishedNameToAsn1": {}, + "verifyCertificateChain": {}, + "createCaStore": {}, + "decryptPrivateKeyInfo": "pki.decryptPrivateKeyInfo", + "encryptedPrivateKeyToPem": "pki.encryptedPrivateKeyToPem", + "encryptRsaPrivateKey": "pki.encryptRsaPrivateKey", + "decryptRsaPrivateKey": "pki.decryptRsaPrivateKey", + "pemToDer": "pki.pemToDer", + "privateKeyToPem": "pki.privateKeyToPem", + "privateKeyInfoToPem": "pki.privateKeyInfoToPem", + "setRsaPrivateKey": "pki.setRsaPrivateKey", + "wrapRsaPrivateKey": "pki.wrapRsaPrivateKey", + "privateKeyFromAsn1": "pki.privateKeyFromAsn1", + "privateKeyToRSAPrivateKey": "pki.privateKeyToRSAPrivateKey", + "publicKeyFromAsn1": "pki.publicKeyFromAsn1", + "publicKeyToSubjectPublicKeyInfo": "pki.publicKeyToSubjectPublicKeyInfo", + "publicKeyToRSAPublicKey": "pki.publicKeyToRSAPublicKey", + "certificateToPem": "pki.certificateToPem", + "publicKeyFromPem": "pki.publicKeyFromPem", + "publicKeyToPem": "pki.publicKeyToPem", + "publicKeyToRSAPublicKeyPem": "pki.publicKeyToRSAPublicKeyPem", + "certificationRequestToPem": "pki.certificationRequestToPem", + "createCertificate": "pki.createCertificate", + "certificateFromAsn1": "pki.certificateFromAsn1", + "certificationRequestFromAsn1": "pki.certificationRequestFromAsn1", + "createCertificationRequest": "pki.createCertificationRequest", + "getTBSCertificate": "pki.getTBSCertificate", + "getCertificationRequestInfo": "pki.getCertificationRequestInfo", + "certificateToAsn1": "pki.certificateToAsn1", + "certificateExtensionsToAsn1": "pki.certificateExtensionsToAsn1", + "certificateExtensionToAsn1": "pki.certificateExtensionToAsn1", + "certificationRequestToAsn1": "pki.certificationRequestToAsn1" + }, + "ed25519": { + "constants": { + "PUBLIC_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1017[35:18]-1039[35:40]" + }, + "PRIVATE_KEY_BYTE_LENGTH": { + "!type": "number", + "!span": "1064[36:18]-1087[36:41]" + }, + "SEED_BYTE_LENGTH": { + "!type": "number", + "!span": "1112[37:18]-1128[37:34]" + }, + "SIGN_BYTE_LENGTH": { + "!type": "number", + "!span": "1153[38:18]-1169[38:34]" + }, + "HASH_BYTE_LENGTH": { + "!type": "number", + "!span": "1194[39:18]-1210[39:34]" + } + }, + "generateKeyPair": {}, + "privateKeyFromAsn1": "ed25519.privateKeyFromAsn1", + "publicKeyFromAsn1": "ed25519.publicKeyFromAsn1", + "publicKeyFromPrivateKey": "ed25519.publicKeyFromPrivateKey", + "sign": "ed25519.sign", + "verify": "ed25519.verify" + }, + "jsbn": { + "BigInteger": { + "prototype": { + "DB": { + "!type": "number", + "!span": "4167[134:21]-4169[134:23]" + }, + "DM": { + "!type": "number", + "!span": "4200[135:21]-4202[135:23]" + }, + "DV": { + "!type": "number", + "!span": "4242[136:21]-4244[136:23]" + }, + "FV": { + "!type": "number", + "!span": "4297[139:21]-4299[139:23]" + }, + "F1": { + "!type": "number", + "!span": "4342[140:21]-4344[140:23]" + }, + "F2": { + "!type": "number", + "!span": "4381[141:21]-4383[141:23]" + }, + "divideAndRemainder": {}, + "am": "am1", + "copyTo": "bnpCopyTo", + "fromInt": "bnpFromInt", + "fromString": "bnpFromString", + "clamp": "bnpClamp", + "dlShiftTo": "bnpDLShiftTo", + "drShiftTo": "bnpDRShiftTo", + "lShiftTo": "bnpLShiftTo", + "rShiftTo": "bnpRShiftTo", + "subTo": "bnpSubTo", + "multiplyTo": "bnpMultiplyTo", + "squareTo": "bnpSquareTo", + "divRemTo": "bnpDivRemTo", + "invDigit": "bnpInvDigit", + "isEven": "bnpIsEven", + "exp": "bnpExp", + "toString": "bnToString", + "negate": "bnNegate", + "abs": "bnAbs", + "compareTo": "bnCompareTo", + "bitLength": "bnBitLength", + "mod": "bnMod", + "modPowInt": "bnModPowInt", + "chunkSize": "bnpChunkSize", + "toRadix": "bnpToRadix", + "fromRadix": "bnpFromRadix", + "fromNumber": "bnpFromNumber", + "bitwiseTo": "bnpBitwiseTo", + "changeBit": "bnpChangeBit", + "addTo": "bnpAddTo", + "dMultiply": "bnpDMultiply", + "dAddOffset": "bnpDAddOffset", + "multiplyLowerTo": "bnpMultiplyLowerTo", + "multiplyUpperTo": "bnpMultiplyUpperTo", + "modInt": "bnpModInt", + "millerRabin": "bnpMillerRabin", + "clone": "bnClone", + "intValue": "bnIntValue", + "byteValue": "bnByteValue", + "shortValue": "bnShortValue", + "signum": "bnSigNum", + "toByteArray": "bnToByteArray", + "equals": "bnEquals", + "min": "bnMin", + "max": "bnMax", + "and": "bnAnd", + "or": "bnOr", + "xor": "bnXor", + "andNot": "bnAndNot", + "not": "bnNot", + "shiftLeft": "bnShiftLeft", + "shiftRight": "bnShiftRight", + "getLowestSetBit": "bnGetLowestSetBit", + "bitCount": "bnBitCount", + "testBit": "bnTestBit", + "setBit": "bnSetBit", + "clearBit": "bnClearBit", + "flipBit": "bnFlipBit", + "add": "bnAdd", + "subtract": "bnSubtract", + "multiply": "bnMultiply", + "divide": "bnDivide", + "remainder": "bnRemainder", + "modPow": "bnModPow", + "modInverse": "bnModInverse", + "pow": "bnPow", + "gcd": "bnGCD", + "isProbablePrime": "bnIsProbablePrime" + }, + "ONE": "+BigInteger", + "ZERO": "+BigInteger" + }, + "!span": "1779[50:23]-1783[50:27]" + }, + "kem": { + "rsa": { + "create": { + "!type": "fn(kdf: ?, options: ?) -> forge.kem.rsa.create.!ret", + "!span": "1193[37:14]-1199[37:20]", + "!doc": "Creates an RSA KEM API object for generating a secret asymmetric key.\n\nThe symmetric key may be generated via a call to 'encrypt', which will\nproduce a ciphertext to be transmitted to the recipient and a key to be\nkept secret. The ciphertext is a parameter to be passed to 'decrypt' which\nwill produce the same secret key for the recipient to use to decrypt a\nmessage that was encrypted with the secret key.\n\n@param kdf the KDF API to use (eg: new forge.kem.kdf1()).\n@param options the options to use.\n [prng] a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\"." + }, + "!span": "502[21:10]-505[21:13]", + "!doc": "The API for the RSA Key Encapsulation Mechanism (RSA-KEM) from ISO 18033-2." + }, + "kdf1": { + "!type": "fn(md: ?, digestLength: ?)", + "!span": "3474[110:10]-3478[110:14]", + "!doc": "Creates a key derivation API object that implements KDF1 per ISO 18033-2.\n\n@param md the hash API to use.\n@param [digestLength] an optional digest length that must be positive and\n less than or equal to md.digestLength.\n\n@return a KDF1 API object." + }, + "kdf2": { + "!type": "fn(md: ?, digestLength: ?)", + "!span": "3867[123:10]-3871[123:14]", + "!doc": "Creates a key derivation API object that implements KDF2 per ISO 18033-2.\n\n@param md the hash API to use.\n@param [digestLength] an optional digest length that must be positive and\n less than or equal to md.digestLength.\n\n@return a KDF2 API object." + }, + "generate": { + "!type": "fn(x: ?, length: ?) -> ?", + "!span": "4516[145:6]-4524[145:14]", + "!doc": "Generate a key of the specified length.\n\n@param x the binary-encoded byte string to generate a key from.\n@param length the number of bytes to generate (the size of the key).\n\n@return the key as a binary-encoded string." + }, + "!span": "340[14:23]-343[14:26]" + }, + "md": { + "algorithms": { + "sha256": { + "create": {} + }, + "!span": "213[10:9]-223[10:19]", + "md5": { + "create": "md5.create" + }, + "sha1": { + "create": "sha1.create" + }, + "sha384": { + "create": "sha384.create" + }, + "sha512/256": { + "create": "forge.md.sha512/256.create" + }, + "sha512/224": { + "create": "forge.md.sha512/224.create" + } + }, + "sha256": { + "create": {} + }, + "sha512/256": { + "create": { + "!type": "fn() -> _createKDF.!1", + "!span": "787[30:2]-793[30:8]" + }, + "!span": "865[34:9]-877[34:21]", + "!doc": "SHA-512/256" + }, + "sha512/224": { + "create": { + "!type": "fn() -> _createKDF.!1", + "!span": "1005[39:2]-1011[39:8]" + }, + "!span": "1083[43:9]-1095[43:21]", + "!doc": "SHA-512/224" + }, + "!span": "183[9:23]-185[9:25]", + "md5": { + "create": "md5.create" + }, + "sha1": { + "create": "sha1.create" + }, + "sha384": { + "create": "sha384.create" + } + }, + "md5": { + "create": {} + }, + "mgf": { + "!span": "222[10:23]-225[10:26]", + "mgf1": { + "create": {} + } + }, + "oids": { + "": { + "!type": "string", + "!span": "331[14:7]-333[14:9]" + } + }, + "pbe": { + "getCipher": { + "!type": "fn(oid: string, params: ?, password: bool|string) -> ?", + "!span": "22714[753:8]-22723[753:17]", + "!doc": "Get new Forge cipher object instance.\n\n@param oid the OID (in string notation).\n@param params the ASN.1 params object.\n@param password the password to decrypt with.\n\n@return new cipher object instance." + }, + "getCipherForPBES2": { + "!type": "fn(oid: string, params: ?, password: bool|string) -> ?|+BlockCipher", + "!span": "23692[786:8]-23709[786:25]", + "!doc": "Get new Forge cipher object instance according to PBES2 params block.\n\nThe returned cipher instance is already started using the IV\nfrom PBES2 parameter block.\n\n@param oid the PKCS#5 PBKDF2 OID (in string notation).\n@param params the ASN.1 PBES2-params object.\n@param password the password to decrypt with.\n\n@return new cipher object instance." + }, + "getCipherForPKCS12PBE": { + "!type": "fn(oid: string, params: ?, password: bool|string) -> ?", + "!span": "26289[873:8]-26310[873:29]", + "!doc": "Get new Forge cipher object instance for PKCS#12 PBE.\n\nThe returned cipher instance is already started using the key & IV\nderived from the provided password and PKCS#12 PBE salt.\n\n@param oid The PKCS#12 PBE OID (in string notation).\n@param params The ASN.1 PKCS#12 PBE-params object.\n@param password The password to decrypt with.\n\n@return the new cipher object instance." + }, + "opensslDeriveBytes": { + "!type": "fn(password: ?, salt: string, dkLen: number, md: hash.!0) -> string", + "!span": "28120[932:8]-28138[932:26]", + "!doc": "OpenSSL's legacy key derivation function.\n\nSee: http://www.openssl.org/docs/crypto/EVP_BytesToKey.html\n\n@param password the password to derive the key from.\n@param salt the salt to use, null for none.\n@param dkLen the number of bytes needed for the derived key.\n@param [options] the options to use:\n [md] an optional message digest object to use." + }, + "!span": "1000[41:33]-1003[41:36]", + "generatePkcs12Key": "p12.generateKey" + }, + "pbkdf2": { + "!type": "fn(p: bool|string, s: ?, c: number|+ByteBuffer, dkLen: number, md: string, callback: string) -> !4.!ret", + "!span": "1164[37:23]-1170[37:29]", + "!doc": "Derives a key from a password.\n\n@param p the password as a binary-encoded string of bytes.\n@param s the salt as a binary-encoded string of bytes.\n@param c the iteration count, a positive integer.\n@param dkLen the intended length, in bytes, of the derived key,\n (max: 2^32 - 1) * hash length of the PRF.\n@param [md] the message digest (or algorithm identifier as a string) to use\n in the PRF, defaults to SHA-1.\n@param [callback(err, key)] presence triggers asynchronous version, called\n once the operation completes.\n\n@return the derived key, as a binary-encoded string of bytes, for the\n synchronous version (if no callback is specified)." + }, + "pem": { + "encode": {}, + "decode": {} + }, + "pkcs12": { + "pkcs12FromAsn1": {}, + "toPkcs12Asn1": {}, + "generateKey": "p12.generateKey" + }, + "pkcs7": { + "messageFromPem": {}, + "createSignedData": {}, + "createEncryptedData": {}, + "asn1": { + "contentInfoValidator": { + "name": { + "!type": "string", + "!span": "3698[122:2]-3702[122:6]" + }, + "tagClass": { + "!type": "number", + "!span": "3721[123:2]-3729[123:10]" + }, + "type": { + "!type": "number", + "!span": "3755[124:2]-3759[124:6]" + }, + "constructed": { + "!type": "bool", + "!span": "3783[125:2]-3794[125:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "3818[127:4]-3822[127:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3855[128:4]-3863[128:12]" + }, + "type": { + "!type": "number", + "!span": "3891[129:4]-3895[129:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3916[130:4]-3927[130:15]" + }, + "capture": { + "!type": "string", + "!span": "3940[131:4]-3947[131:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "3974[133:4]-3978[133:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4007[134:4]-4015[134:12]" + }, + "type": { + "!type": "number", + "!span": "4050[135:4]-4054[135:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4063[136:4]-4074[136:15]" + }, + "optional": { + "!type": "bool", + "!span": "4086[137:4]-4094[137:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4106[138:4]-4117[138:15]" + } + } + } + }, + "envelopedDataValidator": { + "name": { + "!type": "string", + "!span": "6095[206:2]-6099[206:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6120[207:2]-6128[207:10]" + }, + "type": { + "!type": "number", + "!span": "6154[208:2]-6158[208:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6182[209:2]-6193[209:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6217[211:4]-6221[211:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6252[212:4]-6260[212:12]" + }, + "type": { + "!type": "number", + "!span": "6288[213:4]-6292[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6317[214:4]-6328[214:15]" + }, + "capture": { + "!type": "string", + "!span": "6341[215:4]-6348[215:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6371[217:4]-6375[217:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6413[218:4]-6421[218:12]" + }, + "type": { + "!type": "number", + "!span": "6449[219:4]-6453[219:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6474[220:4]-6485[220:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6497[221:4]-6508[221:15]" + } + } + } + }, + "encryptedDataValidator": { + "name": { + "!type": "string", + "!span": "6607[226:2]-6611[226:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6632[227:2]-6640[227:10]" + }, + "type": { + "!type": "number", + "!span": "6666[228:2]-6670[228:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6694[229:2]-6705[229:13]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6729[231:4]-6733[231:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6764[232:4]-6772[232:12]" + }, + "type": { + "!type": "number", + "!span": "6800[233:4]-6804[233:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6829[234:4]-6840[234:15]" + }, + "capture": { + "!type": "string", + "!span": "6853[235:4]-6860[235:11]" + } + } + } + }, + "signedDataValidator": { + "name": { + "!type": "string", + "!span": "9001[315:2]-9005[315:6]" + }, + "tagClass": { + "!type": "number", + "!span": "9023[316:2]-9031[316:10]" + }, + "type": { + "!type": "number", + "!span": "9057[317:2]-9061[317:6]" + }, + "constructed": { + "!type": "bool", + "!span": "9085[318:2]-9096[318:13]" + }, + "value": { + "": "contentInfoValidator" + } + }, + "recipientInfoValidator": { + "name": { + "!type": "string", + "!span": "9987[356:2]-9991[356:6]" + }, + "tagClass": { + "!type": "number", + "!span": "10012[357:2]-10020[357:10]" + }, + "type": { + "!type": "number", + "!span": "10046[358:2]-10050[358:6]" + }, + "constructed": { + "!type": "bool", + "!span": "10074[359:2]-10085[359:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10109[361:4]-10113[361:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10144[362:4]-10152[362:12]" + }, + "type": { + "!type": "number", + "!span": "10180[363:4]-10184[363:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10209[364:4]-10220[364:15]" + }, + "capture": { + "!type": "string", + "!span": "10233[365:4]-10240[365:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10263[367:4]-10267[367:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10306[368:4]-10314[368:12]" + }, + "type": { + "!type": "number", + "!span": "10342[369:4]-10346[369:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10372[370:4]-10383[370:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10411[372:6]-10415[372:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[373:6]-10471[373:14]" + }, + "type": { + "!type": "number", + "!span": "10501[374:6]-10505[374:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10533[375:6]-10544[375:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "10558[376:6]-10569[376:17]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10595[378:6]-10599[378:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10653[379:6]-10661[379:14]" + }, + "type": { + "!type": "number", + "!span": "10691[380:6]-10695[380:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10722[381:6]-10733[381:17]" + }, + "capture": { + "!type": "string", + "!span": "10748[382:6]-10755[382:13]" + } + } + } + }, + "2": { + "name": { + "!type": "string", + "!span": "10784[385:4]-10788[385:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10834[386:4]-10842[386:12]" + }, + "type": { + "!type": "number", + "!span": "10870[387:4]-10874[387:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10900[388:4]-10911[388:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10939[390:6]-10943[390:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11001[391:6]-11009[391:14]" + }, + "type": { + "!type": "number", + "!span": "11039[392:6]-11043[392:10]" + }, + "constructed": { + "!type": "bool", + "!span": "11066[393:6]-11077[393:17]" + }, + "capture": { + "!type": "string", + "!span": "11092[394:6]-11099[394:13]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "11131[396:6]-11135[396:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11193[397:6]-11201[397:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11231[398:6]-11242[398:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "11257[399:6]-11268[399:17]" + } + } + } + }, + "3": { + "name": { + "!type": "string", + "!span": "11303[402:4]-11307[402:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11343[403:4]-11351[403:12]" + }, + "type": { + "!type": "number", + "!span": "11379[404:4]-11383[404:8]" + }, + "constructed": { + "!type": "bool", + "!span": "11412[405:4]-11423[405:15]" + }, + "capture": { + "!type": "string", + "!span": "11436[406:4]-11443[406:11]" + } + } + } + } + }, + "messageToPem": "p7.messageToPem", + "messageFromAsn1": "p7.messageFromAsn1", + "createEnvelopedData": "p7.createEnvelopedData" + }, + "pkcs7asn1": { + "contentInfoValidator": { + "name": { + "!type": "string", + "!span": "3698[122:2]-3702[122:6]" + }, + "tagClass": { + "!type": "number", + "!span": "3721[123:2]-3729[123:10]" + }, + "type": { + "!type": "number", + "!span": "3755[124:2]-3759[124:6]" + }, + "constructed": { + "!type": "bool", + "!span": "3783[125:2]-3794[125:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "3818[127:4]-3822[127:8]" + }, + "tagClass": { + "!type": "number", + "!span": "3855[128:4]-3863[128:12]" + }, + "type": { + "!type": "number", + "!span": "3891[129:4]-3895[129:8]" + }, + "constructed": { + "!type": "bool", + "!span": "3916[130:4]-3927[130:15]" + }, + "capture": { + "!type": "string", + "!span": "3940[131:4]-3947[131:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "3974[133:4]-3978[133:8]" + }, + "tagClass": { + "!type": "number", + "!span": "4007[134:4]-4015[134:12]" + }, + "type": { + "!type": "number", + "!span": "4050[135:4]-4054[135:8]" + }, + "constructed": { + "!type": "bool", + "!span": "4063[136:4]-4074[136:15]" + }, + "optional": { + "!type": "bool", + "!span": "4086[137:4]-4094[137:12]" + }, + "captureAsn1": { + "!type": "string", + "!span": "4106[138:4]-4117[138:15]" + } + } + } + }, + "envelopedDataValidator": { + "name": { + "!type": "string", + "!span": "6095[206:2]-6099[206:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6120[207:2]-6128[207:10]" + }, + "type": { + "!type": "number", + "!span": "6154[208:2]-6158[208:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6182[209:2]-6193[209:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6217[211:4]-6221[211:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6252[212:4]-6260[212:12]" + }, + "type": { + "!type": "number", + "!span": "6288[213:4]-6292[213:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6317[214:4]-6328[214:15]" + }, + "capture": { + "!type": "string", + "!span": "6341[215:4]-6348[215:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6371[217:4]-6375[217:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6413[218:4]-6421[218:12]" + }, + "type": { + "!type": "number", + "!span": "6449[219:4]-6453[219:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6474[220:4]-6485[220:15]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6497[221:4]-6508[221:15]" + } + } + } + }, + "encryptedDataValidator": { + "name": { + "!type": "string", + "!span": "6607[226:2]-6611[226:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6632[227:2]-6640[227:10]" + }, + "type": { + "!type": "number", + "!span": "6666[228:2]-6670[228:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6694[229:2]-6705[229:13]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6729[231:4]-6733[231:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6764[232:4]-6772[232:12]" + }, + "type": { + "!type": "number", + "!span": "6800[233:4]-6804[233:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6829[234:4]-6840[234:15]" + }, + "capture": { + "!type": "string", + "!span": "6853[235:4]-6860[235:11]" + } + } + } + }, + "signedDataValidator": { + "name": { + "!type": "string", + "!span": "9001[315:2]-9005[315:6]" + }, + "tagClass": { + "!type": "number", + "!span": "9023[316:2]-9031[316:10]" + }, + "type": { + "!type": "number", + "!span": "9057[317:2]-9061[317:6]" + }, + "constructed": { + "!type": "bool", + "!span": "9085[318:2]-9096[318:13]" + }, + "value": { + "": "contentInfoValidator" + } + }, + "recipientInfoValidator": { + "name": { + "!type": "string", + "!span": "9987[356:2]-9991[356:6]" + }, + "tagClass": { + "!type": "number", + "!span": "10012[357:2]-10020[357:10]" + }, + "type": { + "!type": "number", + "!span": "10046[358:2]-10050[358:6]" + }, + "constructed": { + "!type": "bool", + "!span": "10074[359:2]-10085[359:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10109[361:4]-10113[361:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10144[362:4]-10152[362:12]" + }, + "type": { + "!type": "number", + "!span": "10180[363:4]-10184[363:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10209[364:4]-10220[364:15]" + }, + "capture": { + "!type": "string", + "!span": "10233[365:4]-10240[365:11]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10263[367:4]-10267[367:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10306[368:4]-10314[368:12]" + }, + "type": { + "!type": "number", + "!span": "10342[369:4]-10346[369:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10372[370:4]-10383[370:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10411[372:6]-10415[372:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10463[373:6]-10471[373:14]" + }, + "type": { + "!type": "number", + "!span": "10501[374:6]-10505[374:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10533[375:6]-10544[375:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "10558[376:6]-10569[376:17]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "10595[378:6]-10599[378:10]" + }, + "tagClass": { + "!type": "number", + "!span": "10653[379:6]-10661[379:14]" + }, + "type": { + "!type": "number", + "!span": "10691[380:6]-10695[380:10]" + }, + "constructed": { + "!type": "bool", + "!span": "10722[381:6]-10733[381:17]" + }, + "capture": { + "!type": "string", + "!span": "10748[382:6]-10755[382:13]" + } + } + } + }, + "2": { + "name": { + "!type": "string", + "!span": "10784[385:4]-10788[385:8]" + }, + "tagClass": { + "!type": "number", + "!span": "10834[386:4]-10842[386:12]" + }, + "type": { + "!type": "number", + "!span": "10870[387:4]-10874[387:8]" + }, + "constructed": { + "!type": "bool", + "!span": "10900[388:4]-10911[388:15]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "10939[390:6]-10943[390:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11001[391:6]-11009[391:14]" + }, + "type": { + "!type": "number", + "!span": "11039[392:6]-11043[392:10]" + }, + "constructed": { + "!type": "bool", + "!span": "11066[393:6]-11077[393:17]" + }, + "capture": { + "!type": "string", + "!span": "11092[394:6]-11099[394:13]" + } + }, + "1": { + "name": { + "!type": "string", + "!span": "11131[396:6]-11135[396:10]" + }, + "tagClass": { + "!type": "number", + "!span": "11193[397:6]-11201[397:14]" + }, + "constructed": { + "!type": "bool", + "!span": "11231[398:6]-11242[398:17]" + }, + "captureAsn1": { + "!type": "string", + "!span": "11257[399:6]-11268[399:17]" + } + } + } + }, + "3": { + "name": { + "!type": "string", + "!span": "11303[402:4]-11307[402:8]" + }, + "tagClass": { + "!type": "number", + "!span": "11343[403:4]-11351[403:12]" + }, + "type": { + "!type": "number", + "!span": "11379[404:4]-11383[404:8]" + }, + "constructed": { + "!type": "bool", + "!span": "11412[405:4]-11423[405:15]" + }, + "capture": { + "!type": "string", + "!span": "11436[406:4]-11443[406:11]" + } + } + } + } + }, + "prime": { + "generateProbablePrime": { + "!type": "fn(bits: number, options: forge.prime.generateProbablePrime.!1, callback: forge.prime.generateProbablePrime.!1|fn(err: ?, num: +BigInteger))", + "!span": "1765[60:6]-1786[60:27]", + "!doc": "Generates a random probable prime with the given number of bits.\n\nAlternative algorithms can be specified by name as a string or as an\nobject with custom options like so:\n\n{\n name: 'PRIMEINC',\n options: {\n maxBlockTime: ,\n millerRabinTests: ,\n workerScript: ,\n workers: .\n workLoad: the size of the work load, ie: number of possible prime\n numbers for each web worker to check per work assignment,\n (default: 100).\n }\n}\n\n@param bits the number of bits for the prime number.\n@param options the options to use.\n [algorithm] the algorithm to use (default: 'PRIMEINC').\n [prng] a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\".\n\n@return callback(err, num) called once the operation completes." + }, + "!span": "365[21:35]-370[21:40]", + "!doc": "PRIME API" + }, + "prng": { + "create": {} + }, + "random": { + "plugin": { + "formatKey": { + "!type": "fn(key: ?) -> ?", + "!span": "1046[35:9]-1055[35:18]" + }, + "formatSeed": { + "!type": "fn(seed: ?) -> [number|_fromDer.!ret]", + "!span": "1373[47:9]-1383[47:19]" + }, + "cipher": { + "!type": "fn(key: ?, seed: [number|_fromDer.!ret]) -> ?", + "!span": "1647[57:9]-1653[57:15]" + }, + "increment": { + "!type": "fn(seed: [number|_fromDer.!ret]) -> !0", + "!span": "1990[65:9]-1999[65:18]" + }, + "!span": "1382[43:4]-1388[43:10]", + "md": "sha256" + }, + "seed": { + "!type": "[number|_fromDer.!ret]", + "!span": "1417[45:4]-1421[45:8]" + }, + "reseeds": { + "!type": "number", + "!span": "1481[48:4]-1488[48:11]", + "!doc": "update reseed count" + }, + "generated": { + "!type": "number", + "!span": "1536[50:4]-1545[50:13]", + "!doc": "amount of data generated so far" + }, + "keyBytes": { + "!type": "string", + "!span": "1582[52:4]-1590[52:12]", + "!doc": "get digest for key bytes" + }, + "pools": { + "!type": "[forge.random.pools.]", + "!span": "1778[61:6]-1783[61:11]" + }, + "pool": { + "!type": "number", + "!span": "1866[64:6]-1870[64:10]", + "!doc": "entropy pools are written to cyclically, starting at index 0" + }, + "generate": { + "!type": "fn(count: number|string, callback: ?) -> ?", + "!span": "2262[76:6]-2270[76:14]", + "!doc": "Generates random bytes. The bytes may be generated synchronously or\nasynchronously. Web workers must use the asynchronous interface or\nelse the behavior is undefined.\n\n@param count the number of random bytes to generate.\n@param [callback(err, bytes)] called once the operation completes.\n\n@return count random bytes as a string." + }, + "generateSync": { + "!type": "fn(count: number|string) -> ?", + "!span": "3996[140:6]-4008[140:18]", + "!doc": "Generates random bytes synchronously.\n\n@param count the number of random bytes to generate.\n\n@return count random bytes as a string." + }, + "seedFile": { + "!type": "fn(needed: number, callback: fn(err: ?, bytes: ?))", + "!span": "9685[329:8]-9693[329:16]", + "!doc": "use nodejs async API" + }, + "seedFileSync": { + "!type": "fn(needed: number) -> ?", + "!span": "9936[338:8]-9948[338:20]", + "!doc": "use nodejs sync API" + }, + "collect": { + "!type": "fn(bytes: ?)", + "!span": "10372[357:6]-10379[357:13]", + "!doc": "Adds entropy to a prng ctx's accumulator.\n\n@param bytes the bytes of entropy as a string." + }, + "collectInt": { + "!type": "fn(i: number, n: number)", + "!span": "10789[372:6]-10799[372:16]", + "!doc": "Collects an integer of n bits.\n\n@param i the integer entropy.\n@param n the number of bits in the integer." + }, + "registerWorker": { + "!type": "fn(worker: ?)", + "!span": "11316[388:6]-11330[388:20]", + "!doc": "Registers a Web Worker to receive immediate entropy from the main thread.\nThis method is required until Web Workers can access the native crypto\nAPI. This method should be called twice for each created worker, once in\nthe main thread, and once in the worker itself.\n\n@param worker the worker to register." + }, + "getBytes": { + "!type": "fn(count: number, callback: ?) -> ?", + "!span": "2732[90:6]-2740[90:14]", + "!doc": "Gets random bytes. If a native secure crypto API is unavailable, this\nmethod tries to make the bytes more unpredictable by drawing from data that\ncan be collected from the user of the browser, eg: mouse movement.\n\nIf a callback is given, this method will be called asynchronously.\n\n@param count the number of random bytes to get.\n@param [callback(err, bytes)] called once the operation completes.\n\n@return the random bytes in a string." + }, + "getBytesSync": { + "!type": "fn(count: number|string) -> ?", + "!span": "3191[104:6]-3203[104:18]", + "!doc": "Gets random bytes asynchronously. If a native secure crypto API is\nunavailable, this method tries to make the bytes more unpredictable by\ndrawing from data that can be collected from the user of the browser,\neg: mouse movement.\n\n@param count the number of random bytes to get.\n\n@return the random bytes in a string." + }, + "createInstance": { + "!type": "fn() -> forge.random", + "!span": "5318[184:13]-5332[184:27]", + "!doc": "expose spawn PRNG" + }, + "!span": "5158[175:8]-5164[175:14]" + }, + "rc2": { + "expandKey": { + "!type": "fn(key: string|+ByteBuffer, effKeyBits: number) -> !0", + "!span": "2951[72:10]-2960[72:19]", + "!doc": "Perform RC2 key expansion as per RFC #2268, section 2.\n\n@param key variable-length user key (between 1 and 128 bytes)\n@param effKeyBits number of effective key bits (default: 128)\n@return the expanded RC2 key (ByteBuffer of 128 bytes)" + }, + "startEncrypting": { + "!type": "fn(key: ?, iv: ?, output: ?) -> createCipher.!ret", + "!span": "10256[351:10]-10271[351:25]", + "!doc": "Creates an RC2 cipher object to encrypt data in ECB or CBC mode using the\ngiven symmetric key. The output will be stored in the 'output' member\nof the returned cipher.\n\nThe key and iv may be given as a string of bytes or a byte buffer.\nThe cipher is initialized to use 128 effective key bits.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n\n@return the cipher." + }, + "createEncryptionCipher": { + "!type": "fn(key: ?, bits: number) -> createCipher.!ret", + "!span": "10759[370:10]-10781[370:32]", + "!doc": "Creates an RC2 cipher object to encrypt data in ECB or CBC mode using the\ngiven symmetric key.\n\nThe key may be given as a string of bytes or a byte buffer.\n\nTo start encrypting call start() on the cipher with an iv and optional\noutput buffer.\n\n@param key the symmetric key to use.\n\n@return the cipher." + }, + "startDecrypting": { + "!type": "fn(key: ?, iv: ?, output: ?) -> createCipher.!ret", + "!span": "11355[388:10]-11370[388:25]", + "!doc": "Creates an RC2 cipher object to decrypt data in ECB or CBC mode using the\ngiven symmetric key. The output will be stored in the 'output' member\nof the returned cipher.\n\nThe key and iv may be given as a string of bytes or a byte buffer.\nThe cipher is initialized to use 128 effective key bits.\n\n@param key the symmetric key to use.\n@param iv the initialization vector to use.\n@param output the buffer to write to, null to create one.\n\n@return the cipher." + }, + "createDecryptionCipher": { + "!type": "fn(key: string, bits: number) -> createCipher.!ret", + "!span": "11858[407:10]-11880[407:32]", + "!doc": "Creates an RC2 cipher object to decrypt data in ECB or CBC mode using the\ngiven symmetric key.\n\nThe key may be given as a string of bytes or a byte buffer.\n\nTo start decrypting call start() on the cipher with an iv and optional\noutput buffer.\n\n@param key the symmetric key to use.\n\n@return the cipher." + }, + "!span": "2660[63:23]-2663[63:26]", + "!doc": "RC2 API" + }, + "rsa": { + "publicKeyValidator": { + "name": { + "!type": "string", + "!span": "6195[231:2]-6199[231:6]" + }, + "tagClass": { + "!type": "number", + "!span": "6227[232:2]-6235[232:10]" + }, + "type": { + "!type": "number", + "!span": "6261[233:2]-6265[233:6]" + }, + "constructed": { + "!type": "bool", + "!span": "6289[234:2]-6300[234:13]" + }, + "captureAsn1": { + "!type": "string", + "!span": "6310[235:2]-6321[235:13]" + }, + "value": { + "0": { + "name": { + "!type": "string", + "!span": "6363[237:4]-6367[237:8]" + }, + "tagClass": { + "!type": "number", + "!span": "6417[238:4]-6425[238:12]" + }, + "type": { + "!type": "number", + "!span": "6453[239:4]-6457[239:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6483[240:4]-6494[240:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6522[242:6]-6526[242:10]" + }, + "tagClass": { + "!type": "number", + "!span": "6567[243:6]-6575[243:14]" + }, + "type": { + "!type": "number", + "!span": "6605[244:6]-6609[244:10]" + }, + "constructed": { + "!type": "bool", + "!span": "6632[245:6]-6643[245:17]" + }, + "capture": { + "!type": "string", + "!span": "6658[246:6]-6665[246:13]" + } + } + } + }, + "1": { + "name": { + "!type": "string", + "!span": "6724[250:4]-6728[250:8]", + "!doc": "subjectPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6775[251:4]-6783[251:12]" + }, + "type": { + "!type": "number", + "!span": "6811[252:4]-6815[252:8]" + }, + "constructed": { + "!type": "bool", + "!span": "6842[253:4]-6853[253:15]" + }, + "value": { + "": { + "name": { + "!type": "string", + "!span": "6904[256:6]-6908[256:10]", + "!doc": "RSAPublicKey" + }, + "tagClass": { + "!type": "number", + "!span": "6970[257:6]-6978[257:14]" + }, + "type": { + "!type": "number", + "!span": "7008[258:6]-7012[258:10]" + }, + "constructed": { + "!type": "bool", + "!span": "7040[259:6]-7051[259:17]" + }, + "optional": { + "!type": "bool", + "!span": "7065[260:6]-7073[260:14]" + }, + "captureAsn1": { + "!type": "string", + "!span": "7087[261:6]-7098[261:17]" + } + } + } + } + } + }, + "encrypt": { + "!type": "fn(m: string|+ByteBuffer, key: _publicKeyFromJwk.!ret|_modPow.!1, bt: bool|number) -> ?", + "!span": "14183[479:8]-14190[479:15]", + "!doc": "NOTE: THIS METHOD IS DEPRECATED, use 'sign' on a private key object or\n'encrypt' on a public key object instead.\n\nPerforms RSA encryption.\n\nThe parameter bt controls whether to put padding bytes before the\nmessage passed in. Set bt to either true or false to disable padding\ncompletely (in order to handle e.g. EMSA-PSS encoding seperately before),\nsignaling whether the encryption operation is a public key operation\n(i.e. encrypting data) or not, i.e. private key operation (data signing).\n\nFor PKCS#1 v1.5 padding pass in the block type to use, i.e. either 0x01\n(for signing) or 0x02 (for encryption). The key operation mode (private\nor public) is derived from this flag in that case).\n\n@param m the message to encrypt as a byte string.\n@param key the RSA key to use.\n@param bt for PKCS#1 v1.5 padding, the block type to use\n (0x01 for private key, 0x02 for public),\n to disable padding: true = public key, false = private key.\n\n@return the encrypted bytes as a string." + }, + "decrypt": { + "!type": "fn(ed: ?, key: _publicKeyFromJwk.!ret|_modPow.!1, pub: bool, ml: bool) -> ?", + "!span": "15898[534:8]-15905[534:15]", + "!doc": "NOTE: THIS METHOD IS DEPRECATED, use 'decrypt' on a private key object or\n'verify' on a public key object instead.\n\nPerforms RSA decryption.\n\nThe parameter ml controls whether to apply PKCS#1 v1.5 padding\nor not. Set ml = false to disable padding removal completely\n(in order to handle e.g. EMSA-PSS later on) and simply pass back\nthe RSA encryption block.\n\n@param ed the encrypted data to decrypt in as a byte string.\n@param key the RSA key to use.\n@param pub true for a public key operation, false for private.\n@param ml the message length, if known, false to disable padding.\n\n@return the decrypted message as a byte string." + }, + "createKeyPairGenerationState": { + "!type": "fn(bits: number, e: number, options: ?|number) -> _generateKeyPair.!0", + "!span": "17910[594:8]-17938[594:36]", + "!doc": "Creates an RSA key-pair generation state object. It is used to allow\nkey-generation to be performed in steps. It also allows for a UI to\ndisplay progress updates.\n\n@param bits the size for the private key in bits, defaults to 2048.\n@param e the public exponent to use, defaults to 65537 (0x10001).\n@param [options] the options to use.\n prng a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\".\n algorithm the algorithm to use (default: 'PRIMEINC').\n\n@return the state object to use to generate the key-pair." + }, + "stepKeyPairGenerationState": { + "!type": "fn(state: _generateKeyPair.!0, n: number) -> bool", + "!span": "20210[673:8]-20236[673:34]", + "!doc": "Attempts to runs the key-generation algorithm for at most n seconds\n(approximately) using the given state. When key-generation has completed,\nthe keys will be stored in state.keys.\n\nTo use this function to update a UI while generating a key or to prevent\ncausing browser lockups/warnings, set \"n\" to a value other than 0. A\nsimple pattern for generating a key and showing a progress indicator is:\n\nvar state = pki.rsa.createKeyPairGenerationState(2048);\nvar step = function() {\n // step key-generation, run algorithm for 100 ms, repeat\n if(!forge.pki.rsa.stepKeyPairGenerationState(state, 100)) {\n setTimeout(step, 1);\n } else {\n // key-generation complete\n // TODO: turn off progress indicator here\n // TODO: use the generated key-pair in \"state.keys\"\n }\n};\n// TODO: turn on progress indicator here\nsetTimeout(step, 0);\n\n@param state the state to use.\n@param n the maximum number of milliseconds to run the algorithm for, 0\n to run the algorithm to completion.\n\n@return true if the key-generation completed, false if not." + }, + "generateKeyPair": { + "!type": "fn(bits: number, e: number, options: ?|number, callback: ?|number) -> ?", + "!span": "26181[843:8]-26196[843:23]", + "!doc": "Generates an RSA public-private key pair in a single call.\n\nTo generate a key-pair in steps (to allow for progress updates and to\nprevent blocking or warnings in slow browsers) then use the key-pair\ngeneration state functions.\n\nTo generate a key-pair asynchronously (either through web-workers, if\navailable, or by breaking up the work on the main thread), pass a\ncallback function.\n\n@param [bits] the size for the private key in bits, defaults to 2048.\n@param [e] the public exponent to use, defaults to 65537.\n@param [options] options for key-pair generation, if given then 'bits'\n and 'e' must *not* be given:\n bits the size for the private key in bits, (default: 2048).\n e the public exponent to use, (default: 65537 (0x10001)).\n workerScript the worker script URL.\n workers the number of web workers (if supported) to use,\n (default: 2).\n workLoad the size of the work load, ie: number of possible prime\n numbers for each web worker to check per work assignment,\n (default: 100).\n prng a custom crypto-secure pseudo-random number generator to use,\n that must define \"getBytesSync\". Disables use of native APIs.\n algorithm the algorithm to use (default: 'PRIMEINC').\n@param [callback(err, keypair)] called once the operation completes.\n\n@return an object with privateKey and publicKey properties." + }, + "!span": "2386[88:39]-2389[88:42]", + "setPublicKey": "pki.setRsaPublicKey", + "setPrivateKey": "pki.setRsaPrivateKey" + }, + "sha512": { + "create": { + "!type": "fn(algorithm: string) -> _createKDF.!1", + "!span": "1357[54:7]-1363[54:13]" + }, + "!span": "415[16:36]-421[16:42]", + "!doc": "SHA-512", + "sha384": "sha384", + "sha256": "forge.md.sha512/256", + "sha224": "forge.md.sha512/224" + }, + "util": { + "isNodejs": { + "!type": "bool", + "!span": "3331[109:5]-3339[109:13]", + "!doc": "check if running under Node.js" + }, + "parseFragment": {}, + "makeRequest": {}, + "cores": { + "!type": "number", + "!span": "73990[2815:9]-73995[2815:14]", + "!doc": "can't estimate, default to 2" + }, + "setImmediate": "util.nextTick", + "ByteStringBuffer": "ByteBuffer", + "binary": { + "hex": { + "encode": "util.bytesToHex", + "decode": "util.binary.hex.decode" + }, + "raw": { + "encode": "util.binary.raw.encode", + "decode": "util.binary.raw.decode" + }, + "base64": { + "encode": "util.binary.base64.encode", + "decode": "util.binary.base64.decode" + }, + "base58": { + "encode": "util.binary.base58.encode", + "decode": "util.binary.base58.decode" + }, + "baseN": "util.binary.baseN" + }, + "setItem": {}, + "parseUrl": "http.parseUrl", + "deflate": {}, + "ByteBuffer": { + "prototype": { + "_optimizeConstructedString": "ByteBuffer.prototype._optimizeConstructedString", + "length": "ByteBuffer.prototype.length", + "isEmpty": "ByteBuffer.prototype.isEmpty", + "putByte": "ByteBuffer.prototype.putByte", + "fillWithByte": "ByteBuffer.prototype.fillWithByte", + "putBytes": "ByteBuffer.prototype.putBytes", + "putString": "ByteBuffer.prototype.putString", + "putInt16": "ByteBuffer.prototype.putInt16", + "putInt24": "ByteBuffer.prototype.putInt24", + "putInt32": "ByteBuffer.prototype.putInt32", + "putInt16Le": "ByteBuffer.prototype.putInt16Le", + "putInt24Le": "ByteBuffer.prototype.putInt24Le", + "putInt32Le": "ByteBuffer.prototype.putInt32Le", + "putInt": "ByteBuffer.prototype.putInt", + "putSignedInt": "ByteBuffer.prototype.putSignedInt", + "putBuffer": "ByteBuffer.prototype.putBuffer", + "getByte": "ByteBuffer.prototype.getByte", + "getInt16": "ByteBuffer.prototype.getInt16", + "getInt24": "ByteBuffer.prototype.getInt24", + "getInt32": "ByteBuffer.prototype.getInt32", + "getInt16Le": "ByteBuffer.prototype.getInt16Le", + "getInt24Le": "ByteBuffer.prototype.getInt24Le", + "getInt32Le": "ByteBuffer.prototype.getInt32Le", + "getInt": "ByteBuffer.prototype.getInt", + "getSignedInt": "ByteBuffer.prototype.getSignedInt", + "getBytes": "ByteBuffer.prototype.getBytes", + "bytes": "ByteBuffer.prototype.bytes", + "at": "ByteBuffer.prototype.at", + "setAt": "ByteBuffer.prototype.setAt", + "last": "ByteBuffer.prototype.last", + "copy": "ByteBuffer.prototype.copy", + "compact": "ByteBuffer.prototype.compact", + "clear": "ByteBuffer.prototype.clear", + "truncate": "ByteBuffer.prototype.truncate", + "toHex": "ByteBuffer.prototype.toHex", + "toString": "ByteBuffer.prototype.toString" + } + }, + "nextTick": "util.nextTick", + "isArray": "util.isArray", + "isArrayBuffer": "util.isArrayBuffer", + "isArrayBufferView": "util.isArrayBufferView", + "DataBuffer": { + "prototype": { + "length": "DataBuffer.prototype.length", + "isEmpty": "DataBuffer.prototype.isEmpty", + "accommodate": "DataBuffer.prototype.accommodate", + "putByte": "DataBuffer.prototype.putByte", + "fillWithByte": "DataBuffer.prototype.fillWithByte", + "putBytes": "DataBuffer.prototype.putBytes", + "putBuffer": "DataBuffer.prototype.putBuffer", + "putString": "DataBuffer.prototype.putString", + "putInt16": "DataBuffer.prototype.putInt16", + "putInt24": "DataBuffer.prototype.putInt24", + "putInt32": "DataBuffer.prototype.putInt32", + "putInt16Le": "DataBuffer.prototype.putInt16Le", + "putInt24Le": "DataBuffer.prototype.putInt24Le", + "putInt32Le": "DataBuffer.prototype.putInt32Le", + "putInt": "DataBuffer.prototype.putInt", + "putSignedInt": "DataBuffer.prototype.putSignedInt", + "getByte": "DataBuffer.prototype.getByte", + "getInt16": "DataBuffer.prototype.getInt16", + "getInt24": "DataBuffer.prototype.getInt24", + "getInt32": "DataBuffer.prototype.getInt32", + "getInt16Le": "DataBuffer.prototype.getInt16Le", + "getInt24Le": "DataBuffer.prototype.getInt24Le", + "getInt32Le": "DataBuffer.prototype.getInt32Le", + "getInt": "DataBuffer.prototype.getInt", + "getSignedInt": "DataBuffer.prototype.getSignedInt", + "getBytes": "DataBuffer.prototype.getBytes", + "bytes": "DataBuffer.prototype.bytes", + "at": "DataBuffer.prototype.at", + "setAt": "DataBuffer.prototype.setAt", + "last": "DataBuffer.prototype.last", + "copy": "DataBuffer.prototype.copy", + "compact": "DataBuffer.prototype.compact", + "clear": "DataBuffer.prototype.clear", + "truncate": "DataBuffer.prototype.truncate", + "toHex": "DataBuffer.prototype.toHex", + "toString": "DataBuffer.prototype.toString" + } + }, + "createBuffer": "util.createBuffer", + "fillString": "util.fillString", + "xorBytes": "util.xorBytes", + "hexToBytes": "util.hexToBytes", + "bytesToHex": "util.bytesToHex", + "int32ToBytes": "util.int32ToBytes", + "encode64": "util.encode64", + "decode64": "util.decode64", + "encodeUtf8": "util.encodeUtf8", + "decodeUtf8": "util.decodeUtf8", + "text": { + "utf8": { + "encode": "util.text.utf8.encode", + "decode": "util.text.utf8.decode" + }, + "utf16": { + "encode": "util.text.utf16.encode", + "decode": "util.text.utf16.decode" + } + }, + "inflate": "util.inflate", + "getItem": "util.getItem", + "removeItem": "util.removeItem", + "clearItems": "util.clearItems", + "getQueryVariables": "util.getQueryVariables", + "makeLink": "util.makeLink", + "isEmpty": "util.isEmpty", + "format": "util.format", + "formatNumber": "util.formatNumber", + "formatSize": "util.formatSize", + "bytesFromIP": "util.bytesFromIP", + "bytesFromIPv4": "util.bytesFromIPv4", + "bytesFromIPv6": "util.bytesFromIPv6", + "bytesToIP": "util.bytesToIP", + "bytesToIPv4": "util.bytesToIPv4", + "bytesToIPv6": "util.bytesToIPv6", + "estimateCores": "util.estimateCores" + }, + "hmac": { + "create": {} + }, + "pkcs5": { + "pbkdf2": "forge.pbkdf2" + }, + "mgf1": { + "create": {} + }, + "pkcs1": { + "encode_rsa_oaep": "pkcs1.encode_rsa_oaep", + "decode_rsa_oaep": "pkcs1.decode_rsa_oaep" + }, + "pss": { + "create": {} + }, + "sha1": { + "create": "sha1.create" + }, + "sha256": { + "create": "sha256.create" + }, + "sha384": { + "create": "sha384.create" + }, + "ssh": { + "privateKeyToPutty": "ssh.privateKeyToPutty", + "publicKeyToOpenSSH": "ssh.publicKeyToOpenSSH", + "privateKeyToOpenSSH": "ssh.privateKeyToOpenSSH", + "getPublicKeyFingerprint": "ssh.getPublicKeyFingerprint" + } + } +} diff --git a/app/taro/src/constants/defs/lodash.json b/app/taro/src/constants/defs/lodash.json new file mode 100644 index 0000000000..d472f31b6d --- /dev/null +++ b/app/taro/src/constants/defs/lodash.json @@ -0,0 +1,1545 @@ +{ + "!name": "LIB/lodash", + "_": { + "chunk": { + "!url": "https://lodash.com/docs/4.17.15#chunk", + "!doc": "Creates an array of elements split into groups the length of size. If array can't be split evenly, the final chunk will be the remaining elements.", + "!type": "fn(array, [size])" + }, + "compact": { + "!url": "https://lodash.com/docs/4.17.15#compact", + "!doc": "Creates an array with all falsey values removed. The values false, null, 0, \"\", undefined, and NaN are falsey.", + "!type": "fn(array)" + }, + "concat": { + "!url": "https://lodash.com/docs/4.17.15#concat", + "!doc": "Creates a new array concatenating array with any additional arrays and/or values.", + "!type": "fn(array, [values])" + }, + "difference": { + "!url": "https://lodash.com/docs/4.17.15#difference", + "!doc": "Creates an array of array values not included in the other given arrays using SameValueZero for equality comparisons. The order and references of result values are determined by the first array.Note: Unlike _.pullAll, this method returns a new array.", + "!type": "fn(array, [values])" + }, + "differenceBy": { + "!url": "https://lodash.com/docs/4.17.15#differenceBy", + "!doc": "This method is like _.difference except that it accepts iteratee which is invoked for each element of array and values to generate the criterion by which they're compared. The order and references of result values are determined by the first array. The iteratee is invoked with one argument:(value).Note: Unlike _.pullAllBy, this method returns a new array.", + "!type": "fn(array, [values], [iteratee])" + }, + "differenceWith": { + "!url": "https://lodash.com/docs/4.17.15#differenceWith", + "!doc": "This method is like _.difference except that it accepts comparator which is invoked to compare elements of array to values. The order and references of result values are determined by the first array. The comparator is invoked with two arguments: (arrVal, othVal).Note: Unlike _.pullAllWith, this method returns a new array.", + "!type": "fn(array, [values], [comparator])" + }, + "drop": { + "!url": "https://lodash.com/docs/4.17.15#drop", + "!doc": "Creates a slice of array with n elements dropped from the beginning.", + "!type": "fn(array, [n])" + }, + "dropRight": { + "!url": "https://lodash.com/docs/4.17.15#dropRight", + "!doc": "Creates a slice of array with n elements dropped from the end.", + "!type": "fn(array, [n])" + }, + "dropRightWhile": { + "!url": "https://lodash.com/docs/4.17.15#dropRightWhile", + "!doc": "Creates a slice of array excluding elements dropped from the end. Elements are dropped until predicate returns falsey. The predicate is invoked with three arguments: (value, index, array).", + "!type": "fn(array, [predicate])" + }, + "dropWhile": { + "!url": "https://lodash.com/docs/4.17.15#dropWhile", + "!doc": "Creates a slice of array excluding elements dropped from the beginning. Elements are dropped until predicate returns falsey. The predicate is invoked with three arguments: (value, index, array).", + "!type": "fn(array, [predicate])" + }, + "fill": { + "!url": "https://lodash.com/docs/4.17.15#fill", + "!doc": "Fills elements of array with value from start up to, but not including, end.Note: This method mutates array.", + "!type": "fn(array, value, [start], [end])" + }, + "findIndex": { + "!url": "https://lodash.com/docs/4.17.15#findIndex", + "!doc": "This method is like _.find except that it returns the index of the first element predicate returns truthy for instead of the element itself.", + "!type": "fn(array, [predicate], [fromIndex])" + }, + "findLastIndex": { + "!url": "https://lodash.com/docs/4.17.15#findLastIndex", + "!doc": "This method is like _.findIndex except that it iterates over elements of collection from right to left.", + "!type": "fn(array, [predicate], [fromIndex])" + }, + "flatten": { + "!url": "https://lodash.com/docs/4.17.15#flatten", + "!doc": "Flattens array a single level deep.", + "!type": "fn(array)" + }, + "flattenDeep": { + "!url": "https://lodash.com/docs/4.17.15#flattenDeep", + "!doc": "Recursively flattens array.", + "!type": "fn(array)" + }, + "flattenDepth": { + "!url": "https://lodash.com/docs/4.17.15#flattenDepth", + "!doc": "Recursively flatten array up to depth times.", + "!type": "fn(array, [depth])" + }, + "fromPairs": { + "!url": "https://lodash.com/docs/4.17.15#fromPairs", + "!doc": "The inverse of _.toPairs; this method returns an object composed from key-value pairs.", + "!type": "fn(pairs)" + }, + "head": { + "!url": "https://lodash.com/docs/4.17.15#head", + "!doc": "Gets the first element of array.", + "!type": "fn(array)" + }, + "indexOf": { + "!url": "https://lodash.com/docs/4.17.15#indexOf", + "!doc": "Gets the index at which the first occurrence of value is found in array using SameValueZero for equality comparisons. If fromIndex is negative, it's used as the offset from the end of array.", + "!type": "fn(array, value, [fromIndex])" + }, + "initial": { + "!url": "https://lodash.com/docs/4.17.15#initial", + "!doc": "Gets all but the last element of array.", + "!type": "fn(array)" + }, + "intersection": { + "!url": "https://lodash.com/docs/4.17.15#intersection", + "!doc": "Creates an array of unique values that are included in all given arrays using SameValueZero for equality comparisons. The order and references of result values are determined by the first array.", + "!type": "fn([arrays])" + }, + "intersectionBy": { + "!url": "https://lodash.com/docs/4.17.15#intersectionBy", + "!doc": "This method is like _.intersection except that it accepts iteratee which is invoked for each element of each arrays to generate the criterion by which they're compared. The order and references of result values are determined by the first array. The iteratee is invoked with one argument:(value).", + "!type": "fn([arrays], [iteratee])" + }, + "intersectionWith": { + "!url": "https://lodash.com/docs/4.17.15#intersectionWith", + "!doc": "This method is like _.intersection except that it accepts comparator which is invoked to compare elements of arrays. The order and references of result values are determined by the first array. The comparator is invoked with two arguments: (arrVal, othVal).", + "!type": "fn([arrays], [comparator])" + }, + "join": { + "!url": "https://lodash.com/docs/4.17.15#join", + "!doc": "Converts all elements in array into a string separated by separator.", + "!type": "fn(array, [separator])" + }, + "last": { + "!url": "https://lodash.com/docs/4.17.15#last", + "!doc": "Gets the last element of array.", + "!type": "fn(array)" + }, + "lastIndexOf": { + "!url": "https://lodash.com/docs/4.17.15#lastIndexOf", + "!doc": "This method is like _.indexOf except that it iterates over elements of array from right to left.", + "!type": "fn(array, value, [fromIndex])" + }, + "nth": { + "!url": "https://lodash.com/docs/4.17.15#nth", + "!doc": "Gets the element at index n of array. If n is negative, the nth element from the end is returned.", + "!type": "fn(array, [n])" + }, + "pull": { + "!url": "https://lodash.com/docs/4.17.15#pull", + "!doc": "Removes all given values from array using SameValueZero for equality comparisons.Note: Unlike _.without, this method mutates array. Use _.remove to remove elements from an array by predicate.", + "!type": "fn(array, [values])" + }, + "pullAll": { + "!url": "https://lodash.com/docs/4.17.15#pullAll", + "!doc": "This method is like _.pull except that it accepts an array of values to remove.Note: Unlike _.difference, this method mutates array.", + "!type": "fn(array, values)" + }, + "pullAllBy": { + "!url": "https://lodash.com/docs/4.17.15#pullAllBy", + "!doc": "This method is like _.pullAll except that it accepts iteratee which is invoked for each element of array and values to generate the criterion by which they're compared. The iteratee is invoked with one argument: (value).Note: Unlike _.differenceBy, this method mutates array.", + "!type": "fn(array, values, [iteratee])" + }, + "pullAllWith": { + "!url": "https://lodash.com/docs/4.17.15#pullAllWith", + "!doc": "This method is like _.pullAll except that it accepts comparator which is invoked to compare elements of array to values. The comparator is invoked with two arguments: (arrVal, othVal).Note: Unlike _.differenceWith, this method mutates array.", + "!type": "fn(array, values, [comparator])" + }, + "pullAt": { + "!url": "https://lodash.com/docs/4.17.15#pullAt", + "!doc": "Removes elements from array corresponding to indexes and returns an array of removed elements.Note: Unlike _.at, this method mutates array.", + "!type": "fn(array, [indexes])" + }, + "remove": { + "!url": "https://lodash.com/docs/4.17.15#remove", + "!doc": "Removes all elements from array that predicate returns truthy for and returns an array of the removed elements. The predicate is invoked with three arguments: (value, index, array).Note: Unlike _.filter, this method mutates array. Use _.pull to pull elements from an array by value.", + "!type": "fn(array, [predicate])" + }, + "reverse": { + "!url": "https://lodash.com/docs/4.17.15#reverse", + "!doc": "Reverses array so that the first element becomes the last, the second element becomes the second to last, and so on.Note: This method mutates array and is based on Array#reverse.", + "!type": "fn(array)" + }, + "slice": { + "!url": "https://lodash.com/docs/4.17.15#slice", + "!doc": "Creates a slice of array from start up to, but not including, end.Note: This method is used instead of Array#slice to ensure dense arrays are returned.", + "!type": "fn(array, [start], [end])" + }, + "sortedIndex": { + "!url": "https://lodash.com/docs/4.17.15#sortedIndex", + "!doc": "Uses a binary search to determine the lowest index at which value should be inserted into array in order to maintain its sort order.", + "!type": "fn(array, value)" + }, + "sortedIndexBy": { + "!url": "https://lodash.com/docs/4.17.15#sortedIndexBy", + "!doc": "This method is like _.sortedIndex except that it accepts iteratee which is invoked for value and each element of array to compute their sort ranking. The iteratee is invoked with one argument: (value).", + "!type": "fn(array, value, [iteratee])" + }, + "sortedIndexOf": { + "!url": "https://lodash.com/docs/4.17.15#sortedIndexOf", + "!doc": "This method is like _.indexOf except that it performs a binary search on a sorted array.", + "!type": "fn(array, value)" + }, + "sortedLastIndex": { + "!url": "https://lodash.com/docs/4.17.15#sortedLastIndex", + "!doc": "This method is like _.sortedIndex except that it returns the highest index at which value should be inserted into array in order to maintain its sort order.", + "!type": "fn(array, value)" + }, + "sortedLastIndexBy": { + "!url": "https://lodash.com/docs/4.17.15#sortedLastIndexBy", + "!doc": "This method is like _.sortedLastIndex except that it accepts iteratee which is invoked for value and each element of array to compute their sort ranking. The iteratee is invoked with one argument: (value).", + "!type": "fn(array, value, [iteratee])" + }, + "sortedLastIndexOf": { + "!url": "https://lodash.com/docs/4.17.15#sortedLastIndexOf", + "!doc": "This method is like _.lastIndexOf except that it performs a binary search on a sorted array.", + "!type": "fn(array, value)" + }, + "sortedUniq": { + "!url": "https://lodash.com/docs/4.17.15#sortedUniq", + "!doc": "This method is like _.uniq except that it's designed and optimized for sorted arrays.", + "!type": "fn(array)" + }, + "sortedUniqBy": { + "!url": "https://lodash.com/docs/4.17.15#sortedUniqBy", + "!doc": "This method is like _.uniqBy except that it's designed and optimized for sorted arrays.", + "!type": "fn(array, [iteratee])" + }, + "tail": { + "!url": "https://lodash.com/docs/4.17.15#tail", + "!doc": "Gets all but the first element of array.", + "!type": "fn(array)" + }, + "take": { + "!url": "https://lodash.com/docs/4.17.15#take", + "!doc": "Creates a slice of array with n elements taken from the beginning.", + "!type": "fn(array, [n])" + }, + "takeRight": { + "!url": "https://lodash.com/docs/4.17.15#takeRight", + "!doc": "Creates a slice of array with n elements taken from the end.", + "!type": "fn(array, [n])" + }, + "takeRightWhile": { + "!url": "https://lodash.com/docs/4.17.15#takeRightWhile", + "!doc": "Creates a slice of array with elements taken from the end. Elements are taken until predicate returns falsey. The predicate is invoked with three arguments: (value, index, array).", + "!type": "fn(array, [predicate])" + }, + "takeWhile": { + "!url": "https://lodash.com/docs/4.17.15#takeWhile", + "!doc": "Creates a slice of array with elements taken from the beginning. Elements are taken until predicate returns falsey. The predicate is invoked with three arguments: (value, index, array).", + "!type": "fn(array, [predicate])" + }, + "union": { + "!url": "https://lodash.com/docs/4.17.15#union", + "!doc": "Creates an array of unique values, in order, from all given arrays using SameValueZero for equality comparisons.", + "!type": "fn([arrays])" + }, + "unionBy": { + "!url": "https://lodash.com/docs/4.17.15#unionBy", + "!doc": "This method is like _.union except that it accepts iteratee which is invoked for each element of each arrays to generate the criterion by which uniqueness is computed. Result values are chosen from the first array in which the value occurs. The iteratee is invoked with one argument:(value).", + "!type": "fn([arrays], [iteratee])" + }, + "unionWith": { + "!url": "https://lodash.com/docs/4.17.15#unionWith", + "!doc": "This method is like _.union except that it accepts comparator which is invoked to compare elements of arrays. Result values are chosen from the first array in which the value occurs. The comparator is invoked with two arguments: (arrVal, othVal).", + "!type": "fn([arrays], [comparator])" + }, + "uniq": { + "!url": "https://lodash.com/docs/4.17.15#uniq", + "!doc": "Creates a duplicate-free version of an array, using SameValueZero for equality comparisons, in which only the first occurrence of each element is kept. The order of result values is determined by the order they occur in the array.", + "!type": "fn(array)" + }, + "uniqBy": { + "!url": "https://lodash.com/docs/4.17.15#uniqBy", + "!doc": "This method is like _.uniq except that it accepts iteratee which is invoked for each element in array to generate the criterion by which uniqueness is computed. The order of result values is determined by the order they occur in the array. The iteratee is invoked with one argument:(value).", + "!type": "fn(array, [iteratee])" + }, + "uniqWith": { + "!url": "https://lodash.com/docs/4.17.15#uniqWith", + "!doc": "This method is like _.uniq except that it accepts comparator which is invoked to compare elements of array. The order of result values is determined by the order they occur in the array.The comparator is invoked with two arguments: (arrVal, othVal).", + "!type": "fn(array, [comparator])" + }, + "unzip": { + "!url": "https://lodash.com/docs/4.17.15#unzip", + "!doc": "This method is like _.zip except that it accepts an array of grouped elements and creates an array regrouping the elements to their pre-zip configuration.", + "!type": "fn(array)" + }, + "unzipWith": { + "!url": "https://lodash.com/docs/4.17.15#unzipWith", + "!doc": "This method is like _.unzip except that it accepts iteratee to specify how regrouped values should be combined. The iteratee is invoked with the elements of each group: (...group).", + "!type": "fn(array, [iteratee])" + }, + "without": { + "!url": "https://lodash.com/docs/4.17.15#without", + "!doc": "Creates an array excluding all given values using SameValueZero for equality comparisons.Note: Unlike _.pull, this method returns a new array.", + "!type": "fn(array, [values])" + }, + "xor": { + "!url": "https://lodash.com/docs/4.17.15#xor", + "!doc": "Creates an array of unique values that is the symmetric difference of the given arrays. The order of result values is determined by the order they occur in the arrays.", + "!type": "fn([arrays])" + }, + "xorBy": { + "!url": "https://lodash.com/docs/4.17.15#xorBy", + "!doc": "This method is like _.xor except that it accepts iteratee which is invoked for each element of each arrays to generate the criterion by which by which they're compared. The order of result values is determined by the order they occur in the arrays. The iteratee is invoked with one argument: (value).", + "!type": "fn([arrays], [iteratee])" + }, + "xorWith": { + "!url": "https://lodash.com/docs/4.17.15#xorWith", + "!doc": "This method is like _.xor except that it accepts comparator which is invoked to compare elements of arrays. The order of result values is determined by the order they occur in the arrays. The comparator is invoked with two arguments: (arrVal, othVal).", + "!type": "fn([arrays], [comparator])" + }, + "zip": { + "!url": "https://lodash.com/docs/4.17.15#zip", + "!doc": "Creates an array of grouped elements, the first of which contains the first elements of the given arrays, the second of which contains the second elements of the given arrays, and so on.", + "!type": "fn([arrays])" + }, + "zipObject": { + "!url": "https://lodash.com/docs/4.17.15#zipObject", + "!doc": "This method is like _.fromPairs except that it accepts two arrays, one of property identifiers and one of corresponding values.", + "!type": "fn([props], [values])" + }, + "zipObjectDeep": { + "!url": "https://lodash.com/docs/4.17.15#zipObjectDeep", + "!doc": "This method is like _.zipObject except that it supports property paths.", + "!type": "fn([props], [values])" + }, + "zipWith": { + "!url": "https://lodash.com/docs/4.17.15#zipWith", + "!doc": "This method is like _.zip except that it accepts iteratee to specify how grouped values should be combined. The iteratee is invoked with the elements of each group: (...group).", + "!type": "fn([arrays], [iteratee])" + }, + "countBy": { + "!url": "https://lodash.com/docs/4.17.15#countBy", + "!doc": "Creates an object composed of keys generated from the results of running each element of collection thru iteratee. The corresponding value of each key is the number of times the key was returned by iteratee. The iteratee is invoked with one argument: (value).", + "!type": "fn(collection, [iteratee])" + }, + "every": { + "!url": "https://lodash.com/docs/4.17.15#every", + "!doc": "Checks if predicate returns truthy for all elements of collection. Iteration is stopped once predicate returns falsey. The predicate is invoked with three arguments: (value, index|key, collection).Note: This method returns true for empty collections because everything is true of elements of empty collections.", + "!type": "fn(collection, [predicate])" + }, + "filter": { + "!url": "https://lodash.com/docs/4.17.15#filter", + "!doc": "Iterates over elements of collection, returning an array of all elements predicate returns truthy for. The predicate is invoked with three arguments: (value, index|key, collection).Note: Unlike _.remove, this method returns a new array.", + "!type": "fn(collection, [predicate])" + }, + "find": { + "!url": "https://lodash.com/docs/4.17.15#find", + "!doc": "Iterates over elements of collection, returning the first element predicate returns truthy for. The predicate is invoked with three arguments: (value, index|key, collection).", + "!type": "fn(collection, [predicate], [fromIndex])" + }, + "findLast": { + "!url": "https://lodash.com/docs/4.17.15#findLast", + "!doc": "This method is like _.find except that it iterates over elements of collection from right to left.", + "!type": "fn(collection, [predicate], [fromIndex])" + }, + "flatMap": { + "!url": "https://lodash.com/docs/4.17.15#flatMap", + "!doc": "Creates a flattened array of values by running each element in collection thru iteratee and flattening the mapped results. The iteratee is invoked with three arguments: (value, index|key, collection).", + "!type": "fn(collection, [iteratee])" + }, + "flatMapDeep": { + "!url": "https://lodash.com/docs/4.17.15#flatMapDeep", + "!doc": "This method is like _.flatMap except that it recursively flattens the mapped results.", + "!type": "fn(collection, [iteratee])" + }, + "flatMapDepth": { + "!url": "https://lodash.com/docs/4.17.15#flatMapDepth", + "!doc": "This method is like _.flatMap except that it recursively flattens the mapped results up to depth times.", + "!type": "fn(collection, [iteratee], [depth])" + }, + "forEach": { + "!url": "https://lodash.com/docs/4.17.15#forEach", + "!doc": "Iterates over elements of collection and invokes iteratee for each element. The iteratee is invoked with three arguments: (value, index|key, collection). Iteratee functions may exit iteration early by explicitly returning false.Note: As with other \"Collections\" methods, objects with a \"length\" property are iterated like arrays. To avoid this behavior use _.forIn or _.forOwn for object iteration.", + "!type": "fn(collection, [iteratee])" + }, + "forEachRight": { + "!url": "https://lodash.com/docs/4.17.15#forEachRight", + "!doc": "This method is like _.forEach except that it iterates over elements of collection from right to left.", + "!type": "fn(collection, [iteratee])" + }, + "groupBy": { + "!url": "https://lodash.com/docs/4.17.15#groupBy", + "!doc": "Creates an object composed of keys generated from the results of running each element of collection thru iteratee. The order of grouped values is determined by the order they occur in collection. The corresponding value of each key is an array of elements responsible for generating the key. The iteratee is invoked with one argument: (value).", + "!type": "fn(collection, [iteratee])" + }, + "includes": { + "!url": "https://lodash.com/docs/4.17.15#includes", + "!doc": "Checks if value is in collection. If collection is a string, it's checked for a substring of value, otherwise SameValueZero is used for equality comparisons. If fromIndex is negative, it's used as the offset from the end of collection.", + "!type": "fn(collection, value, [fromIndex])" + }, + "invokeMap": { + "!url": "https://lodash.com/docs/4.17.15#invokeMap", + "!doc": "Invokes the method at path of each element in collection, returning an array of the results of each invoked method. Any additional arguments are provided to each invoked method. If path is a function, it's invoked for, and this bound to, each element in collection.", + "!type": "fn(collection, path, [args])" + }, + "keyBy": { + "!url": "https://lodash.com/docs/4.17.15#keyBy", + "!doc": "Creates an object composed of keys generated from the results of running each element of collection thru iteratee. The corresponding value of each key is the last element responsible for generating the key. The iteratee is invoked with one argument: (value).", + "!type": "fn(collection, [iteratee])" + }, + "map": { + "!url": "https://lodash.com/docs/4.17.15#map", + "!doc": "Creates an array of values by running each element in collection thru iteratee. The iteratee is invoked with three arguments:(value, index|key, collection).Many lodash methods are guarded to work as iteratees for methods like _.every, _.filter, _.map, _.mapValues, _.reject, and _.some.The guarded methods are:ary, chunk, curry, curryRight, drop, dropRight, every, fill, invert, parseInt, random, range, rangeRight, repeat, sampleSize, slice, some, sortBy, split, take, takeRight, template, trim, trimEnd, trimStart, and words", + "!type": "fn(collection, [iteratee])" + }, + "orderBy": { + "!url": "https://lodash.com/docs/4.17.15#orderBy", + "!doc": "This method is like _.sortBy except that it allows specifying the sort orders of the iteratees to sort by. If orders is unspecified, all values are sorted in ascending order. Otherwise, specify an order of \"desc\" for descending or \"asc\" for ascending sort order of corresponding values.", + "!type": "fn(collection, [iteratees], [orders])" + }, + "partition": { + "!url": "https://lodash.com/docs/4.17.15#partition", + "!doc": "Creates an array of elements split into two groups, the first of which contains elements predicate returns truthy for, the second of which contains elements predicate returns falsey for. The predicate is invoked with one argument: (value).", + "!type": "fn(collection, [predicate])" + }, + "reduce": { + "!url": "https://lodash.com/docs/4.17.15#reduce", + "!doc": "Reduces collection to a value which is the accumulated result of running each element in collection thru iteratee, where each successive invocation is supplied the return value of the previous. If accumulator is not given, the first element of collection is used as the initial value. The iteratee is invoked with four arguments:(accumulator, value, index|key, collection).Many lodash methods are guarded to work as iteratees for methods like _.reduce, _.reduceRight, and _.transform.The guarded methods are:assign, defaults, defaultsDeep, includes, merge, orderBy, and sortBy", + "!type": "fn(collection, [iteratee], [accumulator])" + }, + "reduceRight": { + "!url": "https://lodash.com/docs/4.17.15#reduceRight", + "!doc": "This method is like _.reduce except that it iterates over elements of collection from right to left.", + "!type": "fn(collection, [iteratee], [accumulator])" + }, + "reject": { + "!url": "https://lodash.com/docs/4.17.15#reject", + "!doc": "The opposite of _.filter; this method returns the elements of collection that predicate does not return truthy for.", + "!type": "fn(collection, [predicate])" + }, + "sample": { + "!url": "https://lodash.com/docs/4.17.15#sample", + "!doc": "Gets a random element from collection.", + "!type": "fn(collection)" + }, + "sampleSize": { + "!url": "https://lodash.com/docs/4.17.15#sampleSize", + "!doc": "Gets n random elements at unique keys from collection up to the size of collection.", + "!type": "fn(collection, [n])" + }, + "shuffle": { + "!url": "https://lodash.com/docs/4.17.15#shuffle", + "!doc": "Creates an array of shuffled values, using a version of the Fisher-Yates shuffle.", + "!type": "fn(collection)" + }, + "size": { + "!url": "https://lodash.com/docs/4.17.15#size", + "!doc": "Gets the size of collection by returning its length for array-like values or the number of own enumerable string keyed properties for objects.", + "!type": "fn(collection)" + }, + "some": { + "!url": "https://lodash.com/docs/4.17.15#some", + "!doc": "Checks if predicate returns truthy for any element of collection. Iteration is stopped once predicate returns truthy. The predicate is invoked with three arguments: (value, index|key, collection).", + "!type": "fn(collection, [predicate])" + }, + "sortBy": { + "!url": "https://lodash.com/docs/4.17.15#sortBy", + "!doc": "Creates an array of elements, sorted in ascending order by the results of running each element in a collection thru each iteratee. This method performs a stable sort, that is, it preserves the original sort order of equal elements. The iteratees are invoked with one argument: (value).", + "!type": "fn(collection, [iteratees])" + }, + "now": { + "!url": "https://lodash.com/docs/4.17.15#now", + "!doc": "Gets the timestamp of the number of milliseconds that have elapsed since the Unix epoch (1 January 1970 00:00:00 UTC).", + "!type": "fn()" + }, + "after": { + "!url": "https://lodash.com/docs/4.17.15#after", + "!doc": "The opposite of _.before; this method creates a function that invokes func once it's called n or more times.", + "!type": "fn(n, func)" + }, + "ary": { + "!url": "https://lodash.com/docs/4.17.15#ary", + "!doc": "Creates a function that invokes func, with up to n arguments, ignoring any additional arguments.", + "!type": "fn(func, [n])" + }, + "before": { + "!url": "https://lodash.com/docs/4.17.15#before", + "!doc": "Creates a function that invokes func, with the this binding and arguments of the created function, while it's called less than n times. Subsequent calls to the created function return the result of the last func invocation.", + "!type": "fn(n, func)" + }, + "bind": { + "!url": "https://lodash.com/docs/4.17.15#bind", + "!doc": "Creates a function that invokes func with the this binding of thisArg and partials prepended to the arguments it receives.The _.bind.placeholder value, which defaults to _ in monolithic builds, may be used as a placeholder for partially applied arguments.Note: Unlike native Function#bind, this method doesn't set the \"length\" property of bound functions.", + "!type": "fn(func, thisArg, [partials])" + }, + "bindKey": { + "!url": "https://lodash.com/docs/4.17.15#bindKey", + "!doc": "Creates a function that invokes the method at object[key] with partials prepended to the arguments it receives.This method differs from _.bind by allowing bound functions to reference methods that may be redefined or don't yet exist. See Peter Michaux's article for more details.The _.bindKey.placeholder value, which defaults to _ in monolithic builds, may be used as a placeholder for partially applied arguments.", + "!type": "fn(object, key, [partials])" + }, + "curry": { + "!url": "https://lodash.com/docs/4.17.15#curry", + "!doc": "Creates a function that accepts arguments of func and either invokes func returning its result, if at least arity number of arguments have been provided, or returns a function that accepts the remaining func arguments, and so on. The arity of func may be specified if func.length is not sufficient.The _.curry.placeholder value, which defaults to _ in monolithic builds, may be used as a placeholder for provided arguments.Note: This method doesn't set the \"length\" property of curried functions.", + "!type": "fn(func, [arity])" + }, + "curryRight": { + "!url": "https://lodash.com/docs/4.17.15#curryRight", + "!doc": "This method is like _.curry except that arguments are applied to func in the manner of _.partialRight instead of _.partial.The _.curryRight.placeholder value, which defaults to _ in monolithic builds, may be used as a placeholder for provided arguments.Note: This method doesn't set the \"length\" property of curried functions.", + "!type": "fn(func, [arity])" + }, + "debounce": { + "!url": "https://lodash.com/docs/4.17.15#debounce", + "!doc": "Creates a debounced function that delays invoking func until after wait milliseconds have elapsed since the last time the debounced function was invoked. The debounced function comes with a cancel method to cancel delayed func invocations and a flush method to immediately invoke them. Provide options to indicate whether func should be invoked on the leading and/or trailing edge of the wait timeout. The func is invoked with the last arguments provided to the debounced function. Subsequent calls to the debounced function return the result of the last func invocation.Note: If leading and trailing options are true, func is invoked on the trailing edge of the timeout only if the debounced function is invoked more than once during the wait timeout.If wait is 0 and leading is false, func invocation is deferred until to the next tick, similar to setTimeout with a timeout of 0.See David Corbacho's article for details over the differences between _.debounce and _.throttle.", + "!type": "fn(func, [wait], [options])" + }, + "defer": { + "!url": "https://lodash.com/docs/4.17.15#defer", + "!doc": "Defers invoking the func until the current call stack has cleared. Any additional arguments are provided to func when it's invoked.", + "!type": "fn(func, [args])" + }, + "delay": { + "!url": "https://lodash.com/docs/4.17.15#delay", + "!doc": "Invokes func after wait milliseconds. Any additional arguments are provided to func when it's invoked.", + "!type": "fn(func, wait, [args])" + }, + "flip": { + "!url": "https://lodash.com/docs/4.17.15#flip", + "!doc": "Creates a function that invokes func with arguments reversed.", + "!type": "fn(func)" + }, + "memoize": { + "!url": "https://lodash.com/docs/4.17.15#memoize", + "!doc": "Creates a function that memoizes the result of func. If resolver is provided, it determines the cache key for storing the result based on the arguments provided to the memoized function. By default, the first argument provided to the memoized function is used as the map cache key. The func is invoked with the this binding of the memoized function.Note: The cache is exposed as the cache property on the memoized function. Its creation may be customized by replacing the _.memoize.Cache constructor with one whose instances implement the Map method interface of clear, delete, get, has, and set.", + "!type": "fn(func, [resolver])" + }, + "negate": { + "!url": "https://lodash.com/docs/4.17.15#negate", + "!doc": "Creates a function that negates the result of the predicate func. The func predicate is invoked with the this binding and arguments of the created function.", + "!type": "fn(predicate)" + }, + "once": { + "!url": "https://lodash.com/docs/4.17.15#once", + "!doc": "Creates a function that is restricted to invoking func once. Repeat calls to the function return the value of the first invocation. The func is invoked with the this binding and arguments of the created function.", + "!type": "fn(func)" + }, + "overArgs": { + "!url": "https://lodash.com/docs/4.17.15#overArgs", + "!doc": "Creates a function that invokes func with its arguments transformed.", + "!type": "fn(func, [transforms])" + }, + "partial": { + "!url": "https://lodash.com/docs/4.17.15#partial", + "!doc": "Creates a function that invokes func with partials prepended to the arguments it receives. This method is like _.bind except it does not alter the this binding.The _.partial.placeholder value, which defaults to _ in monolithic builds, may be used as a placeholder for partially applied arguments.Note: This method doesn't set the \"length\" property of partially applied functions.", + "!type": "fn(func, [partials])" + }, + "partialRight": { + "!url": "https://lodash.com/docs/4.17.15#partialRight", + "!doc": "This method is like _.partial except that partially applied arguments are appended to the arguments it receives.The _.partialRight.placeholder value, which defaults to _ in monolithic builds, may be used as a placeholder for partially applied arguments.Note: This method doesn't set the \"length\" property of partially applied functions.", + "!type": "fn(func, [partials])" + }, + "rearg": { + "!url": "https://lodash.com/docs/4.17.15#rearg", + "!doc": "Creates a function that invokes func with arguments arranged according to the specified indexes where the argument value at the first index is provided as the first argument, the argument value at the second index is provided as the second argument, and so on.", + "!type": "fn(func, indexes)" + }, + "rest": { + "!url": "https://lodash.com/docs/4.17.15#rest", + "!doc": "Creates a function that invokes func with the this binding of the created function and arguments from start and beyond provided as an array.Note: This method is based on the rest parameter.", + "!type": "fn(func, [start])" + }, + "spread": { + "!url": "https://lodash.com/docs/4.17.15#spread", + "!doc": "Creates a function that invokes func with the this binding of the create function and an array of arguments much like Function#apply.Note: This method is based on the spread operator.", + "!type": "fn(func, [start])" + }, + "throttle": { + "!url": "https://lodash.com/docs/4.17.15#throttle", + "!doc": "Creates a throttled function that only invokes func at most once per every wait milliseconds. The throttled function comes with a cancel method to cancel delayed func invocations and a flush method to immediately invoke them. Provide options to indicate whether func should be invoked on the leading and/or trailing edge of the wait timeout. The func is invoked with the last arguments provided to the throttled function. Subsequent calls to the throttled function return the result of the last func invocation.Note: If leading and trailing options are true, func is invoked on the trailing edge of the timeout only if the throttled function is invoked more than once during the wait timeout.If wait is 0 and leading is false, func invocation is deferred until to the next tick, similar to setTimeout with a timeout of 0.See David Corbacho's article for details over the differences between _.throttle and _.debounce.", + "!type": "fn(func, [wait], [options])" + }, + "unary": { + "!url": "https://lodash.com/docs/4.17.15#unary", + "!doc": "Creates a function that accepts up to one argument, ignoring any additional arguments.", + "!type": "fn(func)" + }, + "wrap": { + "!url": "https://lodash.com/docs/4.17.15#wrap", + "!doc": "Creates a function that provides value to wrapper as its first argument. Any additional arguments provided to the function are appended to those provided to the wrapper. The wrapper is invoked with the this binding of the created function.", + "!type": "fn(value, [wrapper])" + }, + "castArray": { + "!url": "https://lodash.com/docs/4.17.15#castArray", + "!doc": "Casts value as an array if it's not one.", + "!type": "fn(value)" + }, + "clone": { + "!url": "https://lodash.com/docs/4.17.15#clone", + "!doc": "Creates a shallow clone of value.Note: This method is loosely based on the structured clone algorithm and supports cloning arrays, array buffers, booleans, date objects, maps, numbers, Object objects, regexes, sets, strings, symbols, and typed arrays. The own enumerable properties of arguments objects are cloned as plain objects. An empty object is returned for uncloneable values such as error objects, functions, DOM nodes, and WeakMaps.", + "!type": "fn(value)" + }, + "cloneDeep": { + "!url": "https://lodash.com/docs/4.17.15#cloneDeep", + "!doc": "This method is like _.clone except that it recursively clones value.", + "!type": "fn(value)" + }, + "cloneDeepWith": { + "!url": "https://lodash.com/docs/4.17.15#cloneDeepWith", + "!doc": "This method is like _.cloneWith except that it recursively clones value.", + "!type": "fn(value, [customizer])" + }, + "cloneWith": { + "!url": "https://lodash.com/docs/4.17.15#cloneWith", + "!doc": "This method is like _.clone except that it accepts customizer which is invoked to produce the cloned value. If customizer returns undefined, cloning is handled by the method instead. The customizer is invoked with up to four arguments; (value [, index|key, object, stack]).", + "!type": "fn(value, [customizer])" + }, + "conformsTo": { + "!url": "https://lodash.com/docs/4.17.15#conformsTo", + "!doc": "Checks if object conforms to source by invoking the predicate properties of source with the corresponding property values of object.Note: This method is equivalent to _.conforms when source is partially applied.", + "!type": "fn(object, source)" + }, + "eq": { + "!url": "https://lodash.com/docs/4.17.15#eq", + "!doc": "Performs a SameValueZero comparison between two values to determine if they are equivalent.", + "!type": "fn(value, other)" + }, + "gt": { + "!url": "https://lodash.com/docs/4.17.15#gt", + "!doc": "Checks if value is greater than other.", + "!type": "fn(value, other)" + }, + "gte": { + "!url": "https://lodash.com/docs/4.17.15#gte", + "!doc": "Checks if value is greater than or equal to other.", + "!type": "fn(value, other)" + }, + "isArguments": { + "!url": "https://lodash.com/docs/4.17.15#isArguments", + "!doc": "Checks if value is likely an arguments object.", + "!type": "fn(value)" + }, + "isArray": { + "!url": "https://lodash.com/docs/4.17.15#isArray", + "!doc": "Checks if value is classified as an Array object.", + "!type": "fn(value)" + }, + "isArrayBuffer": { + "!url": "https://lodash.com/docs/4.17.15#isArrayBuffer", + "!doc": "Checks if value is classified as an ArrayBuffer object.", + "!type": "fn(value)" + }, + "isArrayLike": { + "!url": "https://lodash.com/docs/4.17.15#isArrayLike", + "!doc": "Checks if value is array-like. A value is considered array-like if it's not a function and has a value.length that's an integer greater than or equal to 0 and less than or equal to Number.MAX_SAFE_INTEGER.", + "!type": "fn(value)" + }, + "isArrayLikeObject": { + "!url": "https://lodash.com/docs/4.17.15#isArrayLikeObject", + "!doc": "This method is like _.isArrayLike except that it also checks if value is an object.", + "!type": "fn(value)" + }, + "isBoolean": { + "!url": "https://lodash.com/docs/4.17.15#isBoolean", + "!doc": "Checks if value is classified as a boolean primitive or object.", + "!type": "fn(value)" + }, + "isBuffer": { + "!url": "https://lodash.com/docs/4.17.15#isBuffer", + "!doc": "Checks if value is a buffer.", + "!type": "fn(value)" + }, + "isDate": { + "!url": "https://lodash.com/docs/4.17.15#isDate", + "!doc": "Checks if value is classified as a Date object.", + "!type": "fn(value)" + }, + "isElement": { + "!url": "https://lodash.com/docs/4.17.15#isElement", + "!doc": "Checks if value is likely a DOM element.", + "!type": "fn(value)" + }, + "isEmpty": { + "!url": "https://lodash.com/docs/4.17.15#isEmpty", + "!doc": "Checks if value is an empty object, collection, map, or set.Objects are considered empty if they have no own enumerable string keyed properties.Array-like values such as arguments objects, arrays, buffers, strings, or jQuery-like collections are considered empty if they have a length of 0. Similarly, maps and sets are considered empty if they have a size of 0.", + "!type": "fn(value)" + }, + "isEqual": { + "!url": "https://lodash.com/docs/4.17.15#isEqual", + "!doc": "Performs a deep comparison between two values to determine if they are equivalent.Note: This method supports comparing arrays, array buffers, booleans, date objects, error objects, maps, numbers, Object objects, regexes, sets, strings, symbols, and typed arrays. Object objects are compared by their own, not inherited, enumerable properties. Functions and DOM nodes are compared by strict equality, i.e. ===.", + "!type": "fn(value, other)" + }, + "isEqualWith": { + "!url": "https://lodash.com/docs/4.17.15#isEqualWith", + "!doc": "This method is like _.isEqual except that it accepts customizer which is invoked to compare values. If customizer returns undefined, comparisons are handled by the method instead. The customizer is invoked with up to six arguments: (objValue, othValue [, index|key, object, other, stack]).", + "!type": "fn(value, other, [customizer])" + }, + "isError": { + "!url": "https://lodash.com/docs/4.17.15#isError", + "!doc": "Checks if value is an Error, EvalError, RangeError, ReferenceError, SyntaxError, TypeError, or URIError object.", + "!type": "fn(value)" + }, + "isFinite": { + "!url": "https://lodash.com/docs/4.17.15#isFinite", + "!doc": "Checks if value is a finite primitive number.Note: This method is based on Number.isFinite.", + "!type": "fn(value)" + }, + "isFunction": { + "!url": "https://lodash.com/docs/4.17.15#isFunction", + "!doc": "Checks if value is classified as a Function object.", + "!type": "fn(value)" + }, + "isInteger": { + "!url": "https://lodash.com/docs/4.17.15#isInteger", + "!doc": "Checks if value is an integer.Note: This method is based on Number.isInteger.", + "!type": "fn(value)" + }, + "isLength": { + "!url": "https://lodash.com/docs/4.17.15#isLength", + "!doc": "Checks if value is a valid array-like length.Note: This method is loosely based on ToLength.", + "!type": "fn(value)" + }, + "isMap": { + "!url": "https://lodash.com/docs/4.17.15#isMap", + "!doc": "Checks if value is classified as a Map object.", + "!type": "fn(value)" + }, + "isMatch": { + "!url": "https://lodash.com/docs/4.17.15#isMatch", + "!doc": "Performs a partial deep comparison between object and source to determine if object contains equivalent property values.Note: This method is equivalent to _.matches when source is partially applied.Partial comparisons will match empty array and empty object source values against any array or object value, respectively. See _.isEqual for a list of supported value comparisons.", + "!type": "fn(object, source)" + }, + "isMatchWith": { + "!url": "https://lodash.com/docs/4.17.15#isMatchWith", + "!doc": "This method is like _.isMatch except that it accepts customizer which is invoked to compare values. If customizer returns undefined, comparisons are handled by the method instead. The customizer is invoked with five arguments: (objValue, srcValue, index|key, object, source).", + "!type": "fn(object, source, [customizer])" + }, + "isNaN": { + "!url": "https://lodash.com/docs/4.17.15#isNaN", + "!doc": "Checks if value is NaN.Note: This method is based on Number.isNaN and is not the same as global isNaN which returns true for undefined and other non-number values.", + "!type": "fn(value)" + }, + "isNative": { + "!url": "https://lodash.com/docs/4.17.15#isNative", + "!doc": "Checks if value is a pristine native function.Note: This method can't reliably detect native functions in the presence of the core-js package because core-js circumvents this kind of detection. Despite multiple requests, the core-js maintainer has made it clear: any attempt to fix the detection will be obstructed. As a result, we're left with little choice but to throw an error. Unfortunately, this also affects packages, like babel-polyfill, which rely on core-js.", + "!type": "fn(value)" + }, + "isNil": { + "!url": "https://lodash.com/docs/4.17.15#isNil", + "!doc": "Checks if value is null or undefined.", + "!type": "fn(value)" + }, + "isNull": { + "!url": "https://lodash.com/docs/4.17.15#isNull", + "!doc": "Checks if value is null.", + "!type": "fn(value)" + }, + "isNumber": { + "!url": "https://lodash.com/docs/4.17.15#isNumber", + "!doc": "Checks if value is classified as a Number primitive or object.Note: To exclude Infinity, -Infinity, and NaN, which are classified as numbers, use the _.isFinite method.", + "!type": "fn(value)" + }, + "isObject": { + "!url": "https://lodash.com/docs/4.17.15#isObject", + "!doc": "Checks if value is the language type of Object. (e.g. arrays, functions, objects, regexes, new Number(0), and new String(''))", + "!type": "fn(value)" + }, + "isObjectLike": { + "!url": "https://lodash.com/docs/4.17.15#isObjectLike", + "!doc": "Checks if value is object-like. A value is object-like if it's not null and has a typeof result of \"object\".", + "!type": "fn(value)" + }, + "isPlainObject": { + "!url": "https://lodash.com/docs/4.17.15#isPlainObject", + "!doc": "Checks if value is a plain object, that is, an object created by the Object constructor or one with a [[Prototype]] of null.", + "!type": "fn(value)" + }, + "isRegExp": { + "!url": "https://lodash.com/docs/4.17.15#isRegExp", + "!doc": "Checks if value is classified as a RegExp object.", + "!type": "fn(value)" + }, + "isSafeInteger": { + "!url": "https://lodash.com/docs/4.17.15#isSafeInteger", + "!doc": "Checks if value is a safe integer. An integer is safe if it's an IEEE-754 double precision number which isn't the result of a rounded unsafe integer.Note: This method is based on Number.isSafeInteger.", + "!type": "fn(value)" + }, + "isSet": { + "!url": "https://lodash.com/docs/4.17.15#isSet", + "!doc": "Checks if value is classified as a Set object.", + "!type": "fn(value)" + }, + "isString": { + "!url": "https://lodash.com/docs/4.17.15#isString", + "!doc": "Checks if value is classified as a String primitive or object.", + "!type": "fn(value)" + }, + "isSymbol": { + "!url": "https://lodash.com/docs/4.17.15#isSymbol", + "!doc": "Checks if value is classified as a Symbol primitive or object.", + "!type": "fn(value)" + }, + "isTypedArray": { + "!url": "https://lodash.com/docs/4.17.15#isTypedArray", + "!doc": "Checks if value is classified as a typed array.", + "!type": "fn(value)" + }, + "isUndefined": { + "!url": "https://lodash.com/docs/4.17.15#isUndefined", + "!doc": "Checks if value is undefined.", + "!type": "fn(value)" + }, + "isWeakMap": { + "!url": "https://lodash.com/docs/4.17.15#isWeakMap", + "!doc": "Checks if value is classified as a WeakMap object.", + "!type": "fn(value)" + }, + "isWeakSet": { + "!url": "https://lodash.com/docs/4.17.15#isWeakSet", + "!doc": "Checks if value is classified as a WeakSet object.", + "!type": "fn(value)" + }, + "lt": { + "!url": "https://lodash.com/docs/4.17.15#lt", + "!doc": "Checks if value is less than other.", + "!type": "fn(value, other)" + }, + "lte": { + "!url": "https://lodash.com/docs/4.17.15#lte", + "!doc": "Checks if value is less than or equal to other.", + "!type": "fn(value, other)" + }, + "toArray": { + "!url": "https://lodash.com/docs/4.17.15#toArray", + "!doc": "Converts value to an array.", + "!type": "fn(value)" + }, + "toFinite": { + "!url": "https://lodash.com/docs/4.17.15#toFinite", + "!doc": "Converts value to a finite number.", + "!type": "fn(value)" + }, + "toInteger": { + "!url": "https://lodash.com/docs/4.17.15#toInteger", + "!doc": "Converts value to an integer.Note: This method is loosely based on ToInteger.", + "!type": "fn(value)" + }, + "toLength": { + "!url": "https://lodash.com/docs/4.17.15#toLength", + "!doc": "Converts value to an integer suitable for use as the length of an array-like object.Note: This method is based on ToLength.", + "!type": "fn(value)" + }, + "toNumber": { + "!url": "https://lodash.com/docs/4.17.15#toNumber", + "!doc": "Converts value to a number.", + "!type": "fn(value)" + }, + "toPlainObject": { + "!url": "https://lodash.com/docs/4.17.15#toPlainObject", + "!doc": "Converts value to a plain object flattening inherited enumerable string keyed properties of value to own properties of the plain object.", + "!type": "fn(value)" + }, + "toSafeInteger": { + "!url": "https://lodash.com/docs/4.17.15#toSafeInteger", + "!doc": "Converts value to a safe integer. A safe integer can be compared and represented correctly.", + "!type": "fn(value)" + }, + "toString": { + "!url": "https://lodash.com/docs/4.17.15#toString", + "!doc": "Converts value to a string. An empty string is returned for null and undefined values. The sign of -0 is preserved.", + "!type": "fn(value)" + }, + "add": { + "!url": "https://lodash.com/docs/4.17.15#add", + "!doc": "Adds two numbers.", + "!type": "fn(augend, addend)" + }, + "ceil": { + "!url": "https://lodash.com/docs/4.17.15#ceil", + "!doc": "Computes number rounded up to precision.", + "!type": "fn(number, [precision])" + }, + "divide": { + "!url": "https://lodash.com/docs/4.17.15#divide", + "!doc": "Divide two numbers.", + "!type": "fn(dividend, divisor)" + }, + "floor": { + "!url": "https://lodash.com/docs/4.17.15#floor", + "!doc": "Computes number rounded down to precision.", + "!type": "fn(number, [precision])" + }, + "max": { + "!url": "https://lodash.com/docs/4.17.15#max", + "!doc": "Computes the maximum value of array. If array is empty or falsey, undefined is returned.", + "!type": "fn(array)" + }, + "maxBy": { + "!url": "https://lodash.com/docs/4.17.15#maxBy", + "!doc": "This method is like _.max except that it accepts iteratee which is invoked for each element in array to generate the criterion by which the value is ranked. The iteratee is invoked with one argument: (value).", + "!type": "fn(array, [iteratee])" + }, + "mean": { + "!url": "https://lodash.com/docs/4.17.15#mean", + "!doc": "Computes the mean of the values in array.", + "!type": "fn(array)" + }, + "meanBy": { + "!url": "https://lodash.com/docs/4.17.15#meanBy", + "!doc": "This method is like _.mean except that it accepts iteratee which is invoked for each element in array to generate the value to be averaged. The iteratee is invoked with one argument: (value).", + "!type": "fn(array, [iteratee])" + }, + "min": { + "!url": "https://lodash.com/docs/4.17.15#min", + "!doc": "Computes the minimum value of array. If array is empty or falsey, undefined is returned.", + "!type": "fn(array)" + }, + "minBy": { + "!url": "https://lodash.com/docs/4.17.15#minBy", + "!doc": "This method is like _.min except that it accepts iteratee which is invoked for each element in array to generate the criterion by which the value is ranked. The iteratee is invoked with one argument: (value).", + "!type": "fn(array, [iteratee])" + }, + "multiply": { + "!url": "https://lodash.com/docs/4.17.15#multiply", + "!doc": "Multiply two numbers.", + "!type": "fn(multiplier, multiplicand)" + }, + "round": { + "!url": "https://lodash.com/docs/4.17.15#round", + "!doc": "Computes number rounded to precision.", + "!type": "fn(number, [precision])" + }, + "subtract": { + "!url": "https://lodash.com/docs/4.17.15#subtract", + "!doc": "Subtract two numbers.", + "!type": "fn(minuend, subtrahend)" + }, + "sum": { + "!url": "https://lodash.com/docs/4.17.15#sum", + "!doc": "Computes the sum of the values in array.", + "!type": "fn(array)" + }, + "sumBy": { + "!url": "https://lodash.com/docs/4.17.15#sumBy", + "!doc": "This method is like _.sum except that it accepts iteratee which is invoked for each element in array to generate the value to be summed. The iteratee is invoked with one argument: (value).", + "!type": "fn(array, [iteratee])" + }, + "clamp": { + "!url": "https://lodash.com/docs/4.17.15#clamp", + "!doc": "Clamps number within the inclusive lower and upper bounds.", + "!type": "fn(number, [lower], upper)" + }, + "inRange": { + "!url": "https://lodash.com/docs/4.17.15#inRange", + "!doc": "Checks if n is between start and up to, but not including, end. If end is not specified, it's set to start with start then set to 0. If start is greater than end the params are swapped to support negative ranges.", + "!type": "fn(number, [start], end)" + }, + "random": { + "!url": "https://lodash.com/docs/4.17.15#random", + "!doc": "Produces a random number between the inclusive lower and upper bounds. If only one argument is provided a number between 0 and the given number is returned. If floating is true, or either lower or upper are floats, a floating-point number is returned instead of an integer.Note: JavaScript follows the IEEE-754 standard for resolving floating-point values which can produce unexpected results.", + "!type": "fn([lower], [upper], [floating])" + }, + "assign": { + "!url": "https://lodash.com/docs/4.17.15#assign", + "!doc": "Assigns own enumerable string keyed properties of source objects to the destination object. Source objects are applied from left to right. Subsequent sources overwrite property assignments of previous sources.Note: This method mutates object and is loosely based on Object.assign.", + "!type": "fn(object, [sources])" + }, + "assignIn": { + "!url": "https://lodash.com/docs/4.17.15#assignIn", + "!doc": "This method is like _.assign except that it iterates over own and inherited source properties.Note: This method mutates object.", + "!type": "fn(object, [sources])" + }, + "assignInWith": { + "!url": "https://lodash.com/docs/4.17.15#assignInWith", + "!doc": "This method is like _.assignIn except that it accepts customizer which is invoked to produce the assigned values. If customizer returns undefined, assignment is handled by the method instead. The customizer is invoked with five arguments: (objValue, srcValue, key, object, source).Note: This method mutates object.", + "!type": "fn(object, sources, [customizer])" + }, + "assignWith": { + "!url": "https://lodash.com/docs/4.17.15#assignWith", + "!doc": "This method is like _.assign except that it accepts customizer which is invoked to produce the assigned values. If customizer returns undefined, assignment is handled by the method instead. The customizer is invoked with five arguments: (objValue, srcValue, key, object, source).Note: This method mutates object.", + "!type": "fn(object, sources, [customizer])" + }, + "at": { + "!url": "https://lodash.com/docs/4.17.15#at", + "!doc": "Creates an array of values corresponding to paths of object.", + "!type": "fn(object, [paths])" + }, + "create": { + "!url": "https://lodash.com/docs/4.17.15#create", + "!doc": "Creates an object that inherits from the prototype object. If a properties object is given, its own enumerable string keyed properties are assigned to the created object.", + "!type": "fn(prototype, [properties])" + }, + "defaults": { + "!url": "https://lodash.com/docs/4.17.15#defaults", + "!doc": "Assigns own and inherited enumerable string keyed properties of source objects to the destination object for all destination properties that resolve to undefined. Source objects are applied from left to right. Once a property is set, additional values of the same property are ignored.Note: This method mutates object.", + "!type": "fn(object, [sources])" + }, + "defaultsDeep": { + "!url": "https://lodash.com/docs/4.17.15#defaultsDeep", + "!doc": "This method is like _.defaults except that it recursively assigns default properties.Note: This method mutates object.", + "!type": "fn(object, [sources])" + }, + "findKey": { + "!url": "https://lodash.com/docs/4.17.15#findKey", + "!doc": "This method is like _.find except that it returns the key of the first element predicate returns truthy for instead of the element itself.", + "!type": "fn(object, [predicate])" + }, + "findLastKey": { + "!url": "https://lodash.com/docs/4.17.15#findLastKey", + "!doc": "This method is like _.findKey except that it iterates over elements of a collection in the opposite order.", + "!type": "fn(object, [predicate])" + }, + "forIn": { + "!url": "https://lodash.com/docs/4.17.15#forIn", + "!doc": "Iterates over own and inherited enumerable string keyed properties of an object and invokes iteratee for each property. The iteratee is invoked with three arguments: (value, key, object). Iteratee functions may exit iteration early by explicitly returning false.", + "!type": "fn(object, [iteratee])" + }, + "forInRight": { + "!url": "https://lodash.com/docs/4.17.15#forInRight", + "!doc": "This method is like _.forIn except that it iterates over properties of object in the opposite order.", + "!type": "fn(object, [iteratee])" + }, + "forOwn": { + "!url": "https://lodash.com/docs/4.17.15#forOwn", + "!doc": "Iterates over own enumerable string keyed properties of an object and invokes iteratee for each property. The iteratee is invoked with three arguments: (value, key, object). Iteratee functions may exit iteration early by explicitly returning false.", + "!type": "fn(object, [iteratee])" + }, + "forOwnRight": { + "!url": "https://lodash.com/docs/4.17.15#forOwnRight", + "!doc": "This method is like _.forOwn except that it iterates over properties of object in the opposite order.", + "!type": "fn(object, [iteratee])" + }, + "functions": { + "!url": "https://lodash.com/docs/4.17.15#functions", + "!doc": "Creates an array of function property names from own enumerable properties of object.", + "!type": "fn(object)" + }, + "functionsIn": { + "!url": "https://lodash.com/docs/4.17.15#functionsIn", + "!doc": "Creates an array of function property names from own and inherited enumerable properties of object.", + "!type": "fn(object)" + }, + "get": { + "!url": "https://lodash.com/docs/4.17.15#get", + "!doc": "Gets the value at path of object. If the resolved value is undefined, the defaultValue is returned in its place.", + "!type": "fn(object, path, [defaultValue])" + }, + "has": { + "!url": "https://lodash.com/docs/4.17.15#has", + "!doc": "Checks if path is a direct property of object.", + "!type": "fn(object, path)" + }, + "hasIn": { + "!url": "https://lodash.com/docs/4.17.15#hasIn", + "!doc": "Checks if path is a direct or inherited property of object.", + "!type": "fn(object, path)" + }, + "invert": { + "!url": "https://lodash.com/docs/4.17.15#invert", + "!doc": "Creates an object composed of the inverted keys and values of object. If object contains duplicate values, subsequent values overwrite property assignments of previous values.", + "!type": "fn(object)" + }, + "invertBy": { + "!url": "https://lodash.com/docs/4.17.15#invertBy", + "!doc": "This method is like _.invert except that the inverted object is generated from the results of running each element of object thru iteratee. The corresponding inverted value of each inverted key is an array of keys responsible for generating the inverted value. The iteratee is invoked with one argument: (value).", + "!type": "fn(object, [iteratee])" + }, + "invoke": { + "!url": "https://lodash.com/docs/4.17.15#invoke", + "!doc": "Invokes the method at path of object.", + "!type": "fn(object, path, [args])" + }, + "keys": { + "!url": "https://lodash.com/docs/4.17.15#keys", + "!doc": "Creates an array of the own enumerable property names of object.Note: Non-object values are coerced to objects. See the ES spec for more details.", + "!type": "fn(object)" + }, + "keysIn": { + "!url": "https://lodash.com/docs/4.17.15#keysIn", + "!doc": "Creates an array of the own and inherited enumerable property names of object.Note: Non-object values are coerced to objects.", + "!type": "fn(object)" + }, + "mapKeys": { + "!url": "https://lodash.com/docs/4.17.15#mapKeys", + "!doc": "The opposite of _.mapValues; this method creates an object with the same values as object and keys generated by running each own enumerable string keyed property of object thru iteratee. The iteratee is invoked with three arguments: (value, key, object).", + "!type": "fn(object, [iteratee])" + }, + "mapValues": { + "!url": "https://lodash.com/docs/4.17.15#mapValues", + "!doc": "Creates an object with the same keys as object and values generated by running each own enumerable string keyed property of object thru iteratee. The iteratee is invoked with three arguments:(value, key, object).", + "!type": "fn(object, [iteratee])" + }, + "merge": { + "!url": "https://lodash.com/docs/4.17.15#merge", + "!doc": "This method is like _.assign except that it recursively merges own and inherited enumerable string keyed properties of source objects into the destination object. Source properties that resolve to undefined are skipped if a destination value exists. Array and plain object properties are merged recursively. Other objects and value types are overridden by assignment. Source objects are applied from left to right. Subsequent sources overwrite property assignments of previous sources.Note: This method mutates object.", + "!type": "fn(object, [sources])" + }, + "mergeWith": { + "!url": "https://lodash.com/docs/4.17.15#mergeWith", + "!doc": "This method is like _.merge except that it accepts customizer which is invoked to produce the merged values of the destination and source properties. If customizer returns undefined, merging is handled by the method instead. The customizer is invoked with six arguments:(objValue, srcValue, key, object, source, stack).Note: This method mutates object.", + "!type": "fn(object, sources, customizer)" + }, + "omit": { + "!url": "https://lodash.com/docs/4.17.15#omit", + "!doc": "The opposite of _.pick; this method creates an object composed of the own and inherited enumerable property paths of object that are not omitted.Note: This method is considerably slower than _.pick.", + "!type": "fn(object, [paths])" + }, + "omitBy": { + "!url": "https://lodash.com/docs/4.17.15#omitBy", + "!doc": "The opposite of _.pickBy; this method creates an object composed of the own and inherited enumerable string keyed properties of object that predicate doesn't return truthy for. The predicate is invoked with two arguments: (value, key).", + "!type": "fn(object, [predicate])" + }, + "pick": { + "!url": "https://lodash.com/docs/4.17.15#pick", + "!doc": "Creates an object composed of the picked object properties.", + "!type": "fn(object, [paths])" + }, + "pickBy": { + "!url": "https://lodash.com/docs/4.17.15#pickBy", + "!doc": "Creates an object composed of the object properties predicate returns truthy for. The predicate is invoked with two arguments: (value, key).", + "!type": "fn(object, [predicate])" + }, + "result": { + "!url": "https://lodash.com/docs/4.17.15#result", + "!doc": "This method is like _.get except that if the resolved value is a function it's invoked with the this binding of its parent object and its result is returned.", + "!type": "fn(object, path, [defaultValue])" + }, + "set": { + "!url": "https://lodash.com/docs/4.17.15#set", + "!doc": "Sets the value at path of object. If a portion of path doesn't exist, it's created. Arrays are created for missing index properties while objects are created for all other missing properties. Use _.setWith to customize path creation.Note: This method mutates object.", + "!type": "fn(object, path, value)" + }, + "setWith": { + "!url": "https://lodash.com/docs/4.17.15#setWith", + "!doc": "This method is like _.set except that it accepts customizer which is invoked to produce the objects of path. If customizer returns undefined path creation is handled by the method instead. The customizer is invoked with three arguments: (nsValue, key, nsObject).Note: This method mutates object.", + "!type": "fn(object, path, value, [customizer])" + }, + "toPairs": { + "!url": "https://lodash.com/docs/4.17.15#toPairs", + "!doc": "Creates an array of own enumerable string keyed-value pairs for object which can be consumed by _.fromPairs. If object is a map or set, its entries are returned.", + "!type": "fn(object)" + }, + "toPairsIn": { + "!url": "https://lodash.com/docs/4.17.15#toPairsIn", + "!doc": "Creates an array of own and inherited enumerable string keyed-value pairs for object which can be consumed by _.fromPairs. If object is a map or set, its entries are returned.", + "!type": "fn(object)" + }, + "transform": { + "!url": "https://lodash.com/docs/4.17.15#transform", + "!doc": "An alternative to _.reduce; this method transforms object to a new accumulator object which is the result of running each of its own enumerable string keyed properties thru iteratee, with each invocation potentially mutating the accumulator object. If accumulator is not provided, a new object with the same [[Prototype]] will be used. The iteratee is invoked with four arguments: (accumulator, value, key, object). Iteratee functions may exit iteration early by explicitly returning false.", + "!type": "fn(object, [iteratee], [accumulator])" + }, + "unset": { + "!url": "https://lodash.com/docs/4.17.15#unset", + "!doc": "Removes the property at path of object.Note: This method mutates object.", + "!type": "fn(object, path)" + }, + "update": { + "!url": "https://lodash.com/docs/4.17.15#update", + "!doc": "This method is like _.set except that accepts updater to produce the value to set. Use _.updateWith to customize path creation. The updater is invoked with one argument: (value).Note: This method mutates object.", + "!type": "fn(object, path, updater)" + }, + "updateWith": { + "!url": "https://lodash.com/docs/4.17.15#updateWith", + "!doc": "This method is like _.update except that it accepts customizer which is invoked to produce the objects of path. If customizer returns undefined path creation is handled by the method instead. The customizer is invoked with three arguments: (nsValue, key, nsObject).Note: This method mutates object.", + "!type": "fn(object, path, updater, [customizer])" + }, + "values": { + "!url": "https://lodash.com/docs/4.17.15#values", + "!doc": "Creates an array of the own enumerable string keyed property values of object.Note: Non-object values are coerced to objects.", + "!type": "fn(object)" + }, + "valuesIn": { + "!url": "https://lodash.com/docs/4.17.15#valuesIn", + "!doc": "Creates an array of the own and inherited enumerable string keyed property values of object.Note: Non-object values are coerced to objects.", + "!type": "fn(object)" + }, + "_": { + "!url": "https://lodash.com/docs/4.17.15#lodash", + "!doc": "Creates a lodash object which wraps value to enable implicit method chain sequences. Methods that operate on and return arrays, collections, and functions can be chained together. Methods that retrieve a single value or may return a primitive value will automatically end the chain sequence and return the unwrapped value. Otherwise, the value must be unwrapped with _#value.Explicit chain sequences, which must be unwrapped with _#value, may be enabled using _.chain.The execution of chained methods is lazy, that is, it's deferred until _#value is implicitly or explicitly called.Lazy evaluation allows several methods to support shortcut fusion. Shortcut fusion is an optimization to merge iteratee calls; this avoids the creation of intermediate arrays and can greatly reduce the number of iteratee executions. Sections of a chain sequence qualify for shortcut fusion if the section is applied to an array and iteratees accept only one argument. The heuristic for whether a section qualifies for shortcut fusion is subject to change.Chaining is supported in custom builds as long as the _#value method is directly or indirectly included in the build.In addition to lodash methods, wrappers have Array and String methods.The wrapper Array methods are:concat, join, pop, push, shift, sort, splice, and unshiftThe wrapper String methods are:replace and splitThe wrapper methods that support shortcut fusion are:at, compact, drop, dropRight, dropWhile, filter, find, findLast, head, initial, last, map, reject, reverse, slice, tail, take, takeRight, takeRightWhile, takeWhile, and toArrayThe chainable wrapper methods are:after, ary, assign, assignIn, assignInWith, assignWith, at, before, bind, bindAll, bindKey, castArray, chain, chunk, commit, compact, concat, conforms, constant, countBy, create, curry, debounce, defaults, defaultsDeep, defer, delay, difference, differenceBy, differenceWith, drop, dropRight, dropRightWhile, dropWhile, extend, extendWith, fill, filter, flatMap, flatMapDeep, flatMapDepth, flatten, flattenDeep, flattenDepth, flip, flow, flowRight, fromPairs, functions, functionsIn, groupBy, initial, intersection, intersectionBy, intersectionWith, invert, invertBy, invokeMap, iteratee, keyBy, keys, keysIn, map, mapKeys, mapValues, matches, matchesProperty, memoize, merge, mergeWith, method, methodOf, mixin, negate, nthArg, omit, omitBy, once, orderBy, over, overArgs, overEvery, overSome, partial, partialRight, partition, pick, pickBy, plant, property, propertyOf, pull, pullAll, pullAllBy, pullAllWith, pullAt, push, range, rangeRight, rearg, reject, remove, rest, reverse, sampleSize, set, setWith, shuffle, slice, sort, sortBy, splice, spread, tail, take, takeRight, takeRightWhile, takeWhile, tap, throttle, thru, toArray, toPairs, toPairsIn, toPath, toPlainObject, transform, unary, union, unionBy, unionWith, uniq, uniqBy, uniqWith, unset, unshift, unzip, unzipWith, update, updateWith, values, valuesIn, without, wrap, xor, xorBy, xorWith, zip, zipObject, zipObjectDeep, and zipWithThe wrapper methods that are not chainable by default are:add, attempt, camelCase, capitalize, ceil, clamp, clone, cloneDeep, cloneDeepWith, cloneWith, conformsTo, deburr, defaultTo, divide, each, eachRight, endsWith, eq, escape, escapeRegExp, every, find, findIndex, findKey, findLast, findLastIndex, findLastKey, first, floor, forEach, forEachRight, forIn, forInRight, forOwn, forOwnRight, get, gt, gte, has, hasIn, head, identity, includes, indexOf, inRange, invoke, isArguments, isArray, isArrayBuffer, isArrayLike, isArrayLikeObject, isBoolean, isBuffer, isDate, isElement, isEmpty, isEqual, isEqualWith, isError, isFinite, isFunction, isInteger, isLength, isMap, isMatch, isMatchWith, isNaN, isNative, isNil, isNull, isNumber, isObject, isObjectLike, isPlainObject, isRegExp, isSafeInteger, isSet, isString, isUndefined, isTypedArray, isWeakMap, isWeakSet, join, kebabCase, last, lastIndexOf, lowerCase, lowerFirst, lt, lte, max, maxBy, mean, meanBy, min, minBy, multiply, noConflict, noop, now, nth, pad, padEnd, padStart, parseInt, pop, random, reduce, reduceRight, repeat, result, round, runInContext, sample, shift, size, snakeCase, some, sortedIndex, sortedIndexBy, sortedLastIndex, sortedLastIndexBy, startCase, startsWith, stubArray, stubFalse, stubObject, stubString, stubTrue, subtract, sum, sumBy, template, times, toFinite, toInteger, toJSON, toLength, toLower, toNumber, toSafeInteger, toString, toUpper, trim, trimEnd, trimStart, truncate, unescape, uniqueId, upperCase, upperFirst, value, and words", + "!type": "fn(value)" + }, + "chain": { + "!url": "https://lodash.com/docs/4.17.15#chain", + "!doc": "Creates a lodash wrapper instance that wraps value with explicit method chain sequences enabled. The result of such sequences must be unwrapped with _#value.", + "!type": "fn(value)" + }, + "tap": { + "!url": "https://lodash.com/docs/4.17.15#tap", + "!doc": "This method invokes interceptor and returns value. The interceptor is invoked with one argument; (value). The purpose of this method is to \"tap into\" a method chain sequence in order to modify intermediate results.", + "!type": "fn(value, interceptor)" + }, + "thru": { + "!url": "https://lodash.com/docs/4.17.15#thru", + "!doc": "This method is like _.tap except that it returns the result of interceptor. The purpose of this method is to \"pass thru\" values replacing intermediate results in a method chain sequence.", + "!type": "fn(value, interceptor)" + }, + "prototype[Symbol.iterator]": { + "!url": "https://lodash.com/docs/4.17.15#prototype-Symbol-iterator", + "!doc": "Enables the wrapper to be iterable.", + "!type": "fn()" + }, + "prototype.at": { + "!url": "https://lodash.com/docs/4.17.15#prototype-at", + "!doc": "This method is the wrapper version of _.at.", + "!type": "fn([paths])" + }, + "prototype.chain": { + "!url": "https://lodash.com/docs/4.17.15#prototype-chain", + "!doc": "Creates a lodash wrapper instance with explicit method chain sequences enabled.", + "!type": "fn()" + }, + "prototype.commit": { + "!url": "https://lodash.com/docs/4.17.15#prototype-commit", + "!doc": "Executes the chain sequence and returns the wrapped result.", + "!type": "fn()" + }, + "prototype.next": { + "!url": "https://lodash.com/docs/4.17.15#prototype-next", + "!doc": "Gets the next value on a wrapped object following the iterator protocol.", + "!type": "fn()" + }, + "prototype.plant": { + "!url": "https://lodash.com/docs/4.17.15#prototype-plant", + "!doc": "Creates a clone of the chain sequence planting value as the wrapped value.", + "!type": "fn(value)" + }, + "prototype.reverse": { + "!url": "https://lodash.com/docs/4.17.15#prototype-reverse", + "!doc": "This method is the wrapper version of _.reverse.Note: This method mutates the wrapped array.", + "!type": "fn()" + }, + "prototype.value": { + "!url": "https://lodash.com/docs/4.17.15#prototype-value", + "!doc": "Executes the chain sequence to resolve the unwrapped value.", + "!type": "fn()" + }, + "camelCase": { + "!url": "https://lodash.com/docs/4.17.15#camelCase", + "!doc": "Converts string to camel case.", + "!type": "fn([string])" + }, + "capitalize": { + "!url": "https://lodash.com/docs/4.17.15#capitalize", + "!doc": "Converts the first character of string to upper case and the remaining to lower case.", + "!type": "fn([string])" + }, + "deburr": { + "!url": "https://lodash.com/docs/4.17.15#deburr", + "!doc": "Deburrs string by converting Latin-1 Supplement and Latin Extended-A letters to basic Latin letters and removing combining diacritical marks.", + "!type": "fn([string])" + }, + "endsWith": { + "!url": "https://lodash.com/docs/4.17.15#endsWith", + "!doc": "Checks if string ends with the given target string.", + "!type": "fn([string], [target], [position])" + }, + "escape": { + "!url": "https://lodash.com/docs/4.17.15#escape", + "!doc": "Converts the characters \"&\", \"<\", \">\", '\"', and \"'\" in string to their corresponding HTML entities.Note: No other characters are escaped. To escape additional characters use a third-party library like he.Though the \">\" character is escaped for symmetry, characters like \">\" and \"/\" don't need escaping in HTML and have no special meaning unless they're part of a tag or unquoted attribute value. See Mathias Bynens's article (under \"semi-related fun fact\") for more details.When working with HTML you should always quote attribute values to reduce XSS vectors.", + "!type": "fn([string])" + }, + "escapeRegExp": { + "!url": "https://lodash.com/docs/4.17.15#escapeRegExp", + "!doc": "Escapes the RegExp special characters \"^\", \"$\", \"\", \".\", \"*\", \"+\", \"?\", \"(\", \")\", \"[\", \"]\", \"{\", \"}\", and \"|\" in string.", + "!type": "fn([string])" + }, + "kebabCase": { + "!url": "https://lodash.com/docs/4.17.15#kebabCase", + "!doc": "Converts string to kebab case.", + "!type": "fn([string])" + }, + "lowerCase": { + "!url": "https://lodash.com/docs/4.17.15#lowerCase", + "!doc": "Converts string, as space separated words, to lower case.", + "!type": "fn([string])" + }, + "lowerFirst": { + "!url": "https://lodash.com/docs/4.17.15#lowerFirst", + "!doc": "Converts the first character of string to lower case.", + "!type": "fn([string])" + }, + "pad": { + "!url": "https://lodash.com/docs/4.17.15#pad", + "!doc": "Pads string on the left and right sides if it's shorter than length. Padding characters are truncated if they can't be evenly divided by length.", + "!type": "fn([string], [length], [chars])" + }, + "padEnd": { + "!url": "https://lodash.com/docs/4.17.15#padEnd", + "!doc": "Pads string on the right side if it's shorter than length. Padding characters are truncated if they exceed length.", + "!type": "fn([string], [length], [chars])" + }, + "padStart": { + "!url": "https://lodash.com/docs/4.17.15#padStart", + "!doc": "Pads string on the left side if it's shorter than length. Padding characters are truncated if they exceed length.", + "!type": "fn([string], [length], [chars])" + }, + "parseInt": { + "!url": "https://lodash.com/docs/4.17.15#parseInt", + "!doc": "Converts string to an integer of the specified radix. If radix is undefined or 0, a radix of 10 is used unless value is a hexadecimal, in which case a radix of 16 is used.Note: This method aligns with the ES5 implementation of parseInt.", + "!type": "fn(string, [radix])" + }, + "repeat": { + "!url": "https://lodash.com/docs/4.17.15#repeat", + "!doc": "Repeats the given string n times.", + "!type": "fn([string], [n])" + }, + "replace": { + "!url": "https://lodash.com/docs/4.17.15#replace", + "!doc": "Replaces matches for pattern in string with replacement.Note: This method is based on String#replace.", + "!type": "fn([string], pattern, replacement)" + }, + "snakeCase": { + "!url": "https://lodash.com/docs/4.17.15#snakeCase", + "!doc": "Converts string to snake case.", + "!type": "fn([string])" + }, + "split": { + "!url": "https://lodash.com/docs/4.17.15#split", + "!doc": "Splits string by separator.Note: This method is based on String#split.", + "!type": "fn([string], separator, [limit])" + }, + "startCase": { + "!url": "https://lodash.com/docs/4.17.15#startCase", + "!doc": "Converts string to start case.", + "!type": "fn([string])" + }, + "startsWith": { + "!url": "https://lodash.com/docs/4.17.15#startsWith", + "!doc": "Checks if string starts with the given target string.", + "!type": "fn([string], [target], [position])" + }, + "template": { + "!url": "https://lodash.com/docs/4.17.15#template", + "!doc": "Creates a compiled template function that can interpolate data properties in \"interpolate\" delimiters, HTML-escape interpolated data properties in \"escape\" delimiters, and execute JavaScript in \"evaluate\" delimiters. Data properties may be accessed as free variables in the template. If a setting object is given, it takes precedence over _.templateSettings values.Note: In the development build _.template utilizes sourceURLs for easier debugging.For more information on precompiling templates see lodash's custom builds documentation.For more information on Chrome extension sandboxes see Chrome's extensions documentation.", + "!type": "fn([string], [options])" + }, + "toLower": { + "!url": "https://lodash.com/docs/4.17.15#toLower", + "!doc": "Converts string, as a whole, to lower case just like String#toLowerCase.", + "!type": "fn([string])" + }, + "toUpper": { + "!url": "https://lodash.com/docs/4.17.15#toUpper", + "!doc": "Converts string, as a whole, to upper case just like String#toUpperCase.", + "!type": "fn([string])" + }, + "trim": { + "!url": "https://lodash.com/docs/4.17.15#trim", + "!doc": "Removes leading and trailing whitespace or specified characters from string.", + "!type": "fn([string], [chars])" + }, + "trimEnd": { + "!url": "https://lodash.com/docs/4.17.15#trimEnd", + "!doc": "Removes trailing whitespace or specified characters from string.", + "!type": "fn([string], [chars])" + }, + "trimStart": { + "!url": "https://lodash.com/docs/4.17.15#trimStart", + "!doc": "Removes leading whitespace or specified characters from string.", + "!type": "fn([string], [chars])" + }, + "truncate": { + "!url": "https://lodash.com/docs/4.17.15#truncate", + "!doc": "Truncates string if it's longer than the given maximum string length. The last characters of the truncated string are replaced with the omission string which defaults to \"...\".", + "!type": "fn([string], [options])" + }, + "unescape": { + "!url": "https://lodash.com/docs/4.17.15#unescape", + "!doc": "The inverse of _.escape; this method converts the HTML entities &, <, >, ", and ' in string to their corresponding characters.Note: No other HTML entities are unescaped. To unescape additional HTML entities use a third-party library like he.", + "!type": "fn([string])" + }, + "upperCase": { + "!url": "https://lodash.com/docs/4.17.15#upperCase", + "!doc": "Converts string, as space separated words, to upper case.", + "!type": "fn([string])" + }, + "upperFirst": { + "!url": "https://lodash.com/docs/4.17.15#upperFirst", + "!doc": "Converts the first character of string to upper case.", + "!type": "fn([string])" + }, + "words": { + "!url": "https://lodash.com/docs/4.17.15#words", + "!doc": "Splits string into an array of its words.", + "!type": "fn([string], [pattern])" + }, + "attempt": { + "!url": "https://lodash.com/docs/4.17.15#attempt", + "!doc": "Attempts to invoke func, returning either the result or the caught error object. Any additional arguments are provided to func when it's invoked.", + "!type": "fn(func, [args])" + }, + "bindAll": { + "!url": "https://lodash.com/docs/4.17.15#bindAll", + "!doc": "Binds methods of an object to the object itself, overwriting the existing method.Note: This method doesn't set the \"length\" property of bound functions.", + "!type": "fn(object, methodNames)" + }, + "cond": { + "!url": "https://lodash.com/docs/4.17.15#cond", + "!doc": "Creates a function that iterates over pairs and invokes the corresponding function of the first predicate to return truthy. The predicate-function pairs are invoked with the this binding and arguments of the created function.", + "!type": "fn(pairs)" + }, + "conforms": { + "!url": "https://lodash.com/docs/4.17.15#conforms", + "!doc": "Creates a function that invokes the predicate properties of source with the corresponding property values of a given object, returning true if all predicates return truthy, else false.Note: The created function is equivalent to _.conformsTo with source partially applied.", + "!type": "fn(source)" + }, + "constant": { + "!url": "https://lodash.com/docs/4.17.15#constant", + "!doc": "Creates a function that returns value.", + "!type": "fn(value)" + }, + "defaultTo": { + "!url": "https://lodash.com/docs/4.17.15#defaultTo", + "!doc": "Checks value to determine whether a default value should be returned in its place. The defaultValue is returned if value is NaN, null, or undefined.", + "!type": "fn(value, defaultValue)" + }, + "flow": { + "!url": "https://lodash.com/docs/4.17.15#flow", + "!doc": "Creates a function that returns the result of invoking the given functions with the this binding of the created function, where each successive invocation is supplied the return value of the previous.", + "!type": "fn([funcs])" + }, + "flowRight": { + "!url": "https://lodash.com/docs/4.17.15#flowRight", + "!doc": "This method is like _.flow except that it creates a function that invokes the given functions from right to left.", + "!type": "fn([funcs])" + }, + "identity": { + "!url": "https://lodash.com/docs/4.17.15#identity", + "!doc": "This method returns the first argument it receives.", + "!type": "fn(value)" + }, + "iteratee": { + "!url": "https://lodash.com/docs/4.17.15#iteratee", + "!doc": "Creates a function that invokes func with the arguments of the created function. If func is a property name, the created function returns the property value for a given element. If func is an array or object, the created function returns true for elements that contain the equivalent source properties, otherwise it returns false.", + "!type": "fn([func])" + }, + "matches": { + "!url": "https://lodash.com/docs/4.17.15#matches", + "!doc": "Creates a function that performs a partial deep comparison between a given object and source, returning true if the given object has equivalent property values, else false.Note: The created function is equivalent to _.isMatch with source partially applied.Partial comparisons will match empty array and empty object source values against any array or object value, respectively. See _.isEqual for a list of supported value comparisons.", + "!type": "fn(source)" + }, + "matchesProperty": { + "!url": "https://lodash.com/docs/4.17.15#matchesProperty", + "!doc": "Creates a function that performs a partial deep comparison between the value at path of a given object to srcValue, returning true if the object value is equivalent, else false.Note: Partial comparisons will match empty array and empty object srcValue values against any array or object value, respectively. See _.isEqual for a list of supported value comparisons.", + "!type": "fn(path, srcValue)" + }, + "method": { + "!url": "https://lodash.com/docs/4.17.15#method", + "!doc": "Creates a function that invokes the method at path of a given object. Any additional arguments are provided to the invoked method.", + "!type": "fn(path, [args])" + }, + "methodOf": { + "!url": "https://lodash.com/docs/4.17.15#methodOf", + "!doc": "The opposite of _.method; this method creates a function that invokes the method at a given path of object. Any additional arguments are provided to the invoked method.", + "!type": "fn(object, [args])" + }, + "mixin": { + "!url": "https://lodash.com/docs/4.17.15#mixin", + "!doc": "Adds all own enumerable string keyed function properties of a source object to the destination object. If object is a function, then methods are added to its prototype as well.Note: Use _.runInContext to create a pristine lodash function to avoid conflicts caused by modifying the original.", + "!type": "fn([object], source, [options])" + }, + "noConflict": { + "!url": "https://lodash.com/docs/4.17.15#noConflict", + "!doc": "Reverts the _ variable to its previous value and returns a reference to the lodash function.", + "!type": "fn()" + }, + "noop": { + "!url": "https://lodash.com/docs/4.17.15#noop", + "!doc": "This method returns undefined.", + "!type": "fn()" + }, + "nthArg": { + "!url": "https://lodash.com/docs/4.17.15#nthArg", + "!doc": "Creates a function that gets the argument at index n. If n is negative, the nth argument from the end is returned.", + "!type": "fn([n])" + }, + "over": { + "!url": "https://lodash.com/docs/4.17.15#over", + "!doc": "Creates a function that invokes iteratees with the arguments it receives and returns their results.", + "!type": "fn([iteratees])" + }, + "overEvery": { + "!url": "https://lodash.com/docs/4.17.15#overEvery", + "!doc": "Creates a function that checks if all of the predicates return truthy when invoked with the arguments it receives.", + "!type": "fn([predicates])" + }, + "overSome": { + "!url": "https://lodash.com/docs/4.17.15#overSome", + "!doc": "Creates a function that checks if any of the predicates return truthy when invoked with the arguments it receives.", + "!type": "fn([predicates])" + }, + "property": { + "!url": "https://lodash.com/docs/4.17.15#property", + "!doc": "Creates a function that returns the value at path of a given object.", + "!type": "fn(path)" + }, + "propertyOf": { + "!url": "https://lodash.com/docs/4.17.15#propertyOf", + "!doc": "The opposite of _.property; this method creates a function that returns the value at a given path of object.", + "!type": "fn(object)" + }, + "range": { + "!url": "https://lodash.com/docs/4.17.15#range", + "!doc": "Creates an array of numbers (positive and/or negative) progressing from start up to, but not including, end. A step of -1 is used if a negative start is specified without an end or step. If end is not specified, it's set to start with start then set to 0.Note: JavaScript follows the IEEE-754 standard for resolving floating-point values which can produce unexpected results.", + "!type": "fn([start], end, [step])" + }, + "rangeRight": { + "!url": "https://lodash.com/docs/4.17.15#rangeRight", + "!doc": "This method is like _.range except that it populates values in descending order.", + "!type": "fn([start], end, [step])" + }, + "runInContext": { + "!url": "https://lodash.com/docs/4.17.15#runInContext", + "!doc": "Create a new pristine lodash function using the context object.", + "!type": "fn([context])" + }, + "stubArray": { + "!url": "https://lodash.com/docs/4.17.15#stubArray", + "!doc": "This method returns a new empty array.", + "!type": "fn()" + }, + "stubFalse": { + "!url": "https://lodash.com/docs/4.17.15#stubFalse", + "!doc": "This method returns false.", + "!type": "fn()" + }, + "stubObject": { + "!url": "https://lodash.com/docs/4.17.15#stubObject", + "!doc": "This method returns a new empty object.", + "!type": "fn()" + }, + "stubString": { + "!url": "https://lodash.com/docs/4.17.15#stubString", + "!doc": "This method returns an empty string.", + "!type": "fn()" + }, + "stubTrue": { + "!url": "https://lodash.com/docs/4.17.15#stubTrue", + "!doc": "This method returns true.", + "!type": "fn()" + }, + "times": { + "!url": "https://lodash.com/docs/4.17.15#times", + "!doc": "Invokes the iteratee n times, returning an array of the results of each invocation. The iteratee is invoked with one argument; (index).", + "!type": "fn(n, [iteratee])" + }, + "toPath": { + "!url": "https://lodash.com/docs/4.17.15#toPath", + "!doc": "Converts value to a property path array.", + "!type": "fn(value)" + }, + "uniqueId": { + "!url": "https://lodash.com/docs/4.17.15#uniqueId", + "!doc": "Generates a unique ID. If prefix is given, the ID is appended to it.", + "!type": "fn([prefix])" + }, + "": { + "!url": "https://lodash.com/docs/4.17.15#templateSettings-imports-_", + "!doc": "A reference to the lodash function.", + "!type": "fn_.templateSettings.imports._" + } + } +} diff --git a/app/taro/src/constants/defs/moment.json b/app/taro/src/constants/defs/moment.json new file mode 100644 index 0000000000..de5060af9c --- /dev/null +++ b/app/taro/src/constants/defs/moment.json @@ -0,0 +1,730 @@ +{ + "!name": "LIB/moment", + "moment": { + "!type": "fn(inp?: MomentInput, format?: MomentFormatSpecification, strict?: boolean) -> Moment", + "!url": "https://momentjs.com/docs/#/parsing/", + "!doc": "Returns a wrapper for the Date object", + "now": { + "!type": "fn() -> number", + "!doc": "Returns unix time in milliseconds." + }, + "version": { + "!type": "string" + }, + "invalid": { + "!type": "fn(flags?: MomentParsingFlagsOpt) -> Moment", + "!url": "https://momentjs.com/docs/#/utilities/invalid/", + "!doc": "Create your own invalid Moment objects" + }, + "isMoment": { + "!type": "fn(m: any) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-a-moment/", + "!doc": "To check if a variable is a moment object" + }, + "isDate": { + "!type": "fn(m: any) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-a-date/", + "!doc": "To check if a variable is a native js Date object" + }, + "isDuration": { + "!type": "fn(m: any) -> bool", + "!url": "https://momentjs.com/docs/#/durations/is-a-duration/", + "!doc": "To check if a variable is a moment duration object" + }, + "locale": { + "!type": "fn(language?: string, definition?: LocaleSpecification|void) -> string", + "!url": "https://momentjs.com/docs/#/i18n/changing-locale/", + "!doc": "To load a locale, pass the key and the string values to moment.locale" + }, + "localeData": { + "!type": "fn(key?: string|[string]) -> Locale", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns the current locale or a locale with the given key" + }, + "duration": { + "!type": "fn(inp?: DurationInputArg1, unit?: DurationInputArg2) -> Duration", + "!url": "https://momentjs.com/docs/#/durations/creating/", + "!doc": "To create a duration, call moment.duration() with the length of time in milliseconds" + }, + "parseZone": { + "!type": "fn(inp?: MomentInput, format?: MomentFormatSpecification, language?: string, strict?: boolean) -> Moment" + }, + "months": { + "!type": "fn(format: string, index: number) -> string", + "!url": "https://momentjs.com/docs/#/get-set/month/", + "!doc": "Gets or sets the month." + }, + "monthsShort": { + "!type": "fn(format?: string, index?: number) -> string|[string]", + "!url": "https://momentjs.com/docs/#/customization/month-abbreviations/", + "!doc": "Returns abbreviated month names" + }, + "weekdays": { + "!type": "fn(localeSorted?: bool, format?: string, index?: number) -> string|[string]", + "!url": "https://momentjs.com/docs/#/customization/weekday-names/" + }, + "weekdaysShort": { + "!type": "fn(localeSorted?: bool, format?: string, index?: number) -> string|[string]", + "!url": "https://momentjs.com/docs/#/customization/weekday-abbreviations/", + "!doc": "Returns abbreviated weekday names" + }, + "weekdaysMin": { + "!type": "fn(localeSorted?: bool, format?: string, index?: number) -> string|[string]", + "!url": "https://momentjs.com/docs/#/customization/weekday-abbreviations/", + "!doc": "Returns abbreviated weekday names" + }, + "min": { + "!type": "fn(moments: [Moment]) -> Moment", + "!url": "https://momentjs.com/docs/#/get-set/min/", + "!doc": "Returns the minimum (most distant past) of the given moment instances" + }, + "max": { + "!type": "fn(moments: [Moment]) -> Moment", + "!url": "https://momentjs.com/docs/#/get-set/max/", + "!doc": "Returns the maximum (most distant future) of the given moment instances" + }, + "defineLocale": { + "!type": "fn(language: string, localeSpec: LocaleSpecification|void) -> Locale", + "!url": "https://momentjs.com/docs/#/customization/", + "!doc": "Create a locale that inherits from a parent locale" + }, + "updateLocale": { + "!type": "fn(language: string, localeSpec: LocaleSpecification|void) -> Locale", + "!url": "https://momentjs.com/docs/#/customization/", + "!doc": "Update a locale's properties" + }, + "locales": { + "!type": "fn() -> [string]", + "!url": "https://momentjs.com/docs/#/i18n/getting-locale/", + "!doc": "List all locales that have been loaded and are available to use" + }, + "normalizeUnits": { + "!type": "fn(unit: ?) -> string", + "!url": "https://momentjs.com/docs/#/utilities/normalize-units/", + "!doc": "If you're extending the library, you may want access to Moment's facilities for that in order to better align your functionality with Moment's" + }, + "relativeTimeThreshold": { + "!type": "fn(threshold: string) -> number|bool", + "!url": "https://momentjs.com/docs/#/customization/relative-time-threshold/" + }, + "calendarFormat": { + "!type": "fn(m: Moment, now: Moment) -> string", + "!url": "https://momentjs.com/docs/#/customization/calendar-format/", + "!doc": "Lets you modify the tokens used by calendar" + }, + "parseTwoDigitYear": { + "!type": "fn(input: string) -> number", + "!url": "https://momentjs.com/docs/#/parsing/string-format/" + } + }, + "Moment": { + "startOf": { + "!type": "fn(unitOfTime: ?) -> Moment", + "!url": "https://momentjs.com/docs/#/manipulating/start-of/", + "!doc": "Mutates the original moment by setting it to the start of a unit of time" + }, + "endOf": { + "!type": "fn(unitOfTime: ?) -> Moment", + "!url": "https://momentjs.com/docs/#/manipulating/end-of/", + "!doc": "Mutates the original moment by setting it to the end of a unit of time" + }, + "isValid": { + "!type": "fn() -> bool", + "!url": "https://momentjs.com/docs/#/parsing/is-valid/", + "!doc": "Check whether the Moment considers the date invalid" + }, + "invalidAt": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/parsing/is-valid/", + "!doc": "Returns which date unit overflowed" + }, + "hasAlignedHourOffset": { + "!type": "fn(other?: MomentInput) -> boolean" + }, + "creationData": { + "!type": "fn() -> MomentCreationData", + "!url": "https://momentjs.com/docs/#/parsing/creation-data/", + "!doc": "After a moment object is created, all of the inputs can be accessed with creationData() method" + }, + "parsingFlags": { + "!type": "fn() -> MomentParsingFlags", + "!url": "https://momentjs.com/docs/#/parsing/is-valid/", + "!doc": "You can check the metrics used by #isValid using moment#parsingFlags, which returns an object" + }, + "add": { + "!type": "fn(amount?: DurationInputArg1, unit?: DurationInputArg2) -> Moment", + "!url": "https://momentjs.com/docs/#/manipulating/add/", + "!doc": "Mutates the original moment by adding time." + }, + "subtract": { + "!type": "fn(amount?: DurationInputArg1, unit?: DurationInputArg2) -> Moment", + "!url": "https://momentjs.com/docs/#/manipulating/subtract/", + "!doc": "Mutates the original moment by subtracting time" + }, + "calender": { + "!type": "fn(fntime?: MomentInput, formats?: CalendarSpec) -> string", + "!url": "https://momentjs.com/docs/#/displaying/calendar-time/", + "!doc": "Calendar time displays time relative to a given referenceDay (defaults to the start of today)" + }, + "valueOf": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/displaying/unix-timestamp-milliseconds/", + "!doc": "Unix timestamp in milliseconds" + }, + "local": { + "!type": "fn(keepLocalTime?: boolean) -> Moment", + "!doc": "Current date/time in local mode" + }, + "isLocal": { + "!type": "fn() -> bool" + }, + "utc": { + "!type": "fn(keepLocalTime?: boolean) -> Moment", + "!url": "https://momentjs.com/docs/#/manipulating/utc/", + "!doc": "Current date/time in UTC mode" + }, + "isUTC": { + "!type": "fn() -> bool" + }, + "parseZone": { + "!type": "fn() -> Moment" + }, + "format": { + "!type": "fn(format?: string) -> string", + "!url": "https://momentjs.com/docs/#/displaying/format/", + "!doc": "Takes a string of tokens and replaces them with their corresponding values" + }, + "isAfter": { + "!type": "fn(inp?: MomentInput, granularity?: ?) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-after/", + "!doc": "Check if a moment is after another moment." + }, + "isSame": { + "!type": "fn(inp?: MomentInput, granularity?: ?) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-same/", + "!doc": "Check if a moment is the same as another moment." + }, + "isBefore": { + "!type": "fn(inp?: MomentInput, granularity?: ?) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-before/", + "!doc": "Check if a moment is before another moment" + }, + "fromNow": { + "!type": "fn(withoutSuffix?: bool) -> string", + "!url": "https://momentjs.com/docs/#/displaying/fromnow/", + "!doc": "Get relative time" + }, + "from": { + "!type": "fn(inp: MomentInput, suffix?: boolean) -> string", + "!url": "https://momentjs.com/docs/#/displaying/from/", + "!doc": "Returns a moment in relation to a time other than now" + }, + "to": { + "!type": "fn(inp: MomentInput, suffix?: boolean) -> string", + "!url": "https://momentjs.com/docs/#/displaying/to/", + "!doc": "Display a moment in relation to a time other than now" + }, + "toNow": { + "!type": "fn(withoutPrefix?: boolean) -> string", + "!url": "https://momentjs.com/docs/#/displaying/tonow/", + "!doc": "Display relative time" + }, + "diff": { + "!type": "fn(b: MomentInput, unitOfTime?: unitOfTime.Diff, precise?: boolean) -> number", + "!url": "https://momentjs.com/docs/#/displaying/difference/", + "!doc": "Get the difference in milliseconds" + }, + "toArray": { + "!type": "fn() -> [number]", + "!url": "https://momentjs.com/docs/#/displaying/as-array/", + "!doc": "Returns an array that mirrors the parameters from new Date()" + }, + "clone": { + "!type": "fn() -> Moment", + "!url": "https://momentjs.com/docs/#/parsing/moment-clone/", + "!doc": "Returns the clone of a moment," + }, + "year": { + "!type": "fn(y: number) -> Moment", + "!url": "https://momentjs.com/docs/#/get-set/year/", + "!doc": "Gets or sets the year" + }, + "quarter": { + "!type": "fn() -> number|fn(q: number) -> Moment", + "!url": "https://momentjs.com/docs/#/get-set/quarter/", + "!doc": "Gets or sets the quarter" + }, + "quarters": { + "!type": "fn() -> number|fn(q: number) -> Moment", + "!url": "https://momentjs.com/docs/#/get-set/quarter/", + "!doc": "Gets or sets the quarter" + }, + "month": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/get-set/month/", + "!doc": "Gets or sets the month" + }, + "day": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/get-set/day/", + "!doc": "Gets or sets the day of the week." + }, + "days": { + "!type": "fn(d?: number|string) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/day/" + }, + "date": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/get-set/date/", + "!doc": "Gets or sets the day of the month." + }, + "hour": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/get-set/hour/", + "!doc": "Gets or sets the hour." + }, + "hours": { + "!type": "fn(h?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/hour/", + "!doc": "Gets or sets the hour." + }, + "minute": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/get-set/minute/", + "!doc": "Gets or sets the minutes." + }, + "minutes": { + "!type": "fn(m?: number) -> Moment|number", + "!url": "https://momentjs.com/docs/#/get-set/minute/", + "!doc": "Gets or sets the minutes." + }, + "second": { + "!type": "fn([s])", + "!url": "https://momentjs.com/docs/#/get-set/second/", + "!doc": "Gets or sets the seconds." + }, + "seconds": { + "!type": "fn([s])", + "!url": "https://momentjs.com/docs/#/get-set/second/", + "!doc": "Gets or sets the seconds." + }, + "millisecond": { + "!type": "fn([ms])", + "!url": "https://momentjs.com/docs/#/get-set/millisecond/", + "!doc": "Gets or sets the milliseconds." + }, + "milliseconds": { + "!type": "fn([ms])", + "!url": "https://momentjs.com/docs/#/get-set/millisecond/", + "!doc": "Gets or sets the milliseconds." + }, + "weekday": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/weekday/", + "!doc": "Gets or sets the day of the week according to the locale" + }, + "isoWeekday": { + "!type": "fn(d?: number|string) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/iso-weekday/", + "!doc": "Gets or sets the ISO day of the week with 1 being Monday and 7 being Sunday" + }, + "weekYear": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/week-year/", + "!doc": "Gets or sets the week-year according to the locale" + }, + "isoWeekYear": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/iso-week-year/", + "!doc": "Gets or sets the ISO week-year" + }, + "week": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/week/", + "!doc": "Gets or sets the week of the year" + }, + "weeks": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/week/", + "!doc": "Gets or sets the week of the year" + }, + "isoWeek": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/iso-week/", + "!doc": "Gets or sets the ISO week of the year" + }, + "isoWeeks": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/iso-week/", + "!doc": "Gets or sets the ISO week of the year" + }, + "weeksInYear": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/get-set/weeks-in-year/", + "!doc": "Gets the number of weeks according to locale in the current moment's year" + }, + "weeksInWeekYear": { + "!type": "fn() -> number" + }, + "isoWeeksInYear": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/get-set/iso-weeks-in-year/", + "!doc": "Gets the number of weeks in the current moment's year, according to ISO weeks" + }, + "isoWeeksInISOWeekYear": { + "!type": "fn() -> number" + }, + "dayOfYear": { + "!type": "fn(d?: number) -> number|Moment", + "!url": "https://momentjs.com/docs/#/get-set/day-of-year/", + "!doc": "Gets or sets the day of the year" + }, + "get": { + "!type": "fn(unit: ?) -> number", + "!url": "https://momentjs.com/docs/#/get-set/get/", + "!doc": "String getter" + }, + "set": { + "!type": "fn(unit: ?, value: number) -> Moment", + "!url": "https://momentjs.com/docs/#/get-set/set/", + "!doc": "Generic setter, accepting unit as first argument, and value as second" + }, + "toDate": { + "!type": "fn()", + "!url": "https://momentjs.com/docs/#/displaying/as-javascript-date/", + "!doc": "Get a copy of the native Date object that Moment.js wraps" + }, + "toISOString": { + "!type": "fn(keepOffset?: boolean) -> string", + "!url": "https://momentjs.com/docs/#/displaying/as-iso-string/", + "!doc": "Formats a string to the ISO8601 standard" + }, + "inspect": { + "!type": "fn() -> string", + "!url": "https://momentjs.com/docs/#/displaying/inspect/", + "!doc": "Returns a machine readable string, that can be evaluated to produce the same moment" + }, + "toJSON": { + "!type": "fn() -> string", + "!url": "https://momentjs.com/docs/#/displaying/as-json/", + "!doc": "When serializing an object to JSON, if there is a Moment object, it will be represented as an ISO8601 string, adjusted to UTC" + }, + "unix": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/displaying/unix-timestamp/", + "!doc": "Outputs a Unix timestamp (the number of seconds since the Unix Epoch)" + }, + "isLeapYear": { + "!type": "fn() -> bool", + "!url": "https://momentjs.com/docs/#/query/is-leap-year/", + "!doc": "Returns true if that year is a leap year, and false if it is not" + }, + "zone": { + "!type": "fn(b: number|string) -> Moment", + "!url": "https://momentjs.com/docs/#/manipulating/timezone-offset/", + "!doc": "Get the time zone offset in minutes" + }, + "utcOffset": { + "!type": "fn(b?: number|string, keepLocalTime?: boolean) -> Moment", + "!url": "https://momentjs.com/docs/#/manipulating/utc-offset/", + "!doc": "Get or set the UTC offset in minutes" + }, + "isUtcOffset": { + "!type": "fn() -> boolean" + }, + "daysInMonth": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/displaying/days-in-month/", + "!doc": "Get the number of days in the current month" + }, + "isDST": { + "!type": "fn() -> boolean", + "!url": "https://momentjs.com/docs/#/query/is-daylight-saving-time/", + "!doc": "Get the number of days in the current month" + }, + "zoneAbbr": { + "!type": "fn() -> string" + }, + "zoneName": { + "!type": "fn() -> string" + }, + "isSameOrAfter": { + "!type": "fn(inp?: MomentInput, granularity?: ?) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-same-or-after/", + "!doc": "Check if a moment is after or the same as another moment" + }, + "isSameOrBefore": { + "!type": "fn(inp?: MomentInput, granularity?: ?) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-same-or-before/", + "!doc": "Check if a moment is before or the same as another moment" + }, + "isBetween": { + "!type": "fn(a: MomentInput, b: MomentInput, granularity?: ?, inclusivity?: ?) -> bool", + "!url": "https://momentjs.com/docs/#/query/is-between/", + "!doc": "Check if a moment is between two other moments," + }, + "locale": { + "!type": "fn(locale: LocaleSpecifier) -> string|Moment", + "!url": "https://momentjs.com/docs/#/i18n/instance-locale/", + "!doc": "A global locale configuration can be problematic when passing around moments that may need to be formatted into different locale" + }, + "localeData": { + "!type": "fn() -> Locale" + }, + "toObject": { + "!type": "fn() -> MomentObjectOutput", + "!url": "https://momentjs.com/docs/#/displaying/as-object/", + "!doc": "Returns an object containing year, month, day-of-month, hour, minute, seconds, milliseconds" + } + }, + "Duration": { + "clone": { + "!type": "fn() -> Duration", + "!url": "https://momentjs.com/docs/#/durations/clone/", + "!doc": "Create a clone of a duration" + }, + "humanize": { + "!type": "fn(argWithSuffix?: boolean, argThresholds?: argThresholdOpts) -> string", + "!url": "https://momentjs.com/docs/#/durations/humanize/" + }, + "abs": { + "!type": "fn() -> Duration" + }, + "as": { + "!type": "fn(units: ?) -> number", + "!url": "https://momentjs.com/docs/#/durations/as/" + }, + "get": { + "!type": "fn(units: ?) -> number", + "!url": "https://momentjs.com/docs/#/durations/get/", + "!doc": "Alternate to Duration#x() getters" + }, + "milliseconds": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/milliseconds/", + "!doc": "Get the number of milliseconds in a duration" + }, + "asMilliseconds": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/milliseconds/", + "!doc": "Get the length of the duration in milliseconds" + }, + "seconds": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/seconds/", + "!doc": "Get the number of seconds in a duration" + }, + "asSeconds": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/seconds/", + "!doc": "Get the length of the duration in seconds" + }, + "minutes": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/minutes/", + "!doc": "Gets the minutes (0 - 59)" + }, + "asMinutes": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/minutes/", + "!doc": "Gets the length of the duration in minutes" + }, + "hours": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/hours/", + "!doc": "Gets the hours (0 - 23)" + }, + "asHours": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/hours/", + "!doc": "Gets the length of the duration in hours" + }, + "days": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/days/", + "!doc": "Gets the days (0 - 30)" + }, + "asDays": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/days/", + "!doc": "Gets the length of the duration in days" + }, + "weeks": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/weeks/", + "!doc": "Gets the weeks (0 - 4)" + }, + "asWeeks": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/weeks/", + "!doc": "Gets the length of the duration in weeks" + }, + "months": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/months/", + "!doc": "Gets the months (0 - 11)." + }, + "asMonths": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/months/", + "!doc": "Gets the length of the duration in months" + }, + "years": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/years/", + "!doc": "Gets the years" + }, + "asYears": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/durations/years/", + "!doc": "Gets the length of the duration in years" + }, + "add": { + "!type": "fn(inp?: DurationInputArg1, unit?: DurationInputArg2) -> Duration", + "!url": "https://momentjs.com/docs/#/durations/add/", + "!doc": "Mutates the original duration by adding time" + }, + "subtract": { + "!type": "fn(inp?: DurationInputArg1, unit?: DurationInputArg2) -> Duration", + "!url": "https://momentjs.com/docs/#/durations/subtract/", + "!doc": "Mutates the original duration by subtracting time" + }, + "locale": { + "!type": "fn(locale: LocaleSpecifier) -> Duration", + "!url": "https://momentjs.com/docs/#/durations/locale/", + "!doc": "Get or set the locale of a duration" + }, + "localeData": { + "!type": "fn() -> Locale" + }, + "toISOString": { + "!type": "fn() -> string", + "!url": "https://momentjs.com/docs/#/durations/as-iso-string/", + "!doc": "Returns duration in string as specified by ISO 8601 standard" + }, + "toJSON": { + "!type": "fn() -> string", + "!url": "https://momentjs.com/docs/#/durations/as-json/", + "!doc": "When serializing a duration object to JSON, it will be represented as an ISO8601 string" + }, + "isValid": { + "!type": "fn() -> boolean" + } + }, + "Locale": { + "calendar": { + "!type": "fn(key?: CalendarKey, m?: Moment, now?: Moment) -> string", + "!url": "https://momentjs.com/docs/#/customization/calendar/" + }, + "longDateFormat": { + "!type": "fn(key: LongDateFormatKey) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns the full format of abbreviated date-time formats LT, L, LL and so on" + }, + "invalidDate": { + "!type": "fn() -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns a translation of 'Invalid date'" + }, + "ordinal": { + "!type": "fn(n: number) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Convert number to ordinal string 1 -> 1st" + }, + "preparse": { + "!type": "fn(inp: string) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Called before parsing on every input string" + }, + "postformat": { + "!type": "fn(inp: string) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Called after formatting on every string" + }, + "relativeTime": { + "!type": "fn(n: number, withoutSuffix: boolean, key: RelativeTimeKey, isFuture: boolean) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns relative time string, key is on of 's', 'm', 'mm', 'h', 'hh', 'd', 'dd', 'M', 'MM', 'y', 'yy'" + }, + "pastFuture": { + "!type": "fn(diff: number, absRelTime: string) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Convert relTime string to past or future string depending on diff" + }, + "set": { + "!type": "fn(config: Object) -> void", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Convert relTime string to past or future string depending on diff" + }, + "months": { + "!type": "fn(m?: Moment, format?: string) -> string|[string]", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Full month name of m" + }, + "monthsShort": { + "!type": "fn(m?: Moment, format?: string) -> string|[string]", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Short month name of m" + }, + "monthsParse": { + "!type": "fn(monthName: string, format: string, strict: bool) -> number", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns month id (0 to 11) of input" + }, + "monthsRegex": { + "!type": "fn(strict: bool) -> RegExp" + }, + "monthsShortRegex": { + "!type": "fn(strict: boolean) -> RegExp" + }, + "week": { + "!type": "fn(m: Moment) -> number", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "returns week-of-year of m" + }, + "firstDayOfYear": { + "!type": "fn() -> number", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "0-15 Used to determine first week of the year" + }, + "weekdays": { + "!type": "fn(m: Moment, format?: string) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Full weekday name of m" + }, + "weekdaysMin": { + "!type": "fn(m: Moment, format?: string) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "min weekday name of m" + }, + "weekdaysShort": { + "!type": "fn(m: Moment) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Short weekday name of m" + }, + "weekdaysParse": { + "!type": "fn(weekdayName: string, format: string, strict: boolean) -> number", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns weekday id (0 to 6) of input" + }, + "weekdaysRegex": { + "!type": "fn(strict: bool) -> RegExp" + }, + "weekdaysShortRegex": { + "!type": "fn(strict: bool) -> RegExp" + }, + "weekdaysMinRegex": { + "!type": "fn(strict: bool) -> RegExp" + }, + "isPM": { + "!type": "fn(input: string) -> bool", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns true if input represents PM" + }, + "meridiem": { + "!type": "fn(hour: number, minute: number, isLower: bool) -> string", + "!url": "https://momentjs.com/docs/#/i18n/locale-data/", + "!doc": "Returns am/pm string for particular time-of-day in upper/lower case" + } + } +} diff --git a/app/taro/src/constants/defs/xmlParser.json b/app/taro/src/constants/defs/xmlParser.json new file mode 100644 index 0000000000..ffbb2ec298 --- /dev/null +++ b/app/taro/src/constants/defs/xmlParser.json @@ -0,0 +1,13 @@ +{ + "!name": "LIB/xmlParser", + "xmlParser": { + "parse": { + "!doc": "converts xml string to json object", + "!type": "fn(xml: string, options?: object) -> object" + }, + "validate": { + "!doc": "validate xml data", + "!type": "fn(xml: string) -> bool" + } + } +} diff --git a/app/taro/src/constants/editorConstants.tsx b/app/taro/src/constants/editorConstants.tsx new file mode 100644 index 0000000000..3762df9faf --- /dev/null +++ b/app/taro/src/constants/editorConstants.tsx @@ -0,0 +1,8 @@ +export type OccupiedSpace = { + left: number; + right: number; + top: number; + bottom: number; + id: string; + parentId?: string; +}; diff --git a/app/taro/src/constants/forms.ts b/app/taro/src/constants/forms.ts new file mode 100644 index 0000000000..b0cf78ede6 --- /dev/null +++ b/app/taro/src/constants/forms.ts @@ -0,0 +1,24 @@ +export const API_EDITOR_FORM_NAME = "ApiEditorForm"; +export const CREATE_APPLICATION_FORM_NAME = "CreateApplicationForm"; +export const INVITE_USERS_TO_ORG_FORM = "InviteUsersToOrgForm"; +export const LOGIN_FORM_NAME = "LoginForm"; + +export const LOGIN_FORM_EMAIL_FIELD_NAME = "username"; +export const LOGIN_FORM_PASSWORD_FIELD_NAME = "password"; + +export const SIGNUP_FORM_NAME = "SignupForm"; +export const SIGNUP_FORM_EMAIL_FIELD_NAME = "email"; +export const FORGOT_PASSWORD_FORM_NAME = "ForgotPasswordForm"; +export const RESET_PASSWORD_FORM_NAME = "ResetPasswordForm"; +export const CREATE_PASSWORD_FORM_NAME = "CreatePasswordForm"; + +export const CREATE_ORGANIZATION_FORM_NAME = "创建应用组"; +export const CURL_IMPORT_FORM = "CurlImportForm"; + +export const QUERY_EDITOR_FORM_NAME = "QueryEditorForm"; +export const API_HOME_SCREEN_FORM = "APIHomeScreenForm"; +export const SAAS_EDITOR_FORM = "SaaSEditorForm"; + +export const DATASOURCE_DB_FORM = "DatasourceDBForm"; +export const DATASOURCE_REST_API_FORM = "DatasourceRestAPIForm"; +export const DATASOURCE_SAAS_FORM = "DatasourceSaaSForm"; diff --git a/app/taro/src/constants/messages.test.ts b/app/taro/src/constants/messages.test.ts new file mode 100644 index 0000000000..f06d1941c0 --- /dev/null +++ b/app/taro/src/constants/messages.test.ts @@ -0,0 +1,9 @@ +import { ERROR_WIDGET_COPY_NOT_ALLOWED } from "./messages"; + +describe("messages", () => { + it("checks for ERROR_WIDGET_COPY_NOT_ALLOWED string", () => { + expect(ERROR_WIDGET_COPY_NOT_ALLOWED()).toBe( + "This selected widget cannot be copied.", + ); + }); +}); diff --git a/app/taro/src/constants/messages.ts b/app/taro/src/constants/messages.ts new file mode 100644 index 0000000000..11d6c2cb70 --- /dev/null +++ b/app/taro/src/constants/messages.ts @@ -0,0 +1,397 @@ +export function createMessage( + format: (...strArgs: any[]) => string, + ...args: any[] +) { + return format(...args); +} + +/* eslint-disable */ +export const ERROR_MESSAGE_SELECT_ACTION = () => `请选择一个动作`; +export const ERROR_MESSAGE_SELECT_ACTION_TYPE = () => + `请选择一个动作类型`; +export const ACTION_CREATED_SUCCESS = (actionName: string) => + `${actionName} 动作创建成功`; +export const ERROR_ADD_API_INVALID_URL = () => + `无法创建API,请在数据源中添加URL`; +export const ERROR_MESSAGE_NAME_EMPTY = () => `名字不能为空`; +export const ERROR_MESSAGE_CREATE_APPLICATION = () => + `应用创建失败`; +export const APPLICATION_NAME_UPDATE = () => `应用名更新成功`; +export const ERROR_EMPTY_APPLICATION_NAME = () => + `应用名不能为空`; +export const API_PATH_START_WITH_SLASH_ERROR = () => `路径不能用 / 开头`; +export const FIELD_REQUIRED_ERROR = () => `必填`; +export const VALID_FUNCTION_NAME_ERROR = () => + `函数名必须符合命名规则(驼峰式)`; +export const UNIQUE_NAME_ERROR = () => `名字必须是独一无二的`; +export const NAME_SPACE_ERROR = () => `名字不能包含空白符`; + +export const FORM_VALIDATION_EMPTY_EMAIL = () => `请输入邮箱`; +export const FORM_VALIDATION_INVALID_EMAIL = () => + `请提供一个有效的邮箱`; +export const ENTER_VIDEO_URL = () => `请提供一个有效的URL`; + +export const FORM_VALIDATION_EMPTY_PASSWORD = () => `请输入密码`; +export const FORM_VALIDATION_PASSWORD_RULE = () => + `密码应该不少于6位`; +export const FORM_VALIDATION_INVALID_PASSWORD = FORM_VALIDATION_PASSWORD_RULE; + +export const LOGIN_PAGE_SUBTITLE = () => `使用你所属应用组的邮箱`; +export const LOGIN_PAGE_TITLE = () => `欢迎回来`; +export const LOGIN_PAGE_EMAIL_INPUT_LABEL = () => `邮箱`; +export const LOGIN_PAGE_PASSWORD_INPUT_LABEL = () => `密码`; +export const LOGIN_PAGE_EMAIL_INPUT_PLACEHOLDER = () => `请输入你的邮箱`; +export const LOGIN_PAGE_PASSWORD_INPUT_PLACEHOLDER = () => `请输入至少6位密码`; +export const LOGIN_PAGE_INVALID_CREDS_ERROR = () => + `密码输入错误😂 如果忘记了密码你可以`; +export const LOGIN_PAGE_INVALID_CREDS_FORGOT_PASSWORD_LINK = () => + `重置密码`; +export const NEW_TO_APPSMITH = () => `萌新还没有账号?`; + +export const LOGIN_PAGE_LOGIN_BUTTON_TEXT = () => `登录`; +export const LOGIN_PAGE_FORGOT_PASSWORD_TEXT = () => `忘记密码`; +export const LOGIN_PAGE_REMEMBER_ME_LABEL = () => `记住我`; +export const LOGIN_PAGE_SIGN_UP_LINK_TEXT = () => `注册`; +export const SIGNUP_PAGE_TITLE = () => `注册账号`; +export const SIGNUP_PAGE_SUBTITLE = () => `你的应用组邮箱`; +export const SIGNUP_PAGE_EMAIL_INPUT_LABEL = () => `邮箱`; +export const SIGNUP_PAGE_EMAIL_INPUT_PLACEHOLDER = () => `请输入你的邮箱`; +export const SIGNUP_PAGE_NAME_INPUT_PLACEHOLDER = () => `用户名`; +export const SIGNUP_PAGE_NAME_INPUT_LABEL = () => `用户名`; +export const SIGNUP_PAGE_PASSWORD_INPUT_LABEL = () => `密码`; +export const SIGNUP_PAGE_PASSWORD_INPUT_PLACEHOLDER = () => `请输入至少6位密码`; +export const SIGNUP_PAGE_LOGIN_LINK_TEXT = () => `登录`; +export const SIGNUP_PAGE_NAME_INPUT_SUBTEXT = () => `请问如何称呼?`; +export const SIGNUP_PAGE_SUBMIT_BUTTON_TEXT = () => `注册`; +export const ALREADY_HAVE_AN_ACCOUNT = () => `已经有账号了吗?`; + +export const SIGNUP_PAGE_SUCCESS = () => + `太棒了!注册成功!✨✨✨`; +export const SIGNUP_PAGE_SUCCESS_LOGIN_BUTTON_TEXT = () => `登录`; + +export const RESET_PASSWORD_PAGE_PASSWORD_INPUT_LABEL = () => `新密码`; +export const RESET_PASSWORD_PAGE_PASSWORD_INPUT_PLACEHOLDER = () => + `请输入至少6位密码`; +export const RESET_PASSWORD_LOGIN_LINK_TEXT = () => `去登录`; +export const RESET_PASSWORD_PAGE_TITLE = () => `重置密码`; +export const RESET_PASSWORD_SUBMIT_BUTTON_TEXT = () => `重置`; +export const RESET_PASSWORD_PAGE_SUBTITLE = () => + `这回不要再忘记了哦😁,不过忘记了也没关系,你可以随时过来重置👌`; + +export const RESET_PASSWORD_RESET_SUCCESS = () => + `密码重置成功`; //`Your password has been reset. Please login` (see next entry)); +export const RESET_PASSWORD_RESET_SUCCESS_LOGIN_LINK = () => `登录`; + +export const RESET_PASSWORD_EXPIRED_TOKEN = () => + `密码重置链接已经过期了,请再次申请重置吧。`; +export const RESET_PASSWORD_INVALID_TOKEN = () => + `密码重置链接已经失效了,请再次申请重置吧。`; +export const RESET_PASSWORD_FORGOT_PASSWORD_LINK = () => `忘记密码`; + +export const FORGOT_PASSWORD_PAGE_EMAIL_INPUT_LABEL = () => `邮箱`; +export const FORGOT_PASSWORD_PAGE_EMAIL_INPUT_PLACEHOLDER = () => `请输入你的邮箱`; +export const FORGOT_PASSWORD_PAGE_TITLE = () => `重置密码`; +export const FORGOT_PASSWORD_PAGE_SUBTITLE = () => + `我们将会往这个邮箱发送一封重置密码的邮件`; +export const FORGOT_PASSWORD_PAGE_SUBMIT_BUTTON_TEXT = () => `重置`; +export const FORGOT_PASSWORD_SUCCESS_TEXT = () => + `重置密码的邮件已经发送成功了,快去看看吧`; + +export const PRIVACY_POLICY_LINK = () => `隐私政策`; +export const TERMS_AND_CONDITIONS_LINK = () => `服务条款`; + +export const ERROR_500 = () => + `很抱歉,系统出错了的😱,请相信我们会很快解决这个问题的`; +export const ERROR_0 = () => + `无法连接到服务器,请检查你的网络连接`; +export const ERROR_401 = () => + `我们无法校验你的登录信息,请重新登录吧`; +export const ERROR_403 = () => + `无权访问。请联系你的管理员给你添加访问权限`; +export const URL_HTTP_VALIDATION_ERROR = () => `请输入有效的URL`; +export const NAVIGATE_TO_VALIDATION_ERROR = () => + `请输入有效的地址或者域名`; +export const PAGE_NOT_FOUND_ERROR = () => + `你想访问的页面不存在`; +export const INVALID_URL_ERROR = () => `无效URL`; + +export const INVITE_USERS_VALIDATION_EMAIL_LIST = () => + `存在无效的邮箱地址`; +export const INVITE_USERS_VALIDATION_ROLE_EMPTY = () => `请选择角色`; + +export const INVITE_USERS_EMAIL_LIST_PLACEHOLDER = () => + `逗号分隔的邮箱地址`; +export const INVITE_USERS_ROLE_SELECT_PLACEHOLDER = () => `选择角色`; +export const INVITE_USERS_ROLE_SELECT_LABEL = () => `角色`; +export const INVITE_USERS_EMAIL_LIST_LABEL = () => `用户邮箱`; +export const INVITE_USERS_ADD_EMAIL_LIST_FIELD = () => `添加更多`; +export const INVITE_USERS_SUBMIT_BUTTON_TEXT = () => `邀请小伙伴`; +export const INVITE_USERS_SUBMIT_ERROR = () => + `无法邀请小伙伴,请稍后重试`; +export const INVITE_USERS_SUBMIT_SUCCESS = () => + `成功向小伙伴们发出了邀请`; +export const INVITE_USER_SUBMIT_SUCCESS = () => + `成功向小伙伴发出了邀请`; +export const INVITE_USERS_VALIDATION_EMAILS_EMPTY = () => + `请告诉我们小伙伴们的邮箱吧`; + +export const CREATE_PASSWORD_PAGE_PASSWORD_INPUT_LABEL = () => `新密码`; +export const CREATE_PASSWORD_PAGE_PASSWORD_INPUT_PLACEHOLDER = () => + `新密码`; +export const CREATE_PASSWORD_LOGIN_LINK_TEXT = () => + `知道密码了吗?马上登录`; +export const CREATE_PASSWORD_PAGE_TITLE = () => `设置密码`; +export const CREATE_PASSWORD_SUBMIT_BUTTON_TEXT = () => `创建`; +export const CREATE_PASSWORD_PAGE_SUBTITLE = () => + `设置新密码`; + +export const CREATE_PASSWORD_RESET_SUCCESS = () => `密码设置成功`; +export const CREATE_PASSWORD_RESET_SUCCESS_LOGIN_LINK = () => `登录`; + +export const CREATE_PASSWORD_EXPIRED_TOKEN = () => + `邀请链接已经过期了,请重新邀请吧`; +export const CREATE_PASSWORD_INVALID_TOKEN = () => + `邀请链接已经失效了,请重新邀请吧`; + +export const DELETING_APPLICATION = () => `正在删除应用...`; +export const DUPLICATING_APPLICATION = () => `正在复制应用...`; + +export const CURL_IMPORT_SUCCESS = () => `Curl 命令导入成功`; +export const FORGOT_PASSWORD_PAGE_LOGIN_LINK = () => `登录`; +export const ADD_API_TO_PAGE_SUCCESS_MESSAGE = (actionName: string) => + `${actionName} API 添加成功`; +export const INPUT_WIDGET_DEFAULT_VALIDATION_ERROR = () => `无效输入`; + +export const AUTOFIT_ALL_COLUMNS = () => `自动调整所有列`; +export const AUTOFIT_THIS_COLUMN = () => `自动调整本列`; +export const AUTOFIT_COLUMN = () => `自动调整列`; + +export const DATE_WIDGET_DEFAULT_VALIDATION_ERROR = () => "日期超出范围"; + +export const TIMEZONE = () => `时区`; +export const ENABLE_TIME = () => `启用时间`; + +export const EDIT_APP = () => `编辑`; +export const FORK_APP = () => `复制`; +export const SIGN_IN = () => `登录`; + +export const LIGHTNING_MENU_DATA_API = () => `使用接口数据`; +export const LIGHTNING_MENU_DATA_QUERY = () => `使用数据库数据`; +export const LIGHTNING_MENU_DATA_TOOLTIP = () => `快速数据绑定`; +export const LIGHTNING_MENU_DATA_WIDGET = () => `使用组件数据`; +export const LIGHTNING_MENU_QUERY_CREATE_NEW = () => `新建查询`; +export const LIGHTNING_MENU_API_CREATE_NEW = () => `新建接口`; + +export const LIGHTNING_MENU_OPTION_TEXT = () => `纯文本`; +export const LIGHTNING_MENU_OPTION_JS = () => `写 JS`; +export const LIGHTNING_MENU_OPTION_HTML = () => `写 HTML`; +export const CHECK_REQUEST_BODY = () => `需要检查请求体吗?`; +export const DONT_SHOW_THIS_AGAIN = () => `不再展示`; +export const SHOW_REQUEST = () => `展示请求`; + +export const TABLE_FILTER_COLUMN_TYPE_CALLOUT = () => + `请修改列数据类型`; + +export const WIDGET_SIDEBAR_TITLE = () => `组件`; +export const WIDGET_SIDEBAR_CAPTION = () => + `将组件拖动到右侧画布`; +export const GOOGLE_RECAPTCHA_KEY_ERROR = () => + `谷歌鉴权 Token 生成失败!请检查 Re-captcha 站点里的键值`; +export const GOOGLE_RECAPTCHA_DOMAIN_ERROR = () => + `谷歌鉴权 Token 生成失败!请检查允许的域名`; + +export const SERVER_API_TIMEOUT_ERROR = () => + `服务器响应超时!请稍后重试`; +export const DEFAULT_ERROR_MESSAGE = () => `出现了意外的错误`; +export const REMOVE_FILE_TOOL_TIP = () => "删除上传"; +export const ERROR_FILE_TOO_LARGE = (fileSize: string) => + `文件最大支持 ${fileSize}!`; +export const ERROR_DATEPICKER_MIN_DATE = () => + `最小日期不能超过当前设置的日期`; +export const ERROR_DATEPICKER_MAX_DATE = () => + `最大日期不能超过当前设置的日期`; +export const ERROR_WIDGET_DOWNLOAD = (err: string) => `下载失败。 ${err}`; +export const ERROR_API_EXECUTE = (actionName: string) => + `${actionName} 运行失败😢,请检查它的配置是否正确`; +export const ERROR_FAIL_ON_PAGE_LOAD_ACTIONS = () => + `在页面加载的过程中,动作运行失败了😢`; +export const ERROR_ACTION_EXECUTE_FAIL = (actionName: string) => + `${actionName} 动作执行失败`; +export const ACTION_DELETE_SUCCESS = (actionName: string) => + `${actionName} 动作删除成功`; +export const ACTION_MOVE_SUCCESS = (actionName: string, pageName: string) => + `${actionName} 动作成功移动到页面 ${pageName}`; +export const ERROR_ACTION_MOVE_FAIL = (actionName: string) => + `移动动作 ${actionName} 失败😢`; +export const ACTION_COPY_SUCCESS = (actionName: string, pageName: string) => + `${actionName} 动作成功复制到页面 ${pageName}`; +export const ERROR_ACTION_COPY_FAIL = (actionName: string) => + `复制动作 ${actionName} 失败😢`; +export const ERROR_ACTION_RENAME_FAIL = (actionName: string) => + `重命名动作 ${actionName} 失败😢`; + +export const DATASOURCE_CREATE = (dsName: string) => + `${dsName} 数据源创建成功`; +export const DATASOURCE_DELETE = (dsName: string) => + `${dsName} 数据源删除成功`; +export const DATASOURCE_UPDATE = (dsName: string) => + `${dsName} 数据源更新成功`; +export const DATASOURCE_VALID = (dsName: string) => + `${dsName} 数据源校验成功`; + +export const ERROR_EVAL_ERROR_GENERIC = () => + `解析应用的时候出现了意外的错误`; + +export const ERROR_EVAL_TRIGGER = (message: string) => + `解析应用触发器的时候出现了错误: ${message}`; + +export const WIDGET_DELETE = (widgetName: string) => + `${widgetName} 组件删除成功`; +export const WIDGET_BULK_DELETE = (widgetName: string) => + `${widgetName} 组件批量删除成功`; +export const WIDGET_COPY = (widgetName: string) => `成功复制 ${widgetName}`; +export const ERROR_WIDGET_COPY_NO_WIDGET_SELECTED = () => + `请选择要复制的组件`; +export const ERROR_WIDGET_COPY_NOT_ALLOWED = () => + `无法复制选中的组件`; +export const WIDGET_CUT = (widgetName: string) => `剪切 ${widgetName}`; +export const ERROR_WIDGET_CUT_NO_WIDGET_SELECTED = () => + `请选择要剪切的组件`; +export const SELECT_ALL_WIDGETS_MSG = () => + `已经全部选中页面上的所有组件(包括弹窗)`; +export const ERROR_ADD_WIDGET_FROM_QUERY = () => `添加组件失败`; + +export const REST_API_AUTHORIZATION_SUCCESSFUL = () => + "鉴权成功"; +export const REST_API_AUTHORIZATION_FAILED = () => + "鉴权失败😢,请仔细检查你的信息或者重试"; +// Todo: improve this for appsmith_error error message +export const REST_API_AUTHORIZATION_APPSMITH_ERROR = () => + "好像出现了一些内部错误,不过请放心,我们已经收集了现场情况"; + +export const SAAS_AUTHORIZATION_SUCCESSFUL = "鉴权成功!"; +export const SAAS_AUTHORIZATION_FAILED = + "鉴权失败😢,请仔细检查你的信息或者重试"; +// Todo: improve this for appsmith_error error message +export const SAAS_AUTHORIZATION_APPSMITH_ERROR = "好像出现了一些内部错误,不过请放心,我们已经收集了现场情况"; +export const SAAS_APPSMITH_TOKEN_NOT_FOUND = "没有找到系统token"; + +export const LOCAL_STORAGE_QUOTA_EXCEEDED_MESSAGE = () => + "本地存储失败😢,本地存储大小已经超过了浏览器的最大限制"; +export const LOCAL_STORAGE_NO_SPACE_LEFT_ON_DEVICE_MESSAGE = () => + "本地存储失败😢,磁盘空间不足"; +export const LOCAL_STORAGE_NOT_SUPPORTED_APP_MIGHT_NOT_WORK_AS_EXPECTED = () => + "你的设备不支持本地存储,系统依赖本地存储的一些功能无法生效"; + +export const OMNIBAR_PLACEHOLDER = () => + "搜索组件、数据、文档等"; +export const HELPBAR_PLACEHOLDER = () => "快速搜索导航"; +export const NO_SEARCH_DATA_TEXT = () => "暂无搜索结果"; + +export const WIDGET_BIND_HELP = () => + "不清楚如何进行数据绑定吗?"; + +export const BACK_TO_HOMEPAGE = () => "回到主页"; + +export const PAGE_NOT_FOUND = () => "找不到页面"; + +export const RESOLVE = () => "解决"; +export const UNRESOLVE = () => "未解决"; + +// comments +export const ADD_COMMENT_PLACEHOLDER = () => "添加评论,你可以用@去提醒他人"; +export const PIN_COMMENT = () => "固定评论"; +export const UNPIN_COMMENT = () => "取消固定评论"; +export const COPY_LINK = () => "复制链接"; +export const DELETE_COMMENT = () => "删除评论"; +export const DELETE_THREAD = () => "删除话题"; +export const EDIT_COMMENT = () => "编辑评论"; +export const COMMENTS = () => "所有评论"; +export const VIEW_LATEST = () => "只看最新"; +export const POST = () => "提交"; +export const CANCEL = () => "取消"; +export const NO_COMMENTS_CLICK_ON_CANVAS_TO_ADD = () => + `暂无评论 \n 点击画布任意地方 \n开始交流`; +export const LINK_COPIED_SUCCESSFULLY = () => "链接已经复制到粘贴板"; +export const FULL_NAME = () => "全名"; +export const DISPLAY_NAME = () => "昵称"; +export const EMAIL_ADDRESS = () => "邮箱地址"; +export const FIRST_AND_LAST_NAME = () => "姓名"; +export const MARK_ALL_AS_READ = () => "全部标记已读"; +export const INVITE_A_NEW_USER = () => "邀请一个新伙伴"; +export const REMOVE = () => "删除"; +export const NO_NOTIFICATIONS_TO_SHOW = () => "暂无通知"; +export const UNREAD_MESSAGE = () => "未读消息"; +export const UNSUBSCRIBE_EMAIL_SUCCESS = () => + "话题退订成功"; +export const UNSUBSCRIBE_EMAIL_MSG_1 = () => + "系统不会再向你发送话题邮件"; +export const UNSUBSCRIBE_EMAIL_MSG_2 = () => + "如果有人在讨论中标记了你,或者你回复了评论,系统会自动为你订阅话题"; +export const UNSUBSCRIBE_EMAIL_CONFIRM_MSG = () => + "确定取消订阅吗?"; +export const UNSUBSCRIBE_BUTTON_LABEL = () => "取消订阅"; + +// Showcase Carousel +export const NEXT = () => "下一个"; +export const BACK = () => "返回"; +export const SKIP = () => "跳过"; + +// Debugger +export const CLICK_ON = () => "👉 点击 "; +export const PRESS = () => "🎉 点击 "; +export const OPEN_THE_DEBUGGER = () => " 打开调试器"; +export const NO_LOGS = () => "💌 暂无日志"; +export const NO_ERRORS = () => "🌈 一切顺利!"; +export const DEBUGGER_ERRORS = () => "错误"; +export const DEBUGGER_LOGS = () => "日志"; +export const INSPECT_ENTITY = () => "检查实体"; +export const INSPECT_ENTITY_BLANK_STATE = () => "选择一个要检查的实体"; +export const ACTION_CONFIGURATION_UPDATED = () => "配置已更新"; +export const WIDGET_PROPERTIES_UPDATED = () => "组件属性已更新"; +export const EMPTY_RESPONSE_FIRST_HALF = () => "👉 点击"; +export const EMPTY_RESPONSE_LAST_HALF = () => "获取响应"; +export const INVALID_EMAIL = () => "请输入有效的邮箱"; + +export const TROUBLESHOOT_ISSUE = () => "答疑解惑"; + +// Import/Export Application features +export const IMPORT_APPLICATION_MODAL_TITLE = () => "导入应用"; + +export const DELETE_CONFIRMATION_MODAL_TITLE = () => `请再次确认`; +export const DELETE_CONFIRMATION_MODAL_SUBTITLE = (name?: string | null) => + `确定将 ${name} 移出应用组吗?`; + +// Generate page from DB Messages + +export const UNSUPPORTED_PLUGIN_DIALOG_TITLE = () => + `这个数据源不支持自动生成页面`; + +export const UNSUPPORTED_PLUGIN_DIALOG_SUBTITLE = () => + `你可以继续拖拽组件来设计你的应用`; +export const UNSUPPORTED_PLUGIN_DIALOG_MAIN_HEADING = () => `请注意`; + +export const BUILD_FROM_SCRATCH_ACTION_SUBTITLE = () => + "通过拖拉拽来创造你的应用"; + +export const BUILD_FROM_SCRATCH_ACTION_TITLE = () => "空白页面"; + +export const GENERATE_PAGE_ACTION_TITLE = () => "自动生成页面"; + +export const GENERATE_PAGE_ACTION_SUBTITLE = () => + "通过数据表自动生成增删改查页面"; + +export const GENERATE_PAGE_FORM_TITLE = () => "数据直接生成页面"; +// Actions Right pane +export const SEE_CONNECTED_ENTITIES = () => "显示所有已连接的实体"; +export const INCOMING_ENTITIES = () => "输入实体"; +export const NO_INCOMING_ENTITIES = () => "暂无输入实体"; +export const OUTGOING_ENTITIES = () => "输出实体"; +export const NO_OUTGOING_ENTITIES = () => "暂无输出实体"; +export const NO_CONNECTIONS = () => "暂无连接"; +export const BACK_TO_CANVAS = () => "回到画布"; +export const SUGGESTED_WIDGET_DESCRIPTION = () => + "添加新组件到画布"; +export const ADD_NEW_WIDGET = () => "添加新组件"; +export const SUGGESTED_WIDGETS = () => "推荐组件"; +export const SUGGESTED_WIDGET_TOOLTIP = () => "添加到画布"; diff --git a/app/taro/src/constants/orgConstants.ts b/app/taro/src/constants/orgConstants.ts new file mode 100644 index 0000000000..93402a4662 --- /dev/null +++ b/app/taro/src/constants/orgConstants.ts @@ -0,0 +1,31 @@ +import { ApplicationPayload } from "./ReduxActionConstants"; + +export type OrgRole = { + id: string; + name: string; + displayName?: string; + isDefault?: boolean; +}; + +export type Org = { + id: string; + name: string; + website?: string; + email?: string; + logoUrl?: string; + uploadProgress?: number; + userPermissions?: string[]; +}; + +export type OrgUser = { + username: string; + name: string; + roleName: string; + isDeleting: boolean; + isChangingRole: boolean; +}; + +export type Organization = { + applications: ApplicationPayload[]; + organization: Org; +}; diff --git a/app/taro/src/constants/providerConstants.ts b/app/taro/src/constants/providerConstants.ts new file mode 100644 index 0000000000..35dcf167a4 --- /dev/null +++ b/app/taro/src/constants/providerConstants.ts @@ -0,0 +1,98 @@ +import { ApiResponse } from "api/ApiResponses"; + +export type ProvidersDataArray = ApiResponse & { + id: string; + name: string; + description: string; + url: string; + imageUrl: string; +}; + +export type ProvidersCategoriesResponse = ApiResponse & { + data: string[]; +}; + +export type FetchProviderDetailsResponse = ApiResponse & { + data: ProvidersDataArray; +}; + +export type Providers = ApiResponse & { + providers: ProvidersDataArray[]; + total: number; +}; + +export type ProviderTemplates = ApiResponse & { + data: Array; + length: number; + templateId: string; +}; + +export type ApiTemplates = { + id: string; + deleted: boolean; + name: string; + providerId: string; + publisher: string; + packageName: string; + versionId: string; + apiTemplateConfiguration: { + documentation: string; + sampleResponse: { + body: string; + }; + }; + actionConfiguration: { + timeoutInMillisecond: number; + paginationType: string; + path: string; + httpMethod: string; + headers: any[]; + routeParameters: any[]; + }; + datasourceConfiguration: { + url: string; + }; +}; + +export type ProviderTemplateArray = ApiResponse & { + templateData: { + id: string; + deleted: boolean; + name: string; + providerId: string; + publisher: string; + packageName: string; + versionId: string; + apiTemplateConfiguration: { + documentation: string; + sampleResponse: { + body: string; + }; + }; + actionConfiguration: { + timeoutInMillisecond: number; + paginationType: string; + path: string; + httpMethod: string; + headers: any[]; + routeParameters: any[]; + }; + datasourceConfiguration: { + url: string; + }; + }; + isOpen: boolean; + addToPageStatus: boolean; + addToPageLoading: boolean; +}; + +export type SearchResultsProviders = { + id: string; + name: string; + description: string; + imageUrl: string; + url: string; + documentationUrl: string; +}; + +export const DEFAULT_TEMPLATE_TYPE = "TEMPLATE"; diff --git a/app/taro/src/constants/routes.ts b/app/taro/src/constants/routes.ts new file mode 100644 index 0000000000..74d3f470ba --- /dev/null +++ b/app/taro/src/constants/routes.ts @@ -0,0 +1,236 @@ +const { match } = require("path-to-regexp"); + +export const BASE_URL = "/"; +export const ORG_URL = "/org"; +export const PAGE_NOT_FOUND_URL = "/404"; +export const SERVER_ERROR_URL = "/500"; +export const APPLICATIONS_URL = `/applications`; +export const BUILDER_URL = "/applications/:applicationId/pages/:pageId/edit"; +export const USER_AUTH_URL = "/user"; +export const PROFILE = "/profile"; +export const USERS_URL = "/users"; +export const VIEWER_URL_REGEX = /applications\/.*?\/pages\/.*/; +export const UNSUBSCRIBE_EMAIL_URL = "/unsubscribe/discussion/:threadId"; + +export type BuilderRouteParams = { + applicationId: string; + pageId: string; +}; + +export type AppViewerRouteParams = { + applicationId?: string; + pageId?: string; +}; + +export type APIEditorRouteParams = { + applicationId: string; + pageId: string; + apiId?: string; +}; + +export type ProviderViewerRouteParams = { + applicationId: string; + pageId: string; + providerId: string; +}; + +export type QueryEditorRouteParams = { + applicationId: string; + pageId: string; + queryId: string; +}; + +export const BUILDER_BASE_URL = (applicationId = ":applicationId"): string => + `/applications/${applicationId}`; + +export const BUILDER_PAGE_URL = ( + applicationId?: string, + pageId?: string, + params?: Record, +): string => { + if (!pageId) return APPLICATIONS_URL; + const queryString = convertToQueryParams(params); + return ( + `${BUILDER_BASE_URL(applicationId)}/pages/${pageId}/edit` + queryString + ); +}; + +export const API_EDITOR_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", +): string => `${BUILDER_PAGE_URL(applicationId, pageId)}/api`; + +export const PAGE_LIST_EDITOR_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", +): string => `${BUILDER_PAGE_URL(applicationId, pageId)}/pages`; + +export const DATA_SOURCES_EDITOR_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", +): string => `${BUILDER_PAGE_URL(applicationId, pageId)}/datasource`; + +export const DATA_SOURCES_EDITOR_ID_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", + datasourceId = ":datasourceId", + params = {}, +): string => { + const queryString = convertToQueryParams(params); + return `${DATA_SOURCES_EDITOR_URL( + applicationId, + pageId, + )}/${datasourceId}${queryString}`; +}; + +export const QUERIES_EDITOR_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", +): string => `${BUILDER_PAGE_URL(applicationId, pageId)}/queries`; + +export const INTEGRATION_TABS = { + ACTIVE: "ACTIVE", + NEW: "NEW", +}; + +export const INTEGRATION_EDITOR_MODES = { + AUTO: "auto", + MOCK: "mock", +}; +export const INTEGRATION_EDITOR_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", + selectedTab = ":selectedTab", + mode = "", + params = {}, +): string => { + const queryString = convertToQueryParams(params); + return `${BUILDER_PAGE_URL( + applicationId, + pageId, + )}/datasources/${selectedTab}${ + mode ? "?mode=" + mode + "&" + queryString.replace("?", "") : queryString + }`; +}; + +export const QUERIES_EDITOR_ID_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", + queryId = ":queryId", + params = {}, +): string => { + const queryString = convertToQueryParams(params); + return `${QUERIES_EDITOR_URL( + applicationId, + pageId, + )}/${queryId}${queryString}`; +}; + +export const API_EDITOR_ID_URL = ( + applicationId = ":applicationId", + pageId = ":pageId", + apiId = ":apiId", + params = {}, +): string => { + const queryString = convertToQueryParams(params); + return `${API_EDITOR_URL(applicationId, pageId)}/${apiId}${queryString}`; +}; + +export const API_EDITOR_URL_WITH_SELECTED_PAGE_ID = ( + applicationId = ":applicationId", + pageId = ":pageId", + selectedPageId = ":importTo", +): string => { + return `${BUILDER_PAGE_URL( + applicationId, + pageId, + )}/api?importTo=${selectedPageId}`; +}; + +export const APP_VIEW_URL = `/applications/:applicationId`; + +export const getApplicationViewerURL = ( + applicationId = ":applicationId", +): string => `/applications/${applicationId}`; + +export const getApplicationViewerPageURL = ( + applicationId = ":applicationId", + pageId = ":pageId", + params: Record = {}, +): string => { + const url = `/applications/${applicationId}/pages/${pageId}`; + const queryString = convertToQueryParams(params); + return url + queryString; +}; + +export function convertToQueryParams( + params: Record = {}, +): string { + const paramKeys = Object.keys(params); + const queryParams: string[] = []; + if (paramKeys) { + paramKeys.forEach((paramKey: string) => { + const value = params[paramKey]; + if (paramKey && value) { + queryParams.push(`${paramKey}=${value}`); + } + }); + } + return queryParams.length ? "?" + queryParams.join("&") : ""; +} + +export const getCurlImportPageURL = ( + applicationId = ":applicationId", + pageId = ":pageId", +): string => `${API_EDITOR_URL(applicationId, pageId)}/curl/curl-import`; + +export const getProviderTemplatesURL = ( + applicationId = ":applicationId", + pageId = ":pageId", + providerId = ":providerId", +): string => `${API_EDITOR_URL(applicationId, pageId)}/provider/${providerId}`; + +export const QUERY_EDITOR_URL_WITH_SELECTED_PAGE_ID = ( + applicationId = ":applicationId", + pageId = ":pageId", + selectedPageId = ":importTo", +): string => { + return `${BUILDER_PAGE_URL( + applicationId, + pageId, + )}/queries?importTo=${selectedPageId}`; +}; + +export const GEN_TEMPLATE_URL = "/generate-page"; +export const GEN_TEMPLATE_FORM_ROUTE = "/form"; + +export const getGenerateTemplateURL = ( + applicationId = ":applicationId", + pageId = ":pageId", +): string => `${BUILDER_PAGE_URL(applicationId, pageId)}${GEN_TEMPLATE_URL}`; + +export const getGenerateTemplateFormURL = ( + applicationId = ":applicationId", + pageId = ":pageId", +): string => + `${BUILDER_PAGE_URL( + applicationId, + pageId, + )}${GEN_TEMPLATE_URL}${GEN_TEMPLATE_FORM_ROUTE}`; + +export const FORGOT_PASSWORD_URL = `${USER_AUTH_URL}/forgotPassword`; +export const RESET_PASSWORD_URL = `${USER_AUTH_URL}/resetPassword`; +export const BASE_SIGNUP_URL = `/signup`; +export const SIGN_UP_URL = `${USER_AUTH_URL}/signup`; +export const BASE_LOGIN_URL = `/login`; +export const AUTH_LOGIN_URL = `${USER_AUTH_URL}/login`; +export const SIGNUP_SUCCESS_URL = `/signup-success`; + +export const ORG_INVITE_USERS_PAGE_URL = `${ORG_URL}/invite`; +export const ORG_SETTINGS_PAGE_URL = `${ORG_URL}/settings`; + +export const matchApiPath = match(API_EDITOR_ID_URL()); +export const matchDatasourcePath = match(DATA_SOURCES_EDITOR_ID_URL()); +export const matchQueryPath = match(QUERIES_EDITOR_ID_URL()); +export const matchBuilderPath = match(BUILDER_URL); +export const matchViewerPath = match(getApplicationViewerPageURL()); diff --git a/app/taro/src/constants/userConstants.ts b/app/taro/src/constants/userConstants.ts new file mode 100644 index 0000000000..d66e873a9c --- /dev/null +++ b/app/taro/src/constants/userConstants.ts @@ -0,0 +1,37 @@ +export const ANONYMOUS_USERNAME = "anonymousUser"; + +type Gender = "MALE" | "FEMALE"; + +export type User = { + email: string; + currentOrganizationId: string; + organizationIds: string[]; + applications: UserApplication[]; + username: string; + name: string; + gender: Gender; + anonymousId: string; +}; + +export interface UserApplication { + id: string; + name: string; +} + +export const CurrentUserDetailsRequestPayload = { + id: "profile", +}; + +export const DefaultCurrentUserDetails: User = { + name: ANONYMOUS_USERNAME, + email: ANONYMOUS_USERNAME, + currentOrganizationId: "", + organizationIds: [], + username: ANONYMOUS_USERNAME, + applications: [], + gender: "MALE", + anonymousId: "anonymousId", +}; + +// TODO keeping it here instead of the USER_API since it leads to cyclic deps errors during tests +export const USER_PHOTO_URL = "v1/users/photo"; diff --git a/app/taro/src/entities/Action/actionProperties.ts b/app/taro/src/entities/Action/actionProperties.ts new file mode 100644 index 0000000000..cbda958366 --- /dev/null +++ b/app/taro/src/entities/Action/actionProperties.ts @@ -0,0 +1,74 @@ +import { Action } from "entities/Action/index"; +import _ from "lodash"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import { isHidden } from "components/formControls/utils"; + +const dynamicFields = ["QUERY_DYNAMIC_TEXT", "QUERY_DYNAMIC_INPUT_TEXT"]; + +const getCorrectEvaluationSubstitutionType = (substitutionType?: string) => { + if (substitutionType) { + if (substitutionType === EvaluationSubstitutionType.SMART_SUBSTITUTE) { + return EvaluationSubstitutionType.SMART_SUBSTITUTE; + } else if (substitutionType === EvaluationSubstitutionType.PARAMETER) { + return EvaluationSubstitutionType.PARAMETER; + } + } + return EvaluationSubstitutionType.TEMPLATE; +}; + +export const getBindingPathsOfAction = ( + action: Action, + formConfig?: any[], +): Record => { + const bindingPaths: Record = { + data: EvaluationSubstitutionType.TEMPLATE, + isLoading: EvaluationSubstitutionType.TEMPLATE, + }; + if (!formConfig) { + return { + ...bindingPaths, + config: EvaluationSubstitutionType.TEMPLATE, + }; + } + const recursiveFindBindingPaths = (formConfig: any) => { + if (formConfig.children) { + formConfig.children.forEach(recursiveFindBindingPaths); + } else { + const configPath = getDataTreeActionConfigPath(formConfig.configProperty); + if (dynamicFields.includes(formConfig.controlType)) { + if (!isHidden(action, formConfig.hidden)) { + bindingPaths[configPath] = getCorrectEvaluationSubstitutionType( + formConfig.evaluationSubstitutionType, + ); + } + } + if (formConfig.controlType === "ARRAY_FIELD") { + const actionValue = _.get(action, formConfig.configProperty); + if (Array.isArray(actionValue)) { + for (let i = 0; i < actionValue.length; i++) { + formConfig.schema.forEach((schemaField: any) => { + if ( + schemaField.key in actionValue[i] && + dynamicFields.includes(schemaField.controlType) + ) { + const arrayConfigPath = `${configPath}[${i}].${schemaField.key}`; + bindingPaths[ + arrayConfigPath + ] = getCorrectEvaluationSubstitutionType( + formConfig.evaluationSubstitutionType, + ); + } + }); + } + } + } + } + }; + + formConfig.forEach(recursiveFindBindingPaths); + + return bindingPaths; +}; + +export const getDataTreeActionConfigPath = (propertyPath: string) => + propertyPath.replace("actionConfiguration.", "config."); diff --git a/app/taro/src/entities/Action/index.ts b/app/taro/src/entities/Action/index.ts new file mode 100644 index 0000000000..e2a8bc342c --- /dev/null +++ b/app/taro/src/entities/Action/index.ts @@ -0,0 +1,128 @@ +import { EmbeddedRestDatasource } from "entities/Datasource"; +import { DynamicPath } from "../../utils/DynamicBindingUtils"; +import _ from "lodash"; + +export enum PluginType { + API = "API", + DB = "DB", + SAAS = "SAAS", +} + +export enum PaginationType { + NONE = "NONE", + PAGE_NO = "PAGE_NO", + URL = "URL", +} + +export interface ActionConfig { + timeoutInMillisecond?: number; + paginationType?: PaginationType; + pluginSpecifiedTemplates?: Array<{ key?: string; value?: unknown }>; +} + +export interface ActionProvider { + name: string; + imageUrl: string; + url: string; + description: string; + credentialSteps: string; +} + +export interface Property { + key: string; + value: string; +} + +export interface BodyFormData { + editable: boolean; + mandatory: boolean; + description: string; + key: string; + value?: string; + type: string; +} + +export interface ApiActionConfig extends ActionConfig { + headers: Property[]; + httpMethod: string; + path?: string; + body?: JSON | string | Record | null; + encodeParamsToggle: boolean; + queryParameters?: Property[]; + bodyFormData?: BodyFormData[]; +} + +export interface QueryActionConfig extends ActionConfig { + body?: string; +} + +export const isStoredDatasource = (val: any): val is StoredDatasource => { + if (!_.isObject(val)) return false; + if (!("id" in val)) return false; + return true; +}; +export interface StoredDatasource { + id: string; +} + +interface BaseAction { + id: string; + name: string; + organizationId: string; + pageId: string; + collectionId?: string; + pluginId: string; + executeOnLoad: boolean; + dynamicBindingPathList: DynamicPath[]; + isValid: boolean; + invalids: string[]; + jsonPathKeys: string[]; + cacheResponse: string; + confirmBeforeExecute?: boolean; + eventData?: any; +} + +interface BaseApiAction extends BaseAction { + pluginType: PluginType.API; + actionConfiguration: ApiActionConfig; +} +export interface SaaSAction extends BaseAction { + pluginType: PluginType.SAAS; + actionConfiguration: any; + datasource: StoredDatasource; +} + +export interface EmbeddedApiAction extends BaseApiAction { + datasource: EmbeddedRestDatasource; +} + +export interface StoredDatasourceApiAction extends BaseApiAction { + datasource: StoredDatasource; +} + +export type ApiAction = EmbeddedApiAction | StoredDatasourceApiAction; + +export type RapidApiAction = ApiAction & { + templateId: string; + proverId: string; + provider: ActionProvider; + pluginId: string; + documentation: { text: string }; +}; + +export interface QueryAction extends BaseAction { + pluginType: PluginType.DB; + actionConfiguration: QueryActionConfig; + datasource: StoredDatasource; +} + +export type ActionViewMode = { + id: string; + name: string; + pageId: string; + jsonPathKeys: string[]; + confirmBeforeExecute?: boolean; + timeoutInMillisecond?: number; +}; + +export type Action = ApiAction | QueryAction | SaaSAction; diff --git a/app/taro/src/entities/App.ts b/app/taro/src/entities/App.ts new file mode 100644 index 0000000000..03f9627669 --- /dev/null +++ b/app/taro/src/entities/App.ts @@ -0,0 +1,4 @@ +export enum APP_MODE { + EDIT = "EDIT", + PUBLISHED = "PUBLISHED", +} diff --git a/app/taro/src/entities/AppsmithConsole/action.ts b/app/taro/src/entities/AppsmithConsole/action.ts new file mode 100644 index 0000000000..b41f7bb5d3 --- /dev/null +++ b/app/taro/src/entities/AppsmithConsole/action.ts @@ -0,0 +1,10 @@ +import { ActionableError } from "entities/AppsmithConsole"; + +export enum ActionError { + EXECUTION_TIMEOUT = "action:execution:timeout", +} + +export interface TimeoutError extends ActionableError { + type: ActionError.EXECUTION_TIMEOUT; + timeoutMs: number; +} diff --git a/app/taro/src/entities/AppsmithConsole/binding.ts b/app/taro/src/entities/AppsmithConsole/binding.ts new file mode 100644 index 0000000000..6544b88a21 --- /dev/null +++ b/app/taro/src/entities/AppsmithConsole/binding.ts @@ -0,0 +1,26 @@ +import { ActionableError } from "entities/AppsmithConsole"; + +export enum BindingError { + SYNTAX = "binding:syntax", + UNKNOWN_VARIABLE = "binding:unknown_variable", + DISALLOWED_FUNCTION = "binding:disallowed_function", +} + +interface BaseBindingError extends ActionableError { + lineNumber: number; + position: number; +} + +export interface SyntaxError extends BaseBindingError { + type: BindingError.SYNTAX; +} + +export interface UnknownVariableError extends BaseBindingError { + type: BindingError.UNKNOWN_VARIABLE; + variableName: string; +} + +export interface DisallowedFunctionError extends BaseBindingError { + type: BindingError.DISALLOWED_FUNCTION; + functionName: string; +} diff --git a/app/taro/src/entities/AppsmithConsole/eval.ts b/app/taro/src/entities/AppsmithConsole/eval.ts new file mode 100644 index 0000000000..bee17c56be --- /dev/null +++ b/app/taro/src/entities/AppsmithConsole/eval.ts @@ -0,0 +1,10 @@ +import { ActionableError, SourceEntity } from "entities/AppsmithConsole"; + +export enum EvalError { + CYCLIC = "eval:cyclic", +} + +export interface CyclicDependencyError extends ActionableError { + type: EvalError.CYCLIC; + entities: SourceEntity[]; +} diff --git a/app/taro/src/entities/AppsmithConsole/index.ts b/app/taro/src/entities/AppsmithConsole/index.ts new file mode 100644 index 0000000000..0ae20d2dee --- /dev/null +++ b/app/taro/src/entities/AppsmithConsole/index.ts @@ -0,0 +1,111 @@ +import { ReduxAction } from "constants/ReduxActionConstants"; +import { BindingError } from "entities/AppsmithConsole/binding"; +import { ActionError } from "entities/AppsmithConsole/action"; +import { WidgetError } from "entities/AppsmithConsole/widget"; +import { EvalError } from "entities/AppsmithConsole/eval"; +import LOG_TYPE from "./logtype"; + +export enum ENTITY_TYPE { + ACTION = "ACTION", + DATASOURCE = "DATASOURCE", + WIDGET = "WIDGET", +} + +export type ErrorType = BindingError | ActionError | WidgetError | EvalError; + +export enum Severity { + // Everything, irrespective of what the user should see or not + // DEBUG = "debug", + // Something the dev user should probably know about + INFO = "info", + // Doesn't break the app, but can cause slowdowns / ux issues/ unexpected behaviour + WARNING = "warning", + // Can cause an error in some cases/ single widget, app will work in other cases + ERROR = "error", + // Makes the app unusable, can't progress without fixing this. + // CRITICAL = "critical", +} + +export type UserAction = { + // Label is used to display the + label: string; + // As there can be multiple errors of the same base type at the same time + // and we need to be able to tell the difference, + // these action types should have a dynamic `id` associated with them + // or we should use JS callback functions instead + reduxAction: ReduxAction; +}; + +export interface SourceEntity { + type: ENTITY_TYPE; + // Widget or action name + name: string; + // Id of the widget or action + id: string; + // property path of the child + propertyPath?: string; +} + +export interface LogActionPayload { + // What is the log about. Is it a datasource update, widget update, eval error etc. + logType?: LOG_TYPE; + text: string; + // Time taken for the event to complete + messages?: Array<{ + // More contextual message than `text` + message: string; + // The section of code being referred to + // codeSegment?: string; + }>; + + timeTaken?: string; + // "where" source entity and propertyPsath. + source?: SourceEntity; + // Snapshot KV pair of scope variables or state associated with this event. + state?: Record; + // Any other data required for analytics + analytics?: Record; +} + +export interface Message extends LogActionPayload { + severity: Severity; + // "when" did this event happen + timestamp: string; +} + +/** + * Example: + * "Api timed out" + * { + * type: ActionError.EXECUTION_TIMEOUT, + * timeoutMs: 10000, + * severity: Severity.ERROR, + * message: "Action execution timedout after 10 seconds", + * source: { + * type: ENTITY_TYPE.ACTION, + * name: "Api1", + * id: "a12345", + * propertyPath: "run", + * }, + * timestamp: new Date(), + * state: {}, + * userActions: [ + * { + * label: "Increase timeout by 5 seconds", + * reduxAction: { + * type: "ACTION_INCREASE_TIMEOUT", + * payload: { actionId: "abcdef", value: 5000 }, + * }, + * }, + * ] + * } + */ +export interface ActionableError extends Message { + // Error type of the event. + type: ErrorType; + + severity: Severity.ERROR; + + // Actions a user can take to resolve this issue + userActions: Array; +} diff --git a/app/taro/src/entities/AppsmithConsole/logtype.ts b/app/taro/src/entities/AppsmithConsole/logtype.ts new file mode 100644 index 0000000000..8fd1658e13 --- /dev/null +++ b/app/taro/src/entities/AppsmithConsole/logtype.ts @@ -0,0 +1,11 @@ +enum LOG_TYPE { + WIDGET_PROPERTY_VALIDATION_ERROR, + WIDGET_UPDATE, + ACTION_EXECUTION_ERROR, + ACTION_EXECUTION_SUCCESS, + ENTITY_DELETED, + EVAL_ERROR, + ACTION_UPDATE, +} + +export default LOG_TYPE; diff --git a/app/taro/src/entities/AppsmithConsole/widget.ts b/app/taro/src/entities/AppsmithConsole/widget.ts new file mode 100644 index 0000000000..63212f4109 --- /dev/null +++ b/app/taro/src/entities/AppsmithConsole/widget.ts @@ -0,0 +1 @@ +export enum WidgetError {} diff --git a/app/taro/src/entities/DataTree/dataTreeAction.ts b/app/taro/src/entities/DataTree/dataTreeAction.ts new file mode 100644 index 0000000000..d108491405 --- /dev/null +++ b/app/taro/src/entities/DataTree/dataTreeAction.ts @@ -0,0 +1,50 @@ +import { DependencyMap, DynamicPath } from "utils/DynamicBindingUtils"; +import { DataTreeAction, ENTITY_TYPE } from "entities/DataTree/dataTreeFactory"; +import { ActionData } from "reducers/entityReducers/actionsReducer"; +import { + getBindingPathsOfAction, + getDataTreeActionConfigPath, +} from "entities/Action/actionProperties"; + +export const generateDataTreeAction = ( + action: ActionData, + editorConfig: any[], + dependencyConfig: DependencyMap = {}, +): DataTreeAction => { + let dynamicBindingPathList: DynamicPath[] = []; + // update paths + if ( + action.config.dynamicBindingPathList && + action.config.dynamicBindingPathList.length + ) { + dynamicBindingPathList = action.config.dynamicBindingPathList.map((d) => ({ + ...d, + key: `config.${d.key}`, + })); + } + const dependencyMap: DependencyMap = {}; + Object.entries(dependencyConfig).forEach(([dependent, dependencies]) => { + dependencyMap[getDataTreeActionConfigPath(dependent)] = dependencies.map( + getDataTreeActionConfigPath, + ); + }); + return { + run: {}, + actionId: action.config.id, + name: action.config.name, + pluginType: action.config.pluginType, + config: action.config.actionConfiguration, + dynamicBindingPathList, + data: action.data ? action.data.body : {}, + responseMeta: { + statusCode: action.data?.statusCode, + isExecutionSuccess: action.data?.isExecutionSuccess || false, + headers: action.data?.headers, + }, + ENTITY_TYPE: ENTITY_TYPE.ACTION, + isLoading: action.isLoading, + bindingPaths: getBindingPathsOfAction(action.config, editorConfig), + dependencyMap, + logBlackList: {}, + }; +}; diff --git a/app/taro/src/entities/DataTree/dataTreeFactory.ts b/app/taro/src/entities/DataTree/dataTreeFactory.ts new file mode 100644 index 0000000000..8363f57c43 --- /dev/null +++ b/app/taro/src/entities/DataTree/dataTreeFactory.ts @@ -0,0 +1,136 @@ +import { + ActionDataState, + ActionDataWithMeta, +} from "reducers/entityReducers/actionsReducer"; +import { WidgetProps } from "widgets/BaseWidget"; +import { ActionResponse } from "api/ActionAPI"; +import { CanvasWidgetsReduxState } from "reducers/entityReducers/canvasWidgetsReducer"; +import { MetaState } from "reducers/entityReducers/metaReducer"; +import { PageListPayload } from "constants/ReduxActionConstants"; +import { ActionConfig, PluginType } from "entities/Action"; +import { AppDataState } from "reducers/entityReducers/appReducer"; +import { DependencyMap, DynamicPath } from "utils/DynamicBindingUtils"; +import { generateDataTreeAction } from "entities/DataTree/dataTreeAction"; +import { generateDataTreeWidget } from "entities/DataTree/dataTreeWidget"; +import { ValidationConfig } from "constants/PropertyControlConstants"; + +export type ActionDescription = { + type: string; + payload: T; +}; + +export type ActionDispatcher = ( + ...args: A +) => ActionDescription; + +export enum ENTITY_TYPE { + ACTION = "ACTION", + WIDGET = "WIDGET", + APPSMITH = "APPSMITH", +} + +export type RunActionPayload = { + actionId: string; + onSuccess: string; + onError: string; + params: Record | string; +}; + +export enum EvaluationSubstitutionType { + TEMPLATE = "TEMPLATE", + PARAMETER = "PARAMETER", + SMART_SUBSTITUTE = "SMART_SUBSTITUTE", +} + +export interface DataTreeAction + extends Omit { + data: ActionResponse["body"]; + actionId: string; + config: Partial; + pluginType: PluginType; + name: string; + run: + | ActionDispatcher + | Record; + dynamicBindingPathList: DynamicPath[]; + bindingPaths: Record; + ENTITY_TYPE: ENTITY_TYPE.ACTION; + dependencyMap: DependencyMap; + logBlackList: Record; +} + +export interface DataTreeWidget extends WidgetProps { + bindingPaths: Record; + triggerPaths: Record; + validationPaths: Record; + ENTITY_TYPE: ENTITY_TYPE.WIDGET; + logBlackList: Record; +} + +export interface DataTreeAppsmith extends Omit { + ENTITY_TYPE: ENTITY_TYPE.APPSMITH; + store: Record; +} + +export type DataTreeObjectEntity = + | DataTreeAction + | DataTreeWidget + | DataTreeAppsmith; + +export type DataTreeEntity = + | DataTreeObjectEntity + | PageListPayload + | ActionDispatcher; + +export type DataTree = { + [entityName: string]: DataTreeEntity; +} & { actionPaths?: string[] }; + +type DataTreeSeed = { + actions: ActionDataState; + editorConfigs: Record; + pluginDependencyConfig: Record; + widgets: CanvasWidgetsReduxState; + widgetsMeta: MetaState; + pageList: PageListPayload; + appData: AppDataState; +}; + +export class DataTreeFactory { + static create({ + actions, + appData, + editorConfigs, + pageList, + pluginDependencyConfig, + widgets, + widgetsMeta, + }: DataTreeSeed): DataTree { + const dataTree: DataTree = {}; + actions.forEach((action) => { + const editorConfig = editorConfigs[action.config.pluginId]; + const dependencyConfig = pluginDependencyConfig[action.config.pluginId]; + dataTree[action.config.name] = generateDataTreeAction( + action, + editorConfig, + dependencyConfig, + ); + }); + Object.values(widgets).forEach((widget) => { + dataTree[widget.widgetName] = generateDataTreeWidget( + widget, + widgetsMeta[widget.widgetId], + ); + }); + + dataTree.pageList = pageList; + dataTree.global = { + ...appData, + // combine both persistent and transient state with the transient state + // taking precedence in case the key is the same + store: { ...appData.store.persistent, ...appData.store.transient }, + } as DataTreeAppsmith; + (dataTree.global as DataTreeAppsmith).ENTITY_TYPE = ENTITY_TYPE.APPSMITH; + return dataTree; + } +} diff --git a/app/taro/src/entities/DataTree/dataTreeWidget.ts b/app/taro/src/entities/DataTree/dataTreeWidget.ts new file mode 100644 index 0000000000..2243f642bf --- /dev/null +++ b/app/taro/src/entities/DataTree/dataTreeWidget.ts @@ -0,0 +1,82 @@ +import WidgetFactory from "utils/WidgetFactory"; +import { getAllPathsFromPropertyConfig } from "entities/Widget/utils"; +import { getEntityDynamicBindingPathList } from "utils/DynamicBindingUtils"; +import _ from "lodash"; +import { DataTreeWidget, ENTITY_TYPE } from "entities/DataTree/dataTreeFactory"; +import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; + +export const generateDataTreeWidget = ( + widget: FlattenedWidgetProps, + widgetMetaProps: Record, +): DataTreeWidget => { + const defaultMetaProps = WidgetFactory.getWidgetMetaPropertiesMap( + widget.type, + ); + + const derivedPropertyMap = WidgetFactory.getWidgetDerivedPropertiesMap( + widget.type, + ); + const defaultProps = WidgetFactory.getWidgetDefaultPropertiesMap(widget.type); + + const propertyPaneConfigs = WidgetFactory.getWidgetPropertyPaneConfig( + widget.type, + ); + const derivedProps: any = {}; + const dynamicBindingPathList = getEntityDynamicBindingPathList(widget); + dynamicBindingPathList.forEach((dynamicPath) => { + const propertyPath = dynamicPath.key; + const propertyValue = _.get(widget, propertyPath); + if (_.isObject(propertyValue)) { + // Stringify this because composite controls may have bindings in the sub controls + _.set(widget, propertyPath, JSON.stringify(propertyValue)); + } + }); + Object.keys(derivedPropertyMap).forEach((propertyName) => { + // TODO regex is too greedy + derivedProps[propertyName] = derivedPropertyMap[propertyName].replace( + /this./g, + `${widget.widgetName}.`, + ); + dynamicBindingPathList.push({ + key: propertyName, + }); + }); + const unInitializedDefaultProps: Record = {}; + Object.values(defaultProps).forEach((propertyName) => { + if (!(propertyName in widget)) { + unInitializedDefaultProps[propertyName] = undefined; + } + }); + const blockedDerivedProps: Record = {}; + Object.keys(derivedProps).forEach((propertyName) => { + blockedDerivedProps[propertyName] = true; + }); + const { + bindingPaths, + triggerPaths, + validationPaths, + } = getAllPathsFromPropertyConfig(widget, propertyPaneConfigs, { + ...derivedPropertyMap, + ...defaultMetaProps, + ...unInitializedDefaultProps, + ..._.keyBy(dynamicBindingPathList, "key"), + }); + return { + ...widget, + ...defaultMetaProps, + ...widgetMetaProps, + ...derivedProps, + ...unInitializedDefaultProps, + defaultProps, + defaultMetaProps: Object.keys(defaultMetaProps), + dynamicBindingPathList, + logBlackList: { + ...widget.logBlackList, + ...blockedDerivedProps, + }, + bindingPaths, + triggerPaths, + validationPaths, + ENTITY_TYPE: ENTITY_TYPE.WIDGET, + }; +}; diff --git a/app/taro/src/entities/Datasource/RestAPIForm.ts b/app/taro/src/entities/Datasource/RestAPIForm.ts new file mode 100644 index 0000000000..c12e1ae2d9 --- /dev/null +++ b/app/taro/src/entities/Datasource/RestAPIForm.ts @@ -0,0 +1,81 @@ +import { Property } from "entities/Action"; + +export enum AuthType { + NONE = "NONE", + OAuth2 = "oAuth2", + basic = "basic", + apiKey = "apiKey", + bearerToken = "bearerToken", +} + +export enum ApiKeyAuthType { + QueryParams = "queryParams", + Header = "header", +} + +export enum GrantType { + ClientCredentials = "client_credentials", + AuthorizationCode = "authorization_code", +} + +export type Authentication = + | ClientCredentials + | AuthorizationCode + | Basic + | ApiKey + | BearerToken; + +export interface ApiDatasourceForm { + datasourceId: string; + pluginId: string; + organizationId: string; + isValid: boolean; + url: string; + headers?: Property[]; + isSendSessionEnabled: boolean; + sessionSignatureKey: string; + authType: AuthType; + authentication?: Authentication; +} + +export interface Oauth2Common { + authenticationType: AuthType.OAuth2; + accessTokenUrl: string; + clientId: string; + clientSecret: string; + headerPrefix: string; + scopeString: string; + isTokenHeader: boolean; + audience: string; + resource: string; +} + +export interface ClientCredentials extends Oauth2Common { + grantType: GrantType.ClientCredentials; +} + +export interface AuthorizationCode extends Oauth2Common { + grantType: GrantType.AuthorizationCode; + authorizationUrl: string; + customAuthenticationParameters: Property[]; + isAuthorizationHeader: boolean; + isAuthorized: boolean; +} + +export interface Basic { + authenticationType: AuthType.basic; + username: string; + password: string; +} + +export interface ApiKey { + authenticationType: AuthType.apiKey; + label: string; + value: string; + addTo: string; +} + +export interface BearerToken { + authenticationType: AuthType.bearerToken; + bearerToken: string; +} diff --git a/app/taro/src/entities/Datasource/index.ts b/app/taro/src/entities/Datasource/index.ts new file mode 100644 index 0000000000..4088d90691 --- /dev/null +++ b/app/taro/src/entities/Datasource/index.ts @@ -0,0 +1,103 @@ +import { APIResponseError } from "api/ApiResponses"; +import { Property } from "entities/Action"; +import _ from "lodash"; +export interface DatasourceAuthentication { + authType?: string; + username?: string; + password?: string; + label?: string; + value?: string; + addTo?: string; + bearerToken?: string; +} + +export interface DatasourceColumns { + name: string; + type: string; +} + +export interface DatasourceKeys { + name: string; + type: string; +} + +export interface DatasourceStructure { + tables?: DatasourceTable[]; + error?: APIResponseError; +} + +export interface QueryTemplate { + title: string; + body: string; + pluginSpecifiedTemplates?: Array<{ key?: string; value?: unknown }>; +} +export interface DatasourceTable { + type: string; + name: string; + columns: DatasourceColumns[]; + keys: DatasourceKeys[]; + templates: QueryTemplate[]; +} + +// todo: check which fields are truly optional and move the common ones into base +interface BaseDatasource { + pluginId: string; + name: string; + organizationId: string; + isValid: boolean; +} + +export const isEmbeddedRestDatasource = ( + val: any, +): val is EmbeddedRestDatasource => { + if (!_.isObject(val)) return false; + if (!("datasourceConfiguration" in val)) return false; + val = val; + // Object should exist and have value + if (!val.datasourceConfiguration) return false; + //url might exist as a key but not have value, so we won't check value + if (!("url" in val.datasourceConfiguration)) return false; + return true; +}; + +export interface EmbeddedRestDatasource extends BaseDatasource { + datasourceConfiguration: { url: string }; + invalids: Array; + messages: Array; +} +export interface Datasource extends BaseDatasource { + id: string; + datasourceConfiguration: { + url: string; + authentication?: DatasourceAuthentication; + properties?: Property[]; + headers?: Property[]; + databaseName?: string; + }; + invalids?: string[]; + structure?: DatasourceStructure; + messages?: string[]; +} + +export interface MockDatasource { + name: string; + description: string; + packageName: string; + pluginType: string; + pluginName?: string; +} + +export const DEFAULT_DATASOURCE = ( + pluginId: string, + organizationId: string, +): EmbeddedRestDatasource => ({ + name: "DEFAULT_REST_DATASOURCE", + datasourceConfiguration: { + url: "", + }, + invalids: [], + isValid: true, + pluginId, + organizationId, + messages: [], +}); diff --git a/app/taro/src/entities/FeatureFlag.ts b/app/taro/src/entities/FeatureFlag.ts new file mode 100644 index 0000000000..638d42d776 --- /dev/null +++ b/app/taro/src/entities/FeatureFlag.ts @@ -0,0 +1,6 @@ +type FeatureFlag = { + COMMENT: boolean; + JS_EDITOR: boolean; +}; + +export default FeatureFlag; diff --git a/app/taro/src/entities/Notification.ts b/app/taro/src/entities/Notification.ts new file mode 100644 index 0000000000..8e021b66c4 --- /dev/null +++ b/app/taro/src/entities/Notification.ts @@ -0,0 +1,12 @@ +export type AppsmithNotification = { + id: string; + _id?: string; + type: string; + new: boolean; + [key: string]: any; +}; + +export enum NotificationTypes { + CommentNotification = "CommentNotification", + CommentThreadNotification = "CommentThreadNotification", +} diff --git a/app/taro/src/entities/Tour/index.ts b/app/taro/src/entities/Tour/index.ts new file mode 100644 index 0000000000..1969d66c8f --- /dev/null +++ b/app/taro/src/entities/Tour/index.ts @@ -0,0 +1,4 @@ +export enum TourType { + COMMENTS_TOUR_EDIT_MODE = "COMMENTS_TOUR_EDIT_MODE", + COMMENTS_TOUR_PUBLISHED_MODE = "COMMENTS_TOUR_PUBLISHED_MODE", +} diff --git a/app/taro/src/entities/Widget/utils.ts b/app/taro/src/entities/Widget/utils.ts new file mode 100644 index 0000000000..67eddd669e --- /dev/null +++ b/app/taro/src/entities/Widget/utils.ts @@ -0,0 +1,162 @@ +import { WidgetProps } from "widgets/BaseWidget"; +import { + PropertyPaneConfig, + ValidationConfig, +} from "constants/PropertyControlConstants"; +import { get, isObject, isUndefined } from "lodash"; +import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; + +export const getAllPathsFromPropertyConfig = ( + widget: WidgetProps, + widgetConfig: readonly PropertyPaneConfig[], + defaultProperties: Record, +): { + bindingPaths: Record; + triggerPaths: Record; + validationPaths: Record; +} => { + const bindingPaths: Record = {}; + Object.keys(defaultProperties).forEach( + (property) => + (bindingPaths[property] = EvaluationSubstitutionType.TEMPLATE), + ); + const triggerPaths: Record = {}; + const validationPaths: Record = {}; + widgetConfig.forEach((config) => { + if (config.children) { + config.children.forEach((controlConfig: any) => { + const basePath = controlConfig.propertyName; + let isHidden = false; + if ("hidden" in controlConfig) { + isHidden = controlConfig.hidden(widget, basePath); + } + + if (!isHidden) { + if ( + controlConfig.isBindProperty && + !controlConfig.isTriggerProperty + ) { + bindingPaths[controlConfig.propertyName] = + controlConfig.evaluationSubstitutionType || + EvaluationSubstitutionType.TEMPLATE; + if (controlConfig.validation) { + validationPaths[controlConfig.propertyName] = + controlConfig.validation; + } + } else if ( + controlConfig.isBindProperty && + controlConfig.isTriggerProperty + ) { + triggerPaths[controlConfig.propertyName] = true; + } + } + if (controlConfig.panelConfig) { + const panelPropertyPath = controlConfig.propertyName; + const widgetPanelPropertyValues = get(widget, panelPropertyPath); + if (widgetPanelPropertyValues) { + Object.values(widgetPanelPropertyValues).forEach( + (widgetPanelPropertyValue: any) => { + controlConfig.panelConfig.children.forEach( + (panelColumnConfig: any) => { + let isSectionHidden = false; + if ("hidden" in panelColumnConfig) { + isSectionHidden = panelColumnConfig.hidden( + widget, + `${basePath}.${widgetPanelPropertyValue.id}`, + ); + } + if (!isSectionHidden) { + panelColumnConfig.children.forEach( + (panelColumnControlConfig: any) => { + const panelPropertyPath = `${basePath}.${widgetPanelPropertyValue.id}.${panelColumnControlConfig.propertyName}`; + let isControlHidden = false; + if ("hidden" in panelColumnControlConfig) { + isControlHidden = panelColumnControlConfig.hidden( + widget, + panelPropertyPath, + ); + } + if (!isControlHidden) { + if ( + panelColumnControlConfig.isBindProperty && + !panelColumnControlConfig.isTriggerProperty + ) { + bindingPaths[panelPropertyPath] = + controlConfig.evaluationSubstitutionType || + EvaluationSubstitutionType.TEMPLATE; + if (panelColumnControlConfig.validation) { + validationPaths[panelPropertyPath] = + panelColumnControlConfig.validation; + } + } else if ( + panelColumnControlConfig.isBindProperty && + panelColumnControlConfig.isTriggerProperty + ) { + triggerPaths[panelPropertyPath] = true; + } + } + }, + ); + } + }, + ); + }, + ); + } + } + if (controlConfig.children) { + const basePropertyPath = controlConfig.propertyName; + const widgetPropertyValue = get(widget, basePropertyPath, []); + // Property in object structure + if ( + !isUndefined(widgetPropertyValue) && + isObject(widgetPropertyValue) + ) { + Object.keys(widgetPropertyValue).map((key: string) => { + const objectIndexPropertyPath = `${basePropertyPath}.${key}`; + controlConfig.children.forEach((childPropertyConfig: any) => { + const childArrayPropertyPath = `${objectIndexPropertyPath}.${childPropertyConfig.propertyName}`; + + if ( + childPropertyConfig.isBindProperty && + !childPropertyConfig.isTriggerProperty + ) { + bindingPaths[childArrayPropertyPath] = + childPropertyConfig.evaluationSubstitutionType || + EvaluationSubstitutionType.TEMPLATE; + if (childPropertyConfig.validation) { + validationPaths[childArrayPropertyPath] = + childPropertyConfig.validation; + } + } else if ( + childPropertyConfig.isBindProperty && + childPropertyConfig.isTriggerProperty + ) { + triggerPaths[childArrayPropertyPath] = true; + } + }); + }); + } + } + }); + } + }); + + return { bindingPaths, triggerPaths, validationPaths }; +}; + +export const nextAvailableRowInContainer = ( + parentContainerId: string, + canvasWidgets: { [widgetId: string]: FlattenedWidgetProps }, +) => { + return ( + Object.values(canvasWidgets).reduce( + (prev: number, next: any) => + next?.parentId === parentContainerId && next.bottomRow > prev + ? next.bottomRow + : prev, + 0, + ) + 1 + ); +}; diff --git a/app/taro/src/index.html b/app/taro/src/index.html new file mode 100644 index 0000000000..826f423513 --- /dev/null +++ b/app/taro/src/index.html @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + +

+ + diff --git a/app/taro/src/mockResponses/ApplicationsNewMockResponse.json b/app/taro/src/mockResponses/ApplicationsNewMockResponse.json new file mode 100644 index 0000000000..f6064a6753 --- /dev/null +++ b/app/taro/src/mockResponses/ApplicationsNewMockResponse.json @@ -0,0 +1,422 @@ +{ + "responseMeta":{ + "status":200, + "success":true + }, + "data":{ + "user":{ + "id":"6065e4a8034ece74b1481817", + "userPermissions":[ + + ], + "email":"b1@appsmith.com", + "source":"FORM", + "isEnabled":true, + "currentOrganizationId":"6065e4b7034ece74b1481819", + "organizationIds":[ + "6065e4a8034ece74b1481818", + "6065e4b7034ece74b1481819" + ], + "groupIds":[ + + ], + "permissions":[ + + ], + "isAnonymous":false, + "enabled":true, + "username":"b1@appsmith.com", + "accountNonExpired":true, + "accountNonLocked":true, + "credentialsNonExpired":true, + "claims":{ + + }, + "address":{ + + }, + "new":false + }, + "organizationApplications":[ + { + "organization":{ + "id":"6065e4a8034ece74b1481818", + "userPermissions":[ + "read:organizations", + "manage:orgApplications", + "manage:organizations", + "inviteUsers:organization", + "publish:orgApplications", + "read:orgApplications" + ], + "name":"b1's apps", + "email":"b1@appsmith.com", + "plugins":[ + { + "userPermissions":[ + + ], + "pluginId":"5ca385dc81b37f0004b4db85", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5e8dad9bf062d5125ddfd836", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5ec3bccdd4b5eaa50ba6f583", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5ec3bcf1d4b5eaa50ba6f593", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f192a44a2d05225d010db9d", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9e9107018510ae540be", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9ec107018510ae540c0", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9ef107018510ae540c3", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9f1107018510ae540c5", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5fbcc1c758377818ddaec444", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"60081f50ffab735a9dae84e7", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"60374b7d074f9b49cd68a036", + "status":"FREE", + "new":true + } + ], + "slug":"b1-s-apps", + "logoUrl":"/api/v1/assets/null", + "new":false + }, + "applications":[ + + ], + "userRoles":[ + { + "username":"b1@appsmith.com", + "roleName":"Administrator" + } + ] + }, + { + "organization":{ + "id":"6065e4b7034ece74b1481819", + "userPermissions":[ + "read:organizations", + "manage:orgApplications", + "manage:organizations", + "inviteUsers:organization", + "publish:orgApplications", + "read:orgApplications" + ], + "name":"new org", + "email":"b1@appsmith.com", + "plugins":[ + { + "userPermissions":[ + + ], + "pluginId":"5ca385dc81b37f0004b4db85", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5e8dad9bf062d5125ddfd836", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5ec3bccdd4b5eaa50ba6f583", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5ec3bcf1d4b5eaa50ba6f593", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f192a44a2d05225d010db9d", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9e9107018510ae540be", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9ec107018510ae540c0", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9ef107018510ae540c3", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9f1107018510ae540c5", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5fbcc1c758377818ddaec444", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"60081f50ffab735a9dae84e7", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"60374b7d074f9b49cd68a036", + "status":"FREE", + "new":true + } + ], + "slug":"new-org5", + "logoUrl":"/api/v1/assets/null", + "new":false + }, + "applications":[ + + ], + "userRoles":[ + { + "username":"b1@appsmith.com", + "roleName":"Administrator" + } + ] + } + ], + "newReleasesCount":"", + "releaseItems":[ + { + "tagName":"v1.4.6", + "name":"Release v1.4.6 \uD83D\uDC1E", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.4.6", + "descriptionHtml":"

Bug fix

\n

New validations in DatePicker widget allows only ISO 8601 format dates in the defaultDate property.
\nThis fix tries to automatically parse the given date string to generate a valid ISO string.

", + "publishedAt":"2021-03-30T10:00:15Z" + }, + { + "tagName":"v1.4.5", + "name":"Release v1.4.5 \uD83C\uDFA2 ", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.4.5", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • We made the storeValue function calls synchronous. You can now access those values directly in any action runs just after creating/updating store values! (#3663)
  • \n
  • You can now add a flag to ensure that values stored in your app via storeValue are saved only for a single user session (#3663)
  • \n
  • We've added a new option to provide non-client certificate-based SSL support for Mysql, Mongo, Postgres plugins. (#3518)
  • \n
  • On-prem installations can now choose to increase the REST API payload size! The default for new installations is set to 100MB. (Appsmith cloud will continue to limit request bodies to 10MB) (#3718, \t#3553)
  • \n
  • We've added a new URL data-type option for the table widget. You can now redirect to URLs with a simple click. No more copy-pasting! (#3569)
  • \n
  • You can now validate the input from the DatePicker Widget to have a datatype of ISO string (#3397)
  • \n
  • While logging out, the local storage gets cleared out. This means you don't end up adding any old persisted data inside Appsmith’s memory. (#3663)
  • \n
  • Chart Widget is now fully customizable by using fusion-charts configs directly to render charts (#2670)
  • \n
\n

\uD83D\uDC1B Bugs

\n
    \n
  • We've fixed an issue of using AWS S3 signed URL requests in the Rest API Plugin (#3734)
  • \n
  • The table widget maps column properties correctly when filtering, sorting or searching for data. (#3381, #3706)
  • \n
  • Debugging APIs with larger JSON responses just got easier with our new code-folding feature. (#3658)
  • \n
  • We've updated the default file encoding to Base64 when creating a file on S3. (#3685)
  • \n
  • Show null values as empty cells in a table (#3522)
  • \n
  • We've made some improvements to the DatePicker widget, for more accurate data-type formats. (#3162)
  • \n
  • We've made some fixes around recognizing string values in Prepared Statement (#3710)
  • \n
  • Previously, while working with APIs, when you convert a GET call to POST, it would add the content-type header in the last row of headers. We've resolved this by adding this header in the first empty row (#3659)
  • \n
", + "publishedAt":"2021-03-29T14:23:12Z" + }, + { + "tagName":"v1.4.4", + "name":"Release v1.4.4 ✨", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.4.4", + "descriptionHtml":"

Whats new

\n

\uD83D\uDE80 Features

\n
    \n
  • We've added a new option to provide non-client certificate-based SSL support for Mysql, Mongo, Postgres plugins. (#3518)
  • \n
  • The logs and analytics are much better! We've enriched the Installation, logging events and their execution. (#3622, #3492, #3573)
  • \n
  • Appsmith pages now support more devices in AppLayout Options for a better viewing experience from large tablets to mobile screens. (#3451)
  • \n
  • We've made some enhancements to Property Pane for widgets and virtualised query Editor Table. (#3057, #3496)
  • \n
  • We've updated the Maven dependencies to reduce build time and Jar Size of S3; it's ~80% faster now! (#3491)
  • \n
  • A new JSON intelligent substitution has been added for REST API Plugin. (#3474)
  • \n
\n

\uD83D\uDC1B Bugs

\n
    \n
  • We've improved the global-search feature, and you'll now have a seamless search experience to our docs, widgets and many more from Appsmith Applications. (#3615, #3502)
  • \n
  • The OAuth tokens for forked data sources will be now cleared, and you can replace them with our own keys and fork apps within no time. (#3609)
  • \n
  • The toast messages for different actions are more intuitive and responsive! (#3591)
  • \n
  • We've fixed the container widget dynamicBindingPathList correction. (#3619)
  • \n
  • You can now add ellipsis to your organisation names from the settings page. (#3572)
  • \n
  • The selected rows on the table widget will be reset whenever the table is changed. (#3576)
  • \n
  • The height of the canvas, while you're building apps, will now be dynamically updated based on the bottom-most widget. (#3398)
  • \n
  • We've fixed some issues and made improvements for forking applications on Appsmith. ([#3519]
    \n(appsmithorg/appsmith#3519), #3509)
  • \n
  • The validation options for dropdown widgets will allow null or an empty string as values.(#3533)
  • \n
  • Appsmith now saves the height of the updated table row while editing the application. (#3537)
  • \n
  • You can now handle scenario's where columnOrder was unavailable in Table widget (#3511)
  • \n
  • API Pane Headers and Parameter Counts are now Fixed. (#3494)
  • \n
  • You'll now find the default test and HTML properties in RTE! (#3055)
  • \n
  • Previously, we had few issues with the API settings page. They have been now fixed and will be showing the updated values. (#3489)
  • \n
  • We've made base64 encoding the default type for S3 file uploads (#3514)
  • \n
  • The Tabs widget property will now be updated while deleting from the explorer. (#3405)
  • \n
", + "publishedAt":"2021-03-22T10:39:05Z" + }, + { + "tagName":"v1.4.3", + "name":"Release v1.4.3 \uD83D\uDD0D", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.4.3", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Global search (#2903)
  • \n
  • Fork application (#3453)
  • \n
  • Use dynamic input text in plugin editor forms (#3470)
  • \n
  • Custom S3 service support (#3469)
  • \n
  • APIs for profile photos (#3260)
  • \n
  • Added support for Prepared Statement in MS SQL plugin. (#3438)
  • \n
  • Added support for Arrays in Prepared Statement in Postgres (#3421)
  • \n
  • Adds support for base64 image strings to image cells (#2769)
  • \n
  • Adding support for Prepared Statements in MySQL plugin (#3327)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Improve cylical dependency error (#3471)
  • \n
  • Fix chat with us button at the editor help menu (#3465)
  • \n
  • Add timeout failure for mongo plugin test datasource (#3431)
  • \n
  • Fix: Incorrect validation of image src in onboarding (#3448)
  • \n
  • Fix chart data migration issues (#3458)
  • \n
  • Render placeholder text in the Key Value form input (#3452)
  • \n
  • Fix: Modal Size gets cut in smaller screens. (#3441)
  • \n
  • Deprecate UPDATE_WIDGET_PROPERTY action (#3392)
  • \n
  • Changed order of message for easy grep in case of invalid dynamic binding path (#3436)
  • \n
  • Only return request object in action execute if the action was executed in EDIT mode. (#3426)
  • \n
  • Add analytical events on page save (#3434)
  • \n
  • Fix for Table onPageSizeChange trigger executing when not defined (#3422)
  • \n
  • [ImgBot] Optimize images (#3435)
  • \n
  • Gracefully handle the timeout overflow / out of expected range errors (#3411)
  • \n
  • Adding test cases for Table (#3325)
  • \n
  • Fix action name issue when moving it from one page to another (#3352)
  • \n
", + "publishedAt":"2021-03-10T10:59:37Z" + }, + { + "tagName":"v1.4.2", + "name":"Release v1.4.2 \uD83E\uDE79", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.4.2", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Add mongo srv support (#3341)
  • \n
  • Support descending ordering for Firestore documents (#3340)
  • \n
  • Canvas Layout Options(max width config) (#3141)
  • \n
  • Reset widget global function (#3181)
  • \n
  • Support editing user’s name field (#3306)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Wrap ads button text within span for resilience for DOM mutations (#3292)
  • \n
  • End to cyclical dependency woes (#3380, #3364, #3310)
  • \n
  • Drop overlay widgets anywhere and add them as main container child (#3332)
  • \n
  • API for forking of public applications (#3221)
  • \n
  • Fix tabs widget crash due to invalid data (#3235)
  • \n
  • Faster typing in cypress tests (#2805)
  • \n
  • Fix ‘placeholderText’ label in form.json files (#3331)
  • \n
  • Remove endpoint host and port fields from Dynamodb datasource configuration form (#3316)
  • \n
  • RTE crashes if the default text is an array (#3385)
  • \n
  • Fix widget updates not working properly (#3403)
  • \n
  • Fix issue with dynamicTrigger updates (#3337)
  • \n
", + "publishedAt":"2021-03-05T08:10:52Z" + }, + { + "tagName":"v1.4.1", + "name":"Release v1.4.1 \uD83C\uDF08", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.4.1", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Added selectedOptionLabel property in dropdown widget (#3205)
  • \n
  • Added functionality to show/hide a tab from tab property pane controls (#3192)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Only add request body in case the HTTP method is GET (#3307)
  • \n
  • Fix help modal overlapping with close button (#3289)
  • \n
  • Refactoring the Action execution to support analytics data (#3159)
  • \n
  • Fix: Duplicate Property For Map Widget (#3174)
  • \n
  • Fix: Make the Table Actions button consistent with the rest of Appsmith's design system (#3222)
  • \n
  • Fix: Invalid cyclical dependency messages showing up when configuring API actions (#3259)
  • \n
  • Fix: Table's selected row would not reflect the correct data on searching and filtering (#3293)
  • \n
  • Fix: Correct organisation wasn't being fetched in all scenarios during onboarding (#3243)
  • \n
  • Fix: The table would add duplicate columns in some scenarios (#3227)
  • \n
  • Fix: Adding support for NULL value parameters in Prepared Statement. (#3255)
  • \n
  • Fix: check dynamodb connection validity using listTables cmd. (#3241)
  • \n
  • Fix: MongoDB test operation errors not being caught (#3234)
  • \n
  • Fix: Show the redirect URL to be configured by the user for OAuth authorization code flow (#3232)
  • \n
  • Fix: Renaming an action goes to the action page (#3201)
  • \n
  • Fix: Current page wasn't changing while switching to an action of another page (#3214)
  • \n
", + "publishedAt":"2021-03-02T08:19:53Z" + }, + { + "tagName":"v1.4", + "name":"Release v1.4 \uD83D\uDD25", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.4", + "descriptionHtml":"

What's new?

\n

Deprecation and updates

\n

A brand new DatePicker widget has replaced the old one in the widget list in the sidebar. Appsmith recommends replacing any existing DatePicker widgets in applications with a new one by dragging the DatePicker from the widget list in the sidebar.

\n

⚠️ The old DatePicker is being phased out and will not receive any bug fixes.

\n

\uD83D\uDE80 Features

\n
    \n
  • An exciting new table design with lots of features such as dynamic fields, dynamic row colouring and many more! (#2816)
  • \n
  • A completely over-hauled API pane design (#2218)
  • \n
  • An exciting new onboarding flow which prompts new users to build a standup application for superheroes. (#2686)
  • \n
  • Support server-side pagination for Firestore (#3128)
  • \n
  • A much improved version of the DatePicker widget (#2889)
  • \n
  • A new Switch widget lands in our kitty as well (#2999)
  • \n
  • Transform Dynamodb response for easy consumption (#3050)
  • \n
  • Adding support for Prepared Statements in Postgres plugin as a beta feature. This mitigates the risk of SQL injection attacks. (#2967, #3161)
  • \n
  • Add integration with OAuth2 endpoints for Rest API plugin. Now you can connect to Google, Facebook etc APIs with ease. Read more in our documentation (#3153)
  • \n
  • Add native Amazon S3 integration within Appsmith. Read more in our documentation (#2735, #2976)
  • \n
  • You can now create a Modal widget directly from the widget pane. Such easy, much wow! (#3092)
  • \n
  • Adding onClick trigger to the Chart widget. Users can now configure actions to be executed on click of data points in a chart. (#2953)
  • \n
  • Allow MongoDB datasources to be created without username/password (#3149)
  • \n
  • Fix Local setup changes to accommodate new M1 chip Macbooks. (#2959)
  • \n
  • Allow app-viewers to invite others as app-viewers. Users with only view access don't need to reach out to their developers to share apps any more. (#2961)
  • \n
  • Show a toast message when an action is intelligently set to execute on page load (#3042)
  • \n
  • Enable toggle for encoding query parameters & form body for REST API actions (#2968)
  • \n
  • Add auto-complete in action forms for all integrations & plugins (#2983)
  • \n
  • Add Firestore document metadata (as _ref field) in responses (#3063, #3135)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Fix: action evaluated value updates (#3142)
  • \n
  • Fix: Modal type form goes out of screen (#3037)
  • \n
  • Fix: Add toast for trigger errors (#3100)
  • \n
  • Fix: Handle quota exceeded and running low on disk space errors while saving a key in localStorage (#2947)
  • \n
  • Fix: Padding/Margin issues with containers (#2446)
  • \n
  • Fix: Consistent handling of signup configuration for FORM and OAUTH (#3013)
  • \n
  • Fix: Better error message when browser's lose network connectivity (#3077)
  • \n
  • Fix: Datasource is given permission for a public app during create/update of a public action (#3086)
  • \n
  • Fix: BatchGetItem and TransactGetItems operations failing on the DynamoDB plugin (#3120)
  • \n
  • Fix: Styles for the appsmith logo for safari browsers (#3133)
  • \n
  • Fix: Shrink Entity explorer by 20% so that you have more canvas space to design beautiful apps. (#3005)
  • \n
  • Fix: Allow searching for page names in explorer and other improvements on the entity explorer (#3038)
  • \n
  • Fix: Datasource & APIs could have the same name which would cause conflicts during page load (#3134)
  • \n
  • Fix: Form would get reset to incorrect default values (#2861)
  • \n
  • Fix: Improve the installation script while generating password and salt on machines with different locales (#3051)
  • \n
\n

Lots of bug fixes focusing on stability & consistency of applications built on Appsmith.

", + "publishedAt":"2021-02-25T16:54:53Z" + }, + { + "tagName":"v1.3.5.1", + "name":"Release v1.3.5.1", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.3.5.1", + "descriptionHtml":"", + "publishedAt":"2021-02-10T09:44:14Z" + }, + { + "tagName":"v1.3.5", + "name":"Release v1.3.5", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.3.5", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Add datasource structure support for DynamoDB (#2919)
  • \n
  • Hide body textarea in Firestore action editor for GET and DELETE operations (#2939)
  • \n
  • Add support for bindings in Firestore plugin's where condition value (#2934)
  • \n
  • Add support for touch events on the tabs in application view mode (#2910)
  • \n
  • Upgrade node to v14 LTS (#2931, #2943)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Modified documentation links for plugins (#2909)
  • \n
  • Fix Scan operation throwing a 500 in DynamoDB plugin (#2915)
  • \n
  • Fix input's onSubmit action being triggered if its validation is failing (#2960)
  • \n
  • Fix pageSize in table generated via \"Add Widget\" in query pane (#2944)
  • \n
  • Fix error on cannot read property closeModal of null (#2911)
  • \n
  • Fix rare condition where the MySQL plugin throws an internal server error (#2922)
  • \n
  • Fix deleted actions showing up in unpublished pages (#2792)
  • \n
", + "publishedAt":"2021-02-10T09:29:04Z" + }, + { + "tagName":"v1.3.4", + "name":"Release v1.3.4", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.3.4", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Update Default styles of Widgets (#2823)
  • \n
  • Added a text property for the file widgets to contain the text contents of the selected file (#2879)
  • \n
  • Introduced a troubleshooting guide in our documentation (#2877)
  • \n
  • New and more consistent design for the editor and the viewer's navbar (#2750)
  • \n
  • Added an option to reset input widgets' value(s) on submit (#2837)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Fix handling of array typed columns in Postgres databases (#2887)
  • \n
  • Fix app viewer's bottom border when the tabs aren't rendered (#2883)
  • \n
  • Fix in-app links to documentation (#2851)
  • \n
  • Fix handling of action error responses leading to undefined responses (#2839)
  • \n
  • Fix missing user name in first organization name when someone signs up (#2873)
  • \n
  • Fix incorrect release time being shown in help popup (#2850)
  • \n
", + "publishedAt":"2021-02-08T11:43:37Z" + }, + { + "tagName":"v1.3.3", + "name":"Release v1.3.3 \uD83C\uDF08", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.3.3", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Add support for mailto and tel links in navigateTo function (#2781)
  • \n
  • Add file name field to file picker's files property (#2843)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Migrate renamed canvas widgets to the correct name (#2782)
  • \n
  • Fix date widget crash due to invalid date (#2845)
  • \n
  • Fix signature in Rest Api actions throwing an internal server error (#2757)
  • \n
  • Fix datasource hostnames being saved with spaces (#2844)
  • \n
  • Fix cursor jumping to end in signup form (#2802)
  • \n
  • Fix manage users link not visible in the share modal when triggered from the editor or viewer (#2653)
  • \n
  • Fix redirect to applications page from auth pages when the user is logged in (#2771)
  • \n
  • Wrap words in a toast message (#2832)
  • \n
  • Fix error when handling lists in DynamoDB responses (#2818)
  • \n
  • Fix bug with onPageLoad state not showing up correctly (#2801)
  • \n
  • Fix reference types in arrays in Firestore (#2811)
  • \n
  • Fix new widget and action name conflicts (#2778)
  • \n
  • Fix tab name update from the entity explorer (#2779)
  • \n
  • Fix user email duplicated as name when inviting a user (#2787)
  • \n
  • Fix incorrect validations (#2687)
  • \n
", + "publishedAt":"2021-02-03T12:55:47Z" + }, + { + "tagName":"v1.3.2", + "name":"Release v1.3.2 \uD83C\uDF08", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.3.2", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Add support for an onSubmit action in the input widget (#2749)
  • \n
  • A brand new Login and Signup page. (#2743, #2696)
  • \n
  • Support for navigateTo function to open in a new window (#2706)
  • \n
  • Trigger onPageSizeChange action when table page size changes (#2737)
  • \n
  • Scheduling of parallel tasks during on-page load actions (#2667)
  • \n
  • Improve performance by batching widget property updates (#2685)
  • \n
  • Remove zebra stripes in the table (#2552)
  • \n
  • Improve the message regarding telemetry during installation (#2621)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Fix reference type fields in Firestore throwing 500 (#2718)
  • \n
  • Fix: App name UI in edit and deploy mode (#2216)
  • \n
  • Fix: In the datasources page, do not show sections that are supposed to be hidden (#2746)
  • \n
  • Fix: Improved error messages across the board (#2583, #2705)
  • \n
  • Fix: Binding to the datasource shows appropriate value instead of a complete object in the entity explorer (#2480)
  • \n
  • Fix: Hover highlight in entity explorer should be edge-to-edge (#2478)
  • \n
  • Fix: Organization slug computation clashes (#2725)
  • \n
  • Fix: Application crash on widget delete undo (#2741)
  • \n
  • Fix: Multiple fixes for greater stability of the Appsmith platform (#2681, #2704, #2719, #2730, #2547)
  • \n
  • Fix: Disable sort by Delete column in Members page (#2722)
  • \n
  • Fix: Timeout for an action being set incorrectly view mode (#2708)
  • \n
  • Fix: Show table row cursor as a pointer when onRowSelect property is configured (#2604)
  • \n
  • Fix: Table widget filter for boolean values (#2586)
  • \n
  • Fix: Hide table filters delete icon when there are no filters (#2605)
  • \n
  • Fix: Table cell tooltip should show inside table widget (#2629)
  • \n
  • Fix: Reset column resizes when sorting column in publish mode (#2578)
  • \n
  • Fix: Show table columns in selectedRow autocomplete irrespective of table row selection (#2603)
  • \n
  • Fix: Update initial location in map widget when changed from the property pane (#2736)
  • \n
", + "publishedAt":"2021-01-28T13:09:55Z" + }, + { + "tagName":"v1.3.1", + "name":"Release v1.3.1 \uD83C\uDF08", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.3.1", + "descriptionHtml":"

What's new?

\n

This is a patch release with bug fixes.

\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Remove functions from Eval Action bindings task returning from the worker (#2679)
  • \n
  • Fix calls to release notes from cloud instances (#2680)
  • \n
  • Fix deleted actions sometimes showing up in edit mode (#2678)
  • \n
  • Fix styling of product updates modal (#2646, #2668)
  • \n
", + "publishedAt":"2021-01-22T09:41:11Z" + }, + { + "tagName":"v1.3", + "name":"Release v1.3 \uD83C\uDF08", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.3", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Fetch release notes for caching every two hours (#2657)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • Scroll to the appropriate section on the home page after creating an organization (#2477)
  • \n
  • Improved error messages when displaying any action execution errors (#2635)
  • \n
  • Bump jackson-databind from 2.9.10.5 to 2.9.10.7 in /app/server/appsmith-interfaces (#2652)
  • \n
  • Add a migration to fix any remembered versions for release notes (#2651)
  • \n
  • Fix application versionioning scheme on self-hosted instances (#2650)
  • \n
", + "publishedAt":"2021-01-21T12:54:31Z" + }, + { + "tagName":"v1.2.25", + "name":"Release v1.2.25 \uD83C\uDF08", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.2.25", + "descriptionHtml":"

What's new?

\n

\uD83D\uDE80 Features

\n
    \n
  • Product updates and display of version number in Appsmith (#2200, #2453, #2631)
  • \n
  • Redshift integration (#2440)
  • \n
  • Copy text function called (surprise!) copyToClipboard (#2379, #2394)
  • \n
  • Vastly improved performance by batching action evaluation calls (#2537, #2517, #2561, #2579)
  • \n
  • Improved onboarding experience (#2458, #2490, #2549)
  • \n
  • Performance improvements with async form field controls (#2491)
  • \n
  • Ability to disable uninvited signups via environment variable (#2512, #2520)
  • \n
  • Auto focus input field when creating a new organization (#2303, #2493)
  • \n
\n

\uD83D\uDC1B Bug Fixes

\n
    \n
  • [Fix] 502 in save layout is abruptly taking me to an error screen (#2475)
  • \n
  • [Fix] Authentication after 404 not redirecting back to the original page (#2423)
  • \n
  • [Fix] Race conditions with the file picker and rich text editor widgets (#2616, #2620, #2622)
  • \n
  • [Fix] Overflow issues with the dropdown widget (#2628)
  • \n
  • [Fix] Crash in map widget (#2347, #2488)
  • \n
  • [Fix] Data field in chart widget showing error by default only for the latest data series (#2599, #2613)
  • \n
  • [Fix] First tab of TabsWidget not loading (#2541, #2538)
  • \n
  • [Fix] Bug with pagination when next url is empty (#2424, #2546)
  • \n
  • [Fix] When an application name is changed, the isPublic flag is reset to false (#2539)
  • \n
  • [Fix] Data inconsistency when action is marked for onPageLoad (#2522, #2523)
  • \n
  • [Fix] When switching to another page, previous page widgets were visible for a fraction of a second (#2516)
  • \n
  • [Fix] Table selected row is set to undefined on mount (#2518)
  • \n
  • [Fix] Potential bad state when datasource information becomes stale on the client (#2164, #2167)
  • \n
  • [Fix] Actions don’t run on page load if result is not bound to a widget (#2217, #2434)
  • \n
  • [Fix] Scroll problems on Edge (#2431, #2456)
  • \n
", + "publishedAt":"2021-01-20T11:49:45Z" + }, + { + "tagName":"v1.2.15", + "name":"Release v1.2.15", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.2.15", + "descriptionHtml":"", + "publishedAt":"2020-11-11T08:48:03Z" + }, + { + "tagName":"v1.2.1", + "name":"Release v1.2.1", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.2.1", + "descriptionHtml":"", + "publishedAt":"2020-08-24T14:38:30Z" + }, + { + "tagName":"v1.0", + "name":"Release v1.0", + "url":"https://github.com/appsmithorg/appsmith-ee/releases/tag/v1.0", + "descriptionHtml":"", + "publishedAt":"2020-08-17T12:13:55Z" + } + ] + } + } \ No newline at end of file diff --git a/app/taro/src/mockResponses/CommentApiMockResponse.tsx b/app/taro/src/mockResponses/CommentApiMockResponse.tsx new file mode 100644 index 0000000000..5d6db2f186 --- /dev/null +++ b/app/taro/src/mockResponses/CommentApiMockResponse.tsx @@ -0,0 +1,365 @@ +export const addCommentToThreadMockResponse = { + responseMeta: { + status: 201, + success: true, + }, + data: { + id: "6063904791dea93f0eaf91d9", + userPermissions: [], + body: { + blocks: [ + { + key: "9b3or", + text: "new", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, +}; + +export const createNewThreadMockResponse = { + responseMeta: { + status: 201, + success: true, + }, + data: { + id: "60636f0591dea93f0eaf91d5", + userPermissions: [], + position: { + topPercent: 10.0, + leftPercent: 72.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "60636f0591dea93f0eaf91d6", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, +}; + +export const fetchApplicationThreadsMockResponse = { + responseMeta: { + status: 200, + success: true, + }, + data: [ + { + id: "605c436591dea93f0eaf91bb", + userPermissions: [], + position: { + topPercent: 7.0, + leftPercent: 13.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "605c436591dea93f0eaf91bc", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + { + id: "605c444c91dea93f0eaf91bd", + userPermissions: [], + position: { + topPercent: 9.0, + leftPercent: 7.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "605c444c91dea93f0eaf91be", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + { + id: "605c519391dea93f0eaf91bf", + userPermissions: [], + position: { + topPercent: 2.0, + leftPercent: 18.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "605c519391dea93f0eaf91c0", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + { + id: "605c519c91dea93f0eaf91c1", + userPermissions: [], + position: { + topPercent: 1.0, + leftPercent: 23.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "605c519c91dea93f0eaf91c2", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + { + id: "605c51b191dea93f0eaf91c3", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + { + id: "605c51e891dea93f0eaf91c4", + userPermissions: [], + position: { + topPercent: 2.0, + leftPercent: 28.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "605c51e891dea93f0eaf91c5", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + { + id: "605c53b491dea93f0eaf91c6", + userPermissions: [], + position: { + topPercent: 2.0, + leftPercent: 33.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "605c53b491dea93f0eaf91c7", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + { + id: "605cb30c91dea93f0eaf91cb", + userPermissions: [], + position: { + topPercent: 1.0, + leftPercent: 3.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "605cb30c91dea93f0eaf91cc", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + { + id: "6060c45e91dea93f0eaf91ce", + userPermissions: [], + position: { + topPercent: 5.0, + leftPercent: 41.0, + }, + refId: "0", + applicationId: "605c435a91dea93f0eaf91b8", + comments: [ + { + id: "6060c45e91dea93f0eaf91cf", + userPermissions: [], + body: { + blocks: [ + { + key: "6bfm4", + text: "asdf", + type: "unstyled", + depth: 0, + inlineStyleRanges: [], + entityRanges: [], + data: {}, + }, + ], + entityMap: {}, + }, + new: false, + }, + ], + new: false, + }, + ], +}; + +export const fetchPagesMockResponse = { + responseMeta: { + status: 200, + success: true, + }, + data: { + organizationId: "605c433c91dea93f0eaf91b5", + pages: [ + { + id: "605c435a91dea93f0eaf91ba", + name: "Page1", + isDefault: true, + }, + ], + }, +}; diff --git a/app/taro/src/mockResponses/CreateOrganisationMockResponse.json b/app/taro/src/mockResponses/CreateOrganisationMockResponse.json new file mode 100644 index 0000000000..e0d5077d0e --- /dev/null +++ b/app/taro/src/mockResponses/CreateOrganisationMockResponse.json @@ -0,0 +1,115 @@ +{ + "responseMeta":{ + "status":201, + "success":true + }, + "data":{ + "id":"6065e4b7034ece74b1481819", + "userPermissions":[ + + ], + "name":"new org", + "email":"b1@appsmith.com", + "plugins":[ + { + "userPermissions":[ + + ], + "pluginId":"5ca385dc81b37f0004b4db85", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5e8dad9bf062d5125ddfd836", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5ec3bccdd4b5eaa50ba6f583", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5ec3bcf1d4b5eaa50ba6f593", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f192a44a2d05225d010db9d", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9e9107018510ae540be", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9ec107018510ae540c0", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9ef107018510ae540c3", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5f92f9f1107018510ae540c5", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"5fbcc1c758377818ddaec444", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"60081f50ffab735a9dae84e7", + "status":"FREE", + "new":true + }, + { + "userPermissions":[ + + ], + "pluginId":"60374b7d074f9b49cd68a036", + "status":"FREE", + "new":true + } + ], + "slug":"new-org5", + "logoUrl":"/api/v1/assets/null", + "new":false + } +} \ No newline at end of file diff --git a/app/taro/src/mockResponses/PageMockResponse.tsx b/app/taro/src/mockResponses/PageMockResponse.tsx new file mode 100644 index 0000000000..1c8aa0744b --- /dev/null +++ b/app/taro/src/mockResponses/PageMockResponse.tsx @@ -0,0 +1,58 @@ +import { FetchPageResponse } from "api/PageApi"; +import { generateReactKey } from "utils/generators"; +import { WidgetType } from "constants/WidgetConstants"; +import { PluginType } from "entities/Action"; + +const PageMockResponse: FetchPageResponse = { + responseMeta: { + status: 200, + success: true, + }, + data: { + id: generateReactKey(), + applicationId: generateReactKey(), + name: "Mock Page", + layouts: [ + { + id: generateReactKey(), + dsl: { + widgetId: "0", + type: "CONTAINER_WIDGET" as WidgetType, + topRow: 2, + leftColumn: 2, + rightColumn: 10, + bottomRow: 10, + children: [ + { + widgetId: "1", + type: "BUTTON_WIDGET" as WidgetType, + topRow: 2, + leftColumn: 2, + text: "submit", + rightColumn: 10, + bottomRow: 10, + onClick: [ + { + actionId: "5d8082e2795dc6000482bc84", + actionType: "API", + }, + ], + }, + ], + }, + layoutActions: [ + { + id: "5d8082e2795dc6000482bc84", + name: "someActions", + jsonPathKeys: [], + pluginType: PluginType.API, + timeoutInMillisecond: 10000, + }, + ], + layoutOnLoadActions: [], + }, + ], + }, +}; + +export default PageMockResponse; diff --git a/app/taro/src/mockResponses/WidgetConfigResponse.tsx b/app/taro/src/mockResponses/WidgetConfigResponse.tsx new file mode 100644 index 0000000000..4c1c37d753 --- /dev/null +++ b/app/taro/src/mockResponses/WidgetConfigResponse.tsx @@ -0,0 +1,446 @@ +import { WidgetConfigReducerState } from "reducers/entityReducers/widgetConfigReducer"; +import { WidgetTypes } from "constants/WidgetConstants"; +import { Colors } from "constants/Colors"; + +/* + ********************************{Grid Density Migration}********************************* + */ +export const GRID_DENSITY_MIGRATION_V1 = 4; + +/** + * this config sets the default values of properties being used in the widget + */ +const WidgetConfigResponse: WidgetConfigReducerState = { + config: { + CONTAINER_WIDGET: { + backgroundColor: "#FFFFFF", + rows: 10 * GRID_DENSITY_MIGRATION_V1, + columns: 8 * GRID_DENSITY_MIGRATION_V1, + widgetName: "Container", + containerStyle: "card", + children: [], + blueprint: { + view: [ + { + type: "CANVAS_WIDGET", + position: { top: 0, left: 0 }, + props: { + containerStyle: "none", + canExtend: false, + detachFromLayout: true, + children: [], + }, + }, + ], + }, + version: 1, + }, + CANVAS_WIDGET: { + rows: 0, + columns: 0, + widgetName: "Canvas", + version: 1, + }, + [WidgetTypes.TARO_PICKER_WIDGET]: { + widgetName: "m_picker", + rows: 2 * GRID_DENSITY_MIGRATION_V1, + columns: 4 * GRID_DENSITY_MIGRATION_V1, + title: "喵喵", + }, + [WidgetTypes.TARO_SWIPER_WIDGET]: { + widgetName: "m_swiper", + rows: 6 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + list: [ + { url: "https://img01.yzcdn.cn/vant/apple-1.jpg" }, + { url: "https://img01.yzcdn.cn/vant/apple-2.jpg" }, + { url: "https://img01.yzcdn.cn/vant/apple-3.jpg" }, + { url: "https://img01.yzcdn.cn/vant/apple-4.jpg" }, + ], + urlKey: "url", + }, + [WidgetTypes.TARO_GRID_WIDGET]: { + widgetName: "m_grid", + rows: 6 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + list: [ + { url: "", name: "文本" }, + { url: "", name: "文本" }, + { url: "", name: "文本" }, + { url: "", name: "文本" }, + { url: "", name: "文本" }, + { url: "", name: "文本" }, + ], + urlKey: "url", + titleKey: "name", + cols: 4, + gutter: "0", + bordered: true, + gridType: "I_N", + titleColor: "#646566", + descriptionColor: "#DD4B34", + buttonColor: "#03b365", + priceUnit: "¥", + }, + [WidgetTypes.TARO_TEXT_WIDGET]: { + widgetName: "m_text", + text: "文本", + fontSize: "PARAGRAPH", + textAlign: "LEFT", + textColor: Colors.THUNDER, + rows: 1 * GRID_DENSITY_MIGRATION_V1, + columns: 4 * GRID_DENSITY_MIGRATION_V1, + version: 1, + }, + [WidgetTypes.TARO_LIST_WIDGET]: { + widgetName: "m_list", + rows: 6 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + list: [ + { url: "", name: "标题", description: "描述" }, + { url: "", name: "标题", description: "描述" }, + { url: "", name: "标题", description: "描述" }, + { url: "", name: "标题", description: "描述" }, + ], + urlKey: "url", + titleKey: "name", + descriptionKey: "description", + contentType: "I_N_D", + controlType: "BUTTON", + width: "100px", + height: "80px", + inset: false, + titleColor: "#646566", + descriptionColor: "#999", + priceColor: "#DD4B34", + buttonColor: "#03b365", + }, + [WidgetTypes.TARO_POPUP_WIDGET]: { + widgetName: "m_popup", + rows: 10 * GRID_DENSITY_MIGRATION_V1, + columns: 16 * GRID_DENSITY_MIGRATION_V1, + // detachFromLayout is set true for widgets that are not bound to the widgets within the layout. + // setting it to true will only render the widgets(from sidebar) on the main container without any collision check. + detachFromLayout: true, + canOutsideClickClose: true, + rounded: true, + height: 400, + children: [], + version: 1, + blueprint: { + view: [ + { + type: "CANVAS_WIDGET", + position: { left: 0, top: 0 }, + props: { + detachFromLayout: true, + canExtend: false, + isVisible: true, + isDisabled: false, + shouldScrollContents: false, + children: [], + version: 1, + }, + }, + ], + }, + }, + [WidgetTypes.TARO_IMAGE_WIDGET]: { + widgetName: "m_image", + rows: 6 * GRID_DENSITY_MIGRATION_V1, + columns: 8 * GRID_DENSITY_MIGRATION_V1, + src: "https://img.yzcdn.cn/vant/cat.jpeg", + mode: "aspectFit", + version: 1, + }, + [WidgetTypes.TARO_BUTTON_WIDGET]: { + widgetName: "m_button", + rows: 1 * GRID_DENSITY_MIGRATION_V1, + columns: 6 * GRID_DENSITY_MIGRATION_V1, + version: 1, + rounded: true, + text: "好的", + fontSize: "16px", + showLoading: true, + }, + [WidgetTypes.TARO_CELL_WIDGET]: { + widgetName: "m_cell", + rows: 3 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + version: 1, + inset: false, + bordered: false, + cellsObj: { + cell1: { + label: "单元格 1", + id: "cell1", + widgetId: "", + isVisible: true, + picType: "none", + showArrow: true, + index: 0, + }, + cell2: { + label: "单元格 2", + id: "cell2", + widgetId: "", + isVisible: true, + picType: "none", + showArrow: true, + index: 1, + }, + }, + }, + [WidgetTypes.TARO_HTML_WIDGET]: { + widgetName: "m_html", + rows: 6 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + content: + "

恭喜发财 大吉大利

", + version: 1, + }, + [WidgetTypes.TARO_SKU_WIDGET]: { + widgetName: "m_sku", + rows: 8 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + version: 1, + goodsId: "10010", + price: 399, + pic: "https://b.yzcdn.cn/vant/sku/shoes-1.png", + stockNum: 999, + categories: [ + { + name: "颜色", + key: "color", + values: [ + { + id: "1", + name: "粉色", + pic: "https://b.yzcdn.cn/vant/sku/shoes-1.png", + }, + { + id: "2", + name: "黄色", + pic: "https://b.yzcdn.cn/vant/sku/shoes-2.png", + }, + { + id: "3", + name: "蓝色", + pic: "https://b.yzcdn.cn/vant/sku/shoes-3.png", + }, + ], + }, + { + name: "尺寸", + key: "size", + values: [ + { + id: "1", + name: "大", + }, + { + id: "2", + name: "小", + }, + ], + }, + ], + products: [ + { + id: "2259", + category: { + color: "2", + size: "1", + }, + price: 100, + stock: 110, + }, + { + id: "2260", + category: { + color: "3", + size: "1", + }, + price: 100, + stock: 99, + }, + { + id: "2257", + category: { + color: "1", + size: "1", + }, + price: 100, + stock: 111, + }, + { + id: "2258", + category: { + color: "1", + size: "2", + }, + price: 100, + stock: 6, + }, + ], + color: "#f44336", + }, + [WidgetTypes.TARO_KV_WIDGET]: { + widgetName: "m_kv", + rows: 6 * GRID_DENSITY_MIGRATION_V1, + columns: 12 * GRID_DENSITY_MIGRATION_V1, + version: 1, + list: [ + { key: "绿蚁新醅酒", value: "红泥小火炉" }, + { key: "晚来天欲雪", value: "能饮一杯无" }, + ], + kKey: "key", + vKey: "value", + layout: "h", + inset: false, + kColor: "#666", + kSize: "PARAGRAPH", + kBold: false, + kAlign: "LEFT", + vColor: "#333", + vSize: "PARAGRAPH", + vBold: true, + vAlign: "LEFT", + }, + [WidgetTypes.TARO_TABS_WIDGET]: { + widgetName: "m_tabs", + rows: 10 * GRID_DENSITY_MIGRATION_V1, + columns: 4 * GRID_DENSITY_MIGRATION_V1, + version: 1, + list: [ + { name: "标签1", id: 1 }, + { name: "标签2", id: 2 }, + { name: "标签3", id: 3 }, + ], + nameKey: "name", + defaultNum: "0", + showLoading: false, + }, + [WidgetTypes.TARO_BOTTOM_BAR_WIDGET]: { + widgetName: "m_bottom_bar", + rows: 3 * GRID_DENSITY_MIGRATION_V1, + columns: 16 * GRID_DENSITY_MIGRATION_V1, + // detachFromLayout is set true for widgets that are not bound to the widgets within the layout. + // setting it to true will only render the widgets(from sidebar) on the main container without any collision check. + detachFromLayout: true, + canOutsideClickClose: true, + height: 100, + children: [], + version: 1, + blueprint: { + view: [ + { + type: "CANVAS_WIDGET", + position: { left: 0, top: 0 }, + props: { + detachFromLayout: true, + canExtend: false, + isVisible: true, + isDisabled: false, + shouldScrollContents: false, + children: [], + version: 1, + }, + }, + ], + }, + }, + [WidgetTypes.TARO_ACTION_BAR_WIDGET]: { + widgetName: "m_action_bar", + rows: 2 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + version: 1, + actionsObj: { + action1: { + label: "购物车", + id: "action1", + widgetId: "", + index: 0, + type: "icon", + badge: "6", + icon: "cart-o", + }, + action2: { + label: "加入购物车", + id: "action2", + widgetId: "", + index: 1, + type: "button", + buttonType: "warning", + }, + action3: { + label: "立即购买", + id: "action3", + widgetId: "", + index: 2, + type: "button", + buttonType: "danger", + }, + }, + }, + [WidgetTypes.TARO_SEARCH_WIDGET]: { + widgetName: "m_search", + rows: 2 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + version: 1, + rounded: true, + readonly: false, + showButton: false, + inputAlign: "left", + }, + [WidgetTypes.TARO_LOADING_WIDGET]: { + widgetName: "m_loading", + rows: 2 * GRID_DENSITY_MIGRATION_V1, + columns: 4 * GRID_DENSITY_MIGRATION_V1, + version: 1, + detachFromLayout: true, + showLoading: false, + }, + [WidgetTypes.TARO_CHECKBOX_WIDGET]: { + widgetName: "m_checkbox", + rows: 1 * GRID_DENSITY_MIGRATION_V1, + columns: 4 * GRID_DENSITY_MIGRATION_V1, + version: 1, + label: "勾选", + defaultCheckedState: true, + isDisabled: false, + showLoading: false, + }, + [WidgetTypes.TARO_FORM_WIDGET]: { + widgetName: "m_form", + rows: 6 * GRID_DENSITY_MIGRATION_V1, + columns: 14 * GRID_DENSITY_MIGRATION_V1, + version: 1, + fieldsObj: { + user: { + label: "用户名", + id: "user", + name: "user", + widgetId: "", + fieldType: "input", + required: true, + inputType: "text", + index: 0, + }, + password: { + label: "密码", + id: "password", + name: "password", + widgetId: "", + fieldType: "input", + required: true, + inputType: "password", + index: 1, + }, + }, + }, + }, + configVersion: 1, +}; + +export default WidgetConfigResponse; diff --git a/app/taro/src/normalizers/CanvasWidgetsNormalizer.tsx b/app/taro/src/normalizers/CanvasWidgetsNormalizer.tsx new file mode 100644 index 0000000000..65fbdfb0c7 --- /dev/null +++ b/app/taro/src/normalizers/CanvasWidgetsNormalizer.tsx @@ -0,0 +1,27 @@ +import { normalize, schema, denormalize } from "normalizr"; +import { WidgetProps } from "widgets/BaseWidget"; +import { ContainerWidgetProps } from "widgets/ContainerWidget"; + +export const widgetSchema = new schema.Entity( + "canvasWidgets", + {}, + { idAttribute: "widgetId" }, +); +widgetSchema.define({ children: [widgetSchema] }); + +class CanvasWidgetsNormalizer { + static normalize( + dsl: Partial>, + ): { entities: any; result: any } { + return normalize(dsl, widgetSchema); + } + + static denormalize( + pageWidgetId: string, + entities: any, + ): ContainerWidgetProps { + return denormalize(pageWidgetId, widgetSchema, entities); + } +} + +export default CanvasWidgetsNormalizer; diff --git a/app/taro/src/pages/index/index.config.ts b/app/taro/src/pages/index/index.config.ts new file mode 100644 index 0000000000..32272c17d2 --- /dev/null +++ b/app/taro/src/pages/index/index.config.ts @@ -0,0 +1,3 @@ +export default { + navigationBarTitleText: 'PagePlug' +} diff --git a/app/taro/src/pages/index/index.less b/app/taro/src/pages/index/index.less new file mode 100644 index 0000000000..8b13789179 --- /dev/null +++ b/app/taro/src/pages/index/index.less @@ -0,0 +1 @@ + diff --git a/app/taro/src/pages/index/index.tsx b/app/taro/src/pages/index/index.tsx new file mode 100644 index 0000000000..ffc9ac3c63 --- /dev/null +++ b/app/taro/src/pages/index/index.tsx @@ -0,0 +1,4 @@ +import React from "react"; +import PageComponent from "components/common/PageFactory"; + +export default PageComponent; diff --git a/app/taro/src/pages/page1/index.config.ts b/app/taro/src/pages/page1/index.config.ts new file mode 100644 index 0000000000..32272c17d2 --- /dev/null +++ b/app/taro/src/pages/page1/index.config.ts @@ -0,0 +1,3 @@ +export default { + navigationBarTitleText: 'PagePlug' +} diff --git a/app/taro/src/pages/page1/index.less b/app/taro/src/pages/page1/index.less new file mode 100644 index 0000000000..8b13789179 --- /dev/null +++ b/app/taro/src/pages/page1/index.less @@ -0,0 +1 @@ + diff --git a/app/taro/src/pages/page1/index.tsx b/app/taro/src/pages/page1/index.tsx new file mode 100644 index 0000000000..ffc9ac3c63 --- /dev/null +++ b/app/taro/src/pages/page1/index.tsx @@ -0,0 +1,4 @@ +import React from "react"; +import PageComponent from "components/common/PageFactory"; + +export default PageComponent; diff --git a/app/taro/src/reducers/entityReducers/actionsReducer.tsx b/app/taro/src/reducers/entityReducers/actionsReducer.tsx new file mode 100644 index 0000000000..86adba10c4 --- /dev/null +++ b/app/taro/src/reducers/entityReducers/actionsReducer.tsx @@ -0,0 +1,372 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxActionTypes, + ReduxAction, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; +import { ActionResponse } from "api/ActionAPI"; +import { ExecuteErrorPayload } from "constants/AppsmithActionConstants/ActionConstants"; +import _ from "lodash"; +import { Action } from "entities/Action"; +import { UpdateActionPropertyActionPayload } from "actions/actionActions"; +import produce from "immer"; + +export interface ActionData { + isLoading: boolean; + config: Action; + data?: ActionResponse; +} + +export interface ActionDataWithMeta extends ActionData { + responseMeta: { + headers?: unknown; + isExecutionSuccess: boolean; + statusCode?: string; + }; +} + +export type ActionDataState = ActionData[]; +export interface PartialActionData { + isLoading: boolean; + config: { id: string }; + data?: ActionResponse; +} + +const initialState: ActionDataState = []; + +const actionsReducer = createReducer(initialState, { + [ReduxActionTypes.FETCH_ACTIONS_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => { + return action.payload.map((action) => { + const foundAction = state.find((currentAction) => { + return currentAction.config.id === action.id; + }); + return { + isLoading: false, + config: action, + data: foundAction?.data, + }; + }); + }, + [ReduxActionTypes.FETCH_ACTIONS_VIEW_MODE_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => + action.payload.map((a) => ({ + isLoading: false, + config: a, + })), + [ReduxActionTypes.FETCH_ACTIONS_FOR_PAGE_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => { + if (action.payload.length > 0) { + const stateActionMap = _.keyBy(state, "config.id"); + const result: ActionDataState = []; + + action.payload.forEach((actionPayload: Action) => { + const stateAction = stateActionMap[actionPayload.id]; + if (stateAction) { + result.push({ + data: stateAction.data, + isLoading: false, + config: actionPayload, + }); + + delete stateActionMap[actionPayload.id]; + } else { + result.push({ + isLoading: false, + config: actionPayload, + }); + } + }); + + Object.keys(stateActionMap).forEach((stateActionKey) => { + result.push(stateActionMap[stateActionKey]); + }); + + return result; + } + return state; + }, + [ReduxActionTypes.SUBMIT_CURL_FORM_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction, + ) => state.concat([{ config: action.payload, isLoading: false }]), + [ReduxActionErrorTypes.FETCH_ACTIONS_ERROR]: () => initialState, + [ReduxActionErrorTypes.FETCH_ACTIONS_VIEW_MODE_ERROR]: () => initialState, + [ReduxActionTypes.CREATE_ACTION_INIT]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => + state.concat([ + { + config: { ...action.payload, id: action.payload.name }, + isLoading: false, + }, + ]), + [ReduxActionTypes.CREATE_ACTION_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => + state.map((a) => { + if ( + a.config.pageId === action.payload.pageId && + a.config.id === action.payload.name + ) { + return { ...a, config: action.payload }; + } + return a; + }), + [ReduxActionErrorTypes.CREATE_ACTION_ERROR]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => + state.filter( + (a) => + a.config.name !== action.payload.name && + a.config.id !== action.payload.name, + ), + [ReduxActionTypes.UPDATE_ACTION_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction<{ data: Action }>, + ): ActionDataState => + state.map((a) => { + if (a.config.id === action.payload.data.id) + return { ...a, config: action.payload.data }; + return a; + }), + [ReduxActionTypes.UPDATE_ACTION_PROPERTY]: ( + state: ActionDataState, + action: ReduxAction, + ) => + state.map((a) => { + if (a.config.id === action.payload.id) { + return _.set(a, `config.${action.payload.field}`, action.payload.value); + } + return a; + }), + [ReduxActionTypes.DELETE_ACTION_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction<{ id: string }>, + ): ActionDataState => state.filter((a) => a.config.id !== action.payload.id), + [ReduxActionTypes.EXECUTE_API_ACTION_REQUEST]: ( + state: ActionDataState, + action: ReduxAction<{ id: string }>, + ): ActionDataState => + state.map((a) => { + if (a.config.id === action.payload.id) { + return { + ...a, + isLoading: true, + }; + } + return a; + }), + [ReduxActionTypes.EXECUTE_API_ACTION_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction<{ id: string; response: ActionResponse }>, + ): PartialActionData[] => { + const foundAction = state.find((stateAction) => { + return stateAction.config.id === action.payload.id; + }); + if (foundAction) { + return state.map((stateAction) => { + if (stateAction.config.id === action.payload.id) { + return { + ...stateAction, + isLoading: false, + data: action.payload.response, + }; + } + return stateAction; + }); + } else { + const partialAction: PartialActionData = { + isLoading: false, + config: { id: action.payload.id }, + data: action.payload.response, + }; + return [...state, partialAction]; + } + }, + [ReduxActionErrorTypes.EXECUTE_ACTION_ERROR]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => + state.map((a) => { + if (a.config.id === action.payload.actionId) { + return { ...a, isLoading: false, data: action.payload.data }; + } + return a; + }), + [ReduxActionTypes.RUN_ACTION_REQUEST]: ( + state: ActionDataState, + action: ReduxAction<{ id: string }>, + ): ActionDataState => + state.map((a) => { + if (action.payload.id === a.config.id) { + return { + ...a, + isLoading: true, + }; + } + + return a; + }), + [ReduxActionTypes.RUN_ACTION_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction<{ [id: string]: ActionResponse }>, + ): ActionDataState => { + const actionId = Object.keys(action.payload)[0]; + return state.map((a) => { + if (a.config.id === actionId) { + return { ...a, isLoading: false, data: action.payload[actionId] }; + } + return a; + }); + }, + [ReduxActionErrorTypes.RUN_ACTION_ERROR]: ( + state: ActionDataState, + action: ReduxAction<{ id: string }>, + ): ActionDataState => + state.map((a) => { + if (a.config.id === action.payload.id) { + return { ...a, isLoading: false }; + } + + return a; + }), + [ReduxActionTypes.MOVE_ACTION_INIT]: ( + state: ActionDataState, + action: ReduxAction<{ + id: string; + destinationPageId: string; + name: string; + }>, + ): ActionDataState => + state.map((a) => { + if (a.config.id === action.payload.id) { + return { + ...a, + config: { + ...a.config, + name: action.payload.name, + pageId: action.payload.destinationPageId, + }, + }; + } + + return a; + }), + [ReduxActionTypes.MOVE_ACTION_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => + state.map((a) => { + if (a.config.id === action.payload.id) { + return { ...a, config: action.payload }; + } + + return a; + }), + [ReduxActionErrorTypes.MOVE_ACTION_ERROR]: ( + state: ActionDataState, + action: ReduxAction<{ id: string; originalPageId: string }>, + ): ActionDataState => + state.map((a) => { + if (a.config.id === action.payload.id) { + return { + ...a, + config: { + ...a.config, + pageId: action.payload.originalPageId, + }, + }; + } + + return a; + }), + [ReduxActionTypes.COPY_ACTION_INIT]: ( + state: ActionDataState, + action: ReduxAction<{ + id: string; + destinationPageId: string; + name: string; + }>, + ): ActionDataState => + state.concat( + state + .filter((a) => a.config.id === action.payload.id) + .map((a) => ({ + ...a, + data: undefined, + config: { + ...a.config, + id: "TEMP_COPY_ID", + name: action.payload.name, + pageId: action.payload.destinationPageId, + }, + })), + ), + [ReduxActionTypes.COPY_ACTION_SUCCESS]: ( + state: ActionDataState, + action: ReduxAction, + ): ActionDataState => + state.map((a) => { + if ( + a.config.pageId === action.payload.pageId && + a.config.name === action.payload.name + ) { + return { + ...a, + config: action.payload, + }; + } + + return a; + }), + [ReduxActionErrorTypes.COPY_ACTION_ERROR]: ( + state: ActionDataState, + action: ReduxAction<{ + id: string; + destinationPageId: string; + name: string; + }>, + ): ActionDataState => + state.filter((a) => { + if (a.config.pageId === action.payload.destinationPageId) { + if (a.config.id === action.payload.id) { + return a.config.name !== action.payload.name; + } + return true; + } + + return true; + }), + [ReduxActionTypes.SET_ACTION_TO_EXECUTE_ON_PAGELOAD]: ( + state: ActionDataState, + action: ReduxAction< + Array<{ + executeOnLoad: boolean; + id: string; + name: string; + }> + >, + ) => { + return produce(state, (draft) => { + const actionUpdateSearch = _.keyBy(action.payload, "id"); + draft.forEach((action, index) => { + if (action.config.id in actionUpdateSearch) { + draft[index].config.executeOnLoad = + actionUpdateSearch[action.config.id].executeOnLoad; + } + }); + }); + }, +}); + +export default actionsReducer; diff --git a/app/taro/src/reducers/entityReducers/appReducer.ts b/app/taro/src/reducers/entityReducers/appReducer.ts new file mode 100644 index 0000000000..7bd35b6d64 --- /dev/null +++ b/app/taro/src/reducers/entityReducers/appReducer.ts @@ -0,0 +1,101 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { User } from "constants/userConstants"; +import { APP_MODE } from "entities/App"; + +export type AuthUserState = { + username: string; + email: string; + id: string; +}; + +export type UrlDataState = { + queryParams: Record; + applicationId: string; + pageId: string; +}; + +export type AppStoreState = { + transient: Record; + persistent: Record; +}; + +export type AppDataState = { + mode?: APP_MODE; + user: AuthUserState; + URL: UrlDataState; + store: AppStoreState; +}; + +const initialState: AppDataState = { + user: { + username: "", + email: "", + id: "", + }, + URL: { + queryParams: {}, + applicationId: "", + pageId: "", + }, + store: { + transient: {}, + persistent: {}, + }, +}; + +const appReducer = createReducer(initialState, { + [ReduxActionTypes.SET_APP_MODE]: ( + state: AppDataState, + action: ReduxAction, + ) => { + return { + ...state, + mode: action.payload, + }; + }, + [ReduxActionTypes.FETCH_USER_DETAILS_SUCCESS]: ( + state: AppDataState, + action: ReduxAction, + ) => { + return { + ...state, + user: action.payload, + }; + }, + [ReduxActionTypes.SET_URL_DATA]: ( + state: AppDataState, + action: ReduxAction, + ) => { + return { + ...state, + URL: action.payload, + }; + }, + [ReduxActionTypes.UPDATE_APP_TRANSIENT_STORE]: ( + state: AppDataState, + action: ReduxAction>, + ) => { + return { + ...state, + store: { + ...state.store, + transient: action.payload, + }, + }; + }, + [ReduxActionTypes.UPDATE_APP_PERSISTENT_STORE]: ( + state: AppDataState, + action: ReduxAction>, + ) => { + return { + ...state, + store: { + ...state.store, + persistent: action.payload, + }, + }; + }, +}); + +export default appReducer; diff --git a/app/taro/src/reducers/entityReducers/canvasWidgetsReducer.tsx b/app/taro/src/reducers/entityReducers/canvasWidgetsReducer.tsx new file mode 100644 index 0000000000..aeece8e481 --- /dev/null +++ b/app/taro/src/reducers/entityReducers/canvasWidgetsReducer.tsx @@ -0,0 +1,44 @@ +import { createImmerReducer } from "utils/AppsmithUtils"; +import { + ReduxActionTypes, + UpdateCanvasPayload, + ReduxAction, +} from "constants/ReduxActionConstants"; +import { WidgetProps } from "widgets/BaseWidget"; +import { UpdateCanvasLayout } from "actions/controlActions"; +import { set } from "lodash"; +import { MAIN_CONTAINER_WIDGET_ID } from "constants/WidgetConstants"; + +const initialState: CanvasWidgetsReduxState = {}; + +export type FlattenedWidgetProps = WidgetProps & { + children?: string[]; +}; + +const canvasWidgetsReducer = createImmerReducer(initialState, { + [ReduxActionTypes.INIT_CANVAS_LAYOUT]: ( + state: CanvasWidgetsReduxState, + action: ReduxAction, + ) => { + return action.payload.widgets; + }, + [ReduxActionTypes.UPDATE_LAYOUT]: ( + state: CanvasWidgetsReduxState, + action: ReduxAction, + ) => { + return action.payload.widgets; + }, + [ReduxActionTypes.UPDATE_CANVAS_LAYOUT]: ( + state: CanvasWidgetsReduxState, + action: ReduxAction, + ) => { + set(state[MAIN_CONTAINER_WIDGET_ID], "rightColumn", action.payload.width); + set(state[MAIN_CONTAINER_WIDGET_ID], "minHeight", action.payload.height); + }, +}); + +export interface CanvasWidgetsReduxState { + [widgetId: string]: FlattenedWidgetProps; +} + +export default canvasWidgetsReducer; diff --git a/app/taro/src/reducers/entityReducers/datasourceReducer.ts b/app/taro/src/reducers/entityReducers/datasourceReducer.ts new file mode 100644 index 0000000000..02b4272b0d --- /dev/null +++ b/app/taro/src/reducers/entityReducers/datasourceReducer.ts @@ -0,0 +1,284 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxActionTypes, + ReduxAction, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; +import { + Datasource, + DatasourceStructure, + MockDatasource, +} from "entities/Datasource"; + +export interface DatasourceDataState { + list: Datasource[]; + loading: boolean; + isTesting: boolean; + isDeleting: boolean; + fetchingDatasourceStructure: boolean; + isRefreshingStructure: boolean; + structure: Record; + isFetchingMockDataSource: false; + mockDatasourceList: any[]; +} + +const initialState: DatasourceDataState = { + list: [], + loading: false, + isTesting: false, + isDeleting: false, + fetchingDatasourceStructure: false, + isRefreshingStructure: false, + structure: {}, + isFetchingMockDataSource: false, + mockDatasourceList: [], +}; + +const datasourceReducer = createReducer(initialState, { + [ReduxActionTypes.FETCH_MOCK_DATASOURCES_INIT]: ( + state: DatasourceDataState, + ) => { + return { ...state, isFetchingMockDataSource: true }; + }, + [ReduxActionTypes.FETCH_MOCK_DATASOURCES_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction, + ) => { + const mockDatasourceList = action.payload as MockDatasource[]; + return { ...state, isFetchingMockDataSource: false, mockDatasourceList }; + }, + [ReduxActionErrorTypes.FETCH_MOCK_DATASOURCES_ERROR]: ( + state: DatasourceDataState, + ) => { + return { ...state, isFetchingMockDataSource: false }; + }, + [ReduxActionTypes.ADD_MOCK_DATASOURCES_INIT]: ( + state: DatasourceDataState, + ) => { + return { ...state, loading: true }; + }, + [ReduxActionTypes.ADD_MOCK_DATASOURCES_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction, + ) => { + return { + ...state, + loading: false, + list: state.list.concat(action.payload), + }; + }, + [ReduxActionErrorTypes.FETCH_MOCK_DATASOURCES_ERROR]: ( + state: DatasourceDataState, + ) => { + return { ...state, loading: false }; + }, + [ReduxActionTypes.FETCH_DATASOURCES_INIT]: (state: DatasourceDataState) => { + return { ...state, loading: true }; + }, + [ReduxActionTypes.CREATE_DATASOURCE_INIT]: (state: DatasourceDataState) => { + return { ...state, loading: true }; + }, + [ReduxActionTypes.CREATE_DATASOURCE_FROM_FORM_INIT]: ( + state: DatasourceDataState, + ) => { + return { ...state, loading: true }; + }, + [ReduxActionTypes.UPDATE_DATASOURCE_INIT]: (state: DatasourceDataState) => { + return { ...state, loading: true }; + }, + [ReduxActionTypes.TEST_DATASOURCE_INIT]: (state: DatasourceDataState) => { + return { ...state, isTesting: true }; + }, + [ReduxActionTypes.DELETE_DATASOURCE_INIT]: (state: DatasourceDataState) => { + return { ...state, isDeleting: true }; + }, + [ReduxActionTypes.REFRESH_DATASOURCE_STRUCTURE_INIT]: ( + state: DatasourceDataState, + ) => { + return { ...state, isRefreshingStructure: true }; + }, + [ReduxActionTypes.FETCH_DATASOURCE_STRUCTURE_INIT]: ( + state: DatasourceDataState, + ) => { + return { ...state, fetchingDatasourceStructure: true }; + }, + [ReduxActionTypes.FETCH_DATASOURCE_STRUCTURE_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction<{ data: DatasourceStructure; datasourceId: string }>, + ) => { + return { + ...state, + fetchingDatasourceStructure: false, + structure: { + ...state.structure, + [action.payload.datasourceId]: action.payload.data, + }, + }; + }, + [ReduxActionTypes.REFRESH_DATASOURCE_STRUCTURE_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction<{ data: DatasourceStructure; datasourceId: string }>, + ) => { + return { + ...state, + isRefreshingStructure: false, + structure: { + ...state.structure, + [action.payload.datasourceId]: action.payload.data, + }, + }; + }, + [ReduxActionErrorTypes.FETCH_DATASOURCE_STRUCTURE_ERROR]: ( + state: DatasourceDataState, + ) => { + return { + ...state, + fetchingDatasourceStructure: false, + }; + }, + [ReduxActionTypes.FETCH_DATASOURCES_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction, + ) => { + return { + ...state, + loading: false, + list: action.payload, + }; + }, + [ReduxActionTypes.TEST_DATASOURCE_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction<{ + show: boolean; + id?: string; + messages?: Array; + error?: any; + }>, + ): DatasourceDataState => { + if (action.payload.id) { + const list = state.list.map((datasource) => { + if (datasource.id === action.payload.id) { + return { ...datasource, messages: action.payload.messages }; + } + return datasource; + }); + return { + ...state, + isTesting: false, + list: list, + }; + } + return { + ...state, + isTesting: false, + }; + }, + [ReduxActionTypes.DELETE_DATASOURCE_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction, + ) => { + return { + ...state, + isDeleting: false, + list: state.list.filter( + (datasource) => datasource.id !== action.payload.id, + ), + }; + }, + [ReduxActionTypes.CREATE_DATASOURCE_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction, + ) => { + return { + ...state, + loading: false, + list: state.list.concat(action.payload), + }; + }, + [ReduxActionTypes.UPDATE_DATASOURCE_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction, + ): DatasourceDataState => { + return { + ...state, + loading: false, + list: state.list.map((datasource) => { + if (datasource.id === action.payload.id) return action.payload; + + return datasource; + }), + }; + }, + [ReduxActionTypes.SAVE_DATASOURCE_NAME_SUCCESS]: ( + state: DatasourceDataState, + action: ReduxAction, + ): DatasourceDataState => { + return { + ...state, + loading: false, + list: state.list.map((datasource) => { + if (datasource.id === action.payload.id) return action.payload; + + return datasource; + }), + }; + }, + [ReduxActionErrorTypes.CREATE_DATASOURCE_ERROR]: ( + state: DatasourceDataState, + ) => { + return { + ...state, + loading: false, + }; + }, + [ReduxActionErrorTypes.DELETE_DATASOURCE_ERROR]: ( + state: DatasourceDataState, + ) => { + return { ...state, isDeleting: false }; + }, + [ReduxActionErrorTypes.TEST_DATASOURCE_ERROR]: ( + state: DatasourceDataState, + action: ReduxAction<{ + show: boolean; + id?: string; + messages?: Array; + error?: any; + }>, + ): DatasourceDataState => { + if (action.payload.id) { + const list = state.list.map((datasource) => { + if (datasource.id === action.payload.id) { + return { ...datasource, messages: action.payload.messages }; + } + return datasource; + }); + return { + ...state, + isTesting: false, + list: list, + }; + } + return { + ...state, + isTesting: false, + }; + }, + [ReduxActionErrorTypes.UPDATE_DATASOURCE_ERROR]: ( + state: DatasourceDataState, + ): DatasourceDataState => { + return { + ...state, + loading: false, + }; + }, + [ReduxActionErrorTypes.REFRESH_DATASOURCE_STRUCTURE_ERROR]: ( + state: DatasourceDataState, + ) => { + return { + ...state, + isRefreshingStructure: false, + }; + }, +}); + +export default datasourceReducer; diff --git a/app/taro/src/reducers/entityReducers/index.ts b/app/taro/src/reducers/entityReducers/index.ts new file mode 100644 index 0000000000..1a4381e41b --- /dev/null +++ b/app/taro/src/reducers/entityReducers/index.ts @@ -0,0 +1,24 @@ +import { combineReducers } from "redux"; +import canvasWidgetsReducer from "./canvasWidgetsReducer"; +import widgetConfigReducer from "./widgetConfigReducer"; +import actionsReducer from "./actionsReducer"; +import datasourceReducer from "./datasourceReducer"; +import pageListReducer from "./pageListReducer"; +import jsExecutionsReducer from "./jsExecutionsReducer"; +import pluginsReducer from "reducers/entityReducers/pluginsReducer"; +import metaReducer from "./metaReducer"; +import appReducer from "./appReducer"; + +const entityReducer = combineReducers({ + canvasWidgets: canvasWidgetsReducer, + widgetConfig: widgetConfigReducer, + actions: actionsReducer, + datasources: datasourceReducer, + pageList: pageListReducer, + jsExecutions: jsExecutionsReducer, + plugins: pluginsReducer, + meta: metaReducer, + app: appReducer, +}); + +export default entityReducer; diff --git a/app/taro/src/reducers/entityReducers/jsExecutionsReducer.ts b/app/taro/src/reducers/entityReducers/jsExecutionsReducer.ts new file mode 100644 index 0000000000..74eaf4f5c1 --- /dev/null +++ b/app/taro/src/reducers/entityReducers/jsExecutionsReducer.ts @@ -0,0 +1,21 @@ +import { createReducer } from "../../utils/AppsmithUtils"; +import { + ReduxActionErrorTypes, + ReduxAction, +} from "../../constants/ReduxActionConstants"; + +export type JSExecutionRecord = Record; +const initialState: JSExecutionRecord = {}; +const jsExecutionsReducer = createReducer(initialState, { + [ReduxActionErrorTypes.SAVE_JS_EXECUTION_RECORD]: ( + state: JSExecutionRecord, + action: ReduxAction, + ) => { + return { + ...state, + ...action.payload, + }; + }, +}); + +export default jsExecutionsReducer; diff --git a/app/taro/src/reducers/entityReducers/metaReducer.ts b/app/taro/src/reducers/entityReducers/metaReducer.ts new file mode 100644 index 0000000000..a5015c54ef --- /dev/null +++ b/app/taro/src/reducers/entityReducers/metaReducer.ts @@ -0,0 +1,91 @@ +import { set, cloneDeep } from "lodash"; +import { createReducer } from "utils/AppsmithUtils"; +import { UpdateWidgetMetaPropertyPayload } from "actions/metaActions"; +import { + ReduxActionTypes, + ReduxAction, + WidgetReduxActionTypes, +} from "constants/ReduxActionConstants"; + +export type MetaState = Record>; + +const initialState: MetaState = {}; + +export const metaReducer = createReducer(initialState, { + [ReduxActionTypes.SET_META_PROP]: ( + state: MetaState, + action: ReduxAction, + ) => { + const next = cloneDeep(state); + + set( + next, + `${action.payload.widgetId}.${action.payload.propertyName}`, + action.payload.propertyValue, + ); + + return next; + }, + [ReduxActionTypes.TABLE_PANE_MOVED]: ( + state: MetaState, + action: ReduxAction, + ) => { + const next = { ...state }; + let widgetMetaProps: Record = next[action.payload.widgetId]; + if (widgetMetaProps === undefined) { + widgetMetaProps = { + isMoved: true, + position: { ...action.payload.position }, + }; + } else { + widgetMetaProps = { + ...widgetMetaProps, + isMoved: true, + position: { ...action.payload.position }, + }; + } + next[action.payload.widgetId] = widgetMetaProps; + return next; + }, + [WidgetReduxActionTypes.WIDGET_DELETE]: ( + state: MetaState, + action: ReduxAction<{ widgetId: string }>, + ) => { + const next = { ...state }; + delete next[action.payload.widgetId]; + return next; + }, + [ReduxActionTypes.RESET_WIDGET_META]: ( + state: MetaState, + action: ReduxAction<{ widgetId: string }>, + ) => { + const widgetId = action.payload.widgetId; + if (widgetId in state) { + const resetData: Record = { + ...state[widgetId], + }; + Object.keys(resetData).forEach((key: string) => { + resetData[key] = undefined; + }); + return { ...state, [widgetId]: { ...resetData } }; + } + return state; + }, + [ReduxActionTypes.FETCH_PAGE_SUCCESS]: () => { + return initialState; + }, + [ReduxActionTypes.FETCH_PUBLISHED_PAGE_SUCCESS]: () => { + return initialState; + }, +}); + +interface TableFilterPanePositionConfig { + widgetId: string; + isMoved: boolean; + position: { + left: number; + top: number; + }; +} + +export default metaReducer; diff --git a/app/taro/src/reducers/entityReducers/pageListReducer.tsx b/app/taro/src/reducers/entityReducers/pageListReducer.tsx new file mode 100644 index 0000000000..c83aa082bf --- /dev/null +++ b/app/taro/src/reducers/entityReducers/pageListReducer.tsx @@ -0,0 +1,165 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxAction, + ReduxActionTypes, + PageListPayload, + ClonePageSuccessPayload, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; + +const initialState: PageListReduxState = { + pages: [], + isGeneratingTemplatePage: false, +}; + +export const pageListReducer = createReducer(initialState, { + [ReduxActionTypes.DELETE_PAGE_INIT]: ( + state: PageListReduxState, + action: ReduxAction<{ id: string }>, + ) => { + if (state.defaultPageId !== action.payload.id) { + const pages = [ + ...state.pages.filter((page) => page.pageId !== action.payload.id), + ]; + return { + ...state, + pages, + }; + } + return state; + }, + [ReduxActionTypes.FETCH_PAGE_LIST_SUCCESS]: ( + state: PageListReduxState, + action: ReduxAction<{ pages: PageListPayload; applicationId: string }>, + ) => { + return { + ...state, + ...action.payload, + defaultPageId: + action.payload.pages.find((page) => page.isDefault)?.pageId || + action.payload.pages[0].pageId, + }; + }, + [ReduxActionTypes.CREATE_PAGE_SUCCESS]: ( + state: PageListReduxState, + action: ReduxAction<{ + pageName: string; + pageId: string; + layoutId: string; + isDefault: boolean; + }>, + ) => { + const _state = state; + _state.pages = state.pages.map((page) => ({ ...page, latest: false })); + _state.pages.push({ ...action.payload, latest: true }); + return { ..._state }; + }, + [ReduxActionTypes.CLONE_PAGE_SUCCESS]: ( + state: PageListReduxState, + action: ReduxAction, + ): PageListReduxState => { + return { + ...state, + pages: state.pages + .map((page) => ({ ...page, latest: false })) + .concat([{ ...action.payload, latest: true }]), + }; + }, + [ReduxActionTypes.SET_DEFAULT_APPLICATION_PAGE_SUCCESS]: ( + state: PageListReduxState, + action: ReduxAction<{ pageId: string; applicationId: string }>, + ) => { + if ( + state.applicationId === action.payload.applicationId && + state.defaultPageId !== action.payload.pageId + ) { + const pageList = state.pages.map((page) => { + if (page.pageId === state.defaultPageId) page.isDefault = false; + if (page.pageId === action.payload.pageId) page.isDefault = true; + return page; + }); + return { + ...state, + pages: pageList, + defaultPageId: action.payload.pageId, + }; + } + return state; + }, + [ReduxActionTypes.SWITCH_CURRENT_PAGE_ID]: ( + state: PageListReduxState, + action: ReduxAction<{ id: string }>, + ) => ({ + ...state, + currentPageId: action.payload.id, + }), + [ReduxActionTypes.UPDATE_PAGE_SUCCESS]: ( + state: PageListReduxState, + action: ReduxAction<{ id: string; name: string; isHidden?: boolean; icon?: string; }>, + ) => { + const pages = [...state.pages]; + const updatedPage = pages.find((page) => page.pageId === action.payload.id); + if (updatedPage) { + updatedPage.pageName = action.payload.name; + updatedPage.isHidden = !!action.payload.isHidden; + updatedPage.icon = action.payload.icon; + } + return { ...state, pages }; + }, + [ReduxActionTypes.GENERATE_TEMPLATE_PAGE_INIT]: ( + state: PageListReduxState, + ) => { + return { ...state, isGeneratingTemplatePage: true }; + }, + [ReduxActionTypes.GENERATE_TEMPLATE_PAGE_SUCCESS]: ( + state: PageListReduxState, + action: ReduxAction<{ + pageName: string; + pageId: string; + layoutId: string; + isDefault: boolean; + isNewPage: boolean; + }>, + ) => { + const _state = state; + if (action.payload.isNewPage) { + _state.pages = state.pages.map((page) => ({ ...page, latest: false })); + const newPage = { + pageName: action.payload.pageName, + pageId: action.payload.pageId, + layoutId: action.payload.layoutId, + isDefault: action.payload.isDefault, + }; + _state.pages.push({ ...newPage, latest: true }); + } + + return { ..._state, isGeneratingTemplatePage: false }; + }, + [ReduxActionErrorTypes.GENERATE_TEMPLATE_PAGE_ERROR]: ( + state: PageListReduxState, + ) => { + return { ...state, isGeneratingTemplatePage: false }; + }, +}); + +export type SupportedLayouts = + | "DESKTOP" + | "TABLET_LARGE" + | "TABLET" + | "MOBILE" + | "FLUID" + | "MOBILE_FLUID"; +export interface AppLayoutConfig { + type: SupportedLayouts; +} + +export interface PageListReduxState { + pages: PageListPayload; + applicationId?: string; + defaultPageId?: string; + currentPageId?: string; + appLayout?: AppLayoutConfig; + isGeneratingTemplatePage?: boolean; +} + +export default pageListReducer; diff --git a/app/taro/src/reducers/entityReducers/pluginsReducer.ts b/app/taro/src/reducers/entityReducers/pluginsReducer.ts new file mode 100644 index 0000000000..dbbacabd47 --- /dev/null +++ b/app/taro/src/reducers/entityReducers/pluginsReducer.ts @@ -0,0 +1,114 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxActionTypes, + ReduxAction, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; +import { Plugin } from "api/PluginApi"; +import { + PluginFormPayloadWithId, + PluginFormsPayload, + GetPluginFormConfigRequest, +} from "actions/pluginActions"; +import { DependencyMap } from "utils/DynamicBindingUtils"; + +export interface PluginDataState { + list: Plugin[]; + loading: boolean; + formConfigs: Record; + editorConfigs: Record; + settingConfigs: Record; + dependencies: Record; + fetchingSinglePluginForm: Record; +} + +const initialState: PluginDataState = { + list: [], + loading: false, + formConfigs: {}, + editorConfigs: {}, + settingConfigs: {}, + dependencies: {}, + fetchingSinglePluginForm: {}, +}; + +const pluginsReducer = createReducer(initialState, { + [ReduxActionTypes.FETCH_PLUGINS_REQUEST]: (state: PluginDataState) => { + return { ...state, loading: true }; + }, + [ReduxActionTypes.FETCH_PLUGINS_SUCCESS]: ( + state: PluginDataState, + action: ReduxAction, + ) => { + return { + ...state, + loading: false, + list: action.payload, + }; + }, + [ReduxActionErrorTypes.FETCH_PLUGINS_ERROR]: (state: PluginDataState) => { + return { + ...state, + loading: false, + }; + }, + [ReduxActionTypes.FETCH_PLUGIN_FORM_CONFIGS_SUCCESS]: ( + state: PluginDataState, + action: ReduxAction, + ) => { + return { + ...state, + ...action.payload, + }; + }, + [ReduxActionTypes.GET_PLUGIN_FORM_CONFIG_INIT]: ( + state: PluginDataState, + action: ReduxAction, + ) => { + return { + ...state, + fetchingSinglePluginForm: { + ...state.fetchingSinglePluginForm, + [action.payload.id]: true, + }, + }; + }, + [ReduxActionTypes.FETCH_PLUGIN_FORM_SUCCESS]: ( + state: PluginDataState, + action: ReduxAction, + ) => { + return { + ...state, + fetchingSinglePluginForm: { + ...state.fetchingSinglePluginForm, + [action.payload.id]: false, + }, + formConfigs: { + ...state.formConfigs, + [action.payload.id]: action.payload.form, + }, + editorConfigs: { + ...state.editorConfigs, + [action.payload.id]: action.payload.editor, + }, + settingConfigs: { + ...state.settingConfigs, + [action.payload.id]: action.payload.setting, + }, + }; + }, + [ReduxActionErrorTypes.FETCH_PLUGIN_FORM_ERROR]: ( + state: PluginDataState, + action: ReduxAction, + ) => { + return { + ...state, + fetchingSinglePluginForm: { + ...state.fetchingSinglePluginForm, + [action.payload.id]: false, + }, + }; + }, +}); + +export default pluginsReducer; diff --git a/app/taro/src/reducers/entityReducers/widgetConfigReducer.tsx b/app/taro/src/reducers/entityReducers/widgetConfigReducer.tsx new file mode 100644 index 0000000000..425bd7bc72 --- /dev/null +++ b/app/taro/src/reducers/entityReducers/widgetConfigReducer.tsx @@ -0,0 +1,84 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { ReduxActionTypes, ReduxAction } from "constants/ReduxActionConstants"; +import { WidgetProps } from "widgets/BaseWidget"; +import WidgetConfigResponse from "mockResponses/WidgetConfigResponse"; +import { ContainerWidgetProps } from "widgets/ContainerWidget"; + +import { PickerWidgetProps } from "widgets/taro/PickerWidget"; +import { SwiperWidgetProps } from "widgets/taro/SwiperWidget"; +import { GridWidgetProps } from "widgets/taro/GridWidget"; +import { MTextWidgetProps } from "widgets/taro/TextWidget"; +import { MListWidgetProps } from "widgets/taro/ListWidget"; +import { MPopupWidgetProps } from "widgets/taro/PopupWidget"; +import { MImageWidgetProps } from "widgets/taro/ImageWidget"; +import { MButtonWidgetProps } from "widgets/taro/ButtonWidget"; +import { MCellWidgetProps } from "widgets/taro/CellWidget"; +import { MHtmlWidgetProps } from "widgets/taro/HtmlWidget"; +import { MSkuWidgetProps } from "widgets/taro/SkuWidget"; +import { MKVWidgetProps } from "widgets/taro/KVWidget"; +import { MTabsWidgetProps } from "widgets/taro/TabsWidget"; +import { MBottomBarWidgetProps } from "widgets/taro/BottomBarWidget"; +import { MActionBarWidgetProps } from "widgets/taro/ActionBarWidget"; +import { MSearchWidgetProps } from "widgets/taro/SearchWidget"; +import { MLoadingWidgetProps } from "widgets/taro/LoadingWidget"; +import { MCheckboxWidgetProps } from "widgets/taro/CheckboxWidget"; +import { MFormWidgetProps } from "widgets/taro/FormWidget"; + +const initialState: WidgetConfigReducerState = WidgetConfigResponse; + +export type WidgetBlueprint = { + view?: Array<{ + type: string; + size?: { rows: number; cols: number }; + position: { top?: number; left?: number }; + props: Record; + }>; + operations?: any; +}; + +export interface WidgetConfigProps { + rows: number; + columns: number; + blueprint?: WidgetBlueprint; + widgetName: string; +} + +export interface WidgetConfigReducerState { + config: { + CONTAINER_WIDGET: Partial> & + WidgetConfigProps; + CANVAS_WIDGET: Partial> & + WidgetConfigProps; + TARO_PICKER_WIDGET: Partial & WidgetConfigProps; + TARO_SWIPER_WIDGET: Partial & WidgetConfigProps; + TARO_GRID_WIDGET: Partial & WidgetConfigProps; + TARO_TEXT_WIDGET: Partial & WidgetConfigProps; + TARO_LIST_WIDGET: Partial & WidgetConfigProps; + TARO_POPUP_WIDGET: Partial & WidgetConfigProps; + TARO_IMAGE_WIDGET: Partial & WidgetConfigProps; + TARO_BUTTON_WIDGET: Partial & WidgetConfigProps; + TARO_CELL_WIDGET: Partial & WidgetConfigProps; + TARO_HTML_WIDGET: Partial & WidgetConfigProps; + TARO_SKU_WIDGET: Partial & WidgetConfigProps; + TARO_KV_WIDGET: Partial & WidgetConfigProps; + TARO_TABS_WIDGET: Partial & WidgetConfigProps; + TARO_BOTTOM_BAR_WIDGET: Partial & WidgetConfigProps; + TARO_ACTION_BAR_WIDGET: Partial & WidgetConfigProps; + TARO_SEARCH_WIDGET: Partial & WidgetConfigProps; + TARO_LOADING_WIDGET: Partial & WidgetConfigProps; + TARO_CHECKBOX_WIDGET: Partial & WidgetConfigProps; + TARO_FORM_WIDGET: Partial & WidgetConfigProps; + }; + configVersion: number; +} + +const widgetConfigReducer = createReducer(initialState, { + [ReduxActionTypes.LOAD_WIDGET_CONFIG]: ( + state: WidgetConfigReducerState, + action: ReduxAction + ) => { + return { ...action.payload }; + }, +}); + +export default widgetConfigReducer; diff --git a/app/taro/src/reducers/evaluationReducers/dependencyReducer.ts b/app/taro/src/reducers/evaluationReducers/dependencyReducer.ts new file mode 100644 index 0000000000..8c2d72242e --- /dev/null +++ b/app/taro/src/reducers/evaluationReducers/dependencyReducer.ts @@ -0,0 +1,25 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { DependencyMap } from "../../utils/DynamicBindingUtils"; + +export type EvaluationDependencyState = { + inverseDependencyMap: DependencyMap; +}; + +const initialState: EvaluationDependencyState = { + inverseDependencyMap: {}, +}; + +const evaluationDependencyReducer = createReducer(initialState, { + [ReduxActionTypes.SET_EVALUATION_INVERSE_DEPENDENCY_MAP]: ( + state: EvaluationDependencyState, + action: ReduxAction<{ + inverseDependencyMap: DependencyMap; + }>, + ): EvaluationDependencyState => ({ + ...state, + inverseDependencyMap: action.payload.inverseDependencyMap, + }), +}); + +export default evaluationDependencyReducer; diff --git a/app/taro/src/reducers/evaluationReducers/index.ts b/app/taro/src/reducers/evaluationReducers/index.ts new file mode 100644 index 0000000000..524186dcb0 --- /dev/null +++ b/app/taro/src/reducers/evaluationReducers/index.ts @@ -0,0 +1,10 @@ +import { combineReducers } from "redux"; +import evaluatedTreeReducer from "./treeReducer"; +import evaluationDependencyReducer from "./dependencyReducer"; +import loadingEntitiesReducer from "./loadingEntitiesReducer"; + +export default combineReducers({ + tree: evaluatedTreeReducer, + dependencies: evaluationDependencyReducer, + loadingEntities: loadingEntitiesReducer, +}); diff --git a/app/taro/src/reducers/evaluationReducers/loadingEntitiesReducer.ts b/app/taro/src/reducers/evaluationReducers/loadingEntitiesReducer.ts new file mode 100644 index 0000000000..c93f20f589 --- /dev/null +++ b/app/taro/src/reducers/evaluationReducers/loadingEntitiesReducer.ts @@ -0,0 +1,16 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; + +export type LoadingEntitiesState = Set; + +const initialState: LoadingEntitiesState = new Set(); + +const loadingEntitiesReducer = createReducer(initialState, { + [ReduxActionTypes.SET_LOADING_ENTITIES]: ( + state: LoadingEntitiesState, + action: ReduxAction>, + ): LoadingEntitiesState => action.payload, + [ReduxActionTypes.FETCH_PAGE_INIT]: () => initialState, +}); + +export default loadingEntitiesReducer; diff --git a/app/taro/src/reducers/evaluationReducers/treeReducer.ts b/app/taro/src/reducers/evaluationReducers/treeReducer.ts new file mode 100644 index 0000000000..20cb80a161 --- /dev/null +++ b/app/taro/src/reducers/evaluationReducers/treeReducer.ts @@ -0,0 +1,45 @@ +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { applyChange, Diff } from "deep-diff"; +import { DataTree } from "entities/DataTree/dataTreeFactory"; +import { createImmerReducer } from "utils/AppsmithUtils"; +// import * as Sentry from "@sentry/react"; + +export type EvaluatedTreeState = DataTree; + +const initialState: EvaluatedTreeState = {}; + +const evaluatedTreeReducer = createImmerReducer(initialState, { + [ReduxActionTypes.SET_EVALUATED_TREE]: ( + state: EvaluatedTreeState, + action: ReduxAction<{ + dataTree: DataTree; + updates: Diff[]; + removedPaths: [string]; + }>, + ) => { + const { dataTree, updates } = action.payload; + if (Object.keys(dataTree).length) { + return dataTree; + } + for (const update of updates) { + // Null check for typescript + if (!Array.isArray(update.path) || update.path.length === 0) { + continue; + } + try { + applyChange(state, undefined, update); + } catch (e) { + // Sentry.captureException(e, { + // extra: { + // update, + // updateLength: updates.length, + // }, + // }); + console.error(e); + } + } + }, + [ReduxActionTypes.FETCH_PAGE_INIT]: () => initialState, +}); + +export default evaluatedTreeReducer; diff --git a/app/taro/src/reducers/index.tsx b/app/taro/src/reducers/index.tsx new file mode 100644 index 0000000000..6778eb1ebf --- /dev/null +++ b/app/taro/src/reducers/index.tsx @@ -0,0 +1,107 @@ +import { combineReducers } from "redux"; +import entityReducer from "./entityReducers"; +import uiReducer from "./uiReducers"; +import evaluationsReducer from "./evaluationReducers"; +import { EditorReduxState } from "./uiReducers/editorReducer"; +import { CanvasWidgetsReduxState } from "./entityReducers/canvasWidgetsReducer"; +import { ErrorReduxState } from "./uiReducers/errorReducer"; +import { ActionDataState } from "./entityReducers/actionsReducer"; +import { PropertyPaneReduxState } from "./uiReducers/propertyPaneReducer"; +import { WidgetConfigReducerState } from "./entityReducers/widgetConfigReducer"; +import { DatasourceDataState } from "./entityReducers/datasourceReducer"; +import { AppViewReduxState } from "./uiReducers/appViewReducer"; +import { DatasourcePaneReduxState } from "./uiReducers/datasourcePaneReducer"; +import { ApplicationsReduxState } from "./uiReducers/applicationsReducer"; +import { PageListReduxState } from "./entityReducers/pageListReducer"; +import { ApiPaneReduxState } from "./uiReducers/apiPaneReducer"; +import { QueryPaneReduxState } from "./uiReducers/queryPaneReducer"; +import { PluginDataState } from "reducers/entityReducers/pluginsReducer"; +import { AuthState } from "reducers/uiReducers/authReducer"; +import { OrgReduxState } from "reducers/uiReducers/orgReducer"; +import { UsersReduxState } from "reducers/uiReducers/usersReducer"; +import { ThemeState } from "reducers/uiReducers/themeReducer"; +import { WidgetDragResizeState } from "reducers/uiReducers/dragResizeReducer"; +import { ImportedCollectionsReduxState } from "reducers/uiReducers/importedCollectionsReducer"; +import { ProvidersReduxState } from "reducers/uiReducers/providerReducer"; +import { MetaState } from "./entityReducers/metaReducer"; +import { ImportReduxState } from "reducers/uiReducers/importReducer"; +import { HelpReduxState } from "./uiReducers/helpReducer"; +import { ApiNameReduxState } from "./uiReducers/apiNameReducer"; +import { ExplorerReduxState } from "./uiReducers/explorerReducer"; +import { PageCanvasStructureReduxState } from "reducers/uiReducers/pageCanvasStructureReducer"; +import { ConfirmRunActionReduxState } from "./uiReducers/confirmRunActionReducer"; +import { AppDataState } from "reducers/entityReducers/appReducer"; +import { DatasourceNameReduxState } from "./uiReducers/datasourceNameReducer"; +import { EvaluatedTreeState } from "./evaluationReducers/treeReducer"; +import { EvaluationDependencyState } from "./evaluationReducers/dependencyReducer"; +import { PageWidgetsReduxState } from "./uiReducers/pageWidgetsReducer"; +import { OnboardingState } from "./uiReducers/onBoardingReducer"; +import { ReleasesState } from "./uiReducers/releasesReducer"; +import { LoadingEntitiesState } from "./evaluationReducers/loadingEntitiesReducer"; +import { WebsocketReduxState } from "./uiReducers/websocketReducer"; +import { DebuggerReduxState } from "./uiReducers/debuggerReducer"; +import { TourReducerState } from "./uiReducers/tourReducer"; +import { TableFilterPaneReduxState } from "./uiReducers/tableFilterPaneReducer"; +import { NotificationReducerState } from "./uiReducers/notificationsReducer"; +import { CanvasSelectionState } from "./uiReducers/canvasSelectionReducer"; +import { ActionTabsReduxState } from "./uiReducers/actionTabsReducer"; + +const appReducer = combineReducers({ + entities: entityReducer, + ui: uiReducer, + evaluations: evaluationsReducer, +}); + +export default appReducer; + +export interface AppState { + ui: { + editor: EditorReduxState; + actionTabs: ActionTabsReduxState; + propertyPane: PropertyPaneReduxState; + tableFilterPane: TableFilterPaneReduxState; + errors: ErrorReduxState; + appView: AppViewReduxState; + applications: ApplicationsReduxState; + apiPane: ApiPaneReduxState; + auth: AuthState; + orgs: OrgReduxState; + users: UsersReduxState; + widgetDragResize: WidgetDragResizeState; + importedCollections: ImportedCollectionsReduxState; + providers: ProvidersReduxState; + imports: ImportReduxState; + queryPane: QueryPaneReduxState; + datasourcePane: DatasourcePaneReduxState; + help: HelpReduxState; + apiName: ApiNameReduxState; + explorer: ExplorerReduxState; + pageCanvasStructure: PageCanvasStructureReduxState; + pageWidgets: PageWidgetsReduxState; + confirmRunAction: ConfirmRunActionReduxState; + datasourceName: DatasourceNameReduxState; + theme: ThemeState; + onBoarding: OnboardingState; + releases: ReleasesState; + websocket: WebsocketReduxState; + debugger: DebuggerReduxState; + tour: TourReducerState; + notifications: NotificationReducerState; + canvasSelection: CanvasSelectionState; + }; + entities: { + canvasWidgets: CanvasWidgetsReduxState; + actions: ActionDataState; + widgetConfig: WidgetConfigReducerState; + datasources: DatasourceDataState; + pageList: PageListReduxState; + plugins: PluginDataState; + meta: MetaState; + app: AppDataState; + }; + evaluations: { + tree: EvaluatedTreeState; + dependencies: EvaluationDependencyState; + loadingEntities: LoadingEntitiesState; + }; +} diff --git a/app/taro/src/reducers/uiReducers/appViewReducer.tsx b/app/taro/src/reducers/uiReducers/appViewReducer.tsx new file mode 100644 index 0000000000..1400795f10 --- /dev/null +++ b/app/taro/src/reducers/uiReducers/appViewReducer.tsx @@ -0,0 +1,44 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxActionTypes, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; + +const initialState: AppViewReduxState = { + isFetchingPage: false, + initialized: false, +}; + +const appViewReducer = createReducer(initialState, { + [ReduxActionTypes.INITIALIZE_PAGE_VIEWER]: (state: AppViewReduxState) => { + return { ...state, initialized: false }; + }, + [ReduxActionTypes.INITIALIZE_PAGE_VIEWER_SUCCESS]: ( + state: AppViewReduxState, + ) => { + return { ...state, initialized: true }; + }, + [ReduxActionTypes.FETCH_PUBLISHED_PAGE_INIT]: (state: AppViewReduxState) => { + return { ...state, isFetchingPage: true }; + }, + [ReduxActionErrorTypes.FETCH_PUBLISHED_PAGE_ERROR]: ( + state: AppViewReduxState, + ) => { + return { ...state, isFetchingPage: false }; + }, + [ReduxActionTypes.FETCH_PUBLISHED_PAGE_SUCCESS]: ( + state: AppViewReduxState, + ) => { + return { + ...state, + isFetchingPage: false, + }; + }, +}); + +export interface AppViewReduxState { + initialized: boolean; + isFetchingPage: boolean; +} + +export default appViewReducer; diff --git a/app/taro/src/reducers/uiReducers/applicationsReducer.tsx b/app/taro/src/reducers/uiReducers/applicationsReducer.tsx new file mode 100644 index 0000000000..c0f601f617 --- /dev/null +++ b/app/taro/src/reducers/uiReducers/applicationsReducer.tsx @@ -0,0 +1,408 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxAction, + ReduxActionTypes, + ReduxActionErrorTypes, + ApplicationPayload, +} from "constants/ReduxActionConstants"; +import { Organization } from "constants/orgConstants"; +import { + createMessage, + ERROR_MESSAGE_CREATE_APPLICATION, +} from "constants/messages"; +import { UpdateApplicationRequest } from "api/ApplicationApi"; +import { AppLayoutConfig } from "reducers/entityReducers/pageListReducer"; + +export type CreateApplicationFormValues = { + applicationName: string; + orgId: string; + colorCode?: string; + appName?: string; +}; + +const initialState: ApplicationsReduxState = { + isFetchingApplications: false, + isSavingAppName: false, + isErrorSavingAppName: false, + isFetchingApplication: false, + isChangingViewAccess: false, + applicationList: [], + creatingApplication: {}, + deletingApplication: false, + forkingApplication: false, + duplicatingApplication: false, + userOrgs: [], + isSavingOrgInfo: false, + importingApplication: false, + importedApplication: null, + showAppInviteUsersDialog: false, +}; + +const applicationsReducer = createReducer(initialState, { + [ReduxActionTypes.DELETE_APPLICATION_INIT]: ( + state: ApplicationsReduxState, + ) => { + return { ...state, deletingApplication: true }; + }, + [ReduxActionTypes.DELETE_APPLICATION_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction, + ) => { + const _organizations = state.userOrgs.map((org: Organization) => { + if (org.organization.id === action.payload.organizationId) { + let applications = org.applications; + + applications = applications.filter( + (application: ApplicationPayload) => { + return application.id !== action.payload.id; + }, + ); + + return { + ...org, + applications, + }; + } + + return org; + }); + + return { + ...state, + userOrgs: _organizations, + deletingApplication: false, + }; + }, + [ReduxActionErrorTypes.DELETE_APPLICATION_ERROR]: ( + state: ApplicationsReduxState, + ) => { + return { ...state, deletingApplication: false }; + }, + [ReduxActionTypes.CHANGE_APPVIEW_ACCESS_INIT]: ( + state: ApplicationsReduxState, + ) => ({ ...state, isChangingViewAccess: true }), + [ReduxActionTypes.CHANGE_APPVIEW_ACCESS_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ id: string; isPublic: boolean }>, + ) => { + return { + ...state, + isChangingViewAccess: false, + currentApplication: { + ...state.currentApplication, + isPublic: action.payload.isPublic, + }, + }; + }, + [ReduxActionTypes.GET_ALL_APPLICATION_INIT]: ( + state: ApplicationsReduxState, + ) => ({ ...state, isFetchingApplications: true }), + [ReduxActionTypes.FETCH_USER_APPLICATIONS_ORGS_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ applicationList: any }>, + ) => { + return { + ...state, + isFetchingApplications: false, + userOrgs: action.payload, + }; + }, + + [ReduxActionTypes.FETCH_APPLICATION_INIT]: ( + state: ApplicationsReduxState, + ) => ({ ...state, isFetchingApplication: true }), + [ReduxActionTypes.FETCH_APPLICATION_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ applicationList: ApplicationPayload[] }>, + ) => ({ + ...state, + currentApplication: action.payload, + isFetchingApplication: false, + }), + [ReduxActionTypes.CURRENT_APPLICATION_NAME_UPDATE]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ name: string }>, + ) => ({ + ...state, + currentApplication: { + ...state.currentApplication, + name: action.payload, + }, + }), + [ReduxActionTypes.CURRENT_APPLICATION_LAYOUT_UPDATE]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ appLayout: AppLayoutConfig }>, + ) => ({ + ...state, + currentApplication: { + ...state.currentApplication, + appLayout: action.payload, + }, + }), + [ReduxActionTypes.CREATE_APPLICATION_INIT]: ( + state: ApplicationsReduxState, + action: ReduxAction, + ) => { + const updatedCreatingApplication = { ...state.creatingApplication }; + updatedCreatingApplication[action.payload.orgId] = true; + + return { + ...state, + creatingApplication: updatedCreatingApplication, + }; + }, + [ReduxActionTypes.CREATE_APPLICATION_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ orgId: string; application: ApplicationPayload }>, + ) => { + const _organizations = state.userOrgs.map((org: Organization) => { + if (org.organization.id === action.payload.orgId) { + const applications = org.applications; + applications.push(action.payload.application); + org.applications = [...applications]; + return { + ...org, + }; + } + return org; + }); + + const updatedCreatingApplication = { ...state.creatingApplication }; + updatedCreatingApplication[action.payload.orgId] = false; + + return { + ...state, + creatingApplication: updatedCreatingApplication, + applicationList: [...state.applicationList, action.payload.application], + userOrgs: _organizations, + }; + }, + [ReduxActionErrorTypes.CREATE_APPLICATION_ERROR]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ orgId: string }>, + ) => { + const updatedCreatingApplication = { ...state.creatingApplication }; + updatedCreatingApplication[action.payload.orgId] = false; + + return { + ...state, + creatingApplication: updatedCreatingApplication, + createApplicationError: createMessage(ERROR_MESSAGE_CREATE_APPLICATION), + }; + }, + [ReduxActionTypes.FORK_APPLICATION_INIT]: (state: ApplicationsReduxState) => { + return { ...state, forkingApplication: true }; + }, + [ReduxActionTypes.FORK_APPLICATION_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ orgId: string; application: ApplicationPayload }>, + ) => { + const _organizations = state.userOrgs.map((org: Organization) => { + if (org.organization.id === action.payload.orgId) { + const applications = org.applications; + org.applications = [...applications, action.payload.application]; + return { + ...org, + }; + } + return org; + }); + + return { + ...state, + forkingApplication: false, + applicationList: [...state.applicationList, action.payload.application], + userOrgs: _organizations, + }; + }, + [ReduxActionErrorTypes.FORK_APPLICATION_ERROR]: ( + state: ApplicationsReduxState, + ) => { + return { + ...state, + forkingApplication: false, + }; + }, + [ReduxActionTypes.IMPORT_APPLICATION_INIT]: ( + state: ApplicationsReduxState, + ) => ({ ...state, importingApplication: true }), + [ReduxActionTypes.IMPORT_APPLICATION_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ importedApplication: any }>, + ) => { + const { importedApplication } = action.payload; + return { + ...state, + importingApplication: false, + importedApplication, + }; + }, + [ReduxActionErrorTypes.IMPORT_APPLICATION_ERROR]: ( + state: ApplicationsReduxState, + ) => { + return { + ...state, + importingApplication: false, + }; + }, + [ReduxActionTypes.SAVING_ORG_INFO]: (state: ApplicationsReduxState) => { + return { + ...state, + isSavingOrgInfo: true, + }; + }, + [ReduxActionTypes.SAVE_ORG_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ + id: string; + name?: string; + website?: string; + email?: string; + logoUrl?: string; + }>, + ) => { + const _organizations = state.userOrgs.map((org: Organization) => { + if (org.organization.id === action.payload.id) { + org.organization = { ...org.organization, ...action.payload }; + + return { + ...org, + }; + } + return org; + }); + + return { + ...state, + userOrgs: _organizations, + isSavingOrgInfo: false, + }; + }, + [ReduxActionErrorTypes.SAVE_ORG_ERROR]: (state: ApplicationsReduxState) => { + return { + ...state, + isSavingOrgInfo: false, + }; + }, + [ReduxActionTypes.SEARCH_APPLICATIONS]: ( + state: ApplicationsReduxState, + action: ReduxAction<{ keyword?: string }>, + ) => { + return { + ...state, + searchKeyword: action.payload.keyword, + }; + }, + [ReduxActionTypes.DUPLICATE_APPLICATION_INIT]: ( + state: ApplicationsReduxState, + ) => { + return { ...state, duplicatingApplication: true }; + }, + [ReduxActionTypes.DUPLICATE_APPLICATION_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction, + ) => { + return { + ...state, + duplicatingApplication: false, + applicationList: [...state.applicationList, action.payload], + }; + }, + [ReduxActionErrorTypes.DUPLICATE_APPLICATION_ERROR]: ( + state: ApplicationsReduxState, + ) => { + return { ...state, duplicatingApplication: false }; + }, + [ReduxActionTypes.UPDATE_APPLICATION]: ( + state: ApplicationsReduxState, + action: ReduxAction, + ) => { + let isSavingAppName = false; + if (action.payload.name) { + isSavingAppName = true; + } + return { + ...state, + isSavingAppName: isSavingAppName, + isErrorSavingAppName: false, + }; + }, + [ReduxActionTypes.UPDATE_APPLICATION_SUCCESS]: ( + state: ApplicationsReduxState, + action: ReduxAction, + ) => { + // userOrgs data has to be saved to localStorage only if the action is successful + // It introduces bug if we prematurely save it during init action. + const { id, ...rest } = action.payload; + const _organizations = state.userOrgs.map((org: Organization) => { + const appIndex = org.applications.findIndex((app) => app.id === id); + + if (appIndex !== -1) { + org.applications[appIndex] = { + ...org.applications[appIndex], + ...rest, + }; + } + + return org; + }); + return { + ...state, + userOrgs: _organizations, + isSavingAppName: false, + isErrorSavingAppName: false, + }; + }, + [ReduxActionErrorTypes.UPDATE_APPLICATION_ERROR]: ( + state: ApplicationsReduxState, + ) => { + return { ...state, isSavingAppName: false, isErrorSavingAppName: true }; + }, + [ReduxActionTypes.RESET_CURRENT_APPLICATION]: ( + state: ApplicationsReduxState, + ) => ({ ...state, currentApplication: null }), + [ReduxActionTypes.SET_SHOW_APP_INVITE_USERS_MODAL]: ( + state: ApplicationsReduxState, + action: ReduxAction, + ) => ({ + ...state, + showAppInviteUsersDialog: action.payload, + }), +}); + +export type creatingApplicationMap = Record; + +export interface ApplicationsReduxState { + applicationList: ApplicationPayload[]; + searchKeyword?: string; + isFetchingApplications: boolean; + isSavingAppName: boolean; + isErrorSavingAppName: boolean; + isFetchingApplication: boolean; + isChangingViewAccess: boolean; + creatingApplication: creatingApplicationMap; + createApplicationError?: string; + deletingApplication: boolean; + forkingApplication: boolean; + duplicatingApplication: boolean; + currentApplication?: ApplicationPayload; + userOrgs: Organization[]; + isSavingOrgInfo: boolean; + importingApplication: boolean; + importedApplication: any; + showAppInviteUsersDialog: boolean; +} + +export interface Application { + id: string; + name: string; + organizationId: string; + isPublic: boolean; + appIsExample: boolean; + new: boolean; + defaultPageId: string; + pages: Array<{ id: string; isDefault: boolean; default: boolean }>; + userPermissions: string[]; +} + +export default applicationsReducer; diff --git a/app/taro/src/reducers/uiReducers/debuggerReducer.ts b/app/taro/src/reducers/uiReducers/debuggerReducer.ts new file mode 100644 index 0000000000..0a685b642a --- /dev/null +++ b/app/taro/src/reducers/uiReducers/debuggerReducer.ts @@ -0,0 +1,125 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { Message, Severity } from "entities/AppsmithConsole"; +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { get, merge, isEmpty, omit, isUndefined } from "lodash"; +import LOG_TYPE from "entities/AppsmithConsole/logtype"; + +const initialState: DebuggerReduxState = { + logs: [], + errorCount: 0, + isOpen: false, + errors: {}, + expandId: "", +}; + +const debuggerReducer = createReducer(initialState, { + [ReduxActionTypes.DEBUGGER_LOG]: ( + state: DebuggerReduxState, + action: ReduxAction, + ) => { + const isError = action.payload.severity === Severity.ERROR; + + return { + ...state, + logs: [...state.logs, action.payload], + errorCount: isError ? state.errorCount + 1 : state.errorCount, + }; + }, + [ReduxActionTypes.CLEAR_DEBUGGER_LOGS]: (state: DebuggerReduxState) => { + return { + ...state, + logs: [], + errorCount: 0, + }; + }, + [ReduxActionTypes.SHOW_DEBUGGER]: ( + state: DebuggerReduxState, + action: ReduxAction, + ) => { + return { + ...state, + isOpen: isUndefined(action.payload) ? !state.isOpen : action.payload, + }; + }, + [ReduxActionTypes.DEBUGGER_ERROR_LOG]: ( + state: DebuggerReduxState, + action: ReduxAction, + ) => { + if (!action.payload.source) return state; + + const entityId = action.payload.source.id; + const id = + action.payload.logType === LOG_TYPE.WIDGET_PROPERTY_VALIDATION_ERROR || + action.payload.logType === LOG_TYPE.EVAL_ERROR + ? `${entityId}-${action.payload.source.propertyPath}` + : entityId; + const previousState = get(state.errors, id, {}); + + return { + ...state, + errors: { + ...state.errors, + [id]: { + ...merge(previousState, action.payload), + }, + }, + expandId: id, + }; + }, + [ReduxActionTypes.DEBUGGER_UPDATE_ERROR_LOG]: ( + state: DebuggerReduxState, + action: ReduxAction, + ) => { + if (!action.payload.source) return state; + + const entityId = action.payload.source.id; + const isWidgetErrorLog = + action.payload.logType === LOG_TYPE.WIDGET_PROPERTY_VALIDATION_ERROR || + action.payload.logType === LOG_TYPE.EVAL_ERROR; + const id = isWidgetErrorLog + ? `${entityId}-${action.payload.source.propertyPath}` + : entityId; + + if (isEmpty(action.payload.state)) { + return { + ...state, + errors: omit(state.errors, id), + }; + } + + return { + ...state, + errors: { + ...state.errors, + [id]: { + ...action.payload, + }, + }, + expandId: id, + }; + }, + [ReduxActionTypes.DEBUGGER_UPDATE_ERROR_LOGS]: ( + state: DebuggerReduxState, + action: ReduxAction, + ) => { + return { + ...state, + errors: { ...action.payload }, + }; + }, + [ReduxActionTypes.INIT_CANVAS_LAYOUT]: () => { + return { + ...initialState, + }; + }, +}); + +export interface DebuggerReduxState { + logs: Message[]; + errorCount: number; + isOpen: boolean; + errors: Record; + expandId: string; +} + +export default debuggerReducer; diff --git a/app/taro/src/reducers/uiReducers/editorReducer.tsx b/app/taro/src/reducers/uiReducers/editorReducer.tsx new file mode 100644 index 0000000000..2e1c5dd08f --- /dev/null +++ b/app/taro/src/reducers/uiReducers/editorReducer.tsx @@ -0,0 +1,206 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxAction, + UpdateCanvasPayload, + ReduxActionTypes, + ReduxActionErrorTypes, +} from "constants/ReduxActionConstants"; +import dayjs from "dayjs"; +import { PageAction } from "constants/AppsmithActionConstants/ActionConstants"; + +const initialState: EditorReduxState = { + initialized: false, + loadingStates: { + publishing: false, + publishingError: false, + saving: false, + savingError: false, + loading: false, + loadingError: false, + pageSwitchingError: false, + isPageSwitching: false, + creatingPage: false, + creatingPageError: false, + cloningPage: false, + cloningPageError: false, + updatingWidgetName: false, + updateWidgetNameError: false, + }, + isSnipingMode: false, +}; + +const editorReducer = createReducer(initialState, { + [ReduxActionTypes.RESET_EDITOR_SUCCESS]: (state: EditorReduxState) => { + return { ...state, initialized: false }; + }, + [ReduxActionTypes.INITIALIZE_EDITOR_SUCCESS]: (state: EditorReduxState) => { + return { ...state, initialized: true }; + }, + [ReduxActionTypes.UPDATE_PAGE_SUCCESS]: ( + state: EditorReduxState, + action: ReduxAction<{ id: string; name: string }>, + ) => { + if (action.payload.id === state.currentPageId) { + return { ...state, currentPageName: action.payload.name }; + } + return state; + }, + [ReduxActionTypes.FETCH_PAGE_INIT]: (state: EditorReduxState) => ({ + ...state, + loadingStates: { + ...state.loadingStates, + isPageSwitching: true, + }, + }), + [ReduxActionTypes.FETCH_PAGE_SUCCESS]: (state: EditorReduxState) => ({ + ...state, + loadingStates: { + ...state.loadingStates, + isPageSwitching: false, + }, + }), + [ReduxActionErrorTypes.FETCH_PAGE_ERROR]: (state: EditorReduxState) => ({ + ...state, + loadingStates: { + ...state.loadingStates, + isPageSwitching: false, + }, + }), + [ReduxActionTypes.PUBLISH_APPLICATION_INIT]: (state: EditorReduxState) => { + state.loadingStates.publishing = true; + state.loadingStates.publishingError = false; + return { ...state }; + }, + [ReduxActionErrorTypes.PUBLISH_APPLICATION_ERROR]: ( + state: EditorReduxState, + ) => { + state.loadingStates.publishing = false; + state.loadingStates.publishingError = true; + return { ...state }; + }, + [ReduxActionTypes.PUBLISH_APPLICATION_SUCCESS]: (state: EditorReduxState) => { + state.loadingStates.publishing = false; + state.loadingStates.publishingError = false; + state.loadingStates.published = dayjs().format(); + return { ...state }; + }, + [ReduxActionTypes.SAVE_PAGE_INIT]: (state: EditorReduxState) => { + state.loadingStates.saving = true; + state.loadingStates.savingError = false; + return { ...state }; + }, + [ReduxActionTypes.SAVE_PAGE_SUCCESS]: (state: EditorReduxState) => { + state.loadingStates.saving = false; + return { ...state }; + }, + [ReduxActionErrorTypes.SAVE_PAGE_ERROR]: (state: EditorReduxState) => { + state.loadingStates.saving = false; + state.loadingStates.savingError = true; + return { ...state }; + }, + [ReduxActionTypes.SET_LAST_UPDATED_TIME]: ( + state: EditorReduxState, + actions: ReduxAction, + ) => { + return { ...state, lastUpdatedTime: actions.payload }; + }, + [ReduxActionTypes.INIT_CANVAS_LAYOUT]: ( + state: EditorReduxState, + action: ReduxAction, + ) => { + const { + currentApplicationId, + currentLayoutId, + currentPageId, + currentPageName, + pageActions, + pageWidgetId, + } = action.payload; + state.loadingStates.publishing = false; + state.loadingStates.publishingError = false; + return { + ...state, + currentPageName, + currentLayoutId, + pageWidgetId, + currentApplicationId, + currentPageId, + pageActions, + }; + }, + [ReduxActionTypes.CLONE_PAGE_INIT]: (state: EditorReduxState) => { + state.loadingStates.cloningPage = true; + state.loadingStates.cloningPageError = false; + return { ...state }; + }, + [ReduxActionErrorTypes.CLONE_PAGE_ERROR]: (state: EditorReduxState) => { + state.loadingStates.cloningPageError = true; + state.loadingStates.cloningPage = false; + return { ...state }; + }, + [ReduxActionTypes.CLONE_PAGE_SUCCESS]: (state: EditorReduxState) => { + state.loadingStates.cloningPage = false; + return { ...state }; + }, + [ReduxActionTypes.CREATE_PAGE_INIT]: (state: EditorReduxState) => { + state.loadingStates.creatingPage = true; + state.loadingStates.creatingPageError = false; + return { ...state }; + }, + [ReduxActionErrorTypes.CREATE_PAGE_ERROR]: (state: EditorReduxState) => { + state.loadingStates.creatingPageError = true; + state.loadingStates.creatingPage = false; + return { ...state }; + }, + [ReduxActionTypes.CREATE_PAGE_SUCCESS]: (state: EditorReduxState) => { + state.loadingStates.creatingPage = false; + return { ...state }; + }, + [ReduxActionTypes.UPDATE_WIDGET_NAME_INIT]: (state: EditorReduxState) => { + state.loadingStates.updatingWidgetName = true; + state.loadingStates.updateWidgetNameError = false; + return { ...state }; + }, + [ReduxActionTypes.UPDATE_WIDGET_NAME_SUCCESS]: (state: EditorReduxState) => { + state.loadingStates.updatingWidgetName = false; + state.loadingStates.updateWidgetNameError = false; + return { ...state }; + }, + [ReduxActionErrorTypes.UPDATE_WIDGET_NAME_ERROR]: ( + state: EditorReduxState, + ) => { + state.loadingStates.updatingWidgetName = false; + state.loadingStates.updateWidgetNameError = true; + return { ...state }; + }, +}); + +export interface EditorReduxState { + initialized: boolean; + pageWidgetId?: string; + currentLayoutId?: string; + currentPageName?: string; + currentPageId?: string; + lastUpdatedTime?: number; + pageActions?: PageAction[][]; + isSnipingMode: boolean; + loadingStates: { + saving: boolean; + savingError: boolean; + publishing: boolean; + published?: string; + publishingError: boolean; + loading: boolean; + loadingError: boolean; + isPageSwitching: boolean; + pageSwitchingError: boolean; + creatingPage: boolean; + creatingPageError: boolean; + cloningPage: boolean; + cloningPageError: boolean; + updatingWidgetName: boolean; + updateWidgetNameError: boolean; + }; +} + +export default editorReducer; diff --git a/app/taro/src/reducers/uiReducers/errorReducer.tsx b/app/taro/src/reducers/uiReducers/errorReducer.tsx new file mode 100644 index 0000000000..88789eb9bf --- /dev/null +++ b/app/taro/src/reducers/uiReducers/errorReducer.tsx @@ -0,0 +1,51 @@ +import { createReducer } from "utils/AppsmithUtils"; +import { + ReduxAction, + ReduxActionTypes, + ReduxActionErrorPayload, +} from "constants/ReduxActionConstants"; +import { ERROR_CODES } from "constants/ApiConstants"; +import _ from "lodash"; + +const initialState: ErrorReduxState = { + safeCrash: false, + safeCrashCode: undefined, + currentError: { sourceAction: "", message: "" }, +}; + +const errorReducer = createReducer(initialState, { + [ReduxActionTypes.SAFE_CRASH_APPSMITH]: ( + state: ErrorReduxState, + action: ReduxAction, + ) => ({ + ...state, + safeCrash: true, + safeCrashCode: _.get(action, "payload.code", 502), // when the server is not responding + }), + [ReduxActionTypes.REPORT_ERROR]: ( + state: ErrorReduxState, + action: ReduxAction, + ) => { + return { + ...state, + currentError: { + sourceAction: action.payload.source, + message: action.payload.message, + }, + }; + }, + [ReduxActionTypes.FLUSH_ERRORS]: () => { + return initialState; + }, +}); + +export interface ErrorReduxState { + safeCrash: boolean; + safeCrashCode?: ERROR_CODES; + currentError: { + sourceAction?: string; + message?: string; + }; +} + +export default errorReducer; diff --git a/app/taro/src/reducers/uiReducers/index.tsx b/app/taro/src/reducers/uiReducers/index.tsx new file mode 100644 index 0000000000..ede44c2d71 --- /dev/null +++ b/app/taro/src/reducers/uiReducers/index.tsx @@ -0,0 +1,22 @@ +import { combineReducers } from "redux"; +import editorReducer from "./editorReducer"; +import errorReducer from "./errorReducer"; +import appViewReducer from "./appViewReducer"; +import applicationsReducer from "./applicationsReducer"; +import themeReducer from "./themeReducer"; +import pageCanvasStructureReducer from "reducers/uiReducers/pageCanvasStructureReducer"; +import pageWidgetsReducer from "./pageWidgetsReducer"; +// import debuggerReducer from "./debuggerReducer"; + +const uiReducer = combineReducers({ + editor: editorReducer, + errors: errorReducer, + appView: appViewReducer, + applications: applicationsReducer, + pageCanvasStructure: pageCanvasStructureReducer, + pageWidgets: pageWidgetsReducer, + theme: themeReducer, + // debugger: debuggerReducer, +}); + +export default uiReducer; diff --git a/app/taro/src/reducers/uiReducers/pageCanvasStructureReducer.ts b/app/taro/src/reducers/uiReducers/pageCanvasStructureReducer.ts new file mode 100644 index 0000000000..87b380c68d --- /dev/null +++ b/app/taro/src/reducers/uiReducers/pageCanvasStructureReducer.ts @@ -0,0 +1,65 @@ +import { createImmerReducer } from "utils/AppsmithUtils"; +import { + ReduxActionTypes, + ReduxActionErrorTypes, + ReduxAction, +} from "constants/ReduxActionConstants"; +import { WidgetProps } from "widgets/BaseWidget"; +import { compareAndGenerateImmutableCanvasStructure } from "utils/canvasStructureHelpers"; +import { WidgetType } from "constants/WidgetConstants"; + +export interface CanvasStructure { + widgetName: string; + widgetId: string; + type: WidgetType; + children?: CanvasStructure[]; +} + +export interface DSL extends WidgetProps { + children?: DSL[]; +} +export interface PageCanvasStructureReduxState { + [pageId: string]: CanvasStructure; +} + +const initialState: PageCanvasStructureReduxState = {}; + +const pageCanvasStructureReducer = createImmerReducer(initialState, { + [ReduxActionTypes.FETCH_PAGE_DSLS_SUCCESS]: ( + state: PageCanvasStructureReduxState, + action: ReduxAction< + Array<{ + pageId: string; + dsl: DSL; + }> + >, + ) => { + action.payload.forEach((entry) => { + state[entry.pageId] = compareAndGenerateImmutableCanvasStructure( + state[entry.pageId], + entry.dsl, + ); + }); + }, + [ReduxActionTypes.FETCH_PAGE_DSL_SUCCESS]: ( + state: PageCanvasStructureReduxState, + action: ReduxAction<{ pageId: string; dsl?: DSL }>, + ) => { + if (!action.payload.dsl) { + delete state[action.payload.pageId]; + } else { + state[action.payload.pageId] = compareAndGenerateImmutableCanvasStructure( + state[action.payload.pageId], + action.payload.dsl, + ); + } + }, + [ReduxActionErrorTypes.FETCH_PAGE_DSL_ERROR]: ( + state: PageCanvasStructureReduxState, + action: ReduxAction<{ pageId: string }>, + ) => { + return { ...state, [action.payload.pageId]: false }; + }, +}); + +export default pageCanvasStructureReducer; diff --git a/app/taro/src/reducers/uiReducers/pageWidgetsReducer.ts b/app/taro/src/reducers/uiReducers/pageWidgetsReducer.ts new file mode 100644 index 0000000000..460339e975 --- /dev/null +++ b/app/taro/src/reducers/uiReducers/pageWidgetsReducer.ts @@ -0,0 +1,43 @@ +import { createImmerReducer } from "utils/AppsmithUtils"; +import { ReduxActionTypes, ReduxAction } from "constants/ReduxActionConstants"; +import { DSL } from "reducers/uiReducers/pageCanvasStructureReducer"; +import { WidgetProps } from "widgets/BaseWidget"; +import CanvasWidgetsNormalizer from "normalizers/CanvasWidgetsNormalizer"; + +export interface PageWidgetsReduxState { + [pageId: string]: { + [widgetId: string]: WidgetProps & { children: string[] }; + }; +} + +const initalState: PageWidgetsReduxState = {}; + +const pageWidgetsReducer = createImmerReducer(initalState, { + // Reducer to clear all pageWidgets before finishing creating + // a new application + [ReduxActionTypes.RESET_APPLICATION_WIDGET_STATE_REQUEST]: () => ({}), + [ReduxActionTypes.FETCH_PAGE_DSLS_SUCCESS]: ( + state: PageWidgetsReduxState, + action: ReduxAction>, + ) => { + action.payload.forEach((entry) => { + state[entry.pageId] = CanvasWidgetsNormalizer.normalize( + entry.dsl, + ).entities.canvasWidgets; + }); + }, + [ReduxActionTypes.FETCH_PAGE_DSL_SUCCESS]: ( + state: PageWidgetsReduxState, + action: ReduxAction<{ pageId: string; dsl?: DSL }>, + ) => { + if (!action.payload.dsl) { + delete state[action.payload.pageId]; + } else { + state[action.payload.pageId] = CanvasWidgetsNormalizer.normalize( + action.payload.dsl, + ).entities.canvasWidgets; + } + }, +}); + +export default pageWidgetsReducer; diff --git a/app/taro/src/reducers/uiReducers/themeReducer.ts b/app/taro/src/reducers/uiReducers/themeReducer.ts new file mode 100644 index 0000000000..fe60590982 --- /dev/null +++ b/app/taro/src/reducers/uiReducers/themeReducer.ts @@ -0,0 +1,49 @@ +import { createImmerReducer } from "utils/AppsmithUtils"; +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { dark, light, theme } from "constants/DefaultTheme"; +import { ThemeMode } from "../../selectors/themeSelectors"; + +const initialState: ThemeState = { + mode: ThemeMode.LIGHT, + theme: { + ...theme, + colors: { + ...theme.colors, + ...light, + }, + }, +}; + +export interface ThemeState { + mode: ThemeMode; + theme: any; +} + +const themeReducer = createImmerReducer(initialState, { + [ReduxActionTypes.SET_THEME]: ( + draftState: ThemeState, + action: ReduxAction, + ) => { + draftState.mode = action.payload; + const completeTheme = { + ...theme, + }; + switch (action.payload) { + case ThemeMode.DARK: + completeTheme.colors = { + ...completeTheme.colors, + ...dark, + }; + break; + default: + completeTheme.colors = { + ...completeTheme.colors, + ...light, + }; + break; + } + draftState.theme = completeTheme; + }, +}); + +export default themeReducer; diff --git a/app/taro/src/sagas/ActionExecutionSagas.ts b/app/taro/src/sagas/ActionExecutionSagas.ts new file mode 100644 index 0000000000..1a3a0f9fbe --- /dev/null +++ b/app/taro/src/sagas/ActionExecutionSagas.ts @@ -0,0 +1,919 @@ +import { + ApplicationPayload, + Page, + ReduxAction, + ReduxActionErrorTypes, + ReduxActionTypes, +} from "constants/ReduxActionConstants"; +import { + EventType, + ExecuteActionPayload, + ExecuteActionPayloadEvent, + PageAction, + RESP_HEADER_DATATYPE, +} from "constants/AppsmithActionConstants/ActionConstants"; +import * as log from "loglevel"; +import { + all, + call, + put, + race, + select, + take, + takeEvery, + takeLatest, +} from "redux-saga/effects"; +import { + ActionDescription, + RunActionPayload, +} from "entities/DataTree/dataTreeFactory"; +import { executeAction, executeActionError } from "actions/widgetActions"; +import { + getCurrentApplicationId, + getCurrentPageId, + getCurrentPage, + getLayoutOnLoadActions, + getPageList, +} from "selectors/editorSelectors"; +import _, { get, isString } from "lodash"; +import { EventName } from "utils/AnalyticsUtil"; +import { + API_EDITOR_ID_URL, + API_EDITOR_URL, + API_EDITOR_URL_WITH_SELECTED_PAGE_ID, + convertToQueryParams, + QUERIES_EDITOR_ID_URL, + QUERIES_EDITOR_URL, + INTEGRATION_EDITOR_URL, +} from "constants/routes"; +import { + executeApiActionRequest, + executeApiActionSuccess, + executePageLoadActionsComplete, + showRunActionConfirmModal, + updateAction, +} from "actions/actionActions"; +import { Action, PluginType } from "entities/Action"; +import ActionAPI, { + ActionExecutionResponse, + ActionResponse, + ExecuteActionRequest, + PaginationField, + Property, +} from "api/ActionAPI"; +import { + getAction, + getAppStoreData, + getCurrentPageNameByActionId, + isActionDirty, + isActionSaving, +} from "selectors/entitiesSelector"; +import { AppState } from "reducers"; +import { mapToPropList } from "utils/AppsmithUtils"; +import { validateResponse } from "sagas/ErrorSagas"; +import { DEFAULT_EXECUTE_ACTION_TIMEOUT_MS } from "constants/ApiConstants"; +import { + updateAppPersistentStore, + updateAppTransientStore, + setUrlData, +} from "actions/pageActions"; +import { getAppStoreName } from "constants/AppConstants"; +import { getType, Types } from "utils/TypeHelpers"; +import Taro from "@tarojs/taro"; +import { APP_MODE } from "entities/App"; +import { + getAppMode, + getCurrentApplication, +} from "selectors/applicationSelectors"; +import { + evaluateDynamicTrigger, + evaluateActionBindings, +} from "./EvaluationsSaga"; +// import { +// createMessage, +// ERROR_ACTION_EXECUTE_FAIL, +// ERROR_API_EXECUTE, +// ERROR_FAIL_ON_PAGE_LOAD_ACTIONS, +// ERROR_WIDGET_DOWNLOAD, +// } from "constants/messages"; +import { getWidgetByName } from "./selectors"; +import { + resetChildrenMetaProperty, + resetWidgetMetaProperty, +} from "actions/metaActions"; +import AppsmithConsole from "utils/AppsmithConsole"; +import { ENTITY_TYPE } from "entities/AppsmithConsole"; +import LOG_TYPE from "entities/AppsmithConsole/logtype"; +import { fetchPublishedPage } from "actions/pageActions"; +import { UrlDataState } from "reducers/entityReducers/appReducer"; + +type TypeOptions = any; +export const EMPTY_RESPONSE: ActionResponse = { + statusCode: "", + duration: "", + body: {}, + headers: {}, + request: { + headers: {}, + body: {}, + httpMethod: "", + url: "", + }, + size: "", +}; +const matchPath = (a: any, b: any) => null; + +enum ActionResponseDataTypes { + BINARY = "BINARY", +} + +export enum NavigationTargetType { + SAME_WINDOW = "SAME_WINDOW", + NEW_WINDOW = "NEW_WINDOW", +} + +const transpileArrawFunction = (s) => + s.replace( + /\(?(.*?)\)?\s*=>\s*([^]*)/, + (_, a, b) => `function(${a})${b[0] == "{" ? b : `{return ${b}}`}` + ); + +const MAIN_PAGE_PATH = "/pages/index/index"; +const LV1_PAGE_PATH = "/pages/page1/index"; + +function* navigateActionSaga( + action: { + pageNameOrUrl: string; + params: Record; + target?: NavigationTargetType; + }, + event: ExecuteActionPayloadEvent +) { + const pageList = yield select(getPageList); + const applicationId = yield select(getCurrentApplicationId); + const { pageNameOrUrl, params } = action; + const page = _.find( + pageList, + (page: Page) => page.pageName === pageNameOrUrl + ); + if (page) { + const currentPage = yield select(getCurrentPage); + const currentPageStacks = Taro.getCurrentPages(); + const onMainPage = currentPageStacks.length === 1; + const currentIsTab = !!currentPage.icon; + const targetIsTab = !!page.icon; + const queryParams = { + ...params, + applicationId, + pageId: page.pageId, + }; + const query = convertToQueryParams(queryParams); + + if (currentIsTab === targetIsTab) { + const urlData: UrlDataState = { + queryParams, + applicationId, + pageId: page.pageId, + }; + yield put(fetchPublishedPage(page.pageId, false, urlData)); + } else if (onMainPage) { + Taro.navigateTo({ + url: `${LV1_PAGE_PATH}${query}`, + }); + } else { + Taro.reLaunch({ + url: `${MAIN_PAGE_PATH}${query}`, + }); + } + + if (event.callback) event.callback({ success: true }); + } +} + +function* storeValueLocally( + action: { key: string; value: string; persist: boolean }, + event: ExecuteActionPayloadEvent +) { + try { + if (action.persist) { + const appId = yield select(getCurrentApplicationId); + const appStoreName = getAppStoreName(appId); + const existingStore = Taro.getStorageSync(appStoreName) || "{}"; + const parsedStore = JSON.parse(existingStore); + parsedStore[action.key] = action.value; + const storeString = JSON.stringify(parsedStore); + Taro.setStorageSync(appStoreName, storeString); + yield put(updateAppPersistentStore(parsedStore)); + } else { + const existingStore = yield select(getAppStoreData); + const newTransientStore = { + ...existingStore.transient, + [action.key]: action.value, + }; + yield put(updateAppTransientStore(newTransientStore)); + } + // Wait for an evaluation before completing this trigger effect + // This makes this trigger work in sync and not trigger + // another effect till the values are reflected in + // the dataTree + yield take(ReduxActionTypes.SET_EVALUATED_TREE); + if (event.callback) event.callback({ success: true }); + } catch (err) { + if (event.callback) event.callback({ success: false }); + } +} + +async function downloadSaga( + action: { data: any; name: string; type: string }, + event: ExecuteActionPayloadEvent +) {} + +function* copySaga( + payload: { + data: string; + options: { debug: boolean; format: string }; + }, + event: ExecuteActionPayloadEvent +) { + Taro.setClipboardData({ + data: payload.data, + success: () => { + if (event.callback) { + event.callback({ success: true }); + } + }, + }); +} + +function* resetWidgetMetaByNameRecursiveSaga( + payload: { widgetName: string; resetChildren: boolean }, + event: ExecuteActionPayloadEvent +) { + const fail = (msg: string) => { + console.error(msg); + if (event.callback) event.callback({ success: false }); + }; + if (typeof payload.widgetName !== "string") { + return fail("widgetName needs to be a string"); + } + + const widget = yield select(getWidgetByName, payload.widgetName); + if (!widget) { + return fail(`widget ${payload.widgetName} not found`); + } + + yield put(resetWidgetMetaProperty(widget.widgetId)); + if (payload.resetChildren) { + yield put(resetChildrenMetaProperty(widget.widgetId)); + } + + if (event.callback) event.callback({ success: true }); +} + +function* showAlertSaga( + payload: { message: string; style?: TypeOptions }, + event: ExecuteActionPayloadEvent +) { + if (typeof payload.message !== "string") { + console.error("Toast message needs to be a string"); + if (event.callback) event.callback({ success: false }); + return; + } + Taro.showToast({ + icon: payload.style, + title: payload.message, + }); + if (event.callback) event.callback({ success: true }); +} + +export const getActionTimeout = ( + state: AppState, + actionId: string +): number | undefined => { + const action = _.find( + state.entities.actions, + (a) => a.config.id === actionId + ); + if (action) { + const timeout = _.get( + action, + "config.actionConfiguration.timeoutInMillisecond", + DEFAULT_EXECUTE_ACTION_TIMEOUT_MS + ); + if (timeout) { + // Extra timeout padding to account for network calls + return timeout + 5000; + } + return undefined; + } + return undefined; +}; +const createActionExecutionResponse = ( + response: ActionExecutionResponse +): ActionResponse => { + const payload = response.data; + if (payload.statusCode === "200 OK" && payload.hasOwnProperty("headers")) { + const respHeaders = payload.headers; + if ( + respHeaders.hasOwnProperty(RESP_HEADER_DATATYPE) && + respHeaders[RESP_HEADER_DATATYPE].length > 0 && + respHeaders[RESP_HEADER_DATATYPE][0] === ActionResponseDataTypes.BINARY && + getType(payload.body) === Types.STRING + ) { + // Decoding from base64 to handle the binary files because direct + // conversion of binary files to string causes corruption in the final output + // this is to only handle the download of binary files + payload.body = atob(payload.body as string); + } + } + return { + ...payload, + ...response.clientMeta, + }; +}; +const isErrorResponse = (response: ActionExecutionResponse) => { + return !response.data.isExecutionSuccess; +}; + +/** + * Api1 + * URL: https://example.com/{{Text1.text}} + * Body: { + * "name": "{{this.params.name}}", + * "age": {{this.params.age}}, + * "gender": {{Dropdown1.selectedOptionValue}} + * } + * + * If you call + * Api1.run(undefined, undefined, { name: "Hetu", age: Input1.text }); + * + * executionParams is { name: "Hetu", age: Input1.text } + * bindings is [ + * "Text1.text", + * "Dropdown1.selectedOptionValue", + * "this.params.name", + * "this.params.age", + * ] + * + * Return will be [ + * { key: "Text1.text", value: "updateUser" }, + * { key: "Dropdown1.selectedOptionValue", value: "M" }, + * { key: "this.params.name", value: "Hetu" }, + * { key: "this.params.age", value: 26 }, + * ] + * @param bindings + * @param executionParams + */ +export function* evaluateActionParams( + bindings: string[] | undefined, + executionParams?: Record | string +) { + if (_.isNil(bindings) || bindings.length === 0) return []; + + // Evaluated all bindings of the actions. Pass executionParams if any + const values: any = yield call( + evaluateActionBindings, + bindings, + executionParams + ); + + // Convert to object and transform non string values + const actionParams: Record = {}; + bindings.forEach((key, i) => { + let value = values[i]; + if (typeof value === "object") value = JSON.stringify(value); + actionParams[key] = value; + }); + return mapToPropList(actionParams); +} + +export function* executeActionSaga( + apiAction: RunActionPayload, + event: ExecuteActionPayloadEvent +) { + const { actionId, onError, onSuccess, params } = apiAction; + const appMode = yield select(getAppMode); + try { + const api: Action = yield select(getAction, actionId); + log.debug(api); + if (api.confirmBeforeExecute) { + const confirmed = yield call(confirmRunActionSaga); + if (!confirmed) { + if (event.callback) { + event.callback({ success: false }); + } + return; + } + } + + yield put(executeApiActionRequest({ id: apiAction.actionId })); + const actionParams: Property[] = yield call( + evaluateActionParams, + api.jsonPathKeys, + params + ); + const pagination = + event.type === EventType.ON_NEXT_PAGE + ? "NEXT" + : event.type === EventType.ON_PREV_PAGE + ? "PREV" + : undefined; + + const executeActionRequest: ExecuteActionRequest = { + actionId: actionId, + params: actionParams, + paginationField: pagination, + viewMode: appMode === APP_MODE.PUBLISHED, + }; + log.debug("Execution started from widget request"); + const timeout = yield select(getActionTimeout, actionId); + const response: ActionExecutionResponse = yield ActionAPI.executeAction( + executeActionRequest, + timeout + ); + const payload = createActionExecutionResponse(response); + yield put( + executeApiActionSuccess({ + id: actionId, + response: payload, + }) + ); + if (isErrorResponse(response)) { + console.error(`Execution failed with status ${response.data.statusCode}`); + if (onError) { + yield put( + executeAction({ + dynamicString: onError, + event: { + ...event, + type: EventType.ON_ERROR, + }, + responseData: [payload.body, params], + }) + ); + } else { + if (event.callback) { + event.callback({ success: false }); + } + } + // Toaster.show({ + // text: createMessage(ERROR_API_EXECUTE, api.name), + // variant: Variant.danger, + // showDebugButton: true, + // }); + } else { + if (onSuccess) { + yield put( + executeAction({ + dynamicString: onSuccess, + event: { + ...event, + type: EventType.ON_SUCCESS, + }, + responseData: [payload.body, params], + }) + ); + } else { + if (event.callback) { + event.callback({ success: true }); + } + } + } + return response; + } catch (error) { + const api: Action = yield select(getAction, actionId); + yield put( + executeActionError({ + actionId: actionId, + error, + data: { + ...EMPTY_RESPONSE, + body: "There was an error executing this action", + }, + }) + ); + // Toaster.show({ + // text: createMessage(ERROR_API_EXECUTE, api.name), + // variant: Variant.danger, + // showDebugButton: true, + // }); + if (onError) { + yield put( + executeAction({ + dynamicString: `{{${onError}}}`, + event: { + ...event, + type: EventType.ON_ERROR, + }, + responseData: [], + }) + ); + } else { + if (event.callback) { + event.callback({ success: false }); + } + } + } +} + +function* executeActionTriggers( + trigger: ActionDescription, + event: ExecuteActionPayloadEvent +) { + try { + switch (trigger.type) { + case "RUN_ACTION": + yield call(executeActionSaga, trigger.payload, event); + break; + case "NAVIGATE_TO": + yield call(navigateActionSaga, trigger.payload, event); + break; + case "SHOW_ALERT": + yield call(showAlertSaga, trigger.payload, event); + break; + case "SHOW_MODAL_BY_NAME": + yield put(trigger); + if (event.callback) event.callback({ success: true }); + break; + case "CLOSE_MODAL": + yield put(trigger); + if (event.callback) event.callback({ success: true }); + break; + case "STORE_VALUE": + yield call(storeValueLocally, trigger.payload, event); + break; + case "DOWNLOAD": + yield call(downloadSaga, trigger.payload, event); + break; + case "COPY_TO_CLIPBOARD": + yield call(copySaga, trigger.payload, event); + break; + case "RESET_WIDGET_META_RECURSIVE_BY_NAME": + yield call(resetWidgetMetaByNameRecursiveSaga, trigger.payload, event); + break; + default: + log.error("Trigger type unknown", trigger.type); + } + } catch (e) { + if (event.callback) event.callback({ success: false }); + } +} + +function* executeAppAction(action: ReduxAction) { + const { dynamicString: es6String, event, responseData } = action.payload; + log.debug({ es6String, responseData }); + + // transpile default es6 arraw functions + const dynamicString = es6String.replace(/\(\) => [^)}]*[\)\}]/g, (t) => + transpileArrawFunction(t) + ); + log.debug(es6String, " ===> ", dynamicString); + + if (dynamicString === undefined) { + if (event.callback) event.callback({ success: false }); + log.error("Executing undefined action", event); + return; + } + + const triggers = yield call( + evaluateDynamicTrigger, + dynamicString, + responseData + ); + + log.debug({ triggers }); + if (triggers && triggers.length) { + yield all( + triggers.map((trigger: ActionDescription) => + call(executeActionTriggers, trigger, event) + ) + ); + } else { + if (event.callback) event.callback({ success: true }); + } +} + +function* runActionShortcutSaga() { + const location = window.location.pathname; + const match: any = matchPath(location, { + path: [ + API_EDITOR_URL(), + API_EDITOR_ID_URL(), + QUERIES_EDITOR_URL(), + QUERIES_EDITOR_ID_URL(), + API_EDITOR_URL_WITH_SELECTED_PAGE_ID(), + INTEGRATION_EDITOR_URL(), + ], + exact: true, + strict: false, + }); + if (!match || !match.params) return; + const { apiId, pageId, queryId } = match.params; + const actionId = apiId || queryId; + if (!actionId) return; + + yield put({ + type: ReduxActionTypes.RUN_ACTION_INIT, + payload: { + id: actionId, + }, + }); +} + +function* runActionInitSaga( + reduxAction: ReduxAction<{ + id: string; + paginationField: PaginationField; + }> +) { + const action = yield select(getAction, reduxAction.payload.id); + + if (action.confirmBeforeExecute) { + const confirmed = yield call(confirmRunActionSaga); + if (!confirmed) return; + } + + yield put({ + type: ReduxActionTypes.RUN_ACTION_REQUEST, + payload: reduxAction.payload, + }); +} + +function* runActionSaga( + reduxAction: ReduxAction<{ + id: string; + paginationField: PaginationField; + }> +) { + try { + const actionId = reduxAction.payload.id; + const isSaving = yield select(isActionSaving(actionId)); + const isDirty = yield select(isActionDirty(actionId)); + if (isSaving || isDirty) { + if (isDirty && !isSaving) { + yield put(updateAction({ id: actionId })); + } + yield take(ReduxActionTypes.UPDATE_ACTION_SUCCESS); + } + const actionObject = yield select(getAction, actionId); + const jsonPathKeys = actionObject.jsonPathKeys; + + const { paginationField } = reduxAction.payload; + + const params = yield call(evaluateActionParams, jsonPathKeys); + const timeout = yield select(getActionTimeout, actionId); + const appMode = yield select(getAppMode); + const viewMode = appMode === APP_MODE.PUBLISHED; + + const datasourceUrl = get( + actionObject, + "datasource.datasourceConfiguration.url" + ); + AppsmithConsole.info({ + text: "Execution started from user request", + source: { + type: ENTITY_TYPE.ACTION, + name: actionObject.name, + id: actionId, + }, + state: { + ...actionObject.actionConfiguration, + ...(datasourceUrl && { + url: datasourceUrl, + }), + }, + }); + + const response: ActionExecutionResponse = yield ActionAPI.executeAction( + { + actionId, + params, + paginationField, + viewMode, + }, + timeout + ); + const isValidResponse = yield validateResponse(response); + + if (isValidResponse) { + const payload = createActionExecutionResponse(response); + + const pageName = yield select(getCurrentPageNameByActionId, actionId); + let eventName: EventName = "RUN_API"; + if (actionObject.pluginType === PluginType.DB) { + eventName = "RUN_QUERY"; + } + if (actionObject.pluginType === PluginType.SAAS) { + eventName = "RUN_SAAS_API"; + } + + // AnalyticsUtil.logEvent(eventName, { + // actionId, + // actionName: actionObject.name, + // pageName: pageName, + // responseTime: response.clientMeta.duration, + // apiType: "INTERNAL", + // }); + + yield put({ + type: ReduxActionTypes.RUN_ACTION_SUCCESS, + payload: { [actionId]: payload }, + }); + if (payload.isExecutionSuccess) { + AppsmithConsole.info({ + logType: LOG_TYPE.ACTION_EXECUTION_SUCCESS, + text: "Executed successfully from user request", + timeTaken: response.clientMeta.duration, + source: { + type: ENTITY_TYPE.ACTION, + name: actionObject.name, + id: actionId, + }, + state: { + response: payload.body, + request: response.data.request, + }, + }); + } else { + AppsmithConsole.error({ + logType: LOG_TYPE.ACTION_EXECUTION_ERROR, + text: `Execution failed with status ${response.data.statusCode}`, + source: { + type: ENTITY_TYPE.ACTION, + name: actionObject.name, + id: actionId, + }, + messages: [ + { + message: !isString(payload.body) + ? JSON.stringify(payload.body) + : payload.body, + }, + ], + state: response.data?.request ?? null, + }); + + // Toaster.show({ + // text: createMessage(ERROR_ACTION_EXECUTE_FAIL, actionObject.name), + // variant: Variant.danger, + // }); + } + } else { + let error = "An unexpected error occurred"; + if (response.data.body) { + error = response.data.body.toString(); + } + + AppsmithConsole.error({ + logType: LOG_TYPE.ACTION_EXECUTION_ERROR, + text: `Execution failed with status ${response.data.statusCode} `, + source: { + type: ENTITY_TYPE.ACTION, + name: actionObject.name, + id: actionId, + }, + state: response.data?.request ?? null, + }); + + yield put({ + type: ReduxActionErrorTypes.RUN_ACTION_ERROR, + payload: { error, id: reduxAction.payload.id }, + }); + } + } catch (error) { + console.error(error); + yield put({ + type: ReduxActionErrorTypes.RUN_ACTION_ERROR, + payload: { error, id: reduxAction.payload.id }, + }); + } +} + +function* confirmRunActionSaga() { + yield put(showRunActionConfirmModal(true)); + + const { accept } = yield race({ + cancel: take(ReduxActionTypes.CANCEL_RUN_ACTION_CONFIRM_MODAL), + accept: take(ReduxActionTypes.ACCEPT_RUN_ACTION_CONFIRM_MODAL), + }); + + return !!accept; +} + +function* executePageLoadAction(pageAction: PageAction) { + try { + const pageId = yield select(getCurrentPageId); + let currentApp: ApplicationPayload = yield select(getCurrentApplication); + currentApp = currentApp || {}; + yield put(executeApiActionRequest({ id: pageAction.id })); + const params: Property[] = yield call( + evaluateActionParams, + pageAction.jsonPathKeys + ); + const appMode = yield select(getAppMode); + const viewMode = appMode === APP_MODE.PUBLISHED; + const executeActionRequest: ExecuteActionRequest = { + actionId: pageAction.id, + params, + viewMode, + }; + const response: ActionExecutionResponse = yield ActionAPI.executeAction( + executeActionRequest, + pageAction.timeoutInMillisecond + ); + if (isErrorResponse(response)) { + let body = _.get(response, "data.body"); + let message = `The action "${pageAction.name}" has failed.`; + if (body) { + if (_.isObject(body)) { + body = JSON.stringify(body); + } + message += `\nERROR: "${body}"`; + } + + AppsmithConsole.error({ + logType: LOG_TYPE.ACTION_EXECUTION_ERROR, + text: `Execution failed with status ${response.data.statusCode}`, + source: { + type: ENTITY_TYPE.ACTION, + name: pageAction.name, + id: pageAction.id, + }, + state: response.data?.request ?? null, + messages: [{ message: JSON.stringify(body) }], + }); + + yield put( + executeActionError({ + actionId: pageAction.id, + isPageLoad: true, + error: _.get(response, "responseMeta.error", { + message, + }), + data: createActionExecutionResponse(response), + }) + ); + } else { + const payload = createActionExecutionResponse(response); + yield put( + executeApiActionSuccess({ + id: pageAction.id, + response: payload, + isPageLoad: true, + }) + ); + yield take(ReduxActionTypes.SET_EVALUATED_TREE); + } + } catch (e) { + yield put( + executeActionError({ + actionId: pageAction.id, + isPageLoad: true, + error: { + message: `The action "${pageAction.name}" has failed.`, + }, + data: { + ...EMPTY_RESPONSE, + body: "There was an error executing this action", + }, + }) + ); + } +} + +function* executePageLoadActionsSaga() { + try { + const pageActions: PageAction[][] = yield select(getLayoutOnLoadActions); + const actionCount = _.flatten(pageActions).length; + for (const actionSet of pageActions) { + // Load all sets in parallel + yield* yield all( + actionSet.map((apiAction) => call(executePageLoadAction, apiAction)) + ); + } + + yield put(executePageLoadActionsComplete()); + } catch (e) { + log.error(e); + // Toaster.show({ + // text: createMessage(ERROR_FAIL_ON_PAGE_LOAD_ACTIONS), + // variant: Variant.danger, + // }); + } +} + +export function* watchActionExecutionSagas() { + yield all([ + takeEvery(ReduxActionTypes.EXECUTE_ACTION, executeAppAction), + takeLatest(ReduxActionTypes.RUN_ACTION_REQUEST, runActionSaga), + takeLatest(ReduxActionTypes.RUN_ACTION_INIT, runActionInitSaga), + takeLatest( + ReduxActionTypes.RUN_ACTION_SHORTCUT_REQUEST, + runActionShortcutSaga + ), + takeLatest( + ReduxActionTypes.EXECUTE_PAGE_LOAD_ACTIONS, + executePageLoadActionsSaga + ), + ]); +} diff --git a/app/taro/src/sagas/ActionSagas.ts b/app/taro/src/sagas/ActionSagas.ts new file mode 100644 index 0000000000..7cc3dec65d --- /dev/null +++ b/app/taro/src/sagas/ActionSagas.ts @@ -0,0 +1,770 @@ +import { + EvaluationReduxAction, + ReduxAction, + ReduxActionErrorTypes, + ReduxActionTypes, +} from "constants/ReduxActionConstants"; +import { + all, + call, + put, + select, + take, + takeEvery, + takeLatest, +} from "redux-saga/effects"; +import { Datasource } from "entities/Datasource"; +import ActionAPI, { ActionCreateUpdateResponse } from "api/ActionAPI"; +import { GenericApiResponse } from "api/ApiResponses"; +import PageApi from "api/PageApi"; +import { updateCanvasWithDSL } from "sagas/PageSagas"; +import { + copyActionError, + copyActionSuccess, + createActionRequest, + createActionSuccess, + deleteActionSuccess, + fetchActionsForPage, + fetchActionsForPageSuccess, + FetchActionsPayload, + moveActionError, + moveActionSuccess, + SetActionPropertyPayload, + updateAction, + updateActionProperty, + updateActionSuccess, +} from "actions/actionActions"; +import { + DynamicPath, + isChildPropertyPath, + isDynamicValue, + removeBindingsFromActionObject, +} from "utils/DynamicBindingUtils"; +import { validateResponse } from "./ErrorSagas"; +import { transformRestAction } from "transformers/RestActionTransformer"; +import { + getCurrentApplicationId, + getCurrentPageId, +} from "selectors/editorSelectors"; +import { Action, ActionViewMode, PluginType } from "entities/Action"; +import { ActionData } from "reducers/entityReducers/actionsReducer"; +import { + getAction, + getCurrentPageNameByActionId, + getEditorConfig, + getPageNameByPageId, + getPlugin, + getSettingConfig, + getDatasources, + getActions, +} from "selectors/entitiesSelector"; +import _, { merge, get } from "lodash"; +import { getConfigInitialValues } from "components/formControls/utils"; +import AppsmithConsole from "utils/AppsmithConsole"; +import { ENTITY_TYPE } from "entities/AppsmithConsole"; +import LOG_TYPE from "entities/AppsmithConsole/logtype"; +import { createNewApiAction } from "actions/apiPaneActions"; +import { createNewApiName, createNewQueryName } from "utils/AppsmithUtils"; +import { DEFAULT_API_ACTION_CONFIG } from "constants/ApiEditorConstants"; + +export function* createActionSaga( + actionPayload: ReduxAction< + Partial & { eventData: any; pluginId: string } + >, +) { + try { + let payload = actionPayload.payload; + if (actionPayload.payload.pluginId) { + const editorConfig = yield select( + getEditorConfig, + actionPayload.payload.pluginId, + ); + + const settingConfig = yield select( + getSettingConfig, + actionPayload.payload.pluginId, + ); + + let initialValues = yield call(getConfigInitialValues, editorConfig); + if (settingConfig) { + const settingInitialValues = yield call( + getConfigInitialValues, + settingConfig, + ); + initialValues = merge(initialValues, settingInitialValues); + } + payload = merge(initialValues, actionPayload.payload); + } + + const response: ActionCreateUpdateResponse = yield ActionAPI.createAction( + payload, + ); + const isValidResponse = yield validateResponse(response); + if (isValidResponse) { + const actionName = actionPayload.payload.name + ? actionPayload.payload.name + : ""; + // Toaster.show({ + // text: createMessage(ACTION_CREATED_SUCCESS, actionName), + // variant: Variant.success, + // }); + + const pageName = yield select( + getCurrentPageNameByActionId, + response.data.id, + ); + + // AnalyticsUtil.logEvent("CREATE_ACTION", { + // id: response.data.id, + // actionName: response.data.name, + // pageName: pageName, + // ...actionPayload.payload.eventData, + // }); + + AppsmithConsole.info({ + text: `Action created`, + source: { + type: ENTITY_TYPE.ACTION, + id: response.data.id, + name: response.data.name, + }, + }); + + const newAction = response.data; + yield put(createActionSuccess(newAction)); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.CREATE_ACTION_ERROR, + payload: actionPayload.payload, + }); + } +} + +export function* fetchActionsSaga( + action: EvaluationReduxAction, +) { + const { applicationId } = action.payload; + try { + const response: GenericApiResponse = yield ActionAPI.fetchActions( + applicationId, + ); + const isValidResponse = yield validateResponse(response); + if (isValidResponse) { + yield put({ + type: ReduxActionTypes.FETCH_ACTIONS_SUCCESS, + payload: response.data, + postEvalActions: action.postEvalActions, + }); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.FETCH_ACTIONS_ERROR, + payload: { error }, + }); + } +} + +export function* fetchActionsForViewModeSaga( + action: ReduxAction, +) { + const { applicationId } = action.payload; + try { + const response: GenericApiResponse = yield ActionAPI.fetchActionsForViewMode( + applicationId, + ); + const correctFormatResponse = response.data.map((action) => { + return { + ...action, + actionConfiguration: { + timeoutInMillisecond: action.timeoutInMillisecond, + }, + }; + }); + const isValidResponse = yield validateResponse(response); + if (isValidResponse) { + yield put({ + type: ReduxActionTypes.FETCH_ACTIONS_VIEW_MODE_SUCCESS, + payload: correctFormatResponse, + }); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.FETCH_ACTIONS_VIEW_MODE_ERROR, + payload: { error }, + }); + } +} + +export function* fetchActionsForPageSaga( + action: EvaluationReduxAction<{ pageId: string }>, +) { + const { pageId } = action.payload; + try { + const response: GenericApiResponse = yield call( + ActionAPI.fetchActionsByPageId, + pageId, + ); + const isValidResponse = yield validateResponse(response); + if (isValidResponse) { + yield put( + fetchActionsForPageSuccess(response.data, action.postEvalActions), + ); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.FETCH_ACTIONS_FOR_PAGE_ERROR, + payload: { error }, + }); + } +} + +export function* updateActionSaga(actionPayload: ReduxAction<{ id: string }>) { + try { + let action = yield select(getAction, actionPayload.payload.id); + if (!action) throw new Error("Could not find action to update"); + const isApi = action.pluginType === PluginType.API; + + if (isApi) { + action = transformRestAction(action); + } + + const response: GenericApiResponse = yield ActionAPI.updateAction( + action, + ); + const isValidResponse = yield validateResponse(response); + if (isValidResponse) { + const pageName = yield select( + getCurrentPageNameByActionId, + response.data.id, + ); + + // if (action.pluginType === PluginType.DB) { + // AnalyticsUtil.logEvent("SAVE_QUERY", { + // queryName: action.name, + // pageName, + // }); + // } else if (action.pluginType === PluginType.API) { + // AnalyticsUtil.logEvent("SAVE_API", { + // apiId: response.data.id, + // apiName: response.data.name, + // pageName: pageName, + // }); + // } else if (action.pluginType === PluginType.SAAS) { + // AnalyticsUtil.logEvent("SAVE_SAAS", { + // apiId: response.data.id, + // apiName: response.data.name, + // pageName: pageName, + // }); + // } + + yield put(updateActionSuccess({ data: response.data })); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.UPDATE_ACTION_ERROR, + payload: { error, id: actionPayload.payload.id }, + }); + } +} + +export function* deleteActionSaga( + actionPayload: ReduxAction<{ + id: string; + name: string; + onSuccess?: () => void; + }>, +) { + try { + const id = actionPayload.payload.id; + const name = actionPayload.payload.name; + const action: Action | undefined = yield select(getAction, id); + + if (!action) return; + + const isApi = action.pluginType === PluginType.API; + const isQuery = action.pluginType === PluginType.DB; + const isSaas = action.pluginType === PluginType.SAAS; + + const response: GenericApiResponse = yield ActionAPI.deleteAction( + id, + ); + const isValidResponse = yield validateResponse(response); + if (isValidResponse) { + // Toaster.show({ + // text: createMessage(ACTION_DELETE_SUCCESS, response.data.name), + // variant: Variant.success, + // }); + // if (isApi) { + // const pageName = yield select(getCurrentPageNameByActionId, id); + // AnalyticsUtil.logEvent("DELETE_API", { + // apiName: name, + // pageName, + // apiID: id, + // }); + // } + // if (isSaas) { + // const pageName = yield select(getCurrentPageNameByActionId, id); + // AnalyticsUtil.logEvent("DELETE_SAAS", { + // apiName: action.name, + // pageName, + // apiID: id, + // }); + // } + // if (isQuery) { + // AnalyticsUtil.logEvent("DELETE_QUERY", { + // queryName: action.name, + // }); + // } + + if (!!actionPayload.payload.onSuccess) { + actionPayload.payload.onSuccess(); + } else { + const applicationId = yield select(getCurrentApplicationId); + const pageId = yield select(getCurrentPageId); + + // history.push( + // INTEGRATION_EDITOR_URL(applicationId, pageId, INTEGRATION_TABS.NEW), + // ); + } + + AppsmithConsole.info({ + logType: LOG_TYPE.ENTITY_DELETED, + text: "Action was deleted", + source: { + type: ENTITY_TYPE.ACTION, + name: response.data.name, + id: response.data.id, + }, + analytics: { + pluginId: action.pluginId, + }, + }); + + yield put(deleteActionSuccess({ id })); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.DELETE_ACTION_ERROR, + payload: { error, id: actionPayload.payload.id }, + }); + } +} + +function* moveActionSaga( + action: ReduxAction<{ + id: string; + destinationPageId: string; + originalPageId: string; + name: string; + }>, +) { + const actionObject: Action = yield select(getAction, action.payload.id); + const withoutBindings = removeBindingsFromActionObject(actionObject); + try { + const response = yield ActionAPI.moveAction({ + action: { + ...withoutBindings, + pageId: action.payload.originalPageId, + name: action.payload.name, + }, + destinationPageId: action.payload.destinationPageId, + }); + + const isValidResponse = yield validateResponse(response); + const pageName = yield select(getPageNameByPageId, response.data.pageId); + if (isValidResponse) { + // Toaster.show({ + // text: createMessage(ACTION_MOVE_SUCCESS, response.data.name, pageName), + // variant: Variant.success, + // }); + } + + // AnalyticsUtil.logEvent("MOVE_API", { + // apiName: response.data.name, + // pageName: pageName, + // apiID: response.data.id, + // }); + yield put(moveActionSuccess(response.data)); + } catch (e) { + // Toaster.show({ + // text: createMessage(ERROR_ACTION_MOVE_FAIL, actionObject.name), + // variant: Variant.danger, + // }); + yield put( + moveActionError({ + id: action.payload.id, + originalPageId: action.payload.originalPageId, + }), + ); + } +} + +function* copyActionSaga( + action: ReduxAction<{ id: string; destinationPageId: string; name: string }>, +) { + let actionObject: Action = yield select(getAction, action.payload.id); + try { + if (!actionObject) throw new Error("Could not find action to copy"); + if (action.payload.destinationPageId !== actionObject.pageId) { + actionObject = removeBindingsFromActionObject(actionObject); + } + + const copyAction = Object.assign({}, actionObject, { + name: action.payload.name, + pageId: action.payload.destinationPageId, + }) as Partial; + delete copyAction.id; + const response = yield ActionAPI.createAction(copyAction); + const datasources = yield select(getDatasources); + + const isValidResponse = yield validateResponse(response); + const pageName = yield select(getPageNameByPageId, response.data.pageId); + if (isValidResponse) { + // Toaster.show({ + // text: createMessage(ACTION_COPY_SUCCESS, actionObject.name, pageName), + // variant: Variant.success, + // }); + } + + // AnalyticsUtil.logEvent("DUPLICATE_API", { + // apiName: response.data.name, + // pageName: pageName, + // apiID: response.data.id, + // }); + + // checking if there is existing datasource to be added to the action payload + const existingDatasource = datasources.find( + (d: Datasource) => d.id === response.data.datasource.id, + ); + + let payload = response.data; + + if (existingDatasource) { + payload = { ...payload, datasource: existingDatasource }; + } + + yield put(copyActionSuccess(payload)); + } catch (e) { + const actionName = actionObject ? actionObject.name : ""; + // Toaster.show({ + // text: createMessage(ERROR_ACTION_COPY_FAIL, actionName), + // variant: Variant.danger, + // }); + yield put(copyActionError(action.payload)); + } +} + +export function* refactorActionName( + id: string, + pageId: string, + oldName: string, + newName: string, +) { + // fetch page of the action + const pageResponse = yield call(PageApi.fetchPage, { + id: pageId, + }); + // check if page request is successful + const isPageRequestSuccessful = yield validateResponse(pageResponse); + if (isPageRequestSuccessful) { + // get the layoutId from the page response + const layoutId = pageResponse.data.layouts[0].id; + // call to refactor action + const refactorResponse = yield ActionAPI.updateActionName({ + layoutId, + actionId: id, + pageId: pageId, + oldName: oldName, + newName: newName, + }); + + const isRefactorSuccessful = yield validateResponse(refactorResponse); + + const currentPageId = yield select(getCurrentPageId); + + if (isRefactorSuccessful) { + yield put({ + type: ReduxActionTypes.SAVE_ACTION_NAME_SUCCESS, + payload: { + actionId: id, + }, + }); + if (currentPageId === pageId) { + yield updateCanvasWithDSL(refactorResponse.data, pageId, layoutId); + } else { + yield put(fetchActionsForPage(pageId)); + } + } + } +} + +function* bindDataOnCanvasSaga( + action: ReduxAction<{ + queryId: string; + applicationId: string; + pageId: string; + }>, +) { + // const { applicationId, pageId, queryId } = action.payload; + // history.push( + // BUILDER_PAGE_URL(applicationId, pageId, { + // isSnipingMode: "true", + // bindTo: queryId, + // }), + // ); +} + +function* saveActionName(action: ReduxAction<{ id: string; name: string }>) { + // Takes from state, checks if the name isValid, saves + const apiId = action.payload.id; + const api = yield select((state) => + state.entities.actions.find( + (action: ActionData) => action.config.id === apiId, + ), + ); + try { + yield refactorActionName( + api.config.id, + api.config.pageId, + api.config.name, + action.payload.name, + ); + } catch (e) { + yield put({ + type: ReduxActionErrorTypes.SAVE_ACTION_NAME_ERROR, + payload: { + actionId: action.payload.id, + oldName: api.config.name, + }, + }); + // Toaster.show({ + // text: createMessage(ERROR_ACTION_RENAME_FAIL, action.payload.name), + // variant: Variant.danger, + // }); + console.error(e); + } +} + +function getDynamicBindingsChangesSaga( + action: Action, + value: unknown, + field: string, +) { + const bindingField = field.replace("actionConfiguration.", ""); + let dynamicBindings: DynamicPath[] = action.dynamicBindingPathList || []; + + if (typeof value === "object") { + dynamicBindings = dynamicBindings.filter((dynamicPath) => { + if (isChildPropertyPath(bindingField, dynamicPath.key)) { + const childPropertyValue = _.get(value, dynamicPath.key); + return isDynamicValue(childPropertyValue); + } + }); + } else if (typeof value === "string") { + const fieldExists = _.some(dynamicBindings, { key: bindingField }); + + const isDynamic = isDynamicValue(value); + + if (!isDynamic && fieldExists) { + dynamicBindings = dynamicBindings.filter((d) => d.key !== bindingField); + } + if (isDynamic && !fieldExists) { + dynamicBindings.push({ key: bindingField }); + } + } + + return dynamicBindings; +} + +function* setActionPropertySaga(action: ReduxAction) { + const { actionId, propertyName, value } = action.payload; + if (!actionId) return; + if (propertyName === "name") return; + + const actionObj = yield select(getAction, actionId); + const fieldToBeUpdated = propertyName.replace( + "actionConfiguration", + "config", + ); + AppsmithConsole.info({ + logType: LOG_TYPE.ACTION_UPDATE, + text: "Configuration updated", + source: { + type: ENTITY_TYPE.ACTION, + name: actionObj.name, + id: actionId, + propertyPath: fieldToBeUpdated, + }, + state: { + [fieldToBeUpdated]: value, + }, + }); + + const effects: Record = {}; + // Value change effect + effects[propertyName] = value; + // Bindings change effect + effects.dynamicBindingPathList = getDynamicBindingsChangesSaga( + actionObj, + value, + propertyName, + ); + yield all( + Object.keys(effects).map((field) => + put(updateActionProperty({ id: actionId, field, value: effects[field] })), + ), + ); + if (propertyName === "executeOnLoad") { + yield put({ + type: ReduxActionTypes.TOGGLE_ACTION_EXECUTE_ON_LOAD_INIT, + payload: { + actionId, + shouldExecute: value, + }, + }); + return; + } + yield put(updateAction({ id: actionId })); +} + +function* toggleActionExecuteOnLoadSaga( + action: ReduxAction<{ actionId: string; shouldExecute: boolean }>, +) { + try { + const response = yield call( + ActionAPI.toggleActionExecuteOnLoad, + action.payload.actionId, + action.payload.shouldExecute, + ); + const isValidResponse = yield validateResponse(response); + if (isValidResponse) { + yield put({ + type: ReduxActionTypes.TOGGLE_ACTION_EXECUTE_ON_LOAD_SUCCESS, + }); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.TOGGLE_ACTION_EXECUTE_ON_LOAD_ERROR, + payload: error, + }); + } +} + +function* handleMoveOrCopySaga(actionPayload: ReduxAction<{ id: string }>) { + const { id } = actionPayload.payload; + const action: Action = yield select(getAction, id); + const isApi = action.pluginType === PluginType.API; + const isQuery = action.pluginType === PluginType.DB; + const isSaas = action.pluginType === PluginType.DB; + const applicationId = yield select(getCurrentApplicationId); + + // if (isApi) { + // history.push(API_EDITOR_ID_URL(applicationId, action.pageId, action.id)); + // } + // if (isQuery) { + // history.push( + // QUERIES_EDITOR_ID_URL(applicationId, action.pageId, action.id), + // ); + // } + // if (isSaas) { + // const plugin = yield select(getPlugin, action.pluginId); + // history.push( + // SAAS_EDITOR_API_ID_URL( + // applicationId, + // action.pageId, + // plugin.packageName, + // action.id, + // ), + // ); + // } +} + +function* executeCommand( + actionPayload: ReduxAction<{ + actionType: string; + callback: (binding: string) => void; + args: any; + }>, +) { + const pageId = yield select(getCurrentPageId); + const applicationId = yield select(getCurrentApplicationId); + switch (actionPayload.payload.actionType) { + case "NEW_INTEGRATION": + // history.push( + // INTEGRATION_EDITOR_URL(applicationId, pageId, INTEGRATION_TABS.NEW), + // ); + break; + case "NEW_QUERY": + const datasource = get(actionPayload, "payload.args.datasource"); + const pluginId = get(datasource, "pluginId"); + const plugin = yield select(getPlugin, pluginId); + const actions = yield select(getActions); + const pageActions = actions.filter( + (a: ActionData) => a.config.pageId === pageId, + ); + const newQueryName = + plugin.type === PluginType.DB + ? createNewQueryName(actions, pageId) + : createNewApiName(pageActions, pageId); + const nextPayload: Partial = { + name: newQueryName, + pageId, + eventData: { + actionType: "Query", + from: "Quick-Commands", + dataSource: datasource.name, + }, + pluginId: datasource.pluginId, + actionConfiguration: {}, + }; + if (plugin.type === "API") { + nextPayload.datasource = datasource; + nextPayload.actionConfiguration = DEFAULT_API_ACTION_CONFIG; + } else { + nextPayload.datasource = { + id: datasource.id, + }; + } + yield put(createActionRequest(nextPayload)); + const QUERY = yield take(ReduxActionTypes.CREATE_ACTION_SUCCESS); + actionPayload.payload.callback(`{{${QUERY.payload.name}.data}}`); + break; + case "NEW_API": + yield put(createNewApiAction(pageId, "QUICK_COMMANDS")); + const API = yield take(ReduxActionTypes.CREATE_ACTION_SUCCESS); + actionPayload.payload.callback(`{{${API.payload.name}.data}}`); + break; + } +} + +export function* watchActionSagas() { + yield all([ + takeEvery(ReduxActionTypes.SET_ACTION_PROPERTY, setActionPropertySaga), + takeEvery(ReduxActionTypes.FETCH_ACTIONS_INIT, fetchActionsSaga), + takeEvery( + ReduxActionTypes.FETCH_ACTIONS_VIEW_MODE_INIT, + fetchActionsForViewModeSaga, + ), + takeEvery(ReduxActionTypes.CREATE_ACTION_INIT, createActionSaga), + takeLatest(ReduxActionTypes.UPDATE_ACTION_INIT, updateActionSaga), + takeLatest(ReduxActionTypes.DELETE_ACTION_INIT, deleteActionSaga), + takeLatest(ReduxActionTypes.BIND_DATA_ON_CANVAS, bindDataOnCanvasSaga), + takeLatest(ReduxActionTypes.SAVE_ACTION_NAME_INIT, saveActionName), + takeLatest(ReduxActionTypes.MOVE_ACTION_INIT, moveActionSaga), + takeLatest(ReduxActionTypes.COPY_ACTION_INIT, copyActionSaga), + takeLatest( + ReduxActionTypes.FETCH_ACTIONS_FOR_PAGE_INIT, + fetchActionsForPageSaga, + ), + takeEvery(ReduxActionTypes.MOVE_ACTION_SUCCESS, handleMoveOrCopySaga), + takeEvery(ReduxActionTypes.COPY_ACTION_SUCCESS, handleMoveOrCopySaga), + takeEvery(ReduxActionErrorTypes.MOVE_ACTION_ERROR, handleMoveOrCopySaga), + takeEvery(ReduxActionErrorTypes.COPY_ACTION_ERROR, handleMoveOrCopySaga), + takeLatest( + ReduxActionTypes.TOGGLE_ACTION_EXECUTE_ON_LOAD_INIT, + toggleActionExecuteOnLoadSaga, + ), + takeLatest(ReduxActionTypes.EXECUTE_COMMAND, executeCommand), + ]); +} diff --git a/app/taro/src/sagas/ApplicationSagas.tsx b/app/taro/src/sagas/ApplicationSagas.tsx new file mode 100644 index 0000000000..239865298a --- /dev/null +++ b/app/taro/src/sagas/ApplicationSagas.tsx @@ -0,0 +1,37 @@ +import { + ReduxAction, + ReduxActionErrorTypes, + ReduxActionTypes, +} from "constants/ReduxActionConstants"; +import ApplicationApi, { FetchApplicationResponse } from "api/ApplicationApi"; +import { all, call, put, takeLatest } from "redux-saga/effects"; +import { FetchApplicationPayload } from "actions/applicationActions"; + +export function* fetchApplicationSaga( + action: ReduxAction +) { + try { + const { applicationId } = action.payload; + const response: FetchApplicationResponse = yield call( + ApplicationApi.fetchApplicationForViewMode, + applicationId + ); + yield put({ + type: ReduxActionTypes.FETCH_APPLICATION_SUCCESS, + payload: response.data, + }); + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.FETCH_APPLICATION_ERROR, + payload: { + error, + }, + }); + } +} + +export default function* applicationSagas() { + yield all([ + takeLatest(ReduxActionTypes.FETCH_APPLICATION_INIT, fetchApplicationSaga), + ]); +} diff --git a/app/taro/src/sagas/BatchSagas.tsx b/app/taro/src/sagas/BatchSagas.tsx new file mode 100644 index 0000000000..e6d458996b --- /dev/null +++ b/app/taro/src/sagas/BatchSagas.tsx @@ -0,0 +1,76 @@ +/* eslint-disable @typescript-eslint/ban-ts-comment */ +import _ from "lodash"; +import { put, debounce, takeEvery, all } from "redux-saga/effects"; +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { batchActionSuccess } from "../actions/batchActions"; + +const BATCH_PRIORITY = { + [ReduxActionTypes.SET_META_PROP]: { + priority: 0, + needsSaga: false, + }, + [ReduxActionTypes.RESET_WIDGET_META]: { + priority: 0, + needsSaga: false, + }, + [ReduxActionTypes.UPDATE_WIDGET_PROPERTY]: { + priority: 0, + needsSaga: false, + }, + [ReduxActionTypes.EXECUTE_ACTION]: { + priority: 1, + needsSaga: true, + }, + [ReduxActionTypes.EXECUTE_PAGE_LOAD_ACTIONS]: { + priority: 1, + needsSaga: true, + }, + [ReduxActionTypes.UPDATE_ACTION_PROPERTY]: { + priority: 0, + needsSaga: false, + }, + [ReduxActionTypes.UPDATE_ACTION_INIT]: { + priority: 1, + needsSaga: true, + }, +}; + +const batches: ReduxAction[][] = []; + +function* storeUpdatesSaga(action: ReduxAction>) { + try { + const priority = BATCH_PRIORITY[action.payload.type].priority; + const currentPriorityBatch = batches[priority] || []; + currentPriorityBatch.push(action.payload); + _.set(batches, `[${priority}]`, currentPriorityBatch); + yield put({ type: ReduxActionTypes.EXECUTE_BATCH }); + } catch (e) { + console.error(`${action.payload.type} action priority not set`); + } +} + +function* executeBatchSaga() { + for (let priority = 0; priority < batches.length; priority++) { + const batch = batches[priority]; + if (Array.isArray(batch) && batch.length) { + const needsSaga = batch.filter((b) => BATCH_PRIORITY[b.type].needsSaga); + const canBatch = batch.filter((b) => !BATCH_PRIORITY[b.type].needsSaga); + batches[priority] = []; + // @ts-ignore: No types available + yield put(canBatch); + if (needsSaga.length) { + for (const sagaAction of needsSaga) { + yield put(sagaAction); + } + } + yield put(batchActionSuccess(batch)); + } + } +} + +export default function* root() { + yield all([ + debounce(20, ReduxActionTypes.EXECUTE_BATCH, executeBatchSaga), + takeEvery(ReduxActionTypes.BATCHED_UPDATE, storeUpdatesSaga), + ]); +} diff --git a/app/taro/src/sagas/DebuggerSagas.ts b/app/taro/src/sagas/DebuggerSagas.ts new file mode 100644 index 0000000000..6c77b78c12 --- /dev/null +++ b/app/taro/src/sagas/DebuggerSagas.ts @@ -0,0 +1,324 @@ +import { + debuggerLog, + errorLog, + logDebuggerErrorAnalytics, + LogDebuggerErrorAnalyticsPayload, + updateErrorLog, +} from "actions/debuggerActions"; +import { ReduxAction, ReduxActionTypes } from "constants/ReduxActionConstants"; +import { + ENTITY_TYPE, + LogActionPayload, + Message, +} from "entities/AppsmithConsole"; +import { + all, + call, + fork, + put, + select, + take, + takeEvery, +} from "redux-saga/effects"; +import { get, set } from "lodash"; +import { getDebuggerErrors } from "selectors/debuggerSelectors"; +import { + getAction, + getPlugin, + getPluginNameFromId, +} from "selectors/entitiesSelector"; +import { Action, PluginType } from "entities/Action"; +import LOG_TYPE from "entities/AppsmithConsole/logtype"; +import { DataTree } from "entities/DataTree/dataTreeFactory"; +import { + getDataTree, + getEvaluationInverseDependencyMap, +} from "selectors/dataTreeSelectors"; +import { + getEntityNameAndPropertyPath, + isAction, + isWidget, +} from "workers/evaluationUtils"; +import { getDependencyChain } from "components/editorComponents/Debugger/helpers"; +import { + ACTION_CONFIGURATION_UPDATED, + createMessage, + WIDGET_PROPERTIES_UPDATED, +} from "constants/messages"; +import AnalyticsUtil from "utils/AnalyticsUtil"; +import { Plugin } from "api/PluginApi"; +import { getCurrentPageId } from "selectors/editorSelectors"; +import { getWidget } from "./selectors"; +import { WidgetProps } from "widgets/BaseWidget"; + +function* formatActionRequestSaga(payload: LogActionPayload, request?: any) { + if (!payload.source || !payload.state || !request || !request.headers) { + return; + } + + const headers = request.headers; + + const source = payload.source; + const action: Action | undefined = yield select(getAction, source.id); + if (action && action.pluginType === PluginType.API) { + let formattedHeaders = []; + + // Convert headers from Record[] to Record[] + // for showing in the logs + formattedHeaders = Object.keys(headers).map((key: string) => { + const value = headers[key]; + return { + [key]: value[0], + }; + }); + + return formattedHeaders; + } else { + return; + } +} + +function* onEntityDeleteSaga(payload: Message) { + const source = payload.source; + + if (!source) { + yield put(debuggerLog(payload)); + return; + } + const currentPageId = yield select(getCurrentPageId); + let pluginName: string = yield select( + getPluginNameFromId, + payload?.analytics?.pluginId, + ); + + const errors: Record = yield select(getDebuggerErrors); + const errorIds = Object.keys(errors); + const updatedErrors: any = {}; + + errorIds.map((e) => { + const includes = e.includes(source.id); + + if (!includes) { + updatedErrors[e] = errors[e]; + } else { + // If the error is being removed here + // need to send an analytics event for the same + const error = errors[e]; + pluginName = pluginName.replace(/ /g, ""); + + if (source.type === ENTITY_TYPE.ACTION) { + AnalyticsUtil.logEvent("DEBUGGER_RESOLVED_ERROR", { + entityType: pluginName, + propertyPath: `${pluginName}.${error.source?.propertyPath ?? ""}`, + errorMessages: error.messages, + pageId: currentPageId, + }); + } else if (source.type === ENTITY_TYPE.WIDGET) { + const widgetType = error?.analytics?.widgetType; + + AnalyticsUtil.logEvent("DEBUGGER_RESOLVED_ERROR", { + entityType: widgetType, + propertyPath: `${widgetType}.${error.source?.propertyPath ?? ""}`, + errorMessages: error.messages, + pageId: currentPageId, + }); + } + } + }); + + yield put({ + type: ReduxActionTypes.DEBUGGER_UPDATE_ERROR_LOGS, + payload: updatedErrors, + }); + yield put(debuggerLog(payload)); +} + +function* logDependentEntityProperties(payload: Message) { + const { source, state } = payload; + if (!state || !source) return; + + yield take(ReduxActionTypes.SET_EVALUATED_TREE); + const dataTree: DataTree = yield select(getDataTree); + + const propertyPath = `${source.name}.` + payload.source?.propertyPath; + const inverseDependencyMap = yield select(getEvaluationInverseDependencyMap); + const finalValue = getDependencyChain(propertyPath, inverseDependencyMap); + + yield all( + finalValue.map((path) => { + const entityInfo = getEntityNameAndPropertyPath(path); + const entity = dataTree[entityInfo.entityName]; + let log = { + ...payload, + state: { + [entityInfo.propertyPath]: get(dataTree, path), + }, + }; + + if (isAction(entity)) { + log = { + ...log, + text: createMessage(ACTION_CONFIGURATION_UPDATED), + source: { + type: ENTITY_TYPE.ACTION, + name: entityInfo.entityName, + id: entity.actionId, + }, + }; + } else if (isWidget(entity)) { + log = { + ...log, + text: createMessage(WIDGET_PROPERTIES_UPDATED), + source: { + type: ENTITY_TYPE.WIDGET, + name: entityInfo.entityName, + id: entity.widgetId, + }, + }; + } + + return put(debuggerLog(log)); + }), + ); +} + +function* debuggerLogSaga(action: ReduxAction) { + const { payload } = action; + const debuggerErrors: Record = yield select( + getDebuggerErrors, + ); + + switch (payload.logType) { + case LOG_TYPE.WIDGET_UPDATE: + yield put(debuggerLog(payload)); + yield call(logDependentEntityProperties, payload); + return; + case LOG_TYPE.ACTION_UPDATE: + yield put(debuggerLog(payload)); + yield call(logDependentEntityProperties, payload); + return; + case LOG_TYPE.EVAL_ERROR: + case LOG_TYPE.WIDGET_PROPERTY_VALIDATION_ERROR: + if (payload.source && payload.source.propertyPath) { + if (payload.text) { + yield put(errorLog(payload)); + + yield put(debuggerLog(payload)); + } + } + break; + case LOG_TYPE.ACTION_EXECUTION_ERROR: + { + const res = yield call(formatActionRequestSaga, payload, payload.state); + const log = { ...payload }; + res && set(log, "state.headers", res); + if (!((payload.source?.id as string) in debuggerErrors)) { + yield put( + logDebuggerErrorAnalytics({ + eventName: "DEBUGGER_NEW_ERROR", + errorMessages: payload.messages ?? [], + entityType: ENTITY_TYPE.ACTION, + entityId: payload.source?.id ?? "", + entityName: payload.source?.name ?? "", + propertyPath: "", + }), + ); + } + + yield put(errorLog(log)); + yield put(debuggerLog(log)); + } + break; + case LOG_TYPE.ACTION_EXECUTION_SUCCESS: + { + const res = yield call( + formatActionRequestSaga, + payload, + payload.state?.request ?? {}, + ); + + if ((payload.source?.id as string) in debuggerErrors) { + yield put( + logDebuggerErrorAnalytics({ + eventName: "DEBUGGER_RESOLVED_ERROR", + errorMessages: + debuggerErrors[payload.source?.id ?? ""].messages ?? [], + entityType: ENTITY_TYPE.ACTION, + entityId: payload.source?.id ?? "", + entityName: payload.source?.name ?? "", + propertyPath: "", + }), + ); + } + yield put( + updateErrorLog({ + ...payload, + state: {}, + }), + ); + + const log = { ...payload }; + res && set(log, "state.request.headers", res); + yield put(debuggerLog(log)); + } + break; + case LOG_TYPE.ENTITY_DELETED: + yield fork(onEntityDeleteSaga, payload); + break; + default: + yield put(debuggerLog(payload)); + } +} + +// This saga is intended for analytics only +function* logDebuggerErrorAnalyticsSaga( + action: ReduxAction, +) { + try { + const { payload } = action; + const currentPageId = yield select(getCurrentPageId); + + if (payload.entityType === ENTITY_TYPE.WIDGET) { + const widget: WidgetProps = yield select(getWidget, payload.entityId); + const widgetType = widget.type; + const propertyPath = `${widgetType}.${payload.propertyPath}`; + + // Sending widget type for widgets + AnalyticsUtil.logEvent(payload.eventName, { + entityType: widgetType, + propertyPath, + errorMessages: payload.errorMessages, + pageId: currentPageId, + }); + } else if (payload.entityType === ENTITY_TYPE.ACTION) { + const action: Action = yield select(getAction, payload.entityId); + const plugin: Plugin = yield select(getPlugin, action.pluginId); + const pluginName = plugin.name.replace(/ /g, ""); + let propertyPath = `${pluginName}`; + + if (payload.propertyPath) { + propertyPath += `.${payload.propertyPath}`; + } + + // Sending plugin name for actions + AnalyticsUtil.logEvent(payload.eventName, { + entityType: pluginName, + propertyPath, + errorMessages: payload.errorMessages, + pageId: currentPageId, + }); + } + } catch (e) { + console.error(e); + } +} + +export default function* debuggerSagasListeners() { + yield all([ + takeEvery(ReduxActionTypes.DEBUGGER_LOG_INIT, debuggerLogSaga), + takeEvery( + ReduxActionTypes.DEBUGGER_ERROR_ANALYTICS, + logDebuggerErrorAnalyticsSaga, + ), + ]); +} diff --git a/app/taro/src/sagas/ErrorSagas.tsx b/app/taro/src/sagas/ErrorSagas.tsx new file mode 100644 index 0000000000..ed890f2457 --- /dev/null +++ b/app/taro/src/sagas/ErrorSagas.tsx @@ -0,0 +1,271 @@ +import { get } from "lodash"; +import { + ReduxActionTypes, + ReduxActionErrorTypes, + ReduxAction, +} from "constants/ReduxActionConstants"; +import log from "loglevel"; +import { ApiResponse } from "api/ApiResponses"; +import { flushErrors } from "actions/errorActions"; +import { ERROR_CODES, SERVER_ERROR_CODES } from "constants/ApiConstants"; +import { getSafeCrash } from "selectors/errorSelectors"; +import { getCurrentUser } from "selectors/usersSelectors"; +import { ANONYMOUS_USERNAME } from "constants/userConstants"; +import { put, takeLatest, call, select } from "redux-saga/effects"; +import { + ERROR_401, + ERROR_500, + ERROR_0, + DEFAULT_ERROR_MESSAGE, + createMessage, +} from "constants/messages"; +import Taro from '@tarojs/taro'; + +/** + * making with error message with action name + * + * @param action + */ +export const getDefaultActionError = (action: string) => + `Incurred an error when ${action}`; + +export function* callAPI(apiCall: any, requestPayload: any) { + try { + return yield call(apiCall, requestPayload); + } catch (error) { + return yield error; + } +} + +/** + * transforn server errors to client error codes + * + * @param code + */ +const getErrorMessage = (code: number) => { + switch (code) { + case 401: + return createMessage(ERROR_401); + case 500: + return createMessage(ERROR_500); + case 0: + return createMessage(ERROR_0); + } +}; + +export class IncorrectBindingError extends Error {} + +/** + * validates if response does have any errors + * + * @param response + * @param show + */ +export function* validateResponse(response: ApiResponse | any, show = true) { + if (!response) { + throw Error(""); + } + if (!response.responseMeta && !response.status) { + throw Error(getErrorMessage(0)); + } + if (!response.responseMeta && response.status) { + throw Error(getErrorMessage(response.status)); + } + if (response.responseMeta.success) { + return true; + } else { + if ( + response.responseMeta.error.code === + SERVER_ERROR_CODES.INCORRECT_BINDING_LIST_OF_WIDGET + ) { + throw new IncorrectBindingError(response.responseMeta.error.message); + } else { + yield put({ + type: ReduxActionErrorTypes.API_ERROR, + payload: { + error: response.responseMeta.error, + show, + }, + }); + throw Error(response.responseMeta.error.message); + } + } +} + +export function getResponseErrorMessage(response: ApiResponse) { + return response.responseMeta.error + ? response.responseMeta.error.message + : undefined; +} + +type ErrorPayloadType = { + code?: number | string; + message?: string; + crash?: boolean; +}; +const ActionErrorDisplayMap: { + [key: string]: (error: ErrorPayloadType) => string; +} = { + [ReduxActionErrorTypes.API_ERROR]: (error) => + get(error, "message", createMessage(DEFAULT_ERROR_MESSAGE)), + [ReduxActionErrorTypes.FETCH_PAGE_ERROR]: () => + getDefaultActionError("fetching the page"), + [ReduxActionErrorTypes.SAVE_PAGE_ERROR]: () => + getDefaultActionError("saving the page"), +}; + +const getErrorMessageFromActionType = ( + type: string, + error: ErrorPayloadType, +): string => { + const actionErrorMessage = get(error, "message"); + if (actionErrorMessage === undefined) { + if (type in ActionErrorDisplayMap) { + return ActionErrorDisplayMap[type](error); + } + return createMessage(DEFAULT_ERROR_MESSAGE); + } + return actionErrorMessage; +}; + +enum ErrorEffectTypes { + SHOW_ALERT = "SHOW_ALERT", + SAFE_CRASH = "SAFE_CRASH", + LOG_ERROR = "LOG_ERROR", + LOG_TO_SENTRY = "LOG_TO_SENTRY", +} + +export interface ErrorActionPayload { + error: ErrorPayloadType; + show?: boolean; + crash?: boolean; + logToSentry?: boolean; +} + +export function* errorSaga(errorAction: ReduxAction) { + const effects = [ErrorEffectTypes.LOG_ERROR]; + const { payload, type } = errorAction; + const { error, logToSentry, show = true } = payload || {}; + const message = getErrorMessageFromActionType(type, error); + + if (show) { + effects.push(ErrorEffectTypes.SHOW_ALERT); + } + + if (error && error.crash) { + effects.push(ErrorEffectTypes.SAFE_CRASH); + } + + if (error && logToSentry) { + effects.push(ErrorEffectTypes.LOG_TO_SENTRY); + } + + for (const effect of effects) { + switch (effect) { + case ErrorEffectTypes.LOG_ERROR: { + logErrorSaga(errorAction); + break; + } + case ErrorEffectTypes.SHOW_ALERT: { + showAlertAboutError(message); + break; + } + case ErrorEffectTypes.SAFE_CRASH: { + yield call(crashAppSaga, error); + break; + } + case ErrorEffectTypes.LOG_TO_SENTRY: { + // yield call(Sentry.captureException, error); + break; + } + } + } + + yield put({ + type: ReduxActionTypes.REPORT_ERROR, + payload: { + source: errorAction.type, + message, + }, + }); +} + +function logErrorSaga(action: ReduxAction<{ error: ErrorPayloadType }>) { + log.debug(`Error in action ${action.type}`); + if (action.payload) log.error(action.payload.error); +} + +function showAlertAboutError(message: string) { + // Toaster.show({ text: message, variant: Variant.danger }); + Taro.showModal({ + title: '出错啦 :(', + content: message, + showCancel: false, + }); +} + +function* crashAppSaga(error: ErrorPayloadType) { + yield put({ + type: ReduxActionTypes.SAFE_CRASH_APPSMITH, + payload: error, + }); +} + +/** + * this saga do some logic before actually setting safeCrash to true + */ +function* safeCrashSagaRequest(action: ReduxAction<{ code?: string }>) { + const user = yield select(getCurrentUser); + const code = get(action, "payload.code"); + + // if user is not logged and the error is "PAGE_NOT_FOUND", + // redirecting user to login page with redirecTo param + if ( + get(user, "email") === ANONYMOUS_USERNAME && + code === ERROR_CODES.PAGE_NOT_FOUND + ) { + // window.location.href = `${AUTH_LOGIN_URL}?redirectUrl=${window.location.href}`; + Taro.showModal({ + title: '未登录', + showCancel: false, + }); + return false; + } + + // if there is no action to be done, just calling the safe crash action + yield put({ + type: ReduxActionTypes.SAFE_CRASH_APPSMITH, + payload: { + code, + }, + }); +} + +/** + * flush errors and redirect users to a url + * + * @param action + */ +export function* flushErrorsAndRedirectSaga( + action: ReduxAction<{ url?: string }>, +) { + const safeCrash = yield select(getSafeCrash); + + if (safeCrash) { + yield put(flushErrors()); + } + + // history.push(action.payload.url); +} + +export default function* errorSagas() { + yield takeLatest(Object.values(ReduxActionErrorTypes), errorSaga); + yield takeLatest( + ReduxActionTypes.FLUSH_AND_REDIRECT, + flushErrorsAndRedirectSaga, + ); + yield takeLatest( + ReduxActionTypes.SAFE_CRASH_APPSMITH_REQUEST, + safeCrashSagaRequest, + ); +} diff --git a/app/taro/src/sagas/EvaluationsSaga.ts b/app/taro/src/sagas/EvaluationsSaga.ts new file mode 100644 index 0000000000..97f2455ad1 --- /dev/null +++ b/app/taro/src/sagas/EvaluationsSaga.ts @@ -0,0 +1,227 @@ +import { + actionChannel, + call, + fork, + put, + select, + take, +} from "redux-saga/effects"; +import { + EvaluationReduxAction, + ReduxAction, + ReduxActionTypes, + ReduxActionWithoutPayload, +} from "constants/ReduxActionConstants"; +import { + getDataTree, + getUnevaluatedDataTree, +} from "selectors/dataTreeSelectors"; +import WidgetFactory, { WidgetTypeConfigMap } from "../utils/WidgetFactory"; +import { GracefulWorkerService } from "utils/WorkerUtil"; +import { EVAL_WORKER_ACTIONS } from "utils/DynamicBindingUtils"; +import log from "loglevel"; +import { WidgetProps } from "widgets/BaseWidget"; +import { Action } from "redux"; +import { + EVALUATE_REDUX_ACTIONS, + FIRST_EVAL_REDUX_ACTIONS, + setDependencyMap, + setEvaluatedTree, + shouldProcessBatchedAction, +} from "actions/evaluationActions"; +import { + evalErrorHandler, + postEvalActionDispatcher, +} from "./PostEvaluationSagas"; + +let widgetTypeConfigMap: WidgetTypeConfigMap; + +const worker = new GracefulWorkerService(); + +function* evaluateTreeSaga( + postEvalActions?: Array | ReduxActionWithoutPayload>, +) { + const unevalTree = yield select(getUnevaluatedDataTree); + log.debug({ unevalTree }); + const workerResponse = yield call( + worker.request, + EVAL_WORKER_ACTIONS.EVAL_TREE, + { + unevalTree, + widgetTypeConfigMap, + }, + ); + const { + dataTree, + dependencies, + errors, + evaluationOrder, + logs, + unEvalUpdates, + updates, + } = workerResponse; + + yield put(setEvaluatedTree(dataTree, updates)); + + const updatedDataTree = yield select(getDataTree); + log.debug({ dataTree: updatedDataTree }); + logs.forEach((evalLog: any) => log.debug(evalLog)); + + yield call(evalErrorHandler, errors, updatedDataTree, evaluationOrder); + yield put(setDependencyMap(dependencies)); + + if (postEvalActions && postEvalActions.length) { + yield call(postEvalActionDispatcher, postEvalActions); + } +} + +export function* evaluateActionBindings( + bindings: string[], + executionParams: Record | string = {}, +) { + const workerResponse = yield call( + worker.request, + EVAL_WORKER_ACTIONS.EVAL_ACTION_BINDINGS, + { + bindings, + executionParams, + }, + ); + + const { errors, values } = workerResponse; + + yield call(evalErrorHandler, errors); + return values; +} + +export function* evaluateDynamicTrigger( + dynamicTrigger: string, + callbackData?: Array, +) { + const unEvalTree = yield select(getUnevaluatedDataTree); + + const workerResponse = yield call( + worker.request, + EVAL_WORKER_ACTIONS.EVAL_TRIGGER, + { dataTree: unEvalTree, dynamicTrigger, callbackData }, + ); + + const { errors, triggers } = workerResponse; + yield call(evalErrorHandler, errors); + return triggers; +} + +export function* clearEvalCache() { + yield call(worker.request, EVAL_WORKER_ACTIONS.CLEAR_CACHE); + + return true; +} + +export function* clearEvalPropertyCache(propertyPath: string) { + yield call(worker.request, EVAL_WORKER_ACTIONS.CLEAR_PROPERTY_CACHE, { + propertyPath, + }); +} + +/** + * clears all cache keys of a widget + * + * @param widgetName + */ +export function* clearEvalPropertyCacheOfWidget(widgetName: string) { + yield call( + worker.request, + EVAL_WORKER_ACTIONS.CLEAR_PROPERTY_CACHE_OF_WIDGET, + { + widgetName, + }, + ); +} + +export function* validateProperty( + property: string, + value: any, + props: WidgetProps, +) { + const unevalTree = yield select(getUnevaluatedDataTree); + const validation = unevalTree[props.widgetName].validationPaths[property]; + return yield call(worker.request, EVAL_WORKER_ACTIONS.VALIDATE_PROPERTY, { + property, + value, + props, + validation, + }); +} + +function evalQueueBuffer() { + let canTake = false; + let postEvalActions: any = []; + const take = () => { + if (canTake) { + const resp = postEvalActions; + postEvalActions = []; + canTake = false; + return { postEvalActions: resp, type: "BUFFERED_ACTION" }; + } + }; + const flush = () => { + if (canTake) { + return [take() as Action]; + } + + return []; + }; + + const put = (action: EvaluationReduxAction) => { + if (!shouldProcessBatchedAction(action)) { + return; + } + canTake = true; + + // TODO: If the action is the same as before, we can send only one and ignore duplicates. + if (action.postEvalActions) { + postEvalActions.push(...action.postEvalActions); + } + }; + + return { + take, + put, + isEmpty: () => { + return !canTake; + }, + flush, + }; +} + +function* evaluationChangeListenerSaga() { + // Explicitly shutdown old worker if present + yield call(worker.shutdown); + yield call(worker.start); + widgetTypeConfigMap = WidgetFactory.getWidgetTypeConfigMap(); + const initAction = yield take(FIRST_EVAL_REDUX_ACTIONS); + yield fork(evaluateTreeSaga, initAction.postEvalActions); + const evtActionChannel = yield actionChannel( + EVALUATE_REDUX_ACTIONS, + evalQueueBuffer(), + ); + while (true) { + const action: EvaluationReduxAction = yield take( + evtActionChannel, + ); + if (shouldProcessBatchedAction(action)) { + yield call(evaluateTreeSaga, action.postEvalActions); + } + } +} + +export default function* evaluationSagaListeners() { + yield take(ReduxActionTypes.START_EVALUATION); + while (true) { + try { + yield call(evaluationChangeListenerSaga); + } catch (e) { + log.error(e); + } + } +} diff --git a/app/taro/src/sagas/InitSagas.ts b/app/taro/src/sagas/InitSagas.ts new file mode 100644 index 0000000000..9675618ff6 --- /dev/null +++ b/app/taro/src/sagas/InitSagas.ts @@ -0,0 +1,114 @@ +import { get } from "lodash"; +import { + all, + call, + put, + race, + select, + take, + takeLatest, +} from "redux-saga/effects"; +import { + ReduxAction, + ReduxActionErrorTypes, + ReduxActionTypes, +} from "constants/ReduxActionConstants"; +import { ERROR_CODES } from "constants/ApiConstants"; + +import { + fetchPageList, + fetchPublishedPage, + setAppMode, + updateAppPersistentStore, +} from "actions/pageActions"; +import { fetchActionsForView } from "actions/actionActions"; +import { fetchApplication } from "actions/applicationActions"; +import { APP_MODE } from "entities/App"; +import { getPersistentAppStore } from "constants/AppConstants"; +import { getDefaultPageId } from "./selectors"; + +export function* initializeAppViewerSaga( + action: ReduxAction<{ applicationId: string; pageId?: string }>, +) { + const { applicationId, pageId } = action.payload; + yield put(setAppMode(APP_MODE.PUBLISHED)); + yield put(updateAppPersistentStore(getPersistentAppStore(applicationId))); + yield put({ type: ReduxActionTypes.START_EVALUATION }); + yield all([ + put(fetchActionsForView(applicationId)), + put(fetchPageList(applicationId, APP_MODE.PUBLISHED)), + put(fetchApplication(applicationId, APP_MODE.PUBLISHED)), + ]); + + const resultOfPrimaryCalls = yield race({ + success: all([ + take(ReduxActionTypes.FETCH_ACTIONS_VIEW_MODE_SUCCESS), + take(ReduxActionTypes.FETCH_PAGE_LIST_SUCCESS), + take(ReduxActionTypes.FETCH_APPLICATION_SUCCESS), + ]), + failure: take([ + ReduxActionErrorTypes.FETCH_ACTIONS_VIEW_MODE_ERROR, + ReduxActionErrorTypes.FETCH_PAGE_LIST_ERROR, + ReduxActionErrorTypes.FETCH_APPLICATION_ERROR, + ]), + }); + + if (resultOfPrimaryCalls.failure) { + yield put({ + type: ReduxActionTypes.SAFE_CRASH_APPSMITH_REQUEST, + payload: { + code: get( + resultOfPrimaryCalls, + "failure.payload.error.code", + ERROR_CODES.SERVER_ERROR, + ), + }, + }); + return; + } + + const defaultPageId = yield select(getDefaultPageId); + const toLoadPageId = pageId || defaultPageId; + + if (toLoadPageId) { + yield put(fetchPublishedPage(toLoadPageId, true)); + + const resultOfFetchPage = yield race({ + success: take(ReduxActionTypes.FETCH_PUBLISHED_PAGE_SUCCESS), + failure: take(ReduxActionErrorTypes.FETCH_PUBLISHED_PAGE_ERROR), + }); + + if (resultOfFetchPage.failure) { + yield put({ + type: ReduxActionTypes.SAFE_CRASH_APPSMITH_REQUEST, + payload: { + code: get( + resultOfFetchPage, + "failure.payload.error.code", + ERROR_CODES.SERVER_ERROR, + ), + }, + }); + return; + } + + yield put({ + type: ReduxActionTypes.INITIALIZE_PAGE_VIEWER_SUCCESS, + }); + + // if ("serviceWorker" in navigator) { + // yield put({ + // type: ReduxActionTypes.FETCH_ALL_PUBLISHED_PAGES, + // }); + // } + } +} + +export default function* watchInitSagas() { + yield all([ + takeLatest( + ReduxActionTypes.INITIALIZE_PAGE_VIEWER, + initializeAppViewerSaga, + ), + ]); +} diff --git a/app/taro/src/sagas/ModalSagas.ts b/app/taro/src/sagas/ModalSagas.ts new file mode 100644 index 0000000000..54a497603d --- /dev/null +++ b/app/taro/src/sagas/ModalSagas.ts @@ -0,0 +1,198 @@ +import { + all, + select, + call, + put, + takeLatest, + takeEvery, + delay, +} from "redux-saga/effects"; + +import { generateReactKey } from "utils/generators"; +import { WidgetAddChild } from "actions/pageActions"; +import { + MAIN_CONTAINER_WIDGET_ID, + WidgetTypes, +} from "constants/WidgetConstants"; +import { + ReduxActionErrorTypes, + ReduxActionTypes, + ReduxAction, + WidgetReduxActionTypes, +} from "constants/ReduxActionConstants"; + +import { + getWidgets, + getWidgetByName, + getWidgetsMeta, + getWidgetIdsByType, + getWidgetMetaProps, +} from "sagas/selectors"; +import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; +import { updateWidgetMetaProperty } from "actions/metaActions"; +import { focusWidget } from "actions/widgetActions"; +import log from "loglevel"; +import { flatten } from "lodash"; + +export function* createModalSaga(action: ReduxAction<{ modalName: string }>) { + try { + const modalWidgetId = generateReactKey(); + const props: WidgetAddChild = { + widgetId: MAIN_CONTAINER_WIDGET_ID, + widgetName: action.payload.modalName, + type: WidgetTypes.TARO_POPUP_WIDGET, + newWidgetId: modalWidgetId, + parentRowSpace: 10, + parentColumnSpace: 1, + leftColumn: 0, + topRow: 0, + columns: 0, + rows: 40, + tabId: "", + }; + yield put({ + type: WidgetReduxActionTypes.WIDGET_ADD_CHILD, + payload: props, + }); + + yield put({ + type: ReduxActionTypes.SHOW_MODAL, + payload: { modalId: modalWidgetId }, + }); + } catch (error) { + log.error(error); + yield put({ + type: ReduxActionErrorTypes.CREATE_MODAL_ERROR, + payload: { error }, + }); + } +} + +export function* showModalByNameSaga( + action: ReduxAction<{ modalName: string }> +) { + const widgets: { [widgetId: string]: FlattenedWidgetProps } = yield select( + getWidgets + ); + const modal: FlattenedWidgetProps | undefined = Object.values(widgets).find( + (widget: FlattenedWidgetProps) => + widget.widgetName === action.payload.modalName + ); + if (modal) { + yield put({ + type: ReduxActionTypes.SHOW_MODAL, + payload: { + modalId: modal.widgetId, + }, + }); + } +} + +export function* showIfModalSaga( + action: ReduxAction<{ widgetId: string; type: string }> +) { + if (action.payload.type === WidgetTypes.TARO_POPUP_WIDGET) { + yield put({ + type: ReduxActionTypes.SHOW_MODAL, + payload: { modalId: action.payload.widgetId }, + }); + } +} + +export function* showModalSaga(action: ReduxAction<{ modalId: string }>) { + // First we close the currently open modals (if any) + // Notice the empty payload. + yield call(closeModalSaga, { + type: ReduxActionTypes.CLOSE_MODAL, + payload: { + exclude: action.payload.modalId, + }, + }); + + yield put({ + type: ReduxActionTypes.SELECT_WIDGET_INIT, + payload: { widgetId: action.payload.modalId }, + }); + yield put(focusWidget(action.payload.modalId)); + + const metaProps = yield select(getWidgetMetaProps, action.payload.modalId); + if (!metaProps || !metaProps.isVisible) { + // Then show the modal we would like to show. + yield put( + updateWidgetMetaProperty(action.payload.modalId, "isVisible", true) + ); + yield delay(1000); + } + yield put({ + type: ReduxActionTypes.SHOW_PROPERTY_PANE, + payload: { + widgetId: action.payload.modalId, + callForDragOrResize: undefined, + force: true, + }, + }); +} + +export function* closeModalSaga( + action: ReduxAction<{ modalName?: string; exclude?: string }> +) { + try { + const { modalName } = action.payload; + let widgetIds: string[] = []; + // If modalName is provided, we just want to close this modal + if (modalName) { + const widget = yield select(getWidgetByName, modalName); + widgetIds = [widget.widgetId]; + yield put({ + type: ReduxActionTypes.SHOW_PROPERTY_PANE, + payload: {}, + }); + } else { + // If modalName is not provided, find all open modals + // Get all meta prop records + const metaProps: Record = yield select(getWidgetsMeta); + + // Get widgetIds of all widgets of type MODAL_WIDGET + const modalWidgetIds: string[] = yield select( + getWidgetIdsByType, + WidgetTypes.TARO_POPUP_WIDGET + ); + + // Loop through all modal widgetIds + modalWidgetIds.forEach((widgetId: string) => { + // Check if modal is open + if (metaProps[widgetId] && metaProps[widgetId].isVisible) { + // Add to our list of widgetIds + widgetIds.push(widgetId); + } + }); + } + widgetIds = action.payload.exclude + ? widgetIds.filter((id: string) => id !== action.payload.exclude) + : widgetIds; + // If we have modals to close, set its isVisible to false to close. + if (widgetIds) { + yield all( + flatten( + widgetIds.map((widgetId: string) => { + return [ + put(updateWidgetMetaProperty(widgetId, "isVisible", false)), + ]; + }) + ) + ); + } + } catch (error) { + log.error(error); + } +} + +export default function* modalSagas() { + yield all([ + takeEvery(ReduxActionTypes.CLOSE_MODAL, closeModalSaga), + takeLatest(ReduxActionTypes.CREATE_MODAL_INIT, createModalSaga), + takeLatest(ReduxActionTypes.SHOW_MODAL, showModalSaga), + takeLatest(ReduxActionTypes.SHOW_MODAL_BY_NAME, showModalByNameSaga), + takeLatest(WidgetReduxActionTypes.WIDGET_CHILD_ADDED, showIfModalSaga), + ]); +} diff --git a/app/taro/src/sagas/PageSagas.tsx b/app/taro/src/sagas/PageSagas.tsx new file mode 100644 index 0000000000..a8b99e13c4 --- /dev/null +++ b/app/taro/src/sagas/PageSagas.tsx @@ -0,0 +1,352 @@ +import CanvasWidgetsNormalizer from "normalizers/CanvasWidgetsNormalizer"; +import { AppState } from "reducers"; +import { + Page, + PageListPayload, + ReduxAction, + ReduxActionErrorTypes, + ReduxActionTypes, + UpdateCanvasPayload, +} from "constants/ReduxActionConstants"; +import { + FetchPageListPayload, + fetchPageSuccess, + fetchPublishedPageSuccess, + setUrlData, + initCanvasLayout, + updateCurrentPage, + saveLayout, + setLastUpdatedTime, +} from "actions/pageActions"; +import PageApi, { + FetchPageListResponse, + FetchPageRequest, + FetchPageResponse, + FetchPublishedPageRequest, + FetchPublishedPageResponse, + PageLayout, +} from "api/PageApi"; +import { all, call, put, select, takeLatest } from "redux-saga/effects"; +import { + checkIfMigrationIsNeeded, + extractCurrentDSL, +} from "utils/WidgetPropsUtils"; +import { getAllPageIds } from "./selectors"; +import { validateResponse } from "./ErrorSagas"; +import { executePageLoadActions } from "actions/widgetActions"; +import { + getCurrentApplicationId, + getCurrentPageId, + getCurrentPageName, +} from "selectors/editorSelectors"; +import { fetchActionsForPage } from "actions/actionActions"; +import { clearEvalCache } from "./EvaluationsSaga"; +import log from "loglevel"; +import DEFAULT_TEMPLATE from "templates/default"; +import Taro from "@tarojs/taro"; +import { UrlDataState } from "reducers/entityReducers/appReducer"; + +export function* fetchPageListSaga( + fetchPageListAction: ReduxAction +) { + try { + const { applicationId } = fetchPageListAction.payload; + const apiCall = PageApi.fetchPageListViewMode; + const response: FetchPageListResponse = yield call(apiCall, applicationId); + const isValidResponse: boolean = yield validateResponse(response); + if (isValidResponse) { + const orgId = response.data.organizationId; + const pages: PageListPayload = response.data.pages.map((page) => ({ + pageName: page.name, + pageId: page.id, + isDefault: page.isDefault, + isHidden: !!page.isHidden, + icon: page.icon, + })); + yield put({ + type: ReduxActionTypes.SET_CURRENT_ORG_ID, + payload: { + orgId, + }, + }); + yield put({ + type: ReduxActionTypes.FETCH_PAGE_LIST_SUCCESS, + payload: { + pages, + applicationId, + }, + }); + } else { + yield put({ + type: ReduxActionErrorTypes.FETCH_PAGE_LIST_ERROR, + payload: { + error: response.responseMeta.error, + }, + }); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.FETCH_PAGE_LIST_ERROR, + payload: { + error, + }, + }); + } +} + +export const getCanvasWidgetsPayload = ( + pageResponse: FetchPageResponse +): UpdateCanvasPayload => { + const normalizedResponse = CanvasWidgetsNormalizer.normalize( + extractCurrentDSL(pageResponse) + ); + return { + pageWidgetId: normalizedResponse.result, + currentPageName: pageResponse.data.name, + currentPageId: pageResponse.data.id, + widgets: normalizedResponse.entities.canvasWidgets, + currentLayoutId: pageResponse.data.layouts[0].id, // TODO(abhinav): Handle for multiple layouts + currentApplicationId: pageResponse.data.applicationId, + pageActions: pageResponse.data.layouts[0].layoutOnLoadActions || [], + }; +}; + +function* handleFetchedPage({ + fetchPageResponse, + isFirstLoad = false, + pageId, +}: { + fetchPageResponse: FetchPageResponse; + pageId: string; + isFirstLoad?: boolean; +}) { + const isValidResponse = yield validateResponse(fetchPageResponse); + const willPageBeMigrated = checkIfMigrationIsNeeded(fetchPageResponse); + const lastUpdatedTime = getLastUpdateTime(fetchPageResponse); + + if (isValidResponse) { + // Clear any existing caches + yield call(clearEvalCache); + // Get Canvas payload + const canvasWidgetsPayload = getCanvasWidgetsPayload(fetchPageResponse); + // Update the canvas + yield put(initCanvasLayout(canvasWidgetsPayload)); + // set current page + yield put(updateCurrentPage(pageId)); + // Set url params + yield call(setDataUrl); + // dispatch fetch page success + yield put( + fetchPageSuccess( + // Execute page load actions post page load + isFirstLoad ? [] : [executePageLoadActions()] + ) + ); + // Sets last updated time + yield put(setLastUpdatedTime(lastUpdatedTime)); + const extractedDSL = extractCurrentDSL(fetchPageResponse); + yield put({ + type: ReduxActionTypes.UPDATE_CANVAS_STRUCTURE, + payload: extractedDSL, + }); + + if (willPageBeMigrated) { + yield put(saveLayout()); + } + } +} +const getLastUpdateTime = (pageResponse: FetchPageResponse): number => + pageResponse.data.lastUpdatedTime; + +export function* fetchPageSaga( + pageRequestAction: ReduxAction +) { + try { + const { id, isFirstLoad } = pageRequestAction.payload; + const fetchPageResponse: FetchPageResponse = yield call(PageApi.fetchPage, { + id, + }); + yield handleFetchedPage({ + fetchPageResponse, + pageId: id, + isFirstLoad, + }); + } catch (error) { + log.error(error); + yield put({ + type: ReduxActionErrorTypes.FETCH_PAGE_ERROR, + payload: { + error, + }, + }); + } +} + +export function* fetchPublishedPageSaga( + pageRequestAction: ReduxAction<{ + pageId: string; + bustCache: boolean; + urlData?: UrlDataState; + }> +) { + try { + const { bustCache, pageId, urlData } = pageRequestAction.payload; + const request: FetchPublishedPageRequest = { + pageId, + bustCache, + }; + const response: FetchPublishedPageResponse = yield call( + PageApi.fetchPublishedPage, + request + ); + const isValidResponse: boolean = yield validateResponse(response); + if (isValidResponse) { + // update navigator title + if (response.data?.name) { + Taro.setNavigationBarTitle({ + title: response.data?.name, + }); + } + // Clear any existing caches + yield call(clearEvalCache); + // Get Canvas payload + const canvasWidgetsPayload = getCanvasWidgetsPayload(response); + // Update the canvas + yield put(initCanvasLayout(canvasWidgetsPayload)); + // set current page + yield put(updateCurrentPage(pageId)); + // Set url params + yield call(setDataUrl, urlData); + // dispatch fetch page success + yield put( + fetchPublishedPageSuccess( + // Execute page load actions post published page eval + [executePageLoadActions()] + ) + ); + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.FETCH_PUBLISHED_PAGE_ERROR, + payload: { + error, + }, + }); + } +} + +export function* fetchAllPublishedPagesSaga() { + try { + const pageIds = yield select(getAllPageIds); + yield all( + pageIds.map((pageId: string) => { + return call(PageApi.fetchPublishedPage, { pageId }); + }) + ); + } catch (error) { + log.error({ error }); + } +} + +export function* updateCanvasWithDSL( + data: PageLayout, + pageId: string, + layoutId: string +) { + const normalizedWidgets = CanvasWidgetsNormalizer.normalize(data.dsl); + const currentPageName = yield select(getCurrentPageName); + const applicationId = yield select(getCurrentApplicationId); + const canvasWidgetsPayload: UpdateCanvasPayload = { + pageWidgetId: normalizedWidgets.result, + currentPageName, + currentPageId: pageId, + currentLayoutId: layoutId, + currentApplicationId: applicationId, + pageActions: data.layoutOnLoadActions, + widgets: normalizedWidgets.entities.canvasWidgets, + }; + yield put(initCanvasLayout(canvasWidgetsPayload)); + yield put(fetchActionsForPage(pageId)); +} + +function* fetchPageDSLSaga(pageId: string) { + try { + const fetchPageResponse: FetchPageResponse = yield call(PageApi.fetchPage, { + id: pageId, + }); + const isValidResponse: boolean = yield validateResponse(fetchPageResponse); + if (isValidResponse) { + return { + pageId: pageId, + dsl: extractCurrentDSL(fetchPageResponse), + }; + } + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.FETCH_PAGE_DSL_ERROR, + payload: { + pageId: pageId, + error, + show: true, + }, + }); + return { + pageId: pageId, + dsl: DEFAULT_TEMPLATE, + }; + } +} + +export function* populatePageDSLsSaga() { + try { + yield put({ + type: ReduxActionTypes.POPULATE_PAGEDSLS_INIT, + }); + const pageIds: string[] = yield select((state: AppState) => + state.entities.pageList.pages.map((page: Page) => page.pageId) + ); + const pageDSLs = yield all( + pageIds.map((pageId: string) => { + return call(fetchPageDSLSaga, pageId); + }) + ); + yield put({ + type: ReduxActionTypes.FETCH_PAGE_DSLS_SUCCESS, + payload: pageDSLs, + }); + } catch (error) { + yield put({ + type: ReduxActionErrorTypes.POPULATE_PAGEDSLS_ERROR, + payload: { + error, + }, + }); + } +} + +export function* setDataUrl(inputData?: UrlDataState) { + const queryParams: any = Taro.getCurrentInstance().router?.params || {}; + const applicationId = yield select(getCurrentApplicationId); + const pageId = yield select(getCurrentPageId); + const urlData: UrlDataState = { + queryParams, + applicationId, + pageId, + }; + yield put(setUrlData(inputData || urlData)); +} + +export default function* pageSagas() { + yield all([ + takeLatest(ReduxActionTypes.FETCH_PAGE_INIT, fetchPageSaga), + takeLatest( + ReduxActionTypes.FETCH_PUBLISHED_PAGE_INIT, + fetchPublishedPageSaga + ), + takeLatest(ReduxActionTypes.FETCH_PAGE_LIST_INIT, fetchPageListSaga), + takeLatest( + ReduxActionTypes.FETCH_ALL_PUBLISHED_PAGES, + fetchAllPublishedPagesSaga + ), + ]); +} diff --git a/app/taro/src/sagas/PostEvaluationSagas.ts b/app/taro/src/sagas/PostEvaluationSagas.ts new file mode 100644 index 0000000000..7757e78004 --- /dev/null +++ b/app/taro/src/sagas/PostEvaluationSagas.ts @@ -0,0 +1,216 @@ +import { DataTree } from "entities/DataTree/dataTreeFactory"; +// import { ENTITY_TYPE, Message } from "entities/AppsmithConsole"; +// import { +// getEntityNameAndPropertyPath, +// isAction, +// isWidget, +// } from "workers/evaluationUtils"; +import { + EvalError, + EvalErrorTypes, + EvaluationError, + getEvalErrorPath, + getEvalValuePath, + PropertyEvalErrorTypeDebugMessage, + PropertyEvaluationErrorType, +} from "utils/DynamicBindingUtils"; +import _ from "lodash"; +// import LOG_TYPE from "../entities/AppsmithConsole/logtype"; +// import dayjs from "dayjs"; +import { put, select } from "redux-saga/effects"; +import { + ReduxAction, + ReduxActionTypes, + ReduxActionWithoutPayload, +} from "constants/ReduxActionConstants"; +import log from "loglevel"; +// import { AppState } from "reducers"; +// import { logDebuggerErrorAnalytics } from "actions/debuggerActions"; +// import store from "../store"; + +// polyfill +const performance = Date; + +// const getDebuggerErrors = (state: AppState) => state.ui.debugger.errors; + +// function getLatestEvalPropertyErrors( +// currentDebuggerErrors: Record, +// dataTree: DataTree, +// evaluationOrder: Array, +// ) { +// const updatedDebuggerErrors: Record = { +// ...currentDebuggerErrors, +// }; + +// for (const evaluatedPath of evaluationOrder) { +// const { entityName, propertyPath } = getEntityNameAndPropertyPath( +// evaluatedPath, +// ); +// const entity = dataTree[entityName]; +// if (isWidget(entity) || isAction(entity)) { +// if (propertyPath in entity.logBlackList) { +// continue; +// } +// const allEvalErrors: EvaluationError[] = _.get( +// entity, +// getEvalErrorPath(evaluatedPath, false), +// [], +// ); +// const evaluatedValue = _.get( +// entity, +// getEvalValuePath(evaluatedPath, false), +// ); +// const evalErrors = allEvalErrors.filter( +// (error) => error.errorType !== PropertyEvaluationErrorType.LINT, +// ); +// const idField = isWidget(entity) ? entity.widgetId : entity.actionId; +// const nameField = isWidget(entity) ? entity.widgetName : entity.name; +// const entityType = isWidget(entity) +// ? ENTITY_TYPE.WIDGET +// : ENTITY_TYPE.ACTION; +// const debuggerKey = idField + "-" + propertyPath; +// // if dataTree has error but debugger does not -> add +// // if debugger has error and data tree has error -> update error +// // if debugger has error but data tree does not -> remove +// // if debugger or data tree does not have an error -> no change + +// if (evalErrors.length) { +// // TODO Rank and set the most critical error +// const error = evalErrors[0]; +// const errorMessages = evalErrors.map((e) => ({ +// message: e.errorMessage, +// })); + +// if (!(debuggerKey in updatedDebuggerErrors)) { +// store.dispatch( +// logDebuggerErrorAnalytics({ +// eventName: "DEBUGGER_NEW_ERROR", +// entityId: idField, +// entityName: nameField, +// entityType, +// propertyPath, +// errorMessages, +// }), +// ); +// } + +// const analyticsData = isWidget(entity) +// ? { +// widgetType: entity.type, +// } +// : {}; + +// // Add or update +// updatedDebuggerErrors[debuggerKey] = { +// logType: LOG_TYPE.EVAL_ERROR, +// text: PropertyEvalErrorTypeDebugMessage[error.errorType]( +// propertyPath, +// ), +// messages: errorMessages, +// severity: error.severity, +// timestamp: dayjs().format("hh:mm:ss"), +// source: { +// id: idField, +// name: nameField, +// type: entityType, +// propertyPath: propertyPath, +// }, +// state: { +// [propertyPath]: evaluatedValue, +// }, +// analytics: analyticsData, +// }; +// } else if (debuggerKey in updatedDebuggerErrors) { +// store.dispatch( +// logDebuggerErrorAnalytics({ +// eventName: "DEBUGGER_RESOLVED_ERROR", +// entityId: idField, +// entityName: nameField, +// entityType, +// propertyPath: +// updatedDebuggerErrors[debuggerKey].source?.propertyPath ?? "", +// errorMessages: updatedDebuggerErrors[debuggerKey].messages ?? [], +// }), +// ); +// // Remove +// delete updatedDebuggerErrors[debuggerKey]; +// } +// } +// } +// return updatedDebuggerErrors; +// } + +export function* evalErrorHandler( + errors: EvalError[], + dataTree?: DataTree, + evaluationOrder?: Array, +): any { + // if (dataTree && evaluationOrder) { + // const currentDebuggerErrors: Record = yield select( + // getDebuggerErrors, + // ); + // const evalPropertyErrors = getLatestEvalPropertyErrors( + // currentDebuggerErrors, + // dataTree, + // evaluationOrder, + // ); + + // yield put({ + // type: ReduxActionTypes.DEBUGGER_UPDATE_ERROR_LOGS, + // payload: evalPropertyErrors, + // }); + // } + + errors.forEach((error) => { + switch (error.type) { + case EvalErrorTypes.CYCLICAL_DEPENDENCY_ERROR: { + log.debug(error); + if (error.context) { + // Add more info about node for the toast + // Toaster.show({ + // text: `${error.message} Node was: ${node}`, + // variant: Variant.danger, + // }); + } + break; + } + case EvalErrorTypes.EVAL_TREE_ERROR: { + log.debug(error); + // Toaster.show({ + // text: createMessage(ERROR_EVAL_ERROR_GENERIC), + // variant: Variant.danger, + // }); + break; + } + case EvalErrorTypes.BAD_UNEVAL_TREE_ERROR: { + // Sentry.captureException(error); + break; + } + case EvalErrorTypes.EVAL_TRIGGER_ERROR: { + log.debug(error); + // Toaster.show({ + // text: createMessage(ERROR_EVAL_TRIGGER, error.message), + // variant: Variant.danger, + // showDebugButton: true, + // }); + break; + } + case EvalErrorTypes.EVAL_PROPERTY_ERROR: { + log.debug(error); + break; + } + default: { + // Sentry.captureException(error); + log.debug(error); + } + } + }); +} + +export function* postEvalActionDispatcher( + actions: Array | ReduxActionWithoutPayload>, +) { + for (const action of actions) { + yield put(action); + } +} diff --git a/app/taro/src/sagas/WidgetEnhancementHelpers.ts b/app/taro/src/sagas/WidgetEnhancementHelpers.ts new file mode 100644 index 0000000000..fe27e2614c --- /dev/null +++ b/app/taro/src/sagas/WidgetEnhancementHelpers.ts @@ -0,0 +1,230 @@ +import { + MAIN_CONTAINER_WIDGET_ID, + WidgetType, +} from "constants/WidgetConstants"; +import { get, set } from "lodash"; +import WidgetConfigResponse from "mockResponses/WidgetConfigResponse"; +import { useSelector } from "react-redux"; +import { AppState } from "reducers"; +import { CanvasWidgetsReduxState } from "reducers/entityReducers/canvasWidgetsReducer"; +import { select } from "redux-saga/effects"; +import { getWidgets } from "./selectors"; + +/* +TODO(abhinav/pawan): Write unit tests for the following functions +Note: +Signature for enhancements in WidgetConfigResponse is as follows: +enhancements: { + child: { + autocomplete: (parentProps: any) => Record>, + customJSControl: (parentProps: any) => string, + propertyUpdateHook: (parentProps: any, widgetName: string, propertyPath: string, propertyValue: string), + action: (parentProps: any, dynamicString: string, responseData?: any[]) => { actionString: string, dataToApply?: any[]}, + } +} +*/ + +// Enum which identifies the path in the enhancements for the +export enum WidgetEnhancementType { + WIDGET_ACTION = "child.action", + PROPERTY_UPDATE = "child.propertyUpdateHook", + CUSTOM_CONTROL = "child.customJSControl", + AUTOCOMPLETE = "child.autocomplete", + HIDE_EVALUATED_VALUE = "child.hideEvaluatedValue", + UPDATE_DATA_TREE_PATH = "child.updateDataTreePath", +} + +export function getParentWithEnhancementFn( + widgetId: string, + widgets: CanvasWidgetsReduxState, +) { + let widget = get(widgets, widgetId, undefined); + + // While this widget has a parent + while (widget?.parentId) { + // Get parent widget props + const parent = get(widgets, widget.parentId, undefined); + + // If parent has enhancements property + // enhancements property is a new widget property which tells us that + // the property pane, properties or actions of this widget or its children + // can be enhanced + + if (parent && parent.enhancements) { + return parent; + } + // If we didn't find any enhancements + // keep walking up the tree to find the parent which does + // if the parent doesn't have a parent stop walking the tree. + // also stop if the parent is the main container (Main container doesn't have enhancements) + if (parent?.parentId && parent.parentId !== MAIN_CONTAINER_WIDGET_ID) { + widget = get(widgets, widget.parentId, undefined); + + continue; + } + + return; + } +} + +export function getWidgetEnhancementFn( + type: WidgetType, + enhancementType: WidgetEnhancementType, +) { + // Get enhancements for the widget type from the config response + // Spread the config response so that we don't pollute the original + // configs + const { enhancements = {} } = { + ...(WidgetConfigResponse as any).config[type], + }; + return get(enhancements, enhancementType, undefined); +} + +// TODO(abhinav): Getting data from the tree may not be needed +// confirm this. +export const getPropsFromTree = ( + state: AppState, + widgetName?: string, +): unknown => { + // Get the evaluated data of this widget from the evaluations tree. + if (!widgetName) return; + + return get(state.evaluations.tree, widgetName, undefined); +}; + +export function* getChildWidgetEnhancementFn( + widgetId: string, + enhancementType: WidgetEnhancementType, +) { + // Get all widgets from the canvas + const widgets: CanvasWidgetsReduxState = yield select(getWidgets); + // Get the parent which wants to enhance this widget + const parentWithEnhancementFn = getParentWithEnhancementFn(widgetId, widgets); + // If such a parent is found + if (parentWithEnhancementFn) { + // Get the enhancement function based on the enhancementType + // from the configs + const enhancementFn = getWidgetEnhancementFn( + parentWithEnhancementFn.type, + enhancementType, + ); + // Get the parent's evaluated data from the evaluatedTree + const parentDataFromDataTree: unknown = yield select( + getPropsFromTree, + parentWithEnhancementFn.widgetName, + ); + if (parentDataFromDataTree) { + // Update the enhancement function by passing the widget data as the first parameter + return (...args: unknown[]) => + enhancementFn(parentDataFromDataTree, ...args); + } + } +} + +/** + * hook that returns parent with enhancments + * + * @param widgetId + * @returns + */ +export function useParentWithEnhancementFn(widgetId: string) { + const widgets: CanvasWidgetsReduxState = useSelector(getWidgets); + return getParentWithEnhancementFn(widgetId, widgets); +} + +export function useChildWidgetEnhancementFn( + widgetId: string, + enhancementType: WidgetEnhancementType, +) { + // Get all widgets from the canvas + const widgets: CanvasWidgetsReduxState = useSelector(getWidgets); + // Get the parent which wants to enhance this widget + const parentWithEnhancementFn = getParentWithEnhancementFn(widgetId, widgets); + // If such a parent is found + // Get the parent's evaluated data from the evaluatedTree + const parentDataFromDataTree: unknown = useSelector((state: AppState) => + getPropsFromTree(state, parentWithEnhancementFn?.widgetName), + ); + + if (parentWithEnhancementFn) { + // Get the enhancement function based on the enhancementType + // from the configs + const enhancementFn = getWidgetEnhancementFn( + parentWithEnhancementFn.type, + enhancementType, + ); + + if (parentDataFromDataTree && enhancementFn) { + // Update the enhancement function by passing the widget data as the first parameter + return (...args: unknown[]) => + enhancementFn(parentDataFromDataTree, ...args); + } + } +} + +type EnhancementFns = { + updateDataTreePathFn: any; + propertyPaneEnhancementFn: any; + autoCompleteEnhancementFn: any; + customJSControlEnhancementFn: any; + hideEvaluatedValueEnhancementFn: any; +}; + +export function useChildWidgetEnhancementFns(widgetId: string): EnhancementFns { + const enhancementFns = { + updateDataTreePathFn: undefined, + propertyPaneEnhancementFn: undefined, + autoCompleteEnhancementFn: undefined, + customJSControlEnhancementFn: undefined, + hideEvaluatedValueEnhancementFn: undefined, + }; + + // Get all widgets from the canvas + const widgets: CanvasWidgetsReduxState = useSelector(getWidgets); + // Get the parent which wants to enhance this widget + const parentWithEnhancementFn = getParentWithEnhancementFn(widgetId, widgets); + // If such a parent is found + // Get the parent's evaluated data from the evaluatedTree + const parentDataFromDataTree: unknown = useSelector((state: AppState) => + getPropsFromTree(state, parentWithEnhancementFn?.widgetName), + ); + + if (parentWithEnhancementFn) { + // Get the enhancement function based on the enhancementType + // from the configs + const widgetEnhancementFns = { + updateDataTreePathFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.UPDATE_DATA_TREE_PATH, + ), + propertyPaneEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.PROPERTY_UPDATE, + ), + autoCompleteEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.AUTOCOMPLETE, + ), + customJSControlEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.CUSTOM_CONTROL, + ), + hideEvaluatedValueEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.HIDE_EVALUATED_VALUE, + ), + }; + + Object.keys(widgetEnhancementFns).map((key: string) => { + const enhancementFn = get(widgetEnhancementFns, `${key}`); + + if (parentDataFromDataTree && enhancementFn) { + set(enhancementFns, `${key}`, (...args: unknown[]) => + enhancementFn(parentDataFromDataTree, ...args), + ); + } + }); + } + + return enhancementFns; +} diff --git a/app/taro/src/sagas/WidgetLoadingSaga.ts b/app/taro/src/sagas/WidgetLoadingSaga.ts new file mode 100644 index 0000000000..b98c5d4472 --- /dev/null +++ b/app/taro/src/sagas/WidgetLoadingSaga.ts @@ -0,0 +1,110 @@ +import { DependencyMap } from "../utils/DynamicBindingUtils"; +import { call, fork, put, select, take } from "redux-saga/effects"; +import { getEvaluationInverseDependencyMap } from "../selectors/dataTreeSelectors"; +import { getActions } from "../selectors/entitiesSelector"; +import { ActionData } from "../reducers/entityReducers/actionsReducer"; +import { + ReduxActionErrorTypes, + ReduxActionTypes, +} from "../constants/ReduxActionConstants"; +import log from "loglevel"; + +const createEntityDependencyMap = (dependencyMap: DependencyMap) => { + const entityDepMap: DependencyMap = {}; + Object.entries(dependencyMap).forEach(([dependant, dependencies]) => { + const entityDependant = dependant.split(".")[0]; + const existing = entityDepMap[entityDependant] || []; + entityDepMap[entityDependant] = existing.concat( + dependencies + .map((dep) => { + const value = dep.split(".")[0]; + if (value !== entityDependant) { + return value; + } + return undefined; + }) + .filter((value) => typeof value === "string") as string[], + ); + }); + return entityDepMap; +}; + +const getEntityDependencies = ( + entityNames: string[], + inverseMap: DependencyMap, + visited: Set, +): Set => { + const dependantsEntities: Set = new Set(); + entityNames.forEach((entityName) => { + if (entityName in inverseMap) { + inverseMap[entityName].forEach((dependency) => { + const dependantEntityName = dependency.split(".")[0]; + // Example: For a dependency chain that looks like Dropdown1.selectedOptionValue -> Table1.tableData -> Text1.text -> Dropdown1.options + // Here we're operating on + // Dropdown1 -> Table1 -> Text1 -> Dropdown1 + // It looks like a circle, but isn't + // So we need to mark the visited nodes and avoid infinite recursion in case we've already visited a node once. + if (visited.has(dependantEntityName)) { + return; + } + visited.add(dependantEntityName); + dependantsEntities.add(dependantEntityName); + const childDependencies = getEntityDependencies( + Array.from(dependantsEntities), + inverseMap, + visited, + ); + childDependencies.forEach((entityName) => { + dependantsEntities.add(entityName); + }); + }); + } + }); + return dependantsEntities; +}; + +const ACTION_EXECUTION_REDUX_ACTIONS = [ + ReduxActionTypes.RUN_ACTION_REQUEST, + ReduxActionTypes.RUN_ACTION_SUCCESS, + ReduxActionTypes.EXECUTE_API_ACTION_REQUEST, + ReduxActionTypes.EXECUTE_API_ACTION_SUCCESS, + ReduxActionErrorTypes.EXECUTE_ACTION_ERROR, +]; + +function* setWidgetsLoadingSaga() { + const inverseMap = yield select(getEvaluationInverseDependencyMap); + const entityDependencyMap = createEntityDependencyMap(inverseMap); + const actions = yield select(getActions); + const isLoadingActions: string[] = actions + .filter((action: ActionData) => action.isLoading) + .map((action: ActionData) => action.config.name); + + const loadingEntities = getEntityDependencies( + isLoadingActions, + entityDependencyMap, + new Set(), + ); + + yield put({ + type: ReduxActionTypes.SET_LOADING_ENTITIES, + payload: loadingEntities, + }); +} + +function* actionExecutionChangeListenerSaga() { + while (true) { + yield take(ACTION_EXECUTION_REDUX_ACTIONS); + yield fork(setWidgetsLoadingSaga); + } +} + +export default function* actionExecutionChangeListeners() { + yield take(ReduxActionTypes.START_EVALUATION); + while (true) { + try { + yield call(actionExecutionChangeListenerSaga); + } catch (e) { + log.error(e); + } + } +} diff --git a/app/taro/src/sagas/index.tsx b/app/taro/src/sagas/index.tsx new file mode 100644 index 0000000000..892ae1ba9e --- /dev/null +++ b/app/taro/src/sagas/index.tsx @@ -0,0 +1,44 @@ +import { call, all, spawn } from "redux-saga/effects"; +import initSagas from "./InitSagas"; +import pageSagas from "sagas/PageSagas"; +import { watchActionSagas } from "./ActionSagas"; +import { watchActionExecutionSagas } from "sagas/ActionExecutionSagas"; +import errorSagas from "./ErrorSagas"; +import applicationSagas from "./ApplicationSagas"; +import batchSagas from "./BatchSagas"; +import evaluationsSaga from "./EvaluationsSaga"; +import actionExecutionChangeListeners from "./WidgetLoadingSaga"; +import modalSagas from "./ModalSagas"; +// import debuggerSagas from "./DebuggerSagas"; +import log from "loglevel"; + +const sagas = [ + initSagas, + pageSagas, + watchActionSagas, + applicationSagas, + errorSagas, + evaluationsSaga, + batchSagas, + actionExecutionChangeListeners, + watchActionExecutionSagas, + modalSagas, + // debuggerSagas, +]; + +export function* rootSaga(sagasToRun = sagas) { + yield all( + sagasToRun.map((saga) => + spawn(function*() { + while (true) { + try { + yield call(saga); + break; + } catch (e) { + log.error(e); + } + } + }), + ), + ); +} diff --git a/app/taro/src/sagas/selectors.tsx b/app/taro/src/sagas/selectors.tsx new file mode 100644 index 0000000000..9864b6456d --- /dev/null +++ b/app/taro/src/sagas/selectors.tsx @@ -0,0 +1,177 @@ +import { AppState } from "reducers"; +import { createSelector } from "reselect"; +import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; +import { WidgetProps } from "widgets/BaseWidget"; +import _ from "lodash"; +import { WidgetType } from "constants/WidgetConstants"; +import { ActionData } from "reducers/entityReducers/actionsReducer"; +import { Page } from "constants/ReduxActionConstants"; +import { getActions, getPlugins } from "../selectors/entitiesSelector"; +import { Plugin } from "api/PluginApi"; + +export const getWidgets = ( + state: AppState, +): { [widgetId: string]: FlattenedWidgetProps } => { + return state.entities.canvasWidgets; +}; + +export const getWidgetsMeta = (state: AppState) => state.entities.meta; +export const getWidgetMetaProps = (state: AppState, widgetId: string) => + state.entities.meta[widgetId]; + +export const getWidget = (state: AppState, widgetId: string): WidgetProps => { + return state.entities.canvasWidgets[widgetId]; +}; + +export const getWidgetIdsByType = (state: AppState, type: WidgetType) => { + return Object.values(state.entities.canvasWidgets) + .filter((widget: FlattenedWidgetProps) => widget.type === type) + .map((widget: FlattenedWidgetProps) => widget.widgetId); +}; + +export const getWidgetOptionsTree = createSelector(getWidgets, (widgets) => + Object.values(widgets) + .filter((w) => w.type !== "CANVAS_WIDGET") + .map((w) => { + return { + label: w.widgetName, + id: w.widgetName, + value: `"${w.widgetName}"`, + }; + }), +); + +// export const getEditorConfigs = ( +// state: AppState, +// ): { pageId: string; layoutId: string } | undefined => { +// const pageId = state.entities.pageList.currentPageId; +// const layoutId = state.ui.editor.currentLayoutId; +// if (!pageId || !layoutId) return undefined; +// return { pageId, layoutId }; +// }; + +export const getDefaultWidgetConfig = ( + state: AppState, + type: WidgetType, +): Partial => { + const configs = state.entities.widgetConfig.config; + if (configs.hasOwnProperty(type)) { + const widgetConfig = { ...configs[type] }; + return widgetConfig; + } + return {}; +}; + +export const getWidgetNamePrefix = ( + state: AppState, + type: WidgetType, +): string => { + return state.entities.widgetConfig.config[type].widgetName; +}; + +export const getDefaultPageId = (state: AppState): string | undefined => + state.entities.pageList.defaultPageId; + +export const getExistingWidgetNames = createSelector( + getWidgets, + (widgets: { [widgetId: string]: FlattenedWidgetProps }) => { + return Object.values(widgets).map((widget) => widget.widgetName); + }, +); + +export const currentPageId = (state: AppState) => { + return state.entities.pageList.currentPageId; +}; + +export const getExistingActionNames = createSelector( + getActions, + currentPageId, + (actions: ActionData[], pageId?: string) => { + return _.compact( + actions.map((action: ActionData) => { + return action.config.pageId === pageId ? action.config.name : undefined; + }), + ); + }, +); + +export const getPluginIdToImageLocation = createSelector( + getPlugins, + (plugins) => + plugins.reduce((acc: any, p: Plugin) => { + acc[p.id] = p.iconLocation; + return acc; + }, {}), +); + +/** + * returns a objects of existing page name in data tree + * + * @param state + */ +export const getExistingPageNames = (state: AppState) => { + const map: Record = {}; + + state.entities.pageList.pages.map((page: Page) => { + map[page.pageName] = page.pageName; + }); + + return map; +}; + +export const getWidgetByName = ( + state: AppState, + widgetName: string, +): FlattenedWidgetProps | undefined => { + const widgets = state.entities.canvasWidgets; + return _.find( + Object.values(widgets), + (widget) => widget.widgetName === widgetName, + ); +}; + +export const getAllPageIds = (state: AppState) => { + return state.entities.pageList.pages.map((page) => page.pageId); +}; + +export const getPluginIdOfPackageName = ( + state: AppState, + name: string, +): string | undefined => { + const plugins = state.entities.plugins.list; + const plugin = _.find(plugins, { packageName: name }); + if (plugin) return plugin.id; + return undefined; +}; + +export const getSelectedWidget = (state: AppState) => { + const selectedWidgetId = state.ui.widgetDragResize.lastSelectedWidget; + if (!selectedWidgetId) return; + return state.entities.canvasWidgets[selectedWidgetId]; +}; + +export const getFocusedWidget = (state: AppState) => { + const focusedWidgetId = state.ui.widgetDragResize.focusedWidget; + if (!focusedWidgetId) return; + return state.entities.canvasWidgets[focusedWidgetId]; +}; + +export const getWidgetImmediateChildren = createSelector( + getWidget, + (widget: WidgetProps) => { + const childrenIds: string[] = []; + if (widget === undefined) { + return []; + } + const { children = [] } = widget; + if (children && children.length) { + for (const childIndex in children) { + if (children.hasOwnProperty(childIndex)) { + const child = children[childIndex]; + childrenIds.push(child); + } + } + } + return childrenIds; + }, +); diff --git a/app/taro/src/selectors/appViewSelectors.tsx b/app/taro/src/selectors/appViewSelectors.tsx new file mode 100644 index 0000000000..477ded716b --- /dev/null +++ b/app/taro/src/selectors/appViewSelectors.tsx @@ -0,0 +1,46 @@ +import { createSelector } from "reselect"; +import { AppState } from "reducers"; +import { AppViewReduxState } from "reducers/uiReducers/appViewReducer"; +import { PageListReduxState } from "reducers/entityReducers/pageListReducer"; +import { BUILDER_PAGE_URL } from "constants/routes"; + +const getAppViewState = (state: AppState) => state.ui.appView; +const getPageListState = (state: AppState): PageListReduxState => + state.entities.pageList; + +// For the viewer, this does not need to be wrapped in createCachedSelector, as it will not change in subsequent renders. +// export const getCurrentPageLayoutDSL = createSelector( +// getAppViewState, +// getDataTree, +// (view: AppViewReduxState, dataTree: DataTree) => +// injectDataTreeIntoDsl(dataTree, view.dsl), +// ); + +export const getPageList = createSelector( + getPageListState, + (pageList: PageListReduxState) => + pageList.pages.length > 0 ? pageList.pages : undefined, +); + +export const getIsFetchingPage = createSelector( + getAppViewState, + (view: AppViewReduxState) => view.isFetchingPage, +); + +export const getIsInitialized = createSelector( + getAppViewState, + (view: AppViewReduxState) => view.initialized, +); + +export const getCurrentDSLPageId = createSelector( + getPageListState, + (pageList: PageListReduxState) => pageList.currentPageId, +); + +export const getEditorURL = createSelector( + getPageListState, + (pageList: PageListReduxState) => + pageList.applicationId && pageList.currentPageId + ? BUILDER_PAGE_URL(pageList.applicationId, pageList.currentPageId) + : "", +); diff --git a/app/taro/src/selectors/applicationSelectors.tsx b/app/taro/src/selectors/applicationSelectors.tsx new file mode 100644 index 0000000000..3cd62820ea --- /dev/null +++ b/app/taro/src/selectors/applicationSelectors.tsx @@ -0,0 +1,148 @@ +import { createSelector } from "reselect"; +import { AppState } from "reducers"; +import { + ApplicationsReduxState, + creatingApplicationMap, +} from "reducers/uiReducers/applicationsReducer"; +import { + ApplicationPayload, + OrganizationDetails, +} from "constants/ReduxActionConstants"; +import Fuse from "fuse.js"; +import { Organization } from "constants/orgConstants"; + +const fuzzySearchOptions = { + keys: ["applications.name", "organization.name"], + shouldSort: true, + threshold: 0.5, + location: 0, + distance: 100, +}; + +const getApplicationsState = (state: AppState) => state.ui.applications; +const getApplications = (state: AppState) => + state.ui.applications.applicationList; +export const getCurrentApplication = ( + state: AppState, +): ApplicationPayload | undefined => { + return state.ui.applications.currentApplication; +}; +export const getApplicationSearchKeyword = (state: AppState) => + state.ui.applications.searchKeyword; +export const getAppMode = (state: AppState) => state.entities.app.mode; +export const getIsDeletingApplication = (state: AppState) => + state.ui.applications.deletingApplication; +export const getIsDuplicatingApplication = (state: AppState) => + state.ui.applications.duplicatingApplication; +export const getIsSavingAppName = (state: AppState) => + state.ui.applications.isSavingAppName; +export const getIsErroredSavingAppName = (state: AppState) => + state.ui.applications.isErrorSavingAppName; +export const getUserApplicationsOrgs = (state: AppState) => { + return state.ui.applications.userOrgs; +}; + +export const getImportedCollections = (state: AppState) => + state.ui.importedCollections.importedCollections; + +export const getProviders = (state: AppState) => state.ui.providers.providers; +export const getProvidersLoadingState = (state: AppState) => + state.ui.providers.isFetchingProviders; +export const getProviderTemplates = (state: AppState) => + state.ui.providers.providerTemplates; +export const getProvidersTemplatesLoadingState = (state: AppState) => + state.ui.providers.isFetchingProviderTemplates; + +export const getApplicationList = createSelector( + getApplications, + getApplicationSearchKeyword, + ( + applications?: ApplicationPayload[], + keyword?: string, + ): ApplicationPayload[] => { + if ( + applications && + applications.length > 0 && + keyword && + keyword.trim().length > 0 + ) { + const fuzzy = new Fuse(applications, fuzzySearchOptions); + return fuzzy.search(keyword) as ApplicationPayload[]; + } else if ( + applications && + (keyword === undefined || keyword.trim().length === 0) + ) { + return applications; + } + return []; + }, +); + +export const getUserApplicationsOrgsList = createSelector( + getUserApplicationsOrgs, + getApplicationSearchKeyword, + ( + applicationsOrgs?: Organization[], + keyword?: string, + ): OrganizationDetails[] => { + if ( + applicationsOrgs && + applicationsOrgs.length > 0 && + keyword && + keyword.trim().length > 0 + ) { + const fuzzy = new Fuse(applicationsOrgs, fuzzySearchOptions); + let organizationList = fuzzy.search(keyword) as OrganizationDetails[]; + organizationList = organizationList.map((org) => { + const applicationFuzzy = new Fuse(org.applications, { + ...fuzzySearchOptions, + keys: ["name"], + }); + const applications = applicationFuzzy.search(keyword) as any[]; + + return { + ...org, + applications, + }; + }); + + return organizationList; + } else if ( + applicationsOrgs && + (keyword === undefined || keyword.trim().length === 0) + ) { + return applicationsOrgs; + } + return []; + }, +); + +export const getIsFetchingApplications = createSelector( + getApplicationsState, + (applications: ApplicationsReduxState): boolean => + applications.isFetchingApplications, +); + +export const getIsCreatingApplication = createSelector( + getApplicationsState, + (applications: ApplicationsReduxState): creatingApplicationMap => + applications.creatingApplication, +); + +export const getCreateApplicationError = createSelector( + getApplicationsState, + (applications: ApplicationsReduxState): string | undefined => + applications.createApplicationError, +); + +export const getIsDeletingApplications = createSelector( + getApplicationsState, + (applications: ApplicationsReduxState): boolean => + applications.deletingApplication, +); + +export const getIsSavingOrgInfo = (state: AppState) => + state.ui.applications.isSavingOrgInfo; + +export const showAppInviteUsersDialogSelector = (state: AppState) => + state.ui.applications.showAppInviteUsersDialog; diff --git a/app/taro/src/selectors/authSelectors.tsx b/app/taro/src/selectors/authSelectors.tsx new file mode 100644 index 0000000000..cbe0b90ae6 --- /dev/null +++ b/app/taro/src/selectors/authSelectors.tsx @@ -0,0 +1,5 @@ +import { AppState } from "reducers"; + +export const getIsTokenValid = (state: AppState) => state.ui.auth.isTokenValid; +export const getIsValidatingToken = (state: AppState) => + state.ui.auth.isValidatingToken; diff --git a/app/taro/src/selectors/dataTreeSelectors.ts b/app/taro/src/selectors/dataTreeSelectors.ts new file mode 100644 index 0000000000..6ad8a33ddc --- /dev/null +++ b/app/taro/src/selectors/dataTreeSelectors.ts @@ -0,0 +1,80 @@ +import { createSelector } from "reselect"; +import { + getActionsForCurrentPage, + getAppData, + getPluginDependencyConfig, + getPluginEditorConfigs, +} from "./entitiesSelector"; +import { ActionDataState } from "reducers/entityReducers/actionsReducer"; +import { DataTree, DataTreeFactory } from "entities/DataTree/dataTreeFactory"; +import { getWidgets, getWidgetsMeta } from "sagas/selectors"; +import "url-search-params-polyfill"; +import { getPageList } from "./appViewSelectors"; +import { AppState } from "reducers"; + +export const getUnevaluatedDataTree = createSelector( + getActionsForCurrentPage, + getWidgets, + getWidgetsMeta, + getPageList, + getAppData, + getPluginEditorConfigs, + getPluginDependencyConfig, + ( + actions, + widgets, + widgetsMeta, + pageListPayload, + appData, + editorConfigs, + pluginDependencyConfig, + ) => { + const pageList = pageListPayload || []; + return DataTreeFactory.create({ + actions, + widgets, + widgetsMeta, + pageList, + appData, + editorConfigs, + pluginDependencyConfig, + }); + }, +); + +export const getEvaluationInverseDependencyMap = (state: AppState) => + state.evaluations.dependencies.inverseDependencyMap; + +export const getLoadingEntities = (state: AppState) => + state.evaluations.loadingEntities; + +/** + * returns evaluation tree object + * + * @param state + */ +export const getDataTree = (state: AppState) => state.evaluations.tree; + +// For autocomplete. Use actions cached responses if +// there isn't a response already +export const getDataTreeForAutocomplete = createSelector( + getDataTree, + getActionsForCurrentPage, + (tree: DataTree, actions: ActionDataState) => { + const cachedResponses: Record = {}; + if (actions && actions.length) { + actions.forEach((action) => { + if (!(action.config.name in tree) && action.config.cacheResponse) { + try { + cachedResponses[action.config.name] = JSON.parse( + action.config.cacheResponse, + ); + } catch (e) { + cachedResponses[action.config.name] = action.config.cacheResponse; + } + } + }); + } + return tree; + }, +); diff --git a/app/taro/src/selectors/debuggerSelectors.tsx b/app/taro/src/selectors/debuggerSelectors.tsx new file mode 100644 index 0000000000..a0e005e8af --- /dev/null +++ b/app/taro/src/selectors/debuggerSelectors.tsx @@ -0,0 +1,3 @@ +import { AppState } from "reducers"; + +export const getDebuggerErrors = (state: AppState) => state.ui.debugger.errors; diff --git a/app/taro/src/selectors/editorSelectors.tsx b/app/taro/src/selectors/editorSelectors.tsx new file mode 100644 index 0000000000..cdbe8c981f --- /dev/null +++ b/app/taro/src/selectors/editorSelectors.tsx @@ -0,0 +1,248 @@ +import { createSelector } from "reselect"; +import { AppState } from "reducers"; +import { WIDGET_STATIC_PROPS, WidgetProps } from "widgets/BaseWidget"; +import CanvasWidgetsNormalizer from "normalizers/CanvasWidgetsNormalizer"; +import { + CanvasWidgetsReduxState, + FlattenedWidgetProps, +} from "reducers/entityReducers/canvasWidgetsReducer"; +import { PageListReduxState } from "reducers/entityReducers/pageListReducer"; + +import { OccupiedSpace } from "constants/editorConstants"; +import { getDataTree, getLoadingEntities } from "selectors/dataTreeSelectors"; +import _ from "lodash"; +import { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { DataTreeWidget, ENTITY_TYPE } from "entities/DataTree/dataTreeFactory"; +import { getActions } from "selectors/entitiesSelector"; + +import { getCanvasWidgets } from "./entitiesSelector"; +import { WidgetTypes } from "../constants/WidgetConstants"; + +const getPageListState = (state: AppState) => state.entities.pageList; + +export const getProviderCategories = (state: AppState) => + state.ui.providers.providerCategories; + +const getWidgets = (state: AppState): CanvasWidgetsReduxState => + state.entities.canvasWidgets; + +export const getPageList = (state: AppState) => state.entities.pageList.pages; + +export const getCurrentPageId = (state: AppState) => + state.entities.pageList.currentPageId; + +export const getCurrentApplicationId = (state: AppState) => + state.entities.pageList.applicationId; + +export const getLayoutOnLoadActions = (state: AppState) => + state.ui.editor.pageActions || []; + +export const getViewModePageList = createSelector( + getPageList, + getCurrentPageId, + (pageList: PageListReduxState["pages"], currentPageId?: string) => { + if (currentPageId) { + const currentPage = pageList.find( + (page) => page.pageId === currentPageId + ); + if (!!currentPage?.isHidden) { + return [currentPage]; + } + + const visiblePages = pageList.filter((page) => !page.isHidden); + return visiblePages; + } + + return []; + } +); + +export const getCurrentPage = createSelector( + getPageList, + getCurrentPageId, + (pageList: PageListReduxState["pages"], currentPageId?: string) => { + if (currentPageId) { + return pageList.find((page) => page.pageId === currentPageId); + } + return null; + } +); + +export const getShowTabBar = createSelector( + getCurrentPage, + getPageList, + (page: any) => !!page?.icon +); + +export const getCurrentApplicationLayout = (state: AppState) => + state.ui.applications.currentApplication?.appLayout; + +export const getCurrentPageName = createSelector( + getPageListState, + (pageList: PageListReduxState) => + pageList.pages.find((page) => page.pageId === pageList.currentPageId) + ?.pageName +); + +export const getCanvasWidgetDsl = createSelector( + getCanvasWidgets, + getDataTree, + getLoadingEntities, + ( + canvasWidgets: CanvasWidgetsReduxState, + evaluatedDataTree, + loadingEntities + ): ContainerWidgetProps => { + const widgets: Record = {}; + Object.keys(canvasWidgets).forEach((widgetKey) => { + const canvasWidget = canvasWidgets[widgetKey]; + const evaluatedWidget = _.find(evaluatedDataTree, { + widgetId: widgetKey, + }) as DataTreeWidget; + if (evaluatedWidget) { + widgets[widgetKey] = createCanvasWidget(canvasWidget, evaluatedWidget); + } else { + widgets[widgetKey] = createLoadingWidget(canvasWidget); + } + widgets[widgetKey].isLoading = loadingEntities.has( + canvasWidget.widgetName + ); + }); + + return CanvasWidgetsNormalizer.denormalize("0", { + canvasWidgets: widgets, + }); + } +); + +const getOccupiedSpacesForContainer = ( + containerWidgetId: string, + widgets: FlattenedWidgetProps[] +): OccupiedSpace[] => { + return widgets.map((widget) => { + const occupiedSpace: OccupiedSpace = { + id: widget.widgetId, + parentId: containerWidgetId, + left: widget.leftColumn, + top: widget.topRow, + bottom: widget.bottomRow, + right: widget.rightColumn, + }; + return occupiedSpace; + }); +}; + +export const getOccupiedSpaces = createSelector( + getWidgets, + ( + widgets: CanvasWidgetsReduxState + ): { [containerWidgetId: string]: OccupiedSpace[] } | undefined => { + const occupiedSpaces: { + [containerWidgetId: string]: OccupiedSpace[]; + } = {}; + // Get all widgets with type "CONTAINER_WIDGET" and has children + const containerWidgets: FlattenedWidgetProps[] = Object.values( + widgets + ).filter((widget) => widget.children && widget.children.length > 0); + + // If we have any container widgets + if (containerWidgets) { + containerWidgets.forEach((containerWidget: FlattenedWidgetProps) => { + const containerWidgetId = containerWidget.widgetId; + // Get child widgets for the container + const childWidgets = Object.keys(widgets).filter( + (widgetId) => + containerWidget.children && + containerWidget.children.indexOf(widgetId) > -1 && + !widgets[widgetId].detachFromLayout + ); + // Get the occupied spaces in this container + // Assign it to the containerWidgetId key in occupiedSpaces + occupiedSpaces[containerWidgetId] = getOccupiedSpacesForContainer( + containerWidgetId, + childWidgets.map((widgetId) => widgets[widgetId]) + ); + }); + } + // Return undefined if there are no occupiedSpaces. + return Object.keys(occupiedSpaces).length > 0 ? occupiedSpaces : undefined; + } +); + +// same as getOccupiedSpaces but gets only the container specific ocupied Spaces +export function getOccupiedSpacesSelectorForContainer( + containerId: string | undefined +) { + return createSelector( + getWidgets, + (widgets: CanvasWidgetsReduxState): OccupiedSpace[] | undefined => { + if (containerId === null || containerId === undefined) return undefined; + + const containerWidget: FlattenedWidgetProps = widgets[containerId]; + + if (!containerWidget || !containerWidget.children) return undefined; + + // Get child widgets for the container + const childWidgets = Object.keys(widgets).filter( + (widgetId) => + containerWidget.children && + containerWidget.children.indexOf(widgetId) > -1 && + !widgets[widgetId].detachFromLayout + ); + + const occupiedSpaces = getOccupiedSpacesForContainer( + containerId, + childWidgets.map((widgetId) => widgets[widgetId]) + ); + return occupiedSpaces; + } + ); +} + +export const getActionById = createSelector( + [getActions, (state: any, props: any) => props.match.params.apiId], + (actions, id) => { + const action = actions.find((action) => action.config.id === id); + if (action) { + return action.config; + } else { + return undefined; + } + } +); + +export const getActionTabsInitialIndex = (state: AppState) => + state.ui.actionTabs.index; + +const createCanvasWidget = ( + canvasWidget: FlattenedWidgetProps, + evaluatedWidget: DataTreeWidget +) => { + const widgetStaticProps = _.pick( + canvasWidget, + Object.keys(WIDGET_STATIC_PROPS) + ); + return { + ...evaluatedWidget, + ...widgetStaticProps, + }; +}; + +const createLoadingWidget = ( + canvasWidget: FlattenedWidgetProps +): DataTreeWidget => { + const widgetStaticProps = _.pick( + canvasWidget, + Object.keys(WIDGET_STATIC_PROPS) + ) as WidgetProps; + return { + ...widgetStaticProps, + type: WidgetTypes.SKELETON_WIDGET, + ENTITY_TYPE: ENTITY_TYPE.WIDGET, + bindingPaths: {}, + triggerPaths: {}, + validationPaths: {}, + logBlackList: {}, + isLoading: true, + }; +}; diff --git a/app/taro/src/selectors/entitiesSelector.ts b/app/taro/src/selectors/entitiesSelector.ts new file mode 100644 index 0000000000..f3ccb4a3ff --- /dev/null +++ b/app/taro/src/selectors/entitiesSelector.ts @@ -0,0 +1,467 @@ +import { AppState } from "reducers"; +import { + ActionData, + ActionDataState, +} from "reducers/entityReducers/actionsReducer"; +import { ActionResponse } from "api/ActionAPI"; +import { createSelector } from "reselect"; +import { + Datasource, + MockDatasource, + DatasourceStructure, +} from "entities/Datasource"; +import { Action, PluginType } from "entities/Action"; +import { find } from "lodash"; +import ImageAlt from "assets/images/placeholder-image.svg"; +import { CanvasWidgetsReduxState } from "../reducers/entityReducers/canvasWidgetsReducer"; +import { MAIN_CONTAINER_WIDGET_ID } from "constants/WidgetConstants"; +import { AppStoreState } from "reducers/entityReducers/appReducer"; +import { GenerateCRUDEnabledPluginMap } from "../api/PluginApi"; +// import { PLUGIN_PACKAGE_NAME } from "../pages/Editor/GeneratePage/components/constants"; + +import { APP_MODE } from "entities/App"; + +export const getEntities = (state: AppState): AppState["entities"] => + state.entities; + +export const getDatasources = (state: AppState): Datasource[] => { + return state.entities.datasources.list; +}; + +export const getDatasourcesStructure = ( + state: AppState, +): Record => { + return state.entities.datasources.structure; +}; + +export const getIsFetchingDatasourceStructure = (state: AppState): boolean => { + return state.entities.datasources.fetchingDatasourceStructure; +}; + +export const getMockDatasources = (state: AppState): MockDatasource[] => { + return state.entities.datasources.mockDatasourceList; +}; + +export const getIsDeletingDatasource = (state: AppState): boolean => { + return state.entities.datasources.isDeleting; +}; + +export const getPluginIdsOfNames = ( + state: AppState, + names: Array, +): Array | undefined => { + const plugins = state.entities.plugins.list.filter((plugin) => + names.includes(plugin.name), + ); + const pluginIds = plugins.map((plugin) => plugin.id); + + if (!pluginIds.length) return undefined; + return pluginIds; +}; + +export const getPluginIdsOfPackageNames = ( + state: AppState, + names: Array, +): Array | undefined => { + const plugins = state.entities.plugins.list.filter((plugin) => + names.includes(plugin.packageName), + ); + const pluginIds = plugins.map((plugin) => plugin.id); + + if (!pluginIds.length) return undefined; + return pluginIds; +}; + +export const getPluginNameFromDatasourceId = ( + state: AppState, + datasourceId: string, +): string | undefined => { + const datasource = state.entities.datasources.list.find( + (datasource) => datasource.id === datasourceId, + ); + const plugin = state.entities.plugins.list.find( + (plugin) => plugin.id === datasource?.pluginId, + ); + + if (!plugin) return undefined; + return plugin.name; +}; + +export const getPluginPackageFromDatasourceId = ( + state: AppState, + datasourceId: string, +): string | undefined => { + const datasource = state.entities.datasources.list.find( + (datasource) => datasource.id === datasourceId, + ); + const plugin = state.entities.plugins.list.find( + (plugin) => plugin.id === datasource?.pluginId, + ); + + if (!plugin) return undefined; + return plugin.packageName; +}; + +export const getPluginNameFromId = ( + state: AppState, + pluginId: string, +): string => { + const plugin = state.entities.plugins.list.find( + (plugin) => plugin.id === pluginId, + ); + + if (!plugin) return ""; + return plugin.name; +}; + +export const getPluginForm = (state: AppState, pluginId: string): any[] => { + return state.entities.plugins.formConfigs[pluginId]; +}; +export const getIsFetchingSinglePluginForm = ( + state: AppState, + pluginId: string, +): boolean => { + return !!state.entities.plugins.fetchingSinglePluginForm[pluginId]; +}; + +export const getEditorConfig = (state: AppState, pluginId: string): any[] => { + return state.entities.plugins.editorConfigs[pluginId]; +}; + +export const getSettingConfig = (state: AppState, pluginId: string): any[] => { + return state.entities.plugins.settingConfigs[pluginId]; +}; + +export const getActions = (state: AppState): ActionDataState => + state.entities.actions; + +export const getDatasource = ( + state: AppState, + datasourceId: string, +): Datasource | undefined => + state.entities.datasources.list.find( + (datasource) => datasource.id === datasourceId, + ); + +export const getDatasourceDraft = (state: AppState, id: string) => { + const drafts = state.ui.datasourcePane.drafts; + if (id in drafts) return drafts[id]; + return {}; +}; + +export const getDatasourcesByPluginId = ( + state: AppState, + id: string, +): Datasource[] => { + return state.entities.datasources.list.filter((d) => d.pluginId === id); +}; + +export const getPlugins = (state: AppState) => state.entities.plugins.list; + +export const getPluginByPackageName = (state: AppState, name: string) => + state.entities.plugins.list.find((p) => p.packageName === name); + +export const getPluginEditorConfigs = (state: AppState) => + state.entities.plugins.editorConfigs; + +export const getPluginDependencyConfig = (state: AppState) => + state.entities.plugins.dependencies; + +export const getPluginSettingConfigs = (state: AppState, pluginId: string) => + state.entities.plugins.settingConfigs[pluginId]; + +export const getDBPlugins = createSelector(getPlugins, (plugins) => + plugins.filter((plugin) => plugin.type === PluginType.DB), +); + +export const getDatasourceByPluginId = (state: AppState, pluginId: string) => + state.entities.datasources.list.filter((d) => d.pluginId === pluginId); + +export const getDBDatasources = createSelector( + getDBPlugins, + getEntities, + (dbPlugins, entities) => { + const datasources = entities.datasources.list; + const dbPluginIds = dbPlugins.map((plugin) => plugin.id); + + return datasources.filter((datasource) => + dbPluginIds.includes(datasource.pluginId), + ); + }, +); + +export const getQueryName = (state: AppState, actionId: string): string => { + const action = state.entities.actions.find((action: ActionData) => { + return action.config.id === actionId; + }); + + return action?.config.name ?? ""; +}; + +const getCurrentPageId = (state: AppState) => + state.entities.pageList.currentPageId; + +export const getDatasourcePlugins = createSelector(getPlugins, (plugins) => { + return plugins.filter((plugin) => plugin?.allowUserDatasources ?? true); +}); + +export const getPluginImages = createSelector(getPlugins, (plugins) => { + const pluginImages: Record = {}; + + plugins.forEach((plugin) => { + pluginImages[plugin.id] = + plugin?.iconLocation + ?.replace("https://s3.us-east-2.amazonaws.com/assets.appsmith.com", "") + ?.replace(/\.png$/g, ".svg") ?? ImageAlt; + }); + + return pluginImages; +}); + +export const getPluginTemplates = createSelector(getPlugins, (plugins) => { + const pluginTemplates: Record = {}; + + plugins.forEach((plugin) => { + pluginTemplates[plugin.id] = plugin.templates; + }); + + return pluginTemplates; +}); + +export const getPluginResponseTypes = createSelector(getPlugins, (plugins) => { + const pluginResponseTypes: Record = {}; + + plugins.forEach((plugin) => { + pluginResponseTypes[plugin.id] = plugin.responseType; + }); + + return pluginResponseTypes; +}); + +export const getPluginDocumentationLinks = createSelector( + getPlugins, + (plugins) => { + const pluginDocumentationLinks: Record = {}; + + plugins.forEach((plugin) => { + pluginDocumentationLinks[plugin.id] = plugin.documentationLink; + }); + + return pluginDocumentationLinks; + }, +); + +export const getGenerateCRUDEnabledPluginMap = createSelector( + getPlugins, + (plugins) => { + const pluginIdGenerateCRUDPageEnabled: GenerateCRUDEnabledPluginMap = {}; + // Disable google sheet plugin + plugins.map((plugin) => { + if ( + plugin.generateCRUDPageComponent + // plugin.packageName !== PLUGIN_PACKAGE_NAME.GOOGLE_SHEETS && + // plugin.packageName !== PLUGIN_PACKAGE_NAME.S3 + ) { + pluginIdGenerateCRUDPageEnabled[plugin.id] = plugin.packageName; + } + }); + return pluginIdGenerateCRUDPageEnabled; + }, +); + +export const getActionsForCurrentPage = createSelector( + getCurrentPageId, + getActions, + (pageId, actions) => { + if (!pageId) return []; + return actions.filter((a) => a.config.pageId === pageId); + }, +); + +export const getQueryActionsForCurrentPage = createSelector( + getActionsForCurrentPage, + (actions) => { + return actions.filter((action) => { + return action.config.pluginType === PluginType.DB; + }); + }, +); + +export const getPlugin = (state: AppState, pluginId: string) => { + return state.entities.plugins.list.find((plugin) => plugin.id === pluginId); +}; + +export const getActionResponses = createSelector(getActions, (actions) => { + const responses: Record = {}; + + actions.forEach((a) => { + responses[a.config.id] = a.data; + }); + return responses; +}); + +export const getAction = ( + state: AppState, + actionId: string, +): Action | undefined => { + const action = find(state.entities.actions, (a) => a.config.id === actionId); + return action ? action.config : undefined; +}; + +export function getCurrentPageNameByActionId( + state: AppState, + actionId: string, +): string { + const action = state.entities.actions.find((action) => { + return action.config.id === actionId; + }); + const pageId = action ? action.config.pageId : ""; + return getPageNameByPageId(state, pageId); +} + +export function getPageNameByPageId(state: AppState, pageId: string): string { + const page = state.entities.pageList.pages.find( + (page) => page.pageId === pageId, + ); + return page ? page.pageName : ""; +} + +const getQueryPaneSavingMap = (state: AppState) => state.ui.queryPane.isSaving; +const getApiPaneSavingMap = (state: AppState) => state.ui.apiPane.isSaving; +const getActionDirtyState = (state: AppState) => state.ui.apiPane.isDirty; + +export const isActionSaving = (id: string) => + createSelector( + [getQueryPaneSavingMap, getApiPaneSavingMap], + (querySavingMap, apiSavingsMap) => { + return ( + (id in querySavingMap && querySavingMap[id]) || + (id in apiSavingsMap && apiSavingsMap[id]) + ); + }, + ); + +export const isActionDirty = (id: string) => + createSelector([getActionDirtyState], (actionDirtyMap) => { + return id in actionDirtyMap && actionDirtyMap[id]; + }); + +export const getAppData = (state: AppState) => state.entities.app; + +export const getAppStoreData = (state: AppState): AppStoreState => + state.entities.app.store; + +export const getCanvasWidgets = (state: AppState): CanvasWidgetsReduxState => + state.entities.canvasWidgets; + +const getPageWidgets = (state: AppState) => state.ui.pageWidgets; +export const getCurrentPageWidgets = createSelector( + getPageWidgets, + getCurrentPageId, + (widgetsByPage, currentPageId) => + currentPageId ? widgetsByPage[currentPageId] : {}, +); + +const getParentModalId = (widget: any, pageWidgets: Record) => { + let parentModalId; + let { parentId } = widget; + let parentWidget = pageWidgets[parentId]; + while (parentId && parentId !== MAIN_CONTAINER_WIDGET_ID) { + if (parentWidget?.type === "MODAL_WIDGET") { + parentModalId = parentId; + break; + } + parentId = parentWidget?.parentId; + parentWidget = pageWidgets[parentId]; + } + return parentModalId; +}; + +export const getCanvasWidgetsWithParentId = createSelector( + getCanvasWidgets, + (canvasWidgets: CanvasWidgetsReduxState) => { + return Object.entries(canvasWidgets).reduce( + (res, [widgetId, widget]: any) => { + const parentModalId = getParentModalId(widget, canvasWidgets); + + return { + ...res, + [widgetId]: { ...widget, parentModalId }, + }; + }, + {}, + ); + }, +); + +export const getAllWidgetsMap = createSelector( + getPageWidgets, + (widgetsByPage) => { + return Object.entries(widgetsByPage).reduce( + (res: any, [pageId, pageWidgets]: any) => { + const widgetsMap = Object.entries(pageWidgets).reduce( + (res, [widgetId, widget]: any) => { + const parentModalId = getParentModalId(widget, pageWidgets); + + return { + ...res, + [widgetId]: { ...widget, pageId, parentModalId }, + }; + }, + {}, + ); + + return { + ...res, + ...widgetsMap, + }; + }, + {}, + ); + }, +); + +export const getAllPageWidgets = createSelector( + getAllWidgetsMap, + (widgetsMap) => { + return Object.entries(widgetsMap).reduce( + (res: any[], [, widget]: any) => [...res, widget], + [], + ); + }, +); + +export const getPageListAsOptions = createSelector( + (state: AppState) => state.entities.pageList.pages, + (pages) => + pages.map((page) => ({ + label: page.pageName, + id: page.pageId, + value: `'${page.pageName}'`, + })), +); + +export const getExistingPageNames = createSelector( + (state: AppState) => state.entities.pageList.pages, + (pages) => pages.map((page) => page.pageName), +); + +export const getExistingWidgetNames = createSelector( + (state: AppState) => state.entities.canvasWidgets, + (widgets) => Object.values(widgets).map((widget) => widget.pageName), +); + +export const getExistingActionNames = createSelector( + (state: AppState) => state.entities.actions, + (actions) => + actions.map((action: { config: { name: string } }) => action.config.name), +); + +export const getAppMode = (state: AppState) => state.entities.app.mode; + +export const widgetsMapWithParentModalId = (state: AppState) => { + const appMode = getAppMode(state); + return appMode === APP_MODE.EDIT + ? getAllWidgetsMap(state) + : getCanvasWidgetsWithParentId(state); +}; diff --git a/app/taro/src/selectors/errorSelectors.tsx b/app/taro/src/selectors/errorSelectors.tsx new file mode 100644 index 0000000000..fc061aa19c --- /dev/null +++ b/app/taro/src/selectors/errorSelectors.tsx @@ -0,0 +1,9 @@ +import { AppState } from "reducers"; + +export const getSafeCrash = (state: AppState) => { + return state.ui.errors.safeCrash; +}; + +export const getSafeCrashCode = (state: AppState) => { + return state.ui.errors.safeCrashCode; +}; diff --git a/app/taro/src/selectors/formSelectors.ts b/app/taro/src/selectors/formSelectors.ts new file mode 100644 index 0000000000..f443df9bbb --- /dev/null +++ b/app/taro/src/selectors/formSelectors.ts @@ -0,0 +1,21 @@ +import { getFormValues, isValid, getFormInitialValues } from "redux-form"; +import { AppState } from "reducers"; +import { ActionData } from "reducers/entityReducers/actionsReducer"; + +type GetFormData = ( + state: AppState, + formName: string, +) => { initialValues: any; values: any; valid: boolean }; + +export const getFormData: GetFormData = (state, formName) => { + const initialValues = getFormInitialValues(formName)(state); + const values = getFormValues(formName)(state); + const valid = isValid(formName)(state); + return { initialValues, values, valid }; +}; + +export const getApiName = (state: AppState, id: string) => { + return state.entities.actions.find( + (action: ActionData) => action.config.id === id, + )?.config.name; +}; diff --git a/app/taro/src/selectors/helpSelectors.tsx b/app/taro/src/selectors/helpSelectors.tsx new file mode 100644 index 0000000000..4cdb67bf60 --- /dev/null +++ b/app/taro/src/selectors/helpSelectors.tsx @@ -0,0 +1,8 @@ +import { AppState } from "reducers"; + +export const getHelpModalOpen = (state: AppState): boolean => + state.ui.help.modalOpen; + +export const getDefaultRefinement = (state: AppState): string => { + return state.ui.help.defaultRefinement || ""; +}; diff --git a/app/taro/src/selectors/notificationSelectors.ts b/app/taro/src/selectors/notificationSelectors.ts new file mode 100644 index 0000000000..c409452b35 --- /dev/null +++ b/app/taro/src/selectors/notificationSelectors.ts @@ -0,0 +1,13 @@ +import { AppState } from "reducers"; + +export const notificationsSelector = (state: AppState) => + state.ui.notifications.notifications; + +export const unreadCountSelector = (state: AppState) => + state.ui.notifications.unreadNotificationsCount; + +export const isNotificationsListVisibleSelector = (state: AppState) => + state.ui.notifications.showNotificationsMenu; + +export const fetchingNotificationsSelector = (state: AppState) => + state.ui.notifications.fetchingNotifications; diff --git a/app/taro/src/selectors/onboardingSelectors.tsx b/app/taro/src/selectors/onboardingSelectors.tsx new file mode 100644 index 0000000000..c170209a4c --- /dev/null +++ b/app/taro/src/selectors/onboardingSelectors.tsx @@ -0,0 +1,7 @@ +import { AppState } from "reducers"; + +export const getIsOnboardingHelperVisible = (state: AppState) => { + const urlSearchParams = new URL(window.location.href).searchParams; + const isCommentModeInUrl = urlSearchParams.get("isCommentMode"); + return state.ui.onBoarding.showHelper && !isCommentModeInUrl; +}; diff --git a/app/taro/src/selectors/organizationSelectors.tsx b/app/taro/src/selectors/organizationSelectors.tsx new file mode 100644 index 0000000000..607ab29c5d --- /dev/null +++ b/app/taro/src/selectors/organizationSelectors.tsx @@ -0,0 +1,63 @@ +import { createSelector } from "reselect"; +import { AppState } from "reducers"; +import { OrgRole } from "constants/orgConstants"; + +export const getRolesFromState = (state: AppState) => { + return state.ui.orgs.roles; +}; + +export const getOrgLoadingStates = (state: AppState) => { + return { + isFetchingOrg: state.ui.orgs.loadingStates.isFetchingOrg, + isFetchingAllUsers: state.ui.orgs.loadingStates.isFetchAllUsers, + isFetchingAllRoles: state.ui.orgs.loadingStates.isFetchAllRoles, + deletingUserInfo: state.ui.orgs.orgUsers.filter((el) => el.isDeleting)[0], + roleChangingUserInfo: state.ui.orgs.orgUsers.filter( + (el) => el.isChangingRole, + )[0], + }; +}; + +export const getCurrentOrgId = (state: AppState) => state.ui.orgs.currentOrg.id; +export const getOrgs = (state: AppState) => { + return state.ui.applications.userOrgs; +}; +export const getCurrentOrg = (state: AppState) => { + return state.ui.applications.userOrgs.map((el) => el.organization); +}; +export const getCurrentAppOrg = (state: AppState) => { + return state.ui.orgs.currentOrg; +}; +export const getAllUsers = (state: AppState) => state.ui.orgs.orgUsers; +export const getAllRoles = (state: AppState) => state.ui.orgs.orgRoles; + +export const getUserCurrentOrgId = (state: AppState) => { + return state.ui.users.currentUser?.currentOrganizationId; +}; + +export const getRoles = createSelector(getRolesFromState, (roles?: OrgRole[]): + | OrgRole[] + | undefined => { + return roles?.map((role) => ({ + id: role.id, + name: role.displayName || role.name, + isDefault: role.isDefault, + })); +}); + +export const getRolesForField = createSelector(getAllRoles, (roles?: any) => { + return Object.entries(roles).map((role) => { + return { + id: role[0], + name: role[0], + description: role[1], + }; + }); +}); + +export const getDefaultRole = createSelector(getRoles, (roles?: OrgRole[]) => { + return roles?.find((role) => role.isDefault); +}); +export const getCurrentError = (state: AppState) => { + return state.ui.errors.currentError; +}; diff --git a/app/taro/src/selectors/pageListSelectors.tsx b/app/taro/src/selectors/pageListSelectors.tsx new file mode 100644 index 0000000000..12a8f32f16 --- /dev/null +++ b/app/taro/src/selectors/pageListSelectors.tsx @@ -0,0 +1,11 @@ +import { AppState } from "reducers"; +import { createSelector } from "reselect"; + +import { PageListReduxState } from "../reducers/entityReducers/pageListReducer"; + +const getPageListState = (state: AppState) => state.entities.pageList; + +export const getIsGeneratingTemplatePage = createSelector( + getPageListState, + (pageList: PageListReduxState) => pageList.isGeneratingTemplatePage, +); diff --git a/app/taro/src/selectors/propertyPaneSelectors.tsx b/app/taro/src/selectors/propertyPaneSelectors.tsx new file mode 100644 index 0000000000..3d83a934f1 --- /dev/null +++ b/app/taro/src/selectors/propertyPaneSelectors.tsx @@ -0,0 +1,178 @@ +import { find, get, set } from "lodash"; +import { AppState } from "reducers"; +import { createSelector } from "reselect"; + +import { WidgetProps } from "widgets/BaseWidget"; +import { getCanvasWidgets } from "./entitiesSelector"; +import { getDataTree } from "selectors/dataTreeSelectors"; +import { DataTree, DataTreeWidget } from "entities/DataTree/dataTreeFactory"; +import { PropertyPaneReduxState } from "reducers/uiReducers/propertyPaneReducer"; +import { CanvasWidgetsReduxState } from "reducers/entityReducers/canvasWidgetsReducer"; +import { getSelectedWidget, getSelectedWidgets } from "./ui"; +import { EVALUATION_PATH } from "utils/DynamicBindingUtils"; +import { DataTreeEntity } from "entities/DataTree/dataTreeFactory"; + +export type WidgetProperties = WidgetProps & { + [EVALUATION_PATH]?: DataTreeEntity; +}; + +const getPropertyPaneState = (state: AppState): PropertyPaneReduxState => + state.ui.propertyPane; + +export const getCurrentWidgetId = createSelector( + getPropertyPaneState, + (propertyPane: PropertyPaneReduxState) => propertyPane.widgetId, +); + +export const getCurrentWidgetProperties = createSelector( + getCanvasWidgets, + getPropertyPaneState, + ( + widgets: CanvasWidgetsReduxState, + pane: PropertyPaneReduxState, + ): WidgetProps | undefined => { + return get(widgets, `${pane.widgetId}`); + }, +); + +export const getWidgetPropsForPropertyPane = createSelector( + getCurrentWidgetProperties, + getDataTree, + ( + widget: WidgetProps | undefined, + evaluatedTree: DataTree, + ): WidgetProps | undefined => { + if (!widget) return undefined; + const evaluatedWidget = find(evaluatedTree, { + widgetId: widget.widgetId, + }) as DataTreeWidget; + const widgetProperties = { ...widget }; + + if (evaluatedWidget) { + widgetProperties[EVALUATION_PATH] = evaluatedWidget[EVALUATION_PATH]; + } + return widgetProperties; + }, +); + +const populateWidgetProperties = ( + widget: WidgetProps | undefined, + propertyPath: string, + dependencies: string[], +) => { + const widgetProperties: any = {}; + + if (!widget) return widgetProperties; + + widgetProperties.type = widget.type; + widgetProperties.widgetName = widget.widgetName; + widgetProperties.widgetId = widget.widgetId; + widgetProperties.dynamicTriggerPathList = widget.dynamicTriggerPathList; + widgetProperties.dynamicPropertyPathList = widget.dynamicPropertyPathList; + + getAndSetPath(widget, widgetProperties, propertyPath); + + if (dependencies && dependencies.length > 0) { + for (const dependentProperty of dependencies) { + widgetProperties[dependentProperty] = widget[dependentProperty]; + } + } + + return widgetProperties; +}; + +const getAndSetPath = (from: any, to: any, path: string) => { + if (!from || !to) return; + + const value = get(from, path); + + if (value === null || value === undefined) return; + + set(to, path, value); +}; + +const populateEvaluatedWidgetProperties = ( + evaluatedWidget: DataTreeWidget, + propertyPath: string, +) => { + if (!evaluatedWidget || !evaluatedWidget[EVALUATION_PATH]) return; + + const evaluatedWidgetPath = evaluatedWidget[EVALUATION_PATH]; + + const evaluatedProperties = { + errors: {}, + evaluatedValues: {}, + }; + + getAndSetPath( + evaluatedWidgetPath?.errors, + evaluatedProperties.errors, + propertyPath, + ); + getAndSetPath( + evaluatedWidgetPath?.evaluatedValues, + evaluatedProperties.evaluatedValues, + propertyPath, + ); + + return evaluatedProperties; +}; + +export const getWidgetPropsForPropertyName = ( + propertyName: string, + dependencies: string[] = [], +) => { + return createSelector( + getCurrentWidgetProperties, + getDataTree, + ( + widget: WidgetProps | undefined, + evaluatedTree: DataTree, + ): WidgetProperties => { + const evaluatedWidget = find(evaluatedTree, { + widgetId: widget?.widgetId, + }) as DataTreeWidget; + + const widgetProperties = populateWidgetProperties( + widget, + propertyName, + dependencies, + ); + + widgetProperties[EVALUATION_PATH] = populateEvaluatedWidgetProperties( + evaluatedWidget, + propertyName, + ); + + return widgetProperties; + }, + ); +}; + +const isResizingorDragging = (state: AppState) => + state.ui.widgetDragResize.isResizing || state.ui.widgetDragResize.isDragging; + +export const getIsPropertyPaneVisible = createSelector( + getPropertyPaneState, + isResizingorDragging, + getSelectedWidget, + getSelectedWidgets, + ( + pane: PropertyPaneReduxState, + isResizingorDragging: boolean, + lastSelectedWidget, + widgets, + ) => { + const isWidgetSelected = pane.widgetId + ? lastSelectedWidget === pane.widgetId || widgets.includes(pane.widgetId) + : false; + const multipleWidgetsSelected = !!(widgets && widgets.length >= 2); + return !!( + isWidgetSelected && + !multipleWidgetsSelected && + !isResizingorDragging && + pane.isVisible && + pane.widgetId + ); + }, +); diff --git a/app/taro/src/selectors/tableFilterSelectors.tsx b/app/taro/src/selectors/tableFilterSelectors.tsx new file mode 100644 index 0000000000..937c33720d --- /dev/null +++ b/app/taro/src/selectors/tableFilterSelectors.tsx @@ -0,0 +1,37 @@ +import { AppState } from "reducers"; +import { createSelector } from "reselect"; + +import { TableFilterPaneReduxState } from "reducers/uiReducers/tableFilterPaneReducer"; +import { getSelectedWidget, getSelectedWidgets } from "./ui"; + +export const getTableFilterState = ( + state: AppState, +): TableFilterPaneReduxState => state.ui.tableFilterPane; + +const isResizingorDragging = (state: AppState) => + state.ui.widgetDragResize.isResizing || state.ui.widgetDragResize.isDragging; + +export const getIsTableFilterPaneVisible = createSelector( + getTableFilterState, + isResizingorDragging, + getSelectedWidget, + getSelectedWidgets, + ( + pane: TableFilterPaneReduxState, + isResizingorDragging: boolean, + lastSelectedWidget, + widgets, + ) => { + const isWidgetSelected = pane?.widgetId + ? lastSelectedWidget === pane.widgetId || widgets.includes(pane.widgetId) + : false; + const multipleWidgetsSelected = !!(widgets && widgets.length >= 2); + return !!( + isWidgetSelected && + !multipleWidgetsSelected && + !isResizingorDragging && + pane.isVisible && + pane.widgetId + ); + }, +); diff --git a/app/taro/src/selectors/themeSelectors.tsx b/app/taro/src/selectors/themeSelectors.tsx new file mode 100644 index 0000000000..aeb85b86ae --- /dev/null +++ b/app/taro/src/selectors/themeSelectors.tsx @@ -0,0 +1,26 @@ +import { AppState } from "reducers"; +import { dark, light, Theme, theme } from "constants/DefaultTheme"; + +export enum ThemeMode { + LIGHT = "LIGHT", + DARK = "DARK", +} + +const lightTheme = { ...theme, colors: { ...theme.colors, ...light } }; + +const darkTheme = { ...theme, colors: { ...theme.colors, ...dark } }; + +// Only for usage with ThemeProvider +export const getThemeDetails = (state: AppState, themeMode: ThemeMode): Theme => + themeMode === ThemeMode.LIGHT ? lightTheme : darkTheme; + +// Use to get the current theme of the app set via the theme switcher +export const getCurrentThemeDetails = (state: AppState): Theme => + state.ui.theme.theme; + +// Use to get the current theme mode of the app set via the theme switcher +export const getCurrentThemeMode = (state: AppState) => state.ui.theme.mode; + +export const getAppCardColorPalette = (state: AppState) => { + return state.ui.theme.theme.colors.appCardColors; +}; diff --git a/app/taro/src/selectors/tourSelectors.tsx b/app/taro/src/selectors/tourSelectors.tsx new file mode 100644 index 0000000000..4b2867a6e1 --- /dev/null +++ b/app/taro/src/selectors/tourSelectors.tsx @@ -0,0 +1,7 @@ +import { AppState } from "reducers"; + +export const getActiveTourIndex = (state: AppState) => + state.ui.tour?.activeTourIndex; + +export const getActiveTourType = (state: AppState) => + state.ui.tour?.activeTourType; diff --git a/app/taro/src/selectors/ui.tsx b/app/taro/src/selectors/ui.tsx new file mode 100644 index 0000000000..a0de172b7a --- /dev/null +++ b/app/taro/src/selectors/ui.tsx @@ -0,0 +1,7 @@ +import { AppState } from "reducers"; + +export const getSelectedWidget = (state: AppState) => + state.ui.widgetDragResize.lastSelectedWidget; + +export const getSelectedWidgets = (state: AppState) => + state.ui.widgetDragResize.selectedWidgets; diff --git a/app/taro/src/selectors/usersSelectors.tsx b/app/taro/src/selectors/usersSelectors.tsx new file mode 100644 index 0000000000..09f70828d7 --- /dev/null +++ b/app/taro/src/selectors/usersSelectors.tsx @@ -0,0 +1,14 @@ +import { AppState } from "reducers"; +import { User } from "constants/userConstants"; +import { PropertyPanePositionConfig } from "reducers/uiReducers/usersReducer"; + +export const getCurrentUser = (state: AppState): User | undefined => + state.ui.users.currentUser; +export const getUserAuthError = (state: AppState): string => + state.ui.users.error; +export const getUsers = (state: AppState): User[] => state.ui.users.users; +export const getProppanePreference = ( + state: AppState, +): PropertyPanePositionConfig | undefined => state.ui.users.propPanePreferences; +export const getFeatureFlagsFetched = (state: AppState) => + state.ui.users.featureFlagFetched; diff --git a/app/taro/src/selectors/widgetEnhancementSelectors.ts b/app/taro/src/selectors/widgetEnhancementSelectors.ts new file mode 100644 index 0000000000..ab3bebe66f --- /dev/null +++ b/app/taro/src/selectors/widgetEnhancementSelectors.ts @@ -0,0 +1,101 @@ +import { createSelector } from "reselect"; +import { get, set } from "lodash"; +import { AppState } from "reducers"; + +import { CanvasWidgetsReduxState } from "reducers/entityReducers/canvasWidgetsReducer"; +import { + getParentWithEnhancementFn, + getWidgetEnhancementFn, + WidgetEnhancementType, +} from "sagas/WidgetEnhancementHelpers"; +import { getWidgets } from "sagas/selectors"; + +const getEvaluationTree = (state: AppState) => state.evaluations.tree; + +const getPropsFromTree = (tree: unknown, widgetName?: string): unknown => { + // Get the evaluated data of this widget from the evaluations tree. + if (!widgetName) return; + + return get(tree, widgetName, undefined); +}; + +export type EnhancementFns = { + enhancementFns: { + updateDataTreePathFn: any; + propertyPaneEnhancementFn: any; + autoCompleteEnhancementFn: any; + customJSControlEnhancementFn: any; + hideEvaluatedValueEnhancementFn: any; + }; + parentIdWithEnhancementFn: any; +}; + +export const getWidgetEnhancementSelector = (widgetId: string) => { + return createSelector( + getWidgets, + getEvaluationTree, + (widgets: CanvasWidgetsReduxState, dataTree: unknown): EnhancementFns => { + const enhancementFns = { + updateDataTreePathFn: undefined, + propertyPaneEnhancementFn: undefined, + autoCompleteEnhancementFn: undefined, + customJSControlEnhancementFn: undefined, + hideEvaluatedValueEnhancementFn: undefined, + }; + + // Get the parent which wants to enhance this widget + const parentWithEnhancementFn = getParentWithEnhancementFn( + widgetId, + widgets, + ); + // If such a parent is found + // Get the parent's evaluated data from the evaluatedTree + const parentDataFromDataTree: unknown = getPropsFromTree( + dataTree, + parentWithEnhancementFn?.widgetName, + ); + + if (parentWithEnhancementFn) { + // Get the enhancement function based on the enhancementType + // from the configs + const widgetEnhancementFns = { + updateDataTreePathFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.UPDATE_DATA_TREE_PATH, + ), + propertyPaneEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.PROPERTY_UPDATE, + ), + autoCompleteEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.AUTOCOMPLETE, + ), + customJSControlEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.CUSTOM_CONTROL, + ), + hideEvaluatedValueEnhancementFn: getWidgetEnhancementFn( + parentWithEnhancementFn.type, + WidgetEnhancementType.HIDE_EVALUATED_VALUE, + ), + }; + + Object.keys(widgetEnhancementFns).map((key: string) => { + const enhancementFn = get(widgetEnhancementFns, `${key}`); + + if (parentDataFromDataTree && enhancementFn) { + set(enhancementFns, `${key}`, (...args: unknown[]) => + enhancementFn(parentDataFromDataTree, ...args), + ); + } + }); + } + + return { + enhancementFns: enhancementFns, + parentIdWithEnhancementFn: get(parentWithEnhancementFn, "widgetId", ""), + }; + }, + ); +}; diff --git a/app/taro/src/selectors/widgetSelectors.ts b/app/taro/src/selectors/widgetSelectors.ts new file mode 100644 index 0000000000..1e38e687a8 --- /dev/null +++ b/app/taro/src/selectors/widgetSelectors.ts @@ -0,0 +1,33 @@ +import { createSelector } from "reselect"; +import { AppState } from "reducers"; +import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; +import { WidgetTypes } from "constants/WidgetConstants"; +import { getExistingWidgetNames, getWidgetNamePrefix } from "sagas/selectors"; +import { getNextEntityName } from "utils/AppsmithUtils"; + +const getCanvasWidgets = (state: AppState) => state.entities.canvasWidgets; +export const getModalDropdownList = createSelector( + getCanvasWidgets, + (widgets) => { + const modalWidgets = Object.values(widgets).filter( + (widget: FlattenedWidgetProps) => + widget.type === WidgetTypes.MODAL_WIDGET, + ); + if (modalWidgets.length === 0) return undefined; + + return modalWidgets.map((widget: FlattenedWidgetProps) => ({ + id: widget.widgetId, + label: widget.widgetName, + value: `${widget.widgetName}`, + })); + }, +); + +const getModalNamePrefix = (state: AppState) => + getWidgetNamePrefix(state, WidgetTypes.MODAL_WIDGET); + +export const getNextModalName = createSelector( + getExistingWidgetNames, + getModalNamePrefix, + (names, prefix) => getNextEntityName(prefix, names), +); diff --git a/app/taro/src/store.ts b/app/taro/src/store.ts new file mode 100644 index 0000000000..b7323210b0 --- /dev/null +++ b/app/taro/src/store.ts @@ -0,0 +1,20 @@ +import { reduxBatch } from "@manaflair/redux-batch"; +import { createStore, applyMiddleware } from "redux"; +import appReducer from "./reducers"; +import createSagaMiddleware from "redux-saga"; +import { rootSaga } from "sagas"; +import { composeWithDevTools } from "redux-devtools-extension/logOnlyInProduction"; + +export const newStore = () => { + const middleware = createSagaMiddleware(); + const store = createStore( + appReducer, + composeWithDevTools( + reduxBatch, + applyMiddleware(middleware), + reduxBatch, + ), + ); + middleware.run(rootSaga); + return store; +}; diff --git a/app/taro/src/templates/default.ts b/app/taro/src/templates/default.ts new file mode 100644 index 0000000000..249f498bbd --- /dev/null +++ b/app/taro/src/templates/default.ts @@ -0,0 +1,19 @@ +import { GridDefaults } from "constants/WidgetConstants"; + +export default { + widgetName: "MainContainer", + backgroundColor: "none", + rightColumn: 1242, + snapColumns: GridDefaults.DEFAULT_GRID_COLUMNS, + widgetId: "0", + topRow: 0, + bottomRow: 1292, + parentRowSpace: 1, + type: "CANVAS_WIDGET", + detachFromLayout: true, + minHeight: 1292, + dynamicBindingPathList: {}, + parentColumnSpace: 1, + leftColumn: 0, + children: [], +}; diff --git a/app/taro/src/transformers/CurlImportTransformer.ts b/app/taro/src/transformers/CurlImportTransformer.ts new file mode 100644 index 0000000000..10ed0a72b0 --- /dev/null +++ b/app/taro/src/transformers/CurlImportTransformer.ts @@ -0,0 +1,3 @@ +export default (curlString: string): string => { + return JSON.stringify(curlString); +}; diff --git a/app/taro/src/transformers/RestAPIDatasourceFormTransformer.ts b/app/taro/src/transformers/RestAPIDatasourceFormTransformer.ts new file mode 100644 index 0000000000..8a10dac832 --- /dev/null +++ b/app/taro/src/transformers/RestAPIDatasourceFormTransformer.ts @@ -0,0 +1,249 @@ +import { Property } from "entities/Action"; +import { Datasource } from "entities/Datasource"; +import { + ApiDatasourceForm, + Authentication, + AuthorizationCode, + AuthType, + ClientCredentials, + GrantType, + Oauth2Common, + Basic, + ApiKey, + BearerToken, +} from "entities/Datasource/RestAPIForm"; +import _ from "lodash"; + +export const datasourceToFormValues = ( + datasource: Datasource, +): ApiDatasourceForm => { + const authType = _.get( + datasource, + "datasourceConfiguration.authentication.authenticationType", + AuthType.NONE, + ); + const authentication = datasourceToFormAuthentication(authType, datasource); + const isSendSessionEnabled = + _.get(datasource, "datasourceConfiguration.properties[0].value", "N") === + "Y"; + const sessionSignatureKey = isSendSessionEnabled + ? _.get(datasource, "datasourceConfiguration.properties[1].value") + : ""; + return { + datasourceId: datasource.id, + organizationId: datasource.organizationId, + pluginId: datasource.pluginId, + isValid: datasource.isValid, + url: datasource.datasourceConfiguration.url, + headers: cleanupProperties(datasource.datasourceConfiguration.headers), + isSendSessionEnabled: isSendSessionEnabled, + sessionSignatureKey: sessionSignatureKey, + authType: authType, + authentication: authentication, + }; +}; + +export const formValuesToDatasource = ( + datasource: Datasource, + form: ApiDatasourceForm, +): Datasource => { + const authentication = formToDatasourceAuthentication( + form.authType, + form.authentication, + ); + + return { + ...datasource, + datasourceConfiguration: { + url: form.url, + headers: cleanupProperties(form.headers), + properties: [ + { + key: "isSendSessionEnabled", + value: form.isSendSessionEnabled ? "Y" : "N", + }, + { key: "sessionSignatureKey", value: form.sessionSignatureKey }, + ], + authentication: authentication, + }, + } as Datasource; +}; + +const formToDatasourceAuthentication = ( + authType: AuthType, + authentication: Authentication | undefined, +): Authentication | null => { + if (authType === AuthType.NONE || !authentication) return null; + if ( + isClientCredentials(authType, authentication) || + isAuthorizationCode(authType, authentication) + ) { + const oAuth2Common: Oauth2Common = { + authenticationType: AuthType.OAuth2, + accessTokenUrl: authentication.accessTokenUrl, + clientId: authentication.clientId, + headerPrefix: authentication.headerPrefix, + scopeString: authentication.scopeString, + clientSecret: authentication.clientSecret, + isTokenHeader: authentication.isTokenHeader, + audience: authentication.audience, + resource: authentication.resource, + }; + if (isClientCredentials(authType, authentication)) { + return { + ...oAuth2Common, + grantType: GrantType.ClientCredentials, + }; + } + if (isAuthorizationCode(authType, authentication)) { + return { + ...oAuth2Common, + grantType: GrantType.AuthorizationCode, + authorizationUrl: authentication.authorizationUrl, + isAuthorizationHeader: authentication.isAuthorizationHeader, + isAuthorized: !!authentication.isAuthorized, + customAuthenticationParameters: cleanupProperties( + authentication.customAuthenticationParameters, + ), + }; + } + } + if (authType === AuthType.basic) { + if ("username" in authentication) { + const basic: Basic = { + authenticationType: AuthType.basic, + username: authentication.username, + password: authentication.password, + }; + return basic; + } + } + if (authType === AuthType.apiKey) { + if ("label" in authentication) { + const apiKey: ApiKey = { + authenticationType: AuthType.apiKey, + label: authentication.label, + value: authentication.value, + addTo: authentication.addTo, + }; + return apiKey; + } + } + if (authType === AuthType.bearerToken) { + if ("bearerToken" in authentication) { + const bearerToken: BearerToken = { + authenticationType: AuthType.bearerToken, + bearerToken: authentication.bearerToken, + }; + return bearerToken; + } + } + return null; +}; + +const datasourceToFormAuthentication = ( + authType: AuthType, + datasource: Datasource, +): Authentication | undefined => { + if ( + !datasource || + !datasource.datasourceConfiguration || + !datasource.datasourceConfiguration.authentication + ) { + return; + } + + const authentication = datasource.datasourceConfiguration.authentication; + if ( + isClientCredentials(authType, authentication) || + isAuthorizationCode(authType, authentication) + ) { + const oAuth2Common: Oauth2Common = { + authenticationType: AuthType.OAuth2, + accessTokenUrl: authentication.accessTokenUrl || "", + clientId: authentication.clientId || "", + headerPrefix: authentication.headerPrefix || "", + scopeString: authentication.scopeString || "", + clientSecret: authentication.clientSecret, + isTokenHeader: !!authentication.isTokenHeader, + audience: authentication.audience || "", + resource: authentication.resource || "", + }; + if (isClientCredentials(authType, authentication)) { + return { + ...oAuth2Common, + grantType: GrantType.ClientCredentials, + }; + } + if (isAuthorizationCode(authType, authentication)) { + return { + ...oAuth2Common, + grantType: GrantType.AuthorizationCode, + authorizationUrl: authentication.authorizationUrl || "", + customAuthenticationParameters: cleanupProperties( + authentication.customAuthenticationParameters, + ), + isAuthorized: !!authentication.isAuthorized, + isAuthorizationHeader: + typeof authentication.isAuthorizationHeader === "undefined" + ? true + : !!authentication.isAuthorizationHeader, + }; + } + } + if (authType === AuthType.basic) { + const basic: Basic = { + authenticationType: AuthType.basic, + username: authentication.username || "", + password: authentication.password || "", + }; + return basic; + } + if (authType === AuthType.apiKey) { + const apiKey: ApiKey = { + authenticationType: AuthType.apiKey, + label: authentication.label || "", + value: authentication.value || "", + addTo: authentication.addTo || "", + }; + return apiKey; + } + if (authType === AuthType.bearerToken) { + const bearerToken: BearerToken = { + authenticationType: AuthType.bearerToken, + bearerToken: authentication.bearerToken || "", + }; + return bearerToken; + } +}; + +const isClientCredentials = ( + authType: AuthType, + val: any, +): val is ClientCredentials => { + if (authType !== AuthType.OAuth2) return false; + // If there's no authentication object at all and it is oauth2, it is client credentials by default + if (!val) return true; + return _.get(val, "grantType") === GrantType.ClientCredentials; +}; + +const isAuthorizationCode = ( + authType: AuthType, + val: any, +): val is AuthorizationCode => { + if (authType !== AuthType.OAuth2) return false; + return _.get(val, "grantType") === GrantType.AuthorizationCode; +}; + +const cleanupProperties = (values: Property[] | undefined): Property[] => { + if (!Array.isArray(values)) return []; + + const newValues: Property[] = []; + values.forEach((object: Property) => { + const isEmpty = Object.values(object).every((x) => x === ""); + if (!isEmpty) { + newValues.push(object); + } + }); + return newValues; +}; diff --git a/app/taro/src/transformers/RestActionTransformer.ts b/app/taro/src/transformers/RestActionTransformer.ts new file mode 100644 index 0000000000..061bce0041 --- /dev/null +++ b/app/taro/src/transformers/RestActionTransformer.ts @@ -0,0 +1,45 @@ +import { HTTP_METHODS } from "constants/ApiEditorConstants"; +import { ApiAction } from "entities/Action"; +import _ from "lodash"; + +export const transformRestAction = (data: ApiAction): ApiAction => { + let action = _.cloneDeep(data); + // // GET actions should not save body + // if (action.actionConfiguration.httpMethod === HTTP_METHODS[0]) { + // delete action.actionConfiguration.body; + // } + // Paths should not have query params + if ( + action.actionConfiguration.queryParameters && + action.actionConfiguration.queryParameters.length + ) { + const path = action.actionConfiguration.path; + if (path && path.indexOf("?") > -1) { + action = { + ...action, + actionConfiguration: { + ...action.actionConfiguration, + path: path.substr(0, path.indexOf("?")), + }, + }; + } + } + // Body should send correct format depending on the content type + if (action.actionConfiguration.httpMethod !== HTTP_METHODS[0]) { + let body: any = ""; + if (action.actionConfiguration.body) { + body = action.actionConfiguration.body || undefined; + } + + if (!_.isString(body)) body = JSON.stringify(body); + action = { + ...action, + actionConfiguration: { + ...action.actionConfiguration, + body, + }, + }; + } + + return action; +}; diff --git a/app/taro/src/typings/worker-loader/index.d.ts b/app/taro/src/typings/worker-loader/index.d.ts new file mode 100644 index 0000000000..756d321d72 --- /dev/null +++ b/app/taro/src/typings/worker-loader/index.d.ts @@ -0,0 +1,7 @@ +declare module "worker-loader?filename=worker.js!*" { + class WebpackWorker extends Worker { + constructor(); + } + + export default WebpackWorker; +} diff --git a/app/taro/src/utils/AnalyticsUtil.tsx b/app/taro/src/utils/AnalyticsUtil.tsx new file mode 100644 index 0000000000..0070edcda6 --- /dev/null +++ b/app/taro/src/utils/AnalyticsUtil.tsx @@ -0,0 +1,149 @@ + +export type EventLocation = + | "LIGHTNING_MENU" + | "API_PANE" + | "QUERY_PANE" + | "QUERY_TEMPLATE" + | "QUICK_COMMANDS"; + +export type EventName = + | "LOGIN_CLICK" + | "SIGNUP_CLICK" + | "PAGE_VIEW" + | "ADD_COMPONENT" + | "DELETE_COMPONENT" + | "RESIZE_COMPONENT" + | "WIDGET_DRAG" + | "WIDGET_DROP" + | "WIDGET_DELETE" + | "WIDGET_RESIZE_START" + | "WIDGET_RESIZE_END" + | "WIDGET_PROPERTY_UPDATE" + | "WIDGET_TOGGLE_JS_PROP" + | "WIDGET_CARD_DRAG" + | "WIDGET_CARD_DROP" + | "CREATE_PAGE" + | "PAGE_RENAME" + | "PAGE_SWITCH" + | "DELETE_PAGE" + | "SIDEBAR_NAVIGATION" + | "PUBLISH_APP" + | "PREVIEW_APP" + | "EDITOR_OPEN" + | "CREATE_ACTION" + | "SAVE_SAAS" + | "DELETE_SAAS" + | "RUN_SAAS_API" + | "SAVE_API" + | "SAVE_API_CLICK" + | "RUN_API" + | "RUN_API_CLICK" + | "RUN_API_SHORTCUT" + | "DELETE_API" + | "DELETE_API_CLICK" + | "IMPORT_API" + | "EXPAND_API" + | "IMPORT_API_CLICK" + | "MOVE_API_CLICK" + | "ADD_API_PAGE" + | "DUPLICATE_API" + | "DUPLICATE_API_CLICK" + | "RUN_QUERY" + | "RUN_QUERY_CLICK" + | "RUN_QUERY_SHORTCUT" + | "DELETE_QUERY" + | "SAVE_QUERY" + | "MOVE_API" + | "3P_PROVIDER_CLICK" + | "API_SELECT" + | "CREATE_API_CLICK" + | "AUTO_COMPLETE_SHOW" + | "AUTO_COMPLETE_SELECT" + | "CREATE_APP_CLICK" + | "CREATE_APP" + | "CREATE_DATA_SOURCE_CLICK" + | "SAVE_DATA_SOURCE" + | "SAVE_DATA_SOURCE_CLICK" + | "TEST_DATA_SOURCE_SUCCESS" + | "TEST_DATA_SOURCE_CLICK" + | "CREATE_QUERY_CLICK" + | "NAVIGATE" + | "PAGE_LOAD" + | "NAVIGATE_EDITOR" + | "PROPERTY_PANE_OPEN" + | "PROPERTY_PANE_CLOSE" + | "PROPERTY_PANE_OPEN_CLICK" + | "PROPERTY_PANE_CLOSE_CLICK" + | "WIDGET_DELETE_UNDO" + | "WIDGET_COPY_VIA_SHORTCUT" + | "WIDGET_COPY" + | "WIDGET_CUT_VIA_SHORTCUT" + | "WIDGET_PASTE" + | "WIDGET_DELETE_VIA_SHORTCUT" + | "OPEN_HELP" + | "INVITE_USER" + | "ROUTE_CHANGE" + | "PROPERTY_PANE_CLOSE_CLICK" + | "APPLICATIONS_PAGE_LOAD" + | "EXECUTE_ACTION" + | "WELCOME_TOUR_CLICK" + | "ONBOARDING_WELCOME" + | "ONBOARDING_START_BUILDING" + | "ONBOARDING_INTRODUCTION" + | "ONBOARDING_ADD_QUERY" + | "ONBOARDING_RUN_QUERY" + | "ONBOARDING_ADD_WIDGET_CLICK" + | "ONBOARDING_ADD_WIDGET_TABLE" + | "ONBOARDING_ADD_WIDGET_INPUT" + | "ONBOARDING_ONSUBMIT_SUCCESS" + | "ONBOARDING_BINDING_HINT" + | "ONBOARDING_CHEAT" + | "ONBOARDING_SUCCESSFUL_BINDING" + | "ONBOARDING_DEPLOY" + | "ONBOARDING_SKIP_NOW" + | "ONBOARDING_NEXT_MISSION" + | "ONBOARDING_GO_HOME" + | "END_ONBOARDING" + | "ONBOARDING_COMPLETE" + | "OPEN_OMNIBAR" + | "CLOSE_OMNIBAR" + | "NAVIGATE_TO_ENTITY_FROM_OMNIBAR" + | "PAGE_SAVE" + | "CORRECT_BAD_BINDING" + | "OPEN_DEBUGGER" + | "DEBUGGER_TAB_SWITCH" + | "DEBUGGER_ENTITY_NAVIGATION" + | "GSHEET_AUTH_INIT" + | "GSHEET_AUTH_COMPLETE" + | "CYCLICAL_DEPENDENCY_ERROR" + | "DISCORD_LINK_CLICK" + | "BINDING_SUCCESS" + | "APP_MENU_OPTION_CLICK" + | "SLASH_COMMAND" + | "DEBUGGER_NEW_ERROR" + | "DEBUGGER_RESOLVED_ERROR" + | "ADD_MOCK_DATASOURCE_CLICK" + | "CREATE_DATA_SOURCE_AUTH_API_CLICK" + | "GEN_CRUD_PAGE_CREATE_NEW_DATASOURCE" + | "GEN_CRUD_PAGE_FORM_SUBMIT" + | "GEN_CRUD_PAGE_EDIT_DATASOURCE_CONFIG" + | "GEN_CRUD_PAGE_SELECT_DATASOURCE" + | "GEN_CRUD_PAGE_SELECT_TABLE" + | "GEN_CRUD_PAGE_SELECT_SEARCH_COLUMN" + | "GEN_CRUD_PAGE_SELECT_SEARCH_COLUMN" + | "BUILD_FROM_SCRATCH_ACTION_CARD_CLICK" + | "GEN_CRUD_PAGE_ACTION_CARD_CLICK" + | "GEN_CRUD_PAGE_DATA_SOURCE_CLICK" + | "DATASOURCE_CARD_GEN_CRUD_PAGE_ACTION" + | "DATASOURCE_CARD_DELETE_ACTION" + | "DATASOURCE_CARD_EDIT_ACTION" + | "UNSUPPORTED_PLUGIN_DIALOG_BACK_ACTION" + | "UNSUPPORTED_PLUGIN_DIALOG_CONTINUE_ACTION" + | "SELECT_IN_CANVAS_CLICK" + | "WIDGET_SELECTED_VIA_SNIPING_MODE" + | "SUGGESTED_WIDGET_CLICK" + | "ASSOCIATED_ENTITY_CLICK" + | "CREATE_DATA_SOURCE_AUTH_API_CLICK" + | "CONNECT_DATA_CLICK" + | "RESPONSE_TAB_RUN_ACTION_CLICK" + | "ASSOCIATED_ENTITY_DROPDOWN_CLICK"; diff --git a/app/taro/src/utils/AppsmithConsole.ts b/app/taro/src/utils/AppsmithConsole.ts new file mode 100644 index 0000000000..f43dd19229 --- /dev/null +++ b/app/taro/src/utils/AppsmithConsole.ts @@ -0,0 +1,40 @@ +import { Message, Severity, LogActionPayload } from "entities/AppsmithConsole"; +import dayjs from "dayjs"; + +function log(ev: Message) { + // store.dispatch(debuggerLogInit(ev)); +} + +function getTimeStamp() { + return dayjs().format("hh:mm:ss"); +} + +function info(ev: LogActionPayload) { + log({ + ...ev, + severity: Severity.INFO, + timestamp: getTimeStamp(), + }); +} + +function warning(ev: LogActionPayload) { + log({ + ...ev, + severity: Severity.WARNING, + timestamp: getTimeStamp(), + }); +} + +function error(ev: LogActionPayload) { + log({ + ...ev, + severity: Severity.ERROR, + timestamp: getTimeStamp(), + }); +} + +export default { + info, + warning, + error, +}; diff --git a/app/taro/src/utils/AppsmithUtils.tsx b/app/taro/src/utils/AppsmithUtils.tsx new file mode 100644 index 0000000000..8691f296d8 --- /dev/null +++ b/app/taro/src/utils/AppsmithUtils.tsx @@ -0,0 +1,241 @@ +import { ReduxAction } from "constants/ReduxActionConstants"; +// import FormControlRegistry from "./FormControlRegistry"; +import { getAppsmithConfigs } from "configs"; +import { Property } from "api/ActionAPI"; +import _ from "lodash"; +import { ActionDataState } from "reducers/entityReducers/actionsReducer"; +import * as log from "loglevel"; +import produce from "immer"; +import { ERROR_CODES } from "constants/ApiConstants"; +import { createMessage, ERROR_500 } from "../constants/messages"; + +export const createReducer = ( + initialState: any, + handlers: { [type: string]: (state: any, action: any) => any } +) => { + return function reducer(state = initialState, action: ReduxAction) { + if (handlers.hasOwnProperty(action.type)) { + return handlers[action.type](state, action); + } else { + return state; + } + }; +}; + +export const createImmerReducer = ( + initialState: any, + handlers: { [type: string]: any } +) => { + return function reducer(state = initialState, action: ReduxAction) { + if (handlers.hasOwnProperty(action.type)) { + return produce(handlers[action.type])(state, action); + } else { + return state; + } + }; +}; + +export const appInitializer = () => { + const appsmithConfigs = getAppsmithConfigs(); + // FormControlRegistry.registerFormControlBuilders(); + log.setLevel(appsmithConfigs.logLevel); +}; + +export const transformDynamicSize = (n: number) => `${(n * 750) / 450}rpx`; + +export const mapToPropList = (map: Record): Property[] => { + return _.map(map, (value, key) => { + return { key: key, value: value }; + }); +}; + +export const getNextEntityName = ( + prefix: string, + existingNames: string[], + startWithoutIndex?: boolean +) => { + const regex = new RegExp(`^${prefix}(\\d+)$`); + + const usedIndices: number[] = existingNames.map((name) => { + if (name && regex.test(name)) { + const matches = name.match(regex); + const ind = + matches && Array.isArray(matches) ? parseInt(matches[1], 10) : 0; + return Number.isNaN(ind) ? 0 : ind; + } + return 0; + }) as number[]; + + const lastIndex = Math.max(...usedIndices, ...[0]); + + if (startWithoutIndex && lastIndex === 0) { + const exactMatchFound = existingNames.some( + (name) => prefix && name.trim() === prefix.trim() + ); + if (!exactMatchFound) { + return prefix.trim(); + } + } + + return prefix + (lastIndex + 1); +}; + +export const getDuplicateName = (prefix: string, existingNames: string[]) => { + const trimmedPrefix = prefix.replace(/ /g, ""); + const regex = new RegExp(`^${trimmedPrefix}(\\d+)$`); + const usedIndices: number[] = existingNames.map((name) => { + if (name && regex.test(name)) { + const matches = name.match(regex); + const ind = + matches && Array.isArray(matches) ? parseInt(matches[1], 10) : 0; + return Number.isNaN(ind) ? 0 : ind; + } + return 0; + }) as number[]; + + const lastIndex = Math.max(...usedIndices, ...[0]); + + return trimmedPrefix + `_${lastIndex + 1}`; +}; + +export const createNewApiName = (actions: ActionDataState, pageId: string) => { + const pageApiNames = actions + .filter((a) => a.config.pageId === pageId) + .map((a) => a.config.name); + return getNextEntityName("Api", pageApiNames); +}; + +export const noop = () => { + log.debug("noop"); +}; + +export const stopEventPropagation = (e: any) => { + e.stopPropagation(); +}; + +export const createNewQueryName = ( + queries: ActionDataState, + pageId: string +) => { + const pageApiNames = queries + .filter((a) => a.config.pageId === pageId) + .map((a) => a.config.name); + const newName = getNextEntityName("Query", pageApiNames); + return newName; +}; + +export const convertToString = (value: any): string => { + if (_.isUndefined(value)) { + return ""; + } + if (_.isObject(value)) { + return JSON.stringify(value, null, 2); + } + if (_.isString(value)) return value; + return value.toString(); +}; + +export const getInitialsAndColorCode = ( + fullName: any, + colorPalette: string[] +): string[] => { + let inits = ""; + // if name contains space. eg: "Full Name" + if (fullName && fullName.includes(" ")) { + const namesArr = fullName.split(" "); + let initials = namesArr.map((name: string) => name.charAt(0)); + initials = initials.join("").toUpperCase(); + inits = initials.slice(0, 2); + } else { + // handle for camelCase + const str = fullName ? fullName.replace(/([a-z])([A-Z])/g, "$1 $2") : ""; + const namesArr = str.split(" "); + let initials = namesArr.map((name: string) => name.charAt(0)); + initials = initials.join("").toUpperCase(); + inits = initials.slice(0, 2); + } + const colorCode = getColorCode(inits, colorPalette); + return [inits, colorCode]; +}; + +export const getColorCode = ( + initials: string, + colorPalette: string[] +): string => { + let asciiSum = 0; + for (let i = 0; i < initials.length; i++) { + asciiSum += initials[i].charCodeAt(0); + } + return colorPalette[asciiSum % colorPalette.length]; +}; + +export function hexToRgb(hex: string): { + r: number; + g: number; + b: number; +} { + const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); + return result + ? { + r: parseInt(result[1], 16), + g: parseInt(result[2], 16), + b: parseInt(result[3], 16), + } + : { + r: -1, + g: -1, + b: -1, + }; +} + +export function getQueryParams() { + const urlParams = new URLSearchParams(window.location.search); + const keys = urlParams.keys(); + let key = keys.next().value; + const queryParams: Record = {}; + while (key) { + queryParams[key] = urlParams.get(key) as string; + key = keys.next().value; + } + return queryParams; +} + +export function convertObjectToQueryParams(object: any): string { + if (!_.isNil(object)) { + const paramArray: string[] = _.map(_.keys(object), (key) => { + return encodeURIComponent(key) + "=" + encodeURIComponent(object[key]); + }); + return "?" + _.join(paramArray, "&"); + } else { + return ""; + } +} + +export const retryPromise = ( + fn: () => Promise, + retriesLeft = 5, + interval = 1000 +): Promise => { + return new Promise((resolve, reject) => { + fn() + .then(resolve) + .catch(() => { + setTimeout(() => { + if (retriesLeft === 1) { + return Promise.reject({ + code: ERROR_CODES.SERVER_ERROR, + message: createMessage(ERROR_500), + show: false, + }); + } + + // Passing on "reject" is the important part + retryPromise(fn, retriesLeft - 1, interval).then(resolve, reject); + }, interval); + }); + }); +}; + +export const getRandomPaletteColor = (colorPalette: string[]) => { + return colorPalette[Math.floor(Math.random() * colorPalette.length)]; +}; diff --git a/app/taro/src/utils/DynamicBindingUtils.ts b/app/taro/src/utils/DynamicBindingUtils.ts new file mode 100644 index 0000000000..8d960a21f7 --- /dev/null +++ b/app/taro/src/utils/DynamicBindingUtils.ts @@ -0,0 +1,338 @@ +import _, { VERSION as lodashVersion } from "lodash"; +import { + DATA_BIND_REGEX, + DATA_BIND_REGEX_GLOBAL, +} from "constants/BindingsConstants"; +import { Action } from "entities/Action"; +import dayjs from "dayjs"; +import { WidgetProps } from "widgets/BaseWidget"; +import parser from "fast-xml-parser"; +import { Severity } from "entities/AppsmithConsole"; +import { getEntityNameAndPropertyPath } from "workers/evaluationUtils"; +// import forge from "node-forge"; + +export type DependencyMap = Record>; + +export const removeBindingsFromActionObject = (obj: Action) => { + const string = JSON.stringify(obj); + const withBindings = string.replace(DATA_BIND_REGEX_GLOBAL, "{{ }}"); + return JSON.parse(withBindings); +}; +// referencing DATA_BIND_REGEX fails for the value "{{Table1.tableData[Table1.selectedRowIndex]}}" if you run it multiple times and don't recreate +export const isDynamicValue = (value: string): boolean => + DATA_BIND_REGEX.test(value); + +//{{}}{{}}} +export function getDynamicStringSegments(dynamicString: string): string[] { + let stringSegments: any[] = []; + const indexOfDoubleParanStart = dynamicString.indexOf("{{"); + if (indexOfDoubleParanStart === -1) { + return [dynamicString]; + } + //{{}}{{}}} + const firstString = dynamicString.substring(0, indexOfDoubleParanStart); + firstString && stringSegments.push(firstString); + let rest = dynamicString.substring( + indexOfDoubleParanStart, + dynamicString.length, + ); + //{{}}{{}}} + let sum = 0; + for (let i = 0; i <= rest.length - 1; i++) { + const char = rest[i]; + const prevChar = rest[i - 1]; + + if (char === "{") { + sum++; + } else if (char === "}") { + sum--; + if (prevChar === "}" && sum === 0) { + stringSegments.push(rest.substring(0, i + 1)); + rest = rest.substring(i + 1, rest.length); + if (rest) { + stringSegments = stringSegments.concat( + getDynamicStringSegments(rest), + ); + break; + } + } + } + } + if (sum !== 0 && dynamicString !== "") { + return [dynamicString]; + } + return stringSegments; +} + +export const getDynamicBindings = ( + dynamicString: string, +): { stringSegments: string[]; jsSnippets: string[] } => { + // Protect against bad string parse + if (!dynamicString || !_.isString(dynamicString)) { + return { stringSegments: [], jsSnippets: [] }; + } + const sanitisedString = dynamicString.trim(); + // Get the {{binding}} bound values + const stringSegments = getDynamicStringSegments(sanitisedString); + // Get the "binding" path values + const paths = stringSegments.map((segment) => { + const length = segment.length; + const matches = isDynamicValue(segment); + if (matches) { + return segment.substring(2, length - 2); + } + return ""; + }); + return { stringSegments: stringSegments, jsSnippets: paths }; +}; + +export enum EvalErrorTypes { + CYCLICAL_DEPENDENCY_ERROR = "CYCLICAL_DEPENDENCY_ERROR", + EVAL_PROPERTY_ERROR = "EVAL_PROPERTY_ERROR", + EVAL_TREE_ERROR = "EVAL_TREE_ERROR", + UNKNOWN_ERROR = "UNKNOWN_ERROR", + BAD_UNEVAL_TREE_ERROR = "BAD_UNEVAL_TREE_ERROR", + EVAL_TRIGGER_ERROR = "EVAL_TRIGGER_ERROR", +} + +export type EvalError = { + type: EvalErrorTypes; + message: string; + context?: Record; +}; + +export enum EVAL_WORKER_ACTIONS { + EVAL_TREE = "EVAL_TREE", + EVAL_ACTION_BINDINGS = "EVAL_ACTION_BINDINGS", + EVAL_TRIGGER = "EVAL_TRIGGER", + CLEAR_PROPERTY_CACHE = "CLEAR_PROPERTY_CACHE", + CLEAR_PROPERTY_CACHE_OF_WIDGET = "CLEAR_PROPERTY_CACHE_OF_WIDGET", + CLEAR_CACHE = "CLEAR_CACHE", + VALIDATE_PROPERTY = "VALIDATE_PROPERTY", +} + +export type ExtraLibrary = { + version: string; + docsURL: string; + displayName: string; + accessor: string; + lib: any; +}; + +export const extraLibraries: ExtraLibrary[] = [ + { + accessor: "_", + lib: _, + version: lodashVersion, + docsURL: `https://lodash.com/docs/${lodashVersion}`, + displayName: "lodash", + }, + { + accessor: "dayjs", + lib: dayjs, + version: "1.10.7", + docsURL: `https://dayjs.gitee.io/docs/zh-CN/parse/parse`, + displayName: "dayjs", + }, + { + accessor: "xmlParser", + lib: parser, + version: "3.17.5", + docsURL: "https://github.com/NaturalIntelligence/fast-xml-parser", + displayName: "xmlParser", + }, + // { + // accessor: "forge", + // // We are removing some functionalities of node-forge because they wont + // // work in the worker thread + // lib: _.omit(forge, ["tls", "http", "xhr", "socket", "task"]), + // version: "0.10.0", + // docsURL: "https://github.com/digitalbazaar/forge", + // displayName: "forge", + // }, +]; + +export interface DynamicPath { + key: string; + value?: string; +} + +export interface WidgetDynamicPathListProps { + dynamicBindingPathList?: DynamicPath[]; + dynamicTriggerPathList?: DynamicPath[]; + dynamicPropertyPathList?: DynamicPath[]; +} + +export interface EntityWithBindings { + dynamicBindingPathList?: DynamicPath[]; +} + +export const getEntityDynamicBindingPathList = ( + entity: EntityWithBindings, +): DynamicPath[] => { + if ( + entity && + entity.dynamicBindingPathList && + Array.isArray(entity.dynamicBindingPathList) + ) { + return [...entity.dynamicBindingPathList]; + } + return []; +}; + +export const isPathADynamicBinding = ( + entity: EntityWithBindings, + path: string, +): boolean => { + if ( + entity && + entity.dynamicBindingPathList && + Array.isArray(entity.dynamicBindingPathList) + ) { + return _.find(entity.dynamicBindingPathList, { key: path }) !== undefined; + } + return false; +}; + +export const getWidgetDynamicTriggerPathList = ( + widget: WidgetProps, +): DynamicPath[] => { + if ( + widget && + widget.dynamicTriggerPathList && + Array.isArray(widget.dynamicTriggerPathList) + ) { + return [...widget.dynamicTriggerPathList]; + } + return []; +}; + +export const isPathADynamicTrigger = ( + widget: WidgetProps, + path: string, +): boolean => { + if ( + widget && + widget.dynamicTriggerPathList && + Array.isArray(widget.dynamicTriggerPathList) + ) { + return _.find(widget.dynamicTriggerPathList, { key: path }) !== undefined; + } + return false; +}; + +export const getWidgetDynamicPropertyPathList = ( + widget: WidgetProps, +): DynamicPath[] => { + if ( + widget && + widget.dynamicPropertyPathList && + Array.isArray(widget.dynamicPropertyPathList) + ) { + return [...widget.dynamicPropertyPathList]; + } + return []; +}; + +export const isPathADynamicProperty = ( + widget: WidgetProps, + path: string, +): boolean => { + if ( + widget && + widget.dynamicPropertyPathList && + Array.isArray(widget.dynamicPropertyPathList) + ) { + return _.find(widget.dynamicPropertyPathList, { key: path }) !== undefined; + } + return false; +}; + +export const unsafeFunctionForEval = [ + "setTimeout", + "fetch", + "setInterval", + "Promise", + "setImmediate", + "XMLHttpRequest", + "importScripts", + "Navigator", +]; + +export const isChildPropertyPath = ( + parentPropertyPath: string, + childPropertyPath: string, +): boolean => + parentPropertyPath === childPropertyPath || + childPropertyPath.startsWith(`${parentPropertyPath}.`) || + childPropertyPath.startsWith(`${parentPropertyPath}[`); + +/** + * Paths set via evaluator on entities + * During evaluation, the evaluator will set various data points + * on the entity objects to describe their state while evaluating. + * This information can be found on the following paths + * These paths are meant to be objects with + * information about the properties in + * a single place + * + * Stored in a flattened object like + * widget.__evaluation__.errors.primaryColumns.customColumn.computedValue = [...] + **/ +export const EVALUATION_PATH = "__evaluation__"; +export const EVAL_ERROR_PATH = `${EVALUATION_PATH}.errors`; +export const EVAL_VALUE_PATH = `${EVALUATION_PATH}.evaluatedValues`; + +const getNestedEvalPath = ( + fullPropertyPath: string, + pathType: string, + fullPath = true, +) => { + const { entityName, propertyPath } = getEntityNameAndPropertyPath( + fullPropertyPath, + ); + const nestedPath = `${pathType}.['${propertyPath}']`; + if (fullPath) { + return `${entityName}.${nestedPath}`; + } + return nestedPath; +}; + +export const getEvalErrorPath = (fullPropertyPath: string, fullPath = true) => { + return getNestedEvalPath(fullPropertyPath, EVAL_ERROR_PATH, fullPath); +}; + +export const getEvalValuePath = (fullPropertyPath: string, fullPath = true) => { + return getNestedEvalPath(fullPropertyPath, EVAL_VALUE_PATH, fullPath); +}; + +export enum PropertyEvaluationErrorType { + VALIDATION = "VALIDATION", + PARSE = "PARSE", + LINT = "LINT", +} + +export type EvaluationError = { + raw: string; + errorType: PropertyEvaluationErrorType; + errorMessage: string; + severity: Severity.WARNING | Severity.ERROR; + errorSegment?: string; +}; + +export interface DataTreeEvaluationProps { + __evaluation__?: { + errors: Record; + evaluatedValues?: Record; + }; +} + +export const PropertyEvalErrorTypeDebugMessage: Record< + PropertyEvaluationErrorType, + (propertyPath: string) => string +> = { + [PropertyEvaluationErrorType.VALIDATION]: (propertyPath: string) => + `The value at ${propertyPath} is invalid`, + [PropertyEvaluationErrorType.PARSE]: () => `Could not parse the binding`, + [PropertyEvaluationErrorType.LINT]: () => `Errors found while evaluating`, +}; diff --git a/app/taro/src/utils/EditorUtils.ts b/app/taro/src/utils/EditorUtils.ts new file mode 100644 index 0000000000..8be1ca62e1 --- /dev/null +++ b/app/taro/src/utils/EditorUtils.ts @@ -0,0 +1,5 @@ +import WidgetBuilderRegistry from "./WidgetRegistry"; + +export const editorInitializer = async () => { + WidgetBuilderRegistry.registerWidgetBuilders(); +}; diff --git a/app/taro/src/utils/TypeHelpers.ts b/app/taro/src/utils/TypeHelpers.ts new file mode 100644 index 0000000000..9b78ad223f --- /dev/null +++ b/app/taro/src/utils/TypeHelpers.ts @@ -0,0 +1,39 @@ +import _ from "lodash"; + +export enum Types { + URL = "URL", + STRING = "STRING", + NUMBER = "NUMBER", + BOOLEAN = "BOOLEAN", + OBJECT = "OBJECT", + ARRAY = "ARRAY", + FUNCTION = "FUNCTION", + UNDEFINED = "UNDEFINED", + NULL = "NULL", + UNKNOWN = "UNKNOWN", +} + +export const getType = (value: unknown) => { + if (_.isString(value)) return Types.STRING; + if (_.isNumber(value)) return Types.NUMBER; + if (_.isBoolean(value)) return Types.BOOLEAN; + if (Array.isArray(value)) return Types.ARRAY; + if (_.isFunction(value)) return Types.FUNCTION; + if (_.isObject(value)) return Types.OBJECT; + if (_.isUndefined(value)) return Types.UNDEFINED; + if (_.isNull(value)) return Types.NULL; + return Types.UNKNOWN; +}; + +export function isURL(str: string) { + const pattern = new RegExp( + "^(https?:\\/\\/)?" + // protocol + "((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|" + // domain name + "((\\d{1,3}\\.){3}\\d{1,3}))" + // OR ip (v4) address + "(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*" + // port and path + "(\\?[;&a-z\\d%_.~+=-]*)?" + // query string + "(\\#[-a-z\\d_]*)?$", + "i", + ); // fragment locator + return !!pattern.test(str); +} diff --git a/app/taro/src/utils/WidgetFactory.tsx b/app/taro/src/utils/WidgetFactory.tsx new file mode 100644 index 0000000000..c76e51d126 --- /dev/null +++ b/app/taro/src/utils/WidgetFactory.tsx @@ -0,0 +1,237 @@ +import { WidgetType, RenderMode } from "constants/WidgetConstants"; +import { + WidgetBuilder, + WidgetProps, + WidgetDataProps, + WidgetState, +} from "widgets/BaseWidget"; +import React from "react"; +import { + PropertyPaneConfig, + PropertyPaneControlConfig, + ValidationConfig, +} from "constants/PropertyControlConstants"; +import { generateReactKey } from "./generators"; +import { ValidationTypes } from "constants/WidgetValidation"; + +type WidgetDerivedPropertyType = any; +export type DerivedPropertiesMap = Record; + +// TODO (abhinav): To enforce the property pane config structure in this function +// Throw an error if the config is not of the desired format. +const addPropertyConfigIds = (config: PropertyPaneConfig[]) => { + return config.map((sectionOrControlConfig: PropertyPaneConfig) => { + sectionOrControlConfig.id = generateReactKey(); + if (sectionOrControlConfig.children) { + sectionOrControlConfig.children = addPropertyConfigIds( + sectionOrControlConfig.children, + ); + } + const config = sectionOrControlConfig as PropertyPaneControlConfig; + if ( + config.panelConfig && + config.panelConfig.children && + Array.isArray(config.panelConfig.children) + ) { + config.panelConfig.children = addPropertyConfigIds( + config.panelConfig.children, + ); + + (sectionOrControlConfig as PropertyPaneControlConfig) = config; + } + return sectionOrControlConfig; + }); +}; + +function validatePropertyPaneConfig(config: PropertyPaneConfig[]) { + return config.map((sectionOrControlConfig: PropertyPaneConfig) => { + if (sectionOrControlConfig.children) { + sectionOrControlConfig.children = sectionOrControlConfig.children.map( + validatePropertyControl, + ); + } + return sectionOrControlConfig; + }); +} + +function validatePropertyControl( + config: PropertyPaneConfig, +): PropertyPaneConfig { + const _config = config as PropertyPaneControlConfig; + if (_config.validation !== undefined) { + _config.validation = validateValidationStructure(_config.validation); + } + if (_config.children) { + _config.children = _config.children.map(validatePropertyControl); + } + return _config; +} + +function validateValidationStructure( + config: ValidationConfig, +): ValidationConfig { + // Todo(abhinav): This only checks for top level params. Throwing nothing here. + if ( + config.type === ValidationTypes.FUNCTION && + config.params && + config.params.fn + ) { + config.params.fnString = config.params.fn.toString(); + if (!config.params.expected) + console.error( + `Error in configuration ${JSON.stringify(config)}: For a ${ + ValidationTypes.FUNCTION + } type validation, expected type and example are mandatory`, + ); + delete config.params.fn; + } + return config; +} +class WidgetFactory { + static widgetMap: Map< + WidgetType, + WidgetBuilder + > = new Map(); + static widgetDerivedPropertiesGetterMap: Map< + WidgetType, + WidgetDerivedPropertyType + > = new Map(); + static derivedPropertiesMap: Map< + WidgetType, + DerivedPropertiesMap + > = new Map(); + static defaultPropertiesMap: Map< + WidgetType, + Record + > = new Map(); + static metaPropertiesMap: Map> = new Map(); + static propertyPaneConfigsMap: Map< + WidgetType, + readonly PropertyPaneConfig[] + > = new Map(); + + static registerWidgetBuilder( + widgetType: WidgetType, + widgetBuilder: WidgetBuilder, + derivedPropertiesMap: DerivedPropertiesMap, + defaultPropertiesMap: Record, + metaPropertiesMap: Record, + propertyPaneConfig?: PropertyPaneConfig[], + ) { + this.widgetMap.set(widgetType, widgetBuilder); + this.derivedPropertiesMap.set(widgetType, derivedPropertiesMap); + this.defaultPropertiesMap.set(widgetType, defaultPropertiesMap); + this.metaPropertiesMap.set(widgetType, metaPropertiesMap); + + if (propertyPaneConfig) { + const validatedPropertyPaneConfig = validatePropertyPaneConfig( + propertyPaneConfig, + ); + + this.propertyPaneConfigsMap.set( + widgetType, + Object.freeze(addPropertyConfigIds(validatedPropertyPaneConfig)), + ); + } + } + + static createWidget( + widgetData: WidgetDataProps, + renderMode: RenderMode, + ): React.ReactNode { + const widgetProps: WidgetProps = { + key: widgetData.widgetId, + isVisible: true, + ...widgetData, + renderMode: renderMode, + }; + const widgetBuilder = this.widgetMap.get(widgetData.type); + if (widgetBuilder) { + // TODO validate props here + const widget = widgetBuilder.buildWidget(widgetProps); + return widget; + } else { + const ex: WidgetCreationException = { + message: + "Widget Builder not registered for widget type" + widgetData.type, + }; + console.error(ex); + return null; + } + } + + static getWidgetTypes(): WidgetType[] { + return Array.from(this.widgetMap.keys()); + } + + static getWidgetDerivedPropertiesMap( + widgetType: WidgetType, + ): DerivedPropertiesMap { + const map = this.derivedPropertiesMap.get(widgetType); + if (!map) { + console.error("Widget type validation is not defined"); + return {}; + } + return map; + } + + static getWidgetDefaultPropertiesMap( + widgetType: WidgetType, + ): Record { + const map = this.defaultPropertiesMap.get(widgetType); + if (!map) { + console.error("Widget default properties not defined", widgetType); + return {}; + } + return map; + } + + static getWidgetMetaPropertiesMap( + widgetType: WidgetType, + ): Record { + const map = this.metaPropertiesMap.get(widgetType); + if (!map) { + console.error("Widget meta properties not defined: ", widgetType); + return {}; + } + return map; + } + + static getWidgetPropertyPaneConfig( + type: WidgetType, + ): readonly PropertyPaneConfig[] { + const map = this.propertyPaneConfigsMap.get(type); + if (!map) { + console.error("Widget property pane configs not defined", type); + return []; + } + return map; + } + + static getWidgetTypeConfigMap(): WidgetTypeConfigMap { + const typeConfigMap: WidgetTypeConfigMap = {}; + WidgetFactory.getWidgetTypes().forEach((type) => { + typeConfigMap[type] = { + defaultProperties: WidgetFactory.getWidgetDefaultPropertiesMap(type), + derivedProperties: WidgetFactory.getWidgetDerivedPropertiesMap(type), + metaProperties: WidgetFactory.getWidgetMetaPropertiesMap(type), + }; + }); + return typeConfigMap; + } +} + +export type WidgetTypeConfigMap = Record< + string, + { + defaultProperties: Record; + metaProperties: Record; + derivedProperties: WidgetDerivedPropertyType; + } +>; + +export interface WidgetCreationException { + message: string; +} + +export default WidgetFactory; diff --git a/app/taro/src/utils/WidgetPropsUtils.tsx b/app/taro/src/utils/WidgetPropsUtils.tsx new file mode 100644 index 0000000000..7d0d4a2a1b --- /dev/null +++ b/app/taro/src/utils/WidgetPropsUtils.tsx @@ -0,0 +1,711 @@ +import { FetchPageResponse } from "api/PageApi"; +import { CANVAS_DEFAULT_HEIGHT_PX } from "constants/AppConstants"; +import { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { WidgetConfigProps } from "reducers/entityReducers/widgetConfigReducer"; +import { + WidgetOperation, + WidgetOperations, + WidgetProps, +} from "widgets/BaseWidget"; +import { + GridDefaults, + LATEST_PAGE_VERSION, + MAIN_CONTAINER_WIDGET_ID, + RenderMode, + WidgetType, + WidgetTypes, +} from "constants/WidgetConstants"; +import { snapToGrid } from "./helpers"; +import { OccupiedSpace } from "constants/editorConstants"; +import defaultTemplate from "templates/default"; +import { generateReactKey } from "./generators"; +import { FlattenedWidgetProps } from "reducers/entityReducers/canvasWidgetsReducer"; +import { omit } from "lodash"; +import { + migrateTablePrimaryColumnsBindings, + tableWidgetPropertyPaneMigrations, + migrateTableWidgetParentRowSpaceProperty, + migrateTableWidgetHeaderVisibilityProperties, + migrateTablePrimaryColumnsComputedValue, +} from "utils/migrations/TableWidget"; +import { migrateIncorrectDynamicBindingPathLists } from "utils/migrations/IncorrectDynamicBindingPathLists"; +import { migrateTextStyleFromTextWidget } from "./migrations/TextWidgetReplaceTextStyle"; +import { nextAvailableRowInContainer } from "entities/Widget/utils"; +import WidgetConfigResponse, { + GRID_DENSITY_MIGRATION_V1, +} from "mockResponses/WidgetConfigResponse"; +import CanvasWidgetsNormalizer from "normalizers/CanvasWidgetsNormalizer"; +import { theme } from "constants/DefaultTheme"; + +export interface XYCoord { + x: number; + y: number; +} +export interface ChartDataPoint { + x: any; + y: any; +} + +export type WidgetOperationParams = { + operation: WidgetOperation; + widgetId: string; + payload: any; +}; + +const { DEFAULT_GRID_ROW_HEIGHT } = GridDefaults; +type Rect = { + top: number; + left: number; + right: number; + bottom: number; +}; + +const defaultDSL = defaultTemplate; + +const updateContainers = (dsl: ContainerWidgetProps) => { + if ( + dsl.type === WidgetTypes.CONTAINER_WIDGET + ) { + if ( + !( + dsl.children && + dsl.children.length > 0 && + (dsl.children[0].type === WidgetTypes.CANVAS_WIDGET) + ) + ) { + const canvas = { + ...dsl, + backgroundColor: "transparent", + type: WidgetTypes.CANVAS_WIDGET, + detachFromLayout: true, + topRow: 0, + leftColumn: 0, + rightColumn: dsl.parentColumnSpace * (dsl.rightColumn - dsl.leftColumn), + bottomRow: dsl.parentRowSpace * (dsl.bottomRow - dsl.topRow), + widgetName: generateReactKey(), + widgetId: generateReactKey(), + parentRowSpace: 1, + parentColumnSpace: 1, + containerStyle: "none", + canExtend: false, + isVisible: true, + }; + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore + delete canvas.dynamicBindings; + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore + delete canvas.dynamicProperties; + if (canvas.children && canvas.children.length > 0) + canvas.children = canvas.children.map(updateContainers); + dsl.children = [{ ...canvas }]; + } + } + return dsl; +}; + +const dynamicPathListMigration = ( + currentDSL: ContainerWidgetProps, +) => { + if (currentDSL.children && currentDSL.children.length) { + currentDSL.children = currentDSL.children.map(dynamicPathListMigration); + } + if (currentDSL.dynamicBindings) { + currentDSL.dynamicBindingPathList = Object.keys( + currentDSL.dynamicBindings, + ).map((path) => ({ key: path })); + delete currentDSL.dynamicBindings; + } + if (currentDSL.dynamicTriggers) { + currentDSL.dynamicTriggerPathList = Object.keys( + currentDSL.dynamicTriggers, + ).map((path) => ({ key: path })); + delete currentDSL.dynamicTriggers; + } + if (currentDSL.dynamicProperties) { + currentDSL.dynamicPropertyPathList = Object.keys( + currentDSL.dynamicProperties, + ).map((path) => ({ key: path })); + delete currentDSL.dynamicProperties; + } + return currentDSL; +}; + +const addVersionNumberMigration = ( + currentDSL: ContainerWidgetProps, +) => { + if (currentDSL.children && currentDSL.children.length) { + currentDSL.children = currentDSL.children.map(addVersionNumberMigration); + } + if (currentDSL.version === undefined) { + currentDSL.version = 1; + } + return currentDSL; +}; + +const canvasNameConflictMigration = ( + currentDSL: ContainerWidgetProps, + props = { counter: 1 }, +): ContainerWidgetProps => { + if ( + currentDSL.type === WidgetTypes.CANVAS_WIDGET && + currentDSL.widgetName.startsWith("Canvas") + ) { + currentDSL.widgetName = `Canvas${props.counter}`; + // Canvases inside tabs have `name` property as well + if (currentDSL.name) { + currentDSL.name = currentDSL.widgetName; + } + props.counter++; + } + currentDSL.children?.forEach((c) => canvasNameConflictMigration(c, props)); + + return currentDSL; +}; + +const renamedCanvasNameConflictMigration = ( + currentDSL: ContainerWidgetProps, + props = { counter: 1 }, +): ContainerWidgetProps => { + // Rename all canvas widgets except for MainContainer + if ( + currentDSL.type === WidgetTypes.CANVAS_WIDGET && + currentDSL.widgetName !== "MainContainer" + ) { + currentDSL.widgetName = `Canvas${props.counter}`; + // Canvases inside tabs have `name` property as well + if (currentDSL.name) { + currentDSL.name = currentDSL.widgetName; + } + props.counter++; + } + currentDSL.children?.forEach((c) => canvasNameConflictMigration(c, props)); + + return currentDSL; +}; + +/** + * changes chartData which we were using as array. now it will be a object + * + * + * @param currentDSL + * @returns + */ +export function migrateChartDataFromArrayToObject( + currentDSL: ContainerWidgetProps, +) { + currentDSL.children = currentDSL.children?.map((children: WidgetProps) => { + if ( + children.type === WidgetTypes.CONTAINER_WIDGET || + children.type === WidgetTypes.CANVAS_WIDGET + ) { + children = migrateChartDataFromArrayToObject(children); + } + + return children; + }); + + return currentDSL; +} + +const pixelToNumber = (pixel: string) => { + if (pixel.includes("px")) { + return parseInt(pixel.split("px").join("")); + } + return 0; +}; + +export const calculateDynamicHeight = ( + canvasWidgets: { + [widgetId: string]: FlattenedWidgetProps; + } = {}, + presentMinimumHeight = CANVAS_DEFAULT_HEIGHT_PX, +) => { + let minimumHeight = presentMinimumHeight; + const nextAvailableRow = nextAvailableRowInContainer( + MAIN_CONTAINER_WIDGET_ID, + canvasWidgets, + ); + const screenHeight = window.innerHeight; + const gridRowHeight = GridDefaults.DEFAULT_GRID_ROW_HEIGHT; + const calculatedCanvasHeight = nextAvailableRow * gridRowHeight; + // DGRH - DEFAULT_GRID_ROW_HEIGHT + // View Mode: Header height + Page Selection Tab = 8 * DGRH (approx) + // Edit Mode: Header height + Canvas control = 8 * DGRH (approx) + // buffer: ~8 grid row height + const buffer = gridRowHeight + 2 * pixelToNumber(theme.smallHeaderHeight); + const calculatedMinHeight = + Math.floor((screenHeight - buffer) / gridRowHeight) * gridRowHeight; + if ( + calculatedCanvasHeight < screenHeight && + calculatedMinHeight !== presentMinimumHeight + ) { + minimumHeight = calculatedMinHeight; + } + return minimumHeight; +}; + +export const migrateInitialValues = ( + currentDSL: ContainerWidgetProps, +) => { + currentDSL.children = currentDSL.children?.map((child: WidgetProps) => { + if (child.children && child.children.length > 0) { + child = migrateInitialValues(child); + } + return child; + }); + return currentDSL; +}; + +// A rudimentary transform function which updates the DSL based on its version. +// A more modular approach needs to be designed. +const transformDSL = (currentDSL: ContainerWidgetProps) => { + if (currentDSL.version === undefined) { + // Since this top level widget is a CANVAS_WIDGET, + // DropTargetComponent needs to know the minimum height the canvas can take + // See DropTargetUtils.ts + currentDSL.minHeight = calculateDynamicHeight(); + + // For the first time the DSL is created, remove one row from the total possible rows + // to adjust for padding and margins. + currentDSL.snapRows = + Math.floor(currentDSL.bottomRow / DEFAULT_GRID_ROW_HEIGHT) - 1; + + // Force the width of the canvas to 1224 px + currentDSL.rightColumn = 1224; + // The canvas is a CANVAS_WIDGET whichdoesn't have a background or borders by default + currentDSL.backgroundColor = "none"; + currentDSL.containerStyle = "none"; + currentDSL.type = WidgetTypes.CANVAS_WIDGET; + currentDSL.detachFromLayout = true; + currentDSL.canExtend = true; + + // Update version to make sure this doesn't run everytime. + currentDSL.version = 1; + } + + if (currentDSL.version === 1) { + if (currentDSL.children && currentDSL.children.length > 0) + currentDSL.children = currentDSL.children.map(updateContainers); + currentDSL.version = 6; + } + if (currentDSL.version === 6) { + currentDSL = dynamicPathListMigration(currentDSL); + currentDSL.version = 7; + } + + if (currentDSL.version === 7) { + currentDSL = canvasNameConflictMigration(currentDSL); + currentDSL.version = 8; + } + + if (currentDSL.version === 8) { + currentDSL = renamedCanvasNameConflictMigration(currentDSL); + currentDSL.version = 9; + } + + if (currentDSL.version === 9) { + currentDSL = tableWidgetPropertyPaneMigrations(currentDSL); + currentDSL.version = 10; + } + + if (currentDSL.version === 10) { + currentDSL = addVersionNumberMigration(currentDSL); + currentDSL.version = 11; + } + + if (currentDSL.version === 11) { + currentDSL = migrateTablePrimaryColumnsBindings(currentDSL); + currentDSL.version = 12; + } + + if (currentDSL.version === 12) { + currentDSL = migrateIncorrectDynamicBindingPathLists(currentDSL); + currentDSL.version = 15; + } + + if (currentDSL.version === 15) { + currentDSL = migrateTextStyleFromTextWidget(currentDSL); + currentDSL.version = 16; + } + + if (currentDSL.version === 16) { + currentDSL = migrateChartDataFromArrayToObject(currentDSL); + currentDSL.version = 18; + } + + if (currentDSL.version === 18) { + currentDSL = migrateInitialValues(currentDSL); + currentDSL.version = 19; + } + + if (currentDSL.version === 19) { + currentDSL.snapColumns = GridDefaults.DEFAULT_GRID_COLUMNS; + currentDSL.snapRows = getCanvasSnapRows( + currentDSL.bottomRow, + currentDSL.detachFromLayout || false, + ); + currentDSL = migrateToNewLayout(currentDSL); + currentDSL.version = 21; + } + + if (currentDSL.version === 21) { + const { + entities: { canvasWidgets }, + } = CanvasWidgetsNormalizer.normalize(currentDSL); + currentDSL = migrateWidgetsWithoutLeftRightColumns( + currentDSL, + canvasWidgets, + ); + currentDSL.version = 22; + } + + if (currentDSL.version === 22) { + currentDSL = migrateTableWidgetParentRowSpaceProperty(currentDSL); + currentDSL.version = 23; + } + + if (currentDSL.version === 23) { + currentDSL.version = 24; + } + + if (currentDSL.version === 24) { + currentDSL = migrateTableWidgetHeaderVisibilityProperties(currentDSL); + currentDSL.version = 28; + } + + if (currentDSL.version === 28) { + currentDSL = migrateTablePrimaryColumnsComputedValue(currentDSL); + currentDSL.version = 29; + } + + if (currentDSL.version === 29) { + currentDSL.version = LATEST_PAGE_VERSION; + } + + return currentDSL; +}; + +const migrateWidgetsWithoutLeftRightColumns = ( + currentDSL: ContainerWidgetProps, + canvasWidgets: any, +) => { + if ( + currentDSL.widgetId !== MAIN_CONTAINER_WIDGET_ID && + !( + currentDSL.hasOwnProperty("leftColumn") && + currentDSL.hasOwnProperty("rightColumn") + ) + ) { + try { + const nextRow = nextAvailableRowInContainer( + currentDSL.parentId || MAIN_CONTAINER_WIDGET_ID, + omit(canvasWidgets, [currentDSL.widgetId]), + ); + canvasWidgets[currentDSL.widgetId].repositioned = true; + const leftColumn = 0; + const rightColumn = WidgetConfigResponse.config[currentDSL.type].rows; + const bottomRow = nextRow + (currentDSL.bottomRow - currentDSL.topRow); + const topRow = nextRow; + currentDSL = { + ...currentDSL, + topRow, + bottomRow, + rightColumn, + leftColumn, + }; + } catch (error) { + // Sentry.captureException({ + // message: "Migrating position of widget on data loss failed", + // oldData: currentDSL, + // }); + } + } + if (currentDSL.children && currentDSL.children.length) { + currentDSL.children = currentDSL.children.map((dsl) => + migrateWidgetsWithoutLeftRightColumns(dsl, canvasWidgets), + ); + } + return currentDSL; +}; + +export const migrateToNewLayout = (dsl: ContainerWidgetProps) => { + const scaleWidget = (widgetProps: WidgetProps) => { + widgetProps.bottomRow *= GRID_DENSITY_MIGRATION_V1; + widgetProps.topRow *= GRID_DENSITY_MIGRATION_V1; + widgetProps.leftColumn *= GRID_DENSITY_MIGRATION_V1; + widgetProps.rightColumn *= GRID_DENSITY_MIGRATION_V1; + if (widgetProps.children && widgetProps.children.length) { + widgetProps.children.forEach((eachWidgetProp: WidgetProps) => { + scaleWidget(eachWidgetProp); + }); + } + }; + scaleWidget(dsl); + return dsl; +}; + +export const checkIfMigrationIsNeeded = ( + fetchPageResponse?: FetchPageResponse, +) => { + const currentDSL = fetchPageResponse?.data.layouts[0].dsl || defaultDSL; + return currentDSL.version !== LATEST_PAGE_VERSION; +}; + +export const extractCurrentDSL = ( + fetchPageResponse?: FetchPageResponse, +): ContainerWidgetProps => { + const currentDSL = fetchPageResponse?.data.layouts[0].dsl || defaultDSL; + return transformDSL(currentDSL); +}; + +export const getDropZoneOffsets = ( + colWidth: number, + rowHeight: number, + dragOffset: XYCoord, + parentOffset: XYCoord, +) => { + // Calculate actual drop position by snapping based on x, y and grid cell size + return snapToGrid( + colWidth, + rowHeight, + dragOffset.x - parentOffset.x, + dragOffset.y - parentOffset.y, + ); +}; + +export const areIntersecting = (r1: Rect, r2: Rect) => { + return !( + r2.left >= r1.right || + r2.right <= r1.left || + r2.top >= r1.bottom || + r2.bottom <= r1.top + ); +}; + +export const isDropZoneOccupied = ( + offset: Rect, + widgetId: string, + occupied?: OccupiedSpace[], +) => { + if (occupied) { + occupied = occupied.filter((widgetDetails) => { + return ( + widgetDetails.id !== widgetId && widgetDetails.parentId !== widgetId + ); + }); + for (let i = 0; i < occupied.length; i++) { + if (areIntersecting(occupied[i], offset)) { + return true; + } + } + return false; + } + return false; +}; + +export const isWidgetOverflowingParentBounds = ( + parentRowCols: { rows?: number; cols?: number }, + offset: Rect, +): boolean => { + return ( + offset.right < 0 || + offset.top < 0 || + (parentRowCols.cols || GridDefaults.DEFAULT_GRID_COLUMNS) < offset.right || + (parentRowCols.rows || 0) < offset.bottom + ); +}; + +export const noCollision = ( + clientOffset: XYCoord, + colWidth: number, + rowHeight: number, + widget: WidgetProps & Partial, + dropTargetOffset: XYCoord, + occupiedSpaces?: OccupiedSpace[], + rows?: number, + cols?: number, +): boolean => { + if (clientOffset && dropTargetOffset && widget) { + if (widget.detachFromLayout) { + return true; + } + const [left, top] = getDropZoneOffsets( + colWidth, + rowHeight, + clientOffset as XYCoord, + dropTargetOffset, + ); + if (left < 0 || top < 0) { + return false; + } + const widgetWidth = widget.columns + ? widget.columns + : widget.rightColumn - widget.leftColumn; + const widgetHeight = widget.rows + ? widget.rows + : widget.bottomRow - widget.topRow; + const currentOffset = { + left, + right: left + widgetWidth, + top, + bottom: top + widgetHeight, + }; + return ( + !isDropZoneOccupied(currentOffset, widget.widgetId, occupiedSpaces) && + !isWidgetOverflowingParentBounds({ rows, cols }, currentOffset) + ); + } + return false; +}; + +export const currentDropRow = ( + dropTargetRowSpace: number, + dropTargetVerticalOffset: number, + draggableItemVerticalOffset: number, + widget: WidgetProps & Partial, +) => { + const widgetHeight = widget.rows + ? widget.rows + : widget.bottomRow - widget.topRow; + const top = Math.round( + (draggableItemVerticalOffset - dropTargetVerticalOffset) / + dropTargetRowSpace, + ); + const currentBottomOffset = top + widgetHeight; + return currentBottomOffset; +}; + +export const widgetOperationParams = ( + widget: WidgetProps & Partial, + widgetOffset: XYCoord, + parentOffset: XYCoord, + parentColumnSpace: number, + parentRowSpace: number, + parentWidgetId: string, // parentWidget +): WidgetOperationParams => { + const [leftColumn, topRow] = getDropZoneOffsets( + parentColumnSpace, + parentRowSpace, + widgetOffset, + parentOffset, + ); + // If this is an existing widget, we'll have the widgetId + // Therefore, this is a move operation on drop of the widget + if (widget.widgetName) { + return { + operation: WidgetOperations.MOVE, + widgetId: widget.widgetId, + payload: { + leftColumn, + topRow, + parentId: widget.parentId, + newParentId: parentWidgetId, + }, + }; + // If this is not an existing widget, we'll not have the widgetId + // Therefore, this is an operation to add child to this container + } + const widgetDimensions = { + columns: widget.columns, + rows: widget.rows, + }; + + return { + operation: WidgetOperations.ADD_CHILD, + widgetId: parentWidgetId, + payload: { + type: widget.type, + leftColumn, + topRow, + ...widgetDimensions, + parentRowSpace, + parentColumnSpace, + newWidgetId: widget.widgetId, + }, + }; +}; + +export const updateWidgetPosition = ( + widget: WidgetProps, + leftColumn: number, + topRow: number, +) => { + const newPositions = { + leftColumn, + topRow, + rightColumn: leftColumn + (widget.rightColumn - widget.leftColumn), + bottomRow: topRow + (widget.bottomRow - widget.topRow), + }; + + return { + ...newPositions, + }; +}; + +export const getCanvasSnapRows = ( + bottomRow: number, + canExtend: boolean, +): number => { + const totalRows = Math.floor( + bottomRow / GridDefaults.DEFAULT_GRID_ROW_HEIGHT, + ); + + // Canvas Widgets do not need to accomodate for widget and container padding. + // Only when they're extensible + if (canExtend) { + return totalRows; + } + // When Canvas widgets are not extensible + return totalRows - 1; +}; + +export const getSnapColumns = (): number => { + return GridDefaults.DEFAULT_GRID_COLUMNS; +}; + +export const generateWidgetProps = ( + parent: FlattenedWidgetProps, + type: WidgetType, + leftColumn: number, + topRow: number, + parentRowSpace: number, + parentColumnSpace: number, + widgetName: string, + widgetConfig: { + widgetId: string; + renderMode: RenderMode; + } & Partial, + version: number, +): ContainerWidgetProps => { + if (parent) { + const sizes = { + leftColumn, + rightColumn: leftColumn + widgetConfig.columns, + topRow, + bottomRow: topRow + widgetConfig.rows, + }; + + const others = {}; + const props: ContainerWidgetProps = { + isVisible: true, + ...widgetConfig, + type, + widgetName, + isLoading: false, + parentColumnSpace, + parentRowSpace, + ...sizes, + ...others, + parentId: parent.widgetId, + version, + }; + delete props.rows; + delete props.columns; + return props; + } else { + if (parent) { + throw Error("Failed to create widget: Parent's size cannot be calculate"); + } else throw Error("Failed to create widget: Parent was not provided "); + } +}; diff --git a/app/taro/src/utils/WidgetRegistry.tsx b/app/taro/src/utils/WidgetRegistry.tsx new file mode 100644 index 0000000000..c7f863becd --- /dev/null +++ b/app/taro/src/utils/WidgetRegistry.tsx @@ -0,0 +1,383 @@ +import React from "react"; +import BaseWidget, { WidgetProps } from "widgets/BaseWidget"; +import { WidgetTypes } from "constants/WidgetConstants"; +import CanvasWidget, { ProfiledCanvasWidget } from "widgets/CanvasWidget"; +import ContainerWidget, { + ContainerWidgetProps, + ProfiledContainerWidget, +} from "widgets/ContainerWidget"; +import SkeletonWidget, { + ProfiledSkeletonWidget, + SkeletonWidgetProps, +} from "../widgets/SkeletonWidget"; +import WidgetFactory from "./WidgetFactory"; +import PickerWidget, { + PickerWidgetProps, + ProfiledPickerWidget, +} from "widgets/taro/PickerWidget"; +import SwiperWidget, { + SwiperWidgetProps, + ProfiledSwiperWidget, +} from "widgets/taro/SwiperWidget"; +import GridWidget, { + GridWidgetProps, + ProfiledGridWidget, +} from "widgets/taro/GridWidget"; +import MTextWidget, { + MTextWidgetProps, + MProfiledTextWidget, +} from "widgets/taro/TextWidget"; +import MListWidget, { + MListWidgetProps, + MProfiledListWidget, +} from "widgets/taro/ListWidget"; +import MPopupWidget, { + MPopupWidgetProps, + MProfiledPopupWidget, +} from "widgets/taro/PopupWidget"; +import MImageWidget, { + MImageWidgetProps, + MProfiledImageWidget, +} from "widgets/taro/ImageWidget"; +import MButtonWidget, { + MButtonWidgetProps, + MProfiledButtonWidget, +} from "widgets/taro/ButtonWidget"; +import MCellWidget, { + MCellWidgetProps, + MProfiledCellWidget, +} from "widgets/taro/CellWidget"; +import MHtmlWidget, { + MHtmlWidgetProps, + MProfiledHtmlWidget, +} from "widgets/taro/HtmlWidget"; +import MSkuWidget, { + MSkuWidgetProps, + MProfiledSkuWidget, +} from "widgets/taro/SkuWidget"; +import MKVWidget, { + MKVWidgetProps, + MProfiledKVWidget, +} from "widgets/taro/KVWidget"; +import MTabsWidget, { + MTabsWidgetProps, + MProfiledTabsWidget, +} from "widgets/taro/TabsWidget"; +import MBottomBarWidget, { + MBottomBarWidgetProps, + MProfiledBottomBarWidget, +} from "widgets/taro/BottomBarWidget"; +import MActionBarWidget, { + MActionBarWidgetProps, + MProfiledActionBarWidget, +} from "widgets/taro/ActionBarWidget"; +import MSearchWidget, { + MSearchWidgetProps, + MProfiledSearchWidget, +} from "widgets/taro/SearchWidget"; +import MLoadingWidget, { + MLoadingWidgetProps, + MProfiledLoadingWidget, +} from "widgets/taro/LoadingWidget"; +import MCheckboxWidget, { + MCheckboxWidgetProps, + MProfiledCheckboxWidget, +} from "widgets/taro/CheckboxWidget"; +import MFormWidget, { + MFormWidgetProps, + MProfiledFormWidget, +} from "widgets/taro/FormWidget"; + +export default class WidgetBuilderRegistry { + static registerWidgetBuilders() { + WidgetFactory.registerWidgetBuilder( + WidgetTypes.CANVAS_WIDGET, + { + buildWidget( + widgetData: ContainerWidgetProps, + ): JSX.Element { + return ; + }, + }, + CanvasWidget.getDerivedPropertiesMap(), + CanvasWidget.getDefaultPropertiesMap(), + CanvasWidget.getMetaPropertiesMap(), + CanvasWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + "CONTAINER_WIDGET", + { + buildWidget( + widgetData: ContainerWidgetProps, + ): JSX.Element { + return ; + }, + }, + ContainerWidget.getDerivedPropertiesMap(), + ContainerWidget.getDefaultPropertiesMap(), + ContainerWidget.getMetaPropertiesMap(), + ContainerWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.SKELETON_WIDGET, + { + buildWidget(widgetProps: SkeletonWidgetProps): JSX.Element { + return ; + }, + }, + SkeletonWidget.getDerivedPropertiesMap(), + SkeletonWidget.getDefaultPropertiesMap(), + SkeletonWidget.getMetaPropertiesMap(), + SkeletonWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_PICKER_WIDGET, + { + buildWidget(widgetData: PickerWidgetProps): JSX.Element { + return ; + }, + }, + PickerWidget.getDerivedPropertiesMap(), + PickerWidget.getDefaultPropertiesMap(), + PickerWidget.getMetaPropertiesMap(), + PickerWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_SWIPER_WIDGET, + { + buildWidget(widgetData: SwiperWidgetProps): JSX.Element { + return ; + }, + }, + SwiperWidget.getDerivedPropertiesMap(), + SwiperWidget.getDefaultPropertiesMap(), + SwiperWidget.getMetaPropertiesMap(), + SwiperWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_GRID_WIDGET, + { + buildWidget(widgetData: GridWidgetProps): JSX.Element { + return ; + }, + }, + GridWidget.getDerivedPropertiesMap(), + GridWidget.getDefaultPropertiesMap(), + GridWidget.getMetaPropertiesMap(), + GridWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_TEXT_WIDGET, + { + buildWidget(widgetData: MTextWidgetProps): JSX.Element { + return ; + }, + }, + MTextWidget.getDerivedPropertiesMap(), + MTextWidget.getDefaultPropertiesMap(), + MTextWidget.getMetaPropertiesMap(), + MTextWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_LIST_WIDGET, + { + buildWidget(widgetData: MListWidgetProps): JSX.Element { + return ; + }, + }, + MListWidget.getDerivedPropertiesMap(), + MListWidget.getDefaultPropertiesMap(), + MListWidget.getMetaPropertiesMap(), + MListWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_POPUP_WIDGET, + { + buildWidget(widgetData: MPopupWidgetProps): JSX.Element { + return ; + }, + }, + MPopupWidget.getDerivedPropertiesMap(), + MPopupWidget.getDefaultPropertiesMap(), + MPopupWidget.getMetaPropertiesMap(), + MPopupWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_IMAGE_WIDGET, + { + buildWidget(widgetData: MImageWidgetProps): JSX.Element { + return ; + }, + }, + MImageWidget.getDerivedPropertiesMap(), + MImageWidget.getDefaultPropertiesMap(), + MImageWidget.getMetaPropertiesMap(), + MImageWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_BUTTON_WIDGET, + { + buildWidget(widgetData: MButtonWidgetProps): JSX.Element { + return ; + }, + }, + MButtonWidget.getDerivedPropertiesMap(), + MButtonWidget.getDefaultPropertiesMap(), + MButtonWidget.getMetaPropertiesMap(), + MButtonWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_CELL_WIDGET, + { + buildWidget(widgetData: MCellWidgetProps): JSX.Element { + return ; + }, + }, + MCellWidget.getDerivedPropertiesMap(), + MCellWidget.getDefaultPropertiesMap(), + MCellWidget.getMetaPropertiesMap(), + MCellWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_HTML_WIDGET, + { + buildWidget(widgetData: MHtmlWidgetProps): JSX.Element { + return ; + }, + }, + MHtmlWidget.getDerivedPropertiesMap(), + MHtmlWidget.getDefaultPropertiesMap(), + MHtmlWidget.getMetaPropertiesMap(), + MHtmlWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_SKU_WIDGET, + { + buildWidget(widgetData: MSkuWidgetProps): JSX.Element { + return ; + }, + }, + MSkuWidget.getDerivedPropertiesMap(), + MSkuWidget.getDefaultPropertiesMap(), + MSkuWidget.getMetaPropertiesMap(), + MSkuWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_KV_WIDGET, + { + buildWidget(widgetData: MKVWidgetProps): JSX.Element { + return ; + }, + }, + MKVWidget.getDerivedPropertiesMap(), + MKVWidget.getDefaultPropertiesMap(), + MKVWidget.getMetaPropertiesMap(), + MKVWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_TABS_WIDGET, + { + buildWidget(widgetData: MTabsWidgetProps): JSX.Element { + return ; + }, + }, + MTabsWidget.getDerivedPropertiesMap(), + MTabsWidget.getDefaultPropertiesMap(), + MTabsWidget.getMetaPropertiesMap(), + MTabsWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_BOTTOM_BAR_WIDGET, + { + buildWidget(widgetData: MBottomBarWidgetProps): JSX.Element { + return ; + }, + }, + MBottomBarWidget.getDerivedPropertiesMap(), + MBottomBarWidget.getDefaultPropertiesMap(), + MBottomBarWidget.getMetaPropertiesMap(), + MBottomBarWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_ACTION_BAR_WIDGET, + { + buildWidget(widgetData: MActionBarWidgetProps): JSX.Element { + return ; + }, + }, + MActionBarWidget.getDerivedPropertiesMap(), + MActionBarWidget.getDefaultPropertiesMap(), + MActionBarWidget.getMetaPropertiesMap(), + MActionBarWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_SEARCH_WIDGET, + { + buildWidget(widgetData: MSearchWidgetProps): JSX.Element { + return ; + }, + }, + MSearchWidget.getDerivedPropertiesMap(), + MSearchWidget.getDefaultPropertiesMap(), + MSearchWidget.getMetaPropertiesMap(), + MSearchWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_LOADING_WIDGET, + { + buildWidget(widgetData: MLoadingWidgetProps): JSX.Element { + return ; + }, + }, + MLoadingWidget.getDerivedPropertiesMap(), + MLoadingWidget.getDefaultPropertiesMap(), + MLoadingWidget.getMetaPropertiesMap(), + MLoadingWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_CHECKBOX_WIDGET, + { + buildWidget(widgetData: MCheckboxWidgetProps): JSX.Element { + return ; + }, + }, + MCheckboxWidget.getDerivedPropertiesMap(), + MCheckboxWidget.getDefaultPropertiesMap(), + MCheckboxWidget.getMetaPropertiesMap(), + MCheckboxWidget.getPropertyPaneConfig(), + ); + + WidgetFactory.registerWidgetBuilder( + WidgetTypes.TARO_FORM_WIDGET, + { + buildWidget(widgetData: MFormWidgetProps): JSX.Element { + return ; + }, + }, + MFormWidget.getDerivedPropertiesMap(), + MFormWidget.getDefaultPropertiesMap(), + MFormWidget.getMetaPropertiesMap(), + MFormWidget.getPropertyPaneConfig(), + ); + } +} diff --git a/app/taro/src/utils/WorkerUtil.ts b/app/taro/src/utils/WorkerUtil.ts new file mode 100644 index 0000000000..b5db71a773 --- /dev/null +++ b/app/taro/src/utils/WorkerUtil.ts @@ -0,0 +1,176 @@ +import { cancelled, delay, put, take } from "redux-saga/effects"; +import { channel, Channel, buffers } from "redux-saga"; +import _ from "lodash"; +import log from "loglevel"; +import Taro from "@tarojs/taro"; + +// polyfill +const performance = Date; + +/** + * Wrap a webworker to provide a synchronous request-response semantic. + * + * Usage on main thread: + * w = GracefulWorkerService(Worker); + * yield w.start(); // Start the worker + * const workerResponse = yield w.request("my_action", { hello: "world" }); // Send a request, wait for response + * + * Worker will receive: + * { + * method: "my_action", + * requestId: "", + * requestData: { hello: "world" }, + * } + * + * Worker is expected to respond with an object with exactly the `requestId`, `timeTaken` and `responseData` keys: + * { + * requestId: "", + * responseData: 42, + * timeTaken: 23.33, + * } + * All other keys will be ignored. + * We make no assumptions about data type of `requestData` or `responseData`. + * + * Note: The worker will hold ALL requests, even in case of restarts. + * If we do not want that behaviour, we should create a new GracefulWorkerService. + */ +// TODO: Add a compatible listener layer on the worker to complete the framework. +// TODO: Extract the worker wrapper into a library to be useful to anyone with WebWorkers + redux-saga. +// TODO: Add support for timeouts on requests and shutdown. +// TODO: Add a readiness + liveness probes. +export class GracefulWorkerService { + // We keep track of all in-flight requests with these channels. + private readonly _channels: Map>; + // The actual WebWorker + private _evaluationWorker: Taro.Worker | undefined; + + // Channels in redux-saga are NOT like signals. + // They operate in `pulse` mode of a signal. But `readiness` is more like a continuous signal. + // This variable provides the equivalent of the `hold` state signal. + // If isReady is false, wait on `this._readyChan` to get the pulse signal. + private _isReady: boolean; + // Channel to signal all waiters that we're ready. Always use it with `this._isReady`. + private readonly _readyChan: Channel; + + constructor() { + this.shutdown = this.shutdown.bind(this); + this.start = this.start.bind(this); + this.request = this.request.bind(this); + this._broker = this._broker.bind(this); + + // Do not buffer messages on this channel + this._readyChan = channel(buffers.none()); + this._isReady = false; + this._channels = new Map>(); + } + + /** + * Start a new worker and registers our broker. + * Note: If the worker is already running, this is a no-op + */ + *start() { + if (this._isReady || this._evaluationWorker) return; + this._evaluationWorker = Taro.createWorker("worker/worker.js"); + this._evaluationWorker.onMessage(this._broker); + // Inform all pending requests that we're good to go! + this._isReady = true; + yield put(this._readyChan, true); + } + + /** + * Gracefully shutdown the worker. + * Note: If the worker is already stopped / shutting down, this is a no-op + */ + *shutdown() { + if (!this._isReady) return; + // stop accepting new requests + this._isReady = false; + // wait for current responses to drain, check every 10 milliseconds + while (this._channels.size > 0) { + yield delay(10); + } + // close the worker + if (!this._evaluationWorker) return; + this._evaluationWorker.terminate(); + this._evaluationWorker = undefined; + } + + /** + * Check if the worker is ready, optionally block on it. + */ + *ready(block = false) { + if (this._isReady && this._evaluationWorker) return true; + if (block) { + yield take(this._readyChan); + return true; + } + return false; + } + + /** + * Send a request to the worker for processing. + * If the worker isn't ready, we wait for it to become ready. + * + * @param method identifier for a rpc method + * @param requestData data that we want to send over to the worker + * + * @returns response from the worker + */ + *request(method: string, requestData = {}): any { + yield this.ready(true); + // Impossible case, but helps avoid `?` later in code and makes it clearer. + if (!this._evaluationWorker) return; + + /** + * We create a unique channel to wait for a response of this specific request. + */ + const requestId = `${method}__${_.uniqueId()}`; + const ch = channel(); + this._channels.set(requestId, ch); + const mainThreadStartTime = performance.now(); + let timeTaken; + + try { + this._evaluationWorker.postMessage({ + method, + requestData, + requestId, + }); + // The `this._broker` method is listening to events and will pass response to us over this channel. + const response = yield take(ch); + timeTaken = response.timeTaken; + const { responseData } = response; + return responseData; + } finally { + // Log perf of main thread and worker + const mainThreadEndTime = performance.now(); + const timeTakenOnMainThread = mainThreadEndTime - mainThreadStartTime; + if (yield cancelled()) { + log.debug( + `Main ${method} cancelled in ${timeTakenOnMainThread.toFixed(2)}ms`, + ); + } else { + log.debug(`Main ${method} took ${timeTakenOnMainThread.toFixed(2)}ms`); + } + + if (timeTaken) { + const transferTime = timeTakenOnMainThread - timeTaken; + log.debug(`Worker ${method} took ${timeTaken}ms`); + log.debug(`Transfer ${method} took ${transferTime.toFixed(2)}ms`); + } + // Cleanup + yield ch.close(); + this._channels.delete(requestId); + } + } + + private _broker(result: any) { + const { requestId, responseData, timeTaken } = result; + const ch = this._channels.get(requestId); + // Channel could have been deleted if the request gets cancelled before the WebWorker can respond. + // In that case, we want to drop the request. + if (ch) { + ch.put({ responseData, timeTaken }); + } + } +} diff --git a/app/taro/src/utils/autocomplete/EntityDefinitions.ts b/app/taro/src/utils/autocomplete/EntityDefinitions.ts new file mode 100644 index 0000000000..3056300f04 --- /dev/null +++ b/app/taro/src/utils/autocomplete/EntityDefinitions.ts @@ -0,0 +1,67 @@ +import _ from "lodash"; + +export const GLOBAL_DEFS = { + dropdownOption: { + label: "string", + value: "string", + }, + tabs: { + id: "string", + label: "string", + }, + chartDataPoint: { + x: "string", + y: "string", + }, + chartData: { + seriesName: "string", + data: "[chartDataPoint]", + }, + latLong: { + lat: "number", + long: "number", + }, + mapMarker: { + lat: "number", + long: "number", + title: "string", + description: "string", + }, + file: { + data: "string", + name: "text", + type: "file", + }, +}; + +export const GLOBAL_FUNCTIONS = { + "!name": "DATA_TREE.APPSMITH.FUNCTIONS", + navigateTo: { + "!doc": "Action to navigate the user to another page or url", + "!type": "fn(pageNameOrUrl: string, params: {}, target?: string) -> void", + }, + showAlert: { + "!doc": "Show a temporary notification style message to the user", + "!type": "fn(message: string, style: string) -> void", + }, + showModal: { + "!doc": "Open a modal", + "!type": "fn(modalName: string) -> void", + }, + closeModal: { + "!doc": "Close a modal", + "!type": "fn(modalName: string) -> void", + }, + storeValue: { + "!doc": "Store key value data locally", + "!type": "fn(key: string, value: any) -> void", + }, + copyToClipboard: { + "!doc": "Copy text to clipboard", + "!type": "fn(data: string, options: object) -> void", + }, + resetWidget: { + "!doc": "Reset widget values", + "!type": "fn(widgetName: string, resetChildren: boolean) -> void", + }, +}; diff --git a/app/taro/src/utils/canvasStructureHelpers.ts b/app/taro/src/utils/canvasStructureHelpers.ts new file mode 100644 index 0000000000..aa00748fbb --- /dev/null +++ b/app/taro/src/utils/canvasStructureHelpers.ts @@ -0,0 +1,44 @@ +import { WidgetTypes } from "constants/WidgetConstants"; +import { + CanvasStructure, + DSL, +} from "reducers/uiReducers/pageCanvasStructureReducer"; + +export const compareAndGenerateImmutableCanvasStructure = ( + original: CanvasStructure, + current: DSL, +) => { + const newStructure = getCanvasStructureFromDSL(current); + if (JSON.stringify(newStructure) === JSON.stringify(original)) { + return original; + } + return newStructure; +}; + +const getCanvasStructureFromDSL = (dsl: DSL): CanvasStructure => { + let children = dsl.children; + let structureChildren: CanvasStructure[] | undefined = undefined; + if (dsl.type === WidgetTypes.TABS_WIDGET) { + if (children && children.length > 0) { + structureChildren = children.map((childTab) => ({ + widgetName: childTab.tabName, + widgetId: childTab.widgetId, + type: WidgetTypes.TABS_WIDGET, + children: childTab.children, + })); + } + } else if (children && children.length === 1) { + if (children[0].type === WidgetTypes.CANVAS_WIDGET) { + children = children[0].children; + } + } + + return { + widgetId: dsl.widgetId, + widgetName: dsl.widgetName, + type: dsl.type, + children: + structureChildren || + children?.filter(Boolean).map(getCanvasStructureFromDSL), + }; +}; diff --git a/app/taro/src/utils/generators.tsx b/app/taro/src/utils/generators.tsx new file mode 100644 index 0000000000..c83b7298ca --- /dev/null +++ b/app/taro/src/utils/generators.tsx @@ -0,0 +1,33 @@ +import { customAlphabet } from 'nanoid/non-secure'; + +const ALPHANUMERIC = "1234567890abcdefghijklmnopqrstuvwxyz"; +// const ALPHABET = "abcdefghijklmnopqrstuvwxyz"; +const generate = customAlphabet(ALPHANUMERIC, 10); + +export const generateReactKey = ({ + prefix = "", +}: { prefix?: string } = {}): string => { + return prefix + generate(); +}; + +// Before you change how this works +// This className is used for the following: +// 1. Resize bounds +// 2. Property pane reference for positioning +// 3. Table widget filter pan reference for positioning +export const generateClassName = (seed?: string) => { + return `appsmith_widget_${seed}`; +}; + +export const getCanvasClassName = () => "canvas"; + +export const getNearestParentCanvas = (el: Element | null) => { + const canvasQuerySelector = `.${getCanvasClassName()}`; + if (el) return el.closest(canvasQuerySelector); + return null; +}; + +export default { + generateReactKey, + generateClassName, +}; diff --git a/app/taro/src/utils/helpers.tsx b/app/taro/src/utils/helpers.tsx new file mode 100644 index 0000000000..fddae7d421 --- /dev/null +++ b/app/taro/src/utils/helpers.tsx @@ -0,0 +1,291 @@ +import { GridDefaults } from "constants/WidgetConstants"; +import { + DATA_TREE_KEYWORDS, + JAVASCRIPT_KEYWORDS, +} from "constants/WidgetValidation"; +import { GLOBAL_FUNCTIONS } from "./autocomplete/EntityDefinitions"; +import { set } from "lodash"; + +export const snapToGrid = ( + columnWidth: number, + rowHeight: number, + x: number, + y: number, +) => { + const snappedX = Math.round(x / columnWidth); + const snappedY = Math.round(y / rowHeight); + return [snappedX, snappedY]; +}; + +export const formatBytes = (bytes: string | number) => { + if (!bytes) return; + const value = typeof bytes === "string" ? parseInt(bytes) : bytes; + const sizes = ["Bytes", "KB", "MB", "GB", "TB"]; + if (value === 0) return "0 bytes"; + const i = parseInt(String(Math.floor(Math.log(value) / Math.log(1024)))); + if (i === 0) return bytes + " " + sizes[i]; + return (value / Math.pow(1024, i)).toFixed(1) + " " + sizes[i]; +}; + +export const getAbsolutePixels = (size?: string | null) => { + if (!size) return 0; + const _dex = size.indexOf("px"); + if (_dex === -1) return 0; + return parseInt(size.slice(0, _dex), 10); +}; + +export const Directions: { [id: string]: string } = { + UP: "up", + DOWN: "down", + LEFT: "left", + RIGHT: "right", + RIGHT_BOTTOM: "RIGHT_BOTTOM", +}; + +export type Direction = typeof Directions[keyof typeof Directions]; +const SCROLL_THESHOLD = 10; + +export const getScrollByPixels = function( + elem: Element, + scrollParent: Element, +): number { + const bounding = elem.getBoundingClientRect(); + const scrollParentBounds = scrollParent.getBoundingClientRect(); + const scrollAmount = + GridDefaults.CANVAS_EXTENSION_OFFSET * GridDefaults.DEFAULT_GRID_ROW_HEIGHT; + + if ( + bounding.top > 0 && + bounding.top - scrollParentBounds.top < SCROLL_THESHOLD + ) + return -scrollAmount; + if (scrollParentBounds.bottom - bounding.bottom < SCROLL_THESHOLD) + return scrollAmount; + return 0; +}; + +export const scrollElementIntoParentCanvasView = ( + el: Element | null, + parent: Element | null, +) => { + if (el) { + const scrollParent = parent; + if (scrollParent) { + const scrollBy: number = getScrollByPixels(el, scrollParent); + if (scrollBy < 0 && scrollParent.scrollTop > 0) { + scrollParent.scrollBy({ top: scrollBy, behavior: "smooth" }); + } + if (scrollBy > 0) { + scrollParent.scrollBy({ top: scrollBy, behavior: "smooth" }); + } + } + } +}; + +export const removeSpecialChars = (value: string, limit?: number) => { + const separatorRegex = /\W+/; + return value + .split(separatorRegex) + .join("_") + .slice(0, limit || 30); +}; + +export const flashElement = (el: HTMLElement) => { + el.style.backgroundColor = "#FFCB33"; + setTimeout(() => { + el.style.backgroundColor = "transparent"; + }, 1000); +}; + +export const flashElementById = (id: string) => { + const el = document.getElementById(id); + el?.scrollIntoView({ + behavior: "smooth", + block: "center", + inline: "center", + }); + + if (el) flashElement(el); +}; + +export const resolveAsSpaceChar = (value: string, limit?: number) => { + // ensures that all special characters are disallowed + // while allowing all utf-8 characters + const removeSpecialCharsRegex = /`|\~|\!|\@|\#|\$|\%|\^|\&|\*|\(|\)|\+|\=|\[|\{|\]|\}|\||\\|\'|\<|\,|\.|\>|\?|\/|\""|\;|\:|\s/; + const duplicateSpaceRegex = /\s+/; + return value + .split(removeSpecialCharsRegex) + .join(" ") + .split(duplicateSpaceRegex) + .join(" ") + .slice(0, limit || 30); +}; + +export const isMac = () => { + const platform = + typeof navigator !== "undefined" ? navigator.platform : undefined; + return !platform ? false : /Mac|iPod|iPhone|iPad/.test(platform); +}; + +/** + * Removes the trailing slashes from the path + * @param path + * @example + * ```js + * let trimmedUrl = trimTrailingSlash('/url/') + * console.log(trimmedUrl) //will output /url + * ``` + * @example + * ```js + * let trimmedUrl = trimTrailingSlash('/yet-another-url//') + * console.log(trimmedUrl) // will output /yet-another-url + * ``` + */ +export const trimTrailingSlash = (path: string) => { + const trailingUrlRegex = /\/+$/; + return path.replace(trailingUrlRegex, ""); +}; + +/** + * checks if ellipsis is active + * this function is meant for checking the existence of ellipsis by CSS. + * Since ellipsis by CSS are not part of DOM, we are checking with scroll width\height and offsetidth\height. + * ScrollWidth\ScrollHeight is always greater than the offsetWidth\OffsetHeight when ellipsis made by CSS is active. + * + * @param element + */ +export const isEllipsisActive = (element: HTMLElement | null) => { + return ( + element && + (element.offsetWidth < element.scrollWidth || + element.offsetHeight < element.scrollHeight) + ); +}; + +/** + * converts array to sentences + * for e.g - ['Pawan', 'Abhinav', 'Hetu'] --> 'Pawan, Abhinav and Hetu' + * + * @param arr string[] + */ +export const convertArrayToSentence = (arr: string[]) => { + return arr.join(", ").replace(/,\s([^,]+)$/, " and $1"); +}; + +/** + * checks if the name is conflicting with + * 1. API names, + * 2. Queries name + * 3. Javascript reserved names + * 4. Few internal function names that are in the evaluation tree + * + * return if false name conflicts with anything from the above list + * + * @param name + * @param invalidNames + */ +export const isNameValid = ( + name: string, + invalidNames: Record, +) => { + return !( + name in JAVASCRIPT_KEYWORDS || + name in DATA_TREE_KEYWORDS || + name in GLOBAL_FUNCTIONS || + name in invalidNames + ); +}; + +/* + * Filter out empty items from an array + * for e.g - ['Pawan', undefined, 'Hetu'] --> ['Pawan', 'Hetu'] + * + * @param array any[] + */ +export const removeFalsyEntries = (arr: any[]): any[] => { + return arr.filter(Boolean); +}; + +/** + * checks if variable passed is of type string or not + * + * for e.g -> 'Pawan' -> true + * ['Pawan', 'Goku'] -> false + * { name: "Pawan"} -> false + */ +export const isString = (str: any) => { + return typeof str === "string" || str instanceof String; +}; + +export const getSelectedText = () => { + if (typeof window.getSelection === "function") { + const selectionObj = window.getSelection(); + return selectionObj && selectionObj.toString(); + } +}; + +/** + * calculates and returns the scrollwidth + * + * @returns + */ +export const scrollbarWidth = () => { + const scrollDiv = document.createElement("div"); + scrollDiv.setAttribute( + "style", + "width: 100px; height: 100px; overflow: scroll; position:absolute; top:-9999px;", + ); + document.body.appendChild(scrollDiv); + const scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth; + document.body.removeChild(scrollDiv); + return scrollbarWidth; +}; + +// Flatten object +// From { isValid: false, settings: { color: false}} +// To { isValid: false, settings.color: false} +export const flattenObject = (data: Record) => { + const result: Record = {}; + function recurse(cur: any, prop: any) { + if (Object(cur) !== cur) { + result[prop] = cur; + } else if (Array.isArray(cur)) { + for (let i = 0, l = cur.length; i < l; i++) + recurse(cur[i], prop + "[" + i + "]"); + if (cur.length == 0) result[prop] = []; + } else { + let isEmpty = true; + for (const p in cur) { + isEmpty = false; + recurse(cur[p], prop ? prop + "." + p : p); + } + if (isEmpty && prop) result[prop] = {}; + } + } + recurse(data, ""); + return result; +}; + +/** + * renames key in object + * + * @param object + * @param key + * @param newKey + * @returns + */ +export const renameKeyInObject = (object: any, key: string, newKey: string) => { + if (object[key]) { + set(object, newKey, object[key]); + } + + return object; +}; + +export const getIsSafeRedirectURL = (redirectURL: string) => { + try { + return new URL(redirectURL).origin === window.location.origin; + } catch (e) { + return false; + } +}; diff --git a/app/taro/src/utils/hooks/use-ref-state.ts b/app/taro/src/utils/hooks/use-ref-state.ts new file mode 100644 index 0000000000..db97078f0e --- /dev/null +++ b/app/taro/src/utils/hooks/use-ref-state.ts @@ -0,0 +1,22 @@ +import { useCallback, useRef, useState } from "react"; +import { Dispatch, SetStateAction, MutableRefObject } from "react"; + +type StateType = T | (() => T); + +export default function useRefState( + initialState: StateType, +): [T, Dispatch>, MutableRefObject] { + const [state, setState] = useState(initialState); + const ref = useRef(state); + const setRafState = useCallback( + (patch) => { + setState((prevState) => { + // eslint-disable-next-line no-return-assign + return (ref.current = + typeof patch === "function" ? patch(prevState) : patch); + }); + }, + [state], + ); + return [state, setRafState, ref]; +} diff --git a/app/taro/src/utils/hooks/use-set-state.ts b/app/taro/src/utils/hooks/use-set-state.ts new file mode 100644 index 0000000000..1a2b753c72 --- /dev/null +++ b/app/taro/src/utils/hooks/use-set-state.ts @@ -0,0 +1,26 @@ +import React, { useCallback } from "react"; +import useRefState from "./use-ref-state"; +import useUnmountedRef from "./use-unmounted-ref"; + +const useSetState = >( + initialState: T = {} as T, +): [ + T, + (patch: Partial | ((prevState: T) => Partial)) => void, + React.MutableRefObject, +] => { + const unmountedRef = useUnmountedRef(); + const [state, setState, ref] = useRefState(initialState); + + const setMergeState = useCallback((patch) => { + if (unmountedRef.current) return; + setState((prevState) => ({ + ...prevState, + ...(typeof patch === "function" ? patch(prevState) : patch), + })); + }, []); + + return [state, setMergeState, ref]; +}; + +export default useSetState; diff --git a/app/taro/src/utils/hooks/use-unmounted-ref.ts b/app/taro/src/utils/hooks/use-unmounted-ref.ts new file mode 100644 index 0000000000..c3cc1bbc50 --- /dev/null +++ b/app/taro/src/utils/hooks/use-unmounted-ref.ts @@ -0,0 +1,16 @@ +import { useRef, useEffect } from "react"; + +// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types +const useUnmountedRef = () => { + const unmountedRef = useRef(false); + useEffect(() => { + unmountedRef.current = false; + + return () => { + unmountedRef.current = true; + }; + }, []); + return unmountedRef; +}; + +export default useUnmountedRef; diff --git a/app/taro/src/utils/hooks/useDynamicAppLayout.tsx b/app/taro/src/utils/hooks/useDynamicAppLayout.tsx new file mode 100644 index 0000000000..9b424dc2e2 --- /dev/null +++ b/app/taro/src/utils/hooks/useDynamicAppLayout.tsx @@ -0,0 +1,92 @@ +import { ReduxActionTypes } from "constants/ReduxActionConstants"; +import { + DefaultLayoutType, + layoutConfigurations, + MAIN_CONTAINER_WIDGET_ID, +} from "constants/WidgetConstants"; +import { debounce } from "lodash"; +import { useCallback, useEffect } from "react"; +import { AppState } from "reducers"; +import { getWidget, getWidgets } from "sagas/selectors"; +import { + getCurrentApplicationLayout, + getCurrentPageId, +} from "selectors/editorSelectors"; +import { calculateDynamicHeight } from "utils/WidgetPropsUtils"; +import Taro from "@tarojs/taro"; + +export const useDynamicAppLayout = (dispatch: any, useSelector: any) => { + const { windowWidth: screenWidth } = Taro.getSystemInfoSync(); + const mainContainer = useSelector((state: AppState) => + getWidget(state, MAIN_CONTAINER_WIDGET_ID) + ); + const currentPageId = useSelector(getCurrentPageId); + const canvasWidgets = useSelector(getWidgets); + const appLayout = useSelector(getCurrentApplicationLayout); + + const calculateFluidMaxWidth = ( + screenWidth: number, + layoutMaxWidth: number + ) => { + const widthToFill = screenWidth; + if (layoutMaxWidth < 0) { + return widthToFill; + } else { + return widthToFill < layoutMaxWidth ? widthToFill : layoutMaxWidth; + } + }; + + const resizeToLayout = ( + screenWidth: number, + appLayout = { type: "FLUID" } + ) => { + const { type } = appLayout; + const { minWidth = -1, maxWidth = -1 } = + layoutConfigurations[type] || layoutConfigurations[DefaultLayoutType]; + const calculatedMinWidth = minWidth; + const layoutWidth = calculateFluidMaxWidth(screenWidth, maxWidth); + const { rightColumn } = mainContainer; + if ( + (type === "FLUID" || + type === "MOBILE_FLUID" || + calculatedMinWidth <= layoutWidth) && + rightColumn !== layoutWidth + ) { + dispatch({ + type: ReduxActionTypes.UPDATE_CANVAS_LAYOUT, + payload: { + width: layoutWidth, + height: mainContainer.minHeight, + }, + }); + } + }; + + const debouncedResize = useCallback(debounce(resizeToLayout, 250), [ + mainContainer, + ]); + + useEffect(() => { + const calculatedMinHeight = calculateDynamicHeight( + canvasWidgets, + mainContainer.minHeight + ); + if (calculatedMinHeight !== mainContainer.minHeight) { + dispatch({ + type: ReduxActionTypes.UPDATE_CANVAS_LAYOUT, + payload: { + height: calculatedMinHeight, + width: mainContainer.rightColumn, + }, + }); + } + }, [mainContainer.minHeight]); + + useEffect(() => { + debouncedResize(screenWidth, appLayout); + }, [screenWidth]); + + useEffect(() => { + resizeToLayout(screenWidth, appLayout); + }, [appLayout, currentPageId, mainContainer.rightColumn]); +}; diff --git a/app/taro/src/utils/migrations/IncorrectDynamicBindingPathLists.ts b/app/taro/src/utils/migrations/IncorrectDynamicBindingPathLists.ts new file mode 100644 index 0000000000..ee487cc059 --- /dev/null +++ b/app/taro/src/utils/migrations/IncorrectDynamicBindingPathLists.ts @@ -0,0 +1,41 @@ +import { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { WidgetProps } from "widgets/BaseWidget"; +import WidgetFactory from "utils/WidgetFactory"; +import { getAllPathsFromPropertyConfig } from "entities/Widget/utils"; +import _ from "lodash"; +import { DynamicPath, isDynamicValue } from "utils/DynamicBindingUtils"; + +export const migrateIncorrectDynamicBindingPathLists = ( + currentDSL: Readonly>, +): ContainerWidgetProps => { + const migratedDsl = { + ...currentDSL, + }; + const dynamicBindingPathList: DynamicPath[] = []; + const propertyPaneConfig = WidgetFactory.getWidgetPropertyPaneConfig( + currentDSL.type, + ); + const { bindingPaths } = getAllPathsFromPropertyConfig( + currentDSL, + propertyPaneConfig, + {}, + ); + + Object.keys(bindingPaths).forEach((bindingPath) => { + const pathValue = _.get(migratedDsl, bindingPath); + if (pathValue && _.isString(pathValue)) { + if (isDynamicValue(pathValue)) { + dynamicBindingPathList.push({ key: bindingPath }); + } + } + }); + + migratedDsl.dynamicBindingPathList = dynamicBindingPathList; + + if (currentDSL.children) { + migratedDsl.children = currentDSL.children.map( + migrateIncorrectDynamicBindingPathLists, + ); + } + return migratedDsl; +}; diff --git a/app/taro/src/utils/migrations/TableWidget.ts b/app/taro/src/utils/migrations/TableWidget.ts new file mode 100644 index 0000000000..f180cfce06 --- /dev/null +++ b/app/taro/src/utils/migrations/TableWidget.ts @@ -0,0 +1,300 @@ +import { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { WidgetProps } from "widgets/BaseWidget"; +import { + WidgetTypes, + FontStyleTypes, + TextSizes, + GridDefaults, +} from "constants/WidgetConstants"; +import { getAllTableColumnKeys } from "components/designSystems/appsmith/TableComponent/TableHelpers"; +import { + ColumnProperties, + CellAlignmentTypes, + VerticalAlignmentTypes, + ColumnTypes, +} from "components/designSystems/appsmith/TableComponent/Constants"; +import { Colors } from "constants/Colors"; +import { cloneDeep, isString } from "lodash"; + +export interface ColumnAction { + label: string; + id: string; + dynamicTrigger: string; +} + +export const tableWidgetPropertyPaneMigrations = ( + currentDSL: ContainerWidgetProps, +) => { + currentDSL.children = currentDSL.children?.map((_child: WidgetProps) => { + let child = cloneDeep(_child); + // If the current child is a TABLE_WIDGET + if (child.type === WidgetTypes.TABLE_WIDGET) { + const hiddenColumns = child.hiddenColumns || []; + const columnNameMap = child.columnNameMap; + const columnSizeMap = child.columnSizeMap; + const columnTypeMap = child.columnTypeMap; + let tableColumns: string[] = []; + const dynamicBindingPathList = child.dynamicBindingPathList; + if (child.tableData.length) { + let tableData = []; + // Try parsing the table data, if it parses great + // If it does not parse, assign tableData the value as is. + try { + tableData = JSON.parse(child.tableData); + } catch (e) { + tableData = child.tableData; + } + if ( + !isString(tableData) && + dynamicBindingPathList?.findIndex((item) => item.key !== "tableData") + ) { + // Get the list of column ids + tableColumns = getAllTableColumnKeys(tableData); + } else { + child.migrated = false; + } + } + // Get primaryColumns to be the list of column keys + // Use the old order if it exists, else use the new order + const primaryColumns = child.columnOrder?.length + ? child.columnOrder + : tableColumns; + child.primaryColumns = {}; + + // const hasActions = child.columnActions && child.columnActions.length > 0; + // Generate new primarycolumns + primaryColumns.forEach((accessor: string, index: number) => { + // Get the column type from the columnTypeMap + let columnType = + columnTypeMap && columnTypeMap[accessor] + ? columnTypeMap[accessor].type + : ColumnTypes.TEXT; + // If the columnType is currency make it a text type + // We're deprecating currency types + if (columnType === "currency") { + columnType = ColumnTypes.TEXT; + } + // Get a full set of column properties + const column: ColumnProperties = { + index, // Use to maintain order of columns + // The widget of the column + width: + columnSizeMap && columnSizeMap[accessor] + ? columnSizeMap[accessor] + : 150, + // id of the column + id: accessor, + // default horizontal alignment + horizontalAlignment: CellAlignmentTypes.LEFT, + // default vertical alignment + verticalAlignment: VerticalAlignmentTypes.CENTER, + // columnType + columnType, + // default text color + textColor: Colors.THUNDER, + // default text size + textSize: TextSizes.PARAGRAPH, + // default font size + fontStyle: FontStyleTypes.REGULAR, + enableFilter: true, + enableSort: true, + // hide the column if it was hidden earlier using hiddenColumns + isVisible: hiddenColumns.includes(accessor) ? false : true, + // We did not have a concept of derived columns so far + isDerived: false, + // Use renamed names from the map + // or use the newly generated name + label: + columnNameMap && columnNameMap[accessor] + ? columnNameMap[accessor] + : accessor, + // Generate computed value + computedValue: `{{${child.widgetName}.sanitizedTableData.map((currentRow) => ( currentRow.${accessor})}}`, + }; + // copy inputForma nd outputFormat for date column types + if (columnTypeMap && columnTypeMap[accessor]) { + column.outputFormat = columnTypeMap[accessor].format || ""; + column.inputFormat = columnTypeMap[accessor].inputFormat || ""; + } + child.primaryColumns[column.id] = column; + }); + + // Get all column actions + const columnActions = child.columnActions || []; + // Get dynamicTriggerPathList + let dynamicTriggerPathList: Array<{ key: string }> = + child.dynamicTriggerPathList || []; + + const columnPrefix = "customColumn"; + const updatedDerivedColumns: Record = {}; + // Add derived column for each column action + columnActions.forEach((action: ColumnAction, index: number) => { + const column = { + index: child.primaryColumns.length + index, // Add to the end of the columns list + width: 150, // Default width + id: `${columnPrefix}${index + 1}`, // A random string which was generated previously + label: action.label, // Revert back to "Actions" + columnType: "button", // All actions are buttons + isVisible: true, + isDerived: true, + buttonLabel: action.label, + buttonStyle: "rgb(3, 179, 101)", + buttonLabelColor: "#FFFFFF", + onClick: action.dynamicTrigger, + computedValue: "", + }; + dynamicTriggerPathList.push({ + key: `primaryColumns.${columnPrefix}${index + 1}.onClick`, + }); + updatedDerivedColumns[column.id] = column; + child.primaryColumns[column.id] = column; + }); + + if (Object.keys(updatedDerivedColumns).length) { + dynamicTriggerPathList = dynamicTriggerPathList.filter( + (triggerPath: Record) => { + triggerPath.key !== "columnActions"; + }, + ); + } + child.dynamicTriggerPathList = dynamicTriggerPathList; + child.textSize = TextSizes.PARAGRAPH; + child.horizontalAlignment = CellAlignmentTypes.LEFT; + child.verticalAlignment = VerticalAlignmentTypes.CENTER; + child.fontStyle = FontStyleTypes.REGULAR; + + child.derivedColumns = updatedDerivedColumns; + } else if (child.children && child.children.length > 0) { + child = tableWidgetPropertyPaneMigrations(child); + } + return child; + }); + return currentDSL; +}; + +const removeSpecialChars = (value: string, limit?: number) => { + const separatorRegex = /\s/; + return value + .split(separatorRegex) + .join("_") + .slice(0, limit || 30); +}; + +export const migrateTablePrimaryColumnsBindings = ( + currentDSL: ContainerWidgetProps, +) => { + currentDSL.children = currentDSL.children?.map((child: WidgetProps) => { + if (child.type === WidgetTypes.TABLE_WIDGET) { + if ( + child.primaryColumns && + Object.keys(child.primaryColumns).length > 0 + ) { + const newPrimaryColumns: Record = {}; + for (const [key, value] of Object.entries( + child.primaryColumns as Record, + )) { + const sanitizedKey = removeSpecialChars(key, 200); + const newComputedValue = value.computedValue + ? value.computedValue.replace( + `${child.widgetName}.tableData.map`, + `${child.widgetName}.sanitizedTableData.map`, + ) + : ""; + newPrimaryColumns[sanitizedKey] = { + ...value, + computedValue: newComputedValue, + }; + } + child.primaryColumns = newPrimaryColumns; + child.dynamicBindingPathList = child.dynamicBindingPathList?.map( + (path) => { + path.key = path.key.split(" ").join("_"); + return path; + }, + ); + } + } else if (child.children && child.children.length > 0) { + child = migrateTablePrimaryColumnsBindings(child); + } + return child; + }); + return currentDSL; +}; + +export const migrateTableWidgetParentRowSpaceProperty = ( + currentDSL: ContainerWidgetProps, +) => { + currentDSL.children = currentDSL.children?.map((child: WidgetProps) => { + if (child.type === WidgetTypes.TABLE_WIDGET) { + if (child.parentRowSpace === 40) { + child.parentRowSpace = GridDefaults.DEFAULT_GRID_ROW_HEIGHT; + } + } else if (child.children && child.children.length > 0) { + child = migrateTableWidgetParentRowSpaceProperty(child); + } + return child; + }); + return currentDSL; +}; + +export const migrateTableWidgetHeaderVisibilityProperties = ( + currentDSL: ContainerWidgetProps, +) => { + currentDSL.children = currentDSL.children?.map((child: WidgetProps) => { + if (child.type === WidgetTypes.TABLE_WIDGET) { + if (!("isVisibleSearch" in child)) { + child.isVisibleSearch = true; + child.isVisibleFilters = true; + child.isVisibleDownload = true; + child.isVisibleCompactMode = true; + child.isVisiblePagination = true; + } + } else if (child.children && child.children.length > 0) { + child = migrateTableWidgetHeaderVisibilityProperties(child); + } + return child; + }); + return currentDSL; +}; + +export const migrateTablePrimaryColumnsComputedValue = ( + currentDSL: ContainerWidgetProps, +) => { + currentDSL.children = currentDSL.children?.map((child: WidgetProps) => { + if (child.type === WidgetTypes.TABLE_WIDGET) { + if ( + child.primaryColumns && + Object.keys(child.primaryColumns).length > 0 + ) { + const newPrimaryColumns: Record = {}; + for (const [key, value] of Object.entries( + child.primaryColumns as Record, + )) { + const sanitizedKey = removeSpecialChars(key, 200); + let newComputedValue = ""; + if (value.computedValue) { + newComputedValue = value.computedValue.replace( + `${child.widgetName}.sanitizedTableData.map((currentRow) => { return`, + `${child.widgetName}.sanitizedTableData.map((currentRow) => (`, + ); + // change matching "}" bracket with ")" + const lastParanthesesInd = newComputedValue.length - 4; + newComputedValue = + newComputedValue.substring(0, lastParanthesesInd) + + ")" + + newComputedValue.substring(lastParanthesesInd + 1); + } + newPrimaryColumns[sanitizedKey] = { + ...value, + computedValue: newComputedValue, + }; + } + child.primaryColumns = newPrimaryColumns; + } + } else if (child.children && child.children.length > 0) { + child = migrateTablePrimaryColumnsComputedValue(child); + } + return child; + }); + return currentDSL; +}; diff --git a/app/taro/src/utils/migrations/TextWidgetReplaceTextStyle.ts b/app/taro/src/utils/migrations/TextWidgetReplaceTextStyle.ts new file mode 100644 index 0000000000..89659b0e1b --- /dev/null +++ b/app/taro/src/utils/migrations/TextWidgetReplaceTextStyle.ts @@ -0,0 +1,36 @@ +import { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { WidgetProps } from "widgets/BaseWidget"; +import { WidgetTypes } from "constants/WidgetConstants"; +import { FontStyleTypes, TextSizes } from "constants/WidgetConstants"; + +export const migrateTextStyleFromTextWidget = ( + currentDSL: ContainerWidgetProps, +): ContainerWidgetProps => { + currentDSL.children = currentDSL.children?.map((child: WidgetProps) => { + if (child.type === WidgetTypes.TEXT_WIDGET) { + const textStyle = child.textStyle; + switch (textStyle) { + case "HEADING": + child.fontSize = TextSizes.HEADING1; + child.fontStyle = FontStyleTypes.BOLD; + break; + case "BODY": + child.fontSize = TextSizes.PARAGRAPH; + child.fontStyle = ""; + break; + case "LABEL": + child.fontSize = TextSizes.PARAGRAPH; + child.fontStyle = FontStyleTypes.BOLD; + break; + default: + break; + } + child.textColor = "#231F20"; + delete child.textStyle; + } else if (child.children && child.children.length > 0) { + child = migrateTextStyleFromTextWidget(child); + } + return child; + }); + return currentDSL; +}; diff --git a/app/taro/src/utils/validation/getIsSafeURL.ts b/app/taro/src/utils/validation/getIsSafeURL.ts new file mode 100644 index 0000000000..9a49f35f14 --- /dev/null +++ b/app/taro/src/utils/validation/getIsSafeURL.ts @@ -0,0 +1,37 @@ +/** + * REF: https://github.com/angular/angular/blob/master/packages/core/src/sanitization/url_sanitizer.ts + * A pattern that recognizes a commonly useful subset of URLs that are safe. + * + * This regular expression matches a subset of URLs that will not cause script + * execution if used in URL context within a HTML document. Specifically, this + * regular expression matches if (comment from here on and regex copied from + * Soy's EscapingConventions): + * (1) Either an allowed protocol (http, https, mailto or ftp). + * (2) or no protocol. A protocol must be followed by a colon. The below + * allows that by allowing colons only after one of the characters [/?#]. + * A colon after a hash (#) must be in the fragment. + * Otherwise, a colon after a (?) must be in a query. + * Otherwise, a colon after a single solidus (/) must be in a path. + * Otherwise, a colon after a double solidus (//) must be in the authority + * (before port). + * + * The pattern disallows &, used in HTML entity declarations before + * one of the characters in [/?#]. This disallows HTML entities used in the + * protocol name, which should never happen, e.g. "http" for "http". + * It also disallows HTML entities in the first path part of a relative path, + * e.g. "foo<bar/baz". Our existing escaping functions should not produce + * that. More importantly, it disallows masking of a colon, + * e.g. "javascript:...". + * + * This regular expression was taken from the Closure sanitization library. + */ +const SAFE_URL_PATTERN = /^(?:(?:https?|mailto|ftp|tel|file|sms):|[^&:/?#]*(?:[/?#]|$))/gi; + +/** A pattern that matches safe data URLs. Only matches image, video and audio types. */ +const DATA_URL_PATTERN = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+\/]+=*$/i; + +const getIsSafeURL = (value: string) => + typeof value === "string" && + (value.match(SAFE_URL_PATTERN) || value.match(DATA_URL_PATTERN)); + +export default getIsSafeURL; diff --git a/app/taro/src/widgets/BaseWidget.tsx b/app/taro/src/widgets/BaseWidget.tsx new file mode 100644 index 0000000000..e13cac7c22 --- /dev/null +++ b/app/taro/src/widgets/BaseWidget.tsx @@ -0,0 +1,376 @@ +import React, { Component, ReactNode } from 'react'; +import { + CONTAINER_GRID_PADDING, + CSSUnit, + CSSUnits, + PositionType, + PositionTypes, + RenderMode, + RenderModes, + WidgetType, + WidgetTypes, +} from "constants/WidgetConstants"; +import shallowequal from "shallowequal"; +import { memoize } from "lodash"; +import { + DataTreeEvaluationProps, + EVAL_ERROR_PATH, + EvaluationError, + PropertyEvaluationErrorType, + WidgetDynamicPathListProps, +} from "utils/DynamicBindingUtils"; +import { DerivedPropertiesMap } from "utils/WidgetFactory"; +import { PropertyPaneConfig } from "constants/PropertyControlConstants"; +import { EditorContext } from "components/editorComponents/EditorContextProvider"; +import { WidgetExecuteActionPayload } from "constants/AppsmithActionConstants/ActionConstants"; +import AppsmithConsole from "utils/AppsmithConsole"; +import { ENTITY_TYPE } from "entities/AppsmithConsole"; +import { BatchPropertyUpdatePayload } from "actions/controlActions"; +import PositionedContainer from "components/designSystems/appsmith/PositionedContainer"; +import ErrorBoundary from "components/editorComponents/ErrorBoundry"; + +abstract class BaseWidget< + T extends WidgetProps, + K extends WidgetState +> extends Component { + static contextType = EditorContext; + + static getPropertyPaneConfig(): PropertyPaneConfig[] { + return []; + } + + static getDerivedPropertiesMap(): DerivedPropertiesMap { + return {}; + } + + static getDefaultPropertiesMap(): Record { + return {}; + } + // TODO Find a way to enforce this, (dont let it be set) + static getMetaPropertiesMap(): Record { + return {}; + } + + /** + * Widget abstraction to register the widget type + * ```javascript + * getWidgetType() { + * return "MY_AWESOME_WIDGET", + * } + * ``` + */ + abstract getWidgetType(): WidgetType; + + /** + * Widgets can execute actions using this `executeAction` method. + * Triggers may be specific to the widget + */ + executeAction(actionPayload: WidgetExecuteActionPayload): void { + const { executeAction } = this.context; + executeAction && executeAction(actionPayload); + + actionPayload.triggerPropertyName && + AppsmithConsole.info({ + text: `${actionPayload.triggerPropertyName} triggered`, + source: { + type: ENTITY_TYPE.WIDGET, + id: this.props.widgetId, + name: this.props.widgetName, + }, + }); + } + + disableDrag(disable: boolean) { + const { disableDrag } = this.context; + disableDrag && disable !== undefined && disableDrag(disable); + } + + updateWidget( + operationName: string, + widgetId: string, + widgetProperties: any, + ): void { + const { updateWidget } = this.context; + updateWidget && updateWidget(operationName, widgetId, widgetProperties); + } + + deleteWidgetProperty(propertyPaths: string[]): void { + const { deleteWidgetProperty } = this.context; + const { widgetId } = this.props; + if (deleteWidgetProperty && widgetId) { + deleteWidgetProperty(widgetId, propertyPaths); + } + } + + batchUpdateWidgetProperty(updates: BatchPropertyUpdatePayload): void { + const { batchUpdateWidgetProperty } = this.context; + const { widgetId } = this.props; + if (batchUpdateWidgetProperty && widgetId) { + batchUpdateWidgetProperty(widgetId, updates); + } + } + + updateWidgetProperty(propertyName: string, propertyValue: any): void { + this.batchUpdateWidgetProperty({ + modify: { [propertyName]: propertyValue }, + }); + } + + resetChildrenMetaProperty(widgetId: string) { + const { resetChildrenMetaProperty } = this.context; + resetChildrenMetaProperty(widgetId); + } + + getComponentDimensions = () => { + return this.calculateWidgetBounds( + this.props.rightColumn, + this.props.leftColumn, + this.props.topRow, + this.props.bottomRow, + this.props.parentColumnSpace, + this.props.parentRowSpace, + ); + }; + + calculateWidgetBounds( + rightColumn: number, + leftColumn: number, + topRow: number, + bottomRow: number, + parentColumnSpace: number, + parentRowSpace: number, + ): { + componentWidth: number; + componentHeight: number; + } { + return { + componentWidth: (rightColumn - leftColumn) * parentColumnSpace, + componentHeight: (bottomRow - topRow) * parentRowSpace, + }; + } + + getErrorCount = memoize((evalErrors: Record) => { + return Object.values(evalErrors).reduce( + (prev, curr) => + curr.filter( + (error) => error.errorType !== PropertyEvaluationErrorType.LINT, + ).length + prev, + 0, + ); + }, JSON.stringify); + + render() { + return this.getWidgetView(); + } + + makePositioned(content: ReactNode) { + const style = this.getPositionStyle(); + return ( + + {content} + + ); + } + + addErrorBoundary(content: ReactNode) { + return {content}; + } + + addTaroWrapper = (content: ReactNode, type: WidgetType) => { + if ( + type === WidgetTypes.TARO_BOTTOM_BAR_WIDGET || + type === WidgetTypes.TARO_POPUP_WIDGET + ) { + return
{content}
; + } + if (type === WidgetTypes.TARO_LOADING_WIDGET) { + return ( +
{content}
+ ); + } + return content; + }; + + private getWidgetView(): ReactNode { + let content: ReactNode; + + switch (this.props.renderMode) { + case RenderModes.PAGE: + content = this.getPageView(); + if (this.props.isVisible) { + content = this.addErrorBoundary(content); + if (!this.props.detachFromLayout) { + content = this.makePositioned(content); + } else { + content = this.addTaroWrapper(content, this.props.type); + } + return content; + } + return null; + default: + throw Error("RenderMode not defined"); + } + } + + abstract getPageView(): ReactNode; + + // TODO(abhinav): Maybe make this a pure component to bailout from updating altogether. + // This would involve making all widgets which have "states" to not have states, + // as they're extending this one. + shouldComponentUpdate(nextProps: WidgetProps, nextState: WidgetState) { + return ( + !shallowequal(nextProps, this.props) || + !shallowequal(nextState, this.state) + ); + } + + /** + * generates styles that positions the widget + */ + private getPositionStyle(): BaseStyle { + const { componentHeight, componentWidth } = this.getComponentDimensions(); + + return { + positionType: PositionTypes.ABSOLUTE, + componentHeight, + componentWidth, + yPosition: + this.props.topRow * this.props.parentRowSpace + + (this.props.noContainerOffset ? 0 : CONTAINER_GRID_PADDING), + xPosition: + this.props.leftColumn * this.props.parentColumnSpace + + (this.props.noContainerOffset ? 0 : CONTAINER_GRID_PADDING), + xPositionUnit: CSSUnits.PIXEL, + yPositionUnit: CSSUnits.PIXEL, + }; + } + + // TODO(abhinav): These defaultProps seem unneccessary. Check it out. + static defaultProps: Partial | undefined = { + parentRowSpace: 1, + parentColumnSpace: 1, + topRow: 0, + leftColumn: 0, + isLoading: false, + renderMode: RenderModes.CANVAS, + dragDisabled: false, + dropDisabled: false, + isDeletable: true, + resizeDisabled: false, + disablePropertyPane: false, + }; +} + +export interface BaseStyle { + componentHeight: number; + componentWidth: number; + positionType: PositionType; + xPosition: number; + yPosition: number; + xPositionUnit: CSSUnit; + yPositionUnit: CSSUnit; + heightUnit?: CSSUnit; + widthUnit?: CSSUnit; +} + +export type WidgetState = Record; +export interface WidgetBuilder { + buildWidget(widgetProps: T): JSX.Element; +} + +export interface WidgetBaseProps { + widgetId: string; + type: WidgetType; + widgetName: string; + parentId?: string; + renderMode: RenderMode; + version: number; + context: any; +} + +export interface WidgetDisplayProps { + isVisible?: boolean; + isLoading: boolean; + isDisabled?: boolean; + backgroundColor?: string; +} + + +export type WidgetRowCols = { + leftColumn: number; + rightColumn: number; + topRow: number; + bottomRow: number; + minHeight?: number; // Required to reduce the size of CanvasWidgets. +}; + +export interface WidgetPositionProps extends WidgetRowCols { + parentColumnSpace: number; + parentRowSpace: number; + // The detachFromLayout flag tells use about the following properties when enabled + // 1) Widget does not drag/resize + // 2) Widget CAN (but not neccessarily) be a dropTarget + // Examples: MainContainer is detached from layout, + // MODAL_WIDGET is also detached from layout. + detachFromLayout?: boolean; + noContainerOffset?: boolean; // This won't offset the child in parent +} + +export interface WidgetDataProps + extends WidgetBaseProps, + WidgetPositionProps, + WidgetDisplayProps {} + +export interface WidgetProps + extends WidgetDataProps, + WidgetDynamicPathListProps, + DataTreeEvaluationProps { + key?: string; + isDefaultClickDisabled?: boolean; + [key: string]: any; +} + +export interface WidgetCardProps { + type: WidgetType; + key?: string; + widgetCardName: string; + isBeta?: boolean; +} + +export const WidgetOperations = { + MOVE: "MOVE", + RESIZE: "RESIZE", + ADD_CHILD: "ADD_CHILD", + UPDATE_PROPERTY: "UPDATE_PROPERTY", + DELETE: "DELETE", + ADD_CHILDREN: "ADD_CHILDREN", +}; + +export type WidgetOperation = typeof WidgetOperations[keyof typeof WidgetOperations]; + +export const WIDGET_STATIC_PROPS = { + leftColumn: true, + rightColumn: true, + topRow: true, + bottomRow: true, + minHeight: true, + parentColumnSpace: true, + parentRowSpace: true, + children: true, + type: true, + widgetId: true, + widgetName: true, + parentId: true, + renderMode: true, + detachFromLayout: true, + noContainerOffset: false, +}; + +export default BaseWidget; diff --git a/app/taro/src/widgets/CanvasWidget.tsx b/app/taro/src/widgets/CanvasWidget.tsx new file mode 100644 index 0000000000..c746b45a43 --- /dev/null +++ b/app/taro/src/widgets/CanvasWidget.tsx @@ -0,0 +1,75 @@ +import React, { CSSProperties } from "react"; +import { WidgetProps } from "widgets/BaseWidget"; +import ContainerWidget, { ContainerWidgetProps } from "widgets/ContainerWidget"; +import { WidgetTypes, GridDefaults } from "constants/WidgetConstants"; +import { getCanvasSnapRows } from "utils/WidgetPropsUtils"; +import { getCanvasClassName } from "utils/generators"; +import WidgetFactory from "utils/WidgetFactory"; + +class CanvasWidget extends ContainerWidget { + static getPropertyPaneConfig() { + return []; + } + getWidgetType = () => { + return WidgetTypes.CANVAS_WIDGET; + }; + + getCanvasProps(): ContainerWidgetProps { + return { + ...this.props, + parentRowSpace: 1, + parentColumnSpace: 1, + topRow: 0, + leftColumn: 0, + containerStyle: "none", + }; + } + + renderChildWidget(childWidgetData: WidgetProps): React.ReactNode { + if (!childWidgetData) return null; + // For now, isVisible prop defines whether to render a detached widget + if (childWidgetData.detachFromLayout && !childWidgetData.isVisible) { + return null; + } + const snapSpaces = this.getSnapSpaces(); + + childWidgetData.parentColumnSpace = snapSpaces.snapColumnSpace; + childWidgetData.parentRowSpace = snapSpaces.snapRowSpace; + if (this.props.noPad) childWidgetData.noContainerOffset = true; + childWidgetData.parentId = this.props.widgetId; + // child widgets need context for connect() + childWidgetData.context = this.props.context; + + return WidgetFactory.createWidget(childWidgetData, this.props.renderMode); + } + + getPageView() { + let height = 0; + const snapRows = getCanvasSnapRows( + this.props.bottomRow, + this.props.canExtend, + ); + height = snapRows * GridDefaults.DEFAULT_GRID_ROW_HEIGHT; + + const style: CSSProperties = { + width: "100%", + height: `${height}px`, + background: "none", + position: "relative", + }; + // This div is the DropTargetComponent alternative for the page view + // DropTargetComponent and this div are responsible for the canvas height + return ( +
+ {this.renderAsContainerComponent(this.getCanvasProps())} +
+ ); + } + + getCanvasView() { + return this.getPageView(); + } +} + +export default CanvasWidget; +export const ProfiledCanvasWidget = CanvasWidget; diff --git a/app/taro/src/widgets/ContainerWidget.tsx b/app/taro/src/widgets/ContainerWidget.tsx new file mode 100644 index 0000000000..e7cba6b3f6 --- /dev/null +++ b/app/taro/src/widgets/ContainerWidget.tsx @@ -0,0 +1,149 @@ +import React from "react"; +import { map, sortBy, compact } from "lodash"; +import { + GridDefaults, + CONTAINER_GRID_PADDING, + WIDGET_PADDING, + MAIN_CONTAINER_WIDGET_ID, +} from "constants/WidgetConstants"; +import WidgetFactory from "utils/WidgetFactory"; +import ContainerComponent, { + ContainerStyle, +} from "components/designSystems/appsmith/ContainerComponent"; +import { WidgetType, WidgetTypes } from "constants/WidgetConstants"; +import BaseWidget, { WidgetProps, WidgetState } from "./BaseWidget"; +import { ValidationTypes } from "constants/WidgetValidation"; + +class ContainerWidget extends BaseWidget< + ContainerWidgetProps, + WidgetState +> { + constructor(props: ContainerWidgetProps) { + super(props); + this.renderChildWidget = this.renderChildWidget.bind(this); + } + + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + helpText: "css颜色配置(html颜色名称,HEX,RGB 或 RGBA)", + placeholderText: "#FFFFFF / Gray / rgb(255, 99, 71)", + propertyName: "backgroundColor", + label: "背景颜色", + controlType: "COLOR_PICKER", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + helpText: "控制组件是否可见", + propertyName: "isVisible", + label: "是否可见", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "shouldScrollContents", + label: "是否滚动内容", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + }, + ], + }, + ]; + } + + getSnapSpaces = () => { + const { componentWidth } = this.getComponentDimensions(); + // For all widgets inside a container, we remove both container padding as well as widget padding from component width + let padding = (CONTAINER_GRID_PADDING + WIDGET_PADDING) * 2; + if ( + this.props.widgetId === MAIN_CONTAINER_WIDGET_ID || + this.props.type === "CONTAINER_WIDGET" + ) { + //For MainContainer and any Container Widget padding doesn't exist coz there is already container padding. + padding = CONTAINER_GRID_PADDING * 2; + } + if (this.props.noPad) { + // Widgets like ListWidget choose to have no container padding so will only have widget padding + padding = WIDGET_PADDING * 2; + } + let width = componentWidth; + width -= padding; + return { + snapRowSpace: GridDefaults.DEFAULT_GRID_ROW_HEIGHT, + snapColumnSpace: componentWidth + ? width / GridDefaults.DEFAULT_GRID_COLUMNS + : 0, + }; + }; + + renderChildWidget(childWidgetData: WidgetProps): React.ReactNode { + // For now, isVisible prop defines whether to render a detached widget + if (childWidgetData.detachFromLayout && !childWidgetData.isVisible) { + return null; + } + + const { componentHeight, componentWidth } = this.getComponentDimensions(); + + childWidgetData.rightColumn = componentWidth; + childWidgetData.bottomRow = this.props.shouldScrollContents + ? childWidgetData.bottomRow + : componentHeight; + childWidgetData.minHeight = componentHeight; + childWidgetData.isVisible = this.props.isVisible; + childWidgetData.shouldScrollContents = false; + childWidgetData.canExtend = this.props.shouldScrollContents; + childWidgetData.parentId = this.props.widgetId; + // child widgets need context for connect() + childWidgetData.context = this.props.context; + + return WidgetFactory.createWidget(childWidgetData, this.props.renderMode); + } + + renderChildren = () => { + return map( + // sort by row so stacking context is correct + // TODO(abhinav): This is hacky. The stacking context should increase for widgets rendered top to bottom, always. + // Figure out a way in which the stacking context is consistent. + sortBy(compact(this.props.children), (child) => child.topRow), + this.renderChildWidget, + ); + }; + + renderAsContainerComponent(props: ContainerWidgetProps) { + return ( + + {/* without the wrapping div onClick events are triggered twice */} + <>{this.renderChildren()} + + ); + } + + getPageView() { + return this.renderAsContainerComponent(this.props); + } + + getWidgetType(): WidgetType { + return WidgetTypes.CONTAINER_WIDGET; + } +} + +export interface ContainerWidgetProps + extends WidgetProps { + children?: T[]; + containerStyle?: ContainerStyle; + shouldScrollContents?: boolean; + noPad?: boolean; +} + +export default ContainerWidget; +export const ProfiledContainerWidget = ContainerWidget; diff --git a/app/taro/src/widgets/FileDataTypes.ts b/app/taro/src/widgets/FileDataTypes.ts new file mode 100644 index 0000000000..01e0a7c493 --- /dev/null +++ b/app/taro/src/widgets/FileDataTypes.ts @@ -0,0 +1,7 @@ +enum FileDataTypes { + Base64 = "Base64", + Text = "Text", + Binary = "Binary", +} + +export default FileDataTypes; diff --git a/app/taro/src/widgets/MetaHOC.tsx b/app/taro/src/widgets/MetaHOC.tsx new file mode 100644 index 0000000000..1c5dcbb8dd --- /dev/null +++ b/app/taro/src/widgets/MetaHOC.tsx @@ -0,0 +1,194 @@ +import React from "react"; +import BaseWidget, { WidgetProps } from "./BaseWidget"; +import _ from "lodash"; +import { EditorContext } from "../components/editorComponents/EditorContextProvider"; +import { clearEvalPropertyCache } from "sagas/EvaluationsSaga"; +import { WidgetExecuteActionPayload } from "constants/AppsmithActionConstants/ActionConstants"; +import AppsmithConsole from "utils/AppsmithConsole"; +import { ENTITY_TYPE } from "entities/AppsmithConsole"; +import LOG_TYPE from "entities/AppsmithConsole/logtype"; + +type DebouncedExecuteActionPayload = Omit< + WidgetExecuteActionPayload, + "dynamicString" +> & { + dynamicString?: string; +}; + +export interface WithMeta { + updateWidgetMetaProperty: ( + propertyName: string, + propertyValue: any, + actionExecution?: DebouncedExecuteActionPayload, + ) => void; + syncUpdateWidgetMetaProperty: ( + propertyName: string, + propertyValue: any, + ) => void; +} + +const withMeta = (WrappedWidget: typeof BaseWidget) => { + return class MetaHOC extends React.PureComponent { + static contextType = EditorContext; + updatedProperties = new Map(); + propertyTriggers = new Map(); + + debouncedHandleUpdateWidgetMetaProperty = _.debounce( + this.handleUpdateWidgetMetaProperty.bind(this), + 200, + { + leading: true, + trailing: true, + }, + ); + + constructor(props: any) { + super(props); + const metaProperties = WrappedWidget.getMetaPropertiesMap(); + this.state = _.fromPairs( + Object.keys(metaProperties).map((metaProperty) => { + return [metaProperty, this.props[metaProperty]]; + }), + ); + } + + componentDidUpdate(prevProps: WidgetProps) { + const metaProperties = WrappedWidget.getMetaPropertiesMap(); + const defaultProperties = WrappedWidget.getDefaultPropertiesMap(); + Object.keys(metaProperties).forEach((metaProperty) => { + const defaultProperty = defaultProperties[metaProperty]; + /* + Generally the meta property value of a widget will directly be + controlled by itself and the platform will not interfere except: + When we reset the meta property value to it's default property value. + This operation happens by the platform and is outside the widget logic + so to identify this change, we want to see if the meta value has + changed to the current default value. If this has happened, we should + set the state of the meta property value (controlled by inside the + widget) to the current value that is outside (controlled by platform) + */ + if ( + !_.isEqual(prevProps[metaProperty], this.props[metaProperty]) && + _.isEqual(this.props[defaultProperty], this.props[metaProperty]) + ) { + this.setState({ [metaProperty]: this.props[metaProperty] }); + } + }); + } + + updateWidgetMetaProperty = ( + propertyName: string, + propertyValue: any, + actionExecution?: DebouncedExecuteActionPayload, + ): void => { + this.updatedProperties.set(propertyName, true); + if (actionExecution) { + this.propertyTriggers.set(propertyName, actionExecution); + } + + AppsmithConsole.info({ + logType: LOG_TYPE.WIDGET_UPDATE, + text: "Widget property was updated", + source: { + type: ENTITY_TYPE.WIDGET, + id: this.props.widgetId, + name: this.props.widgetName, + propertyPath: propertyName, + }, + state: { + [propertyName]: propertyValue, + }, + }); + this.setState( + { + [propertyName]: propertyValue, + }, + () => { + this.debouncedHandleUpdateWidgetMetaProperty(); + }, + ); + }; + + // To be used when there is a race condition noticed on updating different + // properties from a widget in quick succession + syncUpdateWidgetMetaProperty = ( + propertyName: string, + propertyValue: any, + ): void => { + const { updateWidgetMetaProperty } = this.context; + const { widgetId, widgetName } = this.props; + this.setState({ + [propertyName]: propertyValue, + }); + clearEvalPropertyCache(`${widgetName}.${propertyName}`); + updateWidgetMetaProperty(widgetId, propertyName, propertyValue); + }; + + handleUpdateWidgetMetaProperty() { + const { executeAction, updateWidgetMetaProperty } = this.context; + const { widgetId, widgetName } = this.props; + const metaOptions = this.props.__metaOptions; + /* + We have kept a map of all updated properties. After debouncing we will + go through these properties and update with the final value. This way + we will only update a certain property once per debounce interval. + Then we will execute any action associated with the trigger of + that value changing + */ + + [...this.updatedProperties.keys()].forEach((propertyName) => { + if (updateWidgetMetaProperty) { + const propertyValue = this.state[propertyName]; + + clearEvalPropertyCache(`${widgetName}.${propertyName}`); + // step 6 - look at this.props.options, check for metaPropPath value + // if they exist, then update the propertyName + updateWidgetMetaProperty(widgetId, propertyName, propertyValue); + + if (metaOptions) { + updateWidgetMetaProperty( + metaOptions.widgetId, + `${metaOptions.metaPropPrefix}.${this.props.widgetName}.${propertyName}[${metaOptions.index}]`, + propertyValue, + ); + } + + this.updatedProperties.delete(propertyName); + } + const debouncedPayload = this.propertyTriggers.get(propertyName); + if ( + debouncedPayload && + debouncedPayload.dynamicString && + executeAction + ) { + executeAction(debouncedPayload); + this.propertyTriggers.delete(propertyName); + debouncedPayload.triggerPropertyName && + AppsmithConsole.info({ + text: `${debouncedPayload.triggerPropertyName} triggered`, + source: { + type: ENTITY_TYPE.WIDGET, + id: this.props.widgetId, + name: this.props.widgetName, + }, + }); + } + }); + } + + updatedProps = () => { + return { + ...this.props, + ...this.state, + updateWidgetMetaProperty: this.updateWidgetMetaProperty, + syncUpdateWidgetMetaProperty: this.syncUpdateWidgetMetaProperty, + }; + }; + + render() { + return ; + } + }; +}; + +export default withMeta; diff --git a/app/taro/src/widgets/SkeletonWidget.tsx b/app/taro/src/widgets/SkeletonWidget.tsx new file mode 100644 index 0000000000..4400d1034a --- /dev/null +++ b/app/taro/src/widgets/SkeletonWidget.tsx @@ -0,0 +1,31 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "./BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import { Skeleton } from "@taroify/core"; +import { styled } from "linaria/react"; + +const Loading = styled(Skeleton)` + width: 100%; + height: 100%; + border-radius: 4px; +`; + +class SkeletonWidget extends BaseWidget { + static getPropertyPaneConfig() { + return []; + } + getPageView() { + return ; + } + + getWidgetType(): WidgetType { + return "SKELETON_WIDGET"; + } +} + +export interface SkeletonWidgetProps extends WidgetProps { + isLoading: boolean; +} + +export default SkeletonWidget; +export const ProfiledSkeletonWidget = SkeletonWidget; diff --git a/app/taro/src/widgets/taro/ActionBarWidget.tsx b/app/taro/src/widgets/taro/ActionBarWidget.tsx new file mode 100644 index 0000000000..5a7f8196f3 --- /dev/null +++ b/app/taro/src/widgets/taro/ActionBarWidget.tsx @@ -0,0 +1,242 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import ActionBar from "components/designSystems/taro/ActionBar"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { get } from "lodash"; + +const noMeSubField = ( + props: MActionBarWidgetProps, + propertyPath: string, + field: string, + current: string, +) => { + const baseProperty = propertyPath.replace(/\.\w+$/g, ""); + const target = get(props, `${baseProperty}.${field}`, ""); + return target !== current; +}; + +class MActionBarWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "内容", + children: [ + { + propertyName: "actionsObj", + label: "动作单元", + controlType: "ACTIONS_INPUT", + isJSConvertible: false, + isBindProperty: false, + isTriggerProperty: false, + panelConfig: { + editableTitle: true, + titlePropertyName: "label", + panelIdPropertyName: "id", + updateHook: ( + props: any, + propertyPath: string, + propertyValue: string, + ) => { + return [ + { + propertyPath, + propertyValue, + }, + ]; + }, + children: [ + { + sectionName: "配置", + children: [ + { + propertyName: "type", + label: "类型", + controlType: "RADIO", + options: [ + { + label: "图标", + value: "icon", + }, + { + label: "按钮", + value: "button", + }, + ], + columns: 3, + defaultValue: "icon", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "icon", + label: "图标", + controlType: "VANT_ICON_SELECT", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["actionsObj"], + hidden: ( + props: MActionBarWidgetProps, + propertyPath: string, + ) => noMeSubField(props, propertyPath, "type", "icon"), + }, + { + propertyName: "badge", + label: "小红点提示", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["actionsObj"], + hidden: ( + props: MActionBarWidgetProps, + propertyPath: string, + ) => noMeSubField(props, propertyPath, "type", "icon"), + }, + { + propertyName: "color", + label: "颜色", + controlType: "COLOR_PICKER", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + }, + { + propertyName: "buttonType", + label: "按钮类型", + controlType: "RADIO", + options: [ + { + label: "浅底色", + value: "warning", + }, + { + label: "深底色", + value: "danger", + }, + ], + name: "buttonRadio", + columns: 3, + defaultValue: "danger", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["actionsObj"], + hidden: ( + props: MActionBarWidgetProps, + propertyPath: string, + ) => noMeSubField(props, propertyPath, "type", "button"), + }, + ], + }, + { + sectionName: "动作", + children: [ + { + propertyName: "onClick", + label: "onClick", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ], + }, + }, + ], + }, + ]; + } + + getActions = () => { + const list = Object.values(this.props.actionsObj || {}); + if (list.length) { + return list + .filter((a) => a.isVisible === undefined || !!a.isVisible === true) + .sort((a, b) => a.index - b.index); + } + return []; + }; + + runAction = (script: string) => { + if (script) { + super.executeAction({ + triggerPropertyName: "onClick", + dynamicString: script, + event: { + type: EventType.ON_CLICK, + }, + }); + } + }; + + onClickAction = (script: string) => () => { + this.runAction(script); + }; + + getPageView() { + const actions = this.getActions(); + return ( + + {actions.map((action, index) => { + const { label, type, icon, color, badge, buttonType, onClick } = + action || {}; + if (type === "icon") { + return ( + + ); + } + return ( + + ); + })} + + ); + } + + getWidgetType(): WidgetType { + return "TARO_ACTION_BAR_WIDGET"; + } +} + +export interface MActionBarWidgetProps extends WidgetProps, WithMeta { + actionsObj: Record< + string, + { + id: string; + label: string; + widgetId: string; + type: "icon" | "button"; + icon?: string; + color?: string; + badge?: string; + buttonType?: "warning" | "danger"; + isVisible?: boolean; + onClick?: string; + index: number; + } + >; +} + +export default MActionBarWidget; +export const MProfiledActionBarWidget = withMeta(MActionBarWidget); diff --git a/app/taro/src/widgets/taro/BottomBarWidget.tsx b/app/taro/src/widgets/taro/BottomBarWidget.tsx new file mode 100644 index 0000000000..54349a516e --- /dev/null +++ b/app/taro/src/widgets/taro/BottomBarWidget.tsx @@ -0,0 +1,101 @@ +import React, { ReactNode } from "react"; +import { connect } from "react-redux"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import WidgetFactory from "utils/WidgetFactory"; +import { ValidationTypes } from "constants/WidgetValidation"; +import BottomBarComponent from "components/designSystems/taro/BottomBarComponent"; +import { + WidgetTypes, + RenderMode, + MAIN_CONTAINER_WIDGET_ID, +} from "constants/WidgetConstants"; +import { generateClassName } from "utils/generators"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { AppState } from "reducers"; +import { getWidget } from "sagas/selectors"; + +export class MBottomBarWidget extends BaseWidget< + MBottomBarWidgetProps, + WidgetState +> { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "height", + label: "面板高度(不带单位的数字)", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.NUMBER, + params: { min: 80, max: 200 }, + }, + }, + ], + }, + ]; + } + + getModalWidth() { + return this.props.mainContainer.rightColumn; + } + + renderChildWidget = (childWidgetData: WidgetProps): ReactNode => { + childWidgetData.parentId = this.props.widgetId; + childWidgetData.shouldScrollContents = false; + childWidgetData.canExtend = false; + childWidgetData.bottomRow = this.props.height; + childWidgetData.isVisible = this.props.isVisible; + childWidgetData.containerStyle = "none"; + childWidgetData.minHeight = this.props.height; + childWidgetData.rightColumn = this.getModalWidth(); + return WidgetFactory.createWidget(childWidgetData, this.props.renderMode); + }; + + getChildren(): ReactNode { + if (this.props.children && this.props.children.length > 0) { + const children = this.props.children.filter(Boolean); + return children.length > 0 && children.map(this.renderChildWidget); + } + } + + makeModalComponent(content: ReactNode) { + return ( + + {content} + + ); + } + + getPageView() { + const children = this.getChildren(); + return this.makeModalComponent(children); + } + + getWidgetType() { + return WidgetTypes.TARO_BOTTOM_BAR_WIDGET; + } +} + +export interface MBottomBarWidgetProps extends WidgetProps, WithMeta { + renderMode: RenderMode; + children?: WidgetProps[]; + height: number; + mainContainer: WidgetProps; +} + +const mapStateToProps = (state: AppState) => { + return { + mainContainer: getWidget(state, MAIN_CONTAINER_WIDGET_ID), + }; +}; +export default MBottomBarWidget; +export const MProfiledBottomBarWidget = connect(mapStateToProps)( + withMeta(MBottomBarWidget) +); diff --git a/app/taro/src/widgets/taro/ButtonWidget.tsx b/app/taro/src/widgets/taro/ButtonWidget.tsx new file mode 100644 index 0000000000..8b14c17623 --- /dev/null +++ b/app/taro/src/widgets/taro/ButtonWidget.tsx @@ -0,0 +1,187 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import ButtonComponent from "components/designSystems/taro/ButtonComponent"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import withMeta, { WithMeta } from "../MetaHOC"; + +class MButtonWidget extends BaseWidget { + state = { + isLoading: false, + }; + + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "text", + label: "按钮文字", + controlType: "INPUT_TEXT", + placeholderText: "输入按钮文字", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "color", + label: "背景颜色", + controlType: "COLOR_PICKER", + isBindProperty: true, + isTriggerProperty: false, + }, + { + propertyName: "textColor", + label: "文本颜色", + controlType: "COLOR_PICKER", + isBindProperty: true, + isTriggerProperty: false, + }, + { + propertyName: "fontSize", + label: "字体大小", + controlType: "RADIO", + options: [ + { + label: "小", + value: "14px", + }, + { + label: "适中", + value: "16px", + }, + { + label: "大", + value: "18px", + }, + { + label: "超大", + value: "20px", + }, + ], + columns: 4, + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "isBold", + label: "字体加粗", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "rounded", + label: "是否圆角", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "isVisible", + label: "是否可见", + helpText: "控制按钮显示/隐藏", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "isDisabled", + label: "禁用", + controlType: "SWITCH", + helpText: "禁止按钮交互", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "showLoading", + label: "显示加载动画", + helpText: "数据加载或触发动作时,是否显示加载动画", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "点击按钮时触发动作", + propertyName: "onClick", + label: "onClick", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + onButtonClick = () => { + if (this.props.onClick) { + this.setState({ + isLoading: true, + }); + super.executeAction({ + triggerPropertyName: "onClick", + dynamicString: this.props.onClick, + event: { + type: EventType.ON_CLICK, + callback: this.handleActionComplete, + }, + }); + } + }; + + handleActionComplete = () => { + this.setState({ + isLoading: false, + }); + }; + + getPageView() { + const { isLoading, showLoading, isDisabled, ...others } = this.props; + const loading = showLoading && (isLoading || this.state.isLoading); + return ( + + ); + } + + getWidgetType(): WidgetType { + return "TARO_BUTTON_WIDGET"; + } +} + +export interface MButtonWidgetProps extends WidgetProps, WithMeta { + text?: string; + color?: string; + textColor?: string; + fontSize?: string; + onClick?: string; + rounded?: boolean; + isDisabled?: boolean; + isVisible?: boolean; +} + +interface ButtonWidgetState extends WidgetState { + isLoading: boolean; +} + +export default MButtonWidget; +export const MProfiledButtonWidget = withMeta(MButtonWidget); diff --git a/app/taro/src/widgets/taro/CellWidget.tsx b/app/taro/src/widgets/taro/CellWidget.tsx new file mode 100644 index 0000000000..de71dbde25 --- /dev/null +++ b/app/taro/src/widgets/taro/CellWidget.tsx @@ -0,0 +1,295 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import CellComponent from "components/designSystems/taro/CellComponent"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { get } from "lodash"; + +const noMeSubField = ( + props: MCellWidgetProps, + propertyPath: string, + field: string, + current: string, +) => { + const baseProperty = propertyPath.replace(/\.\w+$/g, ""); + const target = get(props, `${baseProperty}.${field}`, ""); + return target !== current; +}; + +class MCellWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "内容", + children: [ + { + propertyName: "cellsObj", + label: "单元格列表", + controlType: "CELLS_INPUT", + isJSConvertible: false, + isBindProperty: false, + isTriggerProperty: false, + panelConfig: { + editableTitle: true, + titlePropertyName: "label", + panelIdPropertyName: "id", + updateHook: ( + props: any, + propertyPath: string, + propertyValue: string, + ) => { + return [ + { + propertyPath, + propertyValue, + }, + ]; + }, + children: [ + { + sectionName: "单元格配置", + children: [ + { + propertyName: "picType", + label: "左侧内容", + controlType: "RADIO", + options: [ + { + label: "无", + value: "none", + }, + { + label: "文字", + value: "text", + }, + { + label: "图标", + value: "icon", + }, + { + label: "图片", + value: "image", + }, + ], + columns: 4, + defaultValue: "none", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "prefix", + label: "左侧文字", + controlType: "INPUT_TEXT", + placeholderText: "输入左侧文字", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["cellsObj"], + hidden: (props: MCellWidgetProps, propertyPath: string) => + noMeSubField(props, propertyPath, "picType", "text"), + }, + { + propertyName: "icon", + label: "图标", + controlType: "VANT_ICON_SELECT", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["cellsObj"], + hidden: (props: MCellWidgetProps, propertyPath: string) => + noMeSubField(props, propertyPath, "picType", "icon"), + }, + { + propertyName: "iconColor", + label: "图标颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + dependencies: ["cellsObj"], + hidden: (props: MCellWidgetProps, propertyPath: string) => + noMeSubField(props, propertyPath, "picType", "icon"), + }, + { + propertyName: "picSrc", + label: "图片地址", + controlType: "INPUT_TEXT", + placeholderText: "输入图片地址", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.IMAGE_URL }, + dependencies: ["cellsObj"], + hidden: (props: MCellWidgetProps, propertyPath: string) => + noMeSubField(props, propertyPath, "picType", "image"), + }, + { + propertyName: "brief", + label: "描述", + controlType: "INPUT_TEXT", + placeholderText: "输入描述", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "content", + label: "右侧内容", + controlType: "INPUT_TEXT", + placeholderText: "输入右侧内容", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "showArrow", + label: "显示右侧箭头", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "isVisible", + label: "是否可见", + helpText: "控制单元格显示/隐藏", + controlType: "SWITCH", + useValidationMessage: true, + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + propertyName: "onClick", + label: "onClick", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ], + }, + }, + ], + }, + { + sectionName: "属性", + children: [ + { + propertyName: "inset", + label: "圆角卡片风格", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "bordered", + label: "显示外边框", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "title", + label: "标题", + controlType: "INPUT_TEXT", + placeholderText: "输入标题", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "isVisible", + label: "是否可见", + helpText: "控制显示/隐藏", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + ]; + } + + getCells = () => { + const cells = Object.values(this.props.cellsObj || {}); + if (cells.length) { + return cells + .filter( + (cell) => cell.isVisible === undefined || !!cell.isVisible === true, + ) + .sort((cell1, cell2) => cell1.index - cell2.index); + } + return []; + }; + + runAction = (script: string) => { + if (script) { + super.executeAction({ + triggerPropertyName: "onClick", + dynamicString: script, + event: { + type: EventType.ON_CLICK, + }, + }); + } + }; + + getPageView() { + return ( + + ); + } + + getWidgetType(): WidgetType { + return "TARO_CELL_WIDGET"; + } +} + +export interface MCellWidgetProps extends WidgetProps, WithMeta { + title?: string; + inset: boolean; + bordered: boolean; + isVisible?: boolean; + cellsObj: Record< + string, + { + id: string; + label: string; + widgetId: string; + picType: "none" | "icon" | "image" | "text"; + prefix?: string; + icon?: string; + iconColor?: string; + picSrc?: string; + isVisible?: boolean; + showArrow?: boolean; + content?: string; + brief?: string; + onClick?: string; + index: number; + } + >; +} + +export default MCellWidget; +export const MProfiledCellWidget = withMeta(MCellWidget); diff --git a/app/taro/src/widgets/taro/CheckboxWidget.tsx b/app/taro/src/widgets/taro/CheckboxWidget.tsx new file mode 100644 index 0000000000..c9b72ff49f --- /dev/null +++ b/app/taro/src/widgets/taro/CheckboxWidget.tsx @@ -0,0 +1,152 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { View } from "@tarojs/components"; +import { Checkbox } from "@taroify/core"; +import { WidgetType } from "constants/WidgetConstants"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import { DerivedPropertiesMap } from "utils/WidgetFactory"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { styled } from 'linaria/react'; +import withMeta, { WithMeta } from "../MetaHOC"; +import LoadingWrapper from "./LoadingWrapper"; + +const Container = styled(View)` + width: 100%; + height: 100%; + display: flex; + justify-content: flex-start; + align-items: center; +`; + +class MCheckboxWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "label", + label: "文本", + controlType: "INPUT_TEXT", + placeholderText: "输入文本内容", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "defaultCheckedState", + label: "默认选中", + helpText: "修改它会刷新组件状态", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "isVisible", + label: "是否可见", + helpText: "控制组件是否可见", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "isDisabled", + label: "是否禁用", + controlType: "SWITCH", + helpText: "是否禁止用户操作", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "showLoading", + label: "数据加载时显示加载动画", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "当选中状态变化时触发", + propertyName: "onCheckChange", + label: "onCheckChange", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + static getDefaultPropertiesMap(): Record { + return { + isChecked: "defaultCheckedState", + }; + } + + static getDerivedPropertiesMap(): DerivedPropertiesMap { + return { + value: `{{!!this.isChecked}}`, + }; + } + + static getMetaPropertiesMap(): Record { + return { + isChecked: undefined, + }; + } + + onCheckChange = (isChecked: boolean) => { + this.props.updateWidgetMetaProperty("isChecked", isChecked, { + triggerPropertyName: "onCheckChange", + dynamicString: this.props.onCheckChange, + event: { + type: EventType.ON_CHECK_CHANGE, + }, + }); + }; + + getPageView() { + const { isChecked, label, isDisabled, isLoading, showLoading } = this.props; + return ( + + + + {label} + + + + ); + } + + getWidgetType(): WidgetType { + return "TARO_CHECKBOX_WIDGET"; + } +} + +export interface MCheckboxWidgetProps extends WidgetProps, WithMeta { + label: string; + defaultCheckedState: boolean; + isChecked?: boolean; + isDisabled?: boolean; + onCheckChange?: string; +} + +export default MCheckboxWidget; +export const MProfiledCheckboxWidget = withMeta(MCheckboxWidget); diff --git a/app/taro/src/widgets/taro/FormWidget.tsx b/app/taro/src/widgets/taro/FormWidget.tsx new file mode 100644 index 0000000000..1873bb9173 --- /dev/null +++ b/app/taro/src/widgets/taro/FormWidget.tsx @@ -0,0 +1,382 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import FormComponent, { + FormComponentProps, +} from "components/designSystems/taro/FormComponent"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { get, isArray } from "lodash"; + +const noMeSubField = ( + props: MFormWidgetProps, + propertyPath: string, + field: string, + current: string | string[] +) => { + const baseProperty = propertyPath.replace(/\.\w+$/g, ""); + const target = get(props, `${baseProperty}.${field}`, ""); + if (isArray(current)) { + return !current.includes(target); + } + return target !== current; +}; + +class MFormWidget extends BaseWidget { + state = { + isLoading: false, + }; + + static getPropertyPaneConfig() { + return [ + { + sectionName: "内容", + children: [ + { + propertyName: "fieldsObj", + label: "表单字段", + controlType: "FIELDS_INPUT", + isJSConvertible: false, + isBindProperty: false, + isTriggerProperty: false, + panelConfig: { + editableTitle: true, + titlePropertyName: "label", + panelIdPropertyName: "id", + updateHook: ( + props: any, + propertyPath: string, + propertyValue: string + ) => { + return [ + { + propertyPath, + propertyValue, + }, + ]; + }, + children: [ + { + sectionName: "字段配置", + children: [ + { + propertyName: "name", + label: "字段名称", + controlType: "INPUT_TEXT", + placeholderText: "输入字段名称", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.TEXT, + params: { required: true }, + }, + }, + { + propertyName: "required", + label: "必填", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "fieldType", + label: "字段控件", + controlType: "DROP_DOWN", + options: [ + { + label: "输入框", + value: "input", + }, + { + label: "开关", + value: "switch", + }, + { + label: "单选框", + value: "radio", + }, + { + label: "复选框", + value: "checkbox", + }, + { + label: "选择框", + value: "picker", + }, + { + label: "省市区选择", + value: "address", + }, + { + label: "数字输入框", + value: "stepper", + }, + { + label: "评分", + value: "rate", + }, + { + label: "文件上传", + value: "uploader", + }, + ], + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "inputType", + label: "输入类型", + controlType: "RADIO", + options: [ + { + label: "文本", + value: "text", + }, + { + label: "数字", + value: "digit", + }, + { + label: "整数", + value: "number", + }, + { + label: "身份证号", + value: "idcard", + }, + { + label: "密码", + value: "password", + }, + ], + columns: 3, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["fieldsObj"], + hidden: (props: MFormWidgetProps, propertyPath: string) => + noMeSubField(props, propertyPath, "fieldType", "input"), + }, + // { + // propertyName: "rateCount", + // label: "总分", + // controlType: "INPUT_TEXT", + // isBindProperty: true, + // isTriggerProperty: false, + // validation: { + // type: ValidationTypes.NUMBER, + // params: { natural: true }, + // }, + // dependencies: ["fieldsObj"], + // hidden: (props: MFormWidgetProps, propertyPath: string) => + // noMeSubField(props, propertyPath, "fieldType", "rate"), + // }, + { + propertyName: "options", + label: "可选项", + controlType: "INPUT_TEXT", + placeholderText: '[{"label": "", "value": ""}]', + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.ARRAY, + params: { + unique: ["value"], + default: [], + children: { + type: ValidationTypes.OBJECT, + params: { + allowedKeys: [ + { + name: "label", + type: ValidationTypes.TEXT, + params: { + default: "", + required: true, + }, + }, + { + name: "value", + type: ValidationTypes.TEXT, + params: { + default: "", + required: true, + }, + }, + ], + }, + }, + }, + }, + evaluationSubstitutionType: + EvaluationSubstitutionType.SMART_SUBSTITUTE, + dependencies: ["fieldsObj"], + hidden: (props: MFormWidgetProps, propertyPath: string) => + noMeSubField(props, propertyPath, "fieldType", [ + "radio", + "checkbox", + "picker", + ]), + }, + { + propertyName: "placeholder", + label: "缺省提示", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["fieldsObj"], + hidden: (props: MFormWidgetProps, propertyPath: string) => + noMeSubField(props, propertyPath, "fieldType", [ + "input", + "picker", + "address", + ]), + }, + { + propertyName: "uploadMax", + label: "上传文件数量限制", + controlType: "INPUT_TEXT", + placeholderText: "1", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.NUMBER, + params: { natural: true, default: 1 }, + }, + dependencies: ["fieldsObj"], + hidden: (props: MFormWidgetProps, propertyPath: string) => + noMeSubField( + props, + propertyPath, + "fieldType", + "uploader" + ), + }, + ], + }, + ], + }, + }, + ], + }, + { + sectionName: "属性", + children: [ + { + propertyName: "defaultValues", + label: "表单默认值", + controlType: "INPUT_TEXT", + placeholderText: "{{ { name: '张三' } }}", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.OBJECT, + }, + }, + { + propertyName: "buttonText", + label: "提交按钮文本", + controlType: "INPUT_TEXT", + placeholderText: "提交", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.TEXT, + }, + }, + { + propertyName: "inset", + label: "圆角卡片风格", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "themeColor", + label: "主题颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + propertyName: "onSubmit", + label: "onSubmit", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + static getMetaPropertiesMap(): Record { + return { + formData: undefined, + }; + } + + onFormSubmit = (data: any) => { + if (this.props.onSubmit) { + this.setState({ + isLoading: true, + }); + this.props.updateWidgetMetaProperty("formData", data, { + triggerPropertyName: "onSubmit", + dynamicString: this.props.onSubmit, + event: { + type: EventType.ON_SUBMIT, + callback: this.handleActionComplete, + }, + }); + } + }; + + handleActionComplete = () => { + this.setState({ + isLoading: false, + }); + }; + + getFields = () => { + const fields: any[] = Object.values(this.props.fieldsObj || {}); + if (fields.length) { + return fields.sort((field1, field2) => field1.index - field2.index); + } + return []; + }; + + getPageView() { + return ( + + ); + } + + getWidgetType(): WidgetType { + return "TARO_FORM_WIDGET"; + } +} + +export interface MFormWidgetProps + extends WidgetProps, + FormComponentProps, + WithMeta {} + +export default MFormWidget; +export const MProfiledFormWidget = withMeta(MFormWidget); diff --git a/app/taro/src/widgets/taro/GridWidget.tsx b/app/taro/src/widgets/taro/GridWidget.tsx new file mode 100644 index 0000000000..ec9ebd4fe1 --- /dev/null +++ b/app/taro/src/widgets/taro/GridWidget.tsx @@ -0,0 +1,342 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType, WidgetTypes } from "constants/WidgetConstants"; +import GridComponent, { + GridComponentProps, +} from "components/designSystems/taro/GridComponent"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import { View } from "@tarojs/components"; +import { Skeleton } from "@taroify/core"; +import { styled } from "linaria/react"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import withMeta, { WithMeta } from "../MetaHOC"; + +const LoadingContainer = styled(View)<{ + cols?: number; +}>` + display: grid; + height: 100%; + gap: 4px; + grid-template-columns: repeat(${(props) => props.cols || 2}, 1fr); + + & .taroify-skeleton { + width: 100%; + height: 100%; + border-radius: 4px; + } +`; + +class GridWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + helpText: "数组,通过 {{}} 进行数据绑定", + propertyName: "list", + label: "数据", + controlType: "INPUT_TEXT", + placeholderText: '[{ "url": "", title: "" }]', + inputType: "ARRAY", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.OBJECT_ARRAY, + params: { + default: [], + }, + }, + evaluationSubstitutionType: + EvaluationSubstitutionType.SMART_SUBSTITUTE, + }, + { + propertyName: "gridType", + label: "内容类型", + controlType: "DROP_DOWN", + options: [ + { + label: "图片+标题", + value: "I_N", + }, + { + label: "图片+标题+描述", + value: "I_N_D", + }, + { + label: "图片+标题+描述+按钮", + value: "I_N_D_B", + }, + ], + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "urlKey", + label: "图片字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "badgeKey", + label: "红点字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "titleKey", + label: "标题字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "descriptionKey", + label: "描述字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["gridType"], + hidden: (props: GridWidgetProps) => { + return props.gridType === "I_N"; + }, + }, + { + propertyName: "asPrice", + label: "描述是价格", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + dependencies: ["gridType"], + hidden: (props: GridWidgetProps) => { + return props.gridType === "I_N"; + }, + }, + { + propertyName: "priceUnit", + label: "价格单位符号", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["gridType", "asPrice"], + hidden: (props: GridWidgetProps) => { + return props.gridType === "I_N" || !props.asPrice; + }, + }, + { + propertyName: "buttonText", + label: "按钮文本", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["gridType"], + hidden: (props: GridWidgetProps) => { + return props.gridType !== "I_N_D_B"; + }, + }, + ], + }, + { + sectionName: "样式", + children: [ + { + propertyName: "height", + label: "图片高度", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "width", + label: "图片宽度", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "cols", + label: "列数", + controlType: "INPUT_TEXT", + placeholderText: "网格显示多少列", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.NUMBER, + params: { min: 2, default: 4 }, + }, + }, + { + propertyName: "gutter", + label: "网格间距", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "bordered", + label: "是否显示边框", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "titleColor", + label: "标题颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "descriptionColor", + label: "描述颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + dependencies: ["gridType"], + hidden: (props: GridWidgetProps) => { + return props.gridType === "I_N"; + }, + }, + { + propertyName: "buttonColor", + label: "按钮颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + dependencies: ["gridType"], + hidden: (props: GridWidgetProps) => { + return props.gridType !== "I_N_D_B"; + }, + }, + ], + }, + { + sectionName: "空数据样式", + children: [ + { + propertyName: "emptyPic", + label: "空数据图片", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "emptyText", + label: "空数据文案", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "点击单元格时触发", + propertyName: "onItemClicked", + label: "onItemClicked", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + { + helpText: "点击单元格按钮时触发", + propertyName: "onItemButtonClicked", + label: "onItemButtonClicked", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + dependencies: ["gridType"], + hidden: (props: GridWidgetProps) => { + return props.gridType !== "I_N_D_B"; + }, + }, + ], + }, + ]; + } + + static getMetaPropertiesMap(): Record { + return { + currentItem: undefined, + }; + } + + onCurrentItemChanged = (item: any, type: "ITEM" | "BUTTON") => { + const actionName = + type === "ITEM" ? "onItemClicked" : "onItemButtonClicked"; + const actionScript = this.props[actionName]; + this.props.updateWidgetMetaProperty("currentItem", item, { + triggerPropertyName: actionName, + dynamicString: actionScript, + event: { + type: EventType.ON_CLICK, + }, + }); + }; + + runAction = (dynamicString: string) => { + if (dynamicString) { + super.executeAction({ + triggerPropertyName: "onClick", + dynamicString, + event: { + type: EventType.ON_CLICK, + }, + }); + } + }; + + getPageView() { + const { cols, isLoading } = this.props; + + if (isLoading) { + return ( + + {Array.from(Array((cols || 2) * 3)).map((a, i) => ( + + ))} + + ); + } + + return ( + + ); + } + + getWidgetType(): WidgetType { + return WidgetTypes.TARO_GRID_WIDGET; + } +} + +export interface GridWidgetProps + extends WidgetProps, + GridComponentProps, + WithMeta {} + +export default GridWidget; +export const ProfiledGridWidget = withMeta(GridWidget); diff --git a/app/taro/src/widgets/taro/HtmlWidget.tsx b/app/taro/src/widgets/taro/HtmlWidget.tsx new file mode 100644 index 0000000000..2ddf9deb24 --- /dev/null +++ b/app/taro/src/widgets/taro/HtmlWidget.tsx @@ -0,0 +1,62 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { ScrollView, RichText } from "@tarojs/components"; +import { WidgetType } from "constants/WidgetConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { styled } from "linaria/react"; + +const Container = styled(ScrollView)` + width: 100%; + height: 100%; + & img { + width: 100%; + } + & p { + margin: 0; + } +`; + +class MHtmlWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "content", + label: "HTML内容", + controlType: "INPUT_TEXT", + placeholderText: "输入HTML格式内容", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + ]; + } + + getPageView() { + const { content } = this.props; + const unitContent = content + .replace(/\d+px/g, (size) => `${parseInt(size) * 0.8}px`) + .replace(/

/g, '

') + .replace(/ + + + ); + } + + getWidgetType(): WidgetType { + return "TARO_HTML_WIDGET"; + } +} + +export interface MHtmlWidgetProps extends WidgetProps { + content: string; +} + +export default MHtmlWidget; +export const MProfiledHtmlWidget = MHtmlWidget; diff --git a/app/taro/src/widgets/taro/ImageWidget.tsx b/app/taro/src/widgets/taro/ImageWidget.tsx new file mode 100644 index 0000000000..134e314944 --- /dev/null +++ b/app/taro/src/widgets/taro/ImageWidget.tsx @@ -0,0 +1,125 @@ +import * as React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import ImageComponent from "components/designSystems/taro/ImageComponent"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import LoadingWrapper from "./LoadingWrapper"; + +class MImageWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "src", + label: "图片地址", + controlType: "INPUT_TEXT", + placeholderText: "输入图片地址", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.IMAGE_URL }, + }, + { + helpText: "设置图片填充父容器的方式", + propertyName: "mode", + label: "图片填充方式", + controlType: "DROP_DOWN", + defaultValue: "aspectFill", + options: [ + { + label: "封面模式,保持原始比例", + value: "aspectFill", + }, + { + label: "填充模式,不保持原始比例", + value: "scaleToFill", + }, + { + label: "包含模式,保持原始比例", + value: "aspectFit", + }, + ], + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "radius", + label: "圆角大小(默认单位 px)", + controlType: "INPUT_TEXT", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + helpText: "控制组件显示/隐藏", + propertyName: "isVisible", + label: "是否可见", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "当用户点击图片时触发", + propertyName: "onClick", + label: "onClick", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + getPageView() { + const { src, onClick, mode, radius, isLoading } = this.props; + return ( + + + + ); + } + + onImageClick = () => { + if (this.props.onClick) { + super.executeAction({ + triggerPropertyName: "onClick", + dynamicString: this.props.onClick, + event: { + type: EventType.ON_CLICK, + }, + }); + } + }; + + getWidgetType(): WidgetType { + return "TARO_IMAGE_WIDGET"; + } +} + +export type ImageFillMode = "aspectFill" | "scaleToFill" | "aspectFit"; + +export interface MImageWidgetProps extends WidgetProps { + src: string; + mode: ImageFillMode; + radius?: string; + onClick?: string; +} + +export default MImageWidget; +export const MProfiledImageWidget = MImageWidget; diff --git a/app/taro/src/widgets/taro/KVWidget.tsx b/app/taro/src/widgets/taro/KVWidget.tsx new file mode 100644 index 0000000000..b4b0a9a9ec --- /dev/null +++ b/app/taro/src/widgets/taro/KVWidget.tsx @@ -0,0 +1,306 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import KVComponent from "components/designSystems/taro/KVComponent"; +import { ValidationTypes } from "constants/WidgetValidation"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import LoadingWrapper from "./LoadingWrapper"; + +const textSizeOptions = [ + { + label: "一级标题", + value: "HEADING1", + subText: "24px", + icon: "HEADING_ONE", + }, + { + label: "二级标题", + value: "HEADING2", + subText: "18px", + icon: "HEADING_TWO", + }, + { + label: "三级标题", + value: "HEADING3", + subText: "16px", + icon: "HEADING_THREE", + }, + { + label: "一级段落", + value: "PARAGRAPH", + subText: "14px", + icon: "PARAGRAPH", + }, + { + label: "二级段落", + value: "PARAGRAPH2", + subText: "12px", + icon: "PARAGRAPH_TWO", + }, +]; + +const textAlignOptions = [ + { + icon: "LEFT_ALIGN", + value: "LEFT", + }, + { + icon: "CENTER_ALIGN", + value: "CENTER", + }, + { + icon: "RIGHT_ALIGN", + value: "RIGHT", + }, +]; + +const demoLayoutProps: any = { + list: [ + { + key: "晚来天欲雪", + value: "能饮一杯无", + }, + ], + kKey: "key", + vKey: "value", + layout: "v", + inset: false, + kColor: "#999", + kSize: "PARAGRAPH", + kBold: false, + kAlign: "LEFT", + vColor: "#000", + vSize: "PARAGRAPH", + vBold: false, + vAlign: "LEFT", + style: { + borderRadius: "4px", + padding: "1px 12px", + marginBottom: "8px", + background: "#f7f8f9", + border: "2px solid #ccc", + }, +}; + +class MKVWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + helpText: "数组,通过 {{}} 进行数据绑定", + propertyName: "list", + label: "数据", + controlType: "INPUT_TEXT", + placeholderText: '[{ "a": "1", b: "2" }]', + inputType: "ARRAY", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.OBJECT_ARRAY, + params: { + default: [], + }, + }, + evaluationSubstitutionType: + EvaluationSubstitutionType.SMART_SUBSTITUTE, + }, + { + propertyName: "kKey", + label: "键字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "vKey", + label: "值字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + { + sectionName: "样式", + children: [ + { + propertyName: "inset", + label: "圆角风格背景", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "layout", + label: "布局", + controlType: "RADIO", + options: [ + { + label: , + value: "v", + }, + { + label: , + value: "h", + }, + { + label: , + value: "hb", + }, + ], + columns: 1, + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "showLoading", + label: "数据加载时显示加载动画", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "键样式", + children: [ + { + propertyName: "kColor", + label: "颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "kSize", + label: "字体大小", + controlType: "DROP_DOWN", + options: textSizeOptions, + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "kBold", + label: "粗体", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "kAlign", + label: "文字对齐", + controlType: "ICON_TABS", + options: textAlignOptions, + defaultValue: "LEFT", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + { + sectionName: "值样式", + children: [ + { + propertyName: "vColor", + label: "颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "vSize", + label: "字体大小", + controlType: "DROP_DOWN", + options: textSizeOptions, + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "vBold", + label: "粗体", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "vAlign", + label: "文字对齐", + controlType: "ICON_TABS", + options: textAlignOptions, + defaultValue: "LEFT", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + ]; + } + + getPageView() { + const { + list, + kKey, + vKey, + inset, + layout, + kColor, + kSize, + kBold, + kAlign, + vColor, + vSize, + vBold, + vAlign, + isLoading, + showLoading, + } = this.props; + return ( + + + + ); + } + + getWidgetType(): WidgetType { + return "TARO_KV_WIDGET"; + } +} + +export interface MKVWidgetProps extends WidgetProps, WithMeta { + list: any[]; + kKey: string; + vKey: string; + inset?: boolean; + layout: "h" | "hb" | "v"; +} + +export default MKVWidget; +export const MProfiledKVWidget = withMeta(MKVWidget); diff --git a/app/taro/src/widgets/taro/ListWidget.tsx b/app/taro/src/widgets/taro/ListWidget.tsx new file mode 100644 index 0000000000..6f39948449 --- /dev/null +++ b/app/taro/src/widgets/taro/ListWidget.tsx @@ -0,0 +1,480 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType, WidgetTypes } from "constants/WidgetConstants"; +import ListComponent, { + ListComponentProps, +} from "components/designSystems/taro/ListComponent"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { DerivedPropertiesMap } from "utils/WidgetFactory"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import { View } from "@tarojs/components"; +import { Skeleton } from "@taroify/core"; +import { styled } from 'linaria/react'; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import withMeta, { WithMeta } from "../MetaHOC"; + +const LoadingContainer = styled(View)` + height: 100%; + overflow: hidden; + + & .taroify-skeleton { + width: 100%; + height: 100px; + border-radius: 4px; + margin: 20px 0; + } +`; + +class ListWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + helpText: "数组,通过 {{}} 进行数据绑定", + propertyName: "list", + label: "数据", + controlType: "INPUT_TEXT", + placeholderText: '[{ "url": "", name: "" }]', + inputType: "ARRAY", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.OBJECT_ARRAY, + params: { + default: [], + }, + }, + evaluationSubstitutionType: + EvaluationSubstitutionType.SMART_SUBSTITUTE, + }, + { + propertyName: "contentType", + label: "内容类型", + controlType: "DROP_DOWN", + options: [ + { + label: "图片+标题+描述", + value: "I_N_D", + }, + { + label: "图片+标题+描述+价格", + value: "I_N_D_P", + }, + { + label: "图片+标题+描述+价格+控件", + value: "I_N_D_P_B", + }, + ], + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "checkedKey", + label: "勾选字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["enableCheckbox"], + hidden: (props: MListWidgetProps) => { + return !props.enableCheckbox; + }, + }, + { + propertyName: "urlKey", + label: "图片字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "titleKey", + label: "标题字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "descriptionKey", + label: "描述字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "priceKey", + label: "价格字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["contentType"], + hidden: (props: MListWidgetProps) => { + return props.contentType === "I_N_D"; + }, + }, + { + propertyName: "controlType", + label: "控件类型", + controlType: "RADIO", + options: [ + { + label: "文字", + value: "TEXT", + }, + { + label: "按钮", + value: "BUTTON", + }, + { + label: "数字输入", + value: "STEPPER", + }, + ], + columns: 3, + defaultValue: "BUTTON", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["contentType"], + hidden: (props: MListWidgetProps) => { + return props.contentType !== "I_N_D_P_B"; + }, + }, + { + propertyName: "controlTextKey", + label: "文字控件字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["contentType", "controlType"], + hidden: (props: MListWidgetProps) => { + return !( + props.contentType === "I_N_D_P_B" && + props.controlType === "TEXT" + ); + }, + }, + { + propertyName: "buttonText", + label: "按钮文本", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["contentType", "controlType"], + hidden: (props: MListWidgetProps) => { + return !( + props.contentType === "I_N_D_P_B" && + props.controlType === "BUTTON" + ); + }, + }, + { + propertyName: "defaultNumKey", + label: "数字输入字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + dependencies: ["contentType", "controlType"], + hidden: (props: MListWidgetProps) => { + return !( + props.contentType === "I_N_D_P_B" && + props.controlType === "STEPPER" + ); + }, + }, + { + propertyName: "enableCheckbox", + label: "显示复选框", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "enableSwipe", + label: "滑动删除", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "样式", + children: [ + { + propertyName: "showLoading", + label: "数据加载时显示加载动画", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "inset", + label: "圆角风格", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "width", + label: "图片宽度", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "height", + label: "图片高度", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "titleColor", + label: "标题颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "descriptionColor", + label: "描述颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "priceColor", + label: "价格颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + dependencies: ["contentType"], + hidden: (props: MListWidgetProps) => { + return props.contentType === "I_N_D"; + }, + }, + { + propertyName: "textColor", + label: "文本控件颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + dependencies: ["contentType", "controlType"], + hidden: (props: MListWidgetProps) => { + return !( + props.contentType === "I_N_D_P_B" && + props.controlType === "TEXT" + ); + }, + }, + { + propertyName: "buttonColor", + label: "按钮颜色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + dependencies: ["contentType", "controlType"], + hidden: (props: MListWidgetProps) => { + return !( + props.contentType === "I_N_D_P_B" && + props.controlType === "BUTTON" + ); + }, + }, + ], + }, + { + sectionName: "空数据样式", + children: [ + { + propertyName: "emptyPic", + label: "空数据图片", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "emptyText", + label: "空数据文案", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "勾选行时触发", + propertyName: "onItemChecked", + label: "onItemChecked", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + dependencies: ["enableCheckbox"], + hidden: (props: MListWidgetProps) => { + return !props.enableCheckbox; + }, + }, + { + helpText: "删除行时触发", + propertyName: "onDeleteClicked", + label: "onDeleteClicked", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + dependencies: ["enableSwipe"], + hidden: (props: MListWidgetProps) => { + return !props.enableSwipe; + }, + }, + { + helpText: "点击行时触发", + propertyName: "onItemClicked", + label: "onItemClicked", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + { + helpText: "点击行按钮时触发", + propertyName: "onItemButtonClicked", + label: "onItemButtonClicked", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + dependencies: ["contentType", "controlType"], + hidden: (props: MListWidgetProps) => { + return !( + props.contentType === "I_N_D_P_B" && + props.controlType === "BUTTON" + ); + }, + }, + { + helpText: "数字输入变化时触发", + propertyName: "onItemStepperChanged", + label: "onItemStepperChanged", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + dependencies: ["contentType", "controlType"], + hidden: (props: MListWidgetProps) => { + return !( + props.contentType === "I_N_D_P_B" && + props.controlType === "STEPPER" + ); + }, + }, + ], + }, + ]; + } + + static getDerivedPropertiesMap(): DerivedPropertiesMap { + return { + data: `{{this.list}}`, + }; + } + + static getMetaPropertiesMap(): Record { + return { + currentItem: undefined, + data: [], + }; + } + + onCurrentItemChanged = ( + item: any, + type: "ITEM" | "BUTTON" | "STEPPER" | "CHECKBOX" | "DELETE", + ) => { + let actionName = "onItemClicked"; + if (type === "BUTTON") { + actionName = "onItemButtonClicked"; + } else if (type === "STEPPER") { + actionName = "onItemStepperChanged"; + } else if (type === "CHECKBOX") { + actionName = "onItemChecked"; + } else if (type === "DELETE") { + actionName = "onDeleteClicked"; + } + const actionScript = this.props[actionName]; + this.props.updateWidgetMetaProperty("currentItem", item, { + triggerPropertyName: actionName, + dynamicString: actionScript, + event: { + type: EventType.ON_CLICK, + }, + }); + }; + + runAction = (dynamicString: string) => { + if (dynamicString) { + super.executeAction({ + triggerPropertyName: "onClick", + dynamicString, + event: { + type: EventType.ON_CLICK, + }, + }); + } + }; + + getPageView() { + const { isLoading, showLoading } = this.props; + + if (isLoading && showLoading) { + return ( + + {Array.from(Array(6)).map((a, i) => ( + + ))} + + ); + } + + return ( + + ); + } + + getWidgetType(): WidgetType { + return WidgetTypes.TARO_LIST_WIDGET; + } +} + +export interface MListWidgetProps + extends WidgetProps, + ListComponentProps, + WithMeta {} + +export default ListWidget; +export const MProfiledListWidget = withMeta(ListWidget); diff --git a/app/taro/src/widgets/taro/LoadingWidget.tsx b/app/taro/src/widgets/taro/LoadingWidget.tsx new file mode 100644 index 0000000000..18b0295164 --- /dev/null +++ b/app/taro/src/widgets/taro/LoadingWidget.tsx @@ -0,0 +1,85 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { Backdrop, Loading } from "@taroify/core"; +import { View } from "@tarojs/components"; +import { WidgetType } from "constants/WidgetConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { styled } from 'linaria/react'; + +const BackdropBox = styled(Backdrop)` + display: flex; + align-items: center; + justify-content: center; + --backdrop-background-color: transparent; +`; + +const LoadingContainer = styled(View)` + width: 150px; + height: 150px; + padding: 12px; + border-radius: 6px; + background: #000000bd; + backdrop-filter: blur(5px); + display: flex; + align-items: center; + justify-content: center; + --loading-color: #fff; + --loading-text-color: #fff; +`; + +class MLoadingWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "showLoading", + label: "显示加载中", + controlType: "SWITCH", + helpText: "用于绑定动作的运行状态", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "loadingText", + label: "加载文案", + controlType: "INPUT_TEXT", + placeholderText: "加载中...", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + ]; + } + + getBackdrop = () => { + const { showLoading, loadingText, isLoading } = this.props; + return ( + + + {loadingText || "加载中..."} + + + ); + }; + + getPageView() { + return this.getBackdrop(); + } + + getWidgetType(): WidgetType { + return "TARO_LOADING_WIDGET"; + } +} + +export interface MLoadingWidgetProps extends WidgetProps { + showLoading?: boolean; +} + +export default MLoadingWidget; +export const MProfiledLoadingWidget = MLoadingWidget; diff --git a/app/taro/src/widgets/taro/LoadingWrapper.tsx b/app/taro/src/widgets/taro/LoadingWrapper.tsx new file mode 100644 index 0000000000..0e873e56d5 --- /dev/null +++ b/app/taro/src/widgets/taro/LoadingWrapper.tsx @@ -0,0 +1,18 @@ +import React from "react"; +import { Skeleton } from "@taroify/core"; +import { styled } from 'linaria/react'; + +const Loading = styled(Skeleton)` + width: 100%; + height: 100%; + border-radius: 4px; +`; + +const Wrapper = ({ isLoading, children }: Record) => { + if (isLoading) { + return ; + } + return children; +}; + +export default Wrapper; diff --git a/app/taro/src/widgets/taro/PickerWidget.tsx b/app/taro/src/widgets/taro/PickerWidget.tsx new file mode 100644 index 0000000000..0059ac1b27 --- /dev/null +++ b/app/taro/src/widgets/taro/PickerWidget.tsx @@ -0,0 +1,80 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType, WidgetTypes } from "constants/WidgetConstants"; +import PickerComponent from "components/designSystems/taro/PickerComponent"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import withMeta, { WithMeta } from "../MetaHOC"; + +class PickerWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "title", + label: "这是什么", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + propertyName: "onTap", + label: "被点击后执行", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + onButtonClick = (e: any) => { + if (this.props.onTap) { + super.executeAction({ + triggerPropertyName: "onTap", + dynamicString: this.props.onTap, + event: { + type: EventType.ON_CLICK, + }, + }); + } + }; + + static getMetaPropertiesMap(): Record { + return {}; + } + + getPageView() { + const { title } = this.props; + return ( + + ); + } + + getWidgetType(): WidgetType { + return WidgetTypes.TARO_PICKER_WIDGET; + } +} + +export interface PickerWidgetProps extends WidgetProps, WithMeta { + title?: string; + onTap?: string; +} + +export default PickerWidget; +export const ProfiledPickerWidget = withMeta(PickerWidget); diff --git a/app/taro/src/widgets/taro/PopupWidget.tsx b/app/taro/src/widgets/taro/PopupWidget.tsx new file mode 100644 index 0000000000..ad20c9864a --- /dev/null +++ b/app/taro/src/widgets/taro/PopupWidget.tsx @@ -0,0 +1,151 @@ +import React, { ReactNode } from "react"; +import { connect } from "react-redux"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import WidgetFactory from "utils/WidgetFactory"; +import { ValidationTypes } from "constants/WidgetValidation"; +import ModalComponent from "components/designSystems/taro/PopoverComponent"; +import { + WidgetTypes, + RenderMode, + MAIN_CONTAINER_WIDGET_ID, +} from "constants/WidgetConstants"; +import { generateClassName } from "utils/generators"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { AppState } from "reducers"; +import { getWidget } from "sagas/selectors"; + +export class MPopupWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "height", + label: "弹窗高度(不带单位的数字)", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.NUMBER, + params: { min: 200, max: 800 }, + }, + }, + { + propertyName: "canOutsideClickClose", + label: "点击背景关闭", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "rounded", + label: "圆角风格", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "弹窗关闭后触发", + propertyName: "onClose", + label: "onClose", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + getModalWidth() { + return this.props.mainContainer.rightColumn; + } + + renderChildWidget = (childWidgetData: WidgetProps): ReactNode => { + childWidgetData.parentId = this.props.widgetId; + childWidgetData.shouldScrollContents = false; + childWidgetData.canExtend = false; + childWidgetData.bottomRow = this.props.height; + childWidgetData.isVisible = this.props.isVisible; + childWidgetData.containerStyle = "none"; + childWidgetData.minHeight = this.props.height; + childWidgetData.rightColumn = this.getModalWidth(); + return WidgetFactory.createWidget(childWidgetData, this.props.renderMode); + }; + + onModalClose = () => { + if (this.props.onClose) { + super.executeAction({ + triggerPropertyName: "onClose", + dynamicString: this.props.onClose, + event: { + type: EventType.ON_MODAL_CLOSE, + }, + }); + } + }; + + closeModal = () => { + this.props.updateWidgetMetaProperty("isVisible", false); + }; + + getChildren(): ReactNode { + if (this.props.children && this.props.children.length > 0) { + const children = this.props.children.filter(Boolean); + return children.length > 0 && children.map(this.renderChildWidget); + } + } + + makeModalComponent(content: ReactNode) { + return ( + + {content} + + ); + } + + getPageView() { + const children = this.getChildren(); + return this.makeModalComponent(children); + } + + getWidgetType() { + return WidgetTypes.TARO_POPUP_WIDGET; + } +} + +export interface MPopupWidgetProps extends WidgetProps, WithMeta { + renderMode: RenderMode; + children?: WidgetProps[]; + canOutsideClickClose?: boolean; + rounded?: boolean; + height: number; + onClose: string; + mainContainer: WidgetProps; +} + +const mapStateToProps = (state: AppState) => { + return { + mainContainer: getWidget(state, MAIN_CONTAINER_WIDGET_ID), + }; +}; +export default MPopupWidget; +export const MProfiledPopupWidget = connect(mapStateToProps)( + withMeta(MPopupWidget) +); diff --git a/app/taro/src/widgets/taro/SearchWidget.tsx b/app/taro/src/widgets/taro/SearchWidget.tsx new file mode 100644 index 0000000000..77faa74de2 --- /dev/null +++ b/app/taro/src/widgets/taro/SearchWidget.tsx @@ -0,0 +1,198 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { View } from "@tarojs/components"; +import { Search } from "@taroify/core"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import { WidgetType } from "constants/WidgetConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import withMeta, { WithMeta } from "../MetaHOC"; + +class MSearchWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "placeholder", + label: "占位提示", + controlType: "INPUT_TEXT", + placeholderText: "输入为空时显示提示信息", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "rounded", + label: "圆角风格", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "showButton", + label: "显示搜索按钮", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "readonly", + label: "只读模式", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "inputAlign", + label: "文本对齐", + controlType: "RADIO", + options: [ + { + label: "左对齐", + value: "left", + }, + { + label: "居中", + value: "center", + }, + { + label: "右对齐", + value: "right", + }, + ], + columns: 3, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "输入内容变化时触发", + propertyName: "onTextChanged", + label: "onTextChanged", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + { + helpText: "确定搜索时触发 (点击键盘上的搜索/回车按钮)", + propertyName: "onSearch", + label: "onSearch", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + { + helpText: "点击搜索框时触发", + propertyName: "onClick", + label: "onClick", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + static getMetaPropertiesMap(): Record { + return { + text: undefined, + }; + } + + onValueChange = (value: string) => { + this.props.updateWidgetMetaProperty("text", value, { + triggerPropertyName: "onTextChanged", + dynamicString: this.props.onTextChanged, + event: { + type: EventType.ON_TEXT_CHANGE, + }, + }); + }; + + onSearch = () => { + if (this.props.onSearch) { + super.executeAction({ + triggerPropertyName: "onSearch", + dynamicString: this.props.onSearch, + event: { + type: EventType.ON_SEARCH, + }, + }); + } + }; + + onClick = () => { + if (this.props.onClick) { + super.executeAction({ + triggerPropertyName: "onClick", + dynamicString: this.props.onClick, + event: { + type: EventType.ON_CLICK, + }, + }); + } + }; + + getPageView() { + const { + text, + placeholder, + rounded, + inputAlign, + readonly, + showButton, + } = this.props; + const actionButton = showButton ? ( + 搜索 + ) : null; + + return ( + + this.onValueChange("")} + onChange={(e) => this.onValueChange(e.detail.value)} + onSearch={this.onSearch} + /> + + ); + } + + getWidgetType(): WidgetType { + return "TARO_SEARCH_WIDGET"; + } +} + +export interface MSearchWidgetProps extends WidgetProps, WithMeta { + text: string; + rounded?: boolean; + showButton?: boolean; + readonly?: boolean; + placeholder?: string; + inputAlign?: "left" | "center" | "right"; + onTextChanged?: string; + onSearch?: string; + onClick?: string; +} + +export default MSearchWidget; +export const MProfiledSearchWidget = withMeta(MSearchWidget); diff --git a/app/taro/src/widgets/taro/SkuWidget.tsx b/app/taro/src/widgets/taro/SkuWidget.tsx new file mode 100644 index 0000000000..52955252a7 --- /dev/null +++ b/app/taro/src/widgets/taro/SkuWidget.tsx @@ -0,0 +1,388 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import SkuComponent from "components/designSystems/taro/SkuComponent"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import { ValidationTypes } from "constants/WidgetValidation"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import _ from "lodash"; +import Taro from "@tarojs/taro"; + +export type CategoryValueItem = { + id: string; + name: string; + pic?: string; +}; + +export type Category = { + name: string; + key: string; + values: CategoryValueItem[]; +}; + +export type GoodsItem = { + id: string; + price: number; + stock: number; + category: Record; +}; + +class MSkuWidget extends BaseWidget { + state = { + addCartLoading: false, + buyLoading: false, + }; + + static getPropertyPaneConfig() { + return [ + { + sectionName: "数据", + children: [ + { + propertyName: "goodsId", + label: "商品ID", + controlType: "INPUT_TEXT", + placeholderText: "输入商品ID", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "price", + label: "价格", + controlType: "INPUT_TEXT", + placeholderText: "输入商品价格", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.NUMBER, + params: { min: 0 }, + }, + }, + { + propertyName: "pic", + label: "图片", + controlType: "INPUT_TEXT", + placeholderText: "输入商品图片地址", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "stockNum", + label: "库存", + controlType: "INPUT_TEXT", + placeholderText: "输入商品总库存", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.NUMBER, + params: { min: 0, natural: true }, + }, + }, + { + propertyName: "categories", + label: "商品规格", + controlType: "INPUT_TEXT", + inputType: "ARRAY", + helpText: + "每种规格必须包含字段:name(名称), key(键值), values(可选值)", + placeholderText: "商品规格列表", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.ARRAY, + params: { + children: { + type: ValidationTypes.OBJECT, + params: { + required: true, + allowedKeys: [ + { + name: "name", + type: ValidationTypes.TEXT, + params: { + required: true, + }, + }, + { + name: "key", + type: ValidationTypes.TEXT, + params: { + required: true, + }, + }, + { + name: "values", + type: ValidationTypes.ARRAY, + params: { + children: { + type: ValidationTypes.OBJECT, + params: { + required: true, + allowedKeys: [ + { + name: "id", + type: ValidationTypes.TEXT, + params: { + required: true, + }, + }, + { + name: "name", + type: ValidationTypes.TEXT, + params: { + required: true, + }, + }, + { + name: "pic", + type: ValidationTypes.TEXT, + }, + ], + }, + }, + }, + }, + ], + }, + }, + }, + }, + evaluationSubstitutionType: + EvaluationSubstitutionType.SMART_SUBSTITUTE, + }, + { + propertyName: "products", + label: "商品库存", + controlType: "INPUT_TEXT", + inputType: "ARRAY", + helpText: + "每件商品必须包含字段:id, price(价格), stock(库存), category(规格值)", + placeholderText: "所有库存商品列表", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.ARRAY, + params: { + children: { + type: ValidationTypes.OBJECT, + params: { + required: true, + allowedKeys: [ + { + name: "id", + type: ValidationTypes.TEXT, + params: { + required: true, + }, + }, + { + name: "price", + type: ValidationTypes.NUMBER, + params: { + required: true, + min: 0, + }, + }, + { + name: "stock", + type: ValidationTypes.NUMBER, + params: { + required: true, + min: 0, + }, + }, + { + name: "category", + type: ValidationTypes.OBJECT, + params: { + required: true, + }, + }, + ], + }, + }, + }, + }, + evaluationSubstitutionType: + EvaluationSubstitutionType.SMART_SUBSTITUTE, + }, + ], + }, + { + sectionName: "样式", + children: [ + { + propertyName: "color", + label: "主题色", + controlType: "COLOR_PICKER", + isBindProperty: false, + isTriggerProperty: false, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + propertyName: "onAddCart", + label: "点击加入购物车", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + { + propertyName: "onBuy", + label: "点击立即购买", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + static getMetaPropertiesMap(): Record { + return { + submitData: undefined, + selectedSku: undefined, + }; + } + + onSubmit = (actionName: string) => (data: any) => { + const isBuy = actionName === "onBuy"; + if (isBuy && this.props.onBuy) { + this.setState({ + buyLoading: true, + }); + } + if (!isBuy && this.props.onAddCart) { + this.setState({ + addCartLoading: true, + }); + } + this.props.updateWidgetMetaProperty("submitData", data, { + triggerPropertyName: actionName, + dynamicString: isBuy ? this.props.onBuy : this.props.onAddCart, + event: { + type: isBuy ? EventType.ON_BUY : EventType.ON_ADD_CART, + callback: this.handleActionComplete(actionName), + }, + }); + }; + + onSkuSelected = ({ skuValue, selectedSku, selectedSkuComb }: any) => { + // console.log(skuValue, selectedSku, selectedSkuComb); + }; + + handleActionComplete = (actionName: string) => (result: any) => { + this.setState({ + addCartLoading: false, + buyLoading: false, + }); + if (actionName === "onAddCart" && result?.success) { + Taro.showToast({ + title: "添加成功", + icon: "success", + }); + } + }; + + getPageView() { + const { + goodsId, + price, + pic, + stockNum, + categories, + products, + color, + } = this.props; + const { addCartLoading, buyLoading } = this.state; + const skuData = { + goods_id: goodsId, + goods_info: { + price: price, + picture: pic, + }, + sku: { + price: price, + stock_num: stockNum, + none_sku: false, + hide_stock: false, + tree: _.isArray(categories) + ? categories.map((cate: Category) => { + const { name, key, values } = cate || { + name: "", + key: "", + values: [], + }; + return { + k: name, + k_s: key, + v: _.isArray(values) + ? values.map((v: CategoryValueItem) => ({ + id: v?.id, + name: v?.name, + imgUrl: v?.pic, + })) + : [], + largeImageMode: + _.isArray(values) && values.some((v) => !!v?.pic), + }; + }) + : [], + list: _.isArray(products) + ? products.map((p: GoodsItem) => ({ + id: p?.id, + price: p?.price, + stock_num: p?.stock, + ...p?.category, + })) + : [], + }, + }; + return ( + + ); + } + + getWidgetType(): WidgetType { + return "TARO_SKU_WIDGET"; + } +} + +export interface MSkuWidgetProps extends WidgetProps, WithMeta { + goodsId: string; + price: number; + pic: string; + stockNum: number; + categories: Category[]; + products: GoodsItem[]; + color: string; + onAddCart: string; + onBuy: string; +} + +interface MSkuWidgetState extends WidgetState { + addCartLoading: boolean; + buyLoading: boolean; +} + +export default MSkuWidget; +export const MProfiledSkuWidget = withMeta(MSkuWidget); diff --git a/app/taro/src/widgets/taro/SwiperWidget.tsx b/app/taro/src/widgets/taro/SwiperWidget.tsx new file mode 100644 index 0000000000..db0ed4748c --- /dev/null +++ b/app/taro/src/widgets/taro/SwiperWidget.tsx @@ -0,0 +1,63 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType, WidgetTypes } from "constants/WidgetConstants"; +import SwiperComponent from "components/designSystems/taro/SwiperComponent"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import _ from "lodash"; + +class SwiperWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + helpText: "轮播数据列表,通过 {{}} 进行数据绑定", + propertyName: "list", + label: "数据", + controlType: "INPUT_TEXT", + placeholderText: '例如 [{ "url": "val1", link: "val2" }]', + inputType: "ARRAY", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.OBJECT_ARRAY, + params: { + default: [], + }, + }, + evaluationSubstitutionType: EvaluationSubstitutionType.SMART_SUBSTITUTE, + }, + { + propertyName: "urlKey", + label: "图片字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ]; + } + + getPageView() { + const { list, urlKey } = this.props; + return ( + + ); + } + + getWidgetType(): WidgetType { + return WidgetTypes.TARO_SWIPER_WIDGET; + } +} + +export interface SwiperWidgetProps extends WidgetProps { + list: any[]; + urlKey: string; +} + +export default SwiperWidget; +export const ProfiledSwiperWidget = SwiperWidget; diff --git a/app/taro/src/widgets/taro/TabsWidget.tsx b/app/taro/src/widgets/taro/TabsWidget.tsx new file mode 100644 index 0000000000..c45f7ccde3 --- /dev/null +++ b/app/taro/src/widgets/taro/TabsWidget.tsx @@ -0,0 +1,281 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType } from "constants/WidgetConstants"; +import NavTabComponent from "components/designSystems/taro/NavTabComponent"; +import { EventType } from "constants/AppsmithActionConstants/ActionConstants"; +import { + ValidationResponse, + ValidationTypes, +} from "constants/WidgetValidation"; +import withMeta, { WithMeta } from "../MetaHOC"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import _ from "lodash"; +import { View } from "@tarojs/components"; +import { Skeleton } from "@taroify/core"; +import { styled } from 'linaria/react'; + +const LoadingContainer = styled(View)<{ + direction: string; +}>` + display: flex; + height: 100%; + width: 100%; + flex-direction: ${(props) => (props.direction === "h" ? "row" : "column")}; + align-items: center; + overflow: hidden; + + & .taroify-skeleton { + width: ${(props) => (props.direction === "h" ? "80px" : "80%")}; + height: ${(props) => (props.direction === "h" ? "80%" : "40px")}; + border-radius: 4px; + flex-shrink: 0; + margin: 10px; + } +`; + +export function selectedTabValidation( + value: unknown, + props: MTabsWidgetProps, + _: any, +): ValidationResponse { + try { + let parsed = value; + let isValid = false; + + if (_.isString(value as string)) { + if (/^\d+$/.test(value as string)) { + parsed = Number(value); + isValid = true; + } else { + return { + isValid: false, + parsed: 0, + message: `索引值必须是非负整数`, + }; + } + } + + if (_.isNumber(value)) { + isValid = true; + } + + if (_.isArray(props.list) && Number(parsed) >= props.list.length) { + return { + isValid: false, + parsed, + message: `索引值超出数组范围`, + }; + } + + return { isValid, parsed }; + } catch (e) { + return { + isValid: false, + parsed: value, + message: `校验失败`, + }; + } +} + +class MTabsWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + helpText: "数组,通过 {{}} 进行数据绑定", + propertyName: "list", + label: "数据", + controlType: "INPUT_TEXT", + placeholderText: '[{ name: "标签" }]', + inputType: "ARRAY", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.OBJECT_ARRAY, + params: { + default: [], + }, + }, + evaluationSubstitutionType: + EvaluationSubstitutionType.SMART_SUBSTITUTE, + }, + { + propertyName: "nameKey", + label: "标题字段", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "defaultNum", + label: "默认选中索引(从 0 开始)", + controlType: "INPUT_TEXT", + isBindProperty: true, + isTriggerProperty: false, + validation: { + type: ValidationTypes.FUNCTION, + params: { + fn: selectedTabValidation, + expected: { + type: "数组索引(自然数)", + example: 0, + autocompleteDataType: "NUMBER", + }, + }, + }, + dependencies: ["list"], + }, + { + propertyName: "isVisible", + label: "是否可见", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + { + propertyName: "showLoading", + label: "数据加载时显示加载动画", + controlType: "SWITCH", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "动作", + children: [ + { + helpText: "选中标签页时触发", + propertyName: "onTabSelected", + label: "onTabSelected", + controlType: "ACTION_SELECTOR", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: true, + }, + ], + }, + ]; + } + + onTabChange = (tabIndex: number) => { + this.props.updateWidgetMetaProperty("selectedTabIndex", tabIndex, { + triggerPropertyName: "onTabSelected", + dynamicString: this.props.onTabSelected, + event: { + type: EventType.ON_TAB_CHANGE, + }, + }); + }; + + static getDerivedPropertiesMap() { + return { + selectedTab: `{{_.get(this.list, this.selectedTabIndex)}}`, + }; + } + + static getMetaPropertiesMap(): Record { + return { + selectedTabIndex: undefined, + }; + } + + static getDefaultPropertiesMap(): Record { + return {}; + } + + componentDidUpdate(prevProps: MTabsWidgetProps) { + const props = this.cleanProps(); + const pre = this.cleanProps(prevProps); + if ( + props.list.length !== pre.list.length || + props.defaultNum !== pre.defaultNum + ) { + this.syncMetaProperty(props); + } + } + + componentDidMount() { + this.syncMetaProperty(this.cleanProps()); + } + + syncMetaProperty = (props: any) => { + const { list, defaultNum, safeDefault } = props; + let defaultIndex = defaultNum; + if (!safeDefault) { + defaultIndex = list.length ? 0 : undefined; + } + this.props.updateWidgetMetaProperty("selectedTabIndex", defaultIndex); + }; + + cleanProps = (props?: MTabsWidgetProps) => { + const { list, defaultNum, ...others } = props || this.props; + const tabItems = _.isArray(list) ? list : []; + const safeDefault = + _.isNumber(defaultNum) && + tabItems.length && + defaultNum > 0 && + defaultNum < tabItems.length; + return { + ...others, + defaultNum, + list: tabItems, + safeDefault, + }; + }; + + getPageView() { + const { + topRow, + bottomRow, + leftColumn, + rightColumn, + list, + nameKey, + selectedTabIndex, + isLoading, + showLoading, + } = this.cleanProps(); + const layout = bottomRow - topRow > rightColumn - leftColumn ? "v" : "h"; + if (isLoading && showLoading) { + return ( + + {Array.from(Array(20)).map((a, i) => ( + + ))} + + ); + } + return ( + + ); + } + + getWidgetType(): WidgetType { + return "TARO_TABS_WIDGET"; + } +} + +export interface MTabsWidgetProps extends WidgetProps, WithMeta { + list: any[]; + nameKey: string; + defaultNum?: string | number; + onTabSelected?: string; + selectedTabIndex: number; + showLoading?: boolean; +} + +export default MTabsWidget; +export const MProfiledTabsWidget = withMeta(MTabsWidget); diff --git a/app/taro/src/widgets/taro/TextWidget.tsx b/app/taro/src/widgets/taro/TextWidget.tsx new file mode 100644 index 0000000000..a5b22b76b4 --- /dev/null +++ b/app/taro/src/widgets/taro/TextWidget.tsx @@ -0,0 +1,200 @@ +import React from "react"; +import BaseWidget, { WidgetProps, WidgetState } from "../BaseWidget"; +import { WidgetType, TextSize } from "constants/WidgetConstants"; +import TextComponent from "components/designSystems/taro/TextComponent"; +import { ValidationTypes } from "constants/WidgetValidation"; +import { DerivedPropertiesMap } from "utils/WidgetFactory"; +import LoadingWrapper from "./LoadingWrapper"; + +class TextWidget extends BaseWidget { + static getPropertyPaneConfig() { + return [ + { + sectionName: "属性", + children: [ + { + propertyName: "text", + label: "文本", + controlType: "INPUT_TEXT", + placeholderText: "请输入文本内容", + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "shouldScroll", + label: "允许滚动", + helpText: "内容超长时允许滚动,不然文本会被截断", + controlType: "SWITCH", + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "isVisible", + label: "是否可见", + controlType: "SWITCH", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.BOOLEAN }, + }, + ], + }, + { + sectionName: "样式", + children: [ + { + propertyName: "backgroundColor", + label: "背景颜色", + controlType: "COLOR_PICKER", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + }, + { + propertyName: "textColor", + label: "文本颜色", + controlType: "COLOR_PICKER", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + }, + { + propertyName: "fontSize", + label: "字体大小", + controlType: "DROP_DOWN", + options: [ + { + label: "一级标题", + value: "HEADING1", + subText: "24px", + icon: "HEADING_ONE", + }, + { + label: "二级标题", + value: "HEADING2", + subText: "18px", + icon: "HEADING_TWO", + }, + { + label: "三级标题", + value: "HEADING3", + subText: "16px", + icon: "HEADING_THREE", + }, + { + label: "一级段落", + value: "PARAGRAPH", + subText: "14px", + icon: "PARAGRAPH", + }, + { + label: "二级段落", + value: "PARAGRAPH2", + subText: "12px", + icon: "PARAGRAPH_TWO", + }, + ], + isBindProperty: false, + isTriggerProperty: false, + }, + { + propertyName: "fontStyle", + label: "字体风格", + controlType: "BUTTON_TABS", + options: [ + { + icon: "BOLD_FONT", + value: "BOLD", + }, + { + icon: "ITALICS_FONT", + value: "ITALIC", + }, + { + icon: "LINETHROUGH_FONT", + value: "LINETHROUGH", + }, + ], + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + { + propertyName: "textAlign", + label: "文字对齐", + controlType: "ICON_TABS", + options: [ + { + icon: "LEFT_ALIGN", + value: "LEFT", + }, + { + icon: "CENTER_ALIGN", + value: "CENTER", + }, + { + icon: "RIGHT_ALIGN", + value: "RIGHT", + }, + ], + defaultValue: "LEFT", + isJSConvertible: true, + isBindProperty: true, + isTriggerProperty: false, + validation: { type: ValidationTypes.TEXT }, + }, + ], + }, + ]; + } + + getPageView() { + return ( + + + + ); + } + + static getDerivedPropertiesMap(): DerivedPropertiesMap { + return { + value: `{{ this.text }}`, + }; + } + + getWidgetType(): WidgetType { + return "TARO_TEXT_WIDGET"; + } +} + +export type TextAlign = "LEFT" | "CENTER" | "RIGHT" | "JUSTIFY"; + +export interface TextStyles { + backgroundColor?: string; + textColor?: string; + fontStyle?: string; + fontSize?: TextSize; + textAlign?: TextAlign; +} + +export interface MTextWidgetProps extends WidgetProps, TextStyles { + text?: string; + isLoading: boolean; + shouldScroll: boolean; +} + +export default TextWidget; +export const MProfiledTextWidget = TextWidget; diff --git a/app/taro/src/worker/worker.js b/app/taro/src/worker/worker.js new file mode 100644 index 0000000000..097311a5f8 --- /dev/null +++ b/app/taro/src/worker/worker.js @@ -0,0 +1,2 @@ +/*! For license information please see worker.js.LICENSE.txt */ +(function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=50)})([function(t,e,n){(function(t,r){var i;(function(){var a,o="4.17.21",s=200,u="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",c="Expected a function",l="Invalid `variable` option passed into `_.template`",h="__lodash_hash_undefined__",p=500,f="__lodash_placeholder__",d=1,v=2,g=4,y=1,m=2,b=1,_=2,w=4,x=8,E=16,O=32,S=64,T=128,k=256,A=512,C=30,N="...",I=800,j=16,P=1,R=2,D=3,M=1/0,L=9007199254740991,V=17976931348623157e292,F=NaN,B=4294967295,U=B-1,H=B>>>1,W=[["ary",T],["bind",b],["bindKey",_],["curry",x],["curryRight",E],["flip",A],["partial",O],["partialRight",S],["rearg",k]],G="[object Arguments]",$="[object Array]",q="[object AsyncFunction]",z="[object Boolean]",Y="[object Date]",K="[object DOMException]",J="[object Error]",X="[object Function]",Q="[object GeneratorFunction]",Z="[object Map]",tt="[object Number]",et="[object Null]",nt="[object Object]",rt="[object Promise]",it="[object Proxy]",at="[object RegExp]",ot="[object Set]",st="[object String]",ut="[object Symbol]",ct="[object Undefined]",lt="[object WeakMap]",ht="[object WeakSet]",pt="[object ArrayBuffer]",ft="[object DataView]",dt="[object Float32Array]",vt="[object Float64Array]",gt="[object Int8Array]",yt="[object Int16Array]",mt="[object Int32Array]",bt="[object Uint8Array]",_t="[object Uint8ClampedArray]",wt="[object Uint16Array]",xt="[object Uint32Array]",Et=/\b__p \+= '';/g,Ot=/\b(__p \+=) '' \+/g,St=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Tt=/&(?:amp|lt|gt|quot|#39);/g,kt=/[&<>"']/g,At=RegExp(Tt.source),Ct=RegExp(kt.source),Nt=/<%-([\s\S]+?)%>/g,It=/<%([\s\S]+?)%>/g,jt=/<%=([\s\S]+?)%>/g,Pt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Rt=/^\w*$/,Dt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Mt=/[\\^$.*+?()[\]{}|]/g,Lt=RegExp(Mt.source),Vt=/^\s+/,Ft=/\s/,Bt=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Ut=/\{\n\/\* \[wrapped with (.+)\] \*/,Ht=/,? & /,Wt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Gt=/[()=,{}\[\]\/\s]/,$t=/\\(\\)?/g,qt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,zt=/\w*$/,Yt=/^[-+]0x[0-9a-f]+$/i,Kt=/^0b[01]+$/i,Jt=/^\[object .+?Constructor\]$/,Xt=/^0o[0-7]+$/i,Qt=/^(?:0|[1-9]\d*)$/,Zt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,te=/($^)/,ee=/['\n\r\u2028\u2029\\]/g,ne="\\ud800-\\udfff",re="\\u0300-\\u036f",ie="\\ufe20-\\ufe2f",ae="\\u20d0-\\u20ff",oe=re+ie+ae,se="\\u2700-\\u27bf",ue="a-z\\xdf-\\xf6\\xf8-\\xff",ce="\\xac\\xb1\\xd7\\xf7",le="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",he="\\u2000-\\u206f",pe=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",fe="A-Z\\xc0-\\xd6\\xd8-\\xde",de="\\ufe0e\\ufe0f",ve=ce+le+he+pe,ge="['\u2019]",ye="["+ne+"]",me="["+ve+"]",be="["+oe+"]",_e="\\d+",we="["+se+"]",xe="["+ue+"]",Ee="[^"+ne+ve+_e+se+ue+fe+"]",Oe="\\ud83c[\\udffb-\\udfff]",Se="(?:"+be+"|"+Oe+")",Te="[^"+ne+"]",ke="(?:\\ud83c[\\udde6-\\uddff]){2}",Ae="[\\ud800-\\udbff][\\udc00-\\udfff]",Ce="["+fe+"]",Ne="\\u200d",Ie="(?:"+xe+"|"+Ee+")",je="(?:"+Ce+"|"+Ee+")",Pe="(?:"+ge+"(?:d|ll|m|re|s|t|ve))?",Re="(?:"+ge+"(?:D|LL|M|RE|S|T|VE))?",De=Se+"?",Me="["+de+"]?",Le="(?:"+Ne+"(?:"+[Te,ke,Ae].join("|")+")"+Me+De+")*",Ve="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Fe="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Be=Me+De+Le,Ue="(?:"+[we,ke,Ae].join("|")+")"+Be,He="(?:"+[Te+be+"?",be,ke,Ae,ye].join("|")+")",We=RegExp(ge,"g"),Ge=RegExp(be,"g"),$e=RegExp(Oe+"(?="+Oe+")|"+He+Be,"g"),qe=RegExp([Ce+"?"+xe+"+"+Pe+"(?="+[me,Ce,"$"].join("|")+")",je+"+"+Re+"(?="+[me,Ce+Ie,"$"].join("|")+")",Ce+"?"+Ie+"+"+Pe,Ce+"+"+Re,Fe,Ve,_e,Ue].join("|"),"g"),ze=RegExp("["+Ne+ne+oe+de+"]"),Ye=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ke=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Je=-1,Xe={};Xe[dt]=Xe[vt]=Xe[gt]=Xe[yt]=Xe[mt]=Xe[bt]=Xe[_t]=Xe[wt]=Xe[xt]=!0,Xe[G]=Xe[$]=Xe[pt]=Xe[z]=Xe[ft]=Xe[Y]=Xe[J]=Xe[X]=Xe[Z]=Xe[tt]=Xe[nt]=Xe[at]=Xe[ot]=Xe[st]=Xe[lt]=!1;var Qe={};Qe[G]=Qe[$]=Qe[pt]=Qe[ft]=Qe[z]=Qe[Y]=Qe[dt]=Qe[vt]=Qe[gt]=Qe[yt]=Qe[mt]=Qe[Z]=Qe[tt]=Qe[nt]=Qe[at]=Qe[ot]=Qe[st]=Qe[ut]=Qe[bt]=Qe[_t]=Qe[wt]=Qe[xt]=!0,Qe[J]=Qe[X]=Qe[lt]=!1;var Ze={"\xc0":"A","\xc1":"A","\xc2":"A","\xc3":"A","\xc4":"A","\xc5":"A","\xe0":"a","\xe1":"a","\xe2":"a","\xe3":"a","\xe4":"a","\xe5":"a","\xc7":"C","\xe7":"c","\xd0":"D","\xf0":"d","\xc8":"E","\xc9":"E","\xca":"E","\xcb":"E","\xe8":"e","\xe9":"e","\xea":"e","\xeb":"e","\xcc":"I","\xcd":"I","\xce":"I","\xcf":"I","\xec":"i","\xed":"i","\xee":"i","\xef":"i","\xd1":"N","\xf1":"n","\xd2":"O","\xd3":"O","\xd4":"O","\xd5":"O","\xd6":"O","\xd8":"O","\xf2":"o","\xf3":"o","\xf4":"o","\xf5":"o","\xf6":"o","\xf8":"o","\xd9":"U","\xda":"U","\xdb":"U","\xdc":"U","\xf9":"u","\xfa":"u","\xfb":"u","\xfc":"u","\xdd":"Y","\xfd":"y","\xff":"y","\xc6":"Ae","\xe6":"ae","\xde":"Th","\xfe":"th","\xdf":"ss","\u0100":"A","\u0102":"A","\u0104":"A","\u0101":"a","\u0103":"a","\u0105":"a","\u0106":"C","\u0108":"C","\u010a":"C","\u010c":"C","\u0107":"c","\u0109":"c","\u010b":"c","\u010d":"c","\u010e":"D","\u0110":"D","\u010f":"d","\u0111":"d","\u0112":"E","\u0114":"E","\u0116":"E","\u0118":"E","\u011a":"E","\u0113":"e","\u0115":"e","\u0117":"e","\u0119":"e","\u011b":"e","\u011c":"G","\u011e":"G","\u0120":"G","\u0122":"G","\u011d":"g","\u011f":"g","\u0121":"g","\u0123":"g","\u0124":"H","\u0126":"H","\u0125":"h","\u0127":"h","\u0128":"I","\u012a":"I","\u012c":"I","\u012e":"I","\u0130":"I","\u0129":"i","\u012b":"i","\u012d":"i","\u012f":"i","\u0131":"i","\u0134":"J","\u0135":"j","\u0136":"K","\u0137":"k","\u0138":"k","\u0139":"L","\u013b":"L","\u013d":"L","\u013f":"L","\u0141":"L","\u013a":"l","\u013c":"l","\u013e":"l","\u0140":"l","\u0142":"l","\u0143":"N","\u0145":"N","\u0147":"N","\u014a":"N","\u0144":"n","\u0146":"n","\u0148":"n","\u014b":"n","\u014c":"O","\u014e":"O","\u0150":"O","\u014d":"o","\u014f":"o","\u0151":"o","\u0154":"R","\u0156":"R","\u0158":"R","\u0155":"r","\u0157":"r","\u0159":"r","\u015a":"S","\u015c":"S","\u015e":"S","\u0160":"S","\u015b":"s","\u015d":"s","\u015f":"s","\u0161":"s","\u0162":"T","\u0164":"T","\u0166":"T","\u0163":"t","\u0165":"t","\u0167":"t","\u0168":"U","\u016a":"U","\u016c":"U","\u016e":"U","\u0170":"U","\u0172":"U","\u0169":"u","\u016b":"u","\u016d":"u","\u016f":"u","\u0171":"u","\u0173":"u","\u0174":"W","\u0175":"w","\u0176":"Y","\u0177":"y","\u0178":"Y","\u0179":"Z","\u017b":"Z","\u017d":"Z","\u017a":"z","\u017c":"z","\u017e":"z","\u0132":"IJ","\u0133":"ij","\u0152":"Oe","\u0153":"oe","\u0149":"'n","\u017f":"s"},tn={"&":"&","<":"<",">":">",'"':""","'":"'"},en={"&":"&","<":"<",">":">",""":'"',"'":"'"},nn={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},rn=parseFloat,an=parseInt,on="object"==typeof t&&t&&t.Object===Object&&t,sn="object"==typeof self&&self&&self.Object===Object&&self,un=on||sn||Function("return this")(),cn=e&&!e.nodeType&&e,ln=cn&&"object"==typeof r&&r&&!r.nodeType&&r,hn=ln&&ln.exports===cn,pn=hn&&on.process,fn=function(){try{var t=ln&&ln.require&&ln.require("util").types;return t||pn&&pn.binding&&pn.binding("util")}catch(t){}}(),dn=fn&&fn.isArrayBuffer,vn=fn&&fn.isDate,gn=fn&&fn.isMap,yn=fn&&fn.isRegExp,mn=fn&&fn.isSet,bn=fn&&fn.isTypedArray;function _n(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function wn(t,e,n,r){var i=-1,a=null==t?0:t.length;while(++i-1}function kn(t,e,n){var r=-1,i=null==t?0:t.length;while(++r-1);return n}function tr(t,e){var n=t.length;while(n--&&Vn(e,t[n],0)>-1);return n}function er(t,e){var n=t.length,r=0;while(n--)t[n]===e&&++r;return r}var nr=Wn(Ze),rr=Wn(tn);function ir(t){return"\\"+nn[t]}function ar(t,e){return null==t?a:t[e]}function or(t){return ze.test(t)}function sr(t){return Ye.test(t)}function ur(t){var e,n=[];while(!(e=t.next()).done)n.push(e.value);return n}function cr(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function lr(t,e){return function(n){return t(e(n))}}function hr(t,e){var n=-1,r=t.length,i=0,a=[];while(++n-1}function Hr(t,e){var n=this.__data__,r=li(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this}function Wr(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e=e?t:e)),t}function yi(t,e,n,r,i,o){var s,u=e&d,c=e&v,l=e&g;if(n&&(s=i?n(t,r,i,o):n(t)),s!==a)return s;if(!Ol(t))return t;var h=ul(t);if(h){if(s=es(t),!u)return ro(t,s)}else{var p=Xo(t),f=p==X||p==Q;if(fl(t))return za(t,u);if(p==nt||p==G||f&&!i){if(s=c||f?{}:ns(t),!u)return c?oo(t,fi(s,t)):ao(t,pi(s,t))}else{if(!Qe[p])return i?t:{};s=rs(t,p,u)}}o||(o=new Qr);var y=o.get(t);if(y)return y;o.set(t,s),Ll(t)?t.forEach((function(r){s.add(yi(r,e,n,r,t,o))})):Tl(t)&&t.forEach((function(r,i){s.set(i,yi(r,e,n,i,t,o))}));var m=l?c?Bo:Fo:c?Eh:xh,b=h?a:m(t);return xn(b||t,(function(r,i){b&&(i=r,r=t[i]),ci(s,i,yi(r,e,n,i,t,o))})),s}function mi(t){var e=xh(t);return function(n){return bi(n,t,e)}}function bi(t,e,n){var r=n.length;if(null==t)return!r;t=ne(t);while(r--){var i=n[r],o=e[i],s=t[i];if(s===a&&!(i in t)||!o(s))return!1}return!0}function _i(t,e,n){if("function"!=typeof t)throw new ae(c);return Ss((function(){t.apply(a,n)}),e)}function wi(t,e,n,r){var i=-1,a=Tn,o=!0,u=t.length,c=[],l=e.length;if(!u)return c;n&&(e=An(e,Jn(n))),r?(a=kn,o=!1):e.length>=s&&(a=Qn,o=!1,e=new Kr(e));t:while(++ii?0:i+n),r=r===a||r>i?i:Yl(r),r<0&&(r+=i),r=n>r?0:Kl(r);while(n0&&n(s)?e>1?Ai(s,e-1,n,r,i):Cn(i,s):r||(i[i.length]=s)}return i}var Ci=lo(),Ni=lo(!0);function Ii(t,e){return t&&Ci(t,e,xh)}function ji(t,e){return t&&Ni(t,e,xh)}function Pi(t,e){return Sn(e,(function(e){return wl(t[e])}))}function Ri(t,e){e=Wa(e,t);var n=0,r=e.length;while(null!=t&&ne}function Vi(t,e){return null!=t&&he.call(t,e)}function Fi(t,e){return null!=t&&e in ne(t)}function Bi(t,e,n){return t>=Ue(e,n)&&t=120&&p.length>=120)?new Kr(u&&p):a}p=t[0];var f=-1,d=c[0];t:while(++f-1)s!==t&&Se.call(s,u,1),Se.call(t,u,1)}return t}function ga(t,e){var n=t?e.length:0,r=n-1;while(n--){var i=e[n];if(n==r||i!==a){var a=i;os(i)?Se.call(t,i,1):Da(t,i)}}return t}function ya(t,e){return t+Re(qe()*(e-t+1))}function ma(t,e,r,i){var a=-1,o=Be(Pe((e-t)/(r||1)),0),s=n(o);while(o--)s[i?o:++a]=t,t+=r;return s}function ba(t,e){var n="";if(!t||e<1||e>L)return n;do{e%2&&(n+=t),e=Re(e/2),e&&(t+=t)}while(e);return n}function _a(t,e){return Ts(_s(t,e,Np),t+"")}function wa(t){return ai(Uh(t))}function xa(t,e){var n=Uh(t);return Cs(n,gi(e,0,n.length))}function Ea(t,e,n,r){if(!Ol(t))return t;e=Wa(e,t);var i=-1,o=e.length,s=o-1,u=t;while(null!=u&&++ia?0:a+e),r=r>a?a:r,r<0&&(r+=a),a=e>r?0:r-e>>>0,e>>>=0;var o=n(a);while(++i>>1,o=t[a];null!==o&&!Fl(o)&&(n?o<=e:o=s){var l=e?null:Co(t);if(l)return pr(l);o=!1,i=Qn,c=new Kr}else c=e?[]:u;t:while(++r=r?t:ka(t,e,n)}var qa=Ne||function(t){return un.clearTimeout(t)};function za(t,e){if(e)return t.slice();var n=t.length,r=we?we(n):new t.constructor(n);return t.copy(r),r}function Ya(t){var e=new t.constructor(t.byteLength);return new _e(e).set(new _e(t)),e}function Ka(t,e){var n=e?Ya(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}function Ja(t){var e=new t.constructor(t.source,zt.exec(t));return e.lastIndex=t.lastIndex,e}function Xa(t){return dr?ne(dr.call(t)):{}}function Qa(t,e){var n=e?Ya(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Za(t,e){if(t!==e){var n=t!==a,r=null===t,i=t===t,o=Fl(t),s=e!==a,u=null===e,c=e===e,l=Fl(e);if(!u&&!l&&!o&&t>e||o&&s&&c&&!u&&!l||r&&s&&c||!n&&c||!i)return 1;if(!r&&!o&&!l&&t=s)return u;var c=n[r];return u*("desc"==c?-1:1)}}return t.index-e.index}function eo(t,e,r,i){var a=-1,o=t.length,s=r.length,u=-1,c=e.length,l=Be(o-s,0),h=n(c+l),p=!i;while(++u1?n[i-1]:a,s=i>2?n[2]:a;o=t.length>3&&"function"==typeof o?(i--,o):a,s&&ss(n[0],n[1],s)&&(o=i<3?a:o,i=1),e=ne(e);while(++r-1?i[o?e[s]:s]:a}}function mo(t){return Vo((function(e){var n=e.length,r=n,i=Tr.prototype.thru;t&&e.reverse();while(r--){var o=e[r];if("function"!=typeof o)throw new ae(c);if(i&&!s&&"wrapper"==Ho(o))var s=new Tr([],!0)}r=s?r:n;while(++r1&&b.reverse(),p&&lu))return!1;var l=o.get(t),h=o.get(e);if(l&&h)return l==e&&h==t;var p=-1,f=!0,d=n&m?new Kr:a;o.set(t,e),o.set(e,t);while(++p1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(Bt,"{\n/* [wrapped with "+e+"] */\n")}function as(t){return ul(t)||sl(t)||!!(Te&&t&&t[Te])}function os(t,e){var n=typeof t;return e=null==e?L:e,!!e&&("number"==n||"symbol"!=n&&Qt.test(t))&&t>-1&&t%1==0&&t0){if(++e>=I)return arguments[0]}else e=0;return t.apply(a,arguments)}}function Cs(t,e){var n=-1,r=t.length,i=r-1;e=e===a?r:e;while(++n1?t[e-1]:a;return n="function"==typeof n?(t.pop(),n):a,Mu(t,n)}));function $u(t){var e=wr(t);return e.__chain__=!0,e}function qu(t,e){return e(t),t}function zu(t,e){return e(t)}var Yu=Vo((function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,i=function(e){return vi(e,t)};return!(e>1||this.__actions__.length)&&r instanceof kr&&os(n)?(r=r.slice(n,+n+(e?1:0)),r.__actions__.push({func:zu,args:[i],thisArg:a}),new Tr(r,this.__chain__).thru((function(t){return e&&!t.length&&t.push(a),t}))):this.thru(i)}));function Ku(){return $u(this)}function Ju(){return new Tr(this.value(),this.__chain__)}function Xu(){this.__values__===a&&(this.__values__=ql(this.value()));var t=this.__index__>=this.__values__.length,e=t?a:this.__values__[this.__index__++];return{done:t,value:e}}function Qu(){return this}function Zu(t){var e,n=this;while(n instanceof Sr){var r=Rs(n);r.__index__=0,r.__values__=a,e?i.__wrapped__=r:e=r;var i=r;n=n.__wrapped__}return i.__wrapped__=t,e}function tc(){var t=this.__wrapped__;if(t instanceof kr){var e=t;return this.__actions__.length&&(e=new kr(this)),e=e.reverse(),e.__actions__.push({func:zu,args:[du],thisArg:a}),new Tr(e,this.__chain__)}return this.thru(du)}function ec(){return Va(this.__wrapped__,this.__actions__)}var nc=so((function(t,e,n){he.call(t,n)?++t[n]:di(t,n,1)}));function rc(t,e,n){var r=ul(t)?On:Oi;return n&&ss(t,e,n)&&(e=a),r(t,Go(e,3))}function ic(t,e){var n=ul(t)?Sn:ki;return n(t,Go(e,3))}var ac=yo(qs),oc=yo(zs);function sc(t,e){return Ai(gc(t,e),1)}function uc(t,e){return Ai(gc(t,e),M)}function cc(t,e,n){return n=n===a?1:Yl(n),Ai(gc(t,e),n)}function lc(t,e){var n=ul(t)?xn:xi;return n(t,Go(e,3))}function hc(t,e){var n=ul(t)?En:Ei;return n(t,Go(e,3))}var pc=so((function(t,e,n){he.call(t,n)?t[n].push(e):di(t,n,[e])}));function fc(t,e,n,r){t=ll(t)?t:Uh(t),n=n&&!r?Yl(n):0;var i=t.length;return n<0&&(n=Be(i+n,0)),Vl(t)?n<=i&&t.indexOf(e,n)>-1:!!i&&Vn(t,e,n)>-1}var dc=_a((function(t,e,r){var i=-1,a="function"==typeof e,o=ll(t)?n(t.length):[];return xi(t,(function(t){o[++i]=a?_n(e,t,r):Wi(t,e,r)})),o})),vc=so((function(t,e,n){di(t,n,e)}));function gc(t,e){var n=ul(t)?An:aa;return n(t,Go(e,3))}function yc(t,e,n,r){return null==t?[]:(ul(e)||(e=null==e?[]:[e]),n=r?a:n,ul(n)||(n=null==n?[]:[n]),ha(t,e,n))}var mc=so((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]}));function bc(t,e,n){var r=ul(t)?Nn:Gn,i=arguments.length<3;return r(t,Go(e,4),n,i,xi)}function _c(t,e,n){var r=ul(t)?In:Gn,i=arguments.length<3;return r(t,Go(e,4),n,i,Ei)}function wc(t,e){var n=ul(t)?Sn:ki;return n(t,Uc(Go(e,3)))}function xc(t){var e=ul(t)?ai:wa;return e(t)}function Ec(t,e,n){e=(n?ss(t,e,n):e===a)?1:Yl(e);var r=ul(t)?oi:xa;return r(t,e)}function Oc(t){var e=ul(t)?si:Ta;return e(t)}function Sc(t){if(null==t)return 0;if(ll(t))return Vl(t)?gr(t):t.length;var e=Xo(t);return e==Z||e==ot?t.size:na(t).length}function Tc(t,e,n){var r=ul(t)?jn:Aa;return n&&ss(t,e,n)&&(e=a),r(t,Go(e,3))}var kc=_a((function(t,e){if(null==t)return[];var n=e.length;return n>1&&ss(t,e[0],e[1])?e=[]:n>2&&ss(e[0],e[1],e[2])&&(e=[e[0]]),ha(t,Ai(e,1),[])})),Ac=Ie||function(){return un.Date.now()};function Cc(t,e){if("function"!=typeof e)throw new ae(c);return t=Yl(t),function(){if(--t<1)return e.apply(this,arguments)}}function Nc(t,e,n){return e=n?a:e,e=t&&null==e?t.length:e,Io(t,T,a,a,a,a,e)}function Ic(t,e){var n;if("function"!=typeof e)throw new ae(c);return t=Yl(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=a),n}}var jc=_a((function(t,e,n){var r=b;if(n.length){var i=hr(n,Wo(jc));r|=O}return Io(t,r,e,n,i)})),Pc=_a((function(t,e,n){var r=b|_;if(n.length){var i=hr(n,Wo(Pc));r|=O}return Io(e,r,t,n,i)}));function Rc(t,e,n){e=n?a:e;var r=Io(t,x,a,a,a,a,a,e);return r.placeholder=Rc.placeholder,r}function Dc(t,e,n){e=n?a:e;var r=Io(t,E,a,a,a,a,a,e);return r.placeholder=Dc.placeholder,r}function Mc(t,e,n){var r,i,o,s,u,l,h=0,p=!1,f=!1,d=!0;if("function"!=typeof t)throw new ae(c);function v(e){var n=r,o=i;return r=i=a,h=e,s=t.apply(o,n),s}function g(t){return h=t,u=Ss(b,e),p?v(t):s}function y(t){var n=t-l,r=t-h,i=e-n;return f?Ue(i,o-r):i}function m(t){var n=t-l,r=t-h;return l===a||n>=e||n<0||f&&r>=o}function b(){var t=Ac();if(m(t))return _(t);u=Ss(b,y(t))}function _(t){return u=a,d&&r?v(t):(r=i=a,s)}function w(){u!==a&&qa(u),h=0,r=l=i=u=a}function x(){return u===a?s:_(Ac())}function E(){var t=Ac(),n=m(t);if(r=arguments,i=this,l=t,n){if(u===a)return g(l);if(f)return qa(u),u=Ss(b,e),v(l)}return u===a&&(u=Ss(b,e)),s}return e=Jl(e)||0,Ol(n)&&(p=!!n.leading,f="maxWait"in n,o=f?Be(Jl(n.maxWait)||0,e):o,d="trailing"in n?!!n.trailing:d),E.cancel=w,E.flush=x,E}var Lc=_a((function(t,e){return _i(t,1,e)})),Vc=_a((function(t,e,n){return _i(t,Jl(e)||0,n)}));function Fc(t){return Io(t,A)}function Bc(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new ae(c);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=t.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(Bc.Cache||Wr),n}function Uc(t){if("function"!=typeof t)throw new ae(c);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}function Hc(t){return Ic(2,t)}Bc.Cache=Wr;var Wc=Ga((function(t,e){e=1==e.length&&ul(e[0])?An(e[0],Jn(Go())):An(Ai(e,1),Jn(Go()));var n=e.length;return _a((function(r){var i=-1,a=Ue(r.length,n);while(++i=e})),sl=Gi(function(){return arguments}())?Gi:function(t){return Sl(t)&&he.call(t,"callee")&&!Oe.call(t,"callee")},ul=n.isArray,cl=dn?Jn(dn):$i;function ll(t){return null!=t&&El(t.length)&&!wl(t)}function hl(t){return Sl(t)&&ll(t)}function pl(t){return!0===t||!1===t||Sl(t)&&Mi(t)==z}var fl=Me||Yp,dl=vn?Jn(vn):qi;function vl(t){return Sl(t)&&1===t.nodeType&&!Rl(t)}function gl(t){if(null==t)return!0;if(ll(t)&&(ul(t)||"string"==typeof t||"function"==typeof t.splice||fl(t)||Bl(t)||sl(t)))return!t.length;var e=Xo(t);if(e==Z||e==ot)return!t.size;if(fs(t))return!na(t).length;for(var n in t)if(he.call(t,n))return!1;return!0}function yl(t,e){return zi(t,e)}function ml(t,e,n){n="function"==typeof n?n:a;var r=n?n(t,e):a;return r===a?zi(t,e,a,n):!!r}function bl(t){if(!Sl(t))return!1;var e=Mi(t);return e==J||e==K||"string"==typeof t.message&&"string"==typeof t.name&&!Rl(t)}function _l(t){return"number"==typeof t&&Le(t)}function wl(t){if(!Ol(t))return!1;var e=Mi(t);return e==X||e==Q||e==q||e==it}function xl(t){return"number"==typeof t&&t==Yl(t)}function El(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=L}function Ol(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function Sl(t){return null!=t&&"object"==typeof t}var Tl=gn?Jn(gn):Ki;function kl(t,e){return t===e||Ji(t,e,qo(e))}function Al(t,e,n){return n="function"==typeof n?n:a,Ji(t,e,qo(e),n)}function Cl(t){return Pl(t)&&t!=+t}function Nl(t){if(ps(t))throw new i(u);return Xi(t)}function Il(t){return null===t}function jl(t){return null==t}function Pl(t){return"number"==typeof t||Sl(t)&&Mi(t)==tt}function Rl(t){if(!Sl(t)||Mi(t)!=nt)return!1;var e=xe(t);if(null===e)return!0;var n=he.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&le.call(n)==ve}var Dl=yn?Jn(yn):Qi;function Ml(t){return xl(t)&&t>=-L&&t<=L}var Ll=mn?Jn(mn):Zi;function Vl(t){return"string"==typeof t||!ul(t)&&Sl(t)&&Mi(t)==st}function Fl(t){return"symbol"==typeof t||Sl(t)&&Mi(t)==ut}var Bl=bn?Jn(bn):ta;function Ul(t){return t===a}function Hl(t){return Sl(t)&&Xo(t)==lt}function Wl(t){return Sl(t)&&Mi(t)==ht}var Gl=To(ia),$l=To((function(t,e){return t<=e}));function ql(t){if(!t)return[];if(ll(t))return Vl(t)?yr(t):ro(t);if(ke&&t[ke])return ur(t[ke]());var e=Xo(t),n=e==Z?cr:e==ot?pr:Uh;return n(t)}function zl(t){if(!t)return 0===t?t:0;if(t=Jl(t),t===M||t===-M){var e=t<0?-1:1;return e*V}return t===t?t:0}function Yl(t){var e=zl(t),n=e%1;return e===e?n?e-n:e:0}function Kl(t){return t?gi(Yl(t),0,B):0}function Jl(t){if("number"==typeof t)return t;if(Fl(t))return F;if(Ol(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Ol(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Kn(t);var n=Kt.test(t);return n||Xt.test(t)?an(t.slice(2),n?2:8):Yt.test(t)?F:+t}function Xl(t){return io(t,Eh(t))}function Ql(t){return t?gi(Yl(t),-L,L):0===t?t:0}function Zl(t){return null==t?"":Pa(t)}var th=uo((function(t,e){if(fs(e)||ll(e))io(e,xh(e),t);else for(var n in e)he.call(e,n)&&ci(t,n,e[n])})),eh=uo((function(t,e){io(e,Eh(e),t)})),nh=uo((function(t,e,n,r){io(e,Eh(e),t,r)})),rh=uo((function(t,e,n,r){io(e,xh(e),t,r)})),ih=Vo(vi);function ah(t,e){var n=Er(t);return null==e?n:pi(n,e)}var oh=_a((function(t,e){t=ne(t);var n=-1,r=e.length,i=r>2?e[2]:a;i&&ss(e[0],e[1],i)&&(r=1);while(++n1),e})),io(t,Bo(t),n),r&&(n=yi(n,d|v|g,Ro));var i=e.length;while(i--)Da(n,e[i]);return n}));function Ch(t,e){return Ih(t,Uc(Go(e)))}var Nh=Vo((function(t,e){return null==t?{}:pa(t,e)}));function Ih(t,e){if(null==t)return{};var n=An(Bo(t),(function(t){return[t]}));return e=Go(e),fa(t,n,(function(t,n){return e(t,n[0])}))}function jh(t,e,n){e=Wa(e,t);var r=-1,i=e.length;i||(i=1,t=a);while(++re){var r=t;t=e,e=r}if(n||t%1||e%1){var i=qe();return Ue(t+i*(e-t+rn("1e-"+((i+"").length-1))),e)}return ya(t,e)}var qh=fo((function(t,e,n){return e=e.toLowerCase(),t+(n?zh(e):e)}));function zh(t){return _p(Zl(t).toLowerCase())}function Yh(t){return t=Zl(t),t&&t.replace(Zt,nr).replace(Ge,"")}function Kh(t,e,n){t=Zl(t),e=Pa(e);var r=t.length;n=n===a?r:gi(Yl(n),0,r);var i=n;return n-=e.length,n>=0&&t.slice(n,i)==e}function Jh(t){return t=Zl(t),t&&Ct.test(t)?t.replace(kt,rr):t}function Xh(t){return t=Zl(t),t&&Lt.test(t)?t.replace(Mt,"\\$&"):t}var Qh=fo((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Zh=fo((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),tp=po("toLowerCase");function ep(t,e,n){t=Zl(t),e=Yl(e);var r=e?gr(t):0;if(!e||r>=e)return t;var i=(e-r)/2;return Eo(Re(i),n)+t+Eo(Pe(i),n)}function np(t,e,n){t=Zl(t),e=Yl(e);var r=e?gr(t):0;return e&&r>>0,n?(t=Zl(t),t&&("string"==typeof e||null!=e&&!Dl(e))&&(e=Pa(e),!e&&or(t))?$a(yr(t),0,n):t.split(e,n)):[]}var cp=fo((function(t,e,n){return t+(n?" ":"")+_p(e)}));function lp(t,e,n){return t=Zl(t),n=null==n?0:gi(Yl(n),0,t.length),e=Pa(e),t.slice(n,n+e.length)==e}function hp(t,e,n){var r=wr.templateSettings;n&&ss(t,e,n)&&(e=a),t=Zl(t),e=nh({},e,r,jo);var o,s,u=nh({},e.imports,r.imports,jo),c=xh(u),h=Xn(u,c),p=0,f=e.interpolate||te,d="__p += '",v=re((e.escape||te).source+"|"+f.source+"|"+(f===jt?qt:te).source+"|"+(e.evaluate||te).source+"|$","g"),g="//# sourceURL="+(he.call(e,"sourceURL")?(e.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Je+"]")+"\n";t.replace(v,(function(e,n,r,i,a,u){return r||(r=i),d+=t.slice(p,u).replace(ee,ir),n&&(o=!0,d+="' +\n__e("+n+") +\n'"),a&&(s=!0,d+="';\n"+a+";\n__p += '"),r&&(d+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),p=u+e.length,e})),d+="';\n";var y=he.call(e,"variable")&&e.variable;if(y){if(Gt.test(y))throw new i(l)}else d="with (obj) {\n"+d+"\n}\n";d=(s?d.replace(Et,""):d).replace(Ot,"$1").replace(St,"$1;"),d="function("+(y||"obj")+") {\n"+(y?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+d+"return __p\n}";var m=xp((function(){return Ft(c,g+"return "+d).apply(a,h)}));if(m.source=d,bl(m))throw m;return m}function pp(t){return Zl(t).toLowerCase()}function fp(t){return Zl(t).toUpperCase()}function dp(t,e,n){if(t=Zl(t),t&&(n||e===a))return Kn(t);if(!t||!(e=Pa(e)))return t;var r=yr(t),i=yr(e),o=Zn(r,i),s=tr(r,i)+1;return $a(r,o,s).join("")}function vp(t,e,n){if(t=Zl(t),t&&(n||e===a))return t.slice(0,mr(t)+1);if(!t||!(e=Pa(e)))return t;var r=yr(t),i=tr(r,yr(e))+1;return $a(r,0,i).join("")}function gp(t,e,n){if(t=Zl(t),t&&(n||e===a))return t.replace(Vt,"");if(!t||!(e=Pa(e)))return t;var r=yr(t),i=Zn(r,yr(e));return $a(r,i).join("")}function yp(t,e){var n=C,r=N;if(Ol(e)){var i="separator"in e?e.separator:i;n="length"in e?Yl(e.length):n,r="omission"in e?Pa(e.omission):r}t=Zl(t);var o=t.length;if(or(t)){var s=yr(t);o=s.length}if(n>=o)return t;var u=n-gr(r);if(u<1)return r;var c=s?$a(s,0,u).join(""):t.slice(0,u);if(i===a)return c+r;if(s&&(u+=c.length-u),Dl(i)){if(t.slice(u).search(i)){var l,h=c;i.global||(i=re(i.source,Zl(zt.exec(i))+"g")),i.lastIndex=0;while(l=i.exec(h))var p=l.index;c=c.slice(0,p===a?u:p)}}else if(t.indexOf(Pa(i),u)!=u){var f=c.lastIndexOf(i);f>-1&&(c=c.slice(0,f))}return c+r}function mp(t){return t=Zl(t),t&&At.test(t)?t.replace(Tt,br):t}var bp=fo((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),_p=po("toUpperCase");function wp(t,e,n){return t=Zl(t),e=n?a:e,e===a?sr(t)?xr(t):Dn(t):t.match(e)||[]}var xp=_a((function(t,e){try{return _n(t,a,e)}catch(t){return bl(t)?t:new i(t)}})),Ep=Vo((function(t,e){return xn(e,(function(e){e=Is(e),di(t,e,jc(t[e],t))})),t}));function Op(t){var e=null==t?0:t.length,n=Go();return t=e?An(t,(function(t){if("function"!=typeof t[1])throw new ae(c);return[n(t[0]),t[1]]})):[],_a((function(n){var r=-1;while(++rL)return[];var n=B,r=Ue(t,B);e=Go(e),t-=B;var i=zn(r,e);while(++n0||e<0)?new kr(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==a&&(e=Yl(e),n=e<0?n.dropRight(-e):n.take(e-t)),n)},kr.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},kr.prototype.toArray=function(){return this.take(B)},Ii(kr.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),i=wr[r?"take"+("last"==e?"Right":""):e],o=r||/^find/.test(e);i&&(wr.prototype[e]=function(){var e=this.__wrapped__,s=r?[1]:arguments,u=e instanceof kr,c=s[0],l=u||ul(e),h=function(t){var e=i.apply(wr,Cn([t],s));return r&&p?e[0]:e};l&&n&&"function"==typeof c&&1!=c.length&&(u=l=!1);var p=this.__chain__,f=!!this.__actions__.length,d=o&&!p,v=u&&!f;if(!o&&l){e=v?e:new kr(this);var g=t.apply(e,s);return g.__actions__.push({func:zu,args:[h],thisArg:a}),new Tr(g,p)}return d&&v?t.apply(this,s):(g=this.thru(h),d?r?g.value()[0]:g.value():g)})})),xn(["pop","push","shift","sort","splice","unshift"],(function(t){var e=oe[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);wr.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var i=this.value();return e.apply(ul(i)?i:[],t)}return this[n]((function(n){return e.apply(ul(n)?n:[],t)}))}})),Ii(kr.prototype,(function(t,e){var n=wr[e];if(n){var r=n.name+"";he.call(cn,r)||(cn[r]=[]),cn[r].push({name:e,func:n})}})),cn[bo(a,_).name]=[{name:"wrapper",func:a}],kr.prototype.clone=Ar,kr.prototype.reverse=Cr,kr.prototype.value=Nr,wr.prototype.at=Yu,wr.prototype.chain=Ku,wr.prototype.commit=Ju,wr.prototype.next=Xu,wr.prototype.plant=Zu,wr.prototype.reverse=tc,wr.prototype.toJSON=wr.prototype.valueOf=wr.prototype.value=ec,wr.prototype.first=wr.prototype.head,ke&&(wr.prototype[ke]=Qu),wr},Or=Er();un._=Or,i=function(){return Or}.call(e,n,e,r),i===a||(r.exports=i)}).call(this)}).call(this,n(31),n(32)(t))},function(t,e,n){"use strict";n.d(e,"a",(function(){return Z})),n.d(e,"b",(function(){return Q})),n.d(e,"c",(function(){return et})),n.d(e,"d",(function(){return at})),n.d(e,"e",(function(){return X})),n.d(e,"f",(function(){return u})),n.d(e,"g",(function(){return o})),n.d(e,"h",(function(){return s})),n.d(e,"i",(function(){return a})),n.d(e,"j",(function(){return i})),n.d(e,"k",(function(){return tt})),n.d(e,"l",(function(){return rt})),n.d(e,"m",(function(){return nt}));n(6);var r=n(7);function i(t){return"undefined"===typeof t}function a(t){return null!==t&&"object"===Object(r["a"])(t)}function o(t){return!0===t||!1===t}function s(t){return"function"===typeof t}var u=Array.isArray,c=("i.".concat("st"),"i.".concat("cl"),{bindTouchStart:"",bindTouchMove:"",bindTouchEnd:"",bindTouchCancel:"",bindLongTap:""}),l={bindAnimationStart:"",bindAnimationIteration:"",bindAnimationEnd:"",bindTransitionEnd:""};function h(t){return"'".concat(t,"'")}var p=Object.assign(Object.assign({"hover-class":h("none"),"hover-stop-propagation":"false","hover-start-time":"50","hover-stay-time":"400",animation:""},c),l),f={type:"",size:"23",color:""},d=Object.assign({longitude:"",latitude:"",scale:"16",markers:"[]",covers:"",polyline:"[]",circles:"[]",controls:"[]","include-points":"[]","show-location":"","layer-style":"1",bindMarkerTap:"",bindControlTap:"",bindCalloutTap:"",bindUpdated:""},c),v={percent:"","stroke-width":"6",color:h("#09BB07"),activeColor:h("#09BB07"),backgroundColor:h("#EBEBEB"),active:"false","active-mode":h("backwards"),"show-info":"false"},g={nodes:"[]"},y={selectable:"false",space:"",decode:"false"},m=Object.assign({size:h("default"),type:"",plain:"false",disabled:"",loading:"false","form-type":"","open-type":"","hover-class":h("button-hover"),"hover-stop-propagation":"false","hover-start-time":"20","hover-stay-time":"70",name:""},c),b={value:"",disabled:"",checked:"false",color:h("#09BB07"),name:""},_={bindChange:"",name:""},w={"report-submit":"false",bindSubmit:"",bindReset:"",name:""},x={value:"",type:h(""),password:"false",placeholder:"","placeholder-style":"","placeholder-class":h("input-placeholder"),disabled:"",maxlength:"140","cursor-spacing":"0",focus:"false","confirm-type":h("done"),"confirm-hold":"false",cursor:"i.value.length","selection-start":"-1","selection-end":"-1",bindInput:"",bindFocus:"",bindBlur:"",bindConfirm:"",name:""},E={for:"",name:""},O={mode:h("selector"),disabled:"",range:"","range-key":"",value:"",start:"",end:"",fields:h("day"),"custom-item":"",name:"",bindCancel:"",bindChange:"",bindColumnChange:""},S={value:"","indicator-style":"","indicator-class":"","mask-style":"","mask-class":"",bindChange:"",name:""},T={name:""},k={value:"",checked:"false",disabled:"",color:h("#09BB07"),name:""},A={bindChange:"",name:""},C={min:"0",max:"100",step:"1",disabled:"",value:"0",activeColor:h("#1aad19"),backgroundColor:h("#e9e9e9"),"block-size":"28","block-color":h("#ffffff"),"show-value":"false",bindChange:"",bindChanging:"",name:""},N={checked:"false",disabled:"",type:h("switch"),color:h("#04BE02"),bindChange:"",name:""},I={value:"",placeholder:"","placeholder-style":"","placeholder-class":h("textarea-placeholder"),disabled:"",maxlength:"140","auto-focus":"false",focus:"false","auto-height":"false",fixed:"false","cursor-spacing":"0",cursor:"-1","selection-start":"-1","selection-end":"-1",bindFocus:"",bindBlur:"",bindLineChange:"",bindInput:"",bindConfirm:"",name:""},j={src:"",bindLoad:"eh",bindError:"eh"},P=Object.assign({"scroll-top":"false"},c),R={"scale-area":"false"},D=Object.assign(Object.assign({direction:"none",inertia:"false","out-of-bounds":"false",x:"",y:"",damping:"20",friction:"2",disabled:"",scale:"false","scale-min":"0.5","scale-max":"10","scale-value":"1",animation:"true",bindChange:"",bindScale:"",bindHTouchMove:"",bindVTouchMove:"",width:h("10px"),height:h("10px")},c),l),M=Object.assign(Object.assign({"scroll-x":"false","scroll-y":"false","upper-threshold":"50","lower-threshold":"50","scroll-top":"","scroll-left":"","scroll-into-view":"","scroll-with-animation":"false","enable-back-to-top":"false",bindScrollToUpper:"",bindScrollToLower:"",bindScroll:""},c),l),L=Object.assign({"indicator-dots":"false","indicator-color":h("rgba(0, 0, 0, .3)"),"indicator-active-color":h("#000000"),autoplay:"false",current:"0",interval:"5000",duration:"500",circular:"false",vertical:"false","previous-margin":"'0px'","next-margin":"'0px'","display-multiple-items":"1",bindChange:"",bindTransition:"",bindAnimationFinish:""},c),V={"item-id":""},F={url:"","open-type":h("navigate"),delta:"1","hover-class":h("navigator-hover"),"hover-stop-propagation":"false","hover-start-time":"50","hover-stay-time":"600",bindSuccess:"",bindFail:"",bindComplete:""},B={id:"",src:"",loop:"false",controls:"false",poster:"",name:"",author:"",bindError:"",bindPlay:"",bindPause:"",bindTimeUpdate:"",bindEnded:""},U={"device-position":h("back"),flash:h("auto"),bindStop:"",bindError:""},H=Object.assign({src:"",mode:h("scaleToFill"),"lazy-load":"false",bindError:"",bindLoad:""},c),W={src:"",autoplay:"false",muted:"false",orientation:h("vertical"),"object-fit":h("contain"),"background-mute":"false","min-cache":"1","max-cache":"3",animation:"",bindStateChange:"",bindFullScreenChange:"",bindNetStatus:""},G={src:"",duration:"",controls:"true","danmu-list":"","danmu-btn":"","enable-danmu":"",autoplay:"false",loop:"false",muted:"false","initial-time":"0","page-gesture":"false",direction:"","show-progress":"true","show-fullscreen-btn":"true","show-play-btn":"true","show-center-play-btn":"true","enable-progress-gesture":"true","object-fit":h("contain"),poster:"","show-mute-btn":"false",animation:"",bindPlay:"",bindPause:"",bindEnded:"",bindTimeUpdate:"",bindFullScreenChange:"",bindWaiting:"",bindError:""},$=Object.assign({"canvas-id":"","disable-scroll":"false",bindError:""},c),q={"unit-id":"","ad-intervals":"",bindLoad:"",bindError:"",bindClose:""},z={src:"",bindMessage:"",bindLoad:"",bindError:""},Y={},K={name:""},J={name:""},X={View:p,Icon:f,Progress:v,RichText:g,Text:y,Button:m,Checkbox:b,CheckboxGroup:_,Form:w,Input:x,Label:E,Picker:O,PickerView:S,PickerViewColumn:T,Radio:k,RadioGroup:A,Slider:C,Switch:N,CoverImage:j,Textarea:I,CoverView:P,MovableArea:R,MovableView:D,ScrollView:M,Swiper:L,SwiperItem:V,Navigator:F,Audio:B,Camera:U,Image:H,LivePlayer:W,Video:G,Canvas:$,Ad:q,WebView:z,Block:Y,Map:d,Slot:J,SlotView:K},Q=new Set(["input","checkbox","picker","picker-view","radio","slider","switch","textarea"]),Z=(new Set(["input","textarea"]),new Set(["progress","icon","rich-text","input","textarea","slider","switch","audio","ad","official-account","open-data","navigation-bar"]),new Map([["view",-1],["catch-view",-1],["cover-view",-1],["static-view",-1],["pure-view",-1],["block",-1],["text",-1],["static-text",6],["slot",8],["slot-view",8],["label",6],["form",4],["scroll-view",4],["swiper",4],["swiper-item",4]]),{}),tt=function(){},et=Object.create(null);function nt(t){return t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}function rt(t){for(var e="",n=!1,r=0;r= than the number of constructor arguments of its base class."},U="Invalid Container constructor argument. Container options must be an object.",H="Invalid Container option. Default scope must be a string ('singleton' or 'transient').",W="Invalid Container option. Auto bind injectable must be a boolean",G="Invalid Container option. Skip base check must be a boolean",$=function(){for(var t=[],e=0;e0,l=u.length>n.length,h=c||l?u.length:n.length,p=mt(r,e,a,s,h),f=bt(t,n),d=dt(dt([],p),f);return d}function yt(t,e,n,r,i){var a=i[t.toString()]||[],o=wt(a),s=!0!==o.unmanaged,u=r[t],c=o.inject||o.multiInject;if(u=c||u,u instanceof lt&&(u=u.unwrap()),s){var l=u===Object,h=u===Function,p=void 0===u,f=l||h||p;if(!e&&f){var d=I+" argument "+t+" in class "+n+".";throw new Error(d)}var v=new ft(b.ConstructorArgument,o.targetName,u);return v.metadata=a,v}return null}function mt(t,e,n,r,i){for(var a=[],o=0;o0?u:_t(t,n)}return 0}function wt(t){var e={};return t.forEach((function(t){e[t.key.toString()]=t.value})),{inject:e[u],multiInject:e[c],targetName:e[a],unmanaged:e[o]}}var xt=function(){function t(t,e,n,r,i){this.id=w(),this.serviceIdentifier=t,this.parentContext=e,this.parentRequest=n,this.target=i,this.childRequests=[],this.bindings=Array.isArray(r)?r:[r],this.requestScope=null===n?new Map:null}return t.prototype.addChildRequest=function(e,n,r){var i=new t(e,this.parentContext,this,n,r);return this.childRequests.push(i),i},t}();function Et(t){return t._bindingDictionary}function Ot(t,e,n,r,i,a){var o=t?c:u,s=new at(o,n),l=new ft(e,r,n,s);if(void 0!==i){var h=new at(i,a);l.metadata.push(h)}return l}function St(t,e,n,r,i){var a=At(n.container,i.serviceIdentifier),o=[];return a.length===K.NoBindingsAvailable&&n.container.options.autoBindInjectable&&"function"===typeof i.serviceIdentifier&&t.getConstructorMetadata(i.serviceIdentifier).compilerGeneratedMetadata&&(n.container.bind(i.serviceIdentifier).toSelf(),a=At(n.container,i.serviceIdentifier)),o=e?a:a.filter((function(t){var e=new xt(t.serviceIdentifier,n,r,t,i);return t.constraint(e)})),Tt(i.serviceIdentifier,o,i,n.container),o}function Tt(t,e,n,r){switch(e.length){case K.NoBindingsAvailable:if(n.isOptional())return e;var i=X(t),a=C;throw a+=nt(i,n),a+=Q(r,i,At),new Error(a);case K.OnlyOneBindingAvailable:if(!n.isArray())return e;case K.MultipleBindingsAvailable:default:if(n.isArray())return e;i=X(t),a=k+" "+i;throw a+=Q(r,i,At),new Error(a)}}function kt(t,e,n,r,i,a){var o,s;if(null===i){o=St(t,e,r,null,a),s=new xt(n,r,null,o,a);var u=new ot(r,s);r.addPlan(u)}else o=St(t,e,r,i,a),s=i.addChildRequest(a.serviceIdentifier,o,a);o.forEach((function(e){var n=null;if(a.isArray())n=s.addChildRequest(e.serviceIdentifier,e,a);else{if(e.cache)return;n=s}if(e.type===m.Instance&&null!==e.implementationType){var i=vt(t,e.implementationType);if(!r.container.options.skipBaseClassChecks){var o=_t(t,e.implementationType);if(i.length0){var i=e.filter((function(t){return null!==t.target&&t.target.type===b.ConstructorArgument})),a=i.map(n);r=Pt(t,a),r=jt(r,e,n)}else r=new t;return Rt(t,r),r}var Mt=function(t,e,n){try{return n()}catch(n){throw J(n)?new Error(q(t,e.toString())):n}},Lt=function(t){return function(e){e.parentContext.setCurrentRequest(e);var n=e.bindings,r=e.childRequests,i=e.target&&e.target.isArray(),a=!e.parentRequest||!e.parentRequest.target||!e.target||!e.parentRequest.target.matchesArray(e.target.serviceIdentifier);if(i&&a)return r.map((function(e){var n=Lt(t);return n(e)}));var o=null;if(!e.target.isOptional()||0!==n.length){var s=n[0],u=s.scope===y.Singleton,c=s.scope===y.Request;if(u&&s.activated)return s.cache;if(c&&null!==t&&t.has(s.id))return t.get(s.id);if(s.type===m.ConstantValue)o=s.cache,s.activated=!0;else if(s.type===m.Function)o=s.cache,s.activated=!0;else if(s.type===m.Constructor)o=s.implementationType;else if(s.type===m.DynamicValue&&null!==s.dynamicValue)o=Mt("toDynamicValue",s.serviceIdentifier,(function(){return s.dynamicValue(e.parentContext)}));else if(s.type===m.Factory&&null!==s.factory)o=Mt("toFactory",s.serviceIdentifier,(function(){return s.factory(e.parentContext)}));else if(s.type===m.Provider&&null!==s.provider)o=Mt("toProvider",s.serviceIdentifier,(function(){return s.provider(e.parentContext)}));else{if(s.type!==m.Instance||null===s.implementationType){var l=X(e.serviceIdentifier);throw new Error(R+" "+l)}o=Dt(s.implementationType,r,Lt(t))}return"function"===typeof s.onActivation&&(o=s.onActivation(e.parentContext,o)),u&&(s.cache=o,s.activated=!0),c&&null!==t&&!t.has(s.id)&&t.set(s.id,o),o}}};function Vt(t){var e=Lt(t.plan.rootRequest.requestScope);return e(t.plan.rootRequest)}var Ft=function(t,e){var n=t.parentRequest;return null!==n&&(!!e(n)||Ft(n,e))},Bt=function(t){return function(e){var n=function(n){return null!==n&&null!==n.target&&n.target.matchesTag(t)(e)};return n.metaData=new at(t,e),n}},Ut=Bt(i),Ht=function(t){return function(e){var n=null;if(null!==e){if(n=e.bindings[0],"string"===typeof t){var r=n.serviceIdentifier;return r===t}var i=e.bindings[0].implementationType;return t===i}return!1}},Wt=function(){function t(t){this._binding=t}return t.prototype.when=function(t){return this._binding.constraint=t,new Gt(this._binding)},t.prototype.whenTargetNamed=function(t){return this._binding.constraint=Ut(t),new Gt(this._binding)},t.prototype.whenTargetIsDefault=function(){return this._binding.constraint=function(t){var e=null!==t.target&&!t.target.isNamed()&&!t.target.isTagged();return e},new Gt(this._binding)},t.prototype.whenTargetTagged=function(t,e){return this._binding.constraint=Bt(t)(e),new Gt(this._binding)},t.prototype.whenInjectedInto=function(t){return this._binding.constraint=function(e){return Ht(t)(e.parentRequest)},new Gt(this._binding)},t.prototype.whenParentNamed=function(t){return this._binding.constraint=function(e){return Ut(t)(e.parentRequest)},new Gt(this._binding)},t.prototype.whenParentTagged=function(t,e){return this._binding.constraint=function(n){return Bt(t)(e)(n.parentRequest)},new Gt(this._binding)},t.prototype.whenAnyAncestorIs=function(t){return this._binding.constraint=function(e){return Ft(e,Ht(t))},new Gt(this._binding)},t.prototype.whenNoAncestorIs=function(t){return this._binding.constraint=function(e){return!Ft(e,Ht(t))},new Gt(this._binding)},t.prototype.whenAnyAncestorNamed=function(t){return this._binding.constraint=function(e){return Ft(e,Ut(t))},new Gt(this._binding)},t.prototype.whenNoAncestorNamed=function(t){return this._binding.constraint=function(e){return!Ft(e,Ut(t))},new Gt(this._binding)},t.prototype.whenAnyAncestorTagged=function(t,e){return this._binding.constraint=function(n){return Ft(n,Bt(t)(e))},new Gt(this._binding)},t.prototype.whenNoAncestorTagged=function(t,e){return this._binding.constraint=function(n){return!Ft(n,Bt(t)(e))},new Gt(this._binding)},t.prototype.whenAnyAncestorMatches=function(t){return this._binding.constraint=function(e){return Ft(e,t)},new Gt(this._binding)},t.prototype.whenNoAncestorMatches=function(t){return this._binding.constraint=function(e){return!Ft(e,t)},new Gt(this._binding)},t}(),Gt=function(){function t(t){this._binding=t}return t.prototype.onActivation=function(t){return this._binding.onActivation=t,new Wt(this._binding)},t}(),$t=function(){function t(t){this._binding=t,this._bindingWhenSyntax=new Wt(this._binding),this._bindingOnSyntax=new Gt(this._binding)}return t.prototype.when=function(t){return this._bindingWhenSyntax.when(t)},t.prototype.whenTargetNamed=function(t){return this._bindingWhenSyntax.whenTargetNamed(t)},t.prototype.whenTargetIsDefault=function(){return this._bindingWhenSyntax.whenTargetIsDefault()},t.prototype.whenTargetTagged=function(t,e){return this._bindingWhenSyntax.whenTargetTagged(t,e)},t.prototype.whenInjectedInto=function(t){return this._bindingWhenSyntax.whenInjectedInto(t)},t.prototype.whenParentNamed=function(t){return this._bindingWhenSyntax.whenParentNamed(t)},t.prototype.whenParentTagged=function(t,e){return this._bindingWhenSyntax.whenParentTagged(t,e)},t.prototype.whenAnyAncestorIs=function(t){return this._bindingWhenSyntax.whenAnyAncestorIs(t)},t.prototype.whenNoAncestorIs=function(t){return this._bindingWhenSyntax.whenNoAncestorIs(t)},t.prototype.whenAnyAncestorNamed=function(t){return this._bindingWhenSyntax.whenAnyAncestorNamed(t)},t.prototype.whenAnyAncestorTagged=function(t,e){return this._bindingWhenSyntax.whenAnyAncestorTagged(t,e)},t.prototype.whenNoAncestorNamed=function(t){return this._bindingWhenSyntax.whenNoAncestorNamed(t)},t.prototype.whenNoAncestorTagged=function(t,e){return this._bindingWhenSyntax.whenNoAncestorTagged(t,e)},t.prototype.whenAnyAncestorMatches=function(t){return this._bindingWhenSyntax.whenAnyAncestorMatches(t)},t.prototype.whenNoAncestorMatches=function(t){return this._bindingWhenSyntax.whenNoAncestorMatches(t)},t.prototype.onActivation=function(t){return this._bindingOnSyntax.onActivation(t)},t}(),qt=function(){function t(t){this._binding=t}return t.prototype.inRequestScope=function(){return this._binding.scope=y.Request,new $t(this._binding)},t.prototype.inSingletonScope=function(){return this._binding.scope=y.Singleton,new $t(this._binding)},t.prototype.inTransientScope=function(){return this._binding.scope=y.Transient,new $t(this._binding)},t}(),zt=function(){function t(t){this._binding=t,this._bindingWhenSyntax=new Wt(this._binding),this._bindingOnSyntax=new Gt(this._binding),this._bindingInSyntax=new qt(t)}return t.prototype.inRequestScope=function(){return this._bindingInSyntax.inRequestScope()},t.prototype.inSingletonScope=function(){return this._bindingInSyntax.inSingletonScope()},t.prototype.inTransientScope=function(){return this._bindingInSyntax.inTransientScope()},t.prototype.when=function(t){return this._bindingWhenSyntax.when(t)},t.prototype.whenTargetNamed=function(t){return this._bindingWhenSyntax.whenTargetNamed(t)},t.prototype.whenTargetIsDefault=function(){return this._bindingWhenSyntax.whenTargetIsDefault()},t.prototype.whenTargetTagged=function(t,e){return this._bindingWhenSyntax.whenTargetTagged(t,e)},t.prototype.whenInjectedInto=function(t){return this._bindingWhenSyntax.whenInjectedInto(t)},t.prototype.whenParentNamed=function(t){return this._bindingWhenSyntax.whenParentNamed(t)},t.prototype.whenParentTagged=function(t,e){return this._bindingWhenSyntax.whenParentTagged(t,e)},t.prototype.whenAnyAncestorIs=function(t){return this._bindingWhenSyntax.whenAnyAncestorIs(t)},t.prototype.whenNoAncestorIs=function(t){return this._bindingWhenSyntax.whenNoAncestorIs(t)},t.prototype.whenAnyAncestorNamed=function(t){return this._bindingWhenSyntax.whenAnyAncestorNamed(t)},t.prototype.whenAnyAncestorTagged=function(t,e){return this._bindingWhenSyntax.whenAnyAncestorTagged(t,e)},t.prototype.whenNoAncestorNamed=function(t){return this._bindingWhenSyntax.whenNoAncestorNamed(t)},t.prototype.whenNoAncestorTagged=function(t,e){return this._bindingWhenSyntax.whenNoAncestorTagged(t,e)},t.prototype.whenAnyAncestorMatches=function(t){return this._bindingWhenSyntax.whenAnyAncestorMatches(t)},t.prototype.whenNoAncestorMatches=function(t){return this._bindingWhenSyntax.whenNoAncestorMatches(t)},t.prototype.onActivation=function(t){return this._bindingOnSyntax.onActivation(t)},t}(),Yt=function(){function t(t){this._binding=t}return t.prototype.to=function(t){return this._binding.type=m.Instance,this._binding.implementationType=t,new zt(this._binding)},t.prototype.toSelf=function(){if("function"!==typeof this._binding.serviceIdentifier)throw new Error(""+V);var t=this._binding.serviceIdentifier;return this.to(t)},t.prototype.toConstantValue=function(t){return this._binding.type=m.ConstantValue,this._binding.cache=t,this._binding.dynamicValue=null,this._binding.implementationType=null,this._binding.scope=y.Singleton,new $t(this._binding)},t.prototype.toDynamicValue=function(t){return this._binding.type=m.DynamicValue,this._binding.cache=null,this._binding.dynamicValue=t,this._binding.implementationType=null,new zt(this._binding)},t.prototype.toConstructor=function(t){return this._binding.type=m.Constructor,this._binding.implementationType=t,this._binding.scope=y.Singleton,new $t(this._binding)},t.prototype.toFactory=function(t){return this._binding.type=m.Factory,this._binding.factory=t,this._binding.scope=y.Singleton,new $t(this._binding)},t.prototype.toFunction=function(t){if("function"!==typeof t)throw new Error(L);var e=this.toConstantValue(t);return this._binding.type=m.Function,this._binding.scope=y.Singleton,e},t.prototype.toAutoFactory=function(t){return this._binding.type=m.Factory,this._binding.factory=function(e){var n=function(){return e.container.get(t)};return n},this._binding.scope=y.Singleton,new $t(this._binding)},t.prototype.toProvider=function(t){return this._binding.type=m.Provider,this._binding.provider=t,this._binding.scope=y.Singleton,new $t(this._binding)},t.prototype.toService=function(t){this.toDynamicValue((function(e){return e.container.get(t)}))},t}(),Kt=function(){function t(){}return t.of=function(e,n){var r=new t;return r.bindings=e,r.middleware=n,r},t}(),Jt=function(){function t(){this._map=new Map}return t.prototype.getMap=function(){return this._map},t.prototype.add=function(t,e){if(null===t||void 0===t)throw new Error(S);if(null===e||void 0===e)throw new Error(S);var n=this._map.get(t);void 0!==n?(n.push(e),this._map.set(t,n)):this._map.set(t,[e])},t.prototype.get=function(t){if(null===t||void 0===t)throw new Error(S);var e=this._map.get(t);if(void 0!==e)return e;throw new Error(T)},t.prototype.remove=function(t){if(null===t||void 0===t)throw new Error(S);if(!this._map.delete(t))throw new Error(T)},t.prototype.removeByCondition=function(t){var e=this;this._map.forEach((function(n,r){var i=n.filter((function(e){return!t(e)}));i.length>0?e._map.set(r,i):e._map.delete(r)}))},t.prototype.hasKey=function(t){if(null===t||void 0===t)throw new Error(S);return this._map.has(t)},t.prototype.clone=function(){var e=new t;return this._map.forEach((function(t,n){t.forEach((function(t){return e.add(n,t.clone())}))})),e},t.prototype.traverse=function(t){this._map.forEach((function(e,n){t(n,e)}))},t}(),Xt=function(t,e,n,r){function i(t){return t instanceof n?t:new n((function(e){e(t)}))}return new(n||(n=Promise))((function(n,a){function o(t){try{u(r.next(t))}catch(t){a(t)}}function s(t){try{u(r["throw"](t))}catch(t){a(t)}}function u(t){t.done?n(t.value):i(t.value).then(o,s)}u((r=r.apply(t,e||[])).next())}))},Qt=function(t,e){var n,r,i,a,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return a={next:s(0),throw:s(1),return:s(2)},"function"===typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(t){return function(e){return u([t,e])}}function u(a){if(n)throw new TypeError("Generator is already executing.");while(o)try{if(n=1,r&&(i=2&a[0]?r["return"]:a[0]?r["throw"]||((i=r["return"])&&i.call(r),0):r.next)&&!(i=i.call(r,a[1])).done)return i;switch(r=0,i&&(a=[2&a[0],i.value]),a[0]){case 0:case 1:i=a;break;case 4:return o.label++,{value:a[1],done:!1};case 5:o.label++,r=a[1],a=[0];continue;case 7:a=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(6===a[0]||2===a[0])){o=0;continue}if(3===a[0]&&(!i||a[1]>i[0]&&a[1]=e?t:""+Array(e+1-r.length).join(n)+t},m={s:y,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+y(r,2,"0")+":"+y(i,2,"0")},m:function t(e,n){if(e.date()=0;s--)(i=t[s])&&(o=(a<3?i(o):a>3?i(e,n,o):i(e,n))||o);return a>3&&o&&Object.defineProperty(e,n,o),o}function A(t,e){return function(n,r){e(n,r,t)}}function C(t,e){if("object"===("undefined"===typeof Reflect?"undefined":Object(O["a"])(Reflect))&&"function"===typeof Reflect.metadata)return Reflect.metadata(t,e)}(function(e){(function(t){var n=r(e);function r(t,e){return function(n,r){"function"!==typeof t[n]&&Object.defineProperty(t,n,{configurable:!0,writable:!0,value:r}),e&&e(n,r)}}t(n)})((function(e){var n=Object.prototype.hasOwnProperty,r="function"===typeof Symbol,i=r&&"undefined"!==typeof Symbol.toPrimitive?Symbol.toPrimitive:"@@toPrimitive",a=r&&"undefined"!==typeof Symbol.iterator?Symbol.iterator:"@@iterator",o="function"===typeof Object.create,s={__proto__:[]}instanceof Array,u=!o&&!s,c={create:o?function(){return ot(Object.create(null))}:s?function(){return ot({__proto__:null})}:function(){return ot({})},has:u?function(t,e){return n.call(t,e)}:function(t,e){return e in t},get:u?function(t,e){return n.call(t,e)?t[e]:void 0}:function(t,e){return t[e]}},l=Object.getPrototypeOf(Function),h="object"===("undefined"===typeof t?"undefined":Object(O["a"])(t))&&t.env&&"true"===t.env["REFLECT_METADATA_USE_MAP_POLYFILL"],p=h||"function"!==typeof Map||"function"!==typeof Map.prototype.entries?rt():Map,f=h||"function"!==typeof Set||"function"!==typeof Set.prototype.entries?it():Set,d=h||"function"!==typeof WeakMap?at():WeakMap,v=new d;function g(t,e,n,r){if(V(n)){if(!z(t))throw new TypeError;if(!K(e))throw new TypeError;return k(t,e)}if(!z(t))throw new TypeError;if(!U(e))throw new TypeError;if(!U(r)&&!V(r)&&!F(r))throw new TypeError;return F(r)&&(r=void 0),n=q(n),A(t,e,n,r)}function y(t,e){function n(n,r){if(!U(n))throw new TypeError;if(!V(r)&&!J(r))throw new TypeError;R(t,e,n,r)}return n}function m(t,e,n,r){if(!U(n))throw new TypeError;return V(r)||(r=q(r)),R(t,e,n,r)}function b(t,e,n){if(!U(e))throw new TypeError;return V(n)||(n=q(n)),N(t,e,n)}function _(t,e,n){if(!U(e))throw new TypeError;return V(n)||(n=q(n)),I(t,e,n)}function w(t,e,n){if(!U(e))throw new TypeError;return V(n)||(n=q(n)),j(t,e,n)}function x(t,e,n){if(!U(e))throw new TypeError;return V(n)||(n=q(n)),P(t,e,n)}function E(t,e){if(!U(t))throw new TypeError;return V(e)||(e=q(e)),D(t,e)}function S(t,e){if(!U(t))throw new TypeError;return V(e)||(e=q(e)),M(t,e)}function T(t,e,n){if(!U(e))throw new TypeError;V(n)||(n=q(n));var r=C(e,n,!1);if(V(r))return!1;if(!r.delete(t))return!1;if(r.size>0)return!0;var i=v.get(e);return i.delete(n),i.size>0||v.delete(e),!0}function k(t,e){for(var n=t.length-1;n>=0;--n){var r=t[n],i=r(e);if(!V(i)&&!F(i)){if(!K(i))throw new TypeError;e=i}}return e}function A(t,e,n,r){for(var i=t.length-1;i>=0;--i){var a=t[i],o=a(e,n,r);if(!V(o)&&!F(o)){if(!U(o))throw new TypeError;r=o}}return r}function C(t,e,n){var r=v.get(t);if(V(r)){if(!n)return;r=new p,v.set(t,r)}var i=r.get(e);if(V(i)){if(!n)return;i=new p,r.set(e,i)}return i}function N(t,e,n){var r=I(t,e,n);if(r)return!0;var i=nt(e);return!F(i)&&N(t,i,n)}function I(t,e,n){var r=C(e,n,!1);return!V(r)&&G(r.has(t))}function j(t,e,n){var r=I(t,e,n);if(r)return P(t,e,n);var i=nt(e);return F(i)?void 0:j(t,i,n)}function P(t,e,n){var r=C(e,n,!1);if(!V(r))return r.get(t)}function R(t,e,n,r){var i=C(n,r,!0);i.set(t,e)}function D(t,e){var n=M(t,e),r=nt(t);if(null===r)return n;var i=D(r,e);if(i.length<=0)return n;if(n.length<=0)return i;for(var a=new f,o=[],s=0,u=n;s=0&&t=this._keys.length?(this._index=-1,this._keys=e,this._values=e):this._index++,{value:n,done:!1}}return{value:void 0,done:!0}},t.prototype.throw=function(t){throw this._index>=0&&(this._index=-1,this._keys=e,this._values=e),t},t.prototype.return=function(t){return this._index>=0&&(this._index=-1,this._keys=e,this._values=e),{value:t,done:!0}},t}();return function(){function e(){this._keys=[],this._values=[],this._cacheKey=t,this._cacheIndex=-2}return Object.defineProperty(e.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),e.prototype.has=function(t){return this._find(t,!1)>=0},e.prototype.get=function(t){var e=this._find(t,!1);return e>=0?this._values[e]:void 0},e.prototype.set=function(t,e){var n=this._find(t,!0);return this._values[n]=e,this},e.prototype.delete=function(e){var n=this._find(e,!1);if(n>=0){for(var r=this._keys.length,i=n+1;i",TaroText:"TaroText",TaroTextFactory:"Factory",TaroNodeImpl:"TaroNodeImpl",TaroElementImpl:"TaroElementImpl",Hooks:"hooks",onRemoveAttribute:"onRemoveAttribute",getLifecycle:"getLifecycle",getPathIndex:"getPathIndex",getEventCenter:"getEventCenter",isBubbleEvents:"isBubbleEvents",getSpecialNodes:"getSpecialNodes",eventCenter:"eventCenter",modifyMpEvent:"modifyMpEvent",modifyTaroEvent:"modifyTaroEvent",batchedEventUpdates:"batchedEventUpdates",mergePageInstance:"mergePageInstance",createPullDownComponent:"createPullDownComponent",getDOMNode:"getDOMNode",initNativeApi:"initNativeApi",modifyHydrateData:"modifyHydrateData",modifySetAttrPayload:"modifySetAttrPayload",modifyRmAttrPayload:"modifyRmAttrPayload",onAddEvent:"onAddEvent",patchElement:"patchElement"},I="taro-app",j="\u5c0f\u7a0b\u5e8f setData",P="\u9875\u9762\u521d\u59cb\u5316",R="root",D="html",M="head",L="body",V="app",F="container",B="#document",U="document-fragment",H="id",W="uid",G="class",$="style",q="focus",z="view",Y="static-view",K="pure-view",J="props",X="dataset",Q="object",Z="value",tt="input",et="change",nt="custom-wrapper",rt="target",it="currentTarget",at="type",ot="confirm",st="timeStamp",ut="keyCode",ct="touchmove",lt="Date",ht="setTimeout",pt="catchMove",ft="catch-view",dt="comment",vt=function(){var t=0;return function(){return(t++).toString()}};function gt(t){return 1===t.nodeType}function yt(t){return 3===t.nodeType}function mt(t){return t.nodeName===dt}function bt(t){var e=Object.keys(t.props).find((function(t){return!(/^(class|style|id)$/.test(t)||t.startsWith("data-"))}));return Boolean(e)}function _t(t,e){var n,r=!1;while((null===t||void 0===t?void 0:t.parentElement)&&t.parentElement._path!==R){if(null===(n=t.parentElement.__handlers[e])||void 0===n?void 0:n.length){r=!0;break}t=t.parentElement}return r}function wt(t){switch(t){case $:return"st";case H:return W;case G:return"cl";default:return t}}var xt=function(){function t(e){Object(x["a"])(this,t),this.__handlers={},this.hooks=e}return Object(E["a"])(t,[{key:"addEventListener",value:function(t,e,n){var r,i;if(null===(i=(r=this.hooks).onAddEvent)||void 0===i||i.call(r,t,e,n,this),"regionchange"===t)return this.addEventListener("begin",e,n),void this.addEventListener("end",e,n);t=t.toLowerCase();var a=this.__handlers[t],o=(Boolean(n),!1);if(Object(T["i"])(n)&&(Boolean(n.capture),o=Boolean(n.once)),o){var s=function n(){e.apply(this,arguments),this.removeEventListener(t,n)};this.addEventListener(t,s,Object.assign(Object.assign({},n),{once:!1}))}else Object(T["f"])(a)?a.push(e):this.__handlers[t]=[e]}},{key:"removeEventListener",value:function(t,e){if(t=t.toLowerCase(),null!=e){var n=this.__handlers[t];if(Object(T["f"])(n)){var r=n.indexOf(e);n.splice(r,1)}}}},{key:"isAnyEventBinded",value:function(){var t=this.__handlers,e=Object.keys(t).find((function(e){return t[e].length}));return Boolean(e)}}]),t}();function Et(t){var e,n,r,i,a=t.nodeName;if(yt(t))return i={},Object(w["a"])(i,"v",t.nodeValue),Object(w["a"])(i,"nn",a),i;var o=(e={},Object(w["a"])(e,"nn",a),Object(w["a"])(e,"uid",t.uid),e),s=t.props,u=t.hooks.getSpecialNodes();for(var c in!t.isAnyEventBinded()&&u.indexOf(a)>-1&&(o["nn"]="static-".concat(a),a!==z||bt(t)||(o["nn"]=K)),s){var l=Object(T["l"])(c);c.startsWith("data-")||c===G||c===$||c===H||l===pt||(o[l]=s[c]),a===z&&l===pt&&!1!==s[c]&&(o["nn"]=ft)}var h=t.childNodes;return h=h.filter((function(t){return!mt(t)})),h.length>0?o["cn"]=h.map(Et):o["cn"]=[],""!==t.className&&(o["cl"]=t.className),""!==t.cssText&&"swiper-item"!==a&&(o["st"]=t.cssText),null===(r=(n=t.hooks).modifyHydrateData)||void 0===r||r.call(n,o),o}xt=k([Object(S["d"])(),A(0,Object(S["c"])(N.Hooks)),C("design:paramtypes",[Object])],xt);var Ot,St=new Map;(function(t){t["Element"]="Element",t["Document"]="Document",t["RootElement"]="RootElement",t["FormElement"]="FormElement"})(Ot||(Ot={}));var Tt=vt(),kt=function(t){Object(b["a"])(n,t);var e=Object(_["a"])(n);function n(t,r,i){var a;return Object(x["a"])(this,n),a=e.call(this,i),a.parentNode=null,a.childNodes=[],a.hydrate=function(t){return function(){return Et(t)}},t.bind(Object(m["a"])(a)),a._getElement=r,a.uid="_n_".concat(Tt()),St.set(a.uid,Object(m["a"])(a)),a}return Object(E["a"])(n,[{key:"_empty",value:function(){while(this.childNodes.length>0){var t=this.childNodes[0];t.parentNode=null,St.delete(t.uid),this.childNodes.shift()}}},{key:"_root",get:function(){var t;return(null===(t=this.parentNode)||void 0===t?void 0:t._root)||null}},{key:"findIndex",value:function(t){var e=this.childNodes.indexOf(t);return Object(T["d"])(-1!==e,"The node to be replaced is not a child of this node."),e}},{key:"_path",get:function(){var t=this.parentNode;if(t){var e=t.childNodes.filter((function(t){return!mt(t)})),n=e.indexOf(this),r=this.hooks.getPathIndex(n);return"".concat(t._path,".","cn",".").concat(r)}return""}},{key:"nextSibling",get:function(){var t=this.parentNode;return(null===t||void 0===t?void 0:t.childNodes[t.findIndex(this)+1])||null}},{key:"previousSibling",get:function(){var t=this.parentNode;return(null===t||void 0===t?void 0:t.childNodes[t.findIndex(this)-1])||null}},{key:"parentElement",get:function(){var t=this.parentNode;return 1===(null===t||void 0===t?void 0:t.nodeType)?t:null}},{key:"firstChild",get:function(){return this.childNodes[0]||null}},{key:"lastChild",get:function(){var t=this.childNodes;return t[t.length-1]||null}},{key:"textContent",set:function(t){if(this._empty(),""===t)this.enqueueUpdate({path:"".concat(this._path,".","cn"),value:function(){return[]}});else{var e=this._getElement(Ot.Document)();this.appendChild(e.createTextNode(t))}}},{key:"insertBefore",value:function(t,e,n){var r,i=this;if(t.nodeName===U)return t.childNodes.reduceRight((function(t,e){return i.insertBefore(e,t),e}),e),t;if(t.remove(),t.parentNode=this,e){var a=this.findIndex(e);this.childNodes.splice(a,0,t),r=n?{path:t._path,value:this.hydrate(t)}:{path:"".concat(this._path,".","cn"),value:function(){var t=i.childNodes.filter((function(t){return!mt(t)}));return t.map(Et)}}}else this.childNodes.push(t),r={path:t._path,value:this.hydrate(t)};return this.enqueueUpdate(r),St.has(t.uid)||St.set(t.uid,t),t}},{key:"appendChild",value:function(t){this.insertBefore(t)}},{key:"replaceChild",value:function(t,e){if(e.parentNode===this)return this.insertBefore(t,e,!0),e.remove(!0),e}},{key:"removeChild",value:function(t,e){var n=this,r=this.findIndex(t);return this.childNodes.splice(r,1),e||this.enqueueUpdate({path:"".concat(this._path,".","cn"),value:function(){var t=n.childNodes.filter((function(t){return!mt(t)}));return t.map(Et)}}),t.parentNode=null,St.delete(t.uid),t}},{key:"remove",value:function(t){var e;null===(e=this.parentNode)||void 0===e||e.removeChild(this,t)}},{key:"hasChildNodes",value:function(){return this.childNodes.length>0}},{key:"enqueueUpdate",value:function(t){var e;null===(e=this._root)||void 0===e||e.enqueueUpdate(t)}},{key:"contains",value:function(t){var e=!1;return this.childNodes.some((function(n){var r=n.uid;if(r===t.uid||r===t.id||n.contains(t))return e=!0,!0})),e}},{key:"ownerDocument",get:function(){var t=this._getElement(Ot.Document)();return t}}]),n}(xt);kt=k([Object(S["d"])(),A(0,Object(S["c"])(N.TaroNodeImpl)),A(1,Object(S["c"])(N.TaroElementFactory)),A(2,Object(S["c"])(N.Hooks)),C("design:paramtypes",[Function,Function,Function])],kt);var At=function(t){Object(b["a"])(n,t);var e=Object(_["a"])(n);function n(t,r,i){var a;return Object(x["a"])(this,n),a=e.call(this,t,r,i),a.nodeType=3,a.nodeName="#text",a}return Object(E["a"])(n,[{key:"textContent",get:function(){return this._value},set:function(t){this._value=t,this.enqueueUpdate({path:"".concat(this._path,".","v"),value:t})}},{key:"nodeValue",get:function(){return this._value},set:function(t){this.textContent=t}}]),n}(kt);At=k([Object(S["d"])(),A(0,Object(S["c"])(N.TaroNodeImpl)),A(1,Object(S["c"])(N.TaroElementFactory)),A(2,Object(S["c"])(N.Hooks)),C("design:paramtypes",[Function,Function,Function])],At);var Ct=["all","appearance","blockOverflow","blockSize","bottom","clear","contain","content","continue","cursor","direction","display","filter","float","gap","height","inset","isolation","left","letterSpacing","lightingColor","markerSide","mixBlendMode","opacity","order","position","quotes","resize","right","rowGap","tabSize","tableLayout","top","userSelect","verticalAlign","visibility","voiceFamily","volume","whiteSpace","widows","width","zIndex","pointerEvents"];function Nt(t,e,n){!n&&Ct.push(t),e.forEach((function(e){Ct.push(t+e)}))}var It="Color",jt="Style",Pt="Width",Rt="Image",Dt="Size",Mt=[It,jt,Pt],Lt=["FitLength","FitWidth",Rt],Vt=[].concat(Lt,["Radius"]),Ft=[].concat(Mt,Lt),Bt=["EndRadius","StartRadius"],Ut=["Bottom","Left","Right","Top"],Ht=["End","Start"],Wt=["Content","Items","Self"],Gt=["BlockSize","Height","InlineSize",Pt],$t=["After","Before"];function qt(t,e){var n=this[e];t&&this._usedStyleProp.add(e),n!==t&&(this._value[e]=t,this._element.enqueueUpdate({path:"".concat(this._element._path,".","st"),value:this.cssText}))}function zt(t){for(var e={},n=function(t){var n=Ct[t];e[n]={get:function(){return this._value[n]||""},set:function(t){qt.call(this,t,n)}}},r=0;r0}},{key:"focus",value:function(){this.setAttribute(q,!0)}},{key:"blur",value:function(){this.setAttribute(q,!1)}},{key:"setAttribute",value:function(t,e){var n,r,i=this.nodeName===z&&!bt(this)&&!this.isAnyEventBinded();switch(t){case $:this.style.cssText=e;break;case H:St.delete(this.uid),e=String(e),this.props[t]=this.uid=e,St.set(e,this);break;default:this.props[t]=e,t.startsWith("data-")&&(this.dataset===T["a"]&&(this.dataset=Object.create(null)),this.dataset[Object(T["l"])(t.replace(/^data-/,""))]=e);break}t=wt(t);var a={path:"".concat(this._path,".").concat(Object(T["l"])(t)),value:e};null===(r=(n=this.hooks).modifySetAttrPayload)||void 0===r||r.call(n,this,t,a),this.enqueueUpdate(a),this.nodeName===z&&(Object(T["l"])(t)===pt?this.enqueueUpdate({path:"".concat(this._path,".","nn"),value:e?ft:this.isAnyEventBinded()?z:Y}):i&&bt(this)&&this.enqueueUpdate({path:"".concat(this._path,".","nn"),value:Y}))}},{key:"removeAttribute",value:function(t){var e,n,r,i,a=this.nodeName===z&&bt(this)&&!this.isAnyEventBinded();if(t===$)this.style.cssText="";else{var o=null===(n=(e=this.hooks).onRemoveAttribute)||void 0===n?void 0:n.call(e,this,t);if(o)return;if(!this.props.hasOwnProperty(t))return;delete this.props[t]}t=wt(t);var s={path:"".concat(this._path,".").concat(Object(T["l"])(t)),value:""};null===(i=(r=this.hooks).modifyRmAttrPayload)||void 0===i||i.call(r,this,t,s),this.enqueueUpdate(s),this.nodeName===z&&(Object(T["l"])(t)===pt?this.enqueueUpdate({path:"".concat(this._path,".","nn"),value:this.isAnyEventBinded()?z:bt(this)?Y:K}):a&&!bt(this)&&this.enqueueUpdate({path:"".concat(this._path,".","nn"),value:K}))}},{key:"getAttribute",value:function(t){var e=t===$?this.style.cssText:this.props[t];return null!==e&&void 0!==e?e:""}},{key:"getElementsByTagName",value:function(t){var e=this;return Xt(this,(function(n){return n.nodeName===t||"*"===t&&e!==n}))}},{key:"getElementsByClassName",value:function(t){return Xt(this,(function(e){var n=e.classList,r=t.trim().split(/\s+/);return r.every((function(t){return n.has(t)}))}))}},{key:"dispatchEvent",value:function(t){var e=t.cancelable,n=this.__handlers[t.type];if(!Object(T["f"])(n))return!1;for(var r=n.length;r--;){var i=n[r],a=void 0;if(i._stop?i._stop=!1:a=i.call(this,t),(!1===a||t._end)&&e&&(t.defaultPrevented=!0),t._end&&t._stop)break}return t._stop?this._stopPropagation(t):t._stop=!0,null!=n}},{key:"addEventListener",value:function(t,e,r){var i=this.nodeName,a=this.hooks.getSpecialNodes();!this.isAnyEventBinded()&&a.indexOf(i)>-1&&this.enqueueUpdate({path:"".concat(this._path,".","nn"),value:i}),Object(d["a"])(Object(v["a"])(n.prototype),"addEventListener",this).call(this,t,e,r)}},{key:"removeEventListener",value:function(t,e){Object(d["a"])(Object(v["a"])(n.prototype),"removeEventListener",this).call(this,t,e);var r=this.nodeName,i=this.hooks.getSpecialNodes();!this.isAnyEventBinded()&&i.indexOf(r)>-1&&this.enqueueUpdate({path:"".concat(this._path,".","nn"),value:bt(this)?"static-".concat(r):"pure-".concat(r)})}}]),n}(kt);te=k([Object(S["d"])(),A(0,Object(S["c"])(N.TaroNodeImpl)),A(1,Object(S["c"])(N.TaroElementFactory)),A(2,Object(S["c"])(N.Hooks)),A(3,Object(S["c"])(N.TaroElementImpl)),C("design:paramtypes",[Function,Function,Function,Function])],te);var ee=Array.isArray,ne="object"==("undefined"===typeof r?"undefined":Object(O["a"])(r))&&r&&r.Object===Object&&r,re="object"==("undefined"===typeof self?"undefined":Object(O["a"])(self))&&self&&self.Object===Object&&self,ie=ne||re||Function("return this")(),ae=ie.Symbol,oe=Object.prototype,se=oe.hasOwnProperty,ue=oe.toString,ce=ae?ae.toStringTag:void 0;function le(t){var e=se.call(t,ce),n=t[ce];try{t[ce]=void 0;var r=!0}catch(t){}var i=ue.call(t);return r&&(e?t[ce]=n:delete t[ce]),i}var he=Object.prototype,pe=he.toString;function fe(t){return pe.call(t)}var de="[object Null]",ve="[object Undefined]",ge=ae?ae.toStringTag:void 0;function ye(t){return null==t?void 0===t?ve:de:ge&&ge in Object(t)?le(t):fe(t)}function me(t){return null!=t&&"object"==Object(O["a"])(t)}var be="[object Symbol]";function _e(t){return"symbol"==Object(O["a"])(t)||me(t)&&ye(t)==be}var we=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,xe=/^\w*$/;function Ee(t,e){if(ee(t))return!1;var n=Object(O["a"])(t);return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!_e(t))||(xe.test(t)||!we.test(t)||null!=e&&t in Object(e))}function Oe(t){var e=Object(O["a"])(t);return null!=t&&("object"==e||"function"==e)}var Se="[object AsyncFunction]",Te="[object Function]",ke="[object GeneratorFunction]",Ae="[object Proxy]";function Ce(t){if(!Oe(t))return!1;var e=ye(t);return e==Te||e==ke||e==Se||e==Ae}var Ne=ie["__core-js_shared__"],Ie=function(){var t=/[^.]+$/.exec(Ne&&Ne.keys&&Ne.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function je(t){return!!Ie&&Ie in t}var Pe=Function.prototype,Re=Pe.toString;function De(t){if(null!=t){try{return Re.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var Me=/[\\^$.*+?()[\]{}|]/g,Le=/^\[object .+?Constructor\]$/,Ve=Function.prototype,Fe=Object.prototype,Be=Ve.toString,Ue=Fe.hasOwnProperty,He=RegExp("^"+Be.call(Ue).replace(Me,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function We(t){if(!Oe(t)||je(t))return!1;var e=Ce(t)?He:Le;return e.test(De(t))}function Ge(t,e){return null==t?void 0:t[e]}function $e(t,e){var n=Ge(t,e);return We(n)?n:void 0}var qe=$e(Object,"create");function ze(){this.__data__=qe?qe(null):{},this.size=0}function Ye(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var Ke="__lodash_hash_undefined__",Je=Object.prototype,Xe=Je.hasOwnProperty;function Qe(t){var e=this.__data__;if(qe){var n=e[t];return n===Ke?void 0:n}return Xe.call(e,t)?e[t]:void 0}var Ze=Object.prototype,tn=Ze.hasOwnProperty;function en(t){var e=this.__data__;return qe?void 0!==e[t]:tn.call(e,t)}var nn="__lodash_hash_undefined__";function rn(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=qe&&void 0===e?nn:e,this}function an(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e-1}function dn(t,e){var n=this.__data__,r=un(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this}function vn(t){var e=-1,n=null==t?0:t.length;this.clear();while(++e0&&void 0!==arguments[0]&&arguments[0],n=arguments.length>1?arguments[1]:void 0;this.pendingUpdate=!0;var r=this.ctx;setTimeout((function(){$n.start(j);var i=Object.create(null),a=new Set(e?["root.cn.[0]","root.cn[0]"]:[]);while(t.updatePayloads.length>0){var o=t.updatePayloads.shift(),s=o.path,u=o.value;s.endsWith("cn")&&a.add(s),i[s]=u}var c=function(t){a.forEach((function(e){t.includes(e)&&t!==e&&delete i[t]}));var e=i[t];Object(T["h"])(e)&&(i[t]=e())};for(var l in i)c(l);if(Object(T["h"])(n))n(i);else{t.pendingUpdate=!1;var h=[],p=new Map,f={};if(!e){for(var d in i){for(var v=d.split("."),g=!1,y=v.length;y>0;y--){var m=v.slice(0,y).join("."),b=Hn(r.__data__||r.data,m);if(b&&b.nn&&b.nn===nt){var _=b.uid,x=r.selectComponent("#".concat(_)),E=v.slice(y).join(".");x&&(g=!0,p.set(x,Object.assign(Object.assign({},p.get(x)||{}),Object(w["a"])({},"i.".concat(E),i[d]))));break}}g||(f[d]=i[d])}p.size>0&&p.forEach((function(t,e){h.push({ctx:e,data:t})}))}var O=h.length;if(O){var S="".concat(t._path,"_update_").concat(qn()),k=t.eventCenter,A=0;k.once(S,(function(){A++,A===O+1&&($n.stop(j),t.pendingFlush||t.flushUpdateCallback(),e&&$n.stop(P))}),k),h.forEach((function(t){t.ctx.setData(t.data,(function(){k.trigger(S)}))})),Object.keys(f).length&&r.setData(f,(function(){k.trigger(S)}))}else r.setData(i,(function(){$n.stop(j),t.pendingFlush||t.flushUpdateCallback(),e&&$n.stop(P)}))}}),0)}},{key:"enqueueUpdateCallback",value:function(t,e){this.updateCallbacks.push((function(){e?t.call(e):t()}))}},{key:"flushUpdateCallback",value:function(){this.pendingFlush=!1;var t=this.updateCallbacks.slice(0);this.updateCallbacks.length=0;for(var e=0;ee;i--){var a=n.charAt(i);if(!er(a)){if(rr(a))return!1;break}}for(var o=t+1;o"===a);if(o)break;i++}var s=i+1;while(s"===u);if(!c)break;s++}Qn(n,e,s);var l=e.slice(i,s);return this.tokens.push({type:t,content:l}),l}},{key:"scanAttrs",value:function(){var t=this.html,e=this.position,n=this.tokens,r=e.index,i=null,a=r,o=[],s=t.length;while(r"===u;if(l){r!==a&&o.push(t.slice(a,r));break}if(sr(r,a,t))r!==a&&o.push(t.slice(a,r)),a=r+1,r++;else{var h="'"===u||'"'===u;h?(i=u,r++):r++}}}Qn(e,t,r);for(var p=o.length,f="attribute",d=0;d1){var m=v+y;n.push({type:f,content:m}),d+=1;continue}var b=o[d+2];if(d+=1,b){var _=v+"="+b;n.push({type:f,content:_}),d+=1;continue}}}if(v.endsWith("=")){var w=o[d+1];if(w&&!w.includes("=")){var x=v+w;n.push({type:f,content:x}),d+=1;continue}var E=v.slice(0,-1);n.push({type:f,content:E})}else n.push({type:f,content:v})}}},{key:"scanSkipTag",value:function(t){var e=this.html,n=this.position,r=t.toLowerCase(),i=e.length;while(n.index]*>((.|\n|\s)+?)<\/style>/g,r=t;return r=r.replace(n,(function(t,n){var r=n.trim();return e.stringToSelector(r),""})),r.trim()}},{key:"stringToSelector",value:function(t){var e=this,n=t.indexOf(gr),r=function(){var r=t.indexOf(yr),i=t.slice(0,n).trim(),a=t.slice(n+1,r);a=a.replace(/:(.*);/g,(function(t,e){var n=e.trim().replace(/ +/g,"+++");return":".concat(n,";")})),a=a.replace(/ /g,""),a=a.replace(/\+\+\+/g," "),/;$/.test(a)||(a+=";"),i.split(",").forEach((function(t){var n=e.parseSelector(t);e.styles.push({content:a,selectorList:n})})),t=t.slice(r+1),n=t.indexOf(gr)};while(n>-1)r()}},{key:"parseSelector",value:function(t){var e=t.trim().replace(/ *([>~+]) */g," $1").replace(/ +/g," ").split(" "),n=e.map((function(t){var e=t.charAt(0),n={isChild:e===_r,isGeneralSibling:e===wr,isAdjacentSibling:e===xr,tag:null,id:null,class:[],attrs:[]};return t=t.replace(/^[>~+]/,""),t=t.replace(/\[(.+?)\]/g,(function(t,e){var r=e.split("="),i=Object(h["a"])(r,2),a=i[0],o=i[1],s=-1===e.indexOf("="),u={all:s,key:a,value:s?null:o};return n.attrs.push(u),""})),t=t.replace(/([.#][A-Za-z0-9-_]+)/g,(function(t,e){return e[0]===br?n.id=e.substr(1):e[0]===mr&&n.class.push(e.substr(1)),""})),""!==t&&(n.tag=t),n}));return n}},{key:"matchStyle",value:function(t,e,n){var r=this,i=Sr(this.styles).reduce((function(i,a,o){var s=a.content,u=a.selectorList,c=n[o],l=u[c],h=u[c+1];((null===h||void 0===h?void 0:h.isGeneralSibling)||(null===h||void 0===h?void 0:h.isAdjacentSibling))&&(l=h,c+=1,n[o]+=1);var p=r.matchCurrent(t,e,l);if(p&&l.isGeneralSibling){var f=Or(e);while(f){if(f.h5tagName&&r.matchCurrent(f.h5tagName,f,u[c-1])){p=!0;break}f=Or(f),p=!1}}if(p&&l.isAdjacentSibling){var d=Or(e);if(d&&d.h5tagName){var v=r.matchCurrent(d.h5tagName,d,u[c-1]);v||(p=!1)}else p=!1}if(p){if(c===u.length-1)return i+s;c0&&(n[o]-=1,r.matchCurrent(t,e,u[n[o]])&&(n[o]+=1));return i}),"");return i}},{key:"matchCurrent",value:function(t,e,n){if(n.tag&&n.tag!==t)return!1;if(n.id&&n.id!==e.id)return!1;if(n.class.length)for(var r=e.className.split(" "),i=0;i=0){var i=e[r].tagName;if(i===t)break;if(n&&n.includes(i))return!0;r--}}return!1}function Ir(t){return Wn.html.renderHTMLTag?t:lr[t]?lr[t]:pr(t)?t:dr(t)?"view":fr(t)?"text":"view"}function jr(t){var e="=",n=t.indexOf(e);if(-1===n)return[t];var r=t.slice(0,n).trim(),i=t.slice(n+e.length).trim();return[r,i]}function Pr(t,e,n,r){return t.filter((function(t){return"comment"!==t.type&&("text"!==t.type||""!==t.content)})).map((function(t){if("text"===t.type){var i=e.createTextNode(t.content);return Object(T["h"])(Wn.html.transformText)?Wn.html.transformText(i,t):(null===r||void 0===r||r.appendChild(i),i)}var a=e.createElement(Ir(t.tagName));a.h5tagName=t.tagName,null===r||void 0===r||r.appendChild(a),Wn.html.renderHTMLTag||(a.className="h5-".concat(t.tagName));for(var o=0;o-1)if(n[c].tagName===u){l=!0;break}while(r0){if(u===n[d].tagName){n.splice(d);var v=d-1;a=n[v].children;break}d-=1}}var g=[],y=void 0;while(r2&&void 0!==arguments[2]&&arguments[2],i=e();for(var a in 1===t.nodeType?n=i.createElement(t.nodeName):3===t.nodeType&&(n=i.createTextNode("")),this){var o=this[a];[J,X].includes(a)&&Object(O["a"])(o)===Q?n[a]=Object.assign({},o):"_value"===a?n[a]=o:a===$&&(n.style._value=Object.assign({},o._value),n.style._usedStyleProp=new Set(Array.from(o._usedStyleProp)))}return r&&(n.childNodes=t.childNodes.map((function(t){return t.cloneNode(!0)}))),n}Wn.html={skipElements:new Set(["style","script"]),voidElements:new Set(["!doctype","area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"]),closingElements:new Set(["html","head","body","p","dt","dd","li","option","thead","th","tbody","tr","td","tfoot","colgroup"]),renderHTMLTag:!1};var Fr=function(){function t(e){Object(x["a"])(this,t),this.getDoc=function(){return e(Ot.Document)()}}return Object(E["a"])(t,[{key:"bind",value:function(t){var e=this.getDoc;Br(t,e),Ur(t,e),t.cloneNode=Vr.bind(t,t,e)}}]),t}();function Br(t,e){Object.defineProperty(t,"innerHTML",{configurable:!0,enumerable:!0,set:function(n){Mr.call(t,t,n,e)},get:function(){return""}})}function Ur(t,e){t.insertAdjacentHTML=function(n,r){Lr.call(t,n,r,e)}}function Hr(){var t=this;return Wn.miniGlobal?new Promise((function(e){var n=Wn.miniGlobal.createSelectorQuery();n.select("#".concat(t.uid)).boundingClientRect((function(t){e(t)})).exec()})):Promise.resolve(null)}function Wr(t){if("template"===t.nodeName){var e=t._getElement(Ot.Element)(U);return e.childNodes=t.childNodes,t.childNodes=[e],e.parentNode=t,e.childNodes.forEach((function(t){t.parentNode=e})),e}}Fr=k([Object(S["d"])(),A(0,Object(S["c"])(N.TaroElementFactory)),C("design:paramtypes",[Function])],Fr);var Gr=function(){function t(){Object(x["a"])(this,t)}return Object(E["a"])(t,[{key:"bind",value:function(t){t.getBoundingClientRect=Object(l["a"])(c.a.mark((function e(){var n,r,i,a=arguments;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(n=a.length,r=new Array(n),i=0;i2?n-2:0),i=2;i0){var e=this.pages.pop();this.elements.push(e())}var n=null;return a&&(n={ref:i}),Ki.createElement(t,n,li?Ki.createElement("div",null,this.elements.slice()):this.elements.slice())}}]),r}(Ki.Component);li||(o=Yi.render(Ki.createElement(s),vi.getElementById("app")));var u=Object.create({render:function(t){o.forceUpdate(t)},mount:function(t,e,n){var r=Xi(Ki,e)(t);o.mount(r,e,n)},unmount:function(t,e){o.unmount(t,e)}},{config:{writable:!0,enumerable:!0,configurable:!0,value:r},onLaunch:{enumerable:!0,writable:!0,value:function(t){var e=this;Ti.router=Object.assign({params:null===t||void 0===t?void 0:t.query},t),li&&(o=Yi.render(Ki.createElement(s),vi.getElementById("app")));var n=i.current;if(null===n||void 0===n?void 0:n.taroGlobalData){var r=n.taroGlobalData,a=Object.keys(r),u=Object.getOwnPropertyDescriptors(r);a.forEach((function(t){Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return r[t]},set:function(e){r[t]=e}})})),Object.defineProperties(this,u)}this.$app=n,null!=n&&Object(T["h"])(n.onLaunch)&&n.onLaunch(t)}},onShow:{enumerable:!0,writable:!0,value:function(t){var e=i.current;Ti.router=Object.assign({params:null===t||void 0===t?void 0:t.query},t),null!=e&&Object(T["h"])(e.componentDidShow)&&e.componentDidShow(t),c("onShow")}},onHide:{enumerable:!0,writable:!0,value:function(t){var e=i.current;null!=e&&Object(T["h"])(e.componentDidHide)&&e.componentDidHide(t),c("onHide")}},onPageNotFound:{enumerable:!0,writable:!0,value:function(t){var e=i.current;null!=e&&Object(T["h"])(e.onPageNotFound)&&e.onPageNotFound(t)}}});function c(t){var e=Di(I);if(e){var n=i.current,r=qi.getLifecycle(e,t);Array.isArray(r)&&r.forEach((function(t){return t.apply(n)}))}}return Ti.app=u,Ti.app}var ea,na=vt();function ra(t,e){var n=function(e){Object(b["a"])(r,e);var n=Object(_["a"])(r);function r(){var e;return Object(x["a"])(this,r),e=n.apply(this,arguments),e.root=t.createRef(),e.ctx=e.props.getCtx(),e}return Object(E["a"])(r,[{key:"componentDidMount",value:function(){this.ctx.component=this;var t=this.root.current;t.ctx=this.ctx,t.performUpdate(!0)}},{key:"render",value:function(){return t.createElement("root",{ref:this.root},this.props.renderComponent(this.ctx))}}]),r}(t.Component),r=function(e){Object(b["a"])(i,e);var r=Object(_["a"])(i);function i(){var t;return Object(x["a"])(this,i),t=r.apply(this,arguments),t.state={components:[]},t}return Object(E["a"])(i,[{key:"componentDidMount",value:function(){Ti.app=this}},{key:"mount",value:function(e,r,i){var a=zi(t,e),o=function(t){return t&&Ri(t,r)},s=a?{ref:o}:{forwardedRef:o,reactReduxForwardedRef:o},u={compId:r,element:t.createElement(n,{key:r,getCtx:i,renderComponent:function(n){return t.createElement(e,Object.assign(Object.assign({},(n.data||(n.data={})).props),s))}})};this.setState({components:[].concat(Object(f["a"])(this.state.components),[u])})}},{key:"unmount",value:function(t){var e=this.state.components,n=e.findIndex((function(e){return e.compId===t})),r=[].concat(Object(f["a"])(e.slice(0,n)),Object(f["a"])(e.slice(n+1)));this.setState({components:r})}},{key:"render",value:function(){var t=this.state.components;return t.map((function(t){var e=t.element;return e}))}}]),i}(t.Component);Qi();var i=vi.getElementById("app");e.render(t.createElement(r,{}),i)}function ia(t,e,n,r){Ki=e,Yi=n,Qi();var i={properties:{props:{type:null,value:null,observer:function(t,e){e&&this.component.forceUpdate()}}},created:function(){Ti.app||ra(Ki,Yi)},attached:function(){var e=this;a(),this.compId=na(),this.config=r,Ti.app.mount(t,this.compId,(function(){return e}))},ready:function(){Li(this.compId,"onReady")},detached:function(){Ti.app.unmount(this.compId)},pageLifetimes:{show:function(){Li(this.compId,"onShow")},hide:function(){Li(this.compId,"onHide")}},methods:{eh:ci}};function a(){var t=getCurrentPages(),e=t[t.length-1];if(Ti.page!==e){Ti.page=e;var n=e.route||e.__route__,r={params:e.options||{},path:Mi(n),onReady:"",onHide:"",onShow:""};Ti.router=r,e.options||Object.defineProperty(e,"options",{enumerable:!0,configurable:!0,get:function(){return this._optionsValue},set:function(t){r.params=t,this._optionsValue=t}})}}return i}function aa(t,e){return function(n){var r=t.extend({props:{tid:String},mixins:[n,{created:function(){Ri(this,e)}}]}),i={render:function(t){return t(li?"div":"root",{attrs:{id:e,class:li?"taro_page":""}},[t(r,{props:{tid:e}})])}};return i}}function oa(){var t=ai.get(N.Hooks),e=function(t,e){var n=t.props;if(!n.hasOwnProperty(e)||Object(T["g"])(n[e]))return t.setAttribute(e,!1),!0},n=function(t,e){return t.$options[e]};t.onRemoveAttribute=e,t.getLifecycle=n}function sa(t,e,n){ea=e,Object(T["d"])(!!ea,"\u6784\u5efa Vue \u9879\u76ee\u8bf7\u628a process.env.FRAMEWORK \u8bbe\u7f6e\u4e3a 'vue'"),oa(),ea.config.getTagNamespace=T["k"];var r,i=[],a=[],o=new ea({render:function(e){while(a.length>0){var n=a.pop();i.push(n(e))}return e(t,{ref:"app"},i.slice())},methods:{mount:function(t,e,n){a.push((function(n){return n(t,{key:e})})),this.updateSync(n)},updateSync:function(t){this._update(this._render(),!1),this.$children.forEach((function(t){return t._update(t._render(),!1)})),t()},unmount:function(t,e){for(var n=0;n0&&void 0!==arguments[0]&&arguments[0];return t?Ti.router:Ki.useMemo((function(){return Ti.router}),[])},ka=function(){};function Aa(t){return null==t?"":"/"===t.charAt(0)?t.slice(1):t}var Ca=function(t,e){var n,r,i,a=Ti.router,o=function(){setTimeout((function(){e?t.call(e):t()}),1)};if(null!==a){var s=null,u=Fi(Aa(a.path),a.params);s=vi.getElementById(u),(null===s||void 0===s?void 0:s.pendingUpdate)?li?null!==(i=null===(r=null===(n=s.firstChild)||void 0===n?void 0:n["componentOnReady"])||void 0===r?void 0:r.call(n).then((function(){o()})))&&void 0!==i||o():s.enqueueUpdateCallback(t,e):o()}else o()}}.call(this,n(39),n(31),n(17)["document"],n(17)["window"],n(17)["requestAnimationFrame"],n(17)["cancelAnimationFrame"])},function(t,e,n){"use strict";function r(t,e){return r=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},r(t,e)}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,r.nameRegexp);!Number.parseInt&&t.parseInt&&(Number.parseInt=t.parseInt),!Number.parseFloat&&t.parseFloat&&(Number.parseFloat=t.parseFloat);const s={attributeNamePrefix:"@_",attrNodeName:!1,textNodeName:"#text",ignoreAttributes:!0,ignoreNameSpace:!1,allowBooleanAttributes:!1,parseNodeValue:!0,parseAttributeValue:!1,arrayMode:!1,trimValues:!0,cdataTagName:!1,cdataPositionChar:"\\c",numParseOptions:{hex:!0,leadingZeros:!0},tagValueProcessor:function(t,e){return t},attrValueProcessor:function(t,e){return t},stopNodes:[],alwaysCreateTextNode:!1};e.defaultOptions=s;const u=["attributeNamePrefix","attrNodeName","textNodeName","ignoreAttributes","ignoreNameSpace","allowBooleanAttributes","parseNodeValue","parseAttributeValue","arrayMode","trimValues","cdataTagName","cdataPositionChar","tagValueProcessor","attrValueProcessor","parseTrueNumberOnly","numParseOptions","stopNodes","alwaysCreateTextNode"];function c(t,e,n){return e&&(n.trimValues&&(e=e.trim()),e=n.tagValueProcessor(e,t),e=h(e,n.parseNodeValue,n.numParseOptions)),e}function l(t,e){if(e.ignoreNameSpace){const e=t.split(":"),n="/"===t.charAt(0)?"/":"";if("xmlns"===e[0])return"";2===e.length&&(t=n+e[1])}return t}function h(t,e,n){if(e&&"string"===typeof t){const e=t.trim();return"true"===e||"false"!==e&&o(t,n)}return r.isExist(t)?t:""}e.props=u;const p=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])(.*?)\\3)?","g");function f(t,e){if(!e.ignoreAttributes&&"string"===typeof t){t=t.replace(/\r?\n/g," ");const n=r.getAllMatches(t,p),i=n.length,a={};for(let t=0;t",n,"Closing Tag is not closed.");let a=t.substring(n+2,i).trim();if(e.ignoreNameSpace){const t=a.indexOf(":");-1!==t&&(a=a.substr(t+1))}o&&(o.val?o.val=r.getValue(o.val)+""+c(a,l,e):o.val=c(a,l,e)),e.stopNodes.length&&e.stopNodes.includes(o.tagname)&&(o.child=[],void 0==o.attrsMap&&(o.attrsMap={}),o.val=t.substr(o.startIndex+1,n-o.startIndex-1)),o=o.parent,l="",n=i}else if("?"===t[n+1])n=g(t,"?>",n,"Pi Tag is not closed.");else if("!--"===t.substr(n+1,3))n=g(t,"--\x3e",n,"Comment is not closed.");else if("!D"===t.substr(n+1,2)){const e=g(t,">",n,"DOCTYPE is not closed."),r=t.substring(n,e);n=r.indexOf("[")>=0?t.indexOf("]>",n)+1:e}else if("!["===t.substr(n+1,2)){const i=g(t,"]]>",n,"CDATA is not closed.")-2,s=t.substring(n+9,i);if(l&&(o.val=r.getValue(o.val)+""+c(o.tagname,l,e),l=""),e.cdataTagName){const t=new a(e.cdataTagName,o,s);o.addChild(t),o.val=r.getValue(o.val)+e.cdataPositionChar,s&&(t.val=s)}else o.val=(o.val||"")+(s||"");n=i+2}else{const i=v(t,n+1);let s=i.data;const u=i.index,h=s.indexOf(" ");let p=s,d=!0;if(-1!==h&&(p=s.substr(0,h).replace(/\s\s*$/,""),s=s.substr(h+1)),e.ignoreNameSpace){const t=p.indexOf(":");-1!==t&&(p=p.substr(t+1),d=p!==i.data.substr(t+1))}if(o&&l&&"!xml"!==o.tagname&&(o.val=r.getValue(o.val)+""+c(o.tagname,l,e)),s.length>0&&s.lastIndexOf("/")===s.length-1){"/"===p[p.length-1]?(p=p.substr(0,p.length-1),s=p):s=s.substr(0,s.length-1);const t=new a(p,o,"");p!==s&&(t.attrsMap=f(s,e)),o.addChild(t)}else{const t=new a(p,o);e.stopNodes.length&&e.stopNodes.includes(t.tagname)&&(t.startIndex=u),p!==s&&d&&(t.attrsMap=f(s,e)),o.addChild(t),o=t}l="",n=u}else l+=t[n]}return n};function v(t,e){let n,r="";for(let i=e;i"===e)return{data:r,index:i};"\t"===e&&(e=" ")}r+=e}}function g(t,e,n,r){const i=t.indexOf(e,n);if(-1===i)throw new Error(r);return i+e.length-1}e.getTraversalObj=d}).call(this,n(17)["window"])},function(t,e,n){"use strict";function r(t){if(Array.isArray(t))return t}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";function r(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var r=n(8);function i(t,e){while(!Object.prototype.hasOwnProperty.call(t,e))if(t=Object(r["a"])(t),null===t)break;return t}},function(t,e,n){"use strict";function r(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";function r(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));var r=n(21),i=n(24),a=n(16),o=n(22);function s(t){return Object(r["a"])(t)||Object(i["a"])(t)||Object(a["a"])(t)||Object(o["a"])()}},function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var r=n(8),i=n(18);function a(t){return-1!==Function.toString.call(t).indexOf("[native code]")}var o=n(25);function s(t,e,n){return s=Object(o["a"])()?Reflect.construct:function(t,e,n){var r=[null];r.push.apply(r,e);var a=Function.bind.apply(t,r),o=new a;return n&&Object(i["a"])(o,n.prototype),o},s.apply(null,arguments)}function u(t){var e="function"===typeof Map?new Map:void 0;return u=function(t){if(null===t||!a(t))return t;if("function"!==typeof t)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof e){if(e.has(t))return e.get(t);e.set(t,n)}function n(){return s(t,arguments,Object(r["a"])(this).constructor)}return n.prototype=Object.create(t.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),Object(i["a"])(n,t)},u(t)}},function(t,e,n){var r;(function(i,a){var o=a(i);r=function(){return o}.call(e,n,e,t),void 0===r||(t.exports=r)})(this,(function(t){var e=["N","E","A","D"];function n(t,e){t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}function r(t,e){Object.defineProperty(this,"kind",{value:t,enumerable:!0}),e&&e.length&&Object.defineProperty(this,"path",{value:e,enumerable:!0})}function i(t,e,n){i.super_.call(this,"E",t),Object.defineProperty(this,"lhs",{value:e,enumerable:!0}),Object.defineProperty(this,"rhs",{value:n,enumerable:!0})}function a(t,e){a.super_.call(this,"N",t),Object.defineProperty(this,"rhs",{value:e,enumerable:!0})}function o(t,e){o.super_.call(this,"D",t),Object.defineProperty(this,"lhs",{value:e,enumerable:!0})}function s(t,e,n){s.super_.call(this,"A",t),Object.defineProperty(this,"index",{value:e,enumerable:!0}),Object.defineProperty(this,"item",{value:n,enumerable:!0})}function u(t,e,n){var r=t.slice((n||e)+1||t.length);return t.length=e<0?t.length+e:e,t.push.apply(t,r),t}function c(t){var e=typeof t;return"object"!==e?e:t===Math?"math":null===t?"null":Array.isArray(t)?"array":"[object Date]"===Object.prototype.toString.call(t)?"date":"function"===typeof t.toString&&/^\/.*\//.test(t.toString())?"regexp":"object"}function l(t){var e=0;if(0===t.length)return e;for(var n=0;n0&&f[f.length-1].lhs&&Object.getOwnPropertyDescriptor(f[f.length-1].lhs,l),O="undefined"!==x||f&&f.length>0&&f[f.length-1].rhs&&Object.getOwnPropertyDescriptor(f[f.length-1].rhs,l);if(!E&&O)n.push(new a(v,e));else if(!O&&E)n.push(new o(v,t));else if(c(t)!==c(e))n.push(new i(v,t,e));else if("date"===c(t)&&t-e!==0)n.push(new i(v,t,e));else if("object"===w&&null!==t&&null!==e){for(y=f.length-1;y>-1;--y)if(f[y].lhs===t){_=!0;break}if(_)t!==e&&n.push(new i(v,t,e));else{if(f.push({lhs:t,rhs:e}),Array.isArray(t)){d&&(t.sort((function(t,e){return h(t)-h(e)})),e.sort((function(t,e){return h(t)-h(e)}))),y=e.length-1,m=t.length-1;while(y>m)n.push(new s(v,y,new a(void 0,e[y--])));while(m>y)n.push(new s(v,m,new o(void 0,t[m--])));for(;y>=0;--y)p(t[y],e[y],n,r,v,y,f,d)}else{var S=Object.keys(t),T=Object.keys(e);for(y=0;y=0?(p(t[b],e[b],n,r,v,b,f,d),T[_]=null):p(t[b],void 0,n,r,v,b,f,d);for(y=0;y1)for(var n=1;n=0,a=i&&r.regeneratorRuntime;if(r.regeneratorRuntime=void 0,t.exports=n(41),i)r.regeneratorRuntime=a;else try{delete r.regeneratorRuntime}catch(t){r.regeneratorRuntime=void 0}},function(t,e,n){(function(t){var e=n(29);!function(n){"use strict";var r,i=Object.prototype,a=i.hasOwnProperty,o="function"===typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",u=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag",l="object"===e(t),h=n.regeneratorRuntime;if(h)l&&(t.exports=h);else{h=n.regeneratorRuntime=l?t.exports:{},h.wrap=w;var p="suspendedStart",f="suspendedYield",d="executing",v="completed",g={},y={};y[s]=function(){return this};var m=Object.getPrototypeOf,b=m&&m(m(P([])));b&&b!==i&&a.call(b,s)&&(y=b);var _=S.prototype=E.prototype=Object.create(y);O.prototype=_.constructor=S,S.constructor=O,S[c]=O.displayName="GeneratorFunction",h.isGeneratorFunction=function(t){var e="function"===typeof t&&t.constructor;return!!e&&(e===O||"GeneratorFunction"===(e.displayName||e.name))},h.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,S):(t.__proto__=S,c in t||(t[c]="GeneratorFunction")),t.prototype=Object.create(_),t},h.awrap=function(t){return{__await:t}},T(k.prototype),k.prototype[u]=function(){return this},h.AsyncIterator=k,h.async=function(t,e,n,r){var i=new k(w(t,e,n,r));return h.isGeneratorFunction(e)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},T(_),_[c]="Generator",_[s]=function(){return this},_.toString=function(){return"[object Generator]"},h.keys=function(t){var e=[];for(var n in t)e.push(n);return e.reverse(),function n(){while(e.length){var r=e.pop();if(r in t)return n.value=r,n.done=!1,n}return n.done=!0,n}},h.values=P,j.prototype={constructor:j,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(I),!t)for(var e in this)"t"===e.charAt(0)&&a.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0],e=t.completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(n,i){return s.type="throw",s.arg=t,e.next=n,i&&(e.method="next",e.arg=r),!!i}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],s=o.completion;if("root"===o.tryLoc)return n("end");if(o.tryLoc<=this.prev){var u=a.call(o,"catchLoc"),c=a.call(o,"finallyLoc");if(u&&c){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&a.call(r,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),I(n),g}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;I(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:P(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=r),g}}}function w(t,e,n,r){var i=e&&e.prototype instanceof E?e:E,a=Object.create(i.prototype),o=new j(r||[]);return a._invoke=A(t,n,o),a}function x(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}function E(){}function O(){}function S(){}function T(t){["next","throw","return"].forEach((function(e){t[e]=function(t){return this._invoke(e,t)}}))}function k(t){function n(r,i,o,s){var u=x(t[r],t,i);if("throw"!==u.type){var c=u.arg,l=c.value;return l&&"object"===e(l)&&a.call(l,"__await")?Promise.resolve(l.__await).then((function(t){n("next",t,o,s)}),(function(t){n("throw",t,o,s)})):Promise.resolve(l).then((function(t){c.value=t,o(c)}),s)}s(u.arg)}var r;function i(t,e){function i(){return new Promise((function(r,i){n(t,e,r,i)}))}return r=r?r.then(i,i):i()}this._invoke=i}function A(t,e,n){var r=p;return function(i,a){if(r===d)throw new Error("Generator is already running");if(r===v){if("throw"===i)throw a;return R()}n.method=i,n.arg=a;while(1){var o=n.delegate;if(o){var s=C(o,n);if(s){if(s===g)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===p)throw r=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=d;var u=x(t,e,n);if("normal"===u.type){if(r=n.done?v:f,u.arg===g)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r=v,n.method="throw",n.arg=u.arg)}}}function C(t,e){var n=t.iterator[e.method];if(n===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=r,C(t,e),"throw"===e.method))return g;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}var i=x(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,g;var a=i.arg;return a?a.done?(e[t.resultName]=a.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=r),e.delegate=null,g):a:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,g)}function N(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function I(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function j(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(N,this),this.reset(!0)}function P(t){if(t){var e=t[s];if(e)return e.call(t);if("function"===typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){while(++n1){a[u]=[];for(let n in t.child[u])t.child[u].hasOwnProperty(n)&&a[u].push(i(t.child[u][n],e,u))}else{const o=i(t.child[u][0],e,u),s=!0===e.arrayMode&&"object"===typeof o||r.isTagNameInArrayMode(u,e.arrayMode,n);a[u]=s?[o]:o}}return a};e.convertToJson=i},function(t,e,n){"use strict";t.exports=function(t,e,n){this.tagname=t,this.parent=e,this.child={},this.attrsMap={},this.val=n,this.addChild=function(t){Array.isArray(this.child[t.tagname])?this.child[t.tagname].push(t):this.child[t.tagname]=[t]}}},function(t,e){const n=/^[-+]?0x[a-fA-F0-9]+$/,r=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/,i={hex:!0,leadingZeros:!0,decimalPoint:"."};function a(t,e={}){if(e=Object.assign({},i,e),!t||"string"!==typeof t)return t;let a=t.trim();if(void 0!==e.skipLike&&e.skipLike.test(a))return t;if(e.hex&&n.test(a))return Number.parseInt(a,16);{const n=r.exec(a);if(n){n[1];const r=n[2],i=n[3];n[4]||n[6];return 1===r.length&&"."===i[0]?Number(t):!e.leadingZeros&&r.length>0?t:Number(a)}return t}}t.exports=a},function(t,e,n){"use strict";const r=n(14),i={allowBooleanAttributes:!1},a=["allowBooleanAttributes"];function o(t,e){const n=e;for(;e5&&"xml"===r)return v("InvalidXml","XML declaration allowed only at the start of the document.",m(t,e));if("?"==t[e]&&">"==t[e+1]){e++;break}}return e}function s(t,e){if(t.length>e+5&&"-"===t[e+1]&&"-"===t[e+2]){for(e+=3;e"===t[e+2]){e+=2;break}}else if(t.length>e+8&&"D"===t[e+1]&&"O"===t[e+2]&&"C"===t[e+3]&&"T"===t[e+4]&&"Y"===t[e+5]&&"P"===t[e+6]&&"E"===t[e+7]){let n=1;for(e+=8;e"===t[e]&&(n--,0===n))break}else if(t.length>e+9&&"["===t[e+1]&&"C"===t[e+2]&&"D"===t[e+3]&&"A"===t[e+4]&&"T"===t[e+5]&&"A"===t[e+6]&&"["===t[e+7])for(e+=8;e"===t[e+2]){e+=2;break}return e}e.validate=function(t,e){e=r.buildOptions(e,i,a);const n=[];let u=!1,c=!1;"\ufeff"===t[0]&&(t=t.substr(1));for(let r=0;r"!==t[r]&&" "!==t[r]&&"\t"!==t[r]&&"\n"!==t[r]&&"\r"!==t[r];r++)h+=t[r];if(h=h.trim(),"/"===h[h.length-1]&&(h=h.substring(0,h.length-1),r--),!y(h)){let e;return e=0===h.trim().length?"Invalid space after '<'.":"Tag '"+h+"' is an invalid name.",v("InvalidTag",e,m(t,r))}const f=l(t,r);if(!1===f)return v("InvalidAttr","Attributes for '"+h+"' have open quote.",m(t,r));let g=f.value;if(r=f.index,"/"===g[g.length-1]){const n=r-g.length;g=g.substring(0,g.length-1);const i=p(g,e);if(!0!==i)return v(i.err.code,i.err.msg,m(t,n+i.err.line));u=!0}else if(a){if(!f.tagClosed)return v("InvalidTag","Closing tag '"+h+"' doesn't have proper closing.",m(t,r));if(g.trim().length>0)return v("InvalidTag","Closing tag '"+h+"' can't have attributes or invalid starting.",m(t,i));{const e=n.pop();if(h!==e.tagName){let n=m(t,e.tagStartPos);return v("InvalidTag","Expected closing tag '"+e.tagName+"' (opened in line "+n.line+", col "+n.col+") instead of closing tag '"+h+"'.",m(t,i))}0==n.length&&(c=!0)}}else{const a=p(g,e);if(!0!==a)return v(a.err.code,a.err.msg,m(t,r-g.length+a.err.line));if(!0===c)return v("InvalidXml","Multiple possible root nodes found.",m(t,r));n.push({tagName:h,tagStartPos:i}),u=!0}for(r++;r0)||v("InvalidXml","Invalid '"+JSON.stringify(n.map(t=>t.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):v("InvalidXml","Start tag expected.",1)};const u='"',c="'";function l(t,e){let n="",r="",i=!1;for(;e"===t[e]&&""===r){i=!0;break}n+=t[e]}return""===r&&{value:n,index:e,tagClosed:i}}const h=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");function p(t,e){const n=r.getAllMatches(t,h),i={};for(let t=0;t1){i+='"'+r+'" : [ ';for(let n in t.child[r])i+=s(t.child[r][n],e)+" , ";i=i.substr(0,i.length-1)+" ] "}else i+='"'+r+'" : '+s(t.child[r][0],e)+" ,"}return r.merge(i,t.attrsMap),r.isEmptyObject(i)?r.isExist(t.val)?t.val:"":(r.isExist(t.val)&&("string"!==typeof t.val||""!==t.val&&t.val!==e.cdataPositionChar)&&(i+='"'+e.textNodeName+'" : '+u(t.val)),","===i[i.length-1]&&(i=i.substr(0,i.length-2)),i+"}")};function u(t){return!0!==t&&!1!==t&&isNaN(t)?'"'+t+'"':t}e.convertToJsonString=o},function(t,e,n){"use strict";const r=n(14).buildOptions,i={attributeNamePrefix:"@_",attrNodeName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataTagName:!1,cdataPositionChar:"\\c",format:!1,indentBy:" ",supressEmptyNode:!1,tagValueProcessor:function(t){return t},attrValueProcessor:function(t){return t}},a=["attributeNamePrefix","attrNodeName","textNodeName","ignoreAttributes","cdataTagName","cdataPositionChar","format","indentBy","supressEmptyNode","tagValueProcessor","attrValueProcessor","rootNodeName"];function o(t){this.options=r(t,i,a),this.options.ignoreAttributes||this.options.attrNodeName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=v),this.options.cdataTagName?this.isCDATA=g:this.isCDATA=function(){return!1},this.replaceCDATAstr=u,this.replaceCDATAarr=c,this.processTextOrObjNode=s,this.options.format?(this.indentate=d,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine=""),this.options.supressEmptyNode?(this.buildTextNode=f,this.buildObjNode=h):(this.buildTextNode=p,this.buildObjNode=l),this.buildTextValNode=p,this.buildObjectNode=l}function s(t,e,n){const r=this.j2x(t,n+1);return void 0!==t[this.options.textNodeName]&&1===Object.keys(t).length?this.buildTextNode(r.val,e,r.attrStr,n):this.buildObjNode(r.val,e,r.attrStr,n)}function u(t,e){return t=this.options.tagValueProcessor(""+t),""===this.options.cdataPositionChar||""===t?t+"");return t+this.newLine}function l(t,e,n,r){return n&&-1===t.indexOf("<")?this.indentate(r)+"<"+e+n+">"+t+""+this.options.tagValueProcessor(t)+"1&&(t={[this.options.rootNodeName]:t}),this.j2x(t,0).val},o.prototype.j2x=function(t,e){let n="",r="";for(let i in t)if("undefined"===typeof t[i]);else if(null===t[i])r+=this.indentate(e)+"<"+i+"/"+this.tagEndChar;else if(t[i]instanceof Date)r+=this.buildTextNode(t[i],i,"",e);else if("object"!==typeof t[i]){const a=this.isAttribute(i);a?n+=" "+a+'="'+this.options.attrValueProcessor(""+t[i])+'"':this.isCDATA(i)?t[this.options.textNodeName]?r+=this.replaceCDATAstr(t[this.options.textNodeName],t[i]):r+=this.replaceCDATAstr("",t[i]):i===this.options.textNodeName?t[this.options.cdataTagName]||(r+=this.options.tagValueProcessor(""+t[i])):r+=this.buildTextNode(t[i],i,"",e)}else if(Array.isArray(t[i]))if(this.isCDATA(i))r+=this.indentate(e),t[this.options.textNodeName]?r+=this.replaceCDATAarr(t[this.options.textNodeName],t[i]):r+=this.replaceCDATAarr("",t[i]);else{const n=t[i].length;for(let a=0;a1114111||n(l)!=l)throw RangeError("Invalid code point: "+l);l<=65535?o.push(l):(l-=65536,r=55296+(l>>10),i=l%1024+56320,o.push(r,i)),(s+1==u||o.length>a)&&(c+=e.apply(null,o),o.length=0)}return c};t?t(String,"fromCodePoint",{value:r,configurable:!0,writable:!0}):String.fromCodePoint=r}()},function(t,e,n){"use strict";n.r(e);var r=n(2);function i(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function a(t){for(var e=1;e()=>{let n="",r=e;while(r--)n+=t[Math.random()*t.length|0];return n};var p,f,d="1234567890abcdefghijklmnopqrstuvwxyz",v=h(d,10),g=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.prefix,n=void 0===e?"":e;return n+v()};(function(t){t["API"]="API",t["DB"]="DB",t["SAAS"]="SAAS"})(p||(p={})),function(t){t["NONE"]="NONE",t["PAGE_NO"]="PAGE_NO",t["URL"]="URL"}(f||(f={}));var y,m,b,_,w=[{sectionName:"",id:1,children:[{label:"Run query on page load",configProperty:"executeOnLoad",controlType:"SWITCH",info:"Will refresh data each time the page is loaded"},{label:"Request confirmation before running query",configProperty:"confirmBeforeExecute",controlType:"SWITCH",info:"Ask confirmation from the user each time before refreshing data"},{label:"Query timeout (in milliseconds)",info:"Maximum time after which the query will return",configProperty:"actionConfiguration.timeoutInMillisecond",controlType:"INPUT_TEXT",dataType:"NUMBER"}]}],x=[{sectionName:"",id:1,children:[{label:"Run API on Page load",configProperty:"executeOnLoad",controlType:"CHECKBOX",info:"Will refresh data each time the page is loaded"},{label:"Request confirmation before running API",configProperty:"confirmBeforeExecute",controlType:"CHECKBOX",info:"Ask confirmation from the user each time before refreshing data"},{label:"Encode query params",configProperty:"actionConfiguration.encodeParamsToggle",controlType:"CHECKBOX",info:"Encode query params for all APIs. Also encode form body when Content-Type header is set to x-www-form-encoded"},{label:"Smart JSON Substitution",configProperty:"actionConfiguration.pluginSpecifiedTemplates[0].value",controlType:"CHECKBOX",info:"Turning on this property fixes the JSON substitution of bindings in API body by adding/removing quotes intelligently and reduces developer errors",initialValue:!0},{label:"API timeout (in milliseconds)",info:"Maximum time after which the API will return",configProperty:"actionConfiguration.timeoutInMillisecond",controlType:"NUMBER_INPUT",dataType:"number"}]}],E=[{sectionName:"",id:1,children:[{label:"Path",configProperty:"actionConfiguration.path",controlType:"QUERY_DYNAMIC_INPUT_TEXT"},{label:"Body",configProperty:"actionConfiguration.body",controlType:"QUERY_DYNAMIC_INPUT_TEXT",evaluationSubstitutionType:"SMART_SUBSTITUTE",hidden:{path:"actionConfiguration.pluginSpecifiedTemplates[0].value",comparison:"EQUALS",value:!1}},{label:"Body",configProperty:"actionConfiguration.body",controlType:"QUERY_DYNAMIC_INPUT_TEXT",evaluationSubstitutionType:"TEMPLATE",hidden:{path:"actionConfiguration.pluginSpecifiedTemplates[0].value",comparison:"EQUALS",value:!0}},{label:"Query Parameters",configProperty:"actionConfiguration.queryParameters",controlType:"ARRAY_FIELD",schema:[{label:"Key",key:"key",controlType:"QUERY_DYNAMIC_INPUT_TEXT",placeholderText:"Key"},{label:"Value",key:"value",controlType:"QUERY_DYNAMIC_INPUT_TEXT",placeholderText:"Value"}]},{label:"Headers",configProperty:"actionConfiguration.headers",controlType:"ARRAY_FIELD",schema:[{label:"Key",key:"key",controlType:"QUERY_DYNAMIC_INPUT_TEXT",placeholderText:"Key"},{label:"Value",key:"value",controlType:"QUERY_DYNAMIC_INPUT_TEXT",placeholderText:"Value"}]},{label:"Form data",configProperty:"actionConfiguration.bodyFormData",controlType:"ARRAY_FIELD",schema:[{label:"Key",key:"key",controlType:"QUERY_DYNAMIC_INPUT_TEXT",placeholderText:"Key"},{label:"Value",key:"value",controlType:"QUERY_DYNAMIC_INPUT_TEXT",placeholderText:"Value"}]}]}],O=[{sectionName:"",id:1,children:[{label:"Run API on Page load",configProperty:"executeOnLoad",controlType:"SWITCH",info:"Will refresh data each time the page is loaded"},{label:"Request confirmation before running API",configProperty:"confirmBeforeExecute",controlType:"SWITCH",info:"Ask confirmation from the user each time before refreshing data"},{label:"API timeout (in milliseconds)",info:"Maximum time after which the API will return",configProperty:"actionConfiguration.timeoutInMillisecond",controlType:"INPUT_TEXT",dataType:"NUMBER"}]}],S={"actionConfiguration.body":["actionConfiguration.pluginSpecifiedTemplates[0].value"]};(function(t){t["ON_RESET"]="ON_RESET",t["ON_PAGE_LOAD"]="ON_PAGE_LOAD",t["ON_PREV_PAGE"]="ON_PREV_PAGE",t["ON_NEXT_PAGE"]="ON_NEXT_PAGE",t["ON_PAGE_SIZE_CHANGE"]="ON_PAGE_SIZE_CHANGE",t["ON_ERROR"]="ON_ERROR",t["ON_SUCCESS"]="ON_SUCCESS",t["ON_ROW_SELECTED"]="ON_ROW_SELECTED",t["ON_SEARCH"]="ON_SEARCH",t["ON_CLICK"]="ON_CLICK",t["ON_DATA_POINT_CLICK"]="ON_DATA_POINT_CLICK",t["ON_FILES_SELECTED"]="ON_FILES_SELECTED",t["ON_HOVER"]="ON_HOVER",t["ON_TOGGLE"]="ON_TOGGLE",t["ON_LOAD"]="ON_LOAD",t["ON_MODAL_CLOSE"]="ON_MODAL_CLOSE",t["ON_TEXT_CHANGE"]="ON_TEXT_CHANGE",t["ON_SUBMIT"]="ON_SUBMIT",t["ON_CHECK_CHANGE"]="ON_CHECK_CHANGE",t["ON_SWITCH_CHANGE"]="ON_SWITCH_CHANGE",t["ON_SELECT"]="ON_SELECT",t["ON_DATE_SELECTED"]="ON_DATE_SELECTED",t["ON_DATE_RANGE_SELECTED"]="ON_DATE_RANGE_SELECTED",t["ON_OPTION_CHANGE"]="ON_OPTION_CHANGE",t["ON_MARKER_CLICK"]="ON_MARKER_CLICK",t["ON_CREATE_MARKER"]="ON_CREATE_MARKER",t["ON_TAB_CHANGE"]="ON_TAB_CHANGE",t["ON_VIDEO_START"]="ON_VIDEO_START",t["ON_VIDEO_END"]="ON_VIDEO_END",t["ON_VIDEO_PLAY"]="ON_VIDEO_PLAY",t["ON_VIDEO_PAUSE"]="ON_VIDEO_PAUSE",t["ON_RATE_CHANGED"]="ON_RATE_CHANGED",t["ON_IFRAME_URL_CHANGED"]="ON_IFRAME_URL_CHANGED",t["ON_IFRAME_MESSAGE_RECEIVED"]="ON_IFRAME_MESSAGE_RECEIVED",t["ON_FORM_SUBMIT"]="ON_FORM_SUBMIT"})(_||(_={}));var T,k="executionParams",A=/this.params/g;y={},Object(r["a"])(y,p.API,x),Object(r["a"])(y,p.DB,w),Object(r["a"])(y,p.SAAS,O),m={},Object(r["a"])(m,p.API,E),Object(r["a"])(m,p.DB,[]),Object(r["a"])(m,p.SAAS,[]),b={},Object(r["a"])(b,p.API,S),Object(r["a"])(b,p.DB,{}),Object(r["a"])(b,p.SAAS,{});(function(t){t["TEXT"]="TEXT",t["REGEX"]="REGEX",t["NUMBER"]="NUMBER",t["BOOLEAN"]="BOOLEAN",t["OBJECT"]="OBJECT",t["ARRAY"]="ARRAY",t["OBJECT_ARRAY"]="OBJECT_ARRAY",t["DATE_ISO_STRING"]="DATE_ISO_STRING",t["IMAGE_URL"]="IMAGE_URL",t["FUNCTION"]="FUNCTION",t["SAFE_URL"]="SAFE_URL"})(T||(T={}));Object(r["a"])({actionPaths:"actionPaths",appsmith:"appsmith",pageList:"pageList"},k,k);var C=function t(e){return e.map((function(e){e.id=g(),e.children&&(e.children=t(e.children));var n=e;return n.panelConfig&&n.panelConfig.children&&Array.isArray(n.panelConfig.children)&&(n.panelConfig.children=t(n.panelConfig.children),e=n),e}))};function N(t){return t.map((function(t){return t.children&&(t.children=t.children.map(I)),t}))}function I(t){var e=t;return void 0!==e.validation&&(e.validation=j(e.validation)),e.children&&(e.children=e.children.map(I)),e}function j(t){return t.type===T.FUNCTION&&t.params&&t.params.fn&&(t.params.fnString=t.params.fn.toString(),t.params.expected||console.error("Error in configuration ".concat(JSON.stringify(t),": For a ").concat(T.FUNCTION," type validation, expected type and example are mandatory")),delete t.params.fn),t}var P=function(){function t(){Object(o["a"])(this,t)}return Object(s["a"])(t,null,[{key:"registerWidgetBuilder",value:function(t,e,n,r,i,a){if(this.widgetMap.set(t,e),this.derivedPropertiesMap.set(t,n),this.defaultPropertiesMap.set(t,r),this.metaPropertiesMap.set(t,i),a){var o=N(a);this.propertyPaneConfigsMap.set(t,Object.freeze(C(o)))}}},{key:"createWidget",value:function(t,e){var n=a(a({key:t.widgetId,isVisible:!0},t),{},{renderMode:e}),r=this.widgetMap.get(t.type);if(r){var i=r.buildWidget(n);return i}var o={message:"Widget Builder not registered for widget type"+t.type};return console.error(o),null}},{key:"getWidgetTypes",value:function(){return Array.from(this.widgetMap.keys())}},{key:"getWidgetDerivedPropertiesMap",value:function(t){var e=this.derivedPropertiesMap.get(t);return e||(console.error("Widget type validation is not defined"),{})}},{key:"getWidgetDefaultPropertiesMap",value:function(t){var e=this.defaultPropertiesMap.get(t);return e||(console.error("Widget default properties not defined",t),{})}},{key:"getWidgetMetaPropertiesMap",value:function(t){var e=this.metaPropertiesMap.get(t);return e||(console.error("Widget meta properties not defined: ",t),{})}},{key:"getWidgetPropertyPaneConfig",value:function(t){var e=this.propertyPaneConfigsMap.get(t);return e||(console.error("Widget property pane configs not defined",t),[])}},{key:"getWidgetTypeConfigMap",value:function(){var e={};return t.getWidgetTypes().forEach((function(n){e[n]={defaultProperties:t.getWidgetDefaultPropertiesMap(n),derivedProperties:t.getWidgetDerivedPropertiesMap(n),metaProperties:t.getWidgetMetaPropertiesMap(n)}})),e}}]),t}();Object(r["a"])(P,"widgetMap",new Map),Object(r["a"])(P,"widgetDerivedPropertiesGetterMap",new Map),Object(r["a"])(P,"derivedPropertiesMap",new Map),Object(r["a"])(P,"defaultPropertiesMap",new Map),Object(r["a"])(P,"metaPropertiesMap",new Map),Object(r["a"])(P,"propertyPaneConfigsMap",new Map);var R=n(6),D=/{{([\s\S]*?)}}/,M=/["']({{[\s\S]*?}})["']/g,L=n(15),V=n.n(L),F=n(35),B=n.n(F),U=n(26),H=n(16);function W(t,e){var n="undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=Object(H["a"])(t))||e&&t&&"number"===typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){s=!0,a=t},f:function(){try{o||null==n["return"]||n["return"]()}finally{if(s)throw a}}}}var G,$,q=n(7),z=n(9),Y=n(10),K=n(27),J=n(36),X=n.n(J);(function(t){t["ACTION"]="ACTION",t["DATASOURCE"]="DATASOURCE",t["WIDGET"]="WIDGET"})(G||(G={})),function(t){t["INFO"]="info",t["WARNING"]="warning",t["ERROR"]="error"}($||($={}));var Q={3:"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",5:"class enum extends super const export import",6:"enum",strict:"implements interface let package private protected public static yield",strictBind:"eval arguments"},Z="break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this",tt={5:Z,"5module":Z+" export import",6:Z+" const class extends export import super"},et=/^in(stanceof)?$/,nt="\xaa\xb5\xba\xc0-\xd6\xd8-\xf6\xf8-\u02c1\u02c6-\u02d1\u02e0-\u02e4\u02ec\u02ee\u0370-\u0374\u0376\u0377\u037a-\u037d\u037f\u0386\u0388-\u038a\u038c\u038e-\u03a1\u03a3-\u03f5\u03f7-\u0481\u048a-\u052f\u0531-\u0556\u0559\u0560-\u0588\u05d0-\u05ea\u05ef-\u05f2\u0620-\u064a\u066e\u066f\u0671-\u06d3\u06d5\u06e5\u06e6\u06ee\u06ef\u06fa-\u06fc\u06ff\u0710\u0712-\u072f\u074d-\u07a5\u07b1\u07ca-\u07ea\u07f4\u07f5\u07fa\u0800-\u0815\u081a\u0824\u0828\u0840-\u0858\u0860-\u086a\u08a0-\u08b4\u08b6-\u08c7\u0904-\u0939\u093d\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098c\u098f\u0990\u0993-\u09a8\u09aa-\u09b0\u09b2\u09b6-\u09b9\u09bd\u09ce\u09dc\u09dd\u09df-\u09e1\u09f0\u09f1\u09fc\u0a05-\u0a0a\u0a0f\u0a10\u0a13-\u0a28\u0a2a-\u0a30\u0a32\u0a33\u0a35\u0a36\u0a38\u0a39\u0a59-\u0a5c\u0a5e\u0a72-\u0a74\u0a85-\u0a8d\u0a8f-\u0a91\u0a93-\u0aa8\u0aaa-\u0ab0\u0ab2\u0ab3\u0ab5-\u0ab9\u0abd\u0ad0\u0ae0\u0ae1\u0af9\u0b05-\u0b0c\u0b0f\u0b10\u0b13-\u0b28\u0b2a-\u0b30\u0b32\u0b33\u0b35-\u0b39\u0b3d\u0b5c\u0b5d\u0b5f-\u0b61\u0b71\u0b83\u0b85-\u0b8a\u0b8e-\u0b90\u0b92-\u0b95\u0b99\u0b9a\u0b9c\u0b9e\u0b9f\u0ba3\u0ba4\u0ba8-\u0baa\u0bae-\u0bb9\u0bd0\u0c05-\u0c0c\u0c0e-\u0c10\u0c12-\u0c28\u0c2a-\u0c39\u0c3d\u0c58-\u0c5a\u0c60\u0c61\u0c80\u0c85-\u0c8c\u0c8e-\u0c90\u0c92-\u0ca8\u0caa-\u0cb3\u0cb5-\u0cb9\u0cbd\u0cde\u0ce0\u0ce1\u0cf1\u0cf2\u0d04-\u0d0c\u0d0e-\u0d10\u0d12-\u0d3a\u0d3d\u0d4e\u0d54-\u0d56\u0d5f-\u0d61\u0d7a-\u0d7f\u0d85-\u0d96\u0d9a-\u0db1\u0db3-\u0dbb\u0dbd\u0dc0-\u0dc6\u0e01-\u0e30\u0e32\u0e33\u0e40-\u0e46\u0e81\u0e82\u0e84\u0e86-\u0e8a\u0e8c-\u0ea3\u0ea5\u0ea7-\u0eb0\u0eb2\u0eb3\u0ebd\u0ec0-\u0ec4\u0ec6\u0edc-\u0edf\u0f00\u0f40-\u0f47\u0f49-\u0f6c\u0f88-\u0f8c\u1000-\u102a\u103f\u1050-\u1055\u105a-\u105d\u1061\u1065\u1066\u106e-\u1070\u1075-\u1081\u108e\u10a0-\u10c5\u10c7\u10cd\u10d0-\u10fa\u10fc-\u1248\u124a-\u124d\u1250-\u1256\u1258\u125a-\u125d\u1260-\u1288\u128a-\u128d\u1290-\u12b0\u12b2-\u12b5\u12b8-\u12be\u12c0\u12c2-\u12c5\u12c8-\u12d6\u12d8-\u1310\u1312-\u1315\u1318-\u135a\u1380-\u138f\u13a0-\u13f5\u13f8-\u13fd\u1401-\u166c\u166f-\u167f\u1681-\u169a\u16a0-\u16ea\u16ee-\u16f8\u1700-\u170c\u170e-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176c\u176e-\u1770\u1780-\u17b3\u17d7\u17dc\u1820-\u1878\u1880-\u18a8\u18aa\u18b0-\u18f5\u1900-\u191e\u1950-\u196d\u1970-\u1974\u1980-\u19ab\u19b0-\u19c9\u1a00-\u1a16\u1a20-\u1a54\u1aa7\u1b05-\u1b33\u1b45-\u1b4b\u1b83-\u1ba0\u1bae\u1baf\u1bba-\u1be5\u1c00-\u1c23\u1c4d-\u1c4f\u1c5a-\u1c7d\u1c80-\u1c88\u1c90-\u1cba\u1cbd-\u1cbf\u1ce9-\u1cec\u1cee-\u1cf3\u1cf5\u1cf6\u1cfa\u1d00-\u1dbf\u1e00-\u1f15\u1f18-\u1f1d\u1f20-\u1f45\u1f48-\u1f4d\u1f50-\u1f57\u1f59\u1f5b\u1f5d\u1f5f-\u1f7d\u1f80-\u1fb4\u1fb6-\u1fbc\u1fbe\u1fc2-\u1fc4\u1fc6-\u1fcc\u1fd0-\u1fd3\u1fd6-\u1fdb\u1fe0-\u1fec\u1ff2-\u1ff4\u1ff6-\u1ffc\u2071\u207f\u2090-\u209c\u2102\u2107\u210a-\u2113\u2115\u2118-\u211d\u2124\u2126\u2128\u212a-\u2139\u213c-\u213f\u2145-\u2149\u214e\u2160-\u2188\u2c00-\u2c2e\u2c30-\u2c5e\u2c60-\u2ce4\u2ceb-\u2cee\u2cf2\u2cf3\u2d00-\u2d25\u2d27\u2d2d\u2d30-\u2d67\u2d6f\u2d80-\u2d96\u2da0-\u2da6\u2da8-\u2dae\u2db0-\u2db6\u2db8-\u2dbe\u2dc0-\u2dc6\u2dc8-\u2dce\u2dd0-\u2dd6\u2dd8-\u2dde\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303c\u3041-\u3096\u309b-\u309f\u30a1-\u30fa\u30fc-\u30ff\u3105-\u312f\u3131-\u318e\u31a0-\u31bf\u31f0-\u31ff\u3400-\u4dbf\u4e00-\u9ffc\ua000-\ua48c\ua4d0-\ua4fd\ua500-\ua60c\ua610-\ua61f\ua62a\ua62b\ua640-\ua66e\ua67f-\ua69d\ua6a0-\ua6ef\ua717-\ua71f\ua722-\ua788\ua78b-\ua7bf\ua7c2-\ua7ca\ua7f5-\ua801\ua803-\ua805\ua807-\ua80a\ua80c-\ua822\ua840-\ua873\ua882-\ua8b3\ua8f2-\ua8f7\ua8fb\ua8fd\ua8fe\ua90a-\ua925\ua930-\ua946\ua960-\ua97c\ua984-\ua9b2\ua9cf\ua9e0-\ua9e4\ua9e6-\ua9ef\ua9fa-\ua9fe\uaa00-\uaa28\uaa40-\uaa42\uaa44-\uaa4b\uaa60-\uaa76\uaa7a\uaa7e-\uaaaf\uaab1\uaab5\uaab6\uaab9-\uaabd\uaac0\uaac2\uaadb-\uaadd\uaae0-\uaaea\uaaf2-\uaaf4\uab01-\uab06\uab09-\uab0e\uab11-\uab16\uab20-\uab26\uab28-\uab2e\uab30-\uab5a\uab5c-\uab69\uab70-\uabe2\uac00-\ud7a3\ud7b0-\ud7c6\ud7cb-\ud7fb\uf900-\ufa6d\ufa70-\ufad9\ufb00-\ufb06\ufb13-\ufb17\ufb1d\ufb1f-\ufb28\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40\ufb41\ufb43\ufb44\ufb46-\ufbb1\ufbd3-\ufd3d\ufd50-\ufd8f\ufd92-\ufdc7\ufdf0-\ufdfb\ufe70-\ufe74\ufe76-\ufefc\uff21-\uff3a\uff41-\uff5a\uff66-\uffbe\uffc2-\uffc7\uffca-\uffcf\uffd2-\uffd7\uffda-\uffdc",rt="\u200c\u200d\xb7\u0300-\u036f\u0387\u0483-\u0487\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u0669\u0670\u06d6-\u06dc\u06df-\u06e4\u06e7\u06e8\u06ea-\u06ed\u06f0-\u06f9\u0711\u0730-\u074a\u07a6-\u07b0\u07c0-\u07c9\u07eb-\u07f3\u07fd\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0859-\u085b\u08d3-\u08e1\u08e3-\u0903\u093a-\u093c\u093e-\u094f\u0951-\u0957\u0962\u0963\u0966-\u096f\u0981-\u0983\u09bc\u09be-\u09c4\u09c7\u09c8\u09cb-\u09cd\u09d7\u09e2\u09e3\u09e6-\u09ef\u09fe\u0a01-\u0a03\u0a3c\u0a3e-\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a66-\u0a71\u0a75\u0a81-\u0a83\u0abc\u0abe-\u0ac5\u0ac7-\u0ac9\u0acb-\u0acd\u0ae2\u0ae3\u0ae6-\u0aef\u0afa-\u0aff\u0b01-\u0b03\u0b3c\u0b3e-\u0b44\u0b47\u0b48\u0b4b-\u0b4d\u0b55-\u0b57\u0b62\u0b63\u0b66-\u0b6f\u0b82\u0bbe-\u0bc2\u0bc6-\u0bc8\u0bca-\u0bcd\u0bd7\u0be6-\u0bef\u0c00-\u0c04\u0c3e-\u0c44\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0c66-\u0c6f\u0c81-\u0c83\u0cbc\u0cbe-\u0cc4\u0cc6-\u0cc8\u0cca-\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0ce6-\u0cef\u0d00-\u0d03\u0d3b\u0d3c\u0d3e-\u0d44\u0d46-\u0d48\u0d4a-\u0d4d\u0d57\u0d62\u0d63\u0d66-\u0d6f\u0d81-\u0d83\u0dca\u0dcf-\u0dd4\u0dd6\u0dd8-\u0ddf\u0de6-\u0def\u0df2\u0df3\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0e50-\u0e59\u0eb1\u0eb4-\u0ebc\u0ec8-\u0ecd\u0ed0-\u0ed9\u0f18\u0f19\u0f20-\u0f29\u0f35\u0f37\u0f39\u0f3e\u0f3f\u0f71-\u0f84\u0f86\u0f87\u0f8d-\u0f97\u0f99-\u0fbc\u0fc6\u102b-\u103e\u1040-\u1049\u1056-\u1059\u105e-\u1060\u1062-\u1064\u1067-\u106d\u1071-\u1074\u1082-\u108d\u108f-\u109d\u135d-\u135f\u1369-\u1371\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b4-\u17d3\u17dd\u17e0-\u17e9\u180b-\u180d\u1810-\u1819\u18a9\u1920-\u192b\u1930-\u193b\u1946-\u194f\u19d0-\u19da\u1a17-\u1a1b\u1a55-\u1a5e\u1a60-\u1a7c\u1a7f-\u1a89\u1a90-\u1a99\u1ab0-\u1abd\u1abf\u1ac0\u1b00-\u1b04\u1b34-\u1b44\u1b50-\u1b59\u1b6b-\u1b73\u1b80-\u1b82\u1ba1-\u1bad\u1bb0-\u1bb9\u1be6-\u1bf3\u1c24-\u1c37\u1c40-\u1c49\u1c50-\u1c59\u1cd0-\u1cd2\u1cd4-\u1ce8\u1ced\u1cf4\u1cf7-\u1cf9\u1dc0-\u1df9\u1dfb-\u1dff\u203f\u2040\u2054\u20d0-\u20dc\u20e1\u20e5-\u20f0\u2cef-\u2cf1\u2d7f\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua620-\ua629\ua66f\ua674-\ua67d\ua69e\ua69f\ua6f0\ua6f1\ua802\ua806\ua80b\ua823-\ua827\ua82c\ua880\ua881\ua8b4-\ua8c5\ua8d0-\ua8d9\ua8e0-\ua8f1\ua8ff-\ua909\ua926-\ua92d\ua947-\ua953\ua980-\ua983\ua9b3-\ua9c0\ua9d0-\ua9d9\ua9e5\ua9f0-\ua9f9\uaa29-\uaa36\uaa43\uaa4c\uaa4d\uaa50-\uaa59\uaa7b-\uaa7d\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uaaeb-\uaaef\uaaf5\uaaf6\uabe3-\uabea\uabec\uabed\uabf0-\uabf9\ufb1e\ufe00-\ufe0f\ufe20-\ufe2f\ufe33\ufe34\ufe4d-\ufe4f\uff10-\uff19\uff3f",it=new RegExp("["+nt+"]"),at=new RegExp("["+nt+rt+"]");nt=rt=null;var ot=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,157,310,10,21,11,7,153,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,107,20,28,22,13,52,76,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,85,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,230,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,35,56,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,190,0,80,921,103,110,18,195,2749,1070,4050,582,8634,568,8,30,114,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8952,286,50,2,18,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,2357,44,11,6,17,0,370,43,1301,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42717,35,4148,12,221,3,5761,15,7472,3104,541,1507,4938],st=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,154,10,176,2,54,14,32,9,16,3,46,10,54,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,161,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,19306,9,135,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,5319,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,262,6,10,9,419,13,1495,6,110,6,6,9,4759,9,787719,239];function ut(t,e){for(var n=65536,r=0;rt)return!1;if(n+=e[r+1],n>=t)return!0}}function ct(t,e){return t<65?36===t:t<91||(t<97?95===t:t<123||(t<=65535?t>=170&&it.test(String.fromCharCode(t)):!1!==e&&ut(t,ot)))}function lt(t,e){return t<48?36===t:t<58||!(t<65)&&(t<91||(t<97?95===t:t<123||(t<=65535?t>=170&&at.test(String.fromCharCode(t)):!1!==e&&(ut(t,ot)||ut(t,st)))))}var ht=function(t,e){void 0===e&&(e={}),this.label=t,this.keyword=e.keyword,this.beforeExpr=!!e.beforeExpr,this.startsExpr=!!e.startsExpr,this.isLoop=!!e.isLoop,this.isAssign=!!e.isAssign,this.prefix=!!e.prefix,this.postfix=!!e.postfix,this.binop=e.binop||null,this.updateContext=null};function pt(t,e){return new ht(t,{beforeExpr:!0,binop:e})}var ft={beforeExpr:!0},dt={startsExpr:!0},vt={};function gt(t,e){return void 0===e&&(e={}),e.keyword=t,vt[t]=new ht(t,e)}var yt={num:new ht("num",dt),regexp:new ht("regexp",dt),string:new ht("string",dt),name:new ht("name",dt),eof:new ht("eof"),bracketL:new ht("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new ht("]"),braceL:new ht("{",{beforeExpr:!0,startsExpr:!0}),braceR:new ht("}"),parenL:new ht("(",{beforeExpr:!0,startsExpr:!0}),parenR:new ht(")"),comma:new ht(",",ft),semi:new ht(";",ft),colon:new ht(":",ft),dot:new ht("."),question:new ht("?",ft),questionDot:new ht("?."),arrow:new ht("=>",ft),template:new ht("template"),invalidTemplate:new ht("invalidTemplate"),ellipsis:new ht("...",ft),backQuote:new ht("`",dt),dollarBraceL:new ht("${",{beforeExpr:!0,startsExpr:!0}),eq:new ht("=",{beforeExpr:!0,isAssign:!0}),assign:new ht("_=",{beforeExpr:!0,isAssign:!0}),incDec:new ht("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new ht("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:pt("||",1),logicalAND:pt("&&",2),bitwiseOR:pt("|",3),bitwiseXOR:pt("^",4),bitwiseAND:pt("&",5),equality:pt("==/!=/===/!==",6),relational:pt("/<=/>=",7),bitShift:pt("<>/>>>",8),plusMin:new ht("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:pt("%",10),star:pt("*",10),slash:pt("/",10),starstar:new ht("**",{beforeExpr:!0}),coalesce:pt("??",1),_break:gt("break"),_case:gt("case",ft),_catch:gt("catch"),_continue:gt("continue"),_debugger:gt("debugger"),_default:gt("default",ft),_do:gt("do",{isLoop:!0,beforeExpr:!0}),_else:gt("else",ft),_finally:gt("finally"),_for:gt("for",{isLoop:!0}),_function:gt("function",dt),_if:gt("if"),_return:gt("return",ft),_switch:gt("switch"),_throw:gt("throw",ft),_try:gt("try"),_var:gt("var"),_const:gt("const"),_while:gt("while",{isLoop:!0}),_with:gt("with"),_new:gt("new",{beforeExpr:!0,startsExpr:!0}),_this:gt("this",dt),_super:gt("super",dt),_class:gt("class",dt),_extends:gt("extends",ft),_export:gt("export"),_import:gt("import",dt),_null:gt("null",dt),_true:gt("true",dt),_false:gt("false",dt),_in:gt("in",{beforeExpr:!0,binop:7}),_instanceof:gt("instanceof",{beforeExpr:!0,binop:7}),_typeof:gt("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:gt("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:gt("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},mt=/\r\n?|\n|\u2028|\u2029/,bt=new RegExp(mt.source,"g");function _t(t,e){return 10===t||13===t||!e&&(8232===t||8233===t)}var wt=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,xt=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,Et=Object.prototype,Ot=Et.hasOwnProperty,St=Et.toString;function Tt(t,e){return Ot.call(t,e)}var kt=Array.isArray||function(t){return"[object Array]"===St.call(t)};function At(t){return new RegExp("^(?:"+t.replace(/ /g,"|")+")$")}var Ct=function(t,e){this.line=t,this.column=e};Ct.prototype.offset=function(t){return new Ct(this.line,this.column+t)};var Nt=function(t,e,n){this.start=e,this.end=n,null!==t.sourceFile&&(this.source=t.sourceFile)};function It(t,e){for(var n=1,r=0;;){bt.lastIndex=r;var i=bt.exec(t);if(!(i&&i.index=2015&&(e.ecmaVersion-=2009),null==e.allowReserved&&(e.allowReserved=e.ecmaVersion<5),kt(e.onToken)){var r=e.onToken;e.onToken=function(t){return r.push(t)}}return kt(e.onComment)&&(e.onComment=Rt(e,e.onComment)),e}function Rt(t,e){return function(n,r,i,a,o,s){var u={type:n?"Block":"Line",value:r,start:i,end:a};t.locations&&(u.loc=new Nt(this,o,s)),t.ranges&&(u.range=[i,a]),e.push(u)}}var Dt=1,Mt=2,Lt=Dt|Mt,Vt=4,Ft=8,Bt=16,Ut=32,Ht=64,Wt=128;function Gt(t,e){return Mt|(t?Vt:0)|(e?Ft:0)}var $t=0,qt=1,zt=2,Yt=3,Kt=4,Jt=5,Xt=function(t,e,n){this.options=t=Pt(t),this.sourceFile=t.sourceFile,this.keywords=At(tt[t.ecmaVersion>=6?6:"module"===t.sourceType?"5module":5]);var r="";if(!0!==t.allowReserved){for(var i=t.ecmaVersion;;i--)if(r=Q[i])break;"module"===t.sourceType&&(r+=" await")}this.reservedWords=At(r);var a=(r?r+" ":"")+Q.strict;this.reservedWordsStrict=At(a),this.reservedWordsStrictBind=At(a+" "+Q.strictBind),this.input=String(e),this.containsEsc=!1,n?(this.pos=n,this.lineStart=this.input.lastIndexOf("\n",n-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(mt).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=yt.eof,this.value=null,this.start=this.end=this.pos,this.startLoc=this.endLoc=this.curPosition(),this.lastTokEndLoc=this.lastTokStartLoc=null,this.lastTokStart=this.lastTokEnd=this.pos,this.context=this.initialContext(),this.exprAllowed=!0,this.inModule="module"===t.sourceType,this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports={},0===this.pos&&t.allowHashBang&&"#!"===this.input.slice(0,2)&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(Dt),this.regexpState=null},Qt={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0}};Xt.prototype.parse=function(){var t=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(t)},Qt.inFunction.get=function(){return(this.currentVarScope().flags&Mt)>0},Qt.inGenerator.get=function(){return(this.currentVarScope().flags&Ft)>0},Qt.inAsync.get=function(){return(this.currentVarScope().flags&Vt)>0},Qt.allowSuper.get=function(){return(this.currentThisScope().flags&Ht)>0},Qt.allowDirectSuper.get=function(){return(this.currentThisScope().flags&Wt)>0},Qt.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},Xt.prototype.inNonArrowFunction=function(){return(this.currentThisScope().flags&Mt)>0},Xt.extend=function(){var t=[],e=arguments.length;while(e--)t[e]=arguments[e];for(var n=this,r=0;r=,?^&]/.test(i)||"!"===i&&"="===this.input.charAt(r+1))}t+=e[0].length,xt.lastIndex=t,t+=xt.exec(this.input)[0].length,";"===this.input[t]&&t++}},Zt.eat=function(t){return this.type===t&&(this.next(),!0)},Zt.isContextual=function(t){return this.type===yt.name&&this.value===t&&!this.containsEsc},Zt.eatContextual=function(t){return!!this.isContextual(t)&&(this.next(),!0)},Zt.expectContextual=function(t){this.eatContextual(t)||this.unexpected()},Zt.canInsertSemicolon=function(){return this.type===yt.eof||this.type===yt.braceR||mt.test(this.input.slice(this.lastTokEnd,this.start))},Zt.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0},Zt.semicolon=function(){this.eat(yt.semi)||this.insertSemicolon()||this.unexpected()},Zt.afterTrailingComma=function(t,e){if(this.type===t)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),e||this.next(),!0},Zt.expect=function(t){this.eat(t)||this.unexpected()},Zt.unexpected=function(t){this.raise(null!=t?t:this.start,"Unexpected token")},Zt.checkPatternErrors=function(t,e){if(t){t.trailingComma>-1&&this.raiseRecoverable(t.trailingComma,"Comma is not permitted after the rest element");var n=e?t.parenthesizedAssign:t.parenthesizedBind;n>-1&&this.raiseRecoverable(n,"Parenthesized pattern")}},Zt.checkExpressionErrors=function(t,e){if(!t)return!1;var n=t.shorthandAssign,r=t.doubleProto;if(!e)return n>=0||r>=0;n>=0&&this.raise(n,"Shorthand property assignments are valid only in destructuring patterns"),r>=0&&this.raiseRecoverable(r,"Redefinition of __proto__ property")},Zt.checkYieldAwaitInDefaultParams=function(){this.yieldPos&&(!this.awaitPos||this.yieldPos=6&&this.unexpected(),this.parseFunctionStatement(a,!1,!t);case yt._class:return t&&this.unexpected(),this.parseClass(a,!0);case yt._if:return this.parseIfStatement(a);case yt._return:return this.parseReturnStatement(a);case yt._switch:return this.parseSwitchStatement(a);case yt._throw:return this.parseThrowStatement(a);case yt._try:return this.parseTryStatement(a);case yt._const:case yt._var:return r=r||this.value,t&&"var"!==r&&this.unexpected(),this.parseVarStatement(a,r);case yt._while:return this.parseWhileStatement(a);case yt._with:return this.parseWithStatement(a);case yt.braceL:return this.parseBlock(!0,a);case yt.semi:return this.parseEmptyStatement(a);case yt._export:case yt._import:if(this.options.ecmaVersion>10&&i===yt._import){xt.lastIndex=this.pos;var o=xt.exec(this.input),s=this.pos+o[0].length,u=this.input.charCodeAt(s);if(40===u||46===u)return this.parseExpressionStatement(a,this.parseExpression())}return this.options.allowImportExportEverywhere||(e||this.raise(this.start,"'import' and 'export' may only appear at the top level"),this.inModule||this.raise(this.start,"'import' and 'export' may appear only with 'sourceType: module'")),i===yt._import?this.parseImport(a):this.parseExport(a,n);default:if(this.isAsyncFunction())return t&&this.unexpected(),this.next(),this.parseFunctionStatement(a,!0,!t);var c=this.value,l=this.parseExpression();return i===yt.name&&"Identifier"===l.type&&this.eat(yt.colon)?this.parseLabeledStatement(a,c,l,t):this.parseExpressionStatement(a,l)}},ne.parseBreakContinueStatement=function(t,e){var n="break"===e;this.next(),this.eat(yt.semi)||this.insertSemicolon()?t.label=null:this.type!==yt.name?this.unexpected():(t.label=this.parseIdent(),this.semicolon());for(var r=0;r=6?this.eat(yt.semi):this.semicolon(),this.finishNode(t,"DoWhileStatement")},ne.parseForStatement=function(t){this.next();var e=this.options.ecmaVersion>=9&&(this.inAsync||!this.inFunction&&this.options.allowAwaitOutsideFunction)&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push(re),this.enterScope(0),this.expect(yt.parenL),this.type===yt.semi)return e>-1&&this.unexpected(e),this.parseFor(t,null);var n=this.isLet();if(this.type===yt._var||this.type===yt._const||n){var r=this.startNode(),i=n?"let":this.value;return this.next(),this.parseVar(r,!0,i),this.finishNode(r,"VariableDeclaration"),(this.type===yt._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&1===r.declarations.length?(this.options.ecmaVersion>=9&&(this.type===yt._in?e>-1&&this.unexpected(e):t.await=e>-1),this.parseForIn(t,r)):(e>-1&&this.unexpected(e),this.parseFor(t,r))}var a=new ee,o=this.parseExpression(!0,a);return this.type===yt._in||this.options.ecmaVersion>=6&&this.isContextual("of")?(this.options.ecmaVersion>=9&&(this.type===yt._in?e>-1&&this.unexpected(e):t.await=e>-1),this.toAssignable(o,!1,a),this.checkLVal(o),this.parseForIn(t,o)):(this.checkExpressionErrors(a,!0),e>-1&&this.unexpected(e),this.parseFor(t,o))},ne.parseFunctionStatement=function(t,e,n){return this.next(),this.parseFunction(t,oe|(n?0:se),!1,e)},ne.parseIfStatement=function(t){return this.next(),t.test=this.parseParenExpression(),t.consequent=this.parseStatement("if"),t.alternate=this.eat(yt._else)?this.parseStatement("if"):null,this.finishNode(t,"IfStatement")},ne.parseReturnStatement=function(t){return this.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.start,"'return' outside of function"),this.next(),this.eat(yt.semi)||this.insertSemicolon()?t.argument=null:(t.argument=this.parseExpression(),this.semicolon()),this.finishNode(t,"ReturnStatement")},ne.parseSwitchStatement=function(t){var e;this.next(),t.discriminant=this.parseParenExpression(),t.cases=[],this.expect(yt.braceL),this.labels.push(ie),this.enterScope(0);for(var n=!1;this.type!==yt.braceR;)if(this.type===yt._case||this.type===yt._default){var r=this.type===yt._case;e&&this.finishNode(e,"SwitchCase"),t.cases.push(e=this.startNode()),e.consequent=[],this.next(),r?e.test=this.parseExpression():(n&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),n=!0,e.test=null),this.expect(yt.colon)}else e||this.unexpected(),e.consequent.push(this.parseStatement(null));return this.exitScope(),e&&this.finishNode(e,"SwitchCase"),this.next(),this.labels.pop(),this.finishNode(t,"SwitchStatement")},ne.parseThrowStatement=function(t){return this.next(),mt.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,"Illegal newline after throw"),t.argument=this.parseExpression(),this.semicolon(),this.finishNode(t,"ThrowStatement")};var ae=[];ne.parseTryStatement=function(t){if(this.next(),t.block=this.parseBlock(),t.handler=null,this.type===yt._catch){var e=this.startNode();if(this.next(),this.eat(yt.parenL)){e.param=this.parseBindingAtom();var n="Identifier"===e.param.type;this.enterScope(n?Ut:0),this.checkLVal(e.param,n?Kt:zt),this.expect(yt.parenR)}else this.options.ecmaVersion<10&&this.unexpected(),e.param=null,this.enterScope(0);e.body=this.parseBlock(!1),this.exitScope(),t.handler=this.finishNode(e,"CatchClause")}return t.finalizer=this.eat(yt._finally)?this.parseBlock():null,t.handler||t.finalizer||this.raise(t.start,"Missing catch or finally clause"),this.finishNode(t,"TryStatement")},ne.parseVarStatement=function(t,e){return this.next(),this.parseVar(t,!1,e),this.semicolon(),this.finishNode(t,"VariableDeclaration")},ne.parseWhileStatement=function(t){return this.next(),t.test=this.parseParenExpression(),this.labels.push(re),t.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(t,"WhileStatement")},ne.parseWithStatement=function(t){return this.strict&&this.raise(this.start,"'with' in strict mode"),this.next(),t.object=this.parseParenExpression(),t.body=this.parseStatement("with"),this.finishNode(t,"WithStatement")},ne.parseEmptyStatement=function(t){return this.next(),this.finishNode(t,"EmptyStatement")},ne.parseLabeledStatement=function(t,e,n,r){for(var i=0,a=this.labels;i=0;u--){var c=this.labels[u];if(c.statementStart!==t.start)break;c.statementStart=this.start,c.kind=s}return this.labels.push({name:e,kind:s,statementStart:this.start}),t.body=this.parseStatement(r?-1===r.indexOf("label")?r+"label":r:"label"),this.labels.pop(),t.label=n,this.finishNode(t,"LabeledStatement")},ne.parseExpressionStatement=function(t,e){return t.expression=e,this.semicolon(),this.finishNode(t,"ExpressionStatement")},ne.parseBlock=function(t,e,n){void 0===t&&(t=!0),void 0===e&&(e=this.startNode()),e.body=[],this.expect(yt.braceL),t&&this.enterScope(0);while(this.type!==yt.braceR){var r=this.parseStatement(null);e.body.push(r)}return n&&(this.strict=!1),this.next(),t&&this.exitScope(),this.finishNode(e,"BlockStatement")},ne.parseFor=function(t,e){return t.init=e,this.expect(yt.semi),t.test=this.type===yt.semi?null:this.parseExpression(),this.expect(yt.semi),t.update=this.type===yt.parenR?null:this.parseExpression(),this.expect(yt.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,"ForStatement")},ne.parseForIn=function(t,e){var n=this.type===yt._in;return this.next(),"VariableDeclaration"===e.type&&null!=e.declarations[0].init&&(!n||this.options.ecmaVersion<8||this.strict||"var"!==e.kind||"Identifier"!==e.declarations[0].id.type)?this.raise(e.start,(n?"for-in":"for-of")+" loop variable declaration may not have an initializer"):"AssignmentPattern"===e.type&&this.raise(e.start,"Invalid left-hand side in for-loop"),t.left=e,t.right=n?this.parseExpression():this.parseMaybeAssign(),this.expect(yt.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,n?"ForInStatement":"ForOfStatement")},ne.parseVar=function(t,e,n){for(t.declarations=[],t.kind=n;;){var r=this.startNode();if(this.parseVarId(r,n),this.eat(yt.eq)?r.init=this.parseMaybeAssign(e):"const"!==n||this.type===yt._in||this.options.ecmaVersion>=6&&this.isContextual("of")?"Identifier"===r.id.type||e&&(this.type===yt._in||this.isContextual("of"))?r.init=null:this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):this.unexpected(),t.declarations.push(this.finishNode(r,"VariableDeclarator")),!this.eat(yt.comma))break}return t},ne.parseVarId=function(t,e){t.id=this.parseBindingAtom(),this.checkLVal(t.id,"var"===e?qt:zt,!1)};var oe=1,se=2,ue=4;ne.parseFunction=function(t,e,n,r){this.initFunction(t),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!r)&&(this.type===yt.star&&e&se&&this.unexpected(),t.generator=this.eat(yt.star)),this.options.ecmaVersion>=8&&(t.async=!!r),e&oe&&(t.id=e&ue&&this.type!==yt.name?null:this.parseIdent(),!t.id||e&se||this.checkLVal(t.id,this.strict||t.generator||t.async?this.treatFunctionsAsVar?qt:zt:Yt));var i=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(Gt(t.async,t.generator)),e&oe||(t.id=this.type===yt.name?this.parseIdent():null),this.parseFunctionParams(t),this.parseFunctionBody(t,n,!1),this.yieldPos=i,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(t,e&oe?"FunctionDeclaration":"FunctionExpression")},ne.parseFunctionParams=function(t){this.expect(yt.parenL),t.params=this.parseBindingList(yt.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},ne.parseClass=function(t,e){this.next();var n=this.strict;this.strict=!0,this.parseClassId(t,e),this.parseClassSuper(t);var r=this.startNode(),i=!1;r.body=[],this.expect(yt.braceL);while(this.type!==yt.braceR){var a=this.parseClassElement(null!==t.superClass);a&&(r.body.push(a),"MethodDefinition"===a.type&&"constructor"===a.kind&&(i&&this.raise(a.start,"Duplicate constructor in the same class"),i=!0))}return this.strict=n,this.next(),t.body=this.finishNode(r,"ClassBody"),this.finishNode(t,e?"ClassDeclaration":"ClassExpression")},ne.parseClassElement=function(t){var e=this;if(this.eat(yt.semi))return null;var n=this.startNode(),r=function(t,r){void 0===r&&(r=!1);var i=e.start,a=e.startLoc;return!!e.eatContextual(t)&&(!(e.type===yt.parenL||r&&e.canInsertSemicolon())||(n.key&&e.unexpected(),n.computed=!1,n.key=e.startNodeAt(i,a),n.key.name=t,e.finishNode(n.key,"Identifier"),!1))};n.kind="method",n.static=r("static");var i=this.eat(yt.star),a=!1;i||(this.options.ecmaVersion>=8&&r("async",!0)?(a=!0,i=this.options.ecmaVersion>=9&&this.eat(yt.star)):r("get")?n.kind="get":r("set")&&(n.kind="set")),n.key||this.parsePropertyName(n);var o=n.key,s=!1;return n.computed||n.static||!("Identifier"===o.type&&"constructor"===o.name||"Literal"===o.type&&"constructor"===o.value)?n.static&&"Identifier"===o.type&&"prototype"===o.name&&this.raise(o.start,"Classes may not have a static property named prototype"):("method"!==n.kind&&this.raise(o.start,"Constructor can't have get/set modifier"),i&&this.raise(o.start,"Constructor can't be a generator"),a&&this.raise(o.start,"Constructor can't be an async method"),n.kind="constructor",s=t),this.parseClassMethod(n,i,a,s),"get"===n.kind&&0!==n.value.params.length&&this.raiseRecoverable(n.value.start,"getter should have no params"),"set"===n.kind&&1!==n.value.params.length&&this.raiseRecoverable(n.value.start,"setter should have exactly one param"),"set"===n.kind&&"RestElement"===n.value.params[0].type&&this.raiseRecoverable(n.value.params[0].start,"Setter cannot use rest params"),n},ne.parseClassMethod=function(t,e,n,r){return t.value=this.parseMethod(e,n,r),this.finishNode(t,"MethodDefinition")},ne.parseClassId=function(t,e){this.type===yt.name?(t.id=this.parseIdent(),e&&this.checkLVal(t.id,zt,!1)):(!0===e&&this.unexpected(),t.id=null)},ne.parseClassSuper=function(t){t.superClass=this.eat(yt._extends)?this.parseExprSubscripts():null},ne.parseExport=function(t,e){if(this.next(),this.eat(yt.star))return this.options.ecmaVersion>=11&&(this.eatContextual("as")?(t.exported=this.parseIdent(!0),this.checkExport(e,t.exported.name,this.lastTokStart)):t.exported=null),this.expectContextual("from"),this.type!==yt.string&&this.unexpected(),t.source=this.parseExprAtom(),this.semicolon(),this.finishNode(t,"ExportAllDeclaration");if(this.eat(yt._default)){var n;if(this.checkExport(e,"default",this.lastTokStart),this.type===yt._function||(n=this.isAsyncFunction())){var r=this.startNode();this.next(),n&&this.next(),t.declaration=this.parseFunction(r,oe|ue,!1,n)}else if(this.type===yt._class){var i=this.startNode();t.declaration=this.parseClass(i,"nullableID")}else t.declaration=this.parseMaybeAssign(),this.semicolon();return this.finishNode(t,"ExportDefaultDeclaration")}if(this.shouldParseExportStatement())t.declaration=this.parseStatement(null),"VariableDeclaration"===t.declaration.type?this.checkVariableExport(e,t.declaration.declarations):this.checkExport(e,t.declaration.id.name,t.declaration.id.start),t.specifiers=[],t.source=null;else{if(t.declaration=null,t.specifiers=this.parseExportSpecifiers(e),this.eatContextual("from"))this.type!==yt.string&&this.unexpected(),t.source=this.parseExprAtom();else{for(var a=0,o=t.specifiers;a=6&&t)switch(t.type){case"Identifier":this.inAsync&&"await"===t.name&&this.raise(t.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"RestElement":break;case"ObjectExpression":t.type="ObjectPattern",n&&this.checkPatternErrors(n,!0);for(var r=0,i=t.properties;r=8&&!a&&"async"===o.name&&!this.canInsertSemicolon()&&this.eat(yt._function))return this.parseFunction(this.startNodeAt(r,i),0,!1,!0);if(n&&!this.canInsertSemicolon()){if(this.eat(yt.arrow))return this.parseArrowExpression(this.startNodeAt(r,i),[o],!1);if(this.options.ecmaVersion>=8&&"async"===o.name&&this.type===yt.name&&!a)return o=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(yt.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(r,i),[o],!0)}return o;case yt.regexp:var s=this.value;return e=this.parseLiteral(s.value),e.regex={pattern:s.pattern,flags:s.flags},e;case yt.num:case yt.string:return this.parseLiteral(this.value);case yt._null:case yt._true:case yt._false:return e=this.startNode(),e.value=this.type===yt._null?null:this.type===yt._true,e.raw=this.type.keyword,this.next(),this.finishNode(e,"Literal");case yt.parenL:var u=this.start,c=this.parseParenAndDistinguishExpression(n);return t&&(t.parenthesizedAssign<0&&!this.isSimpleAssignTarget(c)&&(t.parenthesizedAssign=u),t.parenthesizedBind<0&&(t.parenthesizedBind=u)),c;case yt.bracketL:return e=this.startNode(),this.next(),e.elements=this.parseExprList(yt.bracketR,!0,!0,t),this.finishNode(e,"ArrayExpression");case yt.braceL:return this.parseObj(!1,t);case yt._function:return e=this.startNode(),this.next(),this.parseFunction(e,0);case yt._class:return this.parseClass(this.startNode(),!1);case yt._new:return this.parseNew();case yt.backQuote:return this.parseTemplate();case yt._import:return this.options.ecmaVersion>=11?this.parseExprImport():this.unexpected();default:this.unexpected()}},le.parseExprImport=function(){var t=this.startNode();this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import");var e=this.parseIdent(!0);switch(this.type){case yt.parenL:return this.parseDynamicImport(t);case yt.dot:return t.meta=e,this.parseImportMeta(t);default:this.unexpected()}},le.parseDynamicImport=function(t){if(this.next(),t.source=this.parseMaybeAssign(),!this.eat(yt.parenR)){var e=this.start;this.eat(yt.comma)&&this.eat(yt.parenR)?this.raiseRecoverable(e,"Trailing comma is not allowed in import()"):this.unexpected(e)}return this.finishNode(t,"ImportExpression")},le.parseImportMeta=function(t){this.next();var e=this.containsEsc;return t.property=this.parseIdent(!0),"meta"!==t.property.name&&this.raiseRecoverable(t.property.start,"The only valid meta property for import is 'import.meta'"),e&&this.raiseRecoverable(t.start,"'import.meta' must not contain escaped characters"),"module"!==this.options.sourceType&&this.raiseRecoverable(t.start,"Cannot use 'import.meta' outside a module"),this.finishNode(t,"MetaProperty")},le.parseLiteral=function(t){var e=this.startNode();return e.value=t,e.raw=this.input.slice(this.start,this.end),110===e.raw.charCodeAt(e.raw.length-1)&&(e.bigint=e.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(e,"Literal")},le.parseParenExpression=function(){this.expect(yt.parenL);var t=this.parseExpression();return this.expect(yt.parenR),t},le.parseParenAndDistinguishExpression=function(t){var e,n=this.start,r=this.startLoc,i=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var a,o=this.start,s=this.startLoc,u=[],c=!0,l=!1,h=new ee,p=this.yieldPos,f=this.awaitPos;this.yieldPos=0,this.awaitPos=0;while(this.type!==yt.parenR){if(c?c=!1:this.expect(yt.comma),i&&this.afterTrailingComma(yt.parenR,!0)){l=!0;break}if(this.type===yt.ellipsis){a=this.start,u.push(this.parseParenItem(this.parseRestBinding())),this.type===yt.comma&&this.raise(this.start,"Comma is not permitted after the rest element");break}u.push(this.parseMaybeAssign(!1,h,this.parseParenItem))}var d=this.start,v=this.startLoc;if(this.expect(yt.parenR),t&&!this.canInsertSemicolon()&&this.eat(yt.arrow))return this.checkPatternErrors(h,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=p,this.awaitPos=f,this.parseParenArrowList(n,r,u);u.length&&!l||this.unexpected(this.lastTokStart),a&&this.unexpected(a),this.checkExpressionErrors(h,!0),this.yieldPos=p||this.yieldPos,this.awaitPos=f||this.awaitPos,u.length>1?(e=this.startNodeAt(o,s),e.expressions=u,this.finishNodeAt(e,"SequenceExpression",d,v)):e=u[0]}else e=this.parseParenExpression();if(this.options.preserveParens){var g=this.startNodeAt(n,r);return g.expression=e,this.finishNode(g,"ParenthesizedExpression")}return e},le.parseParenItem=function(t){return t},le.parseParenArrowList=function(t,e,n){return this.parseArrowExpression(this.startNodeAt(t,e),n)};var he=[];le.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword new");var t=this.startNode(),e=this.parseIdent(!0);if(this.options.ecmaVersion>=6&&this.eat(yt.dot)){t.meta=e;var n=this.containsEsc;return t.property=this.parseIdent(!0),"target"!==t.property.name&&this.raiseRecoverable(t.property.start,"The only valid meta property for new is 'new.target'"),n&&this.raiseRecoverable(t.start,"'new.target' must not contain escaped characters"),this.inNonArrowFunction()||this.raiseRecoverable(t.start,"'new.target' can only be used in functions"),this.finishNode(t,"MetaProperty")}var r=this.start,i=this.startLoc,a=this.type===yt._import;return t.callee=this.parseSubscripts(this.parseExprAtom(),r,i,!0),a&&"ImportExpression"===t.callee.type&&this.raise(r,"Cannot use new with import()"),this.eat(yt.parenL)?t.arguments=this.parseExprList(yt.parenR,this.options.ecmaVersion>=8,!1):t.arguments=he,this.finishNode(t,"NewExpression")},le.parseTemplateElement=function(t){var e=t.isTagged,n=this.startNode();return this.type===yt.invalidTemplate?(e||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),n.value={raw:this.value,cooked:null}):n.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,"\n"),cooked:this.value},this.next(),n.tail=this.type===yt.backQuote,this.finishNode(n,"TemplateElement")},le.parseTemplate=function(t){void 0===t&&(t={});var e=t.isTagged;void 0===e&&(e=!1);var n=this.startNode();this.next(),n.expressions=[];var r=this.parseTemplateElement({isTagged:e});n.quasis=[r];while(!r.tail)this.type===yt.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(yt.dollarBraceL),n.expressions.push(this.parseExpression()),this.expect(yt.braceR),n.quasis.push(r=this.parseTemplateElement({isTagged:e}));return this.next(),this.finishNode(n,"TemplateLiteral")},le.isAsyncProp=function(t){return!t.computed&&"Identifier"===t.key.type&&"async"===t.key.name&&(this.type===yt.name||this.type===yt.num||this.type===yt.string||this.type===yt.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===yt.star)&&!mt.test(this.input.slice(this.lastTokEnd,this.start))},le.parseObj=function(t,e){var n=this.startNode(),r=!0,i={};n.properties=[],this.next();while(!this.eat(yt.braceR)){if(r)r=!1;else if(this.expect(yt.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(yt.braceR))break;var a=this.parseProperty(t,e);t||this.checkPropClash(a,i,e),n.properties.push(a)}return this.finishNode(n,t?"ObjectPattern":"ObjectExpression")},le.parseProperty=function(t,e){var n,r,i,a,o=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(yt.ellipsis))return t?(o.argument=this.parseIdent(!1),this.type===yt.comma&&this.raise(this.start,"Comma is not permitted after the rest element"),this.finishNode(o,"RestElement")):(this.type===yt.parenL&&e&&(e.parenthesizedAssign<0&&(e.parenthesizedAssign=this.start),e.parenthesizedBind<0&&(e.parenthesizedBind=this.start)),o.argument=this.parseMaybeAssign(!1,e),this.type===yt.comma&&e&&e.trailingComma<0&&(e.trailingComma=this.start),this.finishNode(o,"SpreadElement"));this.options.ecmaVersion>=6&&(o.method=!1,o.shorthand=!1,(t||e)&&(i=this.start,a=this.startLoc),t||(n=this.eat(yt.star)));var s=this.containsEsc;return this.parsePropertyName(o),!t&&!s&&this.options.ecmaVersion>=8&&!n&&this.isAsyncProp(o)?(r=!0,n=this.options.ecmaVersion>=9&&this.eat(yt.star),this.parsePropertyName(o,e)):r=!1,this.parsePropertyValue(o,t,n,r,i,a,e,s),this.finishNode(o,"Property")},le.parsePropertyValue=function(t,e,n,r,i,a,o,s){if((n||r)&&this.type===yt.colon&&this.unexpected(),this.eat(yt.colon))t.value=e?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,o),t.kind="init";else if(this.options.ecmaVersion>=6&&this.type===yt.parenL)e&&this.unexpected(),t.kind="init",t.method=!0,t.value=this.parseMethod(n,r);else if(e||s||!(this.options.ecmaVersion>=5)||t.computed||"Identifier"!==t.key.type||"get"!==t.key.name&&"set"!==t.key.name||this.type===yt.comma||this.type===yt.braceR||this.type===yt.eq)this.options.ecmaVersion>=6&&!t.computed&&"Identifier"===t.key.type?((n||r)&&this.unexpected(),this.checkUnreserved(t.key),"await"!==t.key.name||this.awaitIdentPos||(this.awaitIdentPos=i),t.kind="init",e?t.value=this.parseMaybeDefault(i,a,t.key):this.type===yt.eq&&o?(o.shorthandAssign<0&&(o.shorthandAssign=this.start),t.value=this.parseMaybeDefault(i,a,t.key)):t.value=t.key,t.shorthand=!0):this.unexpected();else{(n||r)&&this.unexpected(),t.kind=t.key.name,this.parsePropertyName(t),t.value=this.parseMethod(!1);var u="get"===t.kind?0:1;if(t.value.params.length!==u){var c=t.value.start;"get"===t.kind?this.raiseRecoverable(c,"getter should have no params"):this.raiseRecoverable(c,"setter should have exactly one param")}else"set"===t.kind&&"RestElement"===t.value.params[0].type&&this.raiseRecoverable(t.value.params[0].start,"Setter cannot use rest params")}},le.parsePropertyName=function(t){if(this.options.ecmaVersion>=6){if(this.eat(yt.bracketL))return t.computed=!0,t.key=this.parseMaybeAssign(),this.expect(yt.bracketR),t.key;t.computed=!1}return t.key=this.type===yt.num||this.type===yt.string?this.parseExprAtom():this.parseIdent("never"!==this.options.allowReserved)},le.initFunction=function(t){t.id=null,this.options.ecmaVersion>=6&&(t.generator=t.expression=!1),this.options.ecmaVersion>=8&&(t.async=!1)},le.parseMethod=function(t,e,n){var r=this.startNode(),i=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.initFunction(r),this.options.ecmaVersion>=6&&(r.generator=t),this.options.ecmaVersion>=8&&(r.async=!!e),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(Gt(e,r.generator)|Ht|(n?Wt:0)),this.expect(yt.parenL),r.params=this.parseBindingList(yt.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(r,!1,!0),this.yieldPos=i,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(r,"FunctionExpression")},le.parseArrowExpression=function(t,e,n){var r=this.yieldPos,i=this.awaitPos,a=this.awaitIdentPos;return this.enterScope(Gt(n,!1)|Bt),this.initFunction(t),this.options.ecmaVersion>=8&&(t.async=!!n),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,t.params=this.toAssignableList(e,!0),this.parseFunctionBody(t,!0,!1),this.yieldPos=r,this.awaitPos=i,this.awaitIdentPos=a,this.finishNode(t,"ArrowFunctionExpression")},le.parseFunctionBody=function(t,e,n){var r=e&&this.type!==yt.braceL,i=this.strict,a=!1;if(r)t.body=this.parseMaybeAssign(),t.expression=!0,this.checkParams(t,!1);else{var o=this.options.ecmaVersion>=7&&!this.isSimpleParamList(t.params);i&&!o||(a=this.strictDirective(this.end),a&&o&&this.raiseRecoverable(t.start,"Illegal 'use strict' directive in function with non-simple parameter list"));var s=this.labels;this.labels=[],a&&(this.strict=!0),this.checkParams(t,!i&&!a&&!e&&!n&&this.isSimpleParamList(t.params)),this.strict&&t.id&&this.checkLVal(t.id,Jt),t.body=this.parseBlock(!1,void 0,a&&!i),t.expression=!1,this.adaptDirectivePrologue(t.body.body),this.labels=s}this.exitScope()},le.isSimpleParamList=function(t){for(var e=0,n=t;e-1||i.functions.indexOf(t)>-1||i.var.indexOf(t)>-1,i.lexical.push(t),this.inModule&&i.flags&Dt&&delete this.undefinedExports[t]}else if(e===Kt){var a=this.currentScope();a.lexical.push(t)}else if(e===Yt){var o=this.currentScope();r=this.treatFunctionsAsVar?o.lexical.indexOf(t)>-1:o.lexical.indexOf(t)>-1||o.var.indexOf(t)>-1,o.functions.push(t)}else for(var s=this.scopeStack.length-1;s>=0;--s){var u=this.scopeStack[s];if(u.lexical.indexOf(t)>-1&&!(u.flags&Ut&&u.lexical[0]===t)||!this.treatFunctionsAsVarInScope(u)&&u.functions.indexOf(t)>-1){r=!0;break}if(u.var.push(t),this.inModule&&u.flags&Dt&&delete this.undefinedExports[t],u.flags&Lt)break}r&&this.raiseRecoverable(n,"Identifier '"+t+"' has already been declared")},fe.checkLocalExport=function(t){-1===this.scopeStack[0].lexical.indexOf(t.name)&&-1===this.scopeStack[0].var.indexOf(t.name)&&(this.undefinedExports[t.name]=t)},fe.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},fe.currentVarScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(e.flags&Lt)return e}},fe.currentThisScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(e.flags&Lt&&!(e.flags&Bt))return e}};var ve=function(t,e,n){this.type="",this.start=e,this.end=0,t.options.locations&&(this.loc=new Nt(t,n)),t.options.directSourceFile&&(this.sourceFile=t.options.directSourceFile),t.options.ranges&&(this.range=[e,0])},ge=Xt.prototype;function ye(t,e,n,r){return t.type=e,t.end=n,this.options.locations&&(t.loc.end=r),this.options.ranges&&(t.range[1]=n),t}ge.startNode=function(){return new ve(this,this.start,this.startLoc)},ge.startNodeAt=function(t,e){return new ve(this,t,e)},ge.finishNode=function(t,e){return ye.call(this,t,e,this.lastTokEnd,this.lastTokEndLoc)},ge.finishNodeAt=function(t,e,n,r){return ye.call(this,t,e,n,r)};var me=function(t,e,n,r,i){this.token=t,this.isExpr=!!e,this.preserveSpace=!!n,this.override=r,this.generator=!!i},be={b_stat:new me("{",!1),b_expr:new me("{",!0),b_tmpl:new me("${",!1),p_stat:new me("(",!1),p_expr:new me("(",!0),q_tmpl:new me("`",!0,!0,(function(t){return t.tryReadTemplateToken()})),f_stat:new me("function",!1),f_expr:new me("function",!0),f_expr_gen:new me("function",!0,!1,null,!0),f_gen:new me("function",!1,!1,null,!0)},_e=Xt.prototype;_e.initialContext=function(){return[be.b_stat]},_e.braceIsBlock=function(t){var e=this.curContext();return e===be.f_expr||e===be.f_stat||(t!==yt.colon||e!==be.b_stat&&e!==be.b_expr?t===yt._return||t===yt.name&&this.exprAllowed?mt.test(this.input.slice(this.lastTokEnd,this.start)):t===yt._else||t===yt.semi||t===yt.eof||t===yt.parenR||t===yt.arrow||(t===yt.braceL?e===be.b_stat:t!==yt._var&&t!==yt._const&&t!==yt.name&&!this.exprAllowed):!e.isExpr)},_e.inGeneratorContext=function(){for(var t=this.context.length-1;t>=1;t--){var e=this.context[t];if("function"===e.token)return e.generator}return!1},_e.updateContext=function(t){var e,n=this.type;n.keyword&&t===yt.dot?this.exprAllowed=!1:(e=n.updateContext)?e.call(this,t):this.exprAllowed=n.beforeExpr},yt.parenR.updateContext=yt.braceR.updateContext=function(){if(1!==this.context.length){var t=this.context.pop();t===be.b_stat&&"function"===this.curContext().token&&(t=this.context.pop()),this.exprAllowed=!t.isExpr}else this.exprAllowed=!0},yt.braceL.updateContext=function(t){this.context.push(this.braceIsBlock(t)?be.b_stat:be.b_expr),this.exprAllowed=!0},yt.dollarBraceL.updateContext=function(){this.context.push(be.b_tmpl),this.exprAllowed=!0},yt.parenL.updateContext=function(t){var e=t===yt._if||t===yt._for||t===yt._with||t===yt._while;this.context.push(e?be.p_stat:be.p_expr),this.exprAllowed=!0},yt.incDec.updateContext=function(){},yt._function.updateContext=yt._class.updateContext=function(t){!t.beforeExpr||t===yt.semi||t===yt._else||t===yt._return&&mt.test(this.input.slice(this.lastTokEnd,this.start))||(t===yt.colon||t===yt.braceL)&&this.curContext()===be.b_stat?this.context.push(be.f_stat):this.context.push(be.f_expr),this.exprAllowed=!1},yt.backQuote.updateContext=function(){this.curContext()===be.q_tmpl?this.context.pop():this.context.push(be.q_tmpl),this.exprAllowed=!1},yt.star.updateContext=function(t){if(t===yt._function){var e=this.context.length-1;this.context[e]===be.f_expr?this.context[e]=be.f_expr_gen:this.context[e]=be.f_gen}this.exprAllowed=!0},yt.name.updateContext=function(t){var e=!1;this.options.ecmaVersion>=6&&t!==yt.dot&&("of"===this.value&&!this.exprAllowed||"yield"===this.value&&this.inGeneratorContext())&&(e=!0),this.exprAllowed=e};var we="ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS",xe=we+" Extended_Pictographic",Ee=xe,Oe={9:we,10:xe,11:Ee},Se="Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu",Te="Adlam Adlm Ahom Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb",ke=Te+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",Ae=ke+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",Ce={9:Te,10:ke,11:Ae},Ne={};function Ie(t){var e=Ne[t]={binary:At(Oe[t]+" "+Se),nonBinary:{General_Category:At(Se),Script:At(Ce[t])}};e.nonBinary.Script_Extensions=e.nonBinary.Script,e.nonBinary.gc=e.nonBinary.General_Category,e.nonBinary.sc=e.nonBinary.Script,e.nonBinary.scx=e.nonBinary.Script_Extensions}Ie(9),Ie(10),Ie(11);var je=Xt.prototype,Pe=function(t){this.parser=t,this.validFlags="gim"+(t.options.ecmaVersion>=6?"uy":"")+(t.options.ecmaVersion>=9?"s":""),this.unicodeProperties=Ne[t.options.ecmaVersion>=11?11:t.options.ecmaVersion],this.source="",this.flags="",this.start=0,this.switchU=!1,this.switchN=!1,this.pos=0,this.lastIntValue=0,this.lastStringValue="",this.lastAssertionIsQuantifiable=!1,this.numCapturingParens=0,this.maxBackReference=0,this.groupNames=[],this.backReferenceNames=[]};function Re(t){return t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode(55296+(t>>10),56320+(1023&t)))}function De(t){return 36===t||t>=40&&t<=43||46===t||63===t||t>=91&&t<=94||t>=123&&t<=125}function Me(t){return ct(t,!0)||36===t||95===t}function Le(t){return lt(t,!0)||36===t||95===t||8204===t||8205===t}function Ve(t){return t>=65&&t<=90||t>=97&&t<=122}function Fe(t){return t>=0&&t<=1114111}function Be(t){return 100===t||68===t||115===t||83===t||119===t||87===t}function Ue(t){return Ve(t)||95===t}function He(t){return Ue(t)||We(t)}function We(t){return t>=48&&t<=57}function Ge(t){return t>=48&&t<=57||t>=65&&t<=70||t>=97&&t<=102}function $e(t){return t>=65&&t<=70?t-65+10:t>=97&&t<=102?t-97+10:t-48}function qe(t){return t>=48&&t<=55}Pe.prototype.reset=function(t,e,n){var r=-1!==n.indexOf("u");this.start=0|t,this.source=e+"",this.flags=n,this.switchU=r&&this.parser.options.ecmaVersion>=6,this.switchN=r&&this.parser.options.ecmaVersion>=9},Pe.prototype.raise=function(t){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+t)},Pe.prototype.at=function(t,e){void 0===e&&(e=!1);var n=this.source,r=n.length;if(t>=r)return-1;var i=n.charCodeAt(t);if(!e&&!this.switchU||i<=55295||i>=57344||t+1>=r)return i;var a=n.charCodeAt(t+1);return a>=56320&&a<=57343?(i<<10)+a-56613888:i},Pe.prototype.nextIndex=function(t,e){void 0===e&&(e=!1);var n=this.source,r=n.length;if(t>=r)return r;var i,a=n.charCodeAt(t);return!e&&!this.switchU||a<=55295||a>=57344||t+1>=r||(i=n.charCodeAt(t+1))<56320||i>57343?t+1:t+2},Pe.prototype.current=function(t){return void 0===t&&(t=!1),this.at(this.pos,t)},Pe.prototype.lookahead=function(t){return void 0===t&&(t=!1),this.at(this.nextIndex(this.pos,t),t)},Pe.prototype.advance=function(t){void 0===t&&(t=!1),this.pos=this.nextIndex(this.pos,t)},Pe.prototype.eat=function(t,e){return void 0===e&&(e=!1),this.current(e)===t&&(this.advance(e),!0)},je.validateRegExpFlags=function(t){for(var e=t.validFlags,n=t.flags,r=0;r-1&&this.raise(t.start,"Duplicate regular expression flag")}},je.validateRegExpPattern=function(t){this.regexp_pattern(t),!t.switchN&&this.options.ecmaVersion>=9&&t.groupNames.length>0&&(t.switchN=!0,this.regexp_pattern(t))},je.regexp_pattern=function(t){t.pos=0,t.lastIntValue=0,t.lastStringValue="",t.lastAssertionIsQuantifiable=!1,t.numCapturingParens=0,t.maxBackReference=0,t.groupNames.length=0,t.backReferenceNames.length=0,this.regexp_disjunction(t),t.pos!==t.source.length&&(t.eat(41)&&t.raise("Unmatched ')'"),(t.eat(93)||t.eat(125))&&t.raise("Lone quantifier brackets")),t.maxBackReference>t.numCapturingParens&&t.raise("Invalid escape");for(var e=0,n=t.backReferenceNames;e=9&&(n=t.eat(60)),t.eat(61)||t.eat(33))return this.regexp_disjunction(t),t.eat(41)||t.raise("Unterminated group"),t.lastAssertionIsQuantifiable=!n,!0}return t.pos=e,!1},je.regexp_eatQuantifier=function(t,e){return void 0===e&&(e=!1),!!this.regexp_eatQuantifierPrefix(t,e)&&(t.eat(63),!0)},je.regexp_eatQuantifierPrefix=function(t,e){return t.eat(42)||t.eat(43)||t.eat(63)||this.regexp_eatBracedQuantifier(t,e)},je.regexp_eatBracedQuantifier=function(t,e){var n=t.pos;if(t.eat(123)){var r=0,i=-1;if(this.regexp_eatDecimalDigits(t)&&(r=t.lastIntValue,t.eat(44)&&this.regexp_eatDecimalDigits(t)&&(i=t.lastIntValue),t.eat(125)))return-1!==i&&i=9?this.regexp_groupSpecifier(t):63===t.current()&&t.raise("Invalid group"),this.regexp_disjunction(t),t.eat(41))return t.numCapturingParens+=1,!0;t.raise("Unterminated group")}return!1},je.regexp_eatExtendedAtom=function(t){return t.eat(46)||this.regexp_eatReverseSolidusAtomEscape(t)||this.regexp_eatCharacterClass(t)||this.regexp_eatUncapturingGroup(t)||this.regexp_eatCapturingGroup(t)||this.regexp_eatInvalidBracedQuantifier(t)||this.regexp_eatExtendedPatternCharacter(t)},je.regexp_eatInvalidBracedQuantifier=function(t){return this.regexp_eatBracedQuantifier(t,!0)&&t.raise("Nothing to repeat"),!1},je.regexp_eatSyntaxCharacter=function(t){var e=t.current();return!!De(e)&&(t.lastIntValue=e,t.advance(),!0)},je.regexp_eatPatternCharacters=function(t){var e=t.pos,n=0;while(-1!==(n=t.current())&&!De(n))t.advance();return t.pos!==e},je.regexp_eatExtendedPatternCharacter=function(t){var e=t.current();return!(-1===e||36===e||e>=40&&e<=43||46===e||63===e||91===e||94===e||124===e)&&(t.advance(),!0)},je.regexp_groupSpecifier=function(t){if(t.eat(63)){if(this.regexp_eatGroupName(t))return-1!==t.groupNames.indexOf(t.lastStringValue)&&t.raise("Duplicate capture group name"),void t.groupNames.push(t.lastStringValue);t.raise("Invalid group")}},je.regexp_eatGroupName=function(t){if(t.lastStringValue="",t.eat(60)){if(this.regexp_eatRegExpIdentifierName(t)&&t.eat(62))return!0;t.raise("Invalid capture group name")}return!1},je.regexp_eatRegExpIdentifierName=function(t){if(t.lastStringValue="",this.regexp_eatRegExpIdentifierStart(t)){t.lastStringValue+=Re(t.lastIntValue);while(this.regexp_eatRegExpIdentifierPart(t))t.lastStringValue+=Re(t.lastIntValue);return!0}return!1},je.regexp_eatRegExpIdentifierStart=function(t){var e=t.pos,n=this.options.ecmaVersion>=11,r=t.current(n);return t.advance(n),92===r&&this.regexp_eatRegExpUnicodeEscapeSequence(t,n)&&(r=t.lastIntValue),Me(r)?(t.lastIntValue=r,!0):(t.pos=e,!1)},je.regexp_eatRegExpIdentifierPart=function(t){var e=t.pos,n=this.options.ecmaVersion>=11,r=t.current(n);return t.advance(n),92===r&&this.regexp_eatRegExpUnicodeEscapeSequence(t,n)&&(r=t.lastIntValue),Le(r)?(t.lastIntValue=r,!0):(t.pos=e,!1)},je.regexp_eatAtomEscape=function(t){return!!(this.regexp_eatBackReference(t)||this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)||t.switchN&&this.regexp_eatKGroupName(t))||(t.switchU&&(99===t.current()&&t.raise("Invalid unicode escape"),t.raise("Invalid escape")),!1)},je.regexp_eatBackReference=function(t){var e=t.pos;if(this.regexp_eatDecimalEscape(t)){var n=t.lastIntValue;if(t.switchU)return n>t.maxBackReference&&(t.maxBackReference=n),!0;if(n<=t.numCapturingParens)return!0;t.pos=e}return!1},je.regexp_eatKGroupName=function(t){if(t.eat(107)){if(this.regexp_eatGroupName(t))return t.backReferenceNames.push(t.lastStringValue),!0;t.raise("Invalid named reference")}return!1},je.regexp_eatCharacterEscape=function(t){return this.regexp_eatControlEscape(t)||this.regexp_eatCControlLetter(t)||this.regexp_eatZero(t)||this.regexp_eatHexEscapeSequence(t)||this.regexp_eatRegExpUnicodeEscapeSequence(t,!1)||!t.switchU&&this.regexp_eatLegacyOctalEscapeSequence(t)||this.regexp_eatIdentityEscape(t)},je.regexp_eatCControlLetter=function(t){var e=t.pos;if(t.eat(99)){if(this.regexp_eatControlLetter(t))return!0;t.pos=e}return!1},je.regexp_eatZero=function(t){return 48===t.current()&&!We(t.lookahead())&&(t.lastIntValue=0,t.advance(),!0)},je.regexp_eatControlEscape=function(t){var e=t.current();return 116===e?(t.lastIntValue=9,t.advance(),!0):110===e?(t.lastIntValue=10,t.advance(),!0):118===e?(t.lastIntValue=11,t.advance(),!0):102===e?(t.lastIntValue=12,t.advance(),!0):114===e&&(t.lastIntValue=13,t.advance(),!0)},je.regexp_eatControlLetter=function(t){var e=t.current();return!!Ve(e)&&(t.lastIntValue=e%32,t.advance(),!0)},je.regexp_eatRegExpUnicodeEscapeSequence=function(t,e){void 0===e&&(e=!1);var n=t.pos,r=e||t.switchU;if(t.eat(117)){if(this.regexp_eatFixedHexDigits(t,4)){var i=t.lastIntValue;if(r&&i>=55296&&i<=56319){var a=t.pos;if(t.eat(92)&&t.eat(117)&&this.regexp_eatFixedHexDigits(t,4)){var o=t.lastIntValue;if(o>=56320&&o<=57343)return t.lastIntValue=1024*(i-55296)+(o-56320)+65536,!0}t.pos=a,t.lastIntValue=i}return!0}if(r&&t.eat(123)&&this.regexp_eatHexDigits(t)&&t.eat(125)&&Fe(t.lastIntValue))return!0;r&&t.raise("Invalid unicode escape"),t.pos=n}return!1},je.regexp_eatIdentityEscape=function(t){if(t.switchU)return!!this.regexp_eatSyntaxCharacter(t)||!!t.eat(47)&&(t.lastIntValue=47,!0);var e=t.current();return!(99===e||t.switchN&&107===e)&&(t.lastIntValue=e,t.advance(),!0)},je.regexp_eatDecimalEscape=function(t){t.lastIntValue=0;var e=t.current();if(e>=49&&e<=57){do{t.lastIntValue=10*t.lastIntValue+(e-48),t.advance()}while((e=t.current())>=48&&e<=57);return!0}return!1},je.regexp_eatCharacterClassEscape=function(t){var e=t.current();if(Be(e))return t.lastIntValue=-1,t.advance(),!0;if(t.switchU&&this.options.ecmaVersion>=9&&(80===e||112===e)){if(t.lastIntValue=-1,t.advance(),t.eat(123)&&this.regexp_eatUnicodePropertyValueExpression(t)&&t.eat(125))return!0;t.raise("Invalid property name")}return!1},je.regexp_eatUnicodePropertyValueExpression=function(t){var e=t.pos;if(this.regexp_eatUnicodePropertyName(t)&&t.eat(61)){var n=t.lastStringValue;if(this.regexp_eatUnicodePropertyValue(t)){var r=t.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(t,n,r),!0}}if(t.pos=e,this.regexp_eatLoneUnicodePropertyNameOrValue(t)){var i=t.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(t,i),!0}return!1},je.regexp_validateUnicodePropertyNameAndValue=function(t,e,n){Tt(t.unicodeProperties.nonBinary,e)||t.raise("Invalid property name"),t.unicodeProperties.nonBinary[e].test(n)||t.raise("Invalid property value")},je.regexp_validateUnicodePropertyNameOrValue=function(t,e){t.unicodeProperties.binary.test(e)||t.raise("Invalid property name")},je.regexp_eatUnicodePropertyName=function(t){var e=0;t.lastStringValue="";while(Ue(e=t.current()))t.lastStringValue+=Re(e),t.advance();return""!==t.lastStringValue},je.regexp_eatUnicodePropertyValue=function(t){var e=0;t.lastStringValue="";while(He(e=t.current()))t.lastStringValue+=Re(e),t.advance();return""!==t.lastStringValue},je.regexp_eatLoneUnicodePropertyNameOrValue=function(t){return this.regexp_eatUnicodePropertyValue(t)},je.regexp_eatCharacterClass=function(t){if(t.eat(91)){if(t.eat(94),this.regexp_classRanges(t),t.eat(93))return!0;t.raise("Unterminated character class")}return!1},je.regexp_classRanges=function(t){while(this.regexp_eatClassAtom(t)){var e=t.lastIntValue;if(t.eat(45)&&this.regexp_eatClassAtom(t)){var n=t.lastIntValue;!t.switchU||-1!==e&&-1!==n||t.raise("Invalid character class"),-1!==e&&-1!==n&&e>n&&t.raise("Range out of order in character class")}}},je.regexp_eatClassAtom=function(t){var e=t.pos;if(t.eat(92)){if(this.regexp_eatClassEscape(t))return!0;if(t.switchU){var n=t.current();(99===n||qe(n))&&t.raise("Invalid class escape"),t.raise("Invalid escape")}t.pos=e}var r=t.current();return 93!==r&&(t.lastIntValue=r,t.advance(),!0)},je.regexp_eatClassEscape=function(t){var e=t.pos;if(t.eat(98))return t.lastIntValue=8,!0;if(t.switchU&&t.eat(45))return t.lastIntValue=45,!0;if(!t.switchU&&t.eat(99)){if(this.regexp_eatClassControlLetter(t))return!0;t.pos=e}return this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)},je.regexp_eatClassControlLetter=function(t){var e=t.current();return!(!We(e)&&95!==e)&&(t.lastIntValue=e%32,t.advance(),!0)},je.regexp_eatHexEscapeSequence=function(t){var e=t.pos;if(t.eat(120)){if(this.regexp_eatFixedHexDigits(t,2))return!0;t.switchU&&t.raise("Invalid escape"),t.pos=e}return!1},je.regexp_eatDecimalDigits=function(t){var e=t.pos,n=0;t.lastIntValue=0;while(We(n=t.current()))t.lastIntValue=10*t.lastIntValue+(n-48),t.advance();return t.pos!==e},je.regexp_eatHexDigits=function(t){var e=t.pos,n=0;t.lastIntValue=0;while(Ge(n=t.current()))t.lastIntValue=16*t.lastIntValue+$e(n),t.advance();return t.pos!==e},je.regexp_eatLegacyOctalEscapeSequence=function(t){if(this.regexp_eatOctalDigit(t)){var e=t.lastIntValue;if(this.regexp_eatOctalDigit(t)){var n=t.lastIntValue;e<=3&&this.regexp_eatOctalDigit(t)?t.lastIntValue=64*e+8*n+t.lastIntValue:t.lastIntValue=8*e+n}else t.lastIntValue=e;return!0}return!1},je.regexp_eatOctalDigit=function(t){var e=t.current();return qe(e)?(t.lastIntValue=e-48,t.advance(),!0):(t.lastIntValue=0,!1)},je.regexp_eatFixedHexDigits=function(t,e){var n=t.pos;t.lastIntValue=0;for(var r=0;r>10),56320+(1023&t)))}Ye.next=function(t){!t&&this.type.keyword&&this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword "+this.type.keyword),this.options.onToken&&this.options.onToken(new ze(this)),this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()},Ye.getToken=function(){return this.next(),new ze(this)},"undefined"!==typeof Symbol&&(Ye[Symbol.iterator]=function(){var t=this;return{next:function(){var e=t.getToken();return{done:e.type===yt.eof,value:e}}}}),Ye.curContext=function(){return this.context[this.context.length-1]},Ye.nextToken=function(){var t=this.curContext();return t&&t.preserveSpace||this.skipSpace(),this.start=this.pos,this.options.locations&&(this.startLoc=this.curPosition()),this.pos>=this.input.length?this.finishToken(yt.eof):t.override?t.override(this):void this.readToken(this.fullCharCodeAtPos())},Ye.readToken=function(t){return ct(t,this.options.ecmaVersion>=6)||92===t?this.readWord():this.getTokenFromCode(t)},Ye.fullCharCodeAtPos=function(){var t=this.input.charCodeAt(this.pos);if(t<=55295||t>=57344)return t;var e=this.input.charCodeAt(this.pos+1);return(t<<10)+e-56613888},Ye.skipBlockComment=function(){var t=this.options.onComment&&this.curPosition(),e=this.pos,n=this.input.indexOf("*/",this.pos+=2);if(-1===n&&this.raise(this.pos-2,"Unterminated comment"),this.pos=n+2,this.options.locations){var r;bt.lastIndex=e;while((r=bt.exec(this.input))&&r.index8&&t<14||t>=5760&&wt.test(String.fromCharCode(t))))break t;++this.pos}}},Ye.finishToken=function(t,e){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var n=this.type;this.type=t,this.value=e,this.updateContext(n)},Ye.readToken_dot=function(){var t=this.input.charCodeAt(this.pos+1);if(t>=48&&t<=57)return this.readNumber(!0);var e=this.input.charCodeAt(this.pos+2);return this.options.ecmaVersion>=6&&46===t&&46===e?(this.pos+=3,this.finishToken(yt.ellipsis)):(++this.pos,this.finishToken(yt.dot))},Ye.readToken_slash=function(){var t=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):61===t?this.finishOp(yt.assign,2):this.finishOp(yt.slash,1)},Ye.readToken_mult_modulo_exp=function(t){var e=this.input.charCodeAt(this.pos+1),n=1,r=42===t?yt.star:yt.modulo;return this.options.ecmaVersion>=7&&42===t&&42===e&&(++n,r=yt.starstar,e=this.input.charCodeAt(this.pos+2)),61===e?this.finishOp(yt.assign,n+1):this.finishOp(r,n)},Ye.readToken_pipe_amp=function(t){var e=this.input.charCodeAt(this.pos+1);if(e===t){if(this.options.ecmaVersion>=12){var n=this.input.charCodeAt(this.pos+2);if(61===n)return this.finishOp(yt.assign,3)}return this.finishOp(124===t?yt.logicalOR:yt.logicalAND,2)}return 61===e?this.finishOp(yt.assign,2):this.finishOp(124===t?yt.bitwiseOR:yt.bitwiseAND,1)},Ye.readToken_caret=function(){var t=this.input.charCodeAt(this.pos+1);return 61===t?this.finishOp(yt.assign,2):this.finishOp(yt.bitwiseXOR,1)},Ye.readToken_plus_min=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?45!==e||this.inModule||62!==this.input.charCodeAt(this.pos+2)||0!==this.lastTokEnd&&!mt.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(yt.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):61===e?this.finishOp(yt.assign,2):this.finishOp(yt.plusMin,1)},Ye.readToken_lt_gt=function(t){var e=this.input.charCodeAt(this.pos+1),n=1;return e===t?(n=62===t&&62===this.input.charCodeAt(this.pos+2)?3:2,61===this.input.charCodeAt(this.pos+n)?this.finishOp(yt.assign,n+1):this.finishOp(yt.bitShift,n)):33!==e||60!==t||this.inModule||45!==this.input.charCodeAt(this.pos+2)||45!==this.input.charCodeAt(this.pos+3)?(61===e&&(n=2),this.finishOp(yt.relational,n)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},Ye.readToken_eq_excl=function(t){var e=this.input.charCodeAt(this.pos+1);return 61===e?this.finishOp(yt.equality,61===this.input.charCodeAt(this.pos+2)?3:2):61===t&&62===e&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(yt.arrow)):this.finishOp(61===t?yt.eq:yt.prefix,1)},Ye.readToken_question=function(){var t=this.options.ecmaVersion;if(t>=11){var e=this.input.charCodeAt(this.pos+1);if(46===e){var n=this.input.charCodeAt(this.pos+2);if(n<48||n>57)return this.finishOp(yt.questionDot,2)}if(63===e){if(t>=12){var r=this.input.charCodeAt(this.pos+2);if(61===r)return this.finishOp(yt.assign,3)}return this.finishOp(yt.coalesce,2)}}return this.finishOp(yt.question,1)},Ye.getTokenFromCode=function(t){switch(t){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(yt.parenL);case 41:return++this.pos,this.finishToken(yt.parenR);case 59:return++this.pos,this.finishToken(yt.semi);case 44:return++this.pos,this.finishToken(yt.comma);case 91:return++this.pos,this.finishToken(yt.bracketL);case 93:return++this.pos,this.finishToken(yt.bracketR);case 123:return++this.pos,this.finishToken(yt.braceL);case 125:return++this.pos,this.finishToken(yt.braceR);case 58:return++this.pos,this.finishToken(yt.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(yt.backQuote);case 48:var e=this.input.charCodeAt(this.pos+1);if(120===e||88===e)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(111===e||79===e)return this.readRadixNumber(8);if(98===e||66===e)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(t);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(t);case 124:case 38:return this.readToken_pipe_amp(t);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(t);case 60:case 62:return this.readToken_lt_gt(t);case 61:case 33:return this.readToken_eq_excl(t);case 63:return this.readToken_question();case 126:return this.finishOp(yt.prefix,1)}this.raise(this.pos,"Unexpected character '"+Xe(t)+"'")},Ye.finishOp=function(t,e){var n=this.input.slice(this.pos,this.pos+e);return this.pos+=e,this.finishToken(t,n)},Ye.readRegexp=function(){for(var t,e,n=this.pos;;){this.pos>=this.input.length&&this.raise(n,"Unterminated regular expression");var r=this.input.charAt(this.pos);if(mt.test(r)&&this.raise(n,"Unterminated regular expression"),t)t=!1;else{if("["===r)e=!0;else if("]"===r&&e)e=!1;else if("/"===r&&!e)break;t="\\"===r}++this.pos}var i=this.input.slice(n,this.pos);++this.pos;var a=this.pos,o=this.readWord1();this.containsEsc&&this.unexpected(a);var s=this.regexpState||(this.regexpState=new Pe(this));s.reset(n,i,o),this.validateRegExpFlags(s),this.validateRegExpPattern(s);var u=null;try{u=new RegExp(i,o)}catch(t){}return this.finishToken(yt.regexp,{pattern:i,flags:o,value:u})},Ye.readInt=function(t,e,n){for(var r=this.options.ecmaVersion>=12&&void 0===e,i=n&&48===this.input.charCodeAt(this.pos),a=this.pos,o=0,s=0,u=0,c=null==e?1/0:e;u=97?l-97+10:l>=65?l-65+10:l>=48&&l<=57?l-48:1/0,h>=t)break;s=l,o=o*t+h}}return r&&95===s&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===a||null!=e&&this.pos-a!==e?null:o},Ye.readRadixNumber=function(t){var e=this.pos;this.pos+=2;var n=this.readInt(t);return null==n&&this.raise(this.start+2,"Expected number in radix "+t),this.options.ecmaVersion>=11&&110===this.input.charCodeAt(this.pos)?(n=Je(this.input.slice(e,this.pos)),++this.pos):ct(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(yt.num,n)},Ye.readNumber=function(t){var e=this.pos;t||null!==this.readInt(10,void 0,!0)||this.raise(e,"Invalid number");var n=this.pos-e>=2&&48===this.input.charCodeAt(e);n&&this.strict&&this.raise(e,"Invalid number");var r=this.input.charCodeAt(this.pos);if(!n&&!t&&this.options.ecmaVersion>=11&&110===r){var i=Je(this.input.slice(e,this.pos));return++this.pos,ct(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(yt.num,i)}n&&/[89]/.test(this.input.slice(e,this.pos))&&(n=!1),46!==r||n||(++this.pos,this.readInt(10),r=this.input.charCodeAt(this.pos)),69!==r&&101!==r||n||(r=this.input.charCodeAt(++this.pos),43!==r&&45!==r||++this.pos,null===this.readInt(10)&&this.raise(e,"Invalid number")),ct(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var a=Ke(this.input.slice(e,this.pos),n);return this.finishToken(yt.num,a)},Ye.readCodePoint=function(){var t,e=this.input.charCodeAt(this.pos);if(123===e){this.options.ecmaVersion<6&&this.unexpected();var n=++this.pos;t=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,t>1114111&&this.invalidStringToken(n,"Code point out of bounds")}else t=this.readHexChar(4);return t},Ye.readString=function(t){for(var e="",n=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");var r=this.input.charCodeAt(this.pos);if(r===t)break;92===r?(e+=this.input.slice(n,this.pos),e+=this.readEscapedChar(!1),n=this.pos):(_t(r,this.options.ecmaVersion>=10)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return e+=this.input.slice(n,this.pos++),this.finishToken(yt.string,e)};var Qe={};Ye.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(t){if(t!==Qe)throw t;this.readInvalidTemplateToken()}this.inTemplateElement=!1},Ye.invalidStringToken=function(t,e){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Qe;this.raise(t,e)},Ye.readTmplToken=function(){for(var t="",e=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated template");var n=this.input.charCodeAt(this.pos);if(96===n||36===n&&123===this.input.charCodeAt(this.pos+1))return this.pos!==this.start||this.type!==yt.template&&this.type!==yt.invalidTemplate?(t+=this.input.slice(e,this.pos),this.finishToken(yt.template,t)):36===n?(this.pos+=2,this.finishToken(yt.dollarBraceL)):(++this.pos,this.finishToken(yt.backQuote));if(92===n)t+=this.input.slice(e,this.pos),t+=this.readEscapedChar(!0),e=this.pos;else if(_t(n)){switch(t+=this.input.slice(e,this.pos),++this.pos,n){case 13:10===this.input.charCodeAt(this.pos)&&++this.pos;case 10:t+="\n";break;default:t+=String.fromCharCode(n);break}this.options.locations&&(++this.curLine,this.lineStart=this.pos),e=this.pos}else++this.pos}},Ye.readInvalidTemplateToken=function(){for(;this.pos=48&&e<=55){var r=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],i=parseInt(r,8);return i>255&&(r=r.slice(0,-1),i=parseInt(r,8)),this.pos+=r.length-1,e=this.input.charCodeAt(this.pos),"0"===r&&56!==e&&57!==e||!this.strict&&!t||this.invalidStringToken(this.pos-1-r.length,t?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(i)}return _t(e)?"":String.fromCharCode(e)}},Ye.readHexChar=function(t){var e=this.pos,n=this.readInt(16,t);return null===n&&this.invalidStringToken(e,"Bad character escape sequence"),n},Ye.readWord1=function(){this.containsEsc=!1;var t="",e=!0,n=this.pos,r=this.options.ecmaVersion>=6;while(this.pos1?n-1:0),i=1;it},e.getNodePosition=function(t){if(t){var e="";return t.loc?" ["+t.loc.start.line+":"+t.loc.start.column+"]"+e:""}return""},e.createClosure=function(t){var e,n=this;switch(t.type){case"BinaryExpression":e=this.binaryExpressionHandler(t);break;case"LogicalExpression":e=this.logicalExpressionHandler(t);break;case"UnaryExpression":e=this.unaryExpressionHandler(t);break;case"UpdateExpression":e=this.updateExpressionHandler(t);break;case"ObjectExpression":e=this.objectExpressionHandler(t);break;case"ArrayExpression":e=this.arrayExpressionHandler(t);break;case"CallExpression":e=this.callExpressionHandler(t);break;case"NewExpression":e=this.newExpressionHandler(t);break;case"MemberExpression":e=this.memberExpressionHandler(t);break;case"ThisExpression":e=this.thisExpressionHandler(t);break;case"SequenceExpression":e=this.sequenceExpressionHandler(t);break;case"Literal":e=this.literalHandler(t);break;case"Identifier":e=this.identifierHandler(t);break;case"AssignmentExpression":e=this.assignmentExpressionHandler(t);break;case"FunctionDeclaration":e=this.functionDeclarationHandler(t);break;case"VariableDeclaration":e=this.variableDeclarationHandler(t);break;case"BlockStatement":case"Program":e=this.programHandler(t);break;case"ExpressionStatement":e=this.expressionStatementHandler(t);break;case"EmptyStatement":e=this.emptyStatementHandler(t);break;case"ReturnStatement":e=this.returnStatementHandler(t);break;case"FunctionExpression":e=this.functionExpressionHandler(t);break;case"IfStatement":e=this.ifStatementHandler(t);break;case"ConditionalExpression":e=this.conditionalExpressionHandler(t);break;case"ForStatement":e=this.forStatementHandler(t);break;case"WhileStatement":e=this.whileStatementHandler(t);break;case"DoWhileStatement":e=this.doWhileStatementHandler(t);break;case"ForInStatement":e=this.forInStatementHandler(t);break;case"WithStatement":e=this.withStatementHandler(t);break;case"ThrowStatement":e=this.throwStatementHandler(t);break;case"TryStatement":e=this.tryStatementHandler(t);break;case"ContinueStatement":e=this.continueStatementHandler(t);break;case"BreakStatement":e=this.breakStatementHandler(t);break;case"SwitchStatement":e=this.switchStatementHandler(t);break;case"LabeledStatement":e=this.labeledStatementHandler(t);break;case"DebuggerStatement":e=this.debuggerStatementHandler(t);break;default:throw this.createInternalThrowError(gn.NodeTypeSyntaxError,t.type,t)}return function(){var r=n.options.timeout;if(r&&r>0&&n.checkTimeout())throw n.createInternalThrowError(gn.ExecutionTimeOutError,r,null);return n.lastExecNode=t,e.apply(void 0,arguments)}},e.binaryExpressionHandler=function(t){var e=this,n=this.createClosure(t.left),r=this.createClosure(t.right);return function(){var i=n(),a=r();switch(t.operator){case"==":return i==a;case"!=":return i!=a;case"===":return i===a;case"!==":return i!==a;case"<":return i":return i>a;case">=":return i>=a;case"<<":return i<>":return i>>a;case">>>":return i>>>a;case"+":return i+a;case"-":return i-a;case"*":return i*a;case"**":return Math.pow(i,a);case"/":return i/a;case"%":return i%a;case"|":return i|a;case"^":return i^a;case"&":return i&a;case"in":return i in a;case"instanceof":return i instanceof a;default:throw e.createInternalThrowError(gn.BinaryOperatorSyntaxError,t.operator,t)}}},e.logicalExpressionHandler=function(t){var e=this,n=this.createClosure(t.left),r=this.createClosure(t.right);return function(){switch(t.operator){case"||":return n()||r();case"&&":return n()&&r();default:throw e.createInternalThrowError(gn.LogicalOperatorSyntaxError,t.operator,t)}}},e.unaryExpressionHandler=function(t){var e=this;switch(t.operator){case"delete":var n=this.createObjectGetter(t.argument),r=this.createNameGetter(t.argument);return function(){var t=n(),e=r();return delete t[e]};default:var i;if("typeof"===t.operator&&"Identifier"===t.argument.type){var a=this.createObjectGetter(t.argument),o=this.createNameGetter(t.argument);i=function(){return a()[o()]}}else i=this.createClosure(t.argument);return function(){var n=i();switch(t.operator){case"-":return-n;case"+":return+n;case"!":return!n;case"~":return~n;case"void":return;case"typeof":return typeof n;default:throw e.createInternalThrowError(gn.UnaryOperatorSyntaxError,t.operator,t)}}}},e.updateExpressionHandler=function(t){var e=this,n=this.createObjectGetter(t.argument),r=this.createNameGetter(t.argument);return function(){var i=n(),a=r();switch(e.assertVariable(i,a,t),t.operator){case"++":return t.prefix?++i[a]:i[a]++;case"--":return t.prefix?--i[a]:i[a]--;default:throw e.createInternalThrowError(gn.UpdateOperatorSyntaxError,t.operator,t)}}},e.objectExpressionHandler=function(t){var e=this,n=[];function r(t){return"Identifier"===t.type?t.name:"Literal"===t.type?t.value:this.throwError(gn.ObjectStructureSyntaxError,t.type,t)}var i=Object.create(null);return t.properties.forEach((function(t){var a=t.kind,o=r(t.key);i[o]&&"init"!==a||(i[o]={}),i[o][a]=e.createClosure(t.value),n.push({key:o,property:t})})),function(){for(var t={},e=n.length,r=0;r>=":return a[o]>>=s;case">>>=":return a[o]>>>=s;case"&=":return a[o]&=s;case"^=":return a[o]^=s;case"|=":return a[o]|=s;default:throw e.createInternalThrowError(gn.AssignmentExpressionSyntaxError,t.type,t)}}},e.functionDeclarationHandler=function(t){if(t.id){var e=this.functionExpressionHandler(t);Object.defineProperty(e,"isFunctionDeclareClosure",{value:!0,writable:!1,configurable:!1,enumerable:!1}),this.funcDeclaration(t.id.name,e)}return function(){return Tn}},e.getVariableName=function(t){if("Identifier"===t.type)return t.name;throw this.createInternalThrowError(gn.VariableTypeSyntaxError,t.type,t)},e.variableDeclarationHandler=function(t){for(var e,n=this,r=[],i=0;i2&&void 0!==arguments[2]&&arguments[2],r=$n.EXPRESSION;return e?r=$n.ANONYMOUS_FUNCTION:n&&(r=$n.TRIGGERS),qn[r](t)},Yn=/^\s+|\s+$/;function Kn(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=X()(t.replace(Yn,"")),a=zn(i,n,r);return function(){var t,i=[],o=[],s={};if(s.ARGUMENTS=n,r){var u=Or(e);if(Object.keys(u).forEach((function(t){s[t]=u[t]})),u.actionPaths){s.triggers=[];var c=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;rNumber(t.params.max)?{isValid:!1,parsed:l,message:"Maximum allowed value: ".concat(t.params.max)}:null!==(a=t.params)&&void 0!==a&&a.natural&&(l<0||!Number.isInteger(l))?{isValid:!1,parsed:l,message:"Value should be a positive integer"}:{isValid:!0,parsed:l}})),Object(r["a"])(Jn,T.BOOLEAN,(function(t,e,n){var r,i;if(void 0===e||null===e)return t.params&&t.params.required?{isValid:!1,parsed:!(null===(i=t.params)||void 0===i||!i.default),message:"".concat(ar,' "boolean"')}:{isValid:!0,parsed:(null===(r=t.params)||void 0===r?void 0:r.default)||e};var a,o=!0===e||!1===e,s="true"===e||"false"===e,u=o||s,c=e;return s&&(c="false"!==e),u?{isValid:u,parsed:c}:{isValid:!1,parsed:(null===(a=t.params)||void 0===a?void 0:a.default)||!1,message:"".concat(ar,' "boolean"')}})),Object(r["a"])(Jn,T.OBJECT,(function(t,e,n){var r,i;if(void 0===e||null===e||Object(c["isString"])(e)&&0===e.trim().length)return t.params&&t.params.required?{isValid:!1,parsed:(null===(i=t.params)||void 0===i?void 0:i.default)||{},message:"".concat(ar,": Object")}:{isValid:!0,parsed:(null===(r=t.params)||void 0===r?void 0:r.default)||e};if(Object(c["isPlainObject"])(e))return er(t,e,n);try{var a,o={parsed:JSON.parse(e),isValid:!0};return Object(c["isPlainObject"])(o.parsed)?er(t,o.parsed,n):{isValid:!1,parsed:(null===(a=t.params)||void 0===a?void 0:a.default)||{},message:"".concat(ar,": Object")}}catch(e){var s;return{isValid:!1,parsed:(null===(s=t.params)||void 0===s?void 0:s.default)||{},message:"".concat(ar,": Object")}}})),Object(r["a"])(Jn,T.ARRAY,(function(t,e,n){var r,i={isValid:!1,parsed:(null===(r=t.params)||void 0===r?void 0:r.default)||[],message:"".concat(ar," Array")};if(void 0===e||null===e)return t.params&&t.params.required?(i.message="This property is required for the widget to function correctly",i):{isValid:!0,parsed:e};if(Object(c["isString"])(e))try{var a=JSON.parse(e);if(Array.isArray(a)){var o=nr(t,a,n);return o}}catch(t){return i}return Array.isArray(e)?nr(t,e,n):i})),Object(r["a"])(Jn,T.OBJECT_ARRAY,(function(t,e,n){var r,i,o={isValid:!1,parsed:(null===(r=t.params)||void 0===r?void 0:r.default)||[{}],message:"".concat(ar," Array of objects")};if(void 0===e||null===e)return null!==(i=t.params)&&void 0!==i&&i.required?o:{isValid:!0,parsed:e};if(!Object(c["isString"])(e)&&!Array.isArray(e))return o;var s=e;if(Object(c["isString"])(e))try{s=JSON.parse(e)}catch(t){return o}return Array.isArray(s)?0===s.length?o:(s.forEach((function(t,e){if(!Object(c["isPlainObject"])(t))return a(a({},o),{},{message:"Invalid object at index ".concat(e)})})),{isValid:!0,parsed:s}):o})),Object(r["a"])(Jn,T.DATE_ISO_STRING,(function(t,e,n){var r,i,a={isValid:!1,parsed:(null===(r=t.params)||void 0===r?void 0:r.default)||V()().toISOString(),message:"".concat(ar,": ISO 8601 date string")};if(void 0===e||null===e||!Object(c["isString"])(e))return null!==(i=t.params)&&void 0!==i&&i.required?a:{isValid:!0,parsed:e};if(Object(c["isString"])(e)){if(!V()(e).isValid())return a;if(e===V()(e).toISOString())return{isValid:!0,parsed:e};if(V()(e).isValid())return{isValid:!0,parsed:V()(e).toISOString()}}return a})),Object(r["a"])(Jn,T.FUNCTION,(function(t,e,n){var r,i,a={isValid:!1,parsed:void 0,message:"Failed to validate"};if(null!==(r=t.params)&&void 0!==r&&r.fnString&&Object(c["isString"])(null===(i=t.params)||void 0===i?void 0:i.fnString))try{var o=Kn(t.params.fnString,{},[e,n,l.a,V.a]),s=o.result;return s}catch(t){console.error("Validation function error: ",{e:t})}return a})),Object(r["a"])(Jn,T.IMAGE_URL,(function(t,e,n){var r,i={isValid:!1,parsed:(null===(r=t.params)||void 0===r?void 0:r.default)||"",message:"".concat(ar,": base64 string or data uri or URL")},a=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,o=/^data:image\/.*;base64/,s=/(http(s?):)([/|.|\w|\s|-])*\.(?:jpeg|jpg|gif|png)??(?:&?[^=&]*=[^=&]*)*/;if(void 0===e||null===e||Object(c["isString"])(e)&&0===e.trim().length)return t.params&&t.params.required?i:{isValid:!0,parsed:e};if(Object(c["isString"])(e)){if(s.test(e.trim()))return{isValid:!0,parsed:e.trim()};if(o.test(e))return{isValid:!0,parsed:e};if(a.test(e)&&btoa(atob(e))===e)return{isValid:!0,parsed:"data:image/png;base64,".concat(e)}}return i})),Object(r["a"])(Jn,T.SAFE_URL,(function(t,e){var n,r={isValid:!1,parsed:(null===t||void 0===t||null===(n=t.params)||void 0===n?void 0:n.default)||"",message:"".concat(ar,": URL")};return"string"===typeof e&&tr(e)?{isValid:!0,parsed:e}:r})),Jn),sr=/^(.*)(\..*|\[.*\])$/;(function(t){t["NEW"]="NEW",t["DELETE"]="DELETE",t["EDIT"]="EDIT",t["NOOP"]="NOOP"})(rr||(rr={}));var ur=function(t){Object(z["a"])(n,t);var e=Object(Y["a"])(n);function n(){return Object(o["a"])(this,n),e.apply(this,arguments)}return n}(Object(K["a"])(Error)),cr=function(t){var e="";return t.forEach((function(t){lr(t)?e=e+"["+t+"]":(0!==e.length&&(e+="."),e+=t)})),e};function lr(t){return Number.isInteger(t)||l.a.isString(t)&&/^\d+$/.test(t)}function hr(t){var e=t.indexOf(".");if(-1===e)return{entityName:t,propertyPath:""};var n=t.substring(0,e),r=t.substring(e+1);return{entityName:n,propertyPath:r}}var pr=function t(e){var n={payload:{propertyPath:"",value:""},event:rr.NOOP};if(!e.path)return n;var r=cr(e.path);switch(e.kind){case"N":n.event=rr.NEW,n.payload={propertyPath:r};break;case"D":n.event=rr.DELETE,n.payload={propertyPath:r};break;case"E":var i="string"===typeof e.rhs&&Nr(e.rhs),o="string"===typeof e.lhs&&Nr(e.lhs);i||o?(n.event=rr.EDIT,n.payload={propertyPath:r,value:e.rhs}):void 0===e.lhs||void 0===e.rhs?(void 0===e.lhs&&Ar(e.rhs)&&(n.event=rr.NEW,n.payload={propertyPath:r}),void 0===e.rhs&&Ar(e.lhs)&&(n.event=rr.DELETE,n.payload={propertyPath:r})):Ar(e.lhs)&&!Ar(e.rhs)?n=Object.keys(e.lhs).map((function(t){var e="".concat(r,".").concat(t);return{event:rr.DELETE,payload:{propertyPath:e}}})):!Ar(e.lhs)&&Ar(e.rhs)&&(n=Object.keys(e.rhs).map((function(t){var e="".concat(r,".").concat(t);return{event:rr.NEW,payload:{propertyPath:e}}})));break;case"A":return t(a(a({},e.item),{},{path:[].concat(Object(R["a"])(e.path),[e.index])}));default:break}return n},fr=function(t,e){var n=new Set,r=Object.keys(e);return t.forEach((function(t){n.add(t),r.filter((function(e){return Ur(t,e)})).forEach((function(t){e[t].forEach((function(t){n.add(t)}))}))})),n};function dr(t){return"object"===Object(q["a"])(t)&&"ENTITY_TYPE"in t&&t.ENTITY_TYPE===Yr.WIDGET}function vr(t){return"object"===Object(q["a"])(t)&&"ENTITY_TYPE"in t&&t.ENTITY_TYPE===Yr.ACTION}var gr=function(t){return l.a.isFunction(t)?"Function call":l.a.isObject(t)?JSON.parse(JSON.stringify(t,(function(t,e){return"bigint"===typeof e?e.toString():e}))):t},yr=function(t){return Object.keys(t).forEach((function(e){t=mr(t,e),t[e].forEach((function(e){t=mr(t,e)}))})),t},mr=function(t,e){var n,r=t,i=e;while(null!==(n=i.match(sr))){var a=n[1],o=new Set(r[a]||[]);o.add(i),r[a]=Array.from(o),i=a}return r},br=function(t){var e=new Set;return t.forEach((function(t){var n=t.match(sr);null!==n&&e.add(n[1])})),Array.from(e)};function _r(t,e,n){return t?ir(t,e,n):{isValid:!0,parsed:e}}function wr(t){return Object.keys(t).reduce((function(t,e){var n=t[e];if(!dr(n))return t;var i=a({},n);return Object.entries(n.validationPaths).forEach((function(r){var a=Object(u["a"])(r,2),o=a[0],s=a[1],c=l.a.get(n,o),h=_r(s,c,n),p=h.isValid,f=h.message,d=h.parsed,v=h.transformed;l.a.set(i,o,d);var g=p?d:l.a.isUndefined(v)?c:v,y=gr(g);l.a.set(i,zr("".concat(e,".").concat(o),!1),y),p||kr([{errorType:Dr.VALIDATION,errorMessage:f||"",severity:$.ERROR,raw:c}],t,qr("".concat(e,".").concat(o),!1))})),a(a({},t),{},Object(r["a"])({},e,i))}),t)}var xr=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(n&&(r[n]=!0),Array.isArray(e))for(var i=0;i2&&void 0!==arguments[2]?arguments[2]:"";return{type:"RUN_ACTION",payload:{actionId:this.actionId,onSuccess:t?"{{".concat(t.toString(),"}}"):"",onError:e?"{{".concat(e.toString(),"}}"):"",params:n}}};l.a.set(e,"".concat(t,".run"),r),e.actionPaths&&e.actionPaths.push("".concat(t,".run"))}})),e.navigateTo=function(t,e,n){return{type:"NAVIGATE_TO",payload:{pageNameOrUrl:t,params:e,target:n}}},e.actionPaths.push("navigateTo"),e.showAlert=function(t,e){return{type:"SHOW_ALERT",payload:{message:t,style:e}}},e.actionPaths.push("showAlert"),e.showModal=function(t){return{type:"SHOW_MODAL_BY_NAME",payload:{modalName:t}}},e.actionPaths.push("showModal"),e.closeModal=function(t){return{type:"CLOSE_MODAL",payload:{modalName:t}}},e.actionPaths.push("closeModal"),e.storeValue=function(t,e){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return{type:"STORE_VALUE",payload:{key:t,value:e,persist:n}}},e.actionPaths.push("storeValue"),e.download=function(t,e,n){return{type:"DOWNLOAD",payload:{data:t,name:e,type:n}}},e.actionPaths.push("download"),e.copyToClipboard=function(t,e){return{type:"COPY_TO_CLIPBOARD",payload:{data:t,options:{debug:null===e||void 0===e?void 0:e.debug,format:null===e||void 0===e?void 0:e.format}}}},e.actionPaths.push("copyToClipboard"),e.resetWidget=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return{type:"RESET_WIDGET_META_RECURSIVE_BY_NAME",payload:{widgetName:t,resetChildren:e}}},e.actionPaths.push("resetWidget"),e};function Sr(t,e){return Object.keys(t).reduce((function(t,n){var i=t[n];if(!dr(i))return t;var o=a({},i);return Object.entries(i.validationPaths).forEach((function(t){var e=Object(u["a"])(t,2),n=e[0],r=e[1],a=l.a.get(i,n),s=_r(r,a,i),c=s.parsed;l.a.set(o,n,c)})),Object.keys(e[i.type].derivedProperties).forEach((function(t){l.a.set(o,t,void 0)})),a(a({},t),{},Object(r["a"])({},n,o))}),t)}var Tr,kr=function(t,e,n){var r=hr(n),i=r.entityName,a=r.propertyPath,o=l.a.get(e,"".concat(i,".logBlackList"),{});if(a&&!(a in o)){var s=l.a.get(e,"".concat(i,".").concat(Wr,"['").concat(a,"']"),[]);l.a.set(e,"".concat(i,".").concat(Wr,"['").concat(a,"']"),s.concat(t))}return e},Ar=function(t){return"[object Object]"===Object.prototype.toString.call(t)},Cr=function(t,e){var n=l.a.toPath(e),r=Object(U["a"])(n),i=r[0],a=r.slice(1);if(i===e)return!1;if(!(i in t))return!1;var o=t[i];if(!vr(o)&&!dr(o))return!1;var s=cr(a);return s in o.bindingPaths},Nr=function(t){return D.test(t)};function Ir(t){var e=[],n=t.indexOf("{{");if(-1===n)return[t];var r=t.substring(0,n);r&&e.push(r);for(var i=t.substring(n,t.length),a=0,o=0;o<=i.length-1;o++){var s=i[o],u=i[o-1];if("{"===s)a++;else if("}"===s&&(a--,"}"===u&&0===a&&(e.push(i.substring(0,o+1)),i=i.substring(o+1,i.length),i))){e=e.concat(Ir(i));break}}return 0!==a&&""!==t?[t]:e}var jr,Pr,Rr=function(t){if(!t||!l.a.isString(t))return{stringSegments:[],jsSnippets:[]};var e=t.trim(),n=Ir(e),r=n.map((function(t){var e=t.length,n=Nr(t);return n?t.substring(2,e-2):""}));return{stringSegments:n,jsSnippets:r}};(function(t){t["CYCLICAL_DEPENDENCY_ERROR"]="CYCLICAL_DEPENDENCY_ERROR",t["EVAL_PROPERTY_ERROR"]="EVAL_PROPERTY_ERROR",t["EVAL_TREE_ERROR"]="EVAL_TREE_ERROR",t["UNKNOWN_ERROR"]="UNKNOWN_ERROR",t["BAD_UNEVAL_TREE_ERROR"]="BAD_UNEVAL_TREE_ERROR",t["EVAL_TRIGGER_ERROR"]="EVAL_TRIGGER_ERROR"})(jr||(jr={})),function(t){t["EVAL_TREE"]="EVAL_TREE",t["EVAL_ACTION_BINDINGS"]="EVAL_ACTION_BINDINGS",t["EVAL_TRIGGER"]="EVAL_TRIGGER",t["CLEAR_PROPERTY_CACHE"]="CLEAR_PROPERTY_CACHE",t["CLEAR_PROPERTY_CACHE_OF_WIDGET"]="CLEAR_PROPERTY_CACHE_OF_WIDGET",t["CLEAR_CACHE"]="CLEAR_CACHE",t["VALIDATE_PROPERTY"]="VALIDATE_PROPERTY"}(Pr||(Pr={}));var Dr,Mr=[{accessor:"_",lib:l.a,version:c["VERSION"],docsURL:"https://lodash.com/docs/".concat(c["VERSION"]),displayName:"lodash"},{accessor:"dayjs",lib:V.a,version:"1.10.7",docsURL:"https://dayjs.gitee.io/docs/zh-CN/parse/parse",displayName:"dayjs"},{accessor:"xmlParser",lib:B.a,version:"3.17.5",docsURL:"https://github.com/NaturalIntelligence/fast-xml-parser",displayName:"xmlParser"}],Lr=function(t){return t&&t.dynamicBindingPathList&&Array.isArray(t.dynamicBindingPathList)?Object(R["a"])(t.dynamicBindingPathList):[]},Vr=function(t,e){return!!(t&&t.dynamicBindingPathList&&Array.isArray(t.dynamicBindingPathList))&&void 0!==l.a.find(t.dynamicBindingPathList,{key:e})},Fr=function(t,e){return!!(t&&t.dynamicTriggerPathList&&Array.isArray(t.dynamicTriggerPathList))&&void 0!==l.a.find(t.dynamicTriggerPathList,{key:e})},Br=["setTimeout","fetch","setInterval","Promise","setImmediate","XMLHttpRequest","importScripts","Navigator"],Ur=function(t,e){return t===e||e.startsWith("".concat(t,"."))||e.startsWith("".concat(t,"["))},Hr="__evaluation__",Wr="".concat(Hr,".errors"),Gr="".concat(Hr,".evaluatedValues"),$r=function(t,e){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=hr(t),i=r.entityName,a=r.propertyPath,o="".concat(e,".['").concat(a,"']");return n?"".concat(i,".").concat(o):o},qr=function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return $r(t,Wr,e)},zr=function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return $r(t,Gr,e)};(function(t){t["VALIDATION"]="VALIDATION",t["PARSE"]="PARSE",t["LINT"]="LINT"})(Dr||(Dr={}));var Yr,Kr;Tr={},Object(r["a"])(Tr,Dr.VALIDATION,(function(t){return"The value at ".concat(t," is invalid")})),Object(r["a"])(Tr,Dr.PARSE,(function(){return"Could not parse the binding"})),Object(r["a"])(Tr,Dr.LINT,(function(){return"Errors found while evaluating"}));(function(t){t["ACTION"]="ACTION",t["WIDGET"]="WIDGET",t["APPSMITH"]="APPSMITH"})(Yr||(Yr={})),function(t){t["TEMPLATE"]="TEMPLATE",t["PARAMETER"]="PARAMETER",t["SMART_SUBSTITUTE"]="SMART_SUBSTITUTE"}(Kr||(Kr={}));var Jr,Xr=n(28),Qr=n(37),Zr=n.n(Qr),ti=n(38),ei=n.n(ti);(function(t){t["URL"]="URL",t["STRING"]="STRING",t["NUMBER"]="NUMBER",t["BOOLEAN"]="BOOLEAN",t["OBJECT"]="OBJECT",t["ARRAY"]="ARRAY",t["FUNCTION"]="FUNCTION",t["UNDEFINED"]="UNDEFINED",t["NULL"]="NULL",t["UNKNOWN"]="UNKNOWN"})(Jr||(Jr={}));var ni=function(t){return l.a.isString(t)?Jr.STRING:l.a.isNumber(t)?Jr.NUMBER:l.a.isBoolean(t)?Jr.BOOLEAN:Array.isArray(t)?Jr.ARRAY:l.a.isFunction(t)?Jr.FUNCTION:l.a.isObject(t)?Jr.OBJECT:l.a.isUndefined(t)?Jr.UNDEFINED:l.a.isNull(t)?Jr.NULL:Jr.UNKNOWN};var ri=function(t,e,n){var r=t.replace(M,(function(t,e){return e})),i=[],a=[];return e.forEach((function(t,e){Nr(t)&&(i.push(t),a.push(n[e]))})),{binding:r,subBindings:i,subValues:a}},ii=function(t,e,n){var r=ri(t,e,n),i=r.binding,a=r.subBindings,o=r.subValues,s=i;return a.forEach((function(t,e){var n=o[e];switch(ni(n)){case Jr.NUMBER:case Jr.BOOLEAN:case Jr.NULL:case Jr.UNDEFINED:s=s.replace(t,"".concat(n));break;case Jr.STRING:s=s.replace(t,"".concat(JSON.stringify(n)));break;case Jr.ARRAY:case Jr.OBJECT:s=s.replace(t,JSON.stringify(n,null,2));break}})),s},ai=function(t,e,n){var r=ri(t,e,n),i=r.binding,a=r.subBindings,o=r.subValues,s=i,u={};return a.forEach((function(t,e){var n="$".concat(e+1);s=s.replace(t,n),u[n]="object"===Object(q["a"])(o[e])?JSON.stringify(o[e],null,2):o[e]})),{value:s,parameters:u}},oi=function(t,e,n){var r=t;return e.forEach((function(t,e){var i=n[e];(Array.isArray(i)||l.a.isObject(i))&&(i=JSON.stringify(i));try{"string"===typeof i&&JSON.parse(i)&&(i=i.replace(/\\([\s\S])|(")/g,"\\$1$2"))}catch(t){}r=r.replace(t,"".concat(i))})),r},si=function(t,e,n,r){switch(r){case Kr.TEMPLATE:return oi(t,e,n);case Kr.SMART_SUBSTITUTE:return ii(t,e,n);case Kr.PARAMETER:return ai(t,e,n)}},ui=Date,ci=function(){function t(e){Object(o["a"])(this,t),Object(r["a"])(this,"dependencyMap",{}),Object(r["a"])(this,"sortedDependencies",[]),Object(r["a"])(this,"inverseDependencyMap",{}),Object(r["a"])(this,"widgetConfigMap",{}),Object(r["a"])(this,"evalTree",{}),Object(r["a"])(this,"allKeys",{}),Object(r["a"])(this,"oldUnEvalTree",{}),Object(r["a"])(this,"errors",[]),Object(r["a"])(this,"parsedValueCache",new Map),Object(r["a"])(this,"logs",[]),this.widgetConfigMap=e}return Object(s["a"])(t,[{key:"createFirstTree",value:function(t){var e=ui.now(),n=ui.now();this.dependencyMap=this.createDependencyMap(t);var r=ui.now(),i=ui.now();this.sortedDependencies=this.sortDependencies(this.dependencyMap);var a=ui.now();this.inverseDependencyMap=this.getInverseDependencyTree();var o=ui.now(),s=this.evaluateTree(t,this.sortedDependencies),u=ui.now(),c=ui.now();this.evalTree=wr(s);var l=ui.now();this.oldUnEvalTree=t;var h=ui.now(),p={total:(h-e).toFixed(2),createDependencies:(r-n).toFixed(2),sortDependencies:(a-i).toFixed(2),evaluate:(u-o).toFixed(2),validate:(l-c).toFixed(2),dependencies:{map:JSON.parse(JSON.stringify(this.dependencyMap)),inverseMap:JSON.parse(JSON.stringify(this.inverseDependencyMap)),sortedList:JSON.parse(JSON.stringify(this.sortedDependencies))}};return this.logs.push({timeTakenForFirstTree:p}),this.evalTree}},{key:"updateDataTree",value:function(t){var e=this,n=l.a.cloneDeep(this.evalTree),r=ui.now(),i=ui.now(),a=Object(Xr["diff"])(this.oldUnEvalTree,t)||[];if(0===a.length)return{updates:[],evaluationOrder:[],unEvalUpdates:[]};var o=l.a.flatten(a.map(pr));this.logs.push({differences:a,translatedDiffs:o});var s=ui.now(),u=ui.now(),c=this.updateDependencyMap(o,t),h=c.dependenciesOfRemovedPaths,p=c.removedPaths,f=ui.now(),d=ui.now(),v=this.calculateSubTreeSortOrder(a,h,p,t),g=ui.now(),y=ui.now(),m=v.filter((function(n){if(Cr(t,n)){var r=l.a.get(t,n);return l.a.set(e.evalTree,n,r),!0}return!1}));this.logs.push({sortedDependencies:this.sortedDependencies,inverse:this.inverseDependencyMap,updatedDependencyMap:this.dependencyMap}),p.forEach((function(t){l.a.unset(e.evalTree,t)}));var b=this.evaluateTree(this.evalTree,m),_=ui.now(),w=ui.now(),x=Object(Xr["diff"])(n,b),E=ui.now(),O=ui.now();this.oldUnEvalTree=t,this.evalTree=b;var S={total:(O-r).toFixed(2),findDifferences:(s-i).toFixed(2),findEvalDifferences:(E-w).toFixed(2),updateDependencies:(f-u).toFixed(2),calculateSortOrder:(g-d).toFixed(2),evaluate:(_-y).toFixed(2)};return this.logs.push({timeTakenForSubTreeEval:S}),{updates:x||[],evaluationOrder:m,unEvalUpdates:o}}},{key:"getCompleteSortOrder",value:function(t,e){var n,r=[],i=!0,a=t;while(i)n=this.getEvaluationSortOrder(a,e),r=[].concat(Object(R["a"])(r),Object(R["a"])(n)),a=br(n),i=a.length>0;var o=new Set(r),s=[];this.sortedDependencies.forEach((function(t){o.has(t)&&(s.push(t),o.delete(t))}));var u=[].concat(Object(R["a"])(Array.from(o)),s),c=[];return u.forEach((function(t){var e=t.lastIndexOf(".");-1!==e&&c.push(t)})),c}},{key:"getEvaluationSortOrder",value:function(t,e){var n=Object(R["a"])(t),r=0;while(r3&&void 0!==arguments[3]&&arguments[3];try{return Kn(t,e,n,r)}catch(e){return{result:void 0,triggers:[],errors:[{errorType:Dr.PARSE,raw:t,severity:$.ERROR,errorMessage:e.message}]}}}},{key:"validateAndParseWidgetProperty",value:function(t,e,n,r,i,a){var o=hr(t),s=o.propertyPath,u=r;if(Fr(e,s)){var c=this.getDynamicValue(i,n,Kr.TEMPLATE,!0,void 0,t),h=c.triggers;u=h}var p=e.validationPaths[s],f=_r(p,u,e),d=f.isValid,v=f.message,g=f.parsed,y=f.transformed,m=d?g:l.a.isUndefined(y)?r:y,b=gr(m);if(l.a.set(e,zr(t,!1),b),d||kr([{raw:i,errorMessage:v||"",errorType:Dr.VALIDATION,severity:$.ERROR}],n,t),Fr(e,s))return i;var _=this.getParsedValueCache(t);return ei()(_.value,g)&&!a||this.parsedValueCache.set(t,{value:g,version:Date.now()}),g}},{key:"overwriteDefaultDependentProps",value:function(t,e,n,r){var i=this.getParsedValueCache("".concat(r.widgetName,".").concat(t)),a=this.getParsedValueCache(n);return void 0===e||a.version1){if(i=cr(r),e.hasOwnProperty(i))return void n.push(i);r.pop()}}})),l.a.uniq(n)},hi=function(t){return D.test(t)};function pi(t){return!!l.a.isObject(t)&&"ENTITY_TYPE"in t}function fi(t){return pi(t)&&t.ENTITY_TYPE===Yr.WIDGET}function di(t){return pi(t)&&t.ENTITY_TYPE===Yr.ACTION}var vi,gi=worker,yi=Date;function mi(t){return function(e){var n=yi.now(),r=e.method,i=e.requestData,a=e.requestId,o=t(r,i),s=yi.now();gi.postMessage({requestId:a,responseData:o,timeTaken:(s-n).toFixed(2)})}}gi.onMessage(mi((function(t,e){switch(t){case Pr.EVAL_TREE:var n=e.unevalTree,r=e.widgetTypeConfigMap,i=n,o=[],s=[],u={},c=[],l=[],h=[];try{if(vi){i={};var p=vi.updateDataTree(n);c=JSON.parse(JSON.stringify(p.updates)),l=p.evaluationOrder,h=p.unEvalUpdates}else vi=new ci(r),i=vi.createFirstTree(n),l=vi.sortedDependencies,i=i&&JSON.parse(JSON.stringify(i));u=vi.inverseDependencyMap,o=vi.errors,vi.clearErrors(),s=vi.logs,vi.clearLogs()}catch(t){void 0!==vi&&(o=vi.errors,s=vi.logs),t instanceof ur||(o.push({type:jr.UNKNOWN_ERROR,message:t.message}),console.error(t)),i=Sr(n,r),vi=void 0}return{dataTree:i,dependencies:u,errors:o,evaluationOrder:l,logs:s,updates:c,unEvalUpdates:h};case Pr.EVAL_ACTION_BINDINGS:var f=e.bindings,d=e.executionParams;if(!vi)return{values:void 0,errors:[]};var v=vi.evaluateActionBindings(f,d),g=gr(v),y=vi.errors;return vi.clearErrors(),{values:g,errors:y};case Pr.EVAL_TRIGGER:var m=e.callbackData,b=e.dataTree,_=e.dynamicTrigger;if(!vi)return{triggers:[],errors:[]};vi.updateDataTree(b);var w=vi.evalTree,x=vi.getDynamicValue(_,w,Kr.TEMPLATE,!0,m),E=x.errors,O=x.triggers,S=gr(O),T=E.filter((function(t){return t.errorType===Dr.PARSE})).map((function(t){return a(a({},t),{},{message:t.errorMessage,type:jr.EVAL_TRIGGER_ERROR})}));return{triggers:S,errors:T};case Pr.CLEAR_CACHE:return vi=void 0,!0;case Pr.CLEAR_PROPERTY_CACHE:var k=e.propertyPath;return!vi||(vi.clearPropertyCache(k),!0);case Pr.CLEAR_PROPERTY_CACHE_OF_WIDGET:var A=e.widgetName;return!vi||(vi.clearPropertyCacheOfWidget(A),!0);case Pr.VALIDATE_PROPERTY:var C=e.props,N=e.validation,I=e.value;return gr(_r(N,I,C));default:console.error("Action not registered on worker",t)}})))}]); \ No newline at end of file diff --git a/app/taro/src/workers/DataTreeEvaluator.ts b/app/taro/src/workers/DataTreeEvaluator.ts new file mode 100644 index 0000000000..4a135e303d --- /dev/null +++ b/app/taro/src/workers/DataTreeEvaluator.ts @@ -0,0 +1,1209 @@ +import { + DependencyMap, + EvalError, + EvalErrorTypes, + getDynamicBindings, + getEntityDynamicBindingPathList, + getEvalErrorPath, + getEvalValuePath, + isChildPropertyPath, + isPathADynamicBinding, + isPathADynamicTrigger, + PropertyEvaluationErrorType, +} from "utils/DynamicBindingUtils"; +import { WidgetTypeConfigMap } from "utils/WidgetFactory"; +import { + DataTree, + DataTreeAction, + DataTreeEntity, + DataTreeObjectEntity, + DataTreeWidget, + ENTITY_TYPE, + EvaluationSubstitutionType, +} from "entities/DataTree/dataTreeFactory"; +import { + addDependantsOfNestedPropertyPaths, + addErrorToEntityProperty, + convertPathToString, + CrashingError, + DataTreeDiff, + DataTreeDiffEvent, + getAllPaths, + getEntityNameAndPropertyPath, + getImmediateParentsOfPropertyPaths, + getValidatedTree, + makeParentsDependOnChildren, + removeFunctions, + translateDiffEventToDataTreeDiffEvent, + trimDependantChangePaths, + validateWidgetProperty, + isDynamicLeaf, +} from "workers/evaluationUtils"; +import _ from "lodash"; +import { applyChange, Diff, diff } from "deep-diff"; +import toposort from "toposort"; +import equal from "fast-deep-equal/es6"; +import { + EXECUTION_PARAM_KEY, + EXECUTION_PARAM_REFERENCE_REGEX, +} from "constants/AppsmithActionConstants/ActionConstants"; +import { DATA_BIND_REGEX } from "constants/BindingsConstants"; +import evaluate, { EvalResult } from "workers/evaluate"; +import { substituteDynamicBindingWithValues } from "workers/evaluationSubstitution"; +import { Severity } from "entities/AppsmithConsole"; + +// polyfill +const performance = Date; + +export default class DataTreeEvaluator { + dependencyMap: DependencyMap = {}; + sortedDependencies: Array = []; + inverseDependencyMap: DependencyMap = {}; + widgetConfigMap: WidgetTypeConfigMap = {}; + evalTree: DataTree = {}; + allKeys: Record = {}; + oldUnEvalTree: DataTree = {}; + errors: EvalError[] = []; + parsedValueCache: Map< + string, + { + value: any; + version: number; + } + > = new Map(); + logs: any[] = []; + + constructor(widgetConfigMap: WidgetTypeConfigMap) { + this.widgetConfigMap = widgetConfigMap; + } + + createFirstTree(unEvalTree: DataTree): DataTree { + const totalStart = performance.now(); + // Create dependency map + const createDependencyStart = performance.now(); + this.dependencyMap = this.createDependencyMap(unEvalTree); + const createDependencyEnd = performance.now(); + // Sort + const sortDependenciesStart = performance.now(); + this.sortedDependencies = this.sortDependencies(this.dependencyMap); + const sortDependenciesEnd = performance.now(); + // Inverse + this.inverseDependencyMap = this.getInverseDependencyTree(); + // Evaluate + const evaluateStart = performance.now(); + const evaluatedTree = this.evaluateTree( + unEvalTree, + this.sortedDependencies, + ); + const evaluateEnd = performance.now(); + // Validate Widgets + const validateStart = performance.now(); + this.evalTree = getValidatedTree(evaluatedTree); + const validateEnd = performance.now(); + + this.oldUnEvalTree = unEvalTree; + const totalEnd = performance.now(); + const timeTakenForFirstTree = { + total: (totalEnd - totalStart).toFixed(2), + createDependencies: (createDependencyEnd - createDependencyStart).toFixed( + 2, + ), + sortDependencies: (sortDependenciesEnd - sortDependenciesStart).toFixed( + 2, + ), + evaluate: (evaluateEnd - evaluateStart).toFixed(2), + validate: (validateEnd - validateStart).toFixed(2), + dependencies: { + map: JSON.parse(JSON.stringify(this.dependencyMap)), + inverseMap: JSON.parse(JSON.stringify(this.inverseDependencyMap)), + sortedList: JSON.parse(JSON.stringify(this.sortedDependencies)), + }, + }; + this.logs.push({ timeTakenForFirstTree }); + return this.evalTree; + } + + updateDataTree( + unEvalTree: DataTree, + ): { + updates: Diff[]; + evaluationOrder: string[]; + unEvalUpdates: DataTreeDiff[]; + } { + const oldEvalTree = _.cloneDeep(this.evalTree); + const totalStart = performance.now(); + // Calculate diff + const diffCheckTimeStart = performance.now(); + const differences = diff(this.oldUnEvalTree, unEvalTree) || []; + // Since eval tree is listening to possible events that dont cause differences + // We want to check if no diffs are present and bail out early + if (differences.length === 0) { + return { + updates: [], + evaluationOrder: [], + unEvalUpdates: [], + }; + } + const translatedDiffs = _.flatten( + differences.map(translateDiffEventToDataTreeDiffEvent), + ); + this.logs.push({ differences, translatedDiffs }); + const diffCheckTimeStop = performance.now(); + // Check if dependencies have changed + const updateDependenciesStart = performance.now(); + + // Find all the paths that have changed as part of the difference and update the + // global dependency map if an existing dynamic binding has now become legal + const { + dependenciesOfRemovedPaths, + removedPaths, + } = this.updateDependencyMap(translatedDiffs, unEvalTree); + const updateDependenciesStop = performance.now(); + + const calculateSortOrderStart = performance.now(); + + const subTreeSortOrder: string[] = this.calculateSubTreeSortOrder( + differences, + dependenciesOfRemovedPaths, + removedPaths, + unEvalTree, + ); + + const calculateSortOrderStop = performance.now(); + + // Evaluate + const evalStart = performance.now(); + + // Remove anything from the sort order that is not a dynamic leaf since only those need evaluation + const evaluationOrder = subTreeSortOrder.filter((propertyPath) => { + // We are setting all values from our uneval tree to the old eval tree we have + // So that the actual uneval value can be evaluated + if (isDynamicLeaf(unEvalTree, propertyPath)) { + const unEvalPropValue = _.get(unEvalTree, propertyPath); + _.set(this.evalTree, propertyPath, unEvalPropValue); + return true; + } + return false; + }); + this.logs.push({ + sortedDependencies: this.sortedDependencies, + inverse: this.inverseDependencyMap, + updatedDependencyMap: this.dependencyMap, + }); + + // Remove any deleted paths from the eval tree + removedPaths.forEach((removedPath) => { + _.unset(this.evalTree, removedPath); + }); + const newEvalTree = this.evaluateTree(this.evalTree, evaluationOrder); + const evalStop = performance.now(); + + const evalTreeDiffsStart = performance.now(); + + const evaluationChanges = diff(oldEvalTree, newEvalTree); + + const evalTreeDiffsStop = performance.now(); + + const totalEnd = performance.now(); + // TODO: For some reason we are passing some reference which are getting mutated. + // Need to check why big api responses are getting split between two eval runs + this.oldUnEvalTree = unEvalTree; + this.evalTree = newEvalTree; + const timeTakenForSubTreeEval = { + total: (totalEnd - totalStart).toFixed(2), + findDifferences: (diffCheckTimeStop - diffCheckTimeStart).toFixed(2), + findEvalDifferences: (evalTreeDiffsStop - evalTreeDiffsStart).toFixed(2), + updateDependencies: ( + updateDependenciesStop - updateDependenciesStart + ).toFixed(2), + calculateSortOrder: ( + calculateSortOrderStop - calculateSortOrderStart + ).toFixed(2), + evaluate: (evalStop - evalStart).toFixed(2), + }; + this.logs.push({ timeTakenForSubTreeEval }); + return { + updates: evaluationChanges || [], + evaluationOrder, + unEvalUpdates: translatedDiffs, + }; + } + + getCompleteSortOrder( + changes: Array, + inverseMap: DependencyMap, + ): Array { + let finalSortOrder: Array = []; + let computeSortOrder = true; + // Initialize parents with the current sent of property paths that need to be evaluated + let parents = changes; + let subSortOrderArray: Array; + while (computeSortOrder) { + // Get all the nodes that would be impacted by the evaluation of the nodes in parents array in sorted order + subSortOrderArray = this.getEvaluationSortOrder(parents, inverseMap); + + // Add all the sorted nodes in the final list + finalSortOrder = [...finalSortOrder, ...subSortOrderArray]; + + parents = getImmediateParentsOfPropertyPaths(subSortOrderArray); + // If we find parents of the property paths in the sorted array, we should continue finding all the nodes dependent + // on the parents + computeSortOrder = parents.length > 0; + } + + // Remove duplicates from this list. Since we explicitly walk down the tree and implicitly (by fetching parents) walk + // up the tree, there are bound to be many duplicates. + const uniqueKeysInSortOrder = new Set(finalSortOrder); + + // if a property path evaluation gets triggered by diff top order changes + // this could lead to incorrect sort order in spite of the bfs traversal + const sortOrderPropertyPaths: string[] = []; + this.sortedDependencies.forEach((path) => { + if (uniqueKeysInSortOrder.has(path)) { + sortOrderPropertyPaths.push(path); + // remove from the uniqueKeysInSortOrder + uniqueKeysInSortOrder.delete(path); + } + }); + // Add any remaining paths in the uniqueKeysInSortOrder + const completeSortOrder = [ + ...Array.from(uniqueKeysInSortOrder), + ...sortOrderPropertyPaths, + ]; + + //Trim this list to now remove the property paths which are simply entity names + const finalSortOrderArray: Array = []; + completeSortOrder.forEach((propertyPath) => { + const lastIndexOfDot = propertyPath.lastIndexOf("."); + // Only do this for property paths and not the entity themselves + if (lastIndexOfDot !== -1) { + finalSortOrderArray.push(propertyPath); + } + }); + + return finalSortOrderArray; + } + + getEvaluationSortOrder( + changes: Array, + inverseMap: DependencyMap, + ): Array { + const sortOrder: Array = [...changes]; + let iterator = 0; + while (iterator < sortOrder.length) { + // Find all the nodes who are to be evaluated when sortOrder[iterator] changes + const newNodes = inverseMap[sortOrder[iterator]]; + + // If we find more nodes that would be impacted by the evaluation of the node being investigated + // we add these to the sort order. + if (newNodes) { + newNodes.forEach((toBeEvaluatedNode) => { + // Only add the nodes if they haven't been already added for evaluation in the list. Since we are doing + // breadth first traversal, we should be safe in not changing the evaluation order and adding this now at this + // point instead of the previous index found. + if (!sortOrder.includes(toBeEvaluatedNode)) { + sortOrder.push(toBeEvaluatedNode); + } + }); + } + iterator++; + } + return sortOrder; + } + + createDependencyMap(unEvalTree: DataTree): DependencyMap { + let dependencyMap: DependencyMap = {}; + this.allKeys = getAllPaths(unEvalTree); + Object.keys(unEvalTree).forEach((entityName) => { + const entity = unEvalTree[entityName]; + if (isAction(entity) || isWidget(entity)) { + const entityListedDependencies = this.listEntityDependencies( + entity, + entityName, + ); + dependencyMap = { ...dependencyMap, ...entityListedDependencies }; + } + }); + Object.keys(dependencyMap).forEach((key) => { + dependencyMap[key] = _.flatten( + dependencyMap[key].map((path) => + extractReferencesFromBinding(path, this.allKeys), + ), + ); + }); + dependencyMap = makeParentsDependOnChildren(dependencyMap); + return dependencyMap; + } + + listEntityDependencies( + entity: DataTreeWidget | DataTreeAction, + entityName: string, + ): DependencyMap { + const dependencies: DependencyMap = {}; + const dynamicBindingPathList = getEntityDynamicBindingPathList(entity); + if (dynamicBindingPathList.length) { + dynamicBindingPathList.forEach((dynamicPath) => { + const propertyPath = dynamicPath.key; + // [[ quincy hack ]] skip all "schema" path binding + if (propertyPath === "schema") { + return; + } + const unevalPropValue = _.get(entity, propertyPath); + const { jsSnippets } = getDynamicBindings(unevalPropValue); + const existingDeps = + dependencies[`${entityName}.${propertyPath}`] || []; + dependencies[`${entityName}.${propertyPath}`] = existingDeps.concat( + jsSnippets.filter((jsSnippet) => !!jsSnippet), + ); + }); + } + if (isWidget(entity)) { + // Set default property dependency + const defaultProperties = this.widgetConfigMap[entity.type] + .defaultProperties; + Object.entries(defaultProperties).forEach( + ([property, defaultPropertyPath]) => { + dependencies[`${entityName}.${property}`] = [ + `${entityName}.${defaultPropertyPath}`, + ]; + }, + ); + } + if (isAction(entity)) { + Object.entries(entity.dependencyMap).forEach( + ([path, entityDependencies]) => { + const actionDependentPaths: Array = []; + const mainPath = `${entityName}.${path}`; + // Only add dependencies for paths which exist at the moment in appsmith world + if (this.allKeys.hasOwnProperty(mainPath)) { + // Only add dependent paths which exist in the data tree. Skip all the other paths to avoid creating + // a cyclical dependency. + entityDependencies.forEach((dependentPath) => { + const completePath = `${entityName}.${dependentPath}`; + if (this.allKeys.hasOwnProperty(completePath)) { + actionDependentPaths.push(completePath); + } + }); + dependencies[mainPath] = actionDependentPaths; + } + }, + ); + } + return dependencies; + } + + evaluateTree( + oldUnevalTree: DataTree, + sortedDependencies: Array, + ): DataTree { + const tree = _.cloneDeep(oldUnevalTree); + try { + return sortedDependencies.reduce( + (currentTree: DataTree, fullPropertyPath: string) => { + const { entityName, propertyPath } = getEntityNameAndPropertyPath( + fullPropertyPath, + ); + const entity = currentTree[entityName] as + | DataTreeWidget + | DataTreeAction; + const unEvalPropertyValue = _.get( + currentTree as any, + fullPropertyPath, + ); + const isABindingPath = + (isAction(entity) || isWidget(entity)) && + isPathADynamicBinding(entity, propertyPath); + let evalPropertyValue; + const requiresEval = + isABindingPath && isDynamicValue(unEvalPropertyValue); + if (propertyPath) { + _.set(currentTree, getEvalErrorPath(fullPropertyPath), []); + } + if (requiresEval) { + const evaluationSubstitutionType = + entity.bindingPaths[propertyPath] || + EvaluationSubstitutionType.TEMPLATE; + try { + evalPropertyValue = this.getDynamicValue( + unEvalPropertyValue, + currentTree, + evaluationSubstitutionType, + false, + undefined, + fullPropertyPath, + ); + } catch (e) { + this.errors.push({ + type: EvalErrorTypes.EVAL_PROPERTY_ERROR, + message: e.message, + context: { + propertyPath: fullPropertyPath, + }, + }); + evalPropertyValue = undefined; + } + } else { + evalPropertyValue = unEvalPropertyValue; + } + + if (isWidget(entity)) { + const widgetEntity = entity; + const defaultPropertyMap = this.widgetConfigMap[widgetEntity.type] + .defaultProperties; + const isDefaultProperty = !!Object.values( + defaultPropertyMap, + ).filter( + (defaultPropertyName) => propertyPath === defaultPropertyName, + ).length; + if (propertyPath) { + let parsedValue = this.validateAndParseWidgetProperty( + fullPropertyPath, + widgetEntity, + currentTree, + evalPropertyValue, + unEvalPropertyValue, + isDefaultProperty, + ); + const hasDefaultProperty = propertyPath in defaultPropertyMap; + if (hasDefaultProperty) { + const defaultProperty = defaultPropertyMap[propertyPath]; + parsedValue = this.overwriteDefaultDependentProps( + defaultProperty, + parsedValue, + fullPropertyPath, + widgetEntity, + ); + } + return _.set(currentTree, fullPropertyPath, parsedValue); + } + return _.set(currentTree, fullPropertyPath, evalPropertyValue); + } else if (isAction(entity)) { + const safeEvaluatedValue = removeFunctions(evalPropertyValue); + _.set( + currentTree, + getEvalValuePath(fullPropertyPath), + safeEvaluatedValue, + ); + _.set(currentTree, fullPropertyPath, evalPropertyValue); + return currentTree; + } else { + return _.set(currentTree, fullPropertyPath, evalPropertyValue); + } + }, + tree, + ); + } catch (e) { + this.errors.push({ + type: EvalErrorTypes.EVAL_TREE_ERROR, + message: e.message, + }); + return tree; + } + } + + sortDependencies( + dependencyMap: DependencyMap, + diffs?: (DataTreeDiff | DataTreeDiff[])[], + ): Array { + const dependencyTree: Array<[string, string]> = []; + Object.keys(dependencyMap).forEach((key: string) => { + if (dependencyMap[key].length) { + dependencyMap[key].forEach((dep) => dependencyTree.push([key, dep])); + } else { + // Set no dependency + dependencyTree.push([key, ""]); + } + }); + + try { + // sort dependencies and remove empty dependencies + return toposort(dependencyTree) + .reverse() + .filter((d) => !!d); + } catch (e) { + // Cyclic dependency found. Extract all node and entity type + const node = e.message.match( + new RegExp('Cyclic dependency, node was:"(.*)"'), + )[1]; + + let entityType = "UNKNOWN"; + const entityName = node.split(".")[0]; + const entity = _.get(this.oldUnEvalTree, entityName); + if (entity && isWidget(entity)) { + entityType = entity.type; + } else if (entity && isAction(entity)) { + entityType = entity.pluginType; + } + this.errors.push({ + type: EvalErrorTypes.CYCLICAL_DEPENDENCY_ERROR, + message: "Cyclic dependency found while evaluating.", + context: { + node, + entityType, + dependencyMap, + diffs, + }, + }); + console.error("CYCLICAL DEPENDENCY MAP", dependencyMap); + throw new CrashingError(e.message); + } + } + + getParsedValueCache(propertyPath: string) { + return ( + this.parsedValueCache.get(propertyPath) || { + value: undefined, + version: 0, + } + ); + } + + clearPropertyCache(propertyPath: string) { + this.parsedValueCache.delete(propertyPath); + } + + clearPropertyCacheOfWidget(widgetName: string) { + // TODO check if this loop mutating itself is safe + this.parsedValueCache.forEach((value, key) => { + const match = key.match(`${widgetName}.`); + if (match) { + this.parsedValueCache.delete(key); + } + }); + } + + clearAllCaches() { + this.parsedValueCache.clear(); + this.clearErrors(); + this.dependencyMap = {}; + this.allKeys = {}; + this.inverseDependencyMap = {}; + this.sortedDependencies = []; + this.evalTree = {}; + this.oldUnEvalTree = {}; + } + + getDynamicValue( + dynamicBinding: string, + data: DataTree, + evaluationSubstitutionType: EvaluationSubstitutionType, + returnTriggers: boolean, + callBackData?: Array, + fullPropertyPath?: string, + ) { + // Get the {{binding}} bound values + const { jsSnippets, stringSegments } = getDynamicBindings(dynamicBinding); + if (returnTriggers) { + return this.evaluateDynamicBoundValue( + jsSnippets[0], + data, + callBackData, + returnTriggers, + ); + } + if (stringSegments.length) { + // Get the Data Tree value of those "binding "paths + const values = jsSnippets.map((jsSnippet, index) => { + if (jsSnippet) { + const result = this.evaluateDynamicBoundValue( + jsSnippet, + data, + callBackData, + ); + if (fullPropertyPath && result.errors.length) { + addErrorToEntityProperty(result.errors, data, fullPropertyPath); + } + return result.result; + } else { + return stringSegments[index]; + } + }); + + // if it is just one binding, return that directly + if (stringSegments.length === 1) return values[0]; + // else return a combined value according to the evaluation type + return substituteDynamicBindingWithValues( + dynamicBinding, + stringSegments, + values, + evaluationSubstitutionType, + ); + } + return undefined; + } + + // Paths are expected to have "{name}.{path}" signature + // Also returns any action triggers found after evaluating value + evaluateDynamicBoundValue( + js: string, + data: DataTree, + callbackData?: Array, + isTriggerBased = false, + ): EvalResult { + try { + return evaluate(js, data, callbackData, isTriggerBased); + } catch (e) { + return { + result: undefined, + triggers: [], + errors: [ + { + errorType: PropertyEvaluationErrorType.PARSE, + raw: js, + severity: Severity.ERROR, + errorMessage: e.message, + }, + ], + }; + } + } + + validateAndParseWidgetProperty( + fullPropertyPath: string, + widget: DataTreeWidget, + currentTree: DataTree, + evalPropertyValue: any, + unEvalPropertyValue: string, + isDefaultProperty: boolean, + ): any { + const { propertyPath } = getEntityNameAndPropertyPath(fullPropertyPath); + let valueToValidate = evalPropertyValue; + if (isPathADynamicTrigger(widget, propertyPath)) { + const { triggers } = this.getDynamicValue( + unEvalPropertyValue, + currentTree, + EvaluationSubstitutionType.TEMPLATE, + true, + undefined, + fullPropertyPath, + ); + valueToValidate = triggers; + } + const validation = widget.validationPaths[propertyPath]; + + const { isValid, message, parsed, transformed } = validateWidgetProperty( + validation, + valueToValidate, + widget, + ); + + const evaluatedValue = isValid + ? parsed + : _.isUndefined(transformed) + ? evalPropertyValue + : transformed; + const safeEvaluatedValue = removeFunctions(evaluatedValue); + _.set( + widget, + getEvalValuePath(fullPropertyPath, false), + safeEvaluatedValue, + ); + if (!isValid) { + addErrorToEntityProperty( + [ + { + raw: unEvalPropertyValue, + errorMessage: message || "", + errorType: PropertyEvaluationErrorType.VALIDATION, + severity: Severity.ERROR, + }, + ], + currentTree, + fullPropertyPath, + ); + } + + if (isPathADynamicTrigger(widget, propertyPath)) { + return unEvalPropertyValue; + } else { + const parsedCache = this.getParsedValueCache(fullPropertyPath); + // In case this is a default property, always set the cache even if the value remains the same so that the version + // in cache gets updated and the property dependent on default property updates accordingly. + if (!equal(parsedCache.value, parsed) || isDefaultProperty) { + this.parsedValueCache.set(fullPropertyPath, { + value: parsed, + version: Date.now(), + }); + } + return parsed; + } + } + + overwriteDefaultDependentProps( + defaultProperty: string, + propertyValue: any, + propertyPath: string, + entity: DataTreeWidget, + ) { + const defaultPropertyCache = this.getParsedValueCache( + `${entity.widgetName}.${defaultProperty}`, + ); + const propertyCache = this.getParsedValueCache(propertyPath); + if ( + propertyValue === undefined || + propertyCache.version < defaultPropertyCache.version + ) { + return defaultPropertyCache.value; + } + return propertyValue; + } + + updateDependencyMap( + translatedDiffs: Array, + unEvalDataTree: DataTree, + ): { + dependenciesOfRemovedPaths: Array; + removedPaths: Array; + } { + const diffCalcStart = performance.now(); + let didUpdateDependencyMap = false; + const dependenciesOfRemovedPaths: Array = []; + const removedPaths: Array = []; + + // This is needed for NEW and DELETE events below. + // In worst case, it tends to take ~12.5% of entire diffCalc (8 ms out of 67ms for 132 array of NEW) + // TODO: Optimise by only getting paths of changed node + this.allKeys = getAllPaths(unEvalDataTree); + // Transform the diff library events to Appsmith evaluator events + translatedDiffs.forEach((dataTreeDiff) => { + const entityName = dataTreeDiff.payload.propertyPath.split(".")[0]; + let entity = unEvalDataTree[entityName]; + if (dataTreeDiff.event === DataTreeDiffEvent.DELETE) { + entity = this.oldUnEvalTree[entityName]; + } + const entityType = isValidEntity(entity) ? entity.ENTITY_TYPE : "noop"; + + if (entityType !== "noop") { + switch (dataTreeDiff.event) { + case DataTreeDiffEvent.NEW: { + // If a new entity/property was added, add all the internal bindings for this entity to the global dependency map + if ( + (isWidget(entity) || isAction(entity)) && + !isDynamicLeaf(unEvalDataTree, dataTreeDiff.payload.propertyPath) + ) { + const entityDependencyMap: DependencyMap = this.listEntityDependencies( + entity, + entityName, + ); + if (Object.keys(entityDependencyMap).length) { + didUpdateDependencyMap = true; + // The entity might already have some dependencies, + // so we just want to update those + Object.entries(entityDependencyMap).forEach( + ([entityDependent, entityDependencies]) => { + if (this.dependencyMap[entityDependent]) { + this.dependencyMap[entityDependent] = this.dependencyMap[ + entityDependent + ].concat(entityDependencies); + } else { + this.dependencyMap[entityDependent] = entityDependencies; + } + }, + ); + } + } + // Either a new entity or a new property path has been added. Go through existing dynamic bindings and + // find out if a new dependency has to be created because the property path used in the binding just became + // eligible + const possibleReferencesInOldBindings: DependencyMap = this.getPropertyPathReferencesInExistingBindings( + unEvalDataTree, + dataTreeDiff.payload.propertyPath, + ); + // We have found some bindings which are related to the new property path and hence should be added to the + // global dependency map + if (Object.keys(possibleReferencesInOldBindings).length) { + didUpdateDependencyMap = true; + Object.assign( + this.dependencyMap, + possibleReferencesInOldBindings, + ); + } + break; + } + case DataTreeDiffEvent.DELETE: { + // Add to removedPaths as they have been deleted from the evalTree + removedPaths.push(dataTreeDiff.payload.propertyPath); + // If an existing widget was deleted, remove all the bindings from the global dependency map + if ( + (isWidget(entity) || isAction(entity)) && + dataTreeDiff.payload.propertyPath === entityName + ) { + const entityDependencies = this.listEntityDependencies( + entity, + entityName, + ); + Object.keys(entityDependencies).forEach((widgetDep) => { + didUpdateDependencyMap = true; + delete this.dependencyMap[widgetDep]; + }); + } + // Either an existing entity or an existing property path has been deleted. Update the global dependency map + // by removing the bindings from the same. + Object.keys(this.dependencyMap).forEach((dependencyPath) => { + didUpdateDependencyMap = true; + if ( + isChildPropertyPath( + dataTreeDiff.payload.propertyPath, + dependencyPath, + ) + ) { + delete this.dependencyMap[dependencyPath]; + } else { + const toRemove: Array = []; + this.dependencyMap[dependencyPath].forEach((dependantPath) => { + if ( + isChildPropertyPath( + dataTreeDiff.payload.propertyPath, + dependantPath, + ) + ) { + dependenciesOfRemovedPaths.push(dependencyPath); + toRemove.push(dependantPath); + } + }); + this.dependencyMap[dependencyPath] = _.difference( + this.dependencyMap[dependencyPath], + toRemove, + ); + } + }); + break; + } + + case DataTreeDiffEvent.EDIT: { + // We only care if the difference is in dynamic bindings since static values do not need + // an evaluation. + if ( + (isWidget(entity) || isAction(entity)) && + typeof dataTreeDiff.payload.value === "string" + ) { + const entity: DataTreeAction | DataTreeWidget = unEvalDataTree[ + entityName + ] as DataTreeAction | DataTreeWidget; + const fullPropertyPath = dataTreeDiff.payload.propertyPath; + const entityPropertyPath = fullPropertyPath.substring( + fullPropertyPath.indexOf(".") + 1, + ); + const isABindingPath = isPathADynamicBinding( + entity, + entityPropertyPath, + ); + if (isABindingPath) { + didUpdateDependencyMap = true; + + const { jsSnippets } = getDynamicBindings( + dataTreeDiff.payload.value, + ); + const correctSnippets = jsSnippets.filter( + (jsSnippet) => !!jsSnippet, + ); + // We found a new dynamic binding for this property path. We update the dependency map by overwriting the + // dependencies for this property path with the newly found dependencies + if (correctSnippets.length) { + this.dependencyMap[fullPropertyPath] = correctSnippets; + } else { + // The dependency on this property path has been removed. Delete this property path from the global + // dependency map + delete this.dependencyMap[fullPropertyPath]; + } + if (isAction(entity)) { + // Actions have a defined dependency map that should always be maintained + if (entityPropertyPath in entity.dependencyMap) { + const entityDependenciesName = entity.dependencyMap[ + entityPropertyPath + ].map((dep) => `${entityName}.${dep}`); + + // Filter only the paths which exist in the appsmith world to avoid cyclical dependencies + const filteredEntityDependencies = entityDependenciesName.filter( + (path) => this.allKeys.hasOwnProperty(path), + ); + + // Now assign these existing dependent paths to the property path in dependencyMap + if (fullPropertyPath in this.dependencyMap) { + this.dependencyMap[fullPropertyPath] = this.dependencyMap[ + fullPropertyPath + ].concat(filteredEntityDependencies); + } else { + this.dependencyMap[ + fullPropertyPath + ] = filteredEntityDependencies; + } + } + } + } + // If the whole binding was removed then the value + // at this path would be "". + // In this case if the path exists in the dependency map + // remove it. + else if (fullPropertyPath in this.dependencyMap) { + delete this.dependencyMap[fullPropertyPath]; + } + } + break; + } + default: { + break; + } + } + } + }); + const diffCalcEnd = performance.now(); + const subDepCalcStart = performance.now(); + if (didUpdateDependencyMap) { + // TODO Optimise + Object.keys(this.dependencyMap).forEach((key) => { + this.dependencyMap[key] = _.uniq( + _.flatten( + this.dependencyMap[key].map((path) => + extractReferencesFromBinding(path, this.allKeys), + ), + ), + ); + }); + this.dependencyMap = makeParentsDependOnChildren(this.dependencyMap); + } + const subDepCalcEnd = performance.now(); + const updateChangedDependenciesStart = performance.now(); + // If the global dependency map has changed, re-calculate the sort order for all entities and the + // global inverse dependency map + if (didUpdateDependencyMap) { + // This is being called purely to test for new circular dependencies that might have been added + this.sortedDependencies = this.sortDependencies( + this.dependencyMap, + translatedDiffs, + ); + this.inverseDependencyMap = this.getInverseDependencyTree(); + } + + const updateChangedDependenciesStop = performance.now(); + this.logs.push({ + diffCalcDeps: (diffCalcEnd - diffCalcStart).toFixed(2), + subDepCalc: (subDepCalcEnd - subDepCalcStart).toFixed(2), + updateChangedDependencies: ( + updateChangedDependenciesStop - updateChangedDependenciesStart + ).toFixed(2), + }); + + return { dependenciesOfRemovedPaths, removedPaths }; + } + + calculateSubTreeSortOrder( + differences: Diff[], + dependenciesOfRemovedPaths: Array, + removedPaths: Array, + unEvalTree: DataTree, + ) { + const changePaths: Set = new Set(dependenciesOfRemovedPaths); + for (const d of differences) { + if (!Array.isArray(d.path) || d.path.length === 0) continue; // Null check for typescript + // Apply the changes into the evalTree so that it gets the latest changes + applyChange(this.evalTree, undefined, d); + + changePaths.add(convertPathToString(d.path)); + // If this is a property path change, simply add for evaluation and move on + if (!isDynamicLeaf(unEvalTree, convertPathToString(d.path))) { + // A parent level property has been added or deleted + /** + * We want to add all pre-existing dynamic and static bindings in dynamic paths of this entity to get evaluated and validated. + * Example: + * - Table1.tableData = {{Api1.data}} + * - Api1 gets created. + * - This function gets called with a diff {path:["Api1"]} + * We want to add `Api.data` to changedPaths so that `Table1.tableData` can be discovered below. + */ + const entityName = d.path[0]; + const entity = unEvalTree[entityName]; + if (!entity) { + continue; + } + if (!isAction(entity) && !isWidget(entity)) { + continue; + } + const parentPropertyPath = convertPathToString(d.path); + Object.keys(entity.bindingPaths).forEach((relativePath) => { + const childPropertyPath = `${entityName}.${relativePath}`; + if (isChildPropertyPath(parentPropertyPath, childPropertyPath)) { + changePaths.add(childPropertyPath); + } + }); + } + } + + // If a nested property path has changed and someone (say x) is dependent on the parent of the said property, + // x must also be evaluated. For example, the following relationship exists in dependency map: + // < "Input1.defaultText" : ["Table1.selectedRow.email"] > + // If Table1.selectedRow has changed, then Input1.defaultText must also be evaluated because Table1.selectedRow.email + // is a nested property of Table1.selectedRow + const changePathsWithNestedDependants = addDependantsOfNestedPropertyPaths( + Array.from(changePaths), + this.inverseDependencyMap, + ); + + const trimmedChangedPaths = trimDependantChangePaths( + changePathsWithNestedDependants, + this.dependencyMap, + ); + + // Now that we have all the root nodes which have to be evaluated, recursively find all the other paths which + // would get impacted because they are dependent on the said root nodes and add them in order + const completeSortOrder = this.getCompleteSortOrder( + trimmedChangedPaths, + this.inverseDependencyMap, + ); + // Remove any paths that do no exist in the data tree any more + return _.difference(completeSortOrder, removedPaths); + } + + getInverseDependencyTree(): DependencyMap { + const inverseDag: DependencyMap = {}; + this.sortedDependencies.forEach((propertyPath) => { + const incomingEdges: Array = this.dependencyMap[propertyPath]; + if (incomingEdges) { + incomingEdges.forEach((edge) => { + const node = inverseDag[edge]; + if (node) { + node.push(propertyPath); + } else { + inverseDag[edge] = [propertyPath]; + } + }); + } + }); + return inverseDag; + } + + // TODO: create the lookup dictionary once + // Response from listEntityDependencies only needs to change if the entity itself changed. + // Check if it is possible to make a flat structure with O(1) or at least O(m) lookup instead of O(n*m) + getPropertyPathReferencesInExistingBindings( + dataTree: DataTree, + propertyPath: string, + ) { + const possibleRefs: DependencyMap = {}; + Object.keys(dataTree).forEach((entityName) => { + const entity = dataTree[entityName]; + if ( + isValidEntity(entity) && + (entity.ENTITY_TYPE === ENTITY_TYPE.ACTION || + entity.ENTITY_TYPE === ENTITY_TYPE.WIDGET) + ) { + const entityPropertyBindings = this.listEntityDependencies( + entity, + entityName, + ); + Object.keys(entityPropertyBindings).forEach((path) => { + const propertyBindings = entityPropertyBindings[path]; + const references = _.flatten( + propertyBindings.map((binding) => + extractReferencesFromBinding(binding, this.allKeys), + ), + ); + references.forEach((value) => { + if (isChildPropertyPath(propertyPath, value)) { + possibleRefs[path] = propertyBindings; + } + }); + }); + } + }); + return possibleRefs; + } + + evaluateActionBindings( + bindings: string[], + executionParams?: Record | string, + ) { + // We might get execution params as an object or as a string. + // If the user has added a proper object (valid case) it will be an object + // If they have not added any execution params or not an object + // it would be a string (invalid case) + let evaluatedExecutionParams: Record = {}; + if (executionParams && _.isObject(executionParams)) { + evaluatedExecutionParams = this.getDynamicValue( + `{{${JSON.stringify(executionParams)}}}`, + this.evalTree, + EvaluationSubstitutionType.TEMPLATE, + false, + ); + } + + // Replace any reference of 'this.params' to 'executionParams' (backwards compatibility) + const bindingsForExecutionParams: string[] = bindings.map( + (binding: string) => + binding.replace(EXECUTION_PARAM_REFERENCE_REGEX, EXECUTION_PARAM_KEY), + ); + + const dataTreeWithExecutionParams = Object.assign({}, this.evalTree, { + [EXECUTION_PARAM_KEY]: evaluatedExecutionParams, + }); + + return bindingsForExecutionParams.map((binding) => + this.getDynamicValue( + `{{${binding}}}`, + dataTreeWithExecutionParams, + EvaluationSubstitutionType.TEMPLATE, + false, + ), + ); + } + + clearErrors() { + this.errors = []; + } + + clearLogs() { + this.logs = []; + } +} + +const extractReferencesFromBinding = ( + dependentPath: string, + all: Record, +): Array => { + const subDeps: Array = []; + const identifiers = dependentPath.match(/[a-zA-Z_$][a-zA-Z_$0-9.\[\]]*/g) || [ + dependentPath, + ]; + identifiers.forEach((identifier: string) => { + // If the identifier exists directly, add it and return + if (all.hasOwnProperty(identifier)) { + subDeps.push(identifier); + return; + } + const subpaths = _.toPath(identifier); + let current = ""; + // We want to keep going till we reach top level, but not add top level + // Eg: Input1.text should not depend on entire Table1 unless it explicitly asked for that. + // This is mainly to avoid a lot of unnecessary evals, if we feel this is wrong + // we can remove the length requirement and it will still work + while (subpaths.length > 1) { + current = convertPathToString(subpaths); + // We've found the dep, add it and return + if (all.hasOwnProperty(current)) { + subDeps.push(current); + return; + } + subpaths.pop(); + } + }); + return _.uniq(subDeps); +}; + +// TODO cryptic comment below. Dont know if we still need this. Duplicate function +// referencing DATA_BIND_REGEX fails for the value "{{Table1.tableData[Table1.selectedRowIndex]}}" if you run it multiple times and don't recreate +const isDynamicValue = (value: string): boolean => DATA_BIND_REGEX.test(value); + +function isValidEntity(entity: DataTreeEntity): entity is DataTreeObjectEntity { + if (!_.isObject(entity)) { + return false; + } + return "ENTITY_TYPE" in entity; +} + +function isWidget(entity: DataTreeEntity): entity is DataTreeWidget { + return isValidEntity(entity) && entity.ENTITY_TYPE === ENTITY_TYPE.WIDGET; +} + +function isAction(entity: DataTreeEntity): entity is DataTreeAction { + return isValidEntity(entity) && entity.ENTITY_TYPE === ENTITY_TYPE.ACTION; +} diff --git a/app/taro/src/workers/ast.ts b/app/taro/src/workers/ast.ts new file mode 100644 index 0000000000..f3f32c474a --- /dev/null +++ b/app/taro/src/workers/ast.ts @@ -0,0 +1,11 @@ +import { generate } from "astring"; +import { parse } from "acorn"; + +export const getAST = (code: string) => parse(code, { ecmaVersion: 2020 }); +export const getFnContents = (code: string) => { + const ast = getAST(code); + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore: ast has body, please believe me! + const fnBlock = generate(ast.body[0].body); + return fnBlock.substring(1, fnBlock.length - 1); +}; diff --git a/app/taro/src/workers/evaluate.ts b/app/taro/src/workers/evaluate.ts new file mode 100644 index 0000000000..53852389eb --- /dev/null +++ b/app/taro/src/workers/evaluate.ts @@ -0,0 +1,211 @@ +import { ActionDescription, DataTree } from "entities/DataTree/dataTreeFactory"; +import { addFunctions } from "workers/evaluationUtils"; +import _ from "lodash"; +import { + EvaluationError, + extraLibraries, + PropertyEvaluationErrorType, + unsafeFunctionForEval, +} from "utils/DynamicBindingUtils"; +import unescapeJS from "unescape-js"; +// import { JSHINT as jshint } from "jshint"; +import { Severity } from "entities/AppsmithConsole"; +import { Interpreter } from "eval5"; + +export type EvalResult = { + result: any; + triggers?: ActionDescription[]; + errors: EvaluationError[]; +}; + +export enum EvaluationScriptType { + EXPRESSION = "EXPRESSION", + ANONYMOUS_FUNCTION = "ANONYMOUS_FUNCTION", + TRIGGERS = "TRIGGERS", +} + +const evaluationScripts: Record< + EvaluationScriptType, + (script: string) => string +> = { + [EvaluationScriptType.EXPRESSION]: (script: string) => ` + function closedFunction () { + var result = ${script} + return result; + } + closedFunction() + `, + [EvaluationScriptType.ANONYMOUS_FUNCTION]: (script) => ` + function callback (script) { + var userFunction = script; + var result = userFunction.apply(this, ARGUMENTS); + return result; + } + callback(${script}) + `, + [EvaluationScriptType.TRIGGERS]: (script) => ` + function closedFunction () { + var result = ${script} + } + closedFunction() + `, +}; + +const getScriptToEval = ( + userScript: string, + evalArguments?: Array, + isTriggerBased = false, +): string => { + let scriptType = EvaluationScriptType.EXPRESSION; + if (evalArguments) { + scriptType = EvaluationScriptType.ANONYMOUS_FUNCTION; + } else if (isTriggerBased) { + scriptType = EvaluationScriptType.TRIGGERS; + } + return evaluationScripts[scriptType](userScript); +}; + +// const getLintingErrors = ( +// script: string, +// data: Record, +// ): EvaluationError[] => { +// const globalData: Record = {}; +// Object.keys(data).forEach((datum) => (globalData[datum] = false)); +// const options = { +// indent: 2, +// esversion: 7, +// eqeqeq: true, +// curly: true, +// freeze: true, +// undef: true, +// unused: true, +// asi: true, +// worker: true, +// globals: globalData, +// }; +// jshint(script, options); + +// return jshint.errors.map((lintError) => { +// return { +// errorType: PropertyEvaluationErrorType.LINT, +// raw: script, +// severity: lintError.code.startsWith("W") +// ? Severity.WARNING +// : Severity.ERROR, +// errorMessage: lintError.reason, +// errorSegment: lintError.evidence, +// }; +// }); +// }; + +const beginsWithLineBreakRegex = /^\s+|\s+$/; + +export default function evaluate( + js: string, + data: DataTree, + evalArguments?: Array, + isTriggerBased = false, +): EvalResult { + // We remove any line breaks from the beginning of the script because that + // makes the final function invalid. We also unescape any escaped characters + // so that eval can happen + const unescapedJS = unescapeJS(js.replace(beginsWithLineBreakRegex, "")); + const script = getScriptToEval(unescapedJS, evalArguments, isTriggerBased); + return (function() { + let errors: EvaluationError[] = []; + let result; + let triggers: any[] = []; + /**** Setting the eval context ****/ + const GLOBAL_DATA: Record = {}; + ///// Adding callback data + GLOBAL_DATA.ARGUMENTS = evalArguments; + if (isTriggerBased) { + //// Add internal functions to dataTree; + const dataTreeWithFunctions = addFunctions(data); + ///// Adding Data tree with functions + Object.keys(dataTreeWithFunctions).forEach((datum) => { + GLOBAL_DATA[datum] = dataTreeWithFunctions[datum]; + }); + ///// Fixing action paths and capturing their execution response + if (dataTreeWithFunctions.actionPaths) { + GLOBAL_DATA.triggers = []; + const pusher = function( + this: DataTree, + action: any, + ...payload: any[] + ) { + const actionPayload = action(...payload); + GLOBAL_DATA.triggers.push(actionPayload); + }; + GLOBAL_DATA.actionPaths.forEach((path: string) => { + const action = _.get(GLOBAL_DATA, path); + const entity = _.get(GLOBAL_DATA, path.split(".")[0]); + if (action) { + _.set(GLOBAL_DATA, path, pusher.bind(data, action.bind(entity))); + } + }); + } + } else { + ///// Adding Data tree + Object.keys(data).forEach((datum) => { + GLOBAL_DATA[datum] = data[datum]; + }); + } + + // eval context + const self = {}; + + // Set it to self so that the eval function can have access to it + // as global data. This is what enables access all appsmith + // entity properties from the global context + Object.keys(GLOBAL_DATA).forEach((key) => { + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore: No types available + self[key] = GLOBAL_DATA[key]; + }); + // errors = getLintingErrors(script, GLOBAL_DATA); + + ///// Adding extra libraries separately + extraLibraries.forEach((library) => { + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore: No types available + self[library.accessor] = library.lib; + }); + + ///// Remove all unsafe functions + unsafeFunctionForEval.forEach((func) => { + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore: No types available + self[func] = undefined; + }); + try { + const interpreter = new Interpreter(self); + Interpreter.globalContextInFunction = self; + result = interpreter.evaluate(script); + // result = eval(script); + if (isTriggerBased) { + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore + triggers = [...self.triggers]; + } + } catch (e) { + const errorMessage = `${e.name}: ${e.message}`; + errors.push({ + errorMessage: errorMessage, + severity: Severity.ERROR, + raw: script, + errorType: PropertyEvaluationErrorType.PARSE, + }); + } + + // Remove it from self + // This is needed so that next eval can have a clean sheet + Object.keys(GLOBAL_DATA).forEach((key) => { + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore: No types available + delete self[key]; + }); + + return { result, triggers, errors }; + })(); +} diff --git a/app/taro/src/workers/evaluation.worker.ts b/app/taro/src/workers/evaluation.worker.ts new file mode 100644 index 0000000000..072bcc6df3 --- /dev/null +++ b/app/taro/src/workers/evaluation.worker.ts @@ -0,0 +1,186 @@ +import { + DataTree, + EvaluationSubstitutionType, +} from "entities/DataTree/dataTreeFactory"; +import { + DependencyMap, + EVAL_WORKER_ACTIONS, + EvalError, + EvalErrorTypes, + EvaluationError, + PropertyEvaluationErrorType, +} from "utils/DynamicBindingUtils"; +import { + CrashingError, + DataTreeDiff, + getSafeToRenderDataTree, + removeFunctions, + validateWidgetProperty, +} from "./evaluationUtils"; +import DataTreeEvaluator from "workers/DataTreeEvaluator"; +import { Diff } from "deep-diff"; + +// @ts-ignore +const ctx: any = worker as any; +// polyfill +const performance = Date; + +let dataTreeEvaluator: DataTreeEvaluator | undefined; + +//TODO: Create a more complete RPC setup in the subtree-eval branch. +function messageEventListener( + fn: (message: EVAL_WORKER_ACTIONS, requestData: any) => void, +) { + return (data: any) => { + const startTime = performance.now(); + const { method, requestData, requestId } = data; + const responseData = fn(method, requestData); + const endTime = performance.now(); + ctx.postMessage({ + requestId, + responseData, + timeTaken: (endTime - startTime).toFixed(2), + }); + }; +} + +ctx.onMessage( + messageEventListener((method, requestData: any) => { + switch (method) { + case EVAL_WORKER_ACTIONS.EVAL_TREE: { + const { unevalTree, widgetTypeConfigMap } = requestData; + let dataTree: DataTree = unevalTree; + let errors: EvalError[] = []; + let logs: any[] = []; + let dependencies: DependencyMap = {}; + let updates: Diff[] = []; + let evaluationOrder: string[] = []; + let unEvalUpdates: DataTreeDiff[] = []; + try { + if (!dataTreeEvaluator) { + dataTreeEvaluator = new DataTreeEvaluator(widgetTypeConfigMap); + dataTree = dataTreeEvaluator.createFirstTree(unevalTree); + evaluationOrder = dataTreeEvaluator.sortedDependencies; + // We need to clean it to remove any possible functions inside the tree. + // If functions exist, it will crash the web worker + dataTree = dataTree && JSON.parse(JSON.stringify(dataTree)); + } else { + dataTree = {}; + const updateResponse = dataTreeEvaluator.updateDataTree(unevalTree); + updates = JSON.parse(JSON.stringify(updateResponse.updates)); + evaluationOrder = updateResponse.evaluationOrder; + unEvalUpdates = updateResponse.unEvalUpdates; + } + dependencies = dataTreeEvaluator.inverseDependencyMap; + errors = dataTreeEvaluator.errors; + dataTreeEvaluator.clearErrors(); + logs = dataTreeEvaluator.logs; + dataTreeEvaluator.clearLogs(); + } catch (e) { + if (dataTreeEvaluator !== undefined) { + errors = dataTreeEvaluator.errors; + logs = dataTreeEvaluator.logs; + } + if (!(e instanceof CrashingError)) { + errors.push({ + type: EvalErrorTypes.UNKNOWN_ERROR, + message: e.message, + }); + console.error(e); + } + dataTree = getSafeToRenderDataTree(unevalTree, widgetTypeConfigMap); + dataTreeEvaluator = undefined; + } + return { + dataTree, + dependencies, + errors, + evaluationOrder, + logs, + updates, + unEvalUpdates, + }; + } + case EVAL_WORKER_ACTIONS.EVAL_ACTION_BINDINGS: { + const { bindings, executionParams } = requestData; + if (!dataTreeEvaluator) { + return { values: undefined, errors: [] }; + } + + const values = dataTreeEvaluator.evaluateActionBindings( + bindings, + executionParams, + ); + + const cleanValues = removeFunctions(values); + + const errors = dataTreeEvaluator.errors; + dataTreeEvaluator.clearErrors(); + return { values: cleanValues, errors }; + } + case EVAL_WORKER_ACTIONS.EVAL_TRIGGER: { + const { callbackData, dataTree, dynamicTrigger } = requestData; + if (!dataTreeEvaluator) { + return { triggers: [], errors: [] }; + } + dataTreeEvaluator.updateDataTree(dataTree); + const evalTree = dataTreeEvaluator.evalTree; + const { + errors: evalErrors, + triggers, + }: { + errors: EvaluationError[]; + triggers: Array; + } = dataTreeEvaluator.getDynamicValue( + dynamicTrigger, + evalTree, + EvaluationSubstitutionType.TEMPLATE, + true, + callbackData, + ); + const cleanTriggers = removeFunctions(triggers); + // Transforming eval errors into eval trigger errors. Since trigger + // errors occur less, we want to treat it separately + const errors = evalErrors + .filter( + (error) => error.errorType === PropertyEvaluationErrorType.PARSE, + ) + .map((error) => ({ + ...error, + message: error.errorMessage, + type: EvalErrorTypes.EVAL_TRIGGER_ERROR, + })); + return { triggers: cleanTriggers, errors }; + } + case EVAL_WORKER_ACTIONS.CLEAR_CACHE: { + dataTreeEvaluator = undefined; + return true; + } + case EVAL_WORKER_ACTIONS.CLEAR_PROPERTY_CACHE: { + const { propertyPath } = requestData; + if (!dataTreeEvaluator) { + return true; + } + dataTreeEvaluator.clearPropertyCache(propertyPath); + return true; + } + case EVAL_WORKER_ACTIONS.CLEAR_PROPERTY_CACHE_OF_WIDGET: { + const { widgetName } = requestData; + if (!dataTreeEvaluator) { + return true; + } + dataTreeEvaluator.clearPropertyCacheOfWidget(widgetName); + return true; + } + case EVAL_WORKER_ACTIONS.VALIDATE_PROPERTY: { + const { props, validation, value } = requestData; + return removeFunctions( + validateWidgetProperty(validation, value, props), + ); + } + default: { + console.error("Action not registered on worker", method); + } + } + }), +); diff --git a/app/taro/src/workers/evaluationSubstitution.ts b/app/taro/src/workers/evaluationSubstitution.ts new file mode 100644 index 0000000000..d4d4511d82 --- /dev/null +++ b/app/taro/src/workers/evaluationSubstitution.ts @@ -0,0 +1,147 @@ +import { getType, Types } from "utils/TypeHelpers"; +import _ from "lodash"; +import { EvaluationSubstitutionType } from "entities/DataTree/dataTreeFactory"; +import { isDynamicValue } from "utils/DynamicBindingUtils"; +import { QUOTED_BINDING_REGEX } from "constants/BindingsConstants"; + +const filterBindingSegmentsAndRemoveQuotes = ( + binding: string, + subSegments: string[], + subSegmentValues: unknown[], +) => { + const bindingStrippedQuotes = binding.replace( + QUOTED_BINDING_REGEX, + (original, firstGroup) => { + return firstGroup; + }, + ); + const subBindings: string[] = []; + const subValues: unknown[] = []; + subSegments.forEach((segment, i) => { + if (isDynamicValue(segment)) { + subBindings.push(segment); + subValues.push(subSegmentValues[i]); + } + }); + return { binding: bindingStrippedQuotes, subBindings, subValues }; +}; + +export const smartSubstituteDynamicValues = ( + originalBinding: string, + subSegments: string[], + subSegmentValues: unknown[], +): string => { + const { + binding, + subBindings, + subValues, + } = filterBindingSegmentsAndRemoveQuotes( + originalBinding, + subSegments, + subSegmentValues, + ); + let finalBinding = binding; + subBindings.forEach((b, i) => { + const value = subValues[i]; + switch (getType(value)) { + case Types.NUMBER: + case Types.BOOLEAN: + case Types.NULL: + case Types.UNDEFINED: + // Direct substitution + finalBinding = finalBinding.replace(b, `${value}`); + break; + case Types.STRING: + // Add quotes to a string + // JSON.stringify string to escape any unsupported characters + finalBinding = finalBinding.replace(b, `${JSON.stringify(value)}`); + break; + case Types.ARRAY: + case Types.OBJECT: + // Stringify and substitute + finalBinding = finalBinding.replace(b, JSON.stringify(value, null, 2)); + break; + } + }); + return finalBinding; +}; + +export const parameterSubstituteDynamicValues = ( + originalBinding: string, + subSegments: string[], + subSegmentValues: unknown[], +) => { + const { + binding, + subBindings, + subValues, + } = filterBindingSegmentsAndRemoveQuotes( + originalBinding, + subSegments, + subSegmentValues, + ); + let finalBinding = binding; + const parameters: Record = {}; + subBindings.forEach((b, i) => { + // Replace binding with $1, $2; + const key = `$${i + 1}`; + finalBinding = finalBinding.replace(b, key); + parameters[key] = + typeof subValues[i] === "object" + ? JSON.stringify(subValues[i], null, 2) + : subValues[i]; + }); + return { value: finalBinding, parameters }; +}; +// For creating a final value where bindings could be in a template format +export const templateSubstituteDynamicValues = ( + binding: string, + subBindings: string[], + subValues: unknown[], +): string => { + // Replace the string with the data tree values + let finalValue = binding; + subBindings.forEach((b, i) => { + let value = subValues[i]; + if (Array.isArray(value) || _.isObject(value)) { + value = JSON.stringify(value); + } + try { + if (typeof value === "string" && JSON.parse(value)) { + value = value.replace(/\\([\s\S])|(")/g, "\\$1$2"); + } + } catch (e) { + // do nothing + } + finalValue = finalValue.replace(b, `${value}`); + }); + return finalValue; +}; + +export const substituteDynamicBindingWithValues = ( + binding: string, + subSegments: string[], + subSegmentValues: unknown[], + evaluationSubstitutionType: EvaluationSubstitutionType, +): string | { value: string; parameters: Record } => { + switch (evaluationSubstitutionType) { + case EvaluationSubstitutionType.TEMPLATE: + return templateSubstituteDynamicValues( + binding, + subSegments, + subSegmentValues, + ); + case EvaluationSubstitutionType.SMART_SUBSTITUTE: + return smartSubstituteDynamicValues( + binding, + subSegments, + subSegmentValues, + ); + case EvaluationSubstitutionType.PARAMETER: + return parameterSubstituteDynamicValues( + binding, + subSegments, + subSegmentValues, + ); + } +}; diff --git a/app/taro/src/workers/evaluationUtils.ts b/app/taro/src/workers/evaluationUtils.ts new file mode 100644 index 0000000000..ccba444a94 --- /dev/null +++ b/app/taro/src/workers/evaluationUtils.ts @@ -0,0 +1,596 @@ +import { + DependencyMap, + EVAL_ERROR_PATH, + EvaluationError, + getEvalErrorPath, + getEvalValuePath, + isChildPropertyPath, + isDynamicValue, + PropertyEvaluationErrorType, +} from "utils/DynamicBindingUtils"; +import { validate } from "./validations"; +import { Diff } from "deep-diff"; +import { + DataTree, + DataTreeAction, + DataTreeAppsmith, + DataTreeEntity, + DataTreeWidget, + ENTITY_TYPE, +} from "entities/DataTree/dataTreeFactory"; +import _ from "lodash"; +import { WidgetTypeConfigMap } from "utils/WidgetFactory"; +import { ValidationConfig } from "constants/PropertyControlConstants"; +import { Severity } from "entities/AppsmithConsole"; + +// Dropdown1.options[1].value -> Dropdown1.options[1] +// Dropdown1.options[1] -> Dropdown1.options +// Dropdown1.options -> Dropdown1 +export const IMMEDIATE_PARENT_REGEX = /^(.*)(\..*|\[.*\])$/; + +export enum DataTreeDiffEvent { + NEW = "NEW", + DELETE = "DELETE", + EDIT = "EDIT", + NOOP = "NOOP", +} + +export type DataTreeDiff = { + payload: { + propertyPath: string; + value?: string; + }; + event: DataTreeDiffEvent; +}; + +export class CrashingError extends Error {} + +export const convertPathToString = (arrPath: Array) => { + let string = ""; + arrPath.forEach((segment) => { + if (isInt(segment)) { + string = string + "[" + segment + "]"; + } else { + if (string.length !== 0) { + string = string + "."; + } + string = string + segment; + } + }); + return string; +}; + +// Todo: improve the logic here +// Right now NaN, Infinity, floats, everything works +function isInt(val: string | number): boolean { + return Number.isInteger(val) || (_.isString(val) && /^\d+$/.test(val)); +} + +// Removes the entity name from the property path +export function getEntityNameAndPropertyPath( + fullPath: string, +): { + entityName: string; + propertyPath: string; +} { + const indexOfFirstDot = fullPath.indexOf("."); + if (indexOfFirstDot === -1) { + // No dot was found so path is the entity name itself + return { + entityName: fullPath, + propertyPath: "", + }; + } + const entityName = fullPath.substring(0, indexOfFirstDot); + const propertyPath = fullPath.substring(indexOfFirstDot + 1); + return { entityName, propertyPath }; +} + +export const translateDiffEventToDataTreeDiffEvent = ( + difference: Diff, +): DataTreeDiff | DataTreeDiff[] => { + let result: DataTreeDiff | DataTreeDiff[] = { + payload: { + propertyPath: "", + value: "", + }, + event: DataTreeDiffEvent.NOOP, + }; + if (!difference.path) { + return result; + } + const propertyPath = convertPathToString(difference.path); + switch (difference.kind) { + case "N": { + result.event = DataTreeDiffEvent.NEW; + result.payload = { + propertyPath, + }; + break; + } + case "D": { + result.event = DataTreeDiffEvent.DELETE; + result.payload = { propertyPath }; + break; + } + case "E": { + const rhsChange = + typeof difference.rhs === "string" && isDynamicValue(difference.rhs); + + const lhsChange = + typeof difference.lhs === "string" && isDynamicValue(difference.lhs); + + if (rhsChange || lhsChange) { + result.event = DataTreeDiffEvent.EDIT; + result.payload = { + propertyPath, + value: difference.rhs, + }; + } else if (difference.lhs === undefined || difference.rhs === undefined) { + // Handle static value changes that change structure that can lead to + // old bindings being eligible + if (difference.lhs === undefined && isTrueObject(difference.rhs)) { + result.event = DataTreeDiffEvent.NEW; + result.payload = { propertyPath }; + } + if (difference.rhs === undefined && isTrueObject(difference.lhs)) { + result.event = DataTreeDiffEvent.DELETE; + result.payload = { propertyPath }; + } + } else if ( + isTrueObject(difference.lhs) && + !isTrueObject(difference.rhs) + ) { + // This will happen for static value changes where a property went + // from being an object to any other type like string or number + // in such a case we want to delete all nested paths of the + // original lhs object + + result = Object.keys(difference.lhs).map((diffKey) => { + const path = `${propertyPath}.${diffKey}`; + return { + event: DataTreeDiffEvent.DELETE, + payload: { + propertyPath: path, + }, + }; + }); + } else if ( + !isTrueObject(difference.lhs) && + isTrueObject(difference.rhs) + ) { + // This will happen for static value changes where a property went + // from being any other type like string or number to an object + // in such a case we want to add all nested paths of the + // new rhs object + result = Object.keys(difference.rhs).map((diffKey) => { + const path = `${propertyPath}.${diffKey}`; + return { + event: DataTreeDiffEvent.NEW, + payload: { + propertyPath: path, + }, + }; + }); + } + break; + } + case "A": { + return translateDiffEventToDataTreeDiffEvent({ + ...difference.item, + path: [...difference.path, difference.index], + }); + } + default: { + break; + } + } + return result; +}; + +/* + Table1.selectedRow + Table1.selectedRow.email: ["Input1.defaultText"] + */ + +export const addDependantsOfNestedPropertyPaths = ( + parentPaths: Array, + inverseMap: DependencyMap, +): Set => { + const withNestedPaths: Set = new Set(); + const dependantNodes = Object.keys(inverseMap); + parentPaths.forEach((propertyPath) => { + withNestedPaths.add(propertyPath); + dependantNodes + .filter((dependantNodePath) => + isChildPropertyPath(propertyPath, dependantNodePath), + ) + .forEach((dependantNodePath) => { + inverseMap[dependantNodePath].forEach((path) => { + withNestedPaths.add(path); + }); + }); + }); + return withNestedPaths; +}; + +export function isWidget(entity: DataTreeEntity): entity is DataTreeWidget { + return ( + typeof entity === "object" && + "ENTITY_TYPE" in entity && + entity.ENTITY_TYPE === ENTITY_TYPE.WIDGET + ); +} + +export function isAction(entity: DataTreeEntity): entity is DataTreeAction { + return ( + typeof entity === "object" && + "ENTITY_TYPE" in entity && + entity.ENTITY_TYPE === ENTITY_TYPE.ACTION + ); +} + +export function isAppsmithEntity( + entity: DataTreeEntity, +): entity is DataTreeAppsmith { + return ( + typeof entity === "object" && + "ENTITY_TYPE" in entity && + entity.ENTITY_TYPE === ENTITY_TYPE.APPSMITH + ); +} + +// We need to remove functions from data tree to avoid any unexpected identifier while JSON parsing +// Check issue https://github.com/appsmithorg/appsmith/issues/719 +export const removeFunctions = (value: any) => { + if (_.isFunction(value)) { + return "Function call"; + } else if (_.isObject(value)) { + return JSON.parse( + JSON.stringify(value, (_, v) => + typeof v === "bigint" ? v.toString() : v, + ), + ); + } else { + return value; + } +}; + +export const makeParentsDependOnChildren = ( + depMap: DependencyMap, +): DependencyMap => { + //return depMap; + // Make all parents depend on child + Object.keys(depMap).forEach((key) => { + depMap = makeParentsDependOnChild(depMap, key); + depMap[key].forEach((path) => { + depMap = makeParentsDependOnChild(depMap, path); + }); + }); + return depMap; +}; + +export const makeParentsDependOnChild = ( + depMap: DependencyMap, + child: string, +): DependencyMap => { + const result: DependencyMap = depMap; + let curKey = child; + + let matches: Array | null; + // Note: The `=` is intentional + // Stops looping when match is null + while ((matches = curKey.match(IMMEDIATE_PARENT_REGEX)) !== null) { + const parentKey = matches[1]; + // Todo: switch everything to set. + const existing = new Set(result[parentKey] || []); + existing.add(curKey); + result[parentKey] = Array.from(existing); + curKey = parentKey; + } + return result; +}; + +// The idea is to find the immediate parents of the property paths +// e.g. For Table1.selectedRow.email, the parent is Table1.selectedRow +export const getImmediateParentsOfPropertyPaths = ( + propertyPaths: Array, +): Array => { + // Use a set to ensure that we dont have duplicates + const parents: Set = new Set(); + + propertyPaths.forEach((path) => { + const matches = path.match(IMMEDIATE_PARENT_REGEX); + + if (matches !== null) { + parents.add(matches[1]); + } + }); + + return Array.from(parents); +}; + +export function validateWidgetProperty( + config: ValidationConfig, + value: unknown, + props: Record, +) { + if (!config) { + return { + isValid: true, + parsed: value, + }; + } + return validate(config, value, props); +} + +export function getValidatedTree(tree: DataTree) { + return Object.keys(tree).reduce((tree, entityKey: string) => { + const entity = tree[entityKey] as DataTreeWidget; + if (!isWidget(entity)) { + return tree; + } + const parsedEntity = { ...entity }; + Object.entries(entity.validationPaths).forEach(([property, validation]) => { + const value = _.get(entity, property); + // Pass it through parse + const { isValid, message, parsed, transformed } = validateWidgetProperty( + validation, + value, + entity, + ); + _.set(parsedEntity, property, parsed); + const evaluatedValue = isValid + ? parsed + : _.isUndefined(transformed) + ? value + : transformed; + const safeEvaluatedValue = removeFunctions(evaluatedValue); + _.set( + parsedEntity, + getEvalValuePath(`${entityKey}.${property}`, false), + safeEvaluatedValue, + ); + if (!isValid) { + addErrorToEntityProperty( + [ + { + errorType: PropertyEvaluationErrorType.VALIDATION, + errorMessage: message || "", + severity: Severity.ERROR, + raw: value, + }, + ], + tree, + getEvalErrorPath(`${entityKey}.${property}`, false), + ); + } + }); + return { ...tree, [entityKey]: parsedEntity }; + }, tree); +} + +export const getAllPaths = ( + records: any, + curKey = "", + result: Record = {}, +): Record => { + // Add the key if it exists + if (curKey) result[curKey] = true; + + if (Array.isArray(records)) { + for (let i = 0; i < records.length; i++) { + const tempKey = curKey ? `${curKey}[${i}]` : `${i}`; + getAllPaths(records[i], tempKey, result); + } + } else if (typeof records === "object") { + for (const key in records) { + const tempKey = curKey ? `${curKey}.${key}` : `${key}`; + getAllPaths(records[key], tempKey, result); + } + } + return result; +}; +export const trimDependantChangePaths = ( + changePaths: Set, + dependencyMap: DependencyMap, +): Array => { + const trimmedPaths: any[] = []; + for (const path of changePaths) { + let foundADependant = false; + if (path in dependencyMap) { + const dependants = dependencyMap[path]; + for (const dependantPath of dependants) { + if (changePaths.has(dependantPath)) { + foundADependant = true; + break; + } + } + } + if (!foundADependant) { + trimmedPaths.push(path); + } + } + return trimmedPaths; +}; + +export const addFunctions = (dataTree: Readonly): DataTree => { + const withFunction: DataTree = _.cloneDeep(dataTree); + withFunction.actionPaths = []; + Object.keys(withFunction).forEach((entityName) => { + const entity = withFunction[entityName]; + if (isAction(entity)) { + const runFunction = function( + this: DataTreeAction, + onSuccess: string, + onError: string, + params = "", + ) { + return { + type: "RUN_ACTION", + payload: { + actionId: this.actionId, + onSuccess: onSuccess ? `{{${onSuccess.toString()}}}` : "", + onError: onError ? `{{${onError.toString()}}}` : "", + params, + }, + }; + }; + _.set(withFunction, `${entityName}.run`, runFunction); + withFunction.actionPaths && + withFunction.actionPaths.push(`${entityName}.run`); + } + }); + withFunction.navigateTo = function( + pageNameOrUrl: string, + params: Record, + target?: string, + ) { + return { + type: "NAVIGATE_TO", + payload: { pageNameOrUrl, params, target }, + }; + }; + withFunction.actionPaths.push("navigateTo"); + + withFunction.showAlert = function(message: string, style: string) { + return { + type: "SHOW_ALERT", + payload: { message, style }, + }; + }; + withFunction.actionPaths.push("showAlert"); + + withFunction.showModal = function(modalName: string) { + return { + type: "SHOW_MODAL_BY_NAME", + payload: { modalName }, + }; + }; + withFunction.actionPaths.push("showModal"); + + withFunction.closeModal = function(modalName: string) { + return { + type: "CLOSE_MODAL", + payload: { modalName }, + }; + }; + withFunction.actionPaths.push("closeModal"); + + withFunction.storeValue = function( + key: string, + value: string, + persist = true, + ) { + return { + type: "STORE_VALUE", + payload: { key, value, persist }, + }; + }; + withFunction.actionPaths.push("storeValue"); + + withFunction.download = function(data: string, name: string, type: string) { + return { + type: "DOWNLOAD", + payload: { data, name, type }, + }; + }; + withFunction.actionPaths.push("download"); + + withFunction.copyToClipboard = function( + data: string, + options?: { debug?: boolean; format?: string }, + ) { + return { + type: "COPY_TO_CLIPBOARD", + payload: { + data, + options: { debug: options?.debug, format: options?.format }, + }, + }; + }; + withFunction.actionPaths.push("copyToClipboard"); + + withFunction.resetWidget = function( + widgetName: string, + resetChildren = false, + ) { + return { + type: "RESET_WIDGET_META_RECURSIVE_BY_NAME", + payload: { widgetName, resetChildren }, + }; + }; + withFunction.actionPaths.push("resetWidget"); + + return withFunction; +}; + +export function getSafeToRenderDataTree( + tree: DataTree, + widgetTypeConfigMap: WidgetTypeConfigMap, +) { + return Object.keys(tree).reduce((tree, entityKey: string) => { + const entity = tree[entityKey] as DataTreeWidget; + if (!isWidget(entity)) { + return tree; + } + const safeToRenderEntity = { ...entity }; + // Set user input values to their parsed values + Object.entries(entity.validationPaths).forEach(([property, validation]) => { + const value = _.get(entity, property); + // Pass it through parse + const { parsed } = validateWidgetProperty(validation, value, entity); + _.set(safeToRenderEntity, property, parsed); + }); + // Set derived values to undefined or else they would go as bindings + Object.keys(widgetTypeConfigMap[entity.type].derivedProperties).forEach( + (property) => { + _.set(safeToRenderEntity, property, undefined); + }, + ); + return { ...tree, [entityKey]: safeToRenderEntity }; + }, tree); +} + +export const addErrorToEntityProperty = ( + errors: EvaluationError[], + dataTree: DataTree, + path: string, +) => { + const { entityName, propertyPath } = getEntityNameAndPropertyPath(path); + const logBlackList = _.get(dataTree, `${entityName}.logBlackList`, {}); + if (propertyPath && !(propertyPath in logBlackList)) { + const existingErrors = _.get( + dataTree, + `${entityName}.${EVAL_ERROR_PATH}['${propertyPath}']`, + [], + ) as EvaluationError[]; + _.set( + dataTree, + `${entityName}.${EVAL_ERROR_PATH}['${propertyPath}']`, + existingErrors.concat(errors), + ); + } + return dataTree; +}; + +// For the times when you need to know if something truly an object like { a: 1, b: 2} +// typeof, lodash.isObject and others will return false positives for things like array, null, etc +export const isTrueObject = ( + item: unknown, +): item is Record => { + return Object.prototype.toString.call(item) === "[object Object]"; +}; + +export const isDynamicLeaf = (unEvalTree: DataTree, propertyPath: string) => { + const [entityName, ...propPathEls] = _.toPath(propertyPath); + // Framework feature: Top level items are never leaves + if (entityName === propertyPath) return false; + // Ignore if this was a delete op + if (!(entityName in unEvalTree)) return false; + + const entity = unEvalTree[entityName]; + if (!isAction(entity) && !isWidget(entity)) return false; + const relativePropertyPath = convertPathToString(propPathEls); + return relativePropertyPath in entity.bindingPaths; +}; diff --git a/app/taro/src/workers/validations.ts b/app/taro/src/workers/validations.ts new file mode 100644 index 0000000000..f95c28fd7b --- /dev/null +++ b/app/taro/src/workers/validations.ts @@ -0,0 +1,585 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ + +import { + ValidationTypes, + ValidationResponse, + Validator, +} from "../constants/WidgetValidation"; +import _, { + get, + isArray, + isObject, + isPlainObject, + isString, + toString, + uniq, +} from "lodash"; + +import dayjs from "dayjs"; +import { ValidationConfig } from "constants/PropertyControlConstants"; +import evaluate from "./evaluate"; + +import getIsSafeURL from "utils/validation/getIsSafeURL"; + +function validatePlainObject( + config: ValidationConfig, + value: Record, + props: Record +) { + if (config.params?.allowedKeys) { + let _valid = true; + const _messages: string[] = []; + config.params.allowedKeys.forEach((entry) => { + if (value.hasOwnProperty(entry.name)) { + const { isValid, message, parsed } = validate( + entry, + value[entry.name], + props + ); + + if (!isValid) { + value[entry.name] = parsed; + _valid = isValid; + message && + _messages.push( + `Value of key: ${entry.name} is invalid: ${message}` + ); + } + } else if (entry.params?.required) { + _valid = false; + _messages.push(`Missing required key: ${entry.name}`); + } + }); + if (_valid) { + return { + isValid: true, + parsed: value, + }; + } + return { + isValid: false, + parsed: config.params?.default || value, + message: _messages.join(" "), + }; + } + return { + isValid: true, + parsed: value, + }; +} + +function validateArray( + config: ValidationConfig, + value: unknown[], + props: Record +) { + const whiteList = config.params?.allowedValues; + if (whiteList) { + value.forEach((entry) => { + if (!whiteList.includes(entry)) { + return { + isValid: false, + parsed: value, + message: `Disallowed value: ${entry}`, + }; + } + }); + } + const children = config.params?.children; + let _isValid = true; + const _messages: string[] = []; + if (children) { + value.forEach((entry, index) => { + const validation = validate(children, entry, props); + if (!validation.isValid) { + _isValid = false; + _messages.push( + `Invalid entry at index: ${index}. ${validation.message}` + ); + } + }); + } + if (config.params?.unique) { + if (isArray(config.params?.unique)) { + for (const param of config.params?.unique) { + const shouldBeUnique = value.map((entry) => + get(entry, param as string, "") + ); + if (uniq(shouldBeUnique).length !== value.length) { + _isValid = false; + _messages.push( + `Array entry path:${param} must be unique. Duplicate values found` + ); + break; + } + } + } else if ( + uniq(value.map((entry) => JSON.stringify(entry))).length !== value.length + ) { + _isValid = false; + _messages.push(`Array must be unique. Duplicate values found`); + } + } + return { isValid: _isValid, parsed: value, message: _messages.join(" ") }; +} + +export const validate = ( + config: ValidationConfig, + value: unknown, + props: Record +) => { + const _result = VALIDATORS[config.type as ValidationTypes]( + config, + value, + props + ); + return _result; +}; + +export const WIDGET_TYPE_VALIDATION_ERROR = + "This value does not evaluate to type"; // TODO: Lot's of changes in validations.ts file + +export const VALIDATORS: Record = { + [ValidationTypes.TEXT]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + if (value === undefined || value === null) { + if (config.params && config.params.required) { + return { + isValid: false, + parsed: config.params?.default || "", + message: `${WIDGET_TYPE_VALIDATION_ERROR} "string"`, + }; + } + return { + isValid: true, + parsed: config.params?.default || "", + }; + } + let parsed = value; + + if (isObject(value)) { + return { + isValid: false, + parsed: JSON.stringify(value, null, 2), + message: `${WIDGET_TYPE_VALIDATION_ERROR} "string"`, + }; + } + + const isValid = isString(parsed); + if (!isValid) { + try { + parsed = toString(parsed); + } catch (e) { + return { + isValid: false, + parsed: config.params?.default || "", + message: `${WIDGET_TYPE_VALIDATION_ERROR} "string"`, + }; + } + } + if (config.params?.allowedValues) { + if (!config.params?.allowedValues.includes((parsed as string).trim())) { + return { + parsed: config.params?.default || "", + message: "Value is not allowed", + isValid: false, + }; + } + } + + if (config.params?.regex && !config.params?.regex.test(parsed as string)) { + return { + parsed: config.params?.default || "", + message: `Value does not match expected regex: ${config.params?.regex.source}`, + isValid: false, + }; + } + + return { + isValid: true, + parsed, + }; + }, + // TODO(abhinav): The original validation does not make sense fix this. + [ValidationTypes.REGEX]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + const { isValid, message, parsed } = VALIDATORS[ValidationTypes.TEXT]( + config, + value, + props + ); + + if (!isValid) { + return { + isValid: false, + parsed: new RegExp(parsed), + message: `${WIDGET_TYPE_VALIDATION_ERROR} "regex"`, + }; + } + + return { isValid, parsed, message }; + }, + [ValidationTypes.NUMBER]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + if (value === undefined || value === null) { + if (config.params?.required) { + return { + isValid: false, + parsed: config.params?.default || 0, + message: "This value is required", + }; + } + return { + isValid: true, + parsed: value, + }; + } + if (!Number.isFinite(value) && !isString(value)) { + return { + isValid: false, + parsed: config.params?.default || 0, + message: `${WIDGET_TYPE_VALIDATION_ERROR} "number"`, + }; + } + + // check for min and max limits + let parsed: number = value as number; + if (isString(value)) { + if (/^\d+\.?\d*$/.test(value)) { + parsed = Number(value); + } else { + return { + isValid: false, + parsed: config.params?.default || 0, + message: `${WIDGET_TYPE_VALIDATION_ERROR} "number"`, + }; + } + } + + if ( + config.params?.min !== undefined && + Number.isFinite(config.params.min) + ) { + if (parsed < Number(config.params.min)) { + return { + isValid: false, + parsed, + message: `Minimum allowed value: ${config.params.min}`, + }; + } + } + + if ( + config.params?.max !== undefined && + Number.isFinite(config.params.max) + ) { + if (parsed > Number(config.params.max)) { + return { + isValid: false, + parsed, + message: `Maximum allowed value: ${config.params.max}`, + }; + } + } + if (config.params?.natural && (parsed < 0 || !Number.isInteger(parsed))) { + return { + isValid: false, + parsed, + message: `Value should be a positive integer`, + }; + } + + return { + isValid: true, + parsed, + }; + }, + [ValidationTypes.BOOLEAN]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + if (value === undefined || value === null) { + if (config.params && config.params.required) { + return { + isValid: false, + parsed: !!config.params?.default, + message: `${WIDGET_TYPE_VALIDATION_ERROR} "boolean"`, + }; + } + return { isValid: true, parsed: config.params?.default || value }; + } + const isABoolean = value === true || value === false; + const isStringTrueFalse = value === "true" || value === "false"; + const isValid = isABoolean || isStringTrueFalse; + + let parsed = value; + if (isStringTrueFalse) parsed = value !== "false"; + + if (!isValid) { + return { + isValid: false, + parsed: config.params?.default || false, + message: `${WIDGET_TYPE_VALIDATION_ERROR} "boolean"`, + }; + } + + return { isValid, parsed }; + }, + [ValidationTypes.OBJECT]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + if ( + value === undefined || + value === null || + (isString(value) && value.trim().length === 0) + ) { + if (config.params && config.params.required) { + return { + isValid: false, + parsed: config.params?.default || {}, + message: `${WIDGET_TYPE_VALIDATION_ERROR}: Object`, + }; + } + return { + isValid: true, + parsed: config.params?.default || value, + }; + } + + if (isPlainObject(value)) { + return validatePlainObject( + config, + value as Record, + props + ); + } + + try { + const result = { parsed: JSON.parse(value as string), isValid: true }; + if (isPlainObject(result.parsed)) { + return validatePlainObject(config, result.parsed, props); + } + return { + isValid: false, + parsed: config.params?.default || {}, + message: `${WIDGET_TYPE_VALIDATION_ERROR}: Object`, + }; + } catch (e) { + return { + isValid: false, + parsed: config.params?.default || {}, + message: `${WIDGET_TYPE_VALIDATION_ERROR}: Object`, + }; + } + }, + [ValidationTypes.ARRAY]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + const invalidResponse = { + isValid: false, + parsed: config.params?.default || [], + message: `${WIDGET_TYPE_VALIDATION_ERROR} Array`, + }; + if (value === undefined || value === null) { + if (config.params && config.params.required) { + invalidResponse.message = + "This property is required for the widget to function correctly"; + return invalidResponse; + } + return { + isValid: true, + parsed: value, + }; + } + + if (isString(value)) { + try { + const _value = JSON.parse(value); + if (Array.isArray(_value)) { + const result = validateArray(config, _value, props); + return result; + } + } catch (e) { + return invalidResponse; + } + } + + if (Array.isArray(value)) { + return validateArray(config, value, props); + } + + return invalidResponse; + }, + [ValidationTypes.OBJECT_ARRAY]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + const invalidResponse = { + isValid: false, + parsed: config.params?.default || [{}], + message: `${WIDGET_TYPE_VALIDATION_ERROR} Array of objects`, + }; + if (value === undefined || value === null) { + if (config.params?.required) return invalidResponse; + return { isValid: true, parsed: value }; + } + if (!isString(value) && !Array.isArray(value)) { + return invalidResponse; + } + + let parsed = value; + + if (isString(value)) { + try { + parsed = JSON.parse(value); + } catch (e) { + return invalidResponse; + } + } + + if (Array.isArray(parsed)) { + if (parsed.length === 0) return invalidResponse; + parsed.forEach((entry, index) => { + if (!isPlainObject(entry)) { + return { + ...invalidResponse, + message: `Invalid object at index ${index}`, + }; + } + }); + return { isValid: true, parsed }; + } + return invalidResponse; + }, + [ValidationTypes.DATE_ISO_STRING]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + const invalidResponse = { + isValid: false, + parsed: config.params?.default || dayjs().toISOString(), + message: `${WIDGET_TYPE_VALIDATION_ERROR}: ISO 8601 date string`, + }; + if (value === undefined || value === null || !isString(value)) { + if (!config.params?.required) { + return { + isValid: true, + parsed: value, + }; + } + return invalidResponse; + } + if (isString(value)) { + if (!dayjs(value).isValid()) return invalidResponse; + + if (value === dayjs(value).toISOString()) { + return { + isValid: true, + parsed: value, + }; + } + if (dayjs(value).isValid()) + return { isValid: true, parsed: dayjs(value).toISOString() }; + } + return invalidResponse; + }, + [ValidationTypes.FUNCTION]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + const invalidResponse = { + isValid: false, + parsed: undefined, + message: "Failed to validate", + }; + if (config.params?.fnString && isString(config.params?.fnString)) { + try { + const { result } = evaluate(config.params.fnString, {}, [ + value, + props, + _, + dayjs, + ]); + return result; + } catch (e) { + console.error("Validation function error: ", { e }); + } + } + return invalidResponse; + }, + [ValidationTypes.IMAGE_URL]: ( + config: ValidationConfig, + value: unknown, + props: Record + ): ValidationResponse => { + const invalidResponse = { + isValid: false, + parsed: config.params?.default || "", + message: `${WIDGET_TYPE_VALIDATION_ERROR}: base64 string or data uri or URL`, + }; + const base64Regex = + /^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/; + const base64ImageRegex = /^data:image\/.*;base64/; + const imageUrlRegex = + /(http(s?):)([/|.|\w|\s|-])*\.(?:jpeg|jpg|gif|png)??(?:&?[^=&]*=[^=&]*)*/; + if ( + value === undefined || + value === null || + (isString(value) && value.trim().length === 0) + ) { + if (config.params && config.params.required) return invalidResponse; + return { isValid: true, parsed: value }; + } + if (isString(value)) { + if (imageUrlRegex.test(value.trim())) { + return { isValid: true, parsed: value.trim() }; + } + if (base64ImageRegex.test(value)) { + return { + isValid: true, + parsed: value, + }; + } + if (base64Regex.test(value) && btoa(atob(value)) === value) { + return { isValid: true, parsed: `data:image/png;base64,${value}` }; + } + } + return invalidResponse; + }, + [ValidationTypes.SAFE_URL]: ( + config: ValidationConfig, + value: unknown + ): ValidationResponse => { + const invalidResponse = { + isValid: false, + parsed: config?.params?.default || "", + message: `${WIDGET_TYPE_VALIDATION_ERROR}: URL`, + }; + + if (typeof value === "string" && getIsSafeURL(value)) { + return { + isValid: true, + parsed: value, + }; + } else { + return invalidResponse; + } + }, +}; diff --git a/app/taro/tsconfig.json b/app/taro/tsconfig.json new file mode 100644 index 0000000000..471ac05d96 --- /dev/null +++ b/app/taro/tsconfig.json @@ -0,0 +1,31 @@ +{ + "compilerOptions": { + "target": "es2017", + "module": "commonjs", + "removeComments": false, + "preserveConstEnums": true, + "moduleResolution": "node", + "experimentalDecorators": true, + "noImplicitAny": false, + "allowSyntheticDefaultImports": true, + "outDir": "lib", + "noUnusedLocals": true, + "noUnusedParameters": true, + "strictNullChecks": true, + "sourceMap": true, + "baseUrl": "./src", + "rootDir": ".", + "jsx": "react-jsx", + "allowJs": true, + "resolveJsonModule": true, + "typeRoots": [ + "node_modules/@types", + "global.d.ts" + ] + }, + "exclude": [ + "node_modules", + "dist" + ], + "compileOnSave": false +} diff --git a/app/taro/yarn.lock b/app/taro/yarn.lock new file mode 100644 index 0000000000..8a25e7117c --- /dev/null +++ b/app/taro/yarn.lock @@ -0,0 +1,13153 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.16.0", "@babel/code-frame@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/code-frame/download/@babel/code-frame-7.16.0.tgz?cache=0&sync_timestamp=1635560663383&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fcode-frame%2Fdownload%2F%40babel%2Fcode-frame-7.16.0.tgz#0dfc80309beec8411e65e706461c408b0bb9b431" + integrity sha1-DfyAMJvuyEEeZecGRhxAiwu5tDE= + dependencies: + "@babel/highlight" "^7.16.0" + +"@babel/code-frame@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/code-frame/-/code-frame-7.16.7.tgz#44416b6bd7624b998f5b1af5d470856c40138789" + integrity sha512-iAXqUn8IIeBTNd72xsFlgaXHkMBMt6y4HJp1tIaK465CWLT/fG1aqB7ykr95gHHmlBdGbFeWWfyB4NJJ0nmeIg== + dependencies: + "@babel/highlight" "^7.16.7" + +"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.14.7", "@babel/compat-data@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/compat-data/download/@babel/compat-data-7.16.0.tgz?cache=0&sync_timestamp=1635560846497&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fcompat-data%2Fdownload%2F%40babel%2Fcompat-data-7.16.0.tgz#ea269d7f78deb3a7826c39a4048eecda541ebdaa" + integrity sha1-6iadf3jes6eCbDmkBI7s2lQevao= + +"@babel/compat-data@^7.16.4", "@babel/compat-data@^7.16.8", "@babel/compat-data@^7.17.0": + version "7.17.0" + resolved "https://registry.npmmirror.com/@babel/compat-data/-/compat-data-7.17.0.tgz#86850b8597ea6962089770952075dcaabb8dba34" + integrity sha512-392byTlpGWXMv4FbyWw3sAZ/FrW/DrwqLGXpy0mbyNe9Taqv1mg9yON5/o0cnr8XYCkFTZbC1eV+c+LAROgrng== + +"@babel/compat-data@^7.9.0": + version "7.16.4" + resolved "https://registry.npmmirror.com/@babel/compat-data/download/@babel/compat-data-7.16.4.tgz?cache=0&sync_timestamp=1637102917946&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fcompat-data%2Fdownload%2F%40babel%2Fcompat-data-7.16.4.tgz#081d6bbc336ec5c2435c6346b2ae1fb98b5ac68e" + integrity sha512-1o/jo7D+kC9ZjHX5v+EHrdjl3PhxMrLSOTGsOdHJ+KL8HCaEK6ehrVL2RS6oHDZp+L7xLirLrPmQtEng769J/Q== + +"@babel/core@7.9.0": + version "7.9.0" + resolved "https://registry.npmmirror.com/@babel/core/download/@babel/core-7.9.0.tgz#ac977b538b77e132ff706f3b8a4dbad09c03c56e" + integrity sha1-rJd7U4t34TL/cG87ik260JwDxW4= + dependencies: + "@babel/code-frame" "^7.8.3" + "@babel/generator" "^7.9.0" + "@babel/helper-module-transforms" "^7.9.0" + "@babel/helpers" "^7.9.0" + "@babel/parser" "^7.9.0" + "@babel/template" "^7.8.6" + "@babel/traverse" "^7.9.0" + "@babel/types" "^7.9.0" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.1" + json5 "^2.1.2" + lodash "^4.17.13" + resolve "^1.3.2" + semver "^5.4.1" + source-map "^0.5.0" + +"@babel/core@^7.11.1", "@babel/core@^7.14.0", "@babel/core@^7.8.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/core/download/@babel/core-7.16.0.tgz#c4ff44046f5fe310525cc9eb4ef5147f0c5374d4" + integrity sha1-xP9EBG9f4xBSXMnrTvUUfwxTdNQ= + dependencies: + "@babel/code-frame" "^7.16.0" + "@babel/generator" "^7.16.0" + "@babel/helper-compilation-targets" "^7.16.0" + "@babel/helper-module-transforms" "^7.16.0" + "@babel/helpers" "^7.16.0" + "@babel/parser" "^7.16.0" + "@babel/template" "^7.16.0" + "@babel/traverse" "^7.16.0" + "@babel/types" "^7.16.0" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.2" + json5 "^2.1.2" + semver "^6.3.0" + source-map "^0.5.0" + +"@babel/generator@>=7", "@babel/generator@^7.16.0", "@babel/generator@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/generator/download/@babel/generator-7.16.0.tgz?cache=0&sync_timestamp=1635560663614&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fgenerator%2Fdownload%2F%40babel%2Fgenerator-7.16.0.tgz#d40f3d1d5075e62d3500bccb67f3daa8a95265b2" + integrity sha1-1A89HVB15i01ALzLZ/PaqKlSZbI= + dependencies: + "@babel/types" "^7.16.0" + jsesc "^2.5.1" + source-map "^0.5.0" + +"@babel/generator@^7.17.3": + version "7.17.3" + resolved "https://registry.npmmirror.com/@babel/generator/-/generator-7.17.3.tgz#a2c30b0c4f89858cb87050c3ffdfd36bdf443200" + integrity sha512-+R6Dctil/MgUsZsZAkYgK+ADNSZzJRRy0TvY65T71z/CR854xHQ1EweBYXdfT+HNeN7w0cSJJEzgxZMv40pxsg== + dependencies: + "@babel/types" "^7.17.0" + jsesc "^2.5.1" + source-map "^0.5.0" + +"@babel/helper-annotate-as-pure@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-annotate-as-pure/download/@babel/helper-annotate-as-pure-7.16.0.tgz#9a1f0ebcda53d9a2d00108c4ceace6a5d5f1f08d" + integrity sha1-mh8OvNpT2aLQAQjEzqzmpdXx8I0= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-annotate-as-pure@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.16.7.tgz#bb2339a7534a9c128e3102024c60760a3a7f3862" + integrity sha512-s6t2w/IPQVTAET1HitoowRGXooX8mCgtuP5195wD/QJPV6wYjpujCGF7JuMODVX2ZAJOf1GT6DT9MHEZvLOFSw== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-builder-binary-assignment-operator-visitor@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-builder-binary-assignment-operator-visitor/download/@babel/helper-builder-binary-assignment-operator-visitor-7.16.0.tgz#f1a686b92da794020c26582eb852e9accd0d7882" + integrity sha1-8aaGuS2nlAIMJlguuFLprM0NeII= + dependencies: + "@babel/helper-explode-assignable-expression" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helper-builder-binary-assignment-operator-visitor@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.16.7.tgz#38d138561ea207f0f69eb1626a418e4f7e6a580b" + integrity sha512-C6FdbRaxYjwVu/geKW4ZeQ0Q31AftgRcdSnZ5/jsH6BzCJbtvXvhpfkbkThYSuutZA7nCXpPR6AD9zd1dprMkA== + dependencies: + "@babel/helper-explode-assignable-expression" "^7.16.7" + "@babel/types" "^7.16.7" + +"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.14.5", "@babel/helper-compilation-targets@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-compilation-targets/download/@babel/helper-compilation-targets-7.16.0.tgz#01d615762e796c17952c29e3ede9d6de07d235a8" + integrity sha1-AdYVdi55bBeVLCnj7enW3gfSNag= + dependencies: + "@babel/compat-data" "^7.16.0" + "@babel/helper-validator-option" "^7.14.5" + browserslist "^4.16.6" + semver "^6.3.0" + +"@babel/helper-compilation-targets@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.16.7.tgz#06e66c5f299601e6c7da350049315e83209d551b" + integrity sha512-mGojBwIWcwGD6rfqgRXVlVYmPAv7eOpIemUG3dGnDdCY4Pae70ROij3XmfrH6Fa1h1aiDylpglbZyktfzyo/hA== + dependencies: + "@babel/compat-data" "^7.16.4" + "@babel/helper-validator-option" "^7.16.7" + browserslist "^4.17.5" + semver "^6.3.0" + +"@babel/helper-compilation-targets@^7.8.7": + version "7.16.3" + resolved "https://registry.npmmirror.com/@babel/helper-compilation-targets/download/@babel/helper-compilation-targets-7.16.3.tgz?cache=0&sync_timestamp=1636494857717&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelper-compilation-targets%2Fdownload%2F%40babel%2Fhelper-compilation-targets-7.16.3.tgz#5b480cd13f68363df6ec4dc8ac8e2da11363cbf0" + integrity sha512-vKsoSQAyBmxS35JUOOt+07cLc6Nk/2ljLIHwmq2/NM6hdioUaqEXq/S+nXvbvXbZkNDlWOymPanJGOc4CBjSJA== + dependencies: + "@babel/compat-data" "^7.16.0" + "@babel/helper-validator-option" "^7.14.5" + browserslist "^4.17.5" + semver "^6.3.0" + +"@babel/helper-create-class-features-plugin@^7.10.4", "@babel/helper-create-class-features-plugin@^7.10.5", "@babel/helper-create-class-features-plugin@^7.16.0", "@babel/helper-create-class-features-plugin@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-create-class-features-plugin/download/@babel/helper-create-class-features-plugin-7.16.0.tgz#090d4d166b342a03a9fec37ef4fd5aeb9c7c6a4b" + integrity sha1-CQ1NFms0KgOp/sN+9P1a65x8aks= + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-function-name" "^7.16.0" + "@babel/helper-member-expression-to-functions" "^7.16.0" + "@babel/helper-optimise-call-expression" "^7.16.0" + "@babel/helper-replace-supers" "^7.16.0" + "@babel/helper-split-export-declaration" "^7.16.0" + +"@babel/helper-create-class-features-plugin@^7.16.10", "@babel/helper-create-class-features-plugin@^7.16.7", "@babel/helper-create-class-features-plugin@^7.17.6": + version "7.17.6" + resolved "https://registry.npmmirror.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.17.6.tgz#3778c1ed09a7f3e65e6d6e0f6fbfcc53809d92c9" + integrity sha512-SogLLSxXm2OkBbSsHZMM4tUi8fUzjs63AT/d0YQIzr6GSd8Hxsbk2KYDX0k0DweAzGMj/YWeiCsorIdtdcW8Eg== + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.7" + "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-function-name" "^7.16.7" + "@babel/helper-member-expression-to-functions" "^7.16.7" + "@babel/helper-optimise-call-expression" "^7.16.7" + "@babel/helper-replace-supers" "^7.16.7" + "@babel/helper-split-export-declaration" "^7.16.7" + +"@babel/helper-create-regexp-features-plugin@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-create-regexp-features-plugin/download/@babel/helper-create-regexp-features-plugin-7.16.0.tgz#06b2348ce37fccc4f5e18dcd8d75053f2a7c44ff" + integrity sha1-BrI0jON/zMT14Y3NjXUFPyp8RP8= + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + regexpu-core "^4.7.1" + +"@babel/helper-create-regexp-features-plugin@^7.16.7": + version "7.17.0" + resolved "https://registry.npmmirror.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.17.0.tgz#1dcc7d40ba0c6b6b25618997c5dbfd310f186fe1" + integrity sha512-awO2So99wG6KnlE+TPs6rn83gCz5WlEePJDTnLEqbchMVrBeAujURVphRdigsk094VhvZehFoNOihSlcBjwsXA== + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.7" + regexpu-core "^5.0.1" + +"@babel/helper-define-polyfill-provider@^0.2.4": + version "0.2.4" + resolved "https://registry.npmmirror.com/@babel/helper-define-polyfill-provider/download/@babel/helper-define-polyfill-provider-0.2.4.tgz#8867aed79d3ea6cade40f801efb7ac5c66916b10" + integrity sha1-iGeu150+psreQPgB77esXGaRaxA= + dependencies: + "@babel/helper-compilation-targets" "^7.13.0" + "@babel/helper-module-imports" "^7.12.13" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/traverse" "^7.13.0" + debug "^4.1.1" + lodash.debounce "^4.0.8" + resolve "^1.14.2" + semver "^6.1.2" + +"@babel/helper-define-polyfill-provider@^0.3.1": + version "0.3.1" + resolved "https://registry.npmmirror.com/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.3.1.tgz#52411b445bdb2e676869e5a74960d2d3826d2665" + integrity sha512-J9hGMpJQmtWmj46B3kBHmL38UhJGhYX7eqkcq+2gsstyYt341HmPeWspihX43yVRA0mS+8GGk2Gckc7bY/HCmA== + dependencies: + "@babel/helper-compilation-targets" "^7.13.0" + "@babel/helper-module-imports" "^7.12.13" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/traverse" "^7.13.0" + debug "^4.1.1" + lodash.debounce "^4.0.8" + resolve "^1.14.2" + semver "^6.1.2" + +"@babel/helper-environment-visitor@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.16.7.tgz#ff484094a839bde9d89cd63cba017d7aae80ecd7" + integrity sha512-SLLb0AAn6PkUeAfKJCCOl9e1R53pQlGAfc4y4XuMRZfqeMYLE0dM1LMhqbGAlGQY0lfw5/ohoYWAe9V1yibRag== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-explode-assignable-expression@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-explode-assignable-expression/download/@babel/helper-explode-assignable-expression-7.16.0.tgz#753017337a15f46f9c09f674cff10cee9b9d7778" + integrity sha1-dTAXM3oV9G+cCfZ0z/EM7pudd3g= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-explode-assignable-expression@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.16.7.tgz#12a6d8522fdd834f194e868af6354e8650242b7a" + integrity sha512-KyUenhWMC8VrxzkGP0Jizjo4/Zx+1nNZhgocs+gLzyZyB8SHidhoq9KK/8Ato4anhwsivfkBLftky7gvzbZMtQ== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-function-name@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-function-name/download/@babel/helper-function-name-7.16.0.tgz?cache=0&sync_timestamp=1635560944177&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelper-function-name%2Fdownload%2F%40babel%2Fhelper-function-name-7.16.0.tgz#b7dd0797d00bbfee4f07e9c4ea5b0e30c8bb1481" + integrity sha1-t90Hl9ALv+5PB+nE6lsOMMi7FIE= + dependencies: + "@babel/helper-get-function-arity" "^7.16.0" + "@babel/template" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helper-function-name@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-function-name/-/helper-function-name-7.16.7.tgz#f1ec51551fb1c8956bc8dd95f38523b6cf375f8f" + integrity sha512-QfDfEnIUyyBSR3HtrtGECuZ6DAyCkYFp7GHl75vFtTnn6pjKeK0T1DB5lLkFvBea8MdaiUABx3osbgLyInoejA== + dependencies: + "@babel/helper-get-function-arity" "^7.16.7" + "@babel/template" "^7.16.7" + "@babel/types" "^7.16.7" + +"@babel/helper-get-function-arity@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-get-function-arity/download/@babel/helper-get-function-arity-7.16.0.tgz?cache=0&sync_timestamp=1635560945700&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelper-get-function-arity%2Fdownload%2F%40babel%2Fhelper-get-function-arity-7.16.0.tgz#0088c7486b29a9cb5d948b1a1de46db66e089cfa" + integrity sha1-AIjHSGspqctdlIsaHeRttm4InPo= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-get-function-arity@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.16.7.tgz#ea08ac753117a669f1508ba06ebcc49156387419" + integrity sha512-flc+RLSOBXzNzVhcLu6ujeHUrD6tANAOU5ojrRx/as+tbzf8+stUCj7+IfRRoAbEZqj/ahXEMsjhOhgeZsrnTw== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-hoist-variables@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-hoist-variables/download/@babel/helper-hoist-variables-7.16.0.tgz?cache=0&sync_timestamp=1635560943828&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelper-hoist-variables%2Fdownload%2F%40babel%2Fhelper-hoist-variables-7.16.0.tgz#4c9023c2f1def7e28ff46fc1dbcd36a39beaa81a" + integrity sha1-TJAjwvHe9+KP9G/B2802o5vqqBo= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-hoist-variables@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.16.7.tgz#86bcb19a77a509c7b77d0e22323ef588fa58c246" + integrity sha512-m04d/0Op34H5v7pbZw6pSKP7weA6lsMvfiIAMeIvkY/R4xQtBSMFEigu9QTZ2qB/9l22vsxtM8a+Q8CzD255fg== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-member-expression-to-functions@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-member-expression-to-functions/download/@babel/helper-member-expression-to-functions-7.16.0.tgz#29287040efd197c77636ef75188e81da8bccd5a4" + integrity sha1-KShwQO/Rl8d2Nu91GI6B2ovM1aQ= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-member-expression-to-functions@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.16.7.tgz#42b9ca4b2b200123c3b7e726b0ae5153924905b0" + integrity sha512-VtJ/65tYiU/6AbMTDwyoXGPKHgTsfRarivm+YbB5uAzKUyuPjgZSgAFeG87FCigc7KNHu2Pegh1XIT3lXjvz3Q== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-module-imports@^7.0.0", "@babel/helper-module-imports@^7.10.4", "@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.16.0", "@babel/helper-module-imports@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-module-imports/download/@babel/helper-module-imports-7.16.0.tgz?cache=0&sync_timestamp=1635560941965&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelper-module-imports%2Fdownload%2F%40babel%2Fhelper-module-imports-7.16.0.tgz#90538e60b672ecf1b448f5f4f5433d37e79a3ec3" + integrity sha1-kFOOYLZy7PG0SPX09UM9N+eaPsM= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-module-imports@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-module-imports/-/helper-module-imports-7.16.7.tgz#25612a8091a999704461c8a222d0efec5d091437" + integrity sha512-LVtS6TqjJHFc+nYeITRo6VLXve70xmq7wPhWTqDJusJEgGmkAACWwMiTNrvfoQo6hEhFwAIixNkvB0jPXDL8Wg== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-module-transforms@^7.16.0", "@babel/helper-module-transforms@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-module-transforms/download/@babel/helper-module-transforms-7.16.0.tgz#1c82a8dd4cb34577502ebd2909699b194c3e9bb5" + integrity sha1-HIKo3UyzRXdQLr0pCWmbGUw+m7U= + dependencies: + "@babel/helper-module-imports" "^7.16.0" + "@babel/helper-replace-supers" "^7.16.0" + "@babel/helper-simple-access" "^7.16.0" + "@babel/helper-split-export-declaration" "^7.16.0" + "@babel/helper-validator-identifier" "^7.15.7" + "@babel/template" "^7.16.0" + "@babel/traverse" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helper-module-transforms@^7.16.7": + version "7.17.6" + resolved "https://registry.npmmirror.com/@babel/helper-module-transforms/-/helper-module-transforms-7.17.6.tgz#3c3b03cc6617e33d68ef5a27a67419ac5199ccd0" + integrity sha512-2ULmRdqoOMpdvkbT8jONrZML/XALfzxlb052bldftkicAUy8AxSCkD5trDPQcwHNmolcl7wP6ehNqMlyUw6AaA== + dependencies: + "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-module-imports" "^7.16.7" + "@babel/helper-simple-access" "^7.16.7" + "@babel/helper-split-export-declaration" "^7.16.7" + "@babel/helper-validator-identifier" "^7.16.7" + "@babel/template" "^7.16.7" + "@babel/traverse" "^7.17.3" + "@babel/types" "^7.17.0" + +"@babel/helper-optimise-call-expression@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-optimise-call-expression/download/@babel/helper-optimise-call-expression-7.16.0.tgz#cecdb145d70c54096b1564f8e9f10cd7d193b338" + integrity sha1-zs2xRdcMVAlrFWT46fEM19GTszg= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-optimise-call-expression@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.16.7.tgz#a34e3560605abbd31a18546bd2aad3e6d9a174f2" + integrity sha512-EtgBhg7rd/JcnpZFXpBy0ze1YRfdm7BnBX4uKMBd3ixa3RGAE002JZB66FJyNH7g0F38U05pXmA5P8cBh7z+1w== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": + version "7.14.5" + resolved "https://registry.nlark.com/@babel/helper-plugin-utils/download/@babel/helper-plugin-utils-7.14.5.tgz#5ac822ce97eec46741ab70a517971e443a70c5a9" + integrity sha1-WsgizpfuxGdBq3ClF5ceRDpwxak= + +"@babel/helper-plugin-utils@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.16.7.tgz#aa3a8ab4c3cceff8e65eb9e73d87dc4ff320b2f5" + integrity sha512-Qg3Nk7ZxpgMrsox6HreY1ZNKdBq7K72tDSliA6dCl5f007jR4ne8iD5UzuNnCJH2xBf2BEEVGr+/OL6Gdp7RxA== + +"@babel/helper-remap-async-to-generator@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-remap-async-to-generator/download/@babel/helper-remap-async-to-generator-7.16.0.tgz#d5aa3b086e13a5fe05238ff40c3a5a0c2dab3ead" + integrity sha1-1ao7CG4Tpf4FI4/0DDpaDC2rPq0= + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-wrap-function" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helper-remap-async-to-generator@^7.16.4": + version "7.16.4" + resolved "https://registry.npmmirror.com/@babel/helper-remap-async-to-generator/download/@babel/helper-remap-async-to-generator-7.16.4.tgz?cache=0&sync_timestamp=1637103423365&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelper-remap-async-to-generator%2Fdownload%2F%40babel%2Fhelper-remap-async-to-generator-7.16.4.tgz#5d7902f61349ff6b963e07f06a389ce139fbfe6e" + integrity sha512-vGERmmhR+s7eH5Y/cp8PCVzj4XEjerq8jooMfxFdA5xVtAk9Sh4AQsrWgiErUEBjtGrBtOFKDUcWQFW4/dFwMA== + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-wrap-function" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helper-remap-async-to-generator@^7.16.8": + version "7.16.8" + resolved "https://registry.npmmirror.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.16.8.tgz#29ffaade68a367e2ed09c90901986918d25e57e3" + integrity sha512-fm0gH7Flb8H51LqJHy3HJ3wnE1+qtYR2A99K06ahwrawLdOFsCEWjZOrYricXJHoPSudNKxrMBUPEIPxiIIvBw== + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.7" + "@babel/helper-wrap-function" "^7.16.8" + "@babel/types" "^7.16.8" + +"@babel/helper-replace-supers@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-replace-supers/download/@babel/helper-replace-supers-7.16.0.tgz#73055e8d3cf9bcba8ddb55cad93fedc860f68f17" + integrity sha1-cwVejTz5vLqN21XK2T/tyGD2jxc= + dependencies: + "@babel/helper-member-expression-to-functions" "^7.16.0" + "@babel/helper-optimise-call-expression" "^7.16.0" + "@babel/traverse" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helper-replace-supers@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-replace-supers/-/helper-replace-supers-7.16.7.tgz#e9f5f5f32ac90429c1a4bdec0f231ef0c2838ab1" + integrity sha512-y9vsWilTNaVnVh6xiJfABzsNpgDPKev9HnAgz6Gb1p6UUwf9NepdlsV7VXGCftJM+jqD5f7JIEubcpLjZj5dBw== + dependencies: + "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-member-expression-to-functions" "^7.16.7" + "@babel/helper-optimise-call-expression" "^7.16.7" + "@babel/traverse" "^7.16.7" + "@babel/types" "^7.16.7" + +"@babel/helper-simple-access@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-simple-access/download/@babel/helper-simple-access-7.16.0.tgz#21d6a27620e383e37534cf6c10bba019a6f90517" + integrity sha1-IdaidiDjg+N1NM9sELugGab5BRc= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-simple-access@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-simple-access/-/helper-simple-access-7.16.7.tgz#d656654b9ea08dbb9659b69d61063ccd343ff0f7" + integrity sha512-ZIzHVyoeLMvXMN/vok/a4LWRy8G2v205mNP0XOuf9XRLyX5/u9CnVulUtDgUTama3lT+bf/UqucuZjqiGuTS1g== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-skip-transparent-expression-wrappers@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-skip-transparent-expression-wrappers/download/@babel/helper-skip-transparent-expression-wrappers-7.16.0.tgz#0ee3388070147c3ae051e487eca3ebb0e2e8bb09" + integrity sha1-DuM4gHAUfDrgUeSH7KPrsOLouwk= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-split-export-declaration@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-split-export-declaration/download/@babel/helper-split-export-declaration-7.16.0.tgz?cache=0&sync_timestamp=1635560943488&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelper-split-export-declaration%2Fdownload%2F%40babel%2Fhelper-split-export-declaration-7.16.0.tgz#29672f43663e936df370aaeb22beddb3baec7438" + integrity sha1-KWcvQ2Y+k23zcKrrIr7ds7rsdDg= + dependencies: + "@babel/types" "^7.16.0" + +"@babel/helper-split-export-declaration@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.16.7.tgz#0b648c0c42da9d3920d85ad585f2778620b8726b" + integrity sha512-xbWoy/PFoxSWazIToT9Sif+jJTlrMcndIsaOKvTA6u7QEo7ilkRZpjew18/W3c7nm8fXdUDXh02VXTbZ0pGDNw== + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-validator-identifier@^7.15.7": + version "7.15.7" + resolved "https://registry.nlark.com/@babel/helper-validator-identifier/download/@babel/helper-validator-identifier-7.15.7.tgz?cache=0&sync_timestamp=1631920110587&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40babel%2Fhelper-validator-identifier%2Fdownload%2F%40babel%2Fhelper-validator-identifier-7.15.7.tgz#220df993bfe904a4a6b02ab4f3385a5ebf6e2389" + integrity sha1-Ig35k7/pBKSmsCq08zhaXr9uI4k= + +"@babel/helper-validator-identifier@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.16.7.tgz#e8c602438c4a8195751243da9031d1607d247cad" + integrity sha512-hsEnFemeiW4D08A5gUAZxLBTXpZ39P+a+DGDsHw1yxqyQ/jzFEnxf5uTEGp+3bzAbNOxU1paTgYS4ECU/IgfDw== + +"@babel/helper-validator-option@^7.12.17", "@babel/helper-validator-option@^7.14.5": + version "7.14.5" + resolved "https://registry.nlark.com/@babel/helper-validator-option/download/@babel/helper-validator-option-7.14.5.tgz#6e72a1fff18d5dfcb878e1e62f1a021c4b72d5a3" + integrity sha1-bnKh//GNXfy4eOHmLxoCHEty1aM= + +"@babel/helper-validator-option@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/helper-validator-option/-/helper-validator-option-7.16.7.tgz#b203ce62ce5fe153899b617c08957de860de4d23" + integrity sha512-TRtenOuRUVo9oIQGPC5G9DgK4743cdxvtOw0weQNpZXaS16SCBi5MNjZF8vba3ETURjZpTbVn7Vvcf2eAwFozQ== + +"@babel/helper-wrap-function@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helper-wrap-function/download/@babel/helper-wrap-function-7.16.0.tgz#b3cf318afce774dfe75b86767cd6d68f3482e57c" + integrity sha1-s88xivzndN/nW4Z2fNbWjzSC5Xw= + dependencies: + "@babel/helper-function-name" "^7.16.0" + "@babel/template" "^7.16.0" + "@babel/traverse" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helper-wrap-function@^7.16.8": + version "7.16.8" + resolved "https://registry.npmmirror.com/@babel/helper-wrap-function/-/helper-wrap-function-7.16.8.tgz#58afda087c4cd235de92f7ceedebca2c41274200" + integrity sha512-8RpyRVIAW1RcDDGTA+GpPAwV22wXCfKOoM9bet6TLkGIFTkRQSkH1nMQ5Yet4MpoXe1ZwHPVtNasc2w0uZMqnw== + dependencies: + "@babel/helper-function-name" "^7.16.7" + "@babel/template" "^7.16.7" + "@babel/traverse" "^7.16.8" + "@babel/types" "^7.16.8" + +"@babel/helpers@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/helpers/download/@babel/helpers-7.16.0.tgz?cache=0&sync_timestamp=1635560662388&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelpers%2Fdownload%2F%40babel%2Fhelpers-7.16.0.tgz#875519c979c232f41adfbd43a3b0398c2e388183" + integrity sha1-h1UZyXnCMvQa371Do7A5jC44gYM= + dependencies: + "@babel/template" "^7.16.0" + "@babel/traverse" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/helpers@^7.9.0": + version "7.16.3" + resolved "https://registry.npmmirror.com/@babel/helpers/download/@babel/helpers-7.16.3.tgz?cache=0&sync_timestamp=1636494884812&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhelpers%2Fdownload%2F%40babel%2Fhelpers-7.16.3.tgz#27fc64f40b996e7074dc73128c3e5c3e7f55c43c" + integrity sha512-Xn8IhDlBPhvYTvgewPKawhADichOsbkZuzN7qz2BusOM0brChsyXMDJvldWaYMMUNiCQdQzNEioXTp3sC8Nt8w== + dependencies: + "@babel/template" "^7.16.0" + "@babel/traverse" "^7.16.3" + "@babel/types" "^7.16.0" + +"@babel/highlight@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/highlight/download/@babel/highlight-7.16.0.tgz?cache=0&sync_timestamp=1635560940881&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fhighlight%2Fdownload%2F%40babel%2Fhighlight-7.16.0.tgz#6ceb32b2ca4b8f5f361fb7fd821e3fddf4a1725a" + integrity sha1-bOsysspLj182H7f9gh4/3fShclo= + dependencies: + "@babel/helper-validator-identifier" "^7.15.7" + chalk "^2.0.0" + js-tokens "^4.0.0" + +"@babel/highlight@^7.16.7": + version "7.16.10" + resolved "https://registry.npmmirror.com/@babel/highlight/-/highlight-7.16.10.tgz#744f2eb81579d6eea753c227b0f570ad785aba88" + integrity sha512-5FnTQLSLswEj6IkgVw5KusNUUFY9ZGqe/TRFnP/BKYHYgfh7tc+C7mwiy95/yNP7Dh9x580Vv8r7u7ZfTBFxdw== + dependencies: + "@babel/helper-validator-identifier" "^7.16.7" + chalk "^2.0.0" + js-tokens "^4.0.0" + +"@babel/parser@^7.16.0", "@babel/parser@^7.7.0": + version "7.16.2" + resolved "https://registry.npmmirror.com/@babel/parser/download/@babel/parser-7.16.2.tgz#3723cd5c8d8773eef96ce57ea1d9b7faaccd12ac" + integrity sha1-NyPNXI2Hc+75bOV+odm3+qzNEqw= + +"@babel/parser@^7.16.3", "@babel/parser@^7.9.0": + version "7.16.4" + resolved "https://registry.npmmirror.com/@babel/parser/download/@babel/parser-7.16.4.tgz?cache=0&sync_timestamp=1637102910055&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fparser%2Fdownload%2F%40babel%2Fparser-7.16.4.tgz#d5f92f57cf2c74ffe9b37981c0e72fee7311372e" + integrity sha512-6V0qdPUaiVHH3RtZeLIsc+6pDhbYzHR8ogA8w+f+Wc77DuXto19g2QUwveINoS34Uw+W8/hQDGJCx+i4n7xcng== + +"@babel/parser@^7.16.7", "@babel/parser@^7.17.3": + version "7.17.3" + resolved "https://registry.npmmirror.com/@babel/parser/-/parser-7.17.3.tgz#b07702b982990bf6fdc1da5049a23fece4c5c3d0" + integrity sha512-7yJPvPV+ESz2IUTPbOL+YkIGyCqOyNIzdguKQuJGnH7bg1WTIifuM21YqokFt/THWh1AkCRn9IgoykTRCBVpzA== + +"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.16.0": + version "7.16.2" + resolved "https://registry.npmmirror.com/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/download/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.16.2.tgz?cache=0&sync_timestamp=1635837362783&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-bugfix-safari-id-destructuring-collision-in-function-expression%2Fdownload%2F%40babel%2Fplugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.16.2.tgz#2977fca9b212db153c195674e57cfab807733183" + integrity sha1-KXf8qbIS2xU8GVZ05Xz6uAdzMYM= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.16.7.tgz#4eda6d6c2a0aa79c70fa7b6da67763dfe2141050" + integrity sha512-anv/DObl7waiGEnC24O9zqL0pSuI9hljihqiDuFHC8d7/bjr/4RLGPWuc8rYOff/QPzbEPSkzG8wGG9aDuhHRg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/download/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.16.0.tgz#358972eaab006f5eb0826183b0c93cbcaf13e1e2" + integrity sha1-NYly6qsAb16wgmGDsMk8vK8T4eI= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" + "@babel/plugin-proposal-optional-chaining" "^7.16.0" + +"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.16.7.tgz#cc001234dfc139ac45f6bcf801866198c8c72ff9" + integrity sha512-di8vUHRdf+4aJ7ltXhaDbPoszdkh59AQtJM5soLsuHpQJdFQZOA4uGj0V2u/CZ8bJ/u8ULDL5yq6FO/bCXnKHw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" + "@babel/plugin-proposal-optional-chaining" "^7.16.7" + +"@babel/plugin-proposal-async-generator-functions@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-async-generator-functions/download/@babel/plugin-proposal-async-generator-functions-7.16.0.tgz#11425d47a60364352f668ad5fbc1d6596b2c5caf" + integrity sha1-EUJdR6YDZDUvZorV+8HWWWssXK8= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-remap-async-to-generator" "^7.16.0" + "@babel/plugin-syntax-async-generators" "^7.8.4" + +"@babel/plugin-proposal-async-generator-functions@^7.16.8": + version "7.16.8" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.16.8.tgz#3bdd1ebbe620804ea9416706cd67d60787504bc8" + integrity sha512-71YHIvMuiuqWJQkebWJtdhQTfd4Q4mF76q2IX37uZPkG9+olBxsX+rH1vkhFto4UeJZ9dPY2s+mDvhDm1u2BGQ== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-remap-async-to-generator" "^7.16.8" + "@babel/plugin-syntax-async-generators" "^7.8.4" + +"@babel/plugin-proposal-async-generator-functions@^7.8.3": + version "7.16.4" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-async-generator-functions/download/@babel/plugin-proposal-async-generator-functions-7.16.4.tgz?cache=0&sync_timestamp=1637103364027&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-proposal-async-generator-functions%2Fdownload%2F%40babel%2Fplugin-proposal-async-generator-functions-7.16.4.tgz#e606eb6015fec6fa5978c940f315eae4e300b081" + integrity sha512-/CUekqaAaZCQHleSK/9HajvcD/zdnJiKRiuUFq8ITE+0HsPzquf53cpFiqAwl/UfmJbR6n5uGPQSPdrmKOvHHg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-remap-async-to-generator" "^7.16.4" + "@babel/plugin-syntax-async-generators" "^7.8.4" + +"@babel/plugin-proposal-class-properties@7.10.4": + version "7.10.4" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-class-properties/download/@babel/plugin-proposal-class-properties-7.10.4.tgz?cache=0&sync_timestamp=1635566517277&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-proposal-class-properties%2Fdownload%2F%40babel%2Fplugin-proposal-class-properties-7.10.4.tgz#a33bf632da390a59c7a8c570045d1115cd778807" + integrity sha1-ozv2Mto5ClnHqMVwBF0RFc13iAc= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.10.4" + "@babel/helper-plugin-utils" "^7.10.4" + +"@babel/plugin-proposal-class-properties@7.8.3": + version "7.8.3" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-class-properties/download/@babel/plugin-proposal-class-properties-7.8.3.tgz?cache=0&sync_timestamp=1635566517277&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-proposal-class-properties%2Fdownload%2F%40babel%2Fplugin-proposal-class-properties-7.8.3.tgz#5e06654af5cd04b608915aada9b2a6788004464e" + integrity sha1-XgZlSvXNBLYIkVqtqbKmeIAERk4= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + +"@babel/plugin-proposal-class-properties@^7.0.0", "@babel/plugin-proposal-class-properties@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-class-properties/download/@babel/plugin-proposal-class-properties-7.16.0.tgz?cache=0&sync_timestamp=1635566517277&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-proposal-class-properties%2Fdownload%2F%40babel%2Fplugin-proposal-class-properties-7.16.0.tgz#c029618267ddebc7280fa286e0f8ca2a278a2d1a" + integrity sha1-wClhgmfd68coD6KG4PjKKieKLRo= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-proposal-class-properties@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.16.7.tgz#925cad7b3b1a2fcea7e59ecc8eb5954f961f91b0" + integrity sha512-IobU0Xme31ewjYOShSIqd/ZGM/r/cuOz2z0MDbNrhF5FW+ZVgi0f2lyeoj9KFPDOAqsYxmLWZte1WOwlvY9aww== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-proposal-class-static-block@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-class-static-block/download/@babel/plugin-proposal-class-static-block-7.16.0.tgz#5296942c564d8144c83eea347d0aa8a0b89170e7" + integrity sha1-UpaULFZNgUTIPuo0fQqooLiRcOc= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + +"@babel/plugin-proposal-class-static-block@^7.16.7": + version "7.17.6" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-class-static-block/-/plugin-proposal-class-static-block-7.17.6.tgz#164e8fd25f0d80fa48c5a4d1438a6629325ad83c" + integrity sha512-X/tididvL2zbs7jZCeeRJ8167U/+Ac135AM6jCAx6gYXDUviZV5Ku9UDvWS2NCuWlFjIRXklYhwo6HhAC7ETnA== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.17.6" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + +"@babel/plugin-proposal-decorators@7.10.5": + version "7.10.5" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-decorators/download/@babel/plugin-proposal-decorators-7.10.5.tgz?cache=0&sync_timestamp=1635578334765&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-proposal-decorators%2Fdownload%2F%40babel%2Fplugin-proposal-decorators-7.10.5.tgz#42898bba478bc4b1ae242a703a953a7ad350ffb4" + integrity sha1-QomLukeLxLGuJCpwOpU6etNQ/7Q= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.10.5" + "@babel/helper-plugin-utils" "^7.10.4" + "@babel/plugin-syntax-decorators" "^7.10.4" + +"@babel/plugin-proposal-decorators@7.8.3": + version "7.8.3" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-decorators/download/@babel/plugin-proposal-decorators-7.8.3.tgz?cache=0&sync_timestamp=1637103539282&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-proposal-decorators%2Fdownload%2F%40babel%2Fplugin-proposal-decorators-7.8.3.tgz#2156860ab65c5abf068c3f67042184041066543e" + integrity sha1-IVaGCrZcWr8GjD9nBCGEBBBmVD4= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-decorators" "^7.8.3" + +"@babel/plugin-proposal-dynamic-import@^7.16.0", "@babel/plugin-proposal-dynamic-import@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-dynamic-import/download/@babel/plugin-proposal-dynamic-import-7.16.0.tgz#783eca61d50526202f9b296095453977e88659f1" + integrity sha1-eD7KYdUFJiAvmylglUU5d+iGWfE= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + +"@babel/plugin-proposal-dynamic-import@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.16.7.tgz#c19c897eaa46b27634a00fee9fb7d829158704b2" + integrity sha512-I8SW9Ho3/8DRSdmDdH3gORdyUuYnk1m4cMxUAdu5oy4n3OfN8flDEH+d60iG7dUfi0KkYwSvoalHzzdRzpWHTg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + +"@babel/plugin-proposal-export-default-from@^7.0.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-export-default-from/download/@babel/plugin-proposal-export-default-from-7.16.0.tgz#f8a07008ffcb0d3de4945f3eb52022ecc28b56ad" + integrity sha1-+KBwCP/LDT3klF8+tSAi7MKLVq0= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-export-default-from" "^7.16.0" + +"@babel/plugin-proposal-export-namespace-from@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-export-namespace-from/download/@babel/plugin-proposal-export-namespace-from-7.16.0.tgz#9c01dee40b9d6b847b656aaf4a3976a71740f222" + integrity sha1-nAHe5Auda4R7ZWqvSjl2pxdA8iI= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + +"@babel/plugin-proposal-export-namespace-from@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.16.7.tgz#09de09df18445a5786a305681423ae63507a6163" + integrity sha512-ZxdtqDXLRGBL64ocZcs7ovt71L3jhC1RGSyR996svrCi3PYqHNkb3SwPJCs8RIzD86s+WPpt2S73+EHCGO+NUA== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + +"@babel/plugin-proposal-json-strings@^7.16.0", "@babel/plugin-proposal-json-strings@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-json-strings/download/@babel/plugin-proposal-json-strings-7.16.0.tgz#cae35a95ed1d2a7fa29c4dc41540b84a72e9ab25" + integrity sha1-yuNale0dKn+inE3EFUC4SnLpqyU= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-json-strings" "^7.8.3" + +"@babel/plugin-proposal-json-strings@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.16.7.tgz#9732cb1d17d9a2626a08c5be25186c195b6fa6e8" + integrity sha512-lNZ3EEggsGY78JavgbHsK9u5P3pQaW7k4axlgFLYkMd7UBsiNahCITShLjNQschPyjtO6dADrL24757IdhBrsQ== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-json-strings" "^7.8.3" + +"@babel/plugin-proposal-logical-assignment-operators@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-logical-assignment-operators/download/@babel/plugin-proposal-logical-assignment-operators-7.16.0.tgz#a711b8ceb3ffddd3ef88d3a49e86dbd3cc7db3fd" + integrity sha1-pxG4zrP/3dPviNOknobb08x9s/0= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + +"@babel/plugin-proposal-logical-assignment-operators@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.16.7.tgz#be23c0ba74deec1922e639832904be0bea73cdea" + integrity sha512-K3XzyZJGQCr00+EtYtrDjmwX7o7PLK6U9bi1nCwkQioRFVUv6dJoxbQjtWVtP+bCPy82bONBKG8NPyQ4+i6yjg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + +"@babel/plugin-proposal-nullish-coalescing-operator@^7.0.0", "@babel/plugin-proposal-nullish-coalescing-operator@^7.16.0", "@babel/plugin-proposal-nullish-coalescing-operator@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-nullish-coalescing-operator/download/@babel/plugin-proposal-nullish-coalescing-operator-7.16.0.tgz#44e1cce08fe2427482cf446a91bb451528ed0596" + integrity sha1-ROHM4I/iQnSCz0RqkbtFFSjtBZY= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + +"@babel/plugin-proposal-nullish-coalescing-operator@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.16.7.tgz#141fc20b6857e59459d430c850a0011e36561d99" + integrity sha512-aUOrYU3EVtjf62jQrCj63pYZ7k6vns2h/DQvHPWGmsJRYzWXZ6/AsfgpiRy6XiuIDADhJzP2Q9MwSMKauBQ+UQ== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + +"@babel/plugin-proposal-numeric-separator@^7.16.0", "@babel/plugin-proposal-numeric-separator@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-numeric-separator/download/@babel/plugin-proposal-numeric-separator-7.16.0.tgz#5d418e4fbbf8b9b7d03125d3a52730433a373734" + integrity sha1-XUGOT7v4ubfQMSXTpScwQzo3NzQ= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + +"@babel/plugin-proposal-numeric-separator@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.16.7.tgz#d6b69f4af63fb38b6ca2558442a7fb191236eba9" + integrity sha512-vQgPMknOIgiuVqbokToyXbkY/OmmjAzr/0lhSIbG/KmnzXPGwW/AdhdKpi+O4X/VkWiWjnkKOBiqJrTaC98VKw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + +"@babel/plugin-proposal-object-rest-spread@7.14.7": + version "7.14.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-object-rest-spread/download/@babel/plugin-proposal-object-rest-spread-7.14.7.tgz#5920a2b3df7f7901df0205974c0641b13fd9d363" + integrity sha1-WSCis99/eQHfAgWXTAZBsT/Z02M= + dependencies: + "@babel/compat-data" "^7.14.7" + "@babel/helper-compilation-targets" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.14.5" + +"@babel/plugin-proposal-object-rest-spread@7.9.0": + version "7.9.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-object-rest-spread/download/@babel/plugin-proposal-object-rest-spread-7.9.0.tgz#a28993699fc13df165995362693962ba6b061d6f" + integrity sha1-oomTaZ/BPfFlmVNiaTliumsGHW8= + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-object-rest-spread" "^7.8.0" + +"@babel/plugin-proposal-object-rest-spread@^7.0.0", "@babel/plugin-proposal-object-rest-spread@^7.16.0", "@babel/plugin-proposal-object-rest-spread@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-object-rest-spread/download/@babel/plugin-proposal-object-rest-spread-7.16.0.tgz#5fb32f6d924d6e6712810362a60e12a2609872e6" + integrity sha1-X7MvbZJNbmcSgQNipg4SomCYcuY= + dependencies: + "@babel/compat-data" "^7.16.0" + "@babel/helper-compilation-targets" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.16.0" + +"@babel/plugin-proposal-object-rest-spread@^7.16.7": + version "7.17.3" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.17.3.tgz#d9eb649a54628a51701aef7e0ea3d17e2b9dd390" + integrity sha512-yuL5iQA/TbZn+RGAfxQXfi7CNLmKi1f8zInn4IgobuCWcAb7i+zj4TYzQ9l8cEzVyJ89PDGuqxK1xZpUDISesw== + dependencies: + "@babel/compat-data" "^7.17.0" + "@babel/helper-compilation-targets" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.16.7" + +"@babel/plugin-proposal-optional-catch-binding@^7.0.0", "@babel/plugin-proposal-optional-catch-binding@^7.16.0", "@babel/plugin-proposal-optional-catch-binding@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-optional-catch-binding/download/@babel/plugin-proposal-optional-catch-binding-7.16.0.tgz#5910085811ab4c28b00d6ebffa4ab0274d1e5f16" + integrity sha1-WRAIWBGrTCiwDW6/+kqwJ00eXxY= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + +"@babel/plugin-proposal-optional-catch-binding@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.16.7.tgz#c623a430674ffc4ab732fd0a0ae7722b67cb74cf" + integrity sha512-eMOH/L4OvWSZAE1VkHbr1vckLG1WUcHGJSLqqQwl2GaUqG6QjddvrOaTUMNYiv77H5IKPMZ9U9P7EaHwvAShfA== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + +"@babel/plugin-proposal-optional-chaining@^7.0.0", "@babel/plugin-proposal-optional-chaining@^7.16.0", "@babel/plugin-proposal-optional-chaining@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-optional-chaining/download/@babel/plugin-proposal-optional-chaining-7.16.0.tgz#56dbc3970825683608e9efb55ea82c2a2d6c8dc0" + integrity sha1-VtvDlwglaDYI6e+1XqgsKi1sjcA= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + +"@babel/plugin-proposal-optional-chaining@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.16.7.tgz#7cd629564724816c0e8a969535551f943c64c39a" + integrity sha512-eC3xy+ZrUcBtP7x+sq62Q/HYd674pPTb/77XZMb5wbDPGWIdUbSr4Agr052+zaUPSb+gGRnjxXfKFvx5iMJ+DA== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + +"@babel/plugin-proposal-private-methods@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-private-methods/download/@babel/plugin-proposal-private-methods-7.16.0.tgz#b4dafb9c717e4301c5776b30d080d6383c89aff6" + integrity sha1-tNr7nHF+QwHFd2sw0IDWODyJr/Y= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-proposal-private-methods@^7.16.11": + version "7.16.11" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.16.11.tgz#e8df108288555ff259f4527dbe84813aac3a1c50" + integrity sha512-F/2uAkPlXDr8+BHpZvo19w3hLFKge+k75XUprE6jaqKxjGkSYcK+4c+bup5PdW/7W/Rpjwql7FTVEDW+fRAQsw== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.16.10" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-proposal-private-property-in-object@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-private-property-in-object/download/@babel/plugin-proposal-private-property-in-object-7.16.0.tgz#69e935b2c5c79d2488112d886f0c4e2790fee76f" + integrity sha1-aek1ssXHnSSIES2IbwxOJ5D+528= + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-create-class-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + +"@babel/plugin-proposal-private-property-in-object@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.16.7.tgz#b0b8cef543c2c3d57e59e2c611994861d46a3fce" + integrity sha512-rMQkjcOFbm+ufe3bTZLyOfsOUOxyvLXZJCTARhJr+8UMSoZmqTe1K1BgkFcrW37rAchWg57yI69ORxiWvUINuQ== + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.7" + "@babel/helper-create-class-features-plugin" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + +"@babel/plugin-proposal-unicode-property-regex@^7.16.0", "@babel/plugin-proposal-unicode-property-regex@^7.4.4", "@babel/plugin-proposal-unicode-property-regex@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-unicode-property-regex/download/@babel/plugin-proposal-unicode-property-regex-7.16.0.tgz#890482dfc5ea378e42e19a71e709728cabf18612" + integrity sha1-iQSC38XqN45C4Zpx5wlyjKvxhhI= + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-proposal-unicode-property-regex@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.16.7.tgz#635d18eb10c6214210ffc5ff4932552de08188a2" + integrity sha512-QRK0YI/40VLhNVGIjRNAAQkEHws0cswSdFFjpFyt943YmJIU1da9uW63Iu6NFV6CxTZW5eTDCrwZUstBWgp/Rg== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-syntax-async-generators@^7.8.0", "@babel/plugin-syntax-async-generators@^7.8.4": + version "7.8.4" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-async-generators/download/@babel/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" + integrity sha1-qYP7Gusuw/btBCohD2QOkOeG/g0= + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-class-properties@^7.12.13": + version "7.12.13" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-class-properties/download/@babel/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" + integrity sha1-tcmHJ0xKOoK4lxR5aTGmtTVErhA= + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-syntax-class-static-block@^7.14.5": + version "7.14.5" + resolved "https://registry.nlark.com/@babel/plugin-syntax-class-static-block/download/@babel/plugin-syntax-class-static-block-7.14.5.tgz?cache=0&sync_timestamp=1623281106862&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40babel%2Fplugin-syntax-class-static-block%2Fdownload%2F%40babel%2Fplugin-syntax-class-static-block-7.14.5.tgz#195df89b146b4b78b3bf897fd7a257c84659d406" + integrity sha1-GV34mxRrS3izv4l/16JXyEZZ1AY= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-decorators@^7.10.4", "@babel/plugin-syntax-decorators@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-syntax-decorators/download/@babel/plugin-syntax-decorators-7.16.0.tgz#eb8d811cdd1060f6ac3c00956bf3f6335505a32f" + integrity sha1-642BHN0QYPasPACVa/P2M1UFoy8= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-dynamic-import@>=7", "@babel/plugin-syntax-dynamic-import@^7.0.0", "@babel/plugin-syntax-dynamic-import@^7.8.0", "@babel/plugin-syntax-dynamic-import@^7.8.3": + version "7.8.3" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-dynamic-import/download/@babel/plugin-syntax-dynamic-import-7.8.3.tgz#62bf98b2da3cd21d626154fc96ee5b3cb68eacb3" + integrity sha1-Yr+Ysto80h1iYVT8lu5bPLaOrLM= + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-export-default-from@^7.0.0", "@babel/plugin-syntax-export-default-from@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-syntax-export-default-from/download/@babel/plugin-syntax-export-default-from-7.16.0.tgz#648520667776781f9a0da178f245fff85bc9e36f" + integrity sha1-ZIUgZnd2eB+aDaF48kX/+FvJ428= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-export-namespace-from@^7.8.3": + version "7.8.3" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-export-namespace-from/download/@babel/plugin-syntax-export-namespace-from-7.8.3.tgz#028964a9ba80dbc094c915c487ad7c4e7a66465a" + integrity sha1-AolkqbqA28CUyRXEh618TnpmRlo= + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + +"@babel/plugin-syntax-flow@^7.16.0", "@babel/plugin-syntax-flow@^7.2.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-syntax-flow/download/@babel/plugin-syntax-flow-7.16.0.tgz?cache=0&sync_timestamp=1635740643275&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-syntax-flow%2Fdownload%2F%40babel%2Fplugin-syntax-flow-7.16.0.tgz#07427021d093ed77019408221beaf0272bbcfaec" + integrity sha1-B0JwIdCT7XcBlAgiG+rwJyu8+uw= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-json-strings@^7.8.0", "@babel/plugin-syntax-json-strings@^7.8.3": + version "7.8.3" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-json-strings/download/@babel/plugin-syntax-json-strings-7.8.3.tgz#01ca21b668cd8218c9e640cb6dd88c5412b2c96a" + integrity sha1-AcohtmjNghjJ5kDLbdiMVBKyyWo= + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-jsx@^7.0.0", "@babel/plugin-syntax-jsx@^7.10.4", "@babel/plugin-syntax-jsx@^7.16.0", "@babel/plugin-syntax-jsx@^7.2.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-syntax-jsx/download/@babel/plugin-syntax-jsx-7.16.0.tgz?cache=0&sync_timestamp=1635578642050&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-syntax-jsx%2Fdownload%2F%40babel%2Fplugin-syntax-jsx-7.16.0.tgz#f9624394317365a9a88c82358d3f8471154698f1" + integrity sha1-+WJDlDFzZamojII1jT+EcRVGmPE= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-logical-assignment-operators@^7.10.4": + version "7.10.4" + resolved "https://registry.nlark.com/@babel/plugin-syntax-logical-assignment-operators/download/@babel/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" + integrity sha1-ypHvRjA1MESLkGZSusLp/plB9pk= + dependencies: + "@babel/helper-plugin-utils" "^7.10.4" + +"@babel/plugin-syntax-nullish-coalescing-operator@^7.0.0", "@babel/plugin-syntax-nullish-coalescing-operator@^7.8.0", "@babel/plugin-syntax-nullish-coalescing-operator@^7.8.3": + version "7.8.3" + resolved "https://registry.nlark.com/@babel/plugin-syntax-nullish-coalescing-operator/download/@babel/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" + integrity sha1-Fn7XA2iIYIH3S1w2xlqIwDtm0ak= + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-numeric-separator@^7.10.4", "@babel/plugin-syntax-numeric-separator@^7.8.0": + version "7.10.4" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-numeric-separator/download/@babel/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" + integrity sha1-ubBws+M1cM2f0Hun+pHA3Te5r5c= + dependencies: + "@babel/helper-plugin-utils" "^7.10.4" + +"@babel/plugin-syntax-object-rest-spread@^7.8.0", "@babel/plugin-syntax-object-rest-spread@^7.8.3": + version "7.8.3" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-object-rest-spread/download/@babel/plugin-syntax-object-rest-spread-7.8.3.tgz#60e225edcbd98a640332a2e72dd3e66f1af55871" + integrity sha1-YOIl7cvZimQDMqLnLdPmbxr1WHE= + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-optional-catch-binding@^7.8.0", "@babel/plugin-syntax-optional-catch-binding@^7.8.3": + version "7.8.3" + resolved "https://registry.npm.taobao.org/@babel/plugin-syntax-optional-catch-binding/download/@babel/plugin-syntax-optional-catch-binding-7.8.3.tgz#6111a265bcfb020eb9efd0fdfd7d26402b9ed6c1" + integrity sha1-YRGiZbz7Ag6579D9/X0mQCue1sE= + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-optional-chaining@^7.0.0", "@babel/plugin-syntax-optional-chaining@^7.8.0", "@babel/plugin-syntax-optional-chaining@^7.8.3": + version "7.8.3" + resolved "https://registry.nlark.com/@babel/plugin-syntax-optional-chaining/download/@babel/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" + integrity sha1-T2nCq5UWfgGAzVM2YT+MV4j31Io= + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-private-property-in-object@^7.14.5": + version "7.14.5" + resolved "https://registry.nlark.com/@babel/plugin-syntax-private-property-in-object/download/@babel/plugin-syntax-private-property-in-object-7.14.5.tgz?cache=0&sync_timestamp=1623280462994&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40babel%2Fplugin-syntax-private-property-in-object%2Fdownload%2F%40babel%2Fplugin-syntax-private-property-in-object-7.14.5.tgz#0dc6671ec0ea22b6e94a1114f857970cd39de1ad" + integrity sha1-DcZnHsDqIrbpShEU+FeXDNOd4a0= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-top-level-await@^7.14.5", "@babel/plugin-syntax-top-level-await@^7.8.3": + version "7.14.5" + resolved "https://registry.nlark.com/@babel/plugin-syntax-top-level-await/download/@babel/plugin-syntax-top-level-await-7.14.5.tgz?cache=0&sync_timestamp=1623280464882&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40babel%2Fplugin-syntax-top-level-await%2Fdownload%2F%40babel%2Fplugin-syntax-top-level-await-7.14.5.tgz#c1cfdadc35a646240001f06138247b741c34d94c" + integrity sha1-wc/a3DWmRiQAAfBhOCR7dBw02Uw= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-typescript@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-syntax-typescript/download/@babel/plugin-syntax-typescript-7.16.0.tgz?cache=0&sync_timestamp=1635560909037&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-syntax-typescript%2Fdownload%2F%40babel%2Fplugin-syntax-typescript-7.16.0.tgz#2feeb13d9334cc582ea9111d3506f773174179bb" + integrity sha1-L+6xPZM0zFguqREdNQb3cxdBebs= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-arrow-functions@^7.0.0", "@babel/plugin-transform-arrow-functions@^7.16.0", "@babel/plugin-transform-arrow-functions@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-arrow-functions/download/@babel/plugin-transform-arrow-functions-7.16.0.tgz#951706f8b449c834ed07bd474c0924c944b95a8e" + integrity sha1-lRcG+LRJyDTtB71HTAkkyUS5Wo4= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-arrow-functions@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.16.7.tgz#44125e653d94b98db76369de9c396dc14bef4154" + integrity sha512-9ffkFFMbvzTvv+7dTp/66xvZAWASuPD5Tl9LK3Z9vhOmANo6j94rik+5YMBt4CwHVMWLWpMsriIc2zsa3WW3xQ== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-async-to-generator@^7.0.0", "@babel/plugin-transform-async-to-generator@^7.16.0", "@babel/plugin-transform-async-to-generator@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-async-to-generator/download/@babel/plugin-transform-async-to-generator-7.16.0.tgz#df12637f9630ddfa0ef9d7a11bc414d629d38604" + integrity sha1-3xJjf5Yw3foO+dehG8QU1inThgQ= + dependencies: + "@babel/helper-module-imports" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-remap-async-to-generator" "^7.16.0" + +"@babel/plugin-transform-async-to-generator@^7.16.8": + version "7.16.8" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.16.8.tgz#b83dff4b970cf41f1b819f8b49cc0cfbaa53a808" + integrity sha512-MtmUmTJQHCnyJVrScNzNlofQJ3dLFuobYn3mwOTKHnSCMtbNsqvF71GQmJfFjdrXSsAA7iysFmYWw4bXZ20hOg== + dependencies: + "@babel/helper-module-imports" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-remap-async-to-generator" "^7.16.8" + +"@babel/plugin-transform-block-scoped-functions@^7.16.0", "@babel/plugin-transform-block-scoped-functions@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-block-scoped-functions/download/@babel/plugin-transform-block-scoped-functions-7.16.0.tgz?cache=0&sync_timestamp=1635567466710&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-block-scoped-functions%2Fdownload%2F%40babel%2Fplugin-transform-block-scoped-functions-7.16.0.tgz#c618763233ad02847805abcac4c345ce9de7145d" + integrity sha1-xhh2MjOtAoR4BavKxMNFzp3nFF0= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-block-scoped-functions@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.16.7.tgz#4d0d57d9632ef6062cdf354bb717102ee042a620" + integrity sha512-JUuzlzmF40Z9cXyytcbZEZKckgrQzChbQJw/5PuEHYeqzCsvebDx0K0jWnIIVcmmDOAVctCgnYs0pMcrYj2zJg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-block-scoping@^7.0.0", "@babel/plugin-transform-block-scoping@^7.16.0", "@babel/plugin-transform-block-scoping@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-block-scoping/download/@babel/plugin-transform-block-scoping-7.16.0.tgz?cache=0&sync_timestamp=1635567471555&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-block-scoping%2Fdownload%2F%40babel%2Fplugin-transform-block-scoping-7.16.0.tgz#bcf433fb482fe8c3d3b4e8a66b1c4a8e77d37c16" + integrity sha1-vPQz+0gv6MPTtOimaxxKjnfTfBY= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-block-scoping@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.16.7.tgz#f50664ab99ddeaee5bc681b8f3a6ea9d72ab4f87" + integrity sha512-ObZev2nxVAYA4bhyusELdo9hb3H+A56bxH3FZMbEImZFiEDYVHXQSJ1hQKFlDnlt8G9bBrCZ5ZpURZUrV4G5qQ== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-classes@^7.0.0", "@babel/plugin-transform-classes@^7.16.0", "@babel/plugin-transform-classes@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-classes/download/@babel/plugin-transform-classes-7.16.0.tgz?cache=0&sync_timestamp=1635567479103&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-classes%2Fdownload%2F%40babel%2Fplugin-transform-classes-7.16.0.tgz#54cf5ff0b2242c6573d753cd4bfc7077a8b282f5" + integrity sha1-VM9f8LIkLGVz11PNS/xwd6iygvU= + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-function-name" "^7.16.0" + "@babel/helper-optimise-call-expression" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-replace-supers" "^7.16.0" + "@babel/helper-split-export-declaration" "^7.16.0" + globals "^11.1.0" + +"@babel/plugin-transform-classes@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.16.7.tgz#8f4b9562850cd973de3b498f1218796eb181ce00" + integrity sha512-WY7og38SFAGYRe64BrjKf8OrE6ulEHtr5jEYaZMwox9KebgqPi67Zqz8K53EKk1fFEJgm96r32rkKZ3qA2nCWQ== + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.7" + "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-function-name" "^7.16.7" + "@babel/helper-optimise-call-expression" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-replace-supers" "^7.16.7" + "@babel/helper-split-export-declaration" "^7.16.7" + globals "^11.1.0" + +"@babel/plugin-transform-computed-properties@^7.0.0", "@babel/plugin-transform-computed-properties@^7.16.0", "@babel/plugin-transform-computed-properties@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-computed-properties/download/@babel/plugin-transform-computed-properties-7.16.0.tgz?cache=0&sync_timestamp=1635567483688&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-computed-properties%2Fdownload%2F%40babel%2Fplugin-transform-computed-properties-7.16.0.tgz#e0c385507d21e1b0b076d66bed6d5231b85110b7" + integrity sha1-4MOFUH0h4bCwdtZr7W1SMbhRELc= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-computed-properties@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.16.7.tgz#66dee12e46f61d2aae7a73710f591eb3df616470" + integrity sha512-gN72G9bcmenVILj//sv1zLNaPyYcOzUho2lIJBMh/iakJ9ygCo/hEF9cpGb61SCMEDxbbyBoVQxrt+bWKu5KGw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-destructuring@^7.0.0", "@babel/plugin-transform-destructuring@^7.16.0", "@babel/plugin-transform-destructuring@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-destructuring/download/@babel/plugin-transform-destructuring-7.16.0.tgz?cache=0&sync_timestamp=1635566910149&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-destructuring%2Fdownload%2F%40babel%2Fplugin-transform-destructuring-7.16.0.tgz#ad3d7e74584ad5ea4eadb1e6642146c590dee33c" + integrity sha1-rT1+dFhK1epOrbHmZCFGxZDe4zw= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-destructuring@^7.16.7": + version "7.17.3" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.17.3.tgz#c445f75819641788a27a0a3a759d9df911df6abc" + integrity sha512-dDFzegDYKlPqa72xIlbmSkly5MluLoaC1JswABGktyt6NTXSBcUuse/kWE/wvKFWJHPETpi158qJZFS3JmykJg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-dotall-regex@^7.16.0", "@babel/plugin-transform-dotall-regex@^7.4.4", "@babel/plugin-transform-dotall-regex@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-dotall-regex/download/@babel/plugin-transform-dotall-regex-7.16.0.tgz?cache=0&sync_timestamp=1635566910899&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-dotall-regex%2Fdownload%2F%40babel%2Fplugin-transform-dotall-regex-7.16.0.tgz#50bab00c1084b6162d0a58a818031cf57798e06f" + integrity sha1-ULqwDBCEthYtClioGAMc9XeY4G8= + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-dotall-regex@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.16.7.tgz#6b2d67686fab15fb6a7fd4bd895d5982cfc81241" + integrity sha512-Lyttaao2SjZF6Pf4vk1dVKv8YypMpomAbygW+mU5cYP3S5cWTfCJjG8xV6CFdzGFlfWK81IjL9viiTvpb6G7gQ== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-duplicate-keys@^7.16.0", "@babel/plugin-transform-duplicate-keys@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-duplicate-keys/download/@babel/plugin-transform-duplicate-keys-7.16.0.tgz?cache=0&sync_timestamp=1635566910658&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-duplicate-keys%2Fdownload%2F%40babel%2Fplugin-transform-duplicate-keys-7.16.0.tgz#8bc2e21813e3e89e5e5bf3b60aa5fc458575a176" + integrity sha1-i8LiGBPj6J5eW/O2CqX8RYV1oXY= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-duplicate-keys@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.16.7.tgz#2207e9ca8f82a0d36a5a67b6536e7ef8b08823c9" + integrity sha512-03DvpbRfvWIXyK0/6QiR1KMTWeT6OcQ7tbhjrXyFS02kjuX/mu5Bvnh5SDSWHxyawit2g5aWhKwI86EE7GUnTw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-exponentiation-operator@^7.0.0", "@babel/plugin-transform-exponentiation-operator@^7.16.0", "@babel/plugin-transform-exponentiation-operator@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-exponentiation-operator/download/@babel/plugin-transform-exponentiation-operator-7.16.0.tgz#a180cd2881e3533cef9d3901e48dad0fbeff4be4" + integrity sha1-oYDNKIHjUzzvnTkB5I2tD77/S+Q= + dependencies: + "@babel/helper-builder-binary-assignment-operator-visitor" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-exponentiation-operator@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.16.7.tgz#efa9862ef97e9e9e5f653f6ddc7b665e8536fe9b" + integrity sha512-8UYLSlyLgRixQvlYH3J2ekXFHDFLQutdy7FfFAMm3CPZ6q9wHCwnUyiXpQCe3gVVnQlHc5nsuiEVziteRNTXEA== + dependencies: + "@babel/helper-builder-binary-assignment-operator-visitor" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-flow-strip-types@^7.0.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-flow-strip-types/download/@babel/plugin-transform-flow-strip-types-7.16.0.tgz#edd968dc2041c1b69e451a262e948d6654a79dc2" + integrity sha1-7dlo3CBBwbaeRRomLpSNZlSnncI= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-flow" "^7.16.0" + +"@babel/plugin-transform-for-of@^7.0.0", "@babel/plugin-transform-for-of@^7.16.0", "@babel/plugin-transform-for-of@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-for-of/download/@babel/plugin-transform-for-of-7.16.0.tgz?cache=0&sync_timestamp=1635566911464&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-for-of%2Fdownload%2F%40babel%2Fplugin-transform-for-of-7.16.0.tgz#f7abaced155260e2461359bbc7c7248aca5e6bd2" + integrity sha1-96us7RVSYOJGE1m7x8ckispea9I= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-for-of@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.16.7.tgz#649d639d4617dff502a9a158c479b3b556728d8c" + integrity sha512-/QZm9W92Ptpw7sjI9Nx1mbcsWz33+l8kuMIQnDwgQBG5s3fAfQvkRjQ7NqXhtNcKOnPkdICmUHyCaWW06HCsqg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-function-name@^7.0.0", "@babel/plugin-transform-function-name@^7.16.0", "@babel/plugin-transform-function-name@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-function-name/download/@babel/plugin-transform-function-name-7.16.0.tgz#02e3699c284c6262236599f751065c5d5f1f400e" + integrity sha1-AuNpnChMYmIjZZn3UQZcXV8fQA4= + dependencies: + "@babel/helper-function-name" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-function-name@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.16.7.tgz#5ab34375c64d61d083d7d2f05c38d90b97ec65cf" + integrity sha512-SU/C68YVwTRxqWj5kgsbKINakGag0KTgq9f2iZEXdStoAbOzLHEBRYzImmA6yFo8YZhJVflvXmIHUO7GWHmxxA== + dependencies: + "@babel/helper-compilation-targets" "^7.16.7" + "@babel/helper-function-name" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-literals@^7.0.0", "@babel/plugin-transform-literals@^7.16.0", "@babel/plugin-transform-literals@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-literals/download/@babel/plugin-transform-literals-7.16.0.tgz#79711e670ffceb31bd298229d50f3621f7980cac" + integrity sha1-eXEeZw/86zG9KYIp1Q82IfeYDKw= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-literals@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.16.7.tgz#254c9618c5ff749e87cb0c0cef1a0a050c0bdab1" + integrity sha512-6tH8RTpTWI0s2sV6uq3e/C9wPo4PTqqZps4uF0kzQ9/xPLFQtipynvmT1g/dOfEJ+0EQsHhkQ/zyRId8J2b8zQ== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-member-expression-literals@^7.16.0", "@babel/plugin-transform-member-expression-literals@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-member-expression-literals/download/@babel/plugin-transform-member-expression-literals-7.16.0.tgz?cache=0&sync_timestamp=1635566912290&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-member-expression-literals%2Fdownload%2F%40babel%2Fplugin-transform-member-expression-literals-7.16.0.tgz#5251b4cce01eaf8314403d21aedb269d79f5e64b" + integrity sha1-UlG0zOAer4MUQD0hrtsmnXn15ks= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-member-expression-literals@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.16.7.tgz#6e5dcf906ef8a098e630149d14c867dd28f92384" + integrity sha512-mBruRMbktKQwbxaJof32LT9KLy2f3gH+27a5XSuXo6h7R3vqltl0PgZ80C8ZMKw98Bf8bqt6BEVi3svOh2PzMw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-modules-amd@^7.16.0", "@babel/plugin-transform-modules-amd@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-amd/download/@babel/plugin-transform-modules-amd-7.16.0.tgz?cache=0&sync_timestamp=1635566912764&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-modules-amd%2Fdownload%2F%40babel%2Fplugin-transform-modules-amd-7.16.0.tgz#09abd41e18dcf4fd479c598c1cef7bd39eb1337e" + integrity sha1-CavUHhjc9P1HnFmMHO97056xM34= + dependencies: + "@babel/helper-module-transforms" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-amd@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.16.7.tgz#b28d323016a7daaae8609781d1f8c9da42b13186" + integrity sha512-KaaEtgBL7FKYwjJ/teH63oAmE3lP34N3kshz8mm4VMAw7U3PxjVwwUmxEFksbgsNUaO3wId9R2AVQYSEGRa2+g== + dependencies: + "@babel/helper-module-transforms" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-commonjs@^7.0.0", "@babel/plugin-transform-modules-commonjs@^7.16.0", "@babel/plugin-transform-modules-commonjs@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-commonjs/download/@babel/plugin-transform-modules-commonjs-7.16.0.tgz#add58e638c8ddc4875bd9a9ecb5c594613f6c922" + integrity sha1-rdWOY4yN3Eh1vZqey1xZRhP2ySI= + dependencies: + "@babel/helper-module-transforms" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-simple-access" "^7.16.0" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-commonjs@^7.16.8": + version "7.16.8" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.16.8.tgz#cdee19aae887b16b9d331009aa9a219af7c86afe" + integrity sha512-oflKPvsLT2+uKQopesJt3ApiaIS2HW+hzHFcwRNtyDGieAeC/dIHZX8buJQ2J2X1rxGPy4eRcUijm3qcSPjYcA== + dependencies: + "@babel/helper-module-transforms" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-simple-access" "^7.16.7" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-systemjs@^7.16.0", "@babel/plugin-transform-modules-systemjs@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-systemjs/download/@babel/plugin-transform-modules-systemjs-7.16.0.tgz?cache=0&sync_timestamp=1635566913014&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-modules-systemjs%2Fdownload%2F%40babel%2Fplugin-transform-modules-systemjs-7.16.0.tgz#a92cf240afeb605f4ca16670453024425e421ea4" + integrity sha1-qSzyQK/rYF9MoWZwRTAkQl5CHqQ= + dependencies: + "@babel/helper-hoist-variables" "^7.16.0" + "@babel/helper-module-transforms" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-validator-identifier" "^7.15.7" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-systemjs@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.16.7.tgz#887cefaef88e684d29558c2b13ee0563e287c2d7" + integrity sha512-DuK5E3k+QQmnOqBR9UkusByy5WZWGRxfzV529s9nPra1GE7olmxfqO2FHobEOYSPIjPBTr4p66YDcjQnt8cBmw== + dependencies: + "@babel/helper-hoist-variables" "^7.16.7" + "@babel/helper-module-transforms" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-validator-identifier" "^7.16.7" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-umd@^7.16.0", "@babel/plugin-transform-modules-umd@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-umd/download/@babel/plugin-transform-modules-umd-7.16.0.tgz?cache=0&sync_timestamp=1635566913244&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-modules-umd%2Fdownload%2F%40babel%2Fplugin-transform-modules-umd-7.16.0.tgz#195f26c2ad6d6a391b70880effce18ce625e06a7" + integrity sha1-GV8mwq1tajkbcIgO/84YzmJeBqc= + dependencies: + "@babel/helper-module-transforms" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-modules-umd@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.16.7.tgz#23dad479fa585283dbd22215bff12719171e7618" + integrity sha512-EMh7uolsC8O4xhudF2F6wedbSHm1HHZ0C6aJ7K67zcDNidMzVcxWdGr+htW9n21klm+bOn+Rx4CBsAntZd3rEQ== + dependencies: + "@babel/helper-module-transforms" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-named-capturing-groups-regex@^7.16.0", "@babel/plugin-transform-named-capturing-groups-regex@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-named-capturing-groups-regex/download/@babel/plugin-transform-named-capturing-groups-regex-7.16.0.tgz#d3db61cc5d5b97986559967cd5ea83e5c32096ca" + integrity sha1-09thzF1bl5hlWZZ81eqD5cMglso= + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.0" + +"@babel/plugin-transform-named-capturing-groups-regex@^7.16.8": + version "7.16.8" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.16.8.tgz#7f860e0e40d844a02c9dcf9d84965e7dfd666252" + integrity sha512-j3Jw+n5PvpmhRR+mrgIh04puSANCk/T/UA3m3P1MjJkhlK906+ApHhDIqBQDdOgL/r1UYpz4GNclTXxyZrYGSw== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.7" + +"@babel/plugin-transform-new-target@^7.16.0", "@babel/plugin-transform-new-target@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-new-target/download/@babel/plugin-transform-new-target-7.16.0.tgz#af823ab576f752215a49937779a41ca65825ab35" + integrity sha1-r4I6tXb3UiFaSZN3eaQcplglqzU= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-new-target@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.16.7.tgz#9967d89a5c243818e0800fdad89db22c5f514244" + integrity sha512-xiLDzWNMfKoGOpc6t3U+etCE2yRnn3SM09BXqWPIZOBpL2gvVrBWUKnsJx0K/ADi5F5YC5f8APFfWrz25TdlGg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-object-assign@^7.0.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-object-assign/download/@babel/plugin-transform-object-assign-7.16.0.tgz#750c726397f1f6402fb1ceffe9d8ff3595c8a0df" + integrity sha1-dQxyY5fx9kAvsc7/6dj/NZXIoN8= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-object-super@^7.16.0", "@babel/plugin-transform-object-super@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-object-super/download/@babel/plugin-transform-object-super-7.16.0.tgz?cache=0&sync_timestamp=1635566913937&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-object-super%2Fdownload%2F%40babel%2Fplugin-transform-object-super-7.16.0.tgz#fb20d5806dc6491a06296ac14ea8e8d6fedda72b" + integrity sha1-+yDVgG3GSRoGKWrBTqjo1v7dpys= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-replace-supers" "^7.16.0" + +"@babel/plugin-transform-object-super@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.16.7.tgz#ac359cf8d32cf4354d27a46867999490b6c32a94" + integrity sha512-14J1feiQVWaGvRxj2WjyMuXS2jsBkgB3MdSN5HuC2G5nRspa5RK9COcs82Pwy5BuGcjb+fYaUj94mYcOj7rCvw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-replace-supers" "^7.16.7" + +"@babel/plugin-transform-parameters@^7.0.0", "@babel/plugin-transform-parameters@^7.14.5", "@babel/plugin-transform-parameters@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-parameters/download/@babel/plugin-transform-parameters-7.16.0.tgz?cache=0&sync_timestamp=1635566914182&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-parameters%2Fdownload%2F%40babel%2Fplugin-transform-parameters-7.16.0.tgz#1b50765fc421c229819dc4c7cdb8911660b3c2d7" + integrity sha1-G1B2X8QhwimBncTHzbiRFmCzwtc= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-parameters@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.16.7.tgz#a1721f55b99b736511cb7e0152f61f17688f331f" + integrity sha512-AT3MufQ7zZEhU2hwOA11axBnExW0Lszu4RL/tAlUJBuNoRak+wehQW8h6KcXOcgjY42fHtDxswuMhMjFEuv/aw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-parameters@^7.8.7": + version "7.16.3" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-parameters/download/@babel/plugin-transform-parameters-7.16.3.tgz?cache=0&sync_timestamp=1636494867938&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-parameters%2Fdownload%2F%40babel%2Fplugin-transform-parameters-7.16.3.tgz#fa9e4c874ee5223f891ee6fa8d737f4766d31d15" + integrity sha512-3MaDpJrOXT1MZ/WCmkOFo7EtmVVC8H4EUZVrHvFOsmwkk4lOjQj8rzv8JKUZV4YoQKeoIgk07GO+acPU9IMu/w== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-property-literals@^7.16.0", "@babel/plugin-transform-property-literals@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-property-literals/download/@babel/plugin-transform-property-literals-7.16.0.tgz?cache=0&sync_timestamp=1635566914424&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-property-literals%2Fdownload%2F%40babel%2Fplugin-transform-property-literals-7.16.0.tgz#a95c552189a96a00059f6776dc4e00e3690c78d1" + integrity sha1-qVxVIYmpagAFn2d23E4A42kMeNE= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-property-literals@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.16.7.tgz#2dadac85155436f22c696c4827730e0fe1057a55" + integrity sha512-z4FGr9NMGdoIl1RqavCqGG+ZuYjfZ/hkCIeuH6Do7tXmSm0ls11nYVSJqFEUOSJbDab5wC6lRE/w6YjVcr6Hqw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-react-display-name@^7.0.0", "@babel/plugin-transform-react-display-name@^7.12.13": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-react-display-name/download/@babel/plugin-transform-react-display-name-7.16.0.tgz?cache=0&sync_timestamp=1635578408407&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-react-display-name%2Fdownload%2F%40babel%2Fplugin-transform-react-display-name-7.16.0.tgz#9a0ad8aa8e8790883a7bd2736f66229a58125676" + integrity sha1-mgrYqo6HkIg6e9Jzb2YimlgSVnY= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-react-jsx-development@^7.12.12": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-react-jsx-development/download/@babel/plugin-transform-react-jsx-development-7.16.0.tgz?cache=0&sync_timestamp=1635578408931&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-react-jsx-development%2Fdownload%2F%40babel%2Fplugin-transform-react-jsx-development-7.16.0.tgz#1cb52874678d23ab11d0d16488d54730807303ef" + integrity sha1-HLUodGeNI6sR0NFkiNVHMIBzA+8= + dependencies: + "@babel/plugin-transform-react-jsx" "^7.16.0" + +"@babel/plugin-transform-react-jsx-self@^7.0.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-react-jsx-self/download/@babel/plugin-transform-react-jsx-self-7.16.0.tgz?cache=0&sync_timestamp=1635892168124&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-react-jsx-self%2Fdownload%2F%40babel%2Fplugin-transform-react-jsx-self-7.16.0.tgz#09202158abbc716a08330f392bfb98d6b9acfa0c" + integrity sha1-CSAhWKu8cWoIMw85K/uY1rms+gw= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-react-jsx-source@^7.0.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-react-jsx-source/download/@babel/plugin-transform-react-jsx-source-7.16.0.tgz#d40c959d7803aae38224594585748693e84c0a22" + integrity sha1-1AyVnXgDquOCJFlFhXSGk+hMCiI= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-react-jsx@^7.0.0", "@babel/plugin-transform-react-jsx@^7.12.13", "@babel/plugin-transform-react-jsx@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-react-jsx/download/@babel/plugin-transform-react-jsx-7.16.0.tgz#55b797d4960c3de04e07ad1c0476e2bc6a4889f1" + integrity sha1-VbeX1JYMPeBOB60cBHbivGpIifE= + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-module-imports" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-jsx" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/plugin-transform-react-pure-annotations@^7.12.1": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-react-pure-annotations/download/@babel/plugin-transform-react-pure-annotations-7.16.0.tgz?cache=0&sync_timestamp=1635578409257&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-react-pure-annotations%2Fdownload%2F%40babel%2Fplugin-transform-react-pure-annotations-7.16.0.tgz#23db6ddf558d8abde41b8ad9d59f48ad5532ccab" + integrity sha1-I9tt31WNir3kG4rZ1Z9IrVUyzKs= + dependencies: + "@babel/helper-annotate-as-pure" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-regenerator@^7.0.0", "@babel/plugin-transform-regenerator@^7.16.0", "@babel/plugin-transform-regenerator@^7.8.7": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-regenerator/download/@babel/plugin-transform-regenerator-7.16.0.tgz?cache=0&sync_timestamp=1635566914723&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-regenerator%2Fdownload%2F%40babel%2Fplugin-transform-regenerator-7.16.0.tgz#eaee422c84b0232d03aea7db99c97deeaf6125a4" + integrity sha1-6u5CLISwIy0Drqfbmcl97q9hJaQ= + dependencies: + regenerator-transform "^0.14.2" + +"@babel/plugin-transform-regenerator@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.16.7.tgz#9e7576dc476cb89ccc5096fff7af659243b4adeb" + integrity sha512-mF7jOgGYCkSJagJ6XCujSQg+6xC1M77/03K2oBmVJWoFGNUtnVJO4WHKJk3dnPC8HCcj4xBQP1Egm8DWh3Pb3Q== + dependencies: + regenerator-transform "^0.14.2" + +"@babel/plugin-transform-reserved-words@^7.16.0", "@babel/plugin-transform-reserved-words@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-reserved-words/download/@babel/plugin-transform-reserved-words-7.16.0.tgz#fff4b9dcb19e12619394bda172d14f2d04c0379c" + integrity sha1-//S53LGeEmGTlL2hctFPLQTAN5w= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-reserved-words@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.16.7.tgz#1d798e078f7c5958eec952059c460b220a63f586" + integrity sha512-KQzzDnZ9hWQBjwi5lpY5v9shmm6IVG0U9pB18zvMu2i4H90xpT4gmqwPYsn8rObiadYe2M0gmgsiOIF5A/2rtg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-runtime@7.11.0": + version "7.11.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-runtime/download/@babel/plugin-transform-runtime-7.11.0.tgz?cache=0&sync_timestamp=1635578304501&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-runtime%2Fdownload%2F%40babel%2Fplugin-transform-runtime-7.11.0.tgz#e27f78eb36f19448636e05c33c90fd9ad9b8bccf" + integrity sha1-4n946zbxlEhjbgXDPJD9mtm4vM8= + dependencies: + "@babel/helper-module-imports" "^7.10.4" + "@babel/helper-plugin-utils" "^7.10.4" + resolve "^1.8.1" + semver "^5.5.1" + +"@babel/plugin-transform-runtime@7.9.0": + version "7.9.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-runtime/download/@babel/plugin-transform-runtime-7.9.0.tgz?cache=0&sync_timestamp=1637103539571&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-runtime%2Fdownload%2F%40babel%2Fplugin-transform-runtime-7.9.0.tgz#45468c0ae74cc13204e1d3b1f4ce6ee83258af0b" + integrity sha1-RUaMCudMwTIE4dOx9M5u6DJYrws= + dependencies: + "@babel/helper-module-imports" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + resolve "^1.8.1" + semver "^5.5.1" + +"@babel/plugin-transform-runtime@>=7", "@babel/plugin-transform-runtime@^7.0.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-runtime/download/@babel/plugin-transform-runtime-7.16.0.tgz?cache=0&sync_timestamp=1635578304501&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-runtime%2Fdownload%2F%40babel%2Fplugin-transform-runtime-7.16.0.tgz#3fe0da36c2f0834bef7c4d3e7f2b2db0ee0c8909" + integrity sha1-P+DaNsLwg0vvfE0+fystsO4MiQk= + dependencies: + "@babel/helper-module-imports" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + babel-plugin-polyfill-corejs2 "^0.2.3" + babel-plugin-polyfill-corejs3 "^0.3.0" + babel-plugin-polyfill-regenerator "^0.2.3" + semver "^6.3.0" + +"@babel/plugin-transform-shorthand-properties@^7.0.0", "@babel/plugin-transform-shorthand-properties@^7.16.0", "@babel/plugin-transform-shorthand-properties@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-shorthand-properties/download/@babel/plugin-transform-shorthand-properties-7.16.0.tgz#090372e3141f7cc324ed70b3daf5379df2fa384d" + integrity sha1-CQNy4xQffMMk7XCz2vU3nfL6OE0= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-shorthand-properties@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.16.7.tgz#e8549ae4afcf8382f711794c0c7b6b934c5fbd2a" + integrity sha512-hah2+FEnoRoATdIb05IOXf+4GzXYTq75TVhIn1PewihbpyrNWUt2JbudKQOETWw6QpLe+AIUpJ5MVLYTQbeeUg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-spread@^7.0.0", "@babel/plugin-transform-spread@^7.16.0", "@babel/plugin-transform-spread@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-spread/download/@babel/plugin-transform-spread-7.16.0.tgz?cache=0&sync_timestamp=1635566916819&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-spread%2Fdownload%2F%40babel%2Fplugin-transform-spread-7.16.0.tgz#d21ca099bbd53ab307a8621e019a7bd0f40cdcfb" + integrity sha1-0hygmbvVOrMHqGIeAZp70PQM3Ps= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" + +"@babel/plugin-transform-spread@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.16.7.tgz#a303e2122f9f12e0105daeedd0f30fb197d8ff44" + integrity sha512-+pjJpgAngb53L0iaA5gU/1MLXJIfXcYepLgXB3esVRf4fqmj8f2cxM3/FKaHsZms08hFQJkFccEWuIpm429TXg== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-skip-transparent-expression-wrappers" "^7.16.0" + +"@babel/plugin-transform-sticky-regex@^7.0.0", "@babel/plugin-transform-sticky-regex@^7.16.0", "@babel/plugin-transform-sticky-regex@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-sticky-regex/download/@babel/plugin-transform-sticky-regex-7.16.0.tgz#c35ea31a02d86be485f6aa510184b677a91738fd" + integrity sha1-w16jGgLYa+SF9qpRAYS2d6kXOP0= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-sticky-regex@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.16.7.tgz#c84741d4f4a38072b9a1e2e3fd56d359552e8660" + integrity sha512-NJa0Bd/87QV5NZZzTuZG5BPJjLYadeSZ9fO6oOUoL4iQx+9EEuw/eEM92SrsT19Yc2jgB1u1hsjqDtH02c3Drw== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-template-literals@>=7", "@babel/plugin-transform-template-literals@^7.0.0", "@babel/plugin-transform-template-literals@^7.16.0", "@babel/plugin-transform-template-literals@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-template-literals/download/@babel/plugin-transform-template-literals-7.16.0.tgz?cache=0&sync_timestamp=1635566917280&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-template-literals%2Fdownload%2F%40babel%2Fplugin-transform-template-literals-7.16.0.tgz#a8eced3a8e7b8e2d40ec4ec4548a45912630d302" + integrity sha1-qOztOo57ji1A7E7EVIpFkSYw0wI= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-template-literals@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.16.7.tgz#f3d1c45d28967c8e80f53666fc9c3e50618217ab" + integrity sha512-VwbkDDUeenlIjmfNeDX/V0aWrQH2QiVyJtwymVQSzItFDTpxfyJh3EVaQiS0rIN/CqbLGr0VcGmuwyTdZtdIsA== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-typeof-symbol@^7.16.0", "@babel/plugin-transform-typeof-symbol@^7.8.4": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-typeof-symbol/download/@babel/plugin-transform-typeof-symbol-7.16.0.tgz?cache=0&sync_timestamp=1635566920452&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-typeof-symbol%2Fdownload%2F%40babel%2Fplugin-transform-typeof-symbol-7.16.0.tgz#8b19a244c6f8c9d668dca6a6f754ad6ead1128f2" + integrity sha1-ixmiRMb4ydZo3Kam91Stbq0RKPI= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-typeof-symbol@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.16.7.tgz#9cdbe622582c21368bd482b660ba87d5545d4f7e" + integrity sha512-p2rOixCKRJzpg9JB4gjnG4gjWkWa89ZoYUnl9snJ1cWIcTH/hvxZqfO+WjG6T8DRBpctEol5jw1O5rA8gkCokQ== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-typescript@^7.12.17", "@babel/plugin-transform-typescript@^7.5.0", "@babel/plugin-transform-typescript@^7.9.0": + version "7.16.1" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-typescript/download/@babel/plugin-transform-typescript-7.16.1.tgz#cc0670b2822b0338355bc1b3d2246a42b8166409" + integrity sha1-zAZwsoIrAzg1W8Gz0iRqQrgWZAk= + dependencies: + "@babel/helper-create-class-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-typescript" "^7.16.0" + +"@babel/plugin-transform-unicode-escapes@^7.16.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-unicode-escapes/download/@babel/plugin-transform-unicode-escapes-7.16.0.tgz?cache=0&sync_timestamp=1635567014397&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-unicode-escapes%2Fdownload%2F%40babel%2Fplugin-transform-unicode-escapes-7.16.0.tgz#1a354064b4c45663a32334f46fa0cf6100b5b1f3" + integrity sha1-GjVAZLTEVmOjIzT0b6DPYQC1sfM= + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-unicode-escapes@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.16.7.tgz#da8717de7b3287a2c6d659750c964f302b31ece3" + integrity sha512-TAV5IGahIz3yZ9/Hfv35TV2xEm+kaBDaZQCn2S/hG9/CZ0DktxJv9eKfPc7yYCvOYR4JGx1h8C+jcSOvgaaI/Q== + dependencies: + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/plugin-transform-unicode-regex@^7.0.0", "@babel/plugin-transform-unicode-regex@^7.16.0", "@babel/plugin-transform-unicode-regex@^7.8.3": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-unicode-regex/download/@babel/plugin-transform-unicode-regex-7.16.0.tgz?cache=0&sync_timestamp=1635567014565&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fplugin-transform-unicode-regex%2Fdownload%2F%40babel%2Fplugin-transform-unicode-regex-7.16.0.tgz#293b80950177c8c85aede87cef280259fb995402" + integrity sha1-KTuAlQF3yMha7eh87ygCWfuZVAI= + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-unicode-regex@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.16.7.tgz#0f7aa4a501198976e25e82702574c34cfebe9ef2" + integrity sha512-oC5tYYKw56HO75KZVLQ+R/Nl3Hro9kf8iG0hXoaHP7tjAyCpvqBiSNe6vGrZni1Z6MggmUOC6A7VP7AVmw225Q== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + +"@babel/preset-env@7.9.0": + version "7.9.0" + resolved "https://registry.npmmirror.com/@babel/preset-env/download/@babel/preset-env-7.9.0.tgz?cache=0&sync_timestamp=1637103547851&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fpreset-env%2Fdownload%2F%40babel%2Fpreset-env-7.9.0.tgz#a5fc42480e950ae8f5d9f8f2bbc03f52722df3a8" + integrity sha1-pfxCSA6VCuj12fjyu8A/UnIt86g= + dependencies: + "@babel/compat-data" "^7.9.0" + "@babel/helper-compilation-targets" "^7.8.7" + "@babel/helper-module-imports" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-proposal-async-generator-functions" "^7.8.3" + "@babel/plugin-proposal-dynamic-import" "^7.8.3" + "@babel/plugin-proposal-json-strings" "^7.8.3" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-proposal-numeric-separator" "^7.8.3" + "@babel/plugin-proposal-object-rest-spread" "^7.9.0" + "@babel/plugin-proposal-optional-catch-binding" "^7.8.3" + "@babel/plugin-proposal-optional-chaining" "^7.9.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.8.3" + "@babel/plugin-syntax-async-generators" "^7.8.0" + "@babel/plugin-syntax-dynamic-import" "^7.8.0" + "@babel/plugin-syntax-json-strings" "^7.8.0" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.0" + "@babel/plugin-syntax-numeric-separator" "^7.8.0" + "@babel/plugin-syntax-object-rest-spread" "^7.8.0" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.0" + "@babel/plugin-syntax-optional-chaining" "^7.8.0" + "@babel/plugin-syntax-top-level-await" "^7.8.3" + "@babel/plugin-transform-arrow-functions" "^7.8.3" + "@babel/plugin-transform-async-to-generator" "^7.8.3" + "@babel/plugin-transform-block-scoped-functions" "^7.8.3" + "@babel/plugin-transform-block-scoping" "^7.8.3" + "@babel/plugin-transform-classes" "^7.9.0" + "@babel/plugin-transform-computed-properties" "^7.8.3" + "@babel/plugin-transform-destructuring" "^7.8.3" + "@babel/plugin-transform-dotall-regex" "^7.8.3" + "@babel/plugin-transform-duplicate-keys" "^7.8.3" + "@babel/plugin-transform-exponentiation-operator" "^7.8.3" + "@babel/plugin-transform-for-of" "^7.9.0" + "@babel/plugin-transform-function-name" "^7.8.3" + "@babel/plugin-transform-literals" "^7.8.3" + "@babel/plugin-transform-member-expression-literals" "^7.8.3" + "@babel/plugin-transform-modules-amd" "^7.9.0" + "@babel/plugin-transform-modules-commonjs" "^7.9.0" + "@babel/plugin-transform-modules-systemjs" "^7.9.0" + "@babel/plugin-transform-modules-umd" "^7.9.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.8.3" + "@babel/plugin-transform-new-target" "^7.8.3" + "@babel/plugin-transform-object-super" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.8.7" + "@babel/plugin-transform-property-literals" "^7.8.3" + "@babel/plugin-transform-regenerator" "^7.8.7" + "@babel/plugin-transform-reserved-words" "^7.8.3" + "@babel/plugin-transform-shorthand-properties" "^7.8.3" + "@babel/plugin-transform-spread" "^7.8.3" + "@babel/plugin-transform-sticky-regex" "^7.8.3" + "@babel/plugin-transform-template-literals" "^7.8.3" + "@babel/plugin-transform-typeof-symbol" "^7.8.4" + "@babel/plugin-transform-unicode-regex" "^7.8.3" + "@babel/preset-modules" "^0.1.3" + "@babel/types" "^7.9.0" + browserslist "^4.9.1" + core-js-compat "^3.6.2" + invariant "^2.2.2" + levenary "^1.1.1" + semver "^5.5.0" + +"@babel/preset-env@>=7": + version "7.16.11" + resolved "https://registry.npmmirror.com/@babel/preset-env/-/preset-env-7.16.11.tgz#5dd88fd885fae36f88fd7c8342475c9f0abe2982" + integrity sha512-qcmWG8R7ZW6WBRPZK//y+E3Cli151B20W1Rv7ln27vuPaXU/8TKms6jFdiJtF7UDTxcrb7mZd88tAeK9LjdT8g== + dependencies: + "@babel/compat-data" "^7.16.8" + "@babel/helper-compilation-targets" "^7.16.7" + "@babel/helper-plugin-utils" "^7.16.7" + "@babel/helper-validator-option" "^7.16.7" + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression" "^7.16.7" + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.16.7" + "@babel/plugin-proposal-async-generator-functions" "^7.16.8" + "@babel/plugin-proposal-class-properties" "^7.16.7" + "@babel/plugin-proposal-class-static-block" "^7.16.7" + "@babel/plugin-proposal-dynamic-import" "^7.16.7" + "@babel/plugin-proposal-export-namespace-from" "^7.16.7" + "@babel/plugin-proposal-json-strings" "^7.16.7" + "@babel/plugin-proposal-logical-assignment-operators" "^7.16.7" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.16.7" + "@babel/plugin-proposal-numeric-separator" "^7.16.7" + "@babel/plugin-proposal-object-rest-spread" "^7.16.7" + "@babel/plugin-proposal-optional-catch-binding" "^7.16.7" + "@babel/plugin-proposal-optional-chaining" "^7.16.7" + "@babel/plugin-proposal-private-methods" "^7.16.11" + "@babel/plugin-proposal-private-property-in-object" "^7.16.7" + "@babel/plugin-proposal-unicode-property-regex" "^7.16.7" + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-syntax-class-properties" "^7.12.13" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + "@babel/plugin-syntax-json-strings" "^7.8.3" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + "@babel/plugin-syntax-top-level-await" "^7.14.5" + "@babel/plugin-transform-arrow-functions" "^7.16.7" + "@babel/plugin-transform-async-to-generator" "^7.16.8" + "@babel/plugin-transform-block-scoped-functions" "^7.16.7" + "@babel/plugin-transform-block-scoping" "^7.16.7" + "@babel/plugin-transform-classes" "^7.16.7" + "@babel/plugin-transform-computed-properties" "^7.16.7" + "@babel/plugin-transform-destructuring" "^7.16.7" + "@babel/plugin-transform-dotall-regex" "^7.16.7" + "@babel/plugin-transform-duplicate-keys" "^7.16.7" + "@babel/plugin-transform-exponentiation-operator" "^7.16.7" + "@babel/plugin-transform-for-of" "^7.16.7" + "@babel/plugin-transform-function-name" "^7.16.7" + "@babel/plugin-transform-literals" "^7.16.7" + "@babel/plugin-transform-member-expression-literals" "^7.16.7" + "@babel/plugin-transform-modules-amd" "^7.16.7" + "@babel/plugin-transform-modules-commonjs" "^7.16.8" + "@babel/plugin-transform-modules-systemjs" "^7.16.7" + "@babel/plugin-transform-modules-umd" "^7.16.7" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.16.8" + "@babel/plugin-transform-new-target" "^7.16.7" + "@babel/plugin-transform-object-super" "^7.16.7" + "@babel/plugin-transform-parameters" "^7.16.7" + "@babel/plugin-transform-property-literals" "^7.16.7" + "@babel/plugin-transform-regenerator" "^7.16.7" + "@babel/plugin-transform-reserved-words" "^7.16.7" + "@babel/plugin-transform-shorthand-properties" "^7.16.7" + "@babel/plugin-transform-spread" "^7.16.7" + "@babel/plugin-transform-sticky-regex" "^7.16.7" + "@babel/plugin-transform-template-literals" "^7.16.7" + "@babel/plugin-transform-typeof-symbol" "^7.16.7" + "@babel/plugin-transform-unicode-escapes" "^7.16.7" + "@babel/plugin-transform-unicode-regex" "^7.16.7" + "@babel/preset-modules" "^0.1.5" + "@babel/types" "^7.16.8" + babel-plugin-polyfill-corejs2 "^0.3.0" + babel-plugin-polyfill-corejs3 "^0.5.0" + babel-plugin-polyfill-regenerator "^0.3.0" + core-js-compat "^3.20.2" + semver "^6.3.0" + +"@babel/preset-env@^7.11.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/preset-env/download/@babel/preset-env-7.16.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fpreset-env%2Fdownload%2F%40babel%2Fpreset-env-7.16.0.tgz#97228393d217560d6a1c6c56f0adb9d12bca67f5" + integrity sha1-lyKDk9IXVg1qHGxW8K250SvKZ/U= + dependencies: + "@babel/compat-data" "^7.16.0" + "@babel/helper-compilation-targets" "^7.16.0" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-validator-option" "^7.14.5" + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression" "^7.16.0" + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.16.0" + "@babel/plugin-proposal-async-generator-functions" "^7.16.0" + "@babel/plugin-proposal-class-properties" "^7.16.0" + "@babel/plugin-proposal-class-static-block" "^7.16.0" + "@babel/plugin-proposal-dynamic-import" "^7.16.0" + "@babel/plugin-proposal-export-namespace-from" "^7.16.0" + "@babel/plugin-proposal-json-strings" "^7.16.0" + "@babel/plugin-proposal-logical-assignment-operators" "^7.16.0" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.16.0" + "@babel/plugin-proposal-numeric-separator" "^7.16.0" + "@babel/plugin-proposal-object-rest-spread" "^7.16.0" + "@babel/plugin-proposal-optional-catch-binding" "^7.16.0" + "@babel/plugin-proposal-optional-chaining" "^7.16.0" + "@babel/plugin-proposal-private-methods" "^7.16.0" + "@babel/plugin-proposal-private-property-in-object" "^7.16.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.16.0" + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-syntax-class-properties" "^7.12.13" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + "@babel/plugin-syntax-json-strings" "^7.8.3" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + "@babel/plugin-syntax-top-level-await" "^7.14.5" + "@babel/plugin-transform-arrow-functions" "^7.16.0" + "@babel/plugin-transform-async-to-generator" "^7.16.0" + "@babel/plugin-transform-block-scoped-functions" "^7.16.0" + "@babel/plugin-transform-block-scoping" "^7.16.0" + "@babel/plugin-transform-classes" "^7.16.0" + "@babel/plugin-transform-computed-properties" "^7.16.0" + "@babel/plugin-transform-destructuring" "^7.16.0" + "@babel/plugin-transform-dotall-regex" "^7.16.0" + "@babel/plugin-transform-duplicate-keys" "^7.16.0" + "@babel/plugin-transform-exponentiation-operator" "^7.16.0" + "@babel/plugin-transform-for-of" "^7.16.0" + "@babel/plugin-transform-function-name" "^7.16.0" + "@babel/plugin-transform-literals" "^7.16.0" + "@babel/plugin-transform-member-expression-literals" "^7.16.0" + "@babel/plugin-transform-modules-amd" "^7.16.0" + "@babel/plugin-transform-modules-commonjs" "^7.16.0" + "@babel/plugin-transform-modules-systemjs" "^7.16.0" + "@babel/plugin-transform-modules-umd" "^7.16.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.16.0" + "@babel/plugin-transform-new-target" "^7.16.0" + "@babel/plugin-transform-object-super" "^7.16.0" + "@babel/plugin-transform-parameters" "^7.16.0" + "@babel/plugin-transform-property-literals" "^7.16.0" + "@babel/plugin-transform-regenerator" "^7.16.0" + "@babel/plugin-transform-reserved-words" "^7.16.0" + "@babel/plugin-transform-shorthand-properties" "^7.16.0" + "@babel/plugin-transform-spread" "^7.16.0" + "@babel/plugin-transform-sticky-regex" "^7.16.0" + "@babel/plugin-transform-template-literals" "^7.16.0" + "@babel/plugin-transform-typeof-symbol" "^7.16.0" + "@babel/plugin-transform-unicode-escapes" "^7.16.0" + "@babel/plugin-transform-unicode-regex" "^7.16.0" + "@babel/preset-modules" "^0.1.5" + "@babel/types" "^7.16.0" + babel-plugin-polyfill-corejs2 "^0.2.3" + babel-plugin-polyfill-corejs3 "^0.3.0" + babel-plugin-polyfill-regenerator "^0.2.3" + core-js-compat "^3.19.0" + semver "^6.3.0" + +"@babel/preset-modules@^0.1.3", "@babel/preset-modules@^0.1.5": + version "0.1.5" + resolved "https://registry.npmmirror.com/@babel/preset-modules/download/@babel/preset-modules-0.1.5.tgz#ef939d6e7f268827e1841638dc6ff95515e115d9" + integrity sha1-75Odbn8miCfhhBY43G/5VRXhFdk= + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" + "@babel/plugin-transform-dotall-regex" "^7.4.4" + "@babel/types" "^7.4.4" + esutils "^2.0.2" + +"@babel/preset-react@7.12.13": + version "7.12.13" + resolved "https://registry.npmmirror.com/@babel/preset-react/download/@babel/preset-react-7.12.13.tgz#5f911b2eb24277fa686820d5bd81cad9a0602a0a" + integrity sha1-X5EbLrJCd/poaCDVvYHK2aBgKgo= + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + "@babel/plugin-transform-react-display-name" "^7.12.13" + "@babel/plugin-transform-react-jsx" "^7.12.13" + "@babel/plugin-transform-react-jsx-development" "^7.12.12" + "@babel/plugin-transform-react-pure-annotations" "^7.12.1" + +"@babel/preset-typescript@7.12.17": + version "7.12.17" + resolved "https://registry.npmmirror.com/@babel/preset-typescript/download/@babel/preset-typescript-7.12.17.tgz#8ecf04618956c268359dd9feab775dc14a666eb5" + integrity sha1-js8EYYlWwmg1ndn+q3ddwUpmbrU= + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + "@babel/helper-validator-option" "^7.12.17" + "@babel/plugin-transform-typescript" "^7.12.17" + +"@babel/preset-typescript@7.9.0": + version "7.9.0" + resolved "https://registry.npmmirror.com/@babel/preset-typescript/download/@babel/preset-typescript-7.9.0.tgz#87705a72b1f0d59df21c179f7c3d2ef4b16ce192" + integrity sha1-h3BacrHw1Z3yHBeffD0u9LFs4ZI= + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-transform-typescript" "^7.9.0" + +"@babel/register@7.14.5": + version "7.14.5" + resolved "https://registry.npmmirror.com/@babel/register/download/@babel/register-7.14.5.tgz#d0eac615065d9c2f1995842f85d6e56c345f3233" + integrity sha1-0OrGFQZdnC8ZlYQvhdblbDRfMjM= + dependencies: + clone-deep "^4.0.1" + find-cache-dir "^2.0.0" + make-dir "^2.1.0" + pirates "^4.0.0" + source-map-support "^0.5.16" + +"@babel/register@7.9.0": + version "7.9.0" + resolved "https://registry.npmmirror.com/@babel/register/download/@babel/register-7.9.0.tgz#02464ede57548bddbb5e9f705d263b7c3f43d48b" + integrity sha1-AkZO3ldUi927Xp9wXSY7fD9D1Is= + dependencies: + find-cache-dir "^2.0.0" + lodash "^4.17.13" + make-dir "^2.1.0" + pirates "^4.0.0" + source-map-support "^0.5.16" + +"@babel/runtime-corejs3@^7.14.8": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/runtime-corejs3/download/@babel/runtime-corejs3-7.16.0.tgz?cache=0&sync_timestamp=1635603064967&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fruntime-corejs3%2Fdownload%2F%40babel%2Fruntime-corejs3-7.16.0.tgz#58a7fb00e6948508f12f53a303993e8b6e2f6c70" + integrity sha1-WKf7AOaUhQjxL1OjA5k+i24vbHA= + dependencies: + core-js-pure "^3.19.0" + regenerator-runtime "^0.13.4" + +"@babel/runtime@7.9.2": + version "7.9.2" + resolved "https://registry.npmmirror.com/@babel/runtime/download/@babel/runtime-7.9.2.tgz?cache=0&sync_timestamp=1636494819594&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fruntime%2Fdownload%2F%40babel%2Fruntime-7.9.2.tgz#d90df0583a3a252f09aaa619665367bae518db06" + integrity sha1-2Q3wWDo6JS8JqqYZZlNnuuUY2wY= + dependencies: + regenerator-runtime "^0.13.4" + +"@babel/runtime@^7.0.0": + version "7.16.5" + resolved "https://registry.npmmirror.com/@babel/runtime/download/@babel/runtime-7.16.5.tgz#7f3e34bf8bdbbadf03fbb7b1ea0d929569c9487a" + integrity sha512-TXWihFIS3Pyv5hzR7j6ihmeLkZfrXGxAr5UfSl8CHf+6q/wpiYDkUau0czckpYG8QmnCIuPpdLtuA9VmuGGyMA== + dependencies: + regenerator-runtime "^0.13.4" + +"@babel/runtime@^7.11.2", "@babel/runtime@^7.15.4", "@babel/runtime@^7.6.3", "@babel/runtime@^7.7.6", "@babel/runtime@^7.7.7", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/runtime/download/@babel/runtime-7.16.0.tgz#e27b977f2e2088ba24748bf99b5e1dece64e4f0b" + integrity sha1-4nuXfy4giLokdIv5m14d7OZOTws= + dependencies: + regenerator-runtime "^0.13.4" + +"@babel/runtime@^7.5.5", "@babel/runtime@^7.8.7": + version "7.16.3" + resolved "https://registry.npmmirror.com/@babel/runtime/download/@babel/runtime-7.16.3.tgz?cache=0&sync_timestamp=1636494819594&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Fruntime%2Fdownload%2F%40babel%2Fruntime-7.16.3.tgz#b86f0db02a04187a3c17caa77de69840165d42d5" + integrity sha512-WBwekcqacdY2e9AF/Q7WLFUWmdJGJTkbjqTjoMDgXkVZ3ZRUvOPsLb5KdwISoQVsbP+DQzVZW4Zhci0DvpbNTQ== + dependencies: + regenerator-runtime "^0.13.4" + +"@babel/template@>=7", "@babel/template@^7.0.0", "@babel/template@^7.16.0", "@babel/template@^7.8.6": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/template/download/@babel/template-7.16.0.tgz#d16a35ebf4cd74e202083356fab21dd89363ddd6" + integrity sha1-0Wo16/TNdOICCDNW+rId2JNj3dY= + dependencies: + "@babel/code-frame" "^7.16.0" + "@babel/parser" "^7.16.0" + "@babel/types" "^7.16.0" + +"@babel/template@^7.16.7": + version "7.16.7" + resolved "https://registry.npmmirror.com/@babel/template/-/template-7.16.7.tgz#8d126c8701fde4d66b264b3eba3d96f07666d155" + integrity sha512-I8j/x8kHUrbYRTUxXrrMbfCa7jxkE7tZre39x3kjr9hvI82cK1FfqLygotcWN5kdPGWcLdWMHpSBavse5tWw3w== + dependencies: + "@babel/code-frame" "^7.16.7" + "@babel/parser" "^7.16.7" + "@babel/types" "^7.16.7" + +"@babel/traverse@^7.0.0", "@babel/traverse@^7.13.0", "@babel/traverse@^7.16.0", "@babel/traverse@^7.7.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/traverse/download/@babel/traverse-7.16.0.tgz?cache=0&sync_timestamp=1635560907867&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Ftraverse%2Fdownload%2F%40babel%2Ftraverse-7.16.0.tgz#965df6c6bfc0a958c1e739284d3c9fa4a6e3c45b" + integrity sha1-ll32xr/AqVjB5zkoTTyfpKbjxFs= + dependencies: + "@babel/code-frame" "^7.16.0" + "@babel/generator" "^7.16.0" + "@babel/helper-function-name" "^7.16.0" + "@babel/helper-hoist-variables" "^7.16.0" + "@babel/helper-split-export-declaration" "^7.16.0" + "@babel/parser" "^7.16.0" + "@babel/types" "^7.16.0" + debug "^4.1.0" + globals "^11.1.0" + +"@babel/traverse@^7.16.3", "@babel/traverse@^7.9.0": + version "7.16.3" + resolved "https://registry.npmmirror.com/@babel/traverse/download/@babel/traverse-7.16.3.tgz?cache=0&sync_timestamp=1636494921751&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Ftraverse%2Fdownload%2F%40babel%2Ftraverse-7.16.3.tgz#f63e8a938cc1b780f66d9ed3c54f532ca2d14787" + integrity sha512-eolumr1vVMjqevCpwVO99yN/LoGL0EyHiLO5I043aYQvwOJ9eR5UsZSClHVCzfhBduMAsSzgA/6AyqPjNayJag== + dependencies: + "@babel/code-frame" "^7.16.0" + "@babel/generator" "^7.16.0" + "@babel/helper-function-name" "^7.16.0" + "@babel/helper-hoist-variables" "^7.16.0" + "@babel/helper-split-export-declaration" "^7.16.0" + "@babel/parser" "^7.16.3" + "@babel/types" "^7.16.0" + debug "^4.1.0" + globals "^11.1.0" + +"@babel/traverse@^7.16.7", "@babel/traverse@^7.16.8", "@babel/traverse@^7.17.3": + version "7.17.3" + resolved "https://registry.npmmirror.com/@babel/traverse/-/traverse-7.17.3.tgz#0ae0f15b27d9a92ba1f2263358ea7c4e7db47b57" + integrity sha512-5irClVky7TxRWIRtxlh2WPUUOLhcPN06AGgaQSB8AEwuyEBgJVuJ5imdHm5zxk8w0QS5T+tDfnDxAlhWjpb7cw== + dependencies: + "@babel/code-frame" "^7.16.7" + "@babel/generator" "^7.17.3" + "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-function-name" "^7.16.7" + "@babel/helper-hoist-variables" "^7.16.7" + "@babel/helper-split-export-declaration" "^7.16.7" + "@babel/parser" "^7.17.3" + "@babel/types" "^7.17.0" + debug "^4.1.0" + globals "^11.1.0" + +"@babel/types@^7.0.0", "@babel/types@^7.16.0", "@babel/types@^7.4.4", "@babel/types@^7.7.0", "@babel/types@^7.9.0": + version "7.16.0" + resolved "https://registry.npmmirror.com/@babel/types/download/@babel/types-7.16.0.tgz?cache=0&sync_timestamp=1635560908248&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40babel%2Ftypes%2Fdownload%2F%40babel%2Ftypes-7.16.0.tgz#db3b313804f96aadd0b776c4823e127ad67289ba" + integrity sha1-2zsxOAT5aq3Qt3bEgj4SetZyibo= + dependencies: + "@babel/helper-validator-identifier" "^7.15.7" + to-fast-properties "^2.0.0" + +"@babel/types@^7.16.7", "@babel/types@^7.16.8", "@babel/types@^7.17.0": + version "7.17.0" + resolved "https://registry.npmmirror.com/@babel/types/-/types-7.17.0.tgz#a826e368bccb6b3d84acd76acad5c0d87342390b" + integrity sha512-TmKSNO4D5rzhL5bjWFcVHHLETzfQ/AmbKpKPOSjlP0WoHZ6L911fgoOKY4Alp/emzG4cHJdyN49zpgkbXFEHHw== + dependencies: + "@babel/helper-validator-identifier" "^7.16.7" + to-fast-properties "^2.0.0" + +"@emotion/is-prop-valid@^0.8.8": + version "0.8.8" + resolved "https://registry.npm.taobao.org/@emotion/is-prop-valid/download/@emotion/is-prop-valid-0.8.8.tgz?cache=0&sync_timestamp=1612610319310&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40emotion%2Fis-prop-valid%2Fdownload%2F%40emotion%2Fis-prop-valid-0.8.8.tgz#db28b1c4368a259b60a97311d6a952d4fd01ac1a" + integrity sha1-2yixxDaKJZtgqXMR1qlS1P0BrBo= + dependencies: + "@emotion/memoize" "0.7.4" + +"@emotion/memoize@0.7.4": + version "0.7.4" + resolved "https://registry.npm.taobao.org/@emotion/memoize/download/@emotion/memoize-0.7.4.tgz?cache=0&sync_timestamp=1615986337535&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40emotion%2Fmemoize%2Fdownload%2F%40emotion%2Fmemoize-0.7.4.tgz#19bf0f5af19149111c40d98bb0cf82119f5d9eeb" + integrity sha1-Gb8PWvGRSREcQNmLsM+CEZ9dnus= + +"@gar/promisify@^1.0.1": + version "1.1.2" + resolved "https://registry.nlark.com/@gar/promisify/download/@gar/promisify-1.1.2.tgz?cache=0&sync_timestamp=1629999814022&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40gar%2Fpromisify%2Fdownload%2F%40gar%2Fpromisify-1.1.2.tgz#30aa825f11d438671d585bd44e7fd564535fc210" + integrity sha1-MKqCXxHUOGcdWFvUTn/VZFNfwhA= + +"@hapi/address@^4.0.1": + version "4.1.0" + resolved "https://registry.npmmirror.com/@hapi/address/download/@hapi/address-4.1.0.tgz#d60c5c0d930e77456fdcde2598e77302e2955e1d" + integrity sha1-1gxcDZMOd0Vv3N4lmOdzAuKVXh0= + dependencies: + "@hapi/hoek" "^9.0.0" + +"@hapi/formula@^2.0.0": + version "2.0.0" + resolved "https://registry.npmmirror.com/@hapi/formula/download/@hapi/formula-2.0.0.tgz#edade0619ed58c8e4f164f233cda70211e787128" + integrity sha1-7a3gYZ7VjI5PFk8jPNpwIR54cSg= + +"@hapi/hoek@^9.0.0": + version "9.2.1" + resolved "https://registry.npmmirror.com/@hapi/hoek/download/@hapi/hoek-9.2.1.tgz#9551142a1980503752536b5050fd99f4a7f13b17" + integrity sha1-lVEUKhmAUDdSU2tQUP2Z9KfxOxc= + +"@hapi/joi@17.1.1": + version "17.1.1" + resolved "https://registry.npmmirror.com/@hapi/joi/download/@hapi/joi-17.1.1.tgz#9cc8d7e2c2213d1e46708c6260184b447c661350" + integrity sha1-nMjX4sIhPR5GcIxiYBhLRHxmE1A= + dependencies: + "@hapi/address" "^4.0.1" + "@hapi/formula" "^2.0.0" + "@hapi/hoek" "^9.0.0" + "@hapi/pinpoint" "^2.0.0" + "@hapi/topo" "^5.0.0" + +"@hapi/pinpoint@^2.0.0": + version "2.0.0" + resolved "https://registry.npmmirror.com/@hapi/pinpoint/download/@hapi/pinpoint-2.0.0.tgz#805b40d4dbec04fc116a73089494e00f073de8df" + integrity sha1-gFtA1NvsBPwRanMIlJTgDwc96N8= + +"@hapi/topo@^5.0.0": + version "5.1.0" + resolved "https://registry.nlark.com/@hapi/topo/download/@hapi/topo-5.1.0.tgz#dc448e332c6c6e37a4dc02fd84ba8d44b9afb012" + integrity sha1-3ESOMyxsbjek3AL9hLqNRLmvsBI= + dependencies: + "@hapi/hoek" "^9.0.0" + +"@linaria/babel-preset@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/babel-preset/-/babel-preset-3.0.0-beta.17.tgz#97623e5f25751aa7641aa107442308697738a669" + integrity sha512-+AVhKvmWY8u0R9FpiN/DD4He5m7KL+4AIHt+z2y3idryFXAhHqG8DEH+LyHFXCE0GN6mOyudfSrhCKsK5+Xnpg== + dependencies: + "@babel/generator" ">=7" + "@babel/plugin-syntax-dynamic-import" ">=7" + "@babel/template" ">=7" + "@linaria/core" "^3.0.0-beta.15" + "@linaria/logger" "^3.0.0-beta.15" + "@linaria/utils" "^3.0.0-beta.15" + cosmiconfig "^5.1.0" + source-map "^0.7.3" + stylis "^3.5.4" + +"@linaria/core@^3.0.0-beta.15": + version "3.0.0-beta.15" + resolved "https://registry.npmmirror.com/@linaria/core/-/core-3.0.0-beta.15.tgz#570fab9430e5b4f2677fbb4eaeda66c041030f08" + integrity sha512-9sqPCcWIlA1zTck45uNGqrjtnWj5HGa7Lxbaw1ZsCcm6K6WcMVyOqW3OQkMBHuf3OzC50Mzb8z7d7d6Rpg8uFw== + dependencies: + "@linaria/utils" "^3.0.0-beta.15" + +"@linaria/extractor@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/extractor/-/extractor-3.0.0-beta.17.tgz#545b34e3fe38153113041e1acbf34080848aba80" + integrity sha512-1ze0JQkvFMCUHiz83ELHiaxKBtkLpO9b7frvgL0yRQvoR1TZOun7OulClK/Ae8fRVCTRwGViK7gyPVmWEiwkHQ== + dependencies: + "@babel/generator" ">=7" + "@babel/plugin-transform-runtime" ">=7" + "@babel/plugin-transform-template-literals" ">=7" + "@linaria/babel-preset" "^3.0.0-beta.17" + "@linaria/preeval" "^3.0.0-beta.17" + +"@linaria/logger@^3.0.0-beta.15": + version "3.0.0-beta.15" + resolved "https://registry.npmmirror.com/@linaria/logger/-/logger-3.0.0-beta.15.tgz#be0490e71da8e5e637ad5aaef59b0a021dc4fec3" + integrity sha512-tKytEEus47CZ4/7pbgRYD+Por4tH7/5Um2Quof6Qamd7Xj7brhmAPRRoZzYu4pht+S7V9oNL0X4IBSmNIOYRZw== + dependencies: + debug "^4.1.1" + picocolors "^1.0.0" + +"@linaria/preeval@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/preeval/-/preeval-3.0.0-beta.17.tgz#ef66b7d03d1af1e6e58f9639698f3f1dfc8f2ee9" + integrity sha512-fLsCaB0hzf2v2hcAX2NyWKToSqJCVm7cYmP5qeN3ZI4yQwpBaDOS8qzjlA3JVJ54WgRXscEw7a4jMNrBjT4Q/w== + dependencies: + "@linaria/babel-preset" "^3.0.0-beta.17" + +"@linaria/react@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/react/-/react-3.0.0-beta.17.tgz#4382ff8fc46fc98180f01cd77fb3a901c39b0126" + integrity sha512-NE3oqtgwb1EyPg5XOMP0SsXKe+S9nX6/rBC9rtyX8VAOl8RfYt/539M1CXhM2JcU0rWpXi/9mFCet0P7a0bfnQ== + dependencies: + "@emotion/is-prop-valid" "^0.8.8" + "@linaria/core" "^3.0.0-beta.15" + +"@linaria/rollup@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/rollup/-/rollup-3.0.0-beta.17.tgz#42aff8f4e886de1bd0cc16b874c5bc0f4f5bb140" + integrity sha512-5PC9HoSpw0V463OGhhw8VC8h6IkYNlSpSQZ1kzrtZByEIRINH7GmnAHWFfLPW1rqZNhGCRRV2GgaP7ldxveHrA== + dependencies: + "@linaria/babel-preset" "^3.0.0-beta.17" + "@rollup/pluginutils" "^4.1.0" + +"@linaria/server@^3.0.0-beta.13": + version "3.0.0-beta.13" + resolved "https://registry.npmmirror.com/@linaria/server/-/server-3.0.0-beta.13.tgz#92504a27aaf8df434b2989538fb5a31598a298a7" + integrity sha512-LkmiTIKY2srNwxqHbYXfgb47ZuiyhKNEMFMAbO7818RY2ijXb9eJgQ7SfDah5Cod7b8HBaWn58Kc2FeTR4+rlg== + dependencies: + postcss "^7.0.14" + +"@linaria/shaker@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/shaker/-/shaker-3.0.0-beta.17.tgz#e4de444530806171acd4bdd4d7ecdb5647572f69" + integrity sha512-Iv5XrEeaOHF9tMW9lsSwZa+Y8LFJW+8XYprvtSxAeVmu4+HGauEMtxkxpRw3RqeSgkoKtJJ6+Ob3oq6T4q1y5A== + dependencies: + "@babel/generator" ">=7" + "@babel/plugin-transform-runtime" ">=7" + "@babel/plugin-transform-template-literals" ">=7" + "@babel/preset-env" ">=7" + "@linaria/babel-preset" "^3.0.0-beta.17" + "@linaria/logger" "^3.0.0-beta.15" + "@linaria/preeval" "^3.0.0-beta.17" + babel-plugin-transform-react-remove-prop-types "^0.4.24" + ts-invariant "^0.9.0" + +"@linaria/stylelint@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/stylelint/-/stylelint-3.0.0-beta.17.tgz#9390b1194571fac618af27477adde4fff4d8c4aa" + integrity sha512-WdI5i1iToQJC4weUGqX/kmpybhzvn/CrDamP/iIjlkNgoZtDO21yzqdIMSZhtJPljSMY2G6bjf1vhXQ2189rWQ== + dependencies: + "@linaria/babel-preset" "^3.0.0-beta.17" + strip-ansi "^5.2.0" + +"@linaria/utils@^3.0.0-beta.15": + version "3.0.0-beta.15" + resolved "https://registry.npmmirror.com/@linaria/utils/-/utils-3.0.0-beta.15.tgz#001d8dacf113c443960651593144e64bf39e995a" + integrity sha512-CF0T8ueWjHK8zJT0oqdAq8JgL9a40WCyE5/t6q8WPvC7xRdsrfyUKA7Z8qEsQse2LKESVWJ5cvkkn8J80B6c+A== + +"@linaria/webpack4-loader@^3.0.0-beta.17": + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/@linaria/webpack4-loader/-/webpack4-loader-3.0.0-beta.17.tgz#1d46b94647d2a272a7200dc8fa53eb193b323a66" + integrity sha512-S+HInj7ui+0iH4KjjKj9bBEfh0MbBYj15cknVlY9H9QYl+5mQ6xedKHqZKq5x7jy4F1Ay9FglRDYMAUfoG5DSg== + dependencies: + "@linaria/babel-preset" "^3.0.0-beta.17" + "@linaria/logger" "^3.0.0-beta.15" + enhanced-resolve "^4.1.0" + loader-utils "^1.2.3" + mkdirp "^0.5.1" + +"@manaflair/redux-batch@^1.0.0": + version "1.0.0" + resolved "https://registry.npm.taobao.org/@manaflair/redux-batch/download/@manaflair/redux-batch-1.0.0.tgz#3af65dc3ac4ba81cf115c96f9759a6d4077b49f5" + integrity sha1-OvZdw6xLqBzxFclvl1mm1Ad7SfU= + +"@mrmlnc/readdir-enhanced@^2.2.1": + version "2.2.1" + resolved "https://registry.npm.taobao.org/@mrmlnc/readdir-enhanced/download/@mrmlnc/readdir-enhanced-2.2.1.tgz#524af240d1a360527b730475ecfa1344aa540dde" + integrity sha1-UkryQNGjYFJ7cwR17PoTRKpUDd4= + dependencies: + call-me-maybe "^1.0.1" + glob-to-regexp "^0.3.0" + +"@nodelib/fs.scandir@2.1.5": + version "2.1.5" + resolved "https://registry.nlark.com/@nodelib/fs.scandir/download/@nodelib/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" + integrity sha1-dhnC6yGyVIP20WdUi0z9WnSIw9U= + dependencies: + "@nodelib/fs.stat" "2.0.5" + run-parallel "^1.1.9" + +"@nodelib/fs.stat@2.0.5", "@nodelib/fs.stat@^2.0.2": + version "2.0.5" + resolved "https://registry.nlark.com/@nodelib/fs.stat/download/@nodelib/fs.stat-2.0.5.tgz?cache=0&sync_timestamp=1622792655362&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40nodelib%2Ffs.stat%2Fdownload%2F%40nodelib%2Ffs.stat-2.0.5.tgz#5bd262af94e9d25bd1e71b05deed44876a222e8b" + integrity sha1-W9Jir5Tp0lvR5xsF3u1Eh2oiLos= + +"@nodelib/fs.stat@^1.1.2": + version "1.1.3" + resolved "https://registry.nlark.com/@nodelib/fs.stat/download/@nodelib/fs.stat-1.1.3.tgz?cache=0&sync_timestamp=1622792655362&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40nodelib%2Ffs.stat%2Fdownload%2F%40nodelib%2Ffs.stat-1.1.3.tgz#2b5a3ab3f918cca48a8c754c08168e3f03eba61b" + integrity sha1-K1o6s/kYzKSKjHVMCBaOPwPrphs= + +"@nodelib/fs.walk@^1.2.3": + version "1.2.8" + resolved "https://registry.nlark.com/@nodelib/fs.walk/download/@nodelib/fs.walk-1.2.8.tgz?cache=0&sync_timestamp=1625769815389&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40nodelib%2Ffs.walk%2Fdownload%2F%40nodelib%2Ffs.walk-1.2.8.tgz#e95737e8bb6746ddedf69c556953494f196fe69a" + integrity sha1-6Vc36LtnRt3t9pxVaVNJTxlv5po= + dependencies: + "@nodelib/fs.scandir" "2.1.5" + fastq "^1.6.0" + +"@npmcli/fs@^1.0.0": + version "1.0.0" + resolved "https://registry.nlark.com/@npmcli/fs/download/@npmcli/fs-1.0.0.tgz?cache=0&sync_timestamp=1629999810191&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40npmcli%2Ffs%2Fdownload%2F%40npmcli%2Ffs-1.0.0.tgz#589612cfad3a6ea0feafcb901d29c63fd52db09f" + integrity sha1-WJYSz606bqD+r8uQHSnGP9UtsJ8= + dependencies: + "@gar/promisify" "^1.0.1" + semver "^7.3.5" + +"@npmcli/move-file@^1.0.1": + version "1.1.2" + resolved "https://registry.npm.taobao.org/@npmcli/move-file/download/@npmcli/move-file-1.1.2.tgz#1a82c3e372f7cae9253eb66d72543d6b8685c674" + integrity sha1-GoLD43L3yuklPrZtclQ9a4aFxnQ= + dependencies: + mkdirp "^1.0.4" + rimraf "^3.0.2" + +"@pmmmwh/react-refresh-webpack-plugin@0.4.3": + version "0.4.3" + resolved "https://registry.npmmirror.com/@pmmmwh/react-refresh-webpack-plugin/download/@pmmmwh/react-refresh-webpack-plugin-0.4.3.tgz#1eec460596d200c0236bf195b078a5d1df89b766" + integrity sha1-HuxGBZbSAMAja/GVsHil0d+Jt2Y= + dependencies: + ansi-html "^0.0.7" + error-stack-parser "^2.0.6" + html-entities "^1.2.1" + native-url "^0.2.6" + schema-utils "^2.6.5" + source-map "^0.7.3" + +"@polka/url@^1.0.0-next.20": + version "1.0.0-next.21" + resolved "https://registry.npmmirror.com/@polka/url/download/@polka/url-1.0.0-next.21.tgz?cache=0&sync_timestamp=1633093207048&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40polka%2Furl%2Fdownload%2F%40polka%2Furl-1.0.0-next.21.tgz#5de5a2385a35309427f6011992b544514d559aa1" + integrity sha1-XeWiOFo1MJQn9gEZkrVEUU1VmqE= + +"@redux-saga/core@^1.1.3": + version "1.1.3" + resolved "https://registry.npm.taobao.org/@redux-saga/core/download/@redux-saga/core-1.1.3.tgz#3085097b57a4ea8db5528d58673f20ce0950f6a4" + integrity sha1-MIUJe1ek6o21Uo1YZz8gzglQ9qQ= + dependencies: + "@babel/runtime" "^7.6.3" + "@redux-saga/deferred" "^1.1.2" + "@redux-saga/delay-p" "^1.1.2" + "@redux-saga/is" "^1.1.2" + "@redux-saga/symbols" "^1.1.2" + "@redux-saga/types" "^1.1.0" + redux "^4.0.4" + typescript-tuple "^2.2.1" + +"@redux-saga/deferred@^1.1.2": + version "1.1.2" + resolved "https://registry.npm.taobao.org/@redux-saga/deferred/download/@redux-saga/deferred-1.1.2.tgz#59937a0eba71fff289f1310233bc518117a71888" + integrity sha1-WZN6Drpx//KJ8TECM7xRgRenGIg= + +"@redux-saga/delay-p@^1.1.2": + version "1.1.2" + resolved "https://registry.nlark.com/@redux-saga/delay-p/download/@redux-saga/delay-p-1.1.2.tgz#8f515f4b009b05b02a37a7c3d0ca9ddc157bb355" + integrity sha1-j1FfSwCbBbAqN6fD0Mqd3BV7s1U= + dependencies: + "@redux-saga/symbols" "^1.1.2" + +"@redux-saga/is@^1.1.2": + version "1.1.2" + resolved "https://registry.npm.taobao.org/@redux-saga/is/download/@redux-saga/is-1.1.2.tgz#ae6c8421f58fcba80faf7cadb7d65b303b97e58e" + integrity sha1-rmyEIfWPy6gPr3ytt9ZbMDuX5Y4= + dependencies: + "@redux-saga/symbols" "^1.1.2" + "@redux-saga/types" "^1.1.0" + +"@redux-saga/symbols@^1.1.2": + version "1.1.2" + resolved "https://registry.nlark.com/@redux-saga/symbols/download/@redux-saga/symbols-1.1.2.tgz#216a672a487fc256872b8034835afc22a2d0595d" + integrity sha1-IWpnKkh/wlaHK4A0g1r8IqLQWV0= + +"@redux-saga/types@^1.1.0": + version "1.1.0" + resolved "https://registry.nlark.com/@redux-saga/types/download/@redux-saga/types-1.1.0.tgz#0e81ce56b4883b4b2a3001ebe1ab298b84237204" + integrity sha1-DoHOVrSIO0sqMAHr4aspi4QjcgQ= + +"@rollup/pluginutils@^4.1.0": + version "4.1.2" + resolved "https://registry.npmmirror.com/@rollup/pluginutils/-/pluginutils-4.1.2.tgz#ed5821c15e5e05e32816f5fb9ec607cdf5a75751" + integrity sha512-ROn4qvkxP9SyPeHaf7uQC/GPFY6L/OWy9+bd9AwcjOAWQwxRscoEyAUD8qCY5o5iL4jqQwoLk2kaTKJPb/HwzQ== + dependencies: + estree-walker "^2.0.1" + picomatch "^2.2.2" + +"@stencil/core@2.4.0": + version "2.4.0" + resolved "https://registry.npmmirror.com/@stencil/core/download/@stencil/core-2.4.0.tgz?cache=0&sync_timestamp=1635907563189&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40stencil%2Fcore%2Fdownload%2F%40stencil%2Fcore-2.4.0.tgz#17b45629c8986e35dcbce3f7dab7d64beede83f2" + integrity sha1-F7RWKciYbjXcvOP32rfWS+7eg/I= + +"@taroify/core@^0.0.28-alpha.1": + version "0.0.28-alpha.1" + resolved "https://registry.npmmirror.com/@taroify/core/-/core-0.0.28-alpha.1.tgz#c560a9cc0e5324c6170988ae78f1daa1c7c92bf5" + integrity sha512-NWsYkSj4IhLRRo1UCf0kbDNZfqTRteegcu1fFdkgmChRzDYSlQDtFmdNhMb94HPhqt/DYTKSPN6BsIZAPGmGfQ== + dependencies: + "@taroify/hooks" "^0.0.28-alpha.1" + "@taroify/icons" "^0.0.28-alpha.1" + classnames "^2.2.6" + lodash "^4.17.21" + promise "^8.1.0" + raf "^3.4.1" + react-is "^17.0.2" + react-transition-group "^4.4.1" + +"@taroify/hooks@^0.0.28-alpha.1": + version "0.0.28-alpha.1" + resolved "https://registry.npmmirror.com/@taroify/hooks/-/hooks-0.0.28-alpha.1.tgz#df31ee2e610d7a740bfb9a36f78c29c846327908" + integrity sha512-lEFGH+5jB/UnjTTZoAoVTcBDu8LoZvtSB4o5RJN3gjOWt2ekadsp+rIbpCyJugXU8EzjUxqu039fNgKrr33Gow== + dependencies: + "@vant/area-data" "^1.2.1" + lodash "^4.17.21" + react "^17.0.2" + +"@taroify/icons@^0.0.28-alpha.1": + version "0.0.28-alpha.1" + resolved "https://registry.npmmirror.com/@taroify/icons/-/icons-0.0.28-alpha.1.tgz#e767fbb125cd9488ac4b046e0858e0143b7174b4" + integrity sha512-v+pZBhi6VwNInMSVoZgz0DkcU55d1hE+koO/Elg7oNnxP6RB43KfhWWiEh71wqeGkM81KEO3ZylW1VFYFGqCSA== + dependencies: + classnames "^2.2.6" + +"@tarojs/api@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/api/download/@tarojs/api-3.3.12.tgz?cache=0&sync_timestamp=1635491347162&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fapi%2Fdownload%2F%40tarojs%2Fapi-3.3.12.tgz#4e1dd58511fca192c520aab4aae69b18397459dd" + integrity sha1-Th3VhRH8oZLFIKq0quabGDl0Wd0= + dependencies: + "@babel/runtime" "^7.11.2" + "@tarojs/runtime" "3.3.12" + +"@tarojs/components@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/components/download/@tarojs/components-3.3.12.tgz?cache=0&sync_timestamp=1635491346379&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fcomponents%2Fdownload%2F%40tarojs%2Fcomponents-3.3.12.tgz#07a4845e19df66350c3b00b0fc43c288d4a55fa3" + integrity sha1-B6SEXhnfZjUMOwCw/EPCiNSlX6M= + dependencies: + "@stencil/core" "2.4.0" + "@tarojs/taro" "3.3.12" + better-scroll "^1.14.1" + classnames "^2.2.5" + intersection-observer "^0.7.0" + omit.js "^1.0.0" + resolve-pathname "^3.0.0" + swiper "6.8.0" + weui "^1.1.2" + +"@tarojs/helper@2.2.18": + version "2.2.18" + resolved "https://registry.npmmirror.com/@tarojs/helper/download/@tarojs/helper-2.2.18.tgz#e0eb012d50bef3efe5e3bf7f5063d7270a7f6547" + integrity sha1-4OsBLVC+8+/l479/UGPXJwp/ZUc= + dependencies: + "@babel/core" "7.9.0" + "@babel/plugin-proposal-class-properties" "7.8.3" + "@babel/plugin-proposal-decorators" "7.8.3" + "@babel/plugin-proposal-object-rest-spread" "7.9.0" + "@babel/plugin-transform-runtime" "7.9.0" + "@babel/preset-env" "7.9.0" + "@babel/preset-typescript" "7.9.0" + "@babel/register" "7.9.0" + "@babel/runtime" "7.9.2" + "@tarojs/taro" "2.2.18" + babel-plugin-transform-react-jsx "^6.24.1" + chalk "3.0.0" + chokidar "3.3.1" + cross-spawn "7.0.1" + debug "4.1.1" + find-yarn-workspace-root "1.2.1" + fs-extra "8.1.0" + lodash "4.17.19" + resolve "^2.0.0-next.0" + yauzl "2.10.0" + +"@tarojs/helper@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/helper/download/@tarojs/helper-3.3.12.tgz?cache=0&sync_timestamp=1635490861426&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fhelper%2Fdownload%2F%40tarojs%2Fhelper-3.3.12.tgz#06b8f993e57e866b6f11935e6ad45cec46ff7df9" + integrity sha1-Brj5k+V+hmtvEZNeatRc7Eb/ffk= + dependencies: + "@babel/core" "^7.11.1" + "@babel/plugin-proposal-class-properties" "7.10.4" + "@babel/plugin-proposal-decorators" "7.10.5" + "@babel/plugin-proposal-object-rest-spread" "7.14.7" + "@babel/plugin-transform-runtime" "7.11.0" + "@babel/preset-env" "^7.11.0" + "@babel/preset-typescript" "7.12.17" + "@babel/register" "7.14.5" + "@babel/runtime" "^7.9.2" + "@tarojs/taro" "3.3.12" + chalk "3.0.0" + chokidar "3.3.1" + cross-spawn "7.0.3" + debug "4.1.1" + find-yarn-workspace-root "2.0.0" + fs-extra "8.1.0" + lodash "4.17.21" + resolve "1.15.1" + yauzl "2.10.0" + +"@tarojs/mini-runner@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/mini-runner/download/@tarojs/mini-runner-3.3.12.tgz?cache=0&sync_timestamp=1635491513598&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fmini-runner%2Fdownload%2F%40tarojs%2Fmini-runner-3.3.12.tgz#1f7d41e4bb72da1515479912e9e1c631eb99fe9e" + integrity sha1-H31B5Lty2hUVR5kS6eHGMeuZ/p4= + dependencies: + "@babel/core" "^7.11.1" + "@tarojs/helper" "3.3.12" + "@tarojs/plugin-platform-alipay" "3.3.12" + "@tarojs/plugin-platform-jd" "3.3.12" + "@tarojs/plugin-platform-qq" "3.3.12" + "@tarojs/plugin-platform-swan" "3.3.12" + "@tarojs/plugin-platform-tt" "3.3.12" + "@tarojs/plugin-platform-weapp" "3.3.12" + "@tarojs/runner-utils" "3.3.12" + "@tarojs/runtime" "3.3.12" + "@tarojs/shared" "3.3.12" + "@tarojs/taro" "3.3.12" + "@tarojs/taro-loader" "3.3.12" + babel-loader "8.2.1" + copy-webpack-plugin "5.1.2" + css "2.2.4" + css-loader "^3.0.0" + csso-webpack-plugin "2.0.0-beta.1" + file-loader "^6.0.0" + fs-extra "^8.0.1" + html-minifier "^4.0.0" + jsdom "^15.2.1" + less "^4.1.0" + less-loader "7.3.0" + loader-utils "^1.2.3" + lodash "^4.17.11" + md5 "^2.3.0" + micromatch "^4.0.2" + mini-css-extract-plugin "0.8.0" + miniprogram-simulate "^1.1.5" + mkdirp "^1.0.4" + ora "^3.4.0" + postcss "8.3.5" + postcss-html-transform "3.3.12" + postcss-import "12.0.1" + postcss-loader "4.3.0" + postcss-pxtransform "3.3.12" + postcss-url "8.0.0" + regenerator-runtime "0.11" + request "^2.88.0" + resolve "^1.11.1" + resolve-url-loader "4.0.0" + sass "1.32.11" + sass-loader "10.1.1" + sax "1.2.4" + stylus "^0.54.7" + stylus-loader "^3.0.2" + tapable "1.1.3" + terser-webpack-plugin "^3.0.5" + url-loader "^4.1.0" + vm2 "^3.8.4" + webpack "4.46.0" + webpack-chain "4.9.0" + webpack-format-messages "^2.0.5" + yauzl "2.10.0" + +"@tarojs/plugin-html@^3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/plugin-html/download/@tarojs/plugin-html-3.3.12.tgz#6b12b30fe260d9c55f488998e86799a4b316dd83" + integrity sha1-axKzD+Jg2cVfSImY6GeZpLMW3YM= + dependencies: + "@tarojs/shared" "3.3.12" + +"@tarojs/plugin-platform-alipay@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/plugin-platform-alipay/download/@tarojs/plugin-platform-alipay-3.3.12.tgz?cache=0&sync_timestamp=1635490862271&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fplugin-platform-alipay%2Fdownload%2F%40tarojs%2Fplugin-platform-alipay-3.3.12.tgz#91e9edb5970beec5331f5b0f491a374cbdb9caa5" + integrity sha1-kenttZcL7sUzH1sPSRo3TL25yqU= + dependencies: + "@tarojs/components" "3.3.12" + "@tarojs/service" "3.3.12" + "@tarojs/shared" "3.3.12" + +"@tarojs/plugin-platform-jd@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/plugin-platform-jd/download/@tarojs/plugin-platform-jd-3.3.12.tgz?cache=0&sync_timestamp=1635490862558&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fplugin-platform-jd%2Fdownload%2F%40tarojs%2Fplugin-platform-jd-3.3.12.tgz#f3a0334f8917b191d43229d37b2b0d3678e24a23" + integrity sha1-86AzT4kXsZHUMinTeysNNnjiSiM= + dependencies: + "@tarojs/service" "3.3.12" + "@tarojs/shared" "3.3.12" + +"@tarojs/plugin-platform-qq@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/plugin-platform-qq/download/@tarojs/plugin-platform-qq-3.3.12.tgz?cache=0&sync_timestamp=1635490862807&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fplugin-platform-qq%2Fdownload%2F%40tarojs%2Fplugin-platform-qq-3.3.12.tgz#fd626a271623ec88113ab7c116a76f6d61a72f17" + integrity sha1-/WJqJxYj7IgROrfBFqdvbWGnLxc= + dependencies: + "@tarojs/plugin-platform-weapp" "3.3.12" + "@tarojs/service" "3.3.12" + "@tarojs/shared" "3.3.12" + +"@tarojs/plugin-platform-swan@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/plugin-platform-swan/download/@tarojs/plugin-platform-swan-3.3.12.tgz?cache=0&sync_timestamp=1635490864143&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fplugin-platform-swan%2Fdownload%2F%40tarojs%2Fplugin-platform-swan-3.3.12.tgz#6efe486bd7b50ab800e831b68176aa5398945260" + integrity sha1-bv5Ia9e1CrgA6DG2gXaqU5iUUmA= + dependencies: + "@tarojs/components" "3.3.12" + "@tarojs/service" "3.3.12" + "@tarojs/shared" "3.3.12" + +"@tarojs/plugin-platform-tt@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/plugin-platform-tt/download/@tarojs/plugin-platform-tt-3.3.12.tgz?cache=0&sync_timestamp=1635490864699&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fplugin-platform-tt%2Fdownload%2F%40tarojs%2Fplugin-platform-tt-3.3.12.tgz#b14b006ab24bb174a187e412cec9e821181967c3" + integrity sha1-sUsAarJLsXShh+QSzsnoIRgZZ8M= + dependencies: + "@tarojs/service" "3.3.12" + "@tarojs/shared" "3.3.12" + +"@tarojs/plugin-platform-weapp@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/plugin-platform-weapp/download/@tarojs/plugin-platform-weapp-3.3.12.tgz?cache=0&sync_timestamp=1635490864457&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fplugin-platform-weapp%2Fdownload%2F%40tarojs%2Fplugin-platform-weapp-3.3.12.tgz#32c5a5e9637d36ba0b6ab60e62e34306ed2eddf3" + integrity sha1-MsWl6WN9NroLarYOYuNDBu0u3fM= + dependencies: + "@tarojs/components" "3.3.12" + "@tarojs/service" "3.3.12" + "@tarojs/shared" "3.3.12" + +"@tarojs/plugin-sass@^2.2.10": + version "2.2.10" + resolved "https://registry.npmmirror.com/@tarojs/plugin-sass/download/@tarojs/plugin-sass-2.2.10.tgz?cache=0&sync_timestamp=1635923804558&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fplugin-sass%2Fdownload%2F%40tarojs%2Fplugin-sass-2.2.10.tgz#b642b9f148ea26a1933a6b3870d0ca2154a68f0e" + integrity sha1-tkK58UjqJqGTOms4cNDKIVSmjw4= + dependencies: + "@tarojs/runner-utils" "^2.2.10" + "@tarojs/service" "^2.2.10" + node-sass "4.14.1" + resolve-url-loader "3.1.1" + sass-loader "8.0.2" + +"@tarojs/react@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/react/download/@tarojs/react-3.3.12.tgz#19ba29e2668fd02ed288c82faf4aa57c59acc09f" + integrity sha1-Gbop4maP0C7SiMgvr0qlfFmswJ8= + dependencies: + "@tarojs/runtime" "3.3.12" + "@tarojs/shared" "3.3.12" + react-reconciler "0.26.1" + scheduler "^0.20.1" + +"@tarojs/router@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/router/download/@tarojs/router-3.3.12.tgz?cache=0&sync_timestamp=1635491621860&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Frouter%2Fdownload%2F%40tarojs%2Frouter-3.3.12.tgz#ca25ee24e683046a5e1cd9374be1b69df563298f" + integrity sha1-yiXuJOaDBGpeHNk3S+G2nfVjKY8= + dependencies: + "@tarojs/runtime" "3.3.12" + history "^5.0.0" + query-string "^6.13.8" + universal-router "^8.3.0" + url-parse "^1.4.7" + +"@tarojs/runner-utils@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/runner-utils/download/@tarojs/runner-utils-3.3.12.tgz?cache=0&sync_timestamp=1635491514230&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Frunner-utils%2Fdownload%2F%40tarojs%2Frunner-utils-3.3.12.tgz#627d3959f24592cb6626345f04e83d0350038a49" + integrity sha1-Yn05WfJFkstmJjRfBOg9A1ADikk= + dependencies: + "@tarojs/helper" "3.3.12" + scss-bundle "^3.0.2" + +"@tarojs/runner-utils@^2.2.10": + version "2.2.18" + resolved "https://registry.npmmirror.com/@tarojs/runner-utils/download/@tarojs/runner-utils-2.2.18.tgz#16f8cf38528f0467e15a9e9c1be39e1aa6de7f5e" + integrity sha1-FvjPOFKPBGfhWp6cG+OeGqbef14= + dependencies: + scss-bundle "^3.0.2" + +"@tarojs/runtime@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/runtime/download/@tarojs/runtime-3.3.12.tgz?cache=0&sync_timestamp=1635491347581&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fruntime%2Fdownload%2F%40tarojs%2Fruntime-3.3.12.tgz#5729994e097ce71e1469ac0da4d37328ee21332c" + integrity sha1-VymZTgl85x4UaawNpNNzKO4hMyw= + dependencies: + "@tarojs/shared" "3.3.12" + inversify "5.1.1" + lodash-es "4.17.15" + reflect-metadata "^0.1.13" + +"@tarojs/service@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/service/download/@tarojs/service-3.3.12.tgz?cache=0&sync_timestamp=1635490865321&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fservice%2Fdownload%2F%40tarojs%2Fservice-3.3.12.tgz#4d304e71e59597bdc02f3b8291ac8303550abc58" + integrity sha1-TTBOceWVl73ALzuCkayDA1UKvFg= + dependencies: + "@hapi/joi" "17.1.1" + "@tarojs/helper" "3.3.12" + "@tarojs/shared" "3.3.12" + "@tarojs/taro" "3.3.12" + fs-extra "8.1.0" + lodash "4.17.21" + resolve "1.15.1" + tapable "1.1.3" + +"@tarojs/service@^2.2.10": + version "2.2.18" + resolved "https://registry.npmmirror.com/@tarojs/service/download/@tarojs/service-2.2.18.tgz#3b89903680fedb711b63e5069f7564bad6647e04" + integrity sha1-O4mQNoD+23EbY+UGn3VkutZkfgQ= + dependencies: + "@hapi/joi" "17.1.1" + "@tarojs/helper" "2.2.18" + "@tarojs/taro" "2.2.18" + fs-extra "8.1.0" + lodash "4.17.19" + resolve "1.15.1" + tapable "1.1.3" + +"@tarojs/shared@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/shared/download/@tarojs/shared-3.3.12.tgz?cache=0&sync_timestamp=1635490865596&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fshared%2Fdownload%2F%40tarojs%2Fshared-3.3.12.tgz#dd10de6842e3557057397fb665891b2f14bf3d05" + integrity sha1-3RDeaELjVXBXOX+2ZYkbLxS/PQU= + +"@tarojs/taro-h5@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/taro-h5/download/@tarojs/taro-h5-3.3.12.tgz?cache=0&sync_timestamp=1635491348236&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Ftaro-h5%2Fdownload%2F%40tarojs%2Ftaro-h5-3.3.12.tgz#af764122bacd9c84b718d1ff37792143a6f81c46" + integrity sha1-r3ZBIrrNnIS3GNH/N3khQ6b4HEY= + dependencies: + "@tarojs/api" "3.3.12" + "@tarojs/router" "3.3.12" + "@tarojs/runtime" "3.3.12" + base64-js "^1.3.0" + jsonp-retry "^1.0.3" + mobile-detect "^1.4.2" + raf "^3.4.1" + whatwg-fetch "^3.4.0" + +"@tarojs/taro-loader@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/taro-loader/download/@tarojs/taro-loader-3.3.12.tgz?cache=0&sync_timestamp=1635491516518&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Ftaro-loader%2Fdownload%2F%40tarojs%2Ftaro-loader-3.3.12.tgz#bcdf32895833612ff30df8f309a8acca41b47d15" + integrity sha1-vN8yiVgzYS/zDfjzCaisykG0fRU= + dependencies: + "@tarojs/helper" "3.3.12" + acorn "^8.0.4" + acorn-walk "^8.0.0" + loader-utils "^1.2.3" + +"@tarojs/taro@2.2.18": + version "2.2.18" + resolved "https://registry.npmmirror.com/@tarojs/taro/download/@tarojs/taro-2.2.18.tgz#bf13096a3f7776e67ef48c4fe6bd29f8cc2585d2" + integrity sha1-vxMJaj93duZ+9IxP5r0p+MwlhdI= + dependencies: + "@tarojs/utils" "2.2.18" + +"@tarojs/taro@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/taro/download/@tarojs/taro-3.3.12.tgz?cache=0&sync_timestamp=1635490846336&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Ftaro%2Fdownload%2F%40tarojs%2Ftaro-3.3.12.tgz#e562036a6d193077eabf4bfba122ba5e3680d13b" + integrity sha1-5WIDam0ZMHfqv0v7oSK6XjaA0Ts= + dependencies: + "@tarojs/api" "3.3.12" + "@tarojs/runtime" "3.3.12" + "@tarojs/taro-h5" "3.3.12" + +"@tarojs/utils@2.2.18": + version "2.2.18" + resolved "https://registry.npmmirror.com/@tarojs/utils/download/@tarojs/utils-2.2.18.tgz#86c94bb711a7ef461a64632c88c3233541fff686" + integrity sha1-hslLtxGn70YaZGMsiMMjNUH/9oY= + +"@tarojs/webpack-runner@3.3.12": + version "3.3.12" + resolved "https://registry.npmmirror.com/@tarojs/webpack-runner/download/@tarojs/webpack-runner-3.3.12.tgz?cache=0&sync_timestamp=1635491515115&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40tarojs%2Fwebpack-runner%2Fdownload%2F%40tarojs%2Fwebpack-runner-3.3.12.tgz#0a65eb2d4ca626352b7dca7fd589952a11a49129" + integrity sha1-CmXrLUymJjUrfcp/1YmVKhGkkSk= + dependencies: + "@babel/core" "^7.11.1" + "@pmmmwh/react-refresh-webpack-plugin" "0.4.3" + "@tarojs/helper" "3.3.12" + "@tarojs/runner-utils" "3.3.12" + "@tarojs/runtime" "3.3.12" + "@tarojs/shared" "3.3.12" + "@tarojs/taro-loader" "3.3.12" + autoprefixer "9.7.4" + babel-loader "8.2.1" + copy-webpack-plugin "5.1.1" + css-loader "3.4.2" + csso-webpack-plugin "2.0.0-beta.1" + detect-port "1.3.0" + file-loader "^6.0.0" + fs-extra "^5.0.0" + html-webpack-include-assets-plugin "1.0.5" + html-webpack-plugin "3.2.0" + less "^4.1.0" + less-loader "7.3.0" + lodash "4.17.21" + mini-css-extract-plugin "0.9.0" + open "7.0.2" + ora "4.0.3" + postcss "8.3.5" + postcss-loader "4.3.0" + postcss-plugin-constparse "3.3.12" + postcss-pxtransform "3.3.12" + react-refresh "0.9.0" + resolve "1.15.1" + resolve-url-loader "3.1.3" + sass "1.32.11" + sass-loader "10.1.1" + style-loader "1.3.0" + stylus "0.54.7" + stylus-loader "3.0.2" + terser-webpack-plugin "^3.0.5" + url-loader "^4.1.0" + webpack "4.46.0" + webpack-chain "4.9.0" + webpack-dev-server "3.11.0" + webpack-format-messages "^2.0.5" + +"@types/acorn@^4.0.5": + version "4.0.6" + resolved "https://registry.npmmirror.com/@types/acorn/download/@types/acorn-4.0.6.tgz#d61ca5480300ac41a7d973dd5b84d0a591154a22" + integrity sha1-1hylSAMArEGn2XPdW4TQpZEVSiI= + dependencies: + "@types/estree" "*" + +"@types/archy@^0.0.31": + version "0.0.31" + resolved "https://registry.nlark.com/@types/archy/download/@types/archy-0.0.31.tgz?cache=0&sync_timestamp=1629706690901&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Farchy%2Fdownload%2F%40types%2Farchy-0.0.31.tgz#01650a4641e7e1d11dbd64eda42eec9a2f829c7f" + integrity sha1-AWUKRkHn4dEdvWTtpC7smi+CnH8= + +"@types/debug@^4.1.5": + version "4.1.7" + resolved "https://registry.nlark.com/@types/debug/download/@types/debug-4.1.7.tgz?cache=0&sync_timestamp=1629707134396&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Fdebug%2Fdownload%2F%40types%2Fdebug-4.1.7.tgz#7cc0ea761509124709b8b2d1090d8f6c17aadb82" + integrity sha1-fMDqdhUJEkcJuLLRCQ2PbBeq24I= + dependencies: + "@types/ms" "*" + +"@types/deep-diff@^1.0.1": + version "1.0.1" + resolved "https://registry.nlark.com/@types/deep-diff/download/@types/deep-diff-1.0.1.tgz#eae15119c68b72b541731872a2883da89dc39396" + integrity sha1-6uFRGcaLcrVBcxhyoog9qJ3Dk5Y= + +"@types/downloadjs@^1.4.2": + version "1.4.2" + resolved "https://registry.nlark.com/@types/downloadjs/download/@types/downloadjs-1.4.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Fdownloadjs%2Fdownload%2F%40types%2Fdownloadjs-1.4.2.tgz#6734e60840cd8df3f0f8937c80e67efe7de6f886" + integrity sha1-ZzTmCEDNjfPw+JN8gOZ+/n3m+IY= + +"@types/estree@*": + version "0.0.50" + resolved "https://registry.npmmirror.com/@types/estree/download/@types/estree-0.0.50.tgz?cache=0&sync_timestamp=1637264753186&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40types%2Festree%2Fdownload%2F%40types%2Festree-0.0.50.tgz#1e0caa9364d3fccd2931c3ed96fdbeaa5d4cca83" + integrity sha1-Hgyqk2TT/M0pMcPtlv2+ql1MyoM= + +"@types/estree@0.0.41": + version "0.0.41" + resolved "https://registry.npmmirror.com/@types/estree/download/@types/estree-0.0.41.tgz?cache=0&sync_timestamp=1637264753186&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40types%2Festree%2Fdownload%2F%40types%2Festree-0.0.41.tgz#fd90754150b57432b72bf560530500597ff04421" + integrity sha1-/ZB1QVC1dDK3K/VgUwUAWX/wRCE= + +"@types/fs-extra@^8.0.1": + version "8.1.2" + resolved "https://registry.nlark.com/@types/fs-extra/download/@types/fs-extra-8.1.2.tgz#7125cc2e4bdd9bd2fc83005ffdb1d0ba00cca61f" + integrity sha1-cSXMLkvdm9L8gwBf/bHQugDMph8= + dependencies: + "@types/node" "*" + +"@types/glob@^7.1.1": + version "7.2.0" + resolved "https://registry.npmmirror.com/@types/glob/download/@types/glob-7.2.0.tgz#bc1b5bf3aa92f25bd5dd39f35c57361bdce5b2eb" + integrity sha1-vBtb86qS8lvV3TnzXFc2G9zlsus= + dependencies: + "@types/minimatch" "*" + "@types/node" "*" + +"@types/hoist-non-react-statics@^3.3.0": + version "3.3.1" + resolved "https://registry.nlark.com/@types/hoist-non-react-statics/download/@types/hoist-non-react-statics-3.3.1.tgz#1124aafe5118cb591977aeb1ceaaed1070eb039f" + integrity sha1-ESSq/lEYy1kZd66xzqrtEHDrA58= + dependencies: + "@types/react" "*" + hoist-non-react-statics "^3.3.0" + +"@types/jshint@^2.12.1": + version "2.12.1" + resolved "https://registry.nlark.com/@types/jshint/download/@types/jshint-2.12.1.tgz#eb38b787b666bc7db7037174a0c2ebce89f0432e" + integrity sha1-6zi3h7ZmvH23A3F0oMLrzonwQy4= + +"@types/json-schema@^7.0.5", "@types/json-schema@^7.0.7", "@types/json-schema@^7.0.8": + version "7.0.9" + resolved "https://registry.nlark.com/@types/json-schema/download/@types/json-schema-7.0.9.tgz?cache=0&sync_timestamp=1629708189890&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Fjson-schema%2Fdownload%2F%40types%2Fjson-schema-7.0.9.tgz#97edc9037ea0c38585320b28964dde3b39e4660d" + integrity sha1-l+3JA36gw4WFMgsolk3eOznkZg0= + +"@types/json5@^0.0.29": + version "0.0.29" + resolved "https://registry.nlark.com/@types/json5/download/@types/json5-0.0.29.tgz#ee28707ae94e11d2b827bcbe5270bcea7f3e71ee" + integrity sha1-7ihweulOEdK4J7y+UnC86n8+ce4= + +"@types/lodash.debounce@^4.0.6": + version "4.0.6" + resolved "https://registry.nlark.com/@types/lodash.debounce/download/@types/lodash.debounce-4.0.6.tgz?cache=0&sync_timestamp=1629708369772&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Flodash.debounce%2Fdownload%2F%40types%2Flodash.debounce-4.0.6.tgz#c5a2326cd3efc46566c47e4c0aa248dc0ee57d60" + integrity sha1-xaIybNPvxGVmxH5MCqJI3A7lfWA= + dependencies: + "@types/lodash" "*" + +"@types/lodash@*": + version "4.14.176" + resolved "https://registry.npmmirror.com/@types/lodash/download/@types/lodash-4.14.176.tgz?cache=0&sync_timestamp=1634769451849&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40types%2Flodash%2Fdownload%2F%40types%2Flodash-4.14.176.tgz#641150fc1cda36fbfa329de603bbb175d7ee20c0" + integrity sha1-ZBFQ/BzaNvv6Mp3mA7uxddfuIMA= + +"@types/minimatch@*": + version "3.0.5" + resolved "https://registry.nlark.com/@types/minimatch/download/@types/minimatch-3.0.5.tgz?cache=0&sync_timestamp=1629708301760&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Fminimatch%2Fdownload%2F%40types%2Fminimatch-3.0.5.tgz#1001cc5e6a3704b83c236027e77f2f58ea010f40" + integrity sha1-EAHMXmo3BLg8I2An538vWOoBD0A= + +"@types/ms@*": + version "0.7.31" + resolved "https://registry.nlark.com/@types/ms/download/@types/ms-0.7.31.tgz#31b7ca6407128a3d2bbc27fe2d21b345397f6197" + integrity sha1-MbfKZAcSij0rvCf+LSGzRTl/YZc= + +"@types/nanoid@^3.0.0": + version "3.0.0" + resolved "https://registry.nlark.com/@types/nanoid/download/@types/nanoid-3.0.0.tgz?cache=0&sync_timestamp=1621876608723&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Fnanoid%2Fdownload%2F%40types%2Fnanoid-3.0.0.tgz#c757b20f343f3a1dd76e80a9a431b6290fc20f35" + integrity sha1-x1eyDzQ/Oh3XboCppDG2KQ/CDzU= + dependencies: + nanoid "*" + +"@types/node@*": + version "16.11.6" + resolved "https://registry.npmmirror.com/@types/node/download/@types/node-16.11.6.tgz#6bef7a2a0ad684cf6e90fcfe31cecabd9ce0a3ae" + integrity sha1-a+96KgrWhM9ukPz+Mc7KvZzgo64= + +"@types/parse-json@^4.0.0": + version "4.0.0" + resolved "https://registry.nlark.com/@types/parse-json/download/@types/parse-json-4.0.0.tgz#2f8bb441434d163b35fb8ffdccd7138927ffb8c0" + integrity sha1-L4u0QUNNFjs1+4/9zNcTiSf/uMA= + +"@types/prop-types@*": + version "15.7.4" + resolved "https://registry.nlark.com/@types/prop-types/download/@types/prop-types-15.7.4.tgz?cache=0&sync_timestamp=1629708829833&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Fprop-types%2Fdownload%2F%40types%2Fprop-types-15.7.4.tgz#fcf7205c25dff795ee79af1e30da2c9790808f11" + integrity sha1-/PcgXCXf95Xuea8eMNosl5CAjxE= + +"@types/react-redux@^7.1.20": + version "7.1.20" + resolved "https://registry.npmmirror.com/@types/react-redux/download/@types/react-redux-7.1.20.tgz?cache=0&sync_timestamp=1634765514657&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40types%2Freact-redux%2Fdownload%2F%40types%2Freact-redux-7.1.20.tgz#42f0e61ababb621e12c66c96dda94c58423bd7df" + integrity sha1-QvDmGrq7Yh4SxmyW3alMWEI7198= + dependencies: + "@types/hoist-non-react-statics" "^3.3.0" + "@types/react" "*" + hoist-non-react-statics "^3.3.0" + redux "^4.0.0" + +"@types/react@*", "@types/react@^17.0.2": + version "17.0.34" + resolved "https://registry.npmmirror.com/@types/react/download/@types/react-17.0.34.tgz#797b66d359b692e3f19991b6b07e4b0c706c0102" + integrity sha1-eXtm01m2kuPxmZG2sH5LDHBsAQI= + dependencies: + "@types/prop-types" "*" + "@types/scheduler" "*" + csstype "^3.0.2" + +"@types/sass@^1.16.0": + version "1.43.0" + resolved "https://registry.npmmirror.com/@types/sass/download/@types/sass-1.43.0.tgz?cache=0&sync_timestamp=1635488596928&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40types%2Fsass%2Fdownload%2F%40types%2Fsass-1.43.0.tgz#b4cebe057d887ed66dc6813fd6cbef22043057bb" + integrity sha1-tM6+BX2IftZtxoE/1svvIgQwV7s= + dependencies: + "@types/node" "*" + +"@types/scheduler@*": + version "0.16.2" + resolved "https://registry.nlark.com/@types/scheduler/download/@types/scheduler-0.16.2.tgz?cache=0&sync_timestamp=1629709152024&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Fscheduler%2Fdownload%2F%40types%2Fscheduler-0.16.2.tgz#1a62f89525723dde24ba1b01b092bf5df8ad4d39" + integrity sha1-GmL4lSVyPd4kuhsBsJK/XfitTTk= + +"@types/toposort@^2.0.3": + version "2.0.3" + resolved "https://registry.nlark.com/@types/toposort/download/@types/toposort-2.0.3.tgz?cache=0&sync_timestamp=1629709476850&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40types%2Ftoposort%2Fdownload%2F%40types%2Ftoposort-2.0.3.tgz#dc490842b77c3e910c8d727ff0bdb2fb124cb41b" + integrity sha1-3EkIQrd8PpEMjXJ/8L2y+xJMtBs= + +"@types/webpack-env@^1.13.6": + version "1.16.3" + resolved "https://registry.npmmirror.com/@types/webpack-env/download/@types/webpack-env-1.16.3.tgz#b776327a73e561b71e7881d0cd6d34a1424db86a" + integrity sha1-t3YyenPlYbceeIHQzW00oUJNuGo= + +"@typescript-eslint/eslint-plugin@^4.15.1": + version "4.33.0" + resolved "https://registry.npmmirror.com/@typescript-eslint/eslint-plugin/download/@typescript-eslint/eslint-plugin-4.33.0.tgz#c24dc7c8069c7706bc40d99f6fa87edcb2005276" + integrity sha1-wk3HyAacdwa8QNmfb6h+3LIAUnY= + dependencies: + "@typescript-eslint/experimental-utils" "4.33.0" + "@typescript-eslint/scope-manager" "4.33.0" + debug "^4.3.1" + functional-red-black-tree "^1.0.1" + ignore "^5.1.8" + regexpp "^3.1.0" + semver "^7.3.5" + tsutils "^3.21.0" + +"@typescript-eslint/experimental-utils@4.33.0": + version "4.33.0" + resolved "https://registry.npmmirror.com/@typescript-eslint/experimental-utils/download/@typescript-eslint/experimental-utils-4.33.0.tgz?cache=0&sync_timestamp=1635789018599&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40typescript-eslint%2Fexperimental-utils%2Fdownload%2F%40typescript-eslint%2Fexperimental-utils-4.33.0.tgz#6f2a786a4209fa2222989e9380b5331b2810f7fd" + integrity sha1-byp4akIJ+iIimJ6TgLUzGygQ9/0= + dependencies: + "@types/json-schema" "^7.0.7" + "@typescript-eslint/scope-manager" "4.33.0" + "@typescript-eslint/types" "4.33.0" + "@typescript-eslint/typescript-estree" "4.33.0" + eslint-scope "^5.1.1" + eslint-utils "^3.0.0" + +"@typescript-eslint/parser@^4.15.1": + version "4.33.0" + resolved "https://registry.npmmirror.com/@typescript-eslint/parser/download/@typescript-eslint/parser-4.33.0.tgz#dfe797570d9694e560528d18eecad86c8c744899" + integrity sha1-3+eXVw2WlOVgUo0Y7srYbIx0SJk= + dependencies: + "@typescript-eslint/scope-manager" "4.33.0" + "@typescript-eslint/types" "4.33.0" + "@typescript-eslint/typescript-estree" "4.33.0" + debug "^4.3.1" + +"@typescript-eslint/scope-manager@4.33.0": + version "4.33.0" + resolved "https://registry.npmmirror.com/@typescript-eslint/scope-manager/download/@typescript-eslint/scope-manager-4.33.0.tgz#d38e49280d983e8772e29121cf8c6e9221f280a3" + integrity sha1-045JKA2YPody4pEhz4xukiHygKM= + dependencies: + "@typescript-eslint/types" "4.33.0" + "@typescript-eslint/visitor-keys" "4.33.0" + +"@typescript-eslint/types@4.33.0": + version "4.33.0" + resolved "https://registry.npmmirror.com/@typescript-eslint/types/download/@typescript-eslint/types-4.33.0.tgz?cache=0&sync_timestamp=1635789264588&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40typescript-eslint%2Ftypes%2Fdownload%2F%40typescript-eslint%2Ftypes-4.33.0.tgz#a1e59036a3b53ae8430ceebf2a919dc7f9af6d72" + integrity sha1-oeWQNqO1OuhDDO6/KpGdx/mvbXI= + +"@typescript-eslint/typescript-estree@4.33.0": + version "4.33.0" + resolved "https://registry.npmmirror.com/@typescript-eslint/typescript-estree/download/@typescript-eslint/typescript-estree-4.33.0.tgz#0dfb51c2908f68c5c08d82aefeaf166a17c24609" + integrity sha1-DftRwpCPaMXAjYKu/q8WahfCRgk= + dependencies: + "@typescript-eslint/types" "4.33.0" + "@typescript-eslint/visitor-keys" "4.33.0" + debug "^4.3.1" + globby "^11.0.3" + is-glob "^4.0.1" + semver "^7.3.5" + tsutils "^3.21.0" + +"@typescript-eslint/visitor-keys@4.33.0": + version "4.33.0" + resolved "https://registry.npmmirror.com/@typescript-eslint/visitor-keys/download/@typescript-eslint/visitor-keys-4.33.0.tgz#2a22f77a41604289b7a186586e9ec48ca92ef1dd" + integrity sha1-KiL3ekFgQom3oYZYbp7EjKku8d0= + dependencies: + "@typescript-eslint/types" "4.33.0" + eslint-visitor-keys "^2.0.0" + +"@vant/area-data@^1.2.1": + version "1.2.2" + resolved "https://registry.npmmirror.com/@vant/area-data/-/area-data-1.2.2.tgz#1b0559ee93661663d10d3766bcde15ab35ff3fcd" + integrity sha512-efv7Yl/OTHjyy0irhJJPtgZb5mJZmroEtVOa8vkGRNTLY93+NgEcVuIBaC35hYCMsTrPHDQRvQGnI9Hyhtto0Q== + +"@vue/babel-helper-vue-jsx-merge-props@^1.2.1": + version "1.2.1" + resolved "https://registry.npm.taobao.org/@vue/babel-helper-vue-jsx-merge-props/download/@vue/babel-helper-vue-jsx-merge-props-1.2.1.tgz?cache=0&sync_timestamp=1602851122331&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40vue%2Fbabel-helper-vue-jsx-merge-props%2Fdownload%2F%40vue%2Fbabel-helper-vue-jsx-merge-props-1.2.1.tgz#31624a7a505fb14da1d58023725a4c5f270e6a81" + integrity sha1-MWJKelBfsU2h1YAjclpMXycOaoE= + +"@vue/babel-helper-vue-transform-on@^1.0.2": + version "1.0.2" + resolved "https://registry.nlark.com/@vue/babel-helper-vue-transform-on/download/@vue/babel-helper-vue-transform-on-1.0.2.tgz#9b9c691cd06fc855221a2475c3cc831d774bc7dc" + integrity sha1-m5xpHNBvyFUiGiR1w8yDHXdLx9w= + +"@vue/babel-plugin-jsx@^1.0.6": + version "1.1.1" + resolved "https://registry.npmmirror.com/@vue/babel-plugin-jsx/download/@vue/babel-plugin-jsx-1.1.1.tgz?cache=0&sync_timestamp=1634464314876&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2F%40vue%2Fbabel-plugin-jsx%2Fdownload%2F%40vue%2Fbabel-plugin-jsx-1.1.1.tgz#0c5bac27880d23f89894cd036a37b55ef61ddfc1" + integrity sha1-DFusJ4gNI/iYlM0Daje1XvYd38E= + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/plugin-syntax-jsx" "^7.0.0" + "@babel/template" "^7.0.0" + "@babel/traverse" "^7.0.0" + "@babel/types" "^7.0.0" + "@vue/babel-helper-vue-transform-on" "^1.0.2" + camelcase "^6.0.0" + html-tags "^3.1.0" + svg-tags "^1.0.0" + +"@vue/babel-plugin-transform-vue-jsx@^1.2.1": + version "1.2.1" + resolved "https://registry.npm.taobao.org/@vue/babel-plugin-transform-vue-jsx/download/@vue/babel-plugin-transform-vue-jsx-1.2.1.tgz?cache=0&sync_timestamp=1602851121024&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40vue%2Fbabel-plugin-transform-vue-jsx%2Fdownload%2F%40vue%2Fbabel-plugin-transform-vue-jsx-1.2.1.tgz#646046c652c2f0242727f34519d917b064041ed7" + integrity sha1-ZGBGxlLC8CQnJ/NFGdkXsGQEHtc= + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/plugin-syntax-jsx" "^7.2.0" + "@vue/babel-helper-vue-jsx-merge-props" "^1.2.1" + html-tags "^2.0.0" + lodash.kebabcase "^4.1.1" + svg-tags "^1.0.0" + +"@vue/babel-preset-jsx@^1.2.4": + version "1.2.4" + resolved "https://registry.npm.taobao.org/@vue/babel-preset-jsx/download/@vue/babel-preset-jsx-1.2.4.tgz#92fea79db6f13b01e80d3a0099e2924bdcbe4e87" + integrity sha1-kv6nnbbxOwHoDToAmeKSS9y+Toc= + dependencies: + "@vue/babel-helper-vue-jsx-merge-props" "^1.2.1" + "@vue/babel-plugin-transform-vue-jsx" "^1.2.1" + "@vue/babel-sugar-composition-api-inject-h" "^1.2.1" + "@vue/babel-sugar-composition-api-render-instance" "^1.2.4" + "@vue/babel-sugar-functional-vue" "^1.2.2" + "@vue/babel-sugar-inject-h" "^1.2.2" + "@vue/babel-sugar-v-model" "^1.2.3" + "@vue/babel-sugar-v-on" "^1.2.3" + +"@vue/babel-sugar-composition-api-inject-h@^1.2.1": + version "1.2.1" + resolved "https://registry.nlark.com/@vue/babel-sugar-composition-api-inject-h/download/@vue/babel-sugar-composition-api-inject-h-1.2.1.tgz#05d6e0c432710e37582b2be9a6049b689b6f03eb" + integrity sha1-BdbgxDJxDjdYKyvppgSbaJtvA+s= + dependencies: + "@babel/plugin-syntax-jsx" "^7.2.0" + +"@vue/babel-sugar-composition-api-render-instance@^1.2.4": + version "1.2.4" + resolved "https://registry.npm.taobao.org/@vue/babel-sugar-composition-api-render-instance/download/@vue/babel-sugar-composition-api-render-instance-1.2.4.tgz#e4cbc6997c344fac271785ad7a29325c51d68d19" + integrity sha1-5MvGmXw0T6wnF4WteikyXFHWjRk= + dependencies: + "@babel/plugin-syntax-jsx" "^7.2.0" + +"@vue/babel-sugar-functional-vue@^1.2.2": + version "1.2.2" + resolved "https://registry.nlark.com/@vue/babel-sugar-functional-vue/download/@vue/babel-sugar-functional-vue-1.2.2.tgz#267a9ac8d787c96edbf03ce3f392c49da9bd2658" + integrity sha1-JnqayNeHyW7b8Dzj85LEnam9Jlg= + dependencies: + "@babel/plugin-syntax-jsx" "^7.2.0" + +"@vue/babel-sugar-inject-h@^1.2.2": + version "1.2.2" + resolved "https://registry.nlark.com/@vue/babel-sugar-inject-h/download/@vue/babel-sugar-inject-h-1.2.2.tgz#d738d3c893367ec8491dcbb669b000919293e3aa" + integrity sha1-1zjTyJM2fshJHcu2abAAkZKT46o= + dependencies: + "@babel/plugin-syntax-jsx" "^7.2.0" + +"@vue/babel-sugar-v-model@^1.2.3": + version "1.2.3" + resolved "https://registry.nlark.com/@vue/babel-sugar-v-model/download/@vue/babel-sugar-v-model-1.2.3.tgz#fa1f29ba51ebf0aa1a6c35fa66d539bc459a18f2" + integrity sha1-+h8pulHr8KoabDX6ZtU5vEWaGPI= + dependencies: + "@babel/plugin-syntax-jsx" "^7.2.0" + "@vue/babel-helper-vue-jsx-merge-props" "^1.2.1" + "@vue/babel-plugin-transform-vue-jsx" "^1.2.1" + camelcase "^5.0.0" + html-tags "^2.0.0" + svg-tags "^1.0.0" + +"@vue/babel-sugar-v-on@^1.2.3": + version "1.2.3" + resolved "https://registry.nlark.com/@vue/babel-sugar-v-on/download/@vue/babel-sugar-v-on-1.2.3.tgz#342367178586a69f392f04bfba32021d02913ada" + integrity sha1-NCNnF4WGpp85LwS/ujICHQKROto= + dependencies: + "@babel/plugin-syntax-jsx" "^7.2.0" + "@vue/babel-plugin-transform-vue-jsx" "^1.2.1" + camelcase "^5.0.0" + +"@webassemblyjs/ast@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/ast/download/@webassemblyjs/ast-1.9.0.tgz?cache=0&sync_timestamp=1625473459015&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fast%2Fdownload%2F%40webassemblyjs%2Fast-1.9.0.tgz#bd850604b4042459a5a41cd7d338cbed695ed964" + integrity sha1-vYUGBLQEJFmlpBzX0zjL7Wle2WQ= + dependencies: + "@webassemblyjs/helper-module-context" "1.9.0" + "@webassemblyjs/helper-wasm-bytecode" "1.9.0" + "@webassemblyjs/wast-parser" "1.9.0" + +"@webassemblyjs/floating-point-hex-parser@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/floating-point-hex-parser/download/@webassemblyjs/floating-point-hex-parser-1.9.0.tgz#3c3d3b271bddfc84deb00f71344438311d52ffb4" + integrity sha1-PD07Jxvd/ITesA9xNEQ4MR1S/7Q= + +"@webassemblyjs/helper-api-error@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/helper-api-error/download/@webassemblyjs/helper-api-error-1.9.0.tgz?cache=0&sync_timestamp=1625473346773&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fhelper-api-error%2Fdownload%2F%40webassemblyjs%2Fhelper-api-error-1.9.0.tgz#203f676e333b96c9da2eeab3ccef33c45928b6a2" + integrity sha1-ID9nbjM7lsnaLuqzzO8zxFkotqI= + +"@webassemblyjs/helper-buffer@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/helper-buffer/download/@webassemblyjs/helper-buffer-1.9.0.tgz?cache=0&sync_timestamp=1625473344792&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fhelper-buffer%2Fdownload%2F%40webassemblyjs%2Fhelper-buffer-1.9.0.tgz#a1442d269c5feb23fcbc9ef759dac3547f29de00" + integrity sha1-oUQtJpxf6yP8vJ73WdrDVH8p3gA= + +"@webassemblyjs/helper-code-frame@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/helper-code-frame/download/@webassemblyjs/helper-code-frame-1.9.0.tgz#647f8892cd2043a82ac0c8c5e75c36f1d9159f27" + integrity sha1-ZH+Iks0gQ6gqwMjF51w28dkVnyc= + dependencies: + "@webassemblyjs/wast-printer" "1.9.0" + +"@webassemblyjs/helper-fsm@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/helper-fsm/download/@webassemblyjs/helper-fsm-1.9.0.tgz#c05256b71244214671f4b08ec108ad63b70eddb8" + integrity sha1-wFJWtxJEIUZx9LCOwQitY7cO3bg= + +"@webassemblyjs/helper-module-context@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/helper-module-context/download/@webassemblyjs/helper-module-context-1.9.0.tgz#25d8884b76839871a08a6c6f806c3979ef712f07" + integrity sha1-JdiIS3aDmHGgimxvgGw5ee9xLwc= + dependencies: + "@webassemblyjs/ast" "1.9.0" + +"@webassemblyjs/helper-wasm-bytecode@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/helper-wasm-bytecode/download/@webassemblyjs/helper-wasm-bytecode-1.9.0.tgz#4fed8beac9b8c14f8c58b70d124d549dd1fe5790" + integrity sha1-T+2L6sm4wU+MWLcNEk1UndH+V5A= + +"@webassemblyjs/helper-wasm-section@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/helper-wasm-section/download/@webassemblyjs/helper-wasm-section-1.9.0.tgz?cache=0&sync_timestamp=1625473466570&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fhelper-wasm-section%2Fdownload%2F%40webassemblyjs%2Fhelper-wasm-section-1.9.0.tgz#5a4138d5a6292ba18b04c5ae49717e4167965346" + integrity sha1-WkE41aYpK6GLBMWuSXF+QWeWU0Y= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/helper-buffer" "1.9.0" + "@webassemblyjs/helper-wasm-bytecode" "1.9.0" + "@webassemblyjs/wasm-gen" "1.9.0" + +"@webassemblyjs/ieee754@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/ieee754/download/@webassemblyjs/ieee754-1.9.0.tgz#15c7a0fbaae83fb26143bbacf6d6df1702ad39e4" + integrity sha1-Fceg+6roP7JhQ7us9tbfFwKtOeQ= + dependencies: + "@xtuc/ieee754" "^1.2.0" + +"@webassemblyjs/leb128@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/leb128/download/@webassemblyjs/leb128-1.9.0.tgz?cache=0&sync_timestamp=1625473342433&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fleb128%2Fdownload%2F%40webassemblyjs%2Fleb128-1.9.0.tgz#f19ca0b76a6dc55623a09cffa769e838fa1e1c95" + integrity sha1-8Zygt2ptxVYjoJz/p2noOPoeHJU= + dependencies: + "@xtuc/long" "4.2.2" + +"@webassemblyjs/utf8@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/utf8/download/@webassemblyjs/utf8-1.9.0.tgz#04d33b636f78e6a6813227e82402f7637b6229ab" + integrity sha1-BNM7Y2945qaBMifoJAL3Y3tiKas= + +"@webassemblyjs/wasm-edit@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/wasm-edit/download/@webassemblyjs/wasm-edit-1.9.0.tgz?cache=0&sync_timestamp=1625473463093&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fwasm-edit%2Fdownload%2F%40webassemblyjs%2Fwasm-edit-1.9.0.tgz#3fe6d79d3f0f922183aa86002c42dd256cfee9cf" + integrity sha1-P+bXnT8PkiGDqoYALELdJWz+6c8= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/helper-buffer" "1.9.0" + "@webassemblyjs/helper-wasm-bytecode" "1.9.0" + "@webassemblyjs/helper-wasm-section" "1.9.0" + "@webassemblyjs/wasm-gen" "1.9.0" + "@webassemblyjs/wasm-opt" "1.9.0" + "@webassemblyjs/wasm-parser" "1.9.0" + "@webassemblyjs/wast-printer" "1.9.0" + +"@webassemblyjs/wasm-gen@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/wasm-gen/download/@webassemblyjs/wasm-gen-1.9.0.tgz?cache=0&sync_timestamp=1625473361759&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fwasm-gen%2Fdownload%2F%40webassemblyjs%2Fwasm-gen-1.9.0.tgz#50bc70ec68ded8e2763b01a1418bf43491a7a49c" + integrity sha1-ULxw7Gje2OJ2OwGhQYv0NJGnpJw= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/helper-wasm-bytecode" "1.9.0" + "@webassemblyjs/ieee754" "1.9.0" + "@webassemblyjs/leb128" "1.9.0" + "@webassemblyjs/utf8" "1.9.0" + +"@webassemblyjs/wasm-opt@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/wasm-opt/download/@webassemblyjs/wasm-opt-1.9.0.tgz?cache=0&sync_timestamp=1625473467198&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fwasm-opt%2Fdownload%2F%40webassemblyjs%2Fwasm-opt-1.9.0.tgz#2211181e5b31326443cc8112eb9f0b9028721a61" + integrity sha1-IhEYHlsxMmRDzIES658LkChyGmE= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/helper-buffer" "1.9.0" + "@webassemblyjs/wasm-gen" "1.9.0" + "@webassemblyjs/wasm-parser" "1.9.0" + +"@webassemblyjs/wasm-parser@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/wasm-parser/download/@webassemblyjs/wasm-parser-1.9.0.tgz?cache=0&sync_timestamp=1625473464593&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fwasm-parser%2Fdownload%2F%40webassemblyjs%2Fwasm-parser-1.9.0.tgz#9d48e44826df4a6598294aa6c87469d642fff65e" + integrity sha1-nUjkSCbfSmWYKUqmyHRp1kL/9l4= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/helper-api-error" "1.9.0" + "@webassemblyjs/helper-wasm-bytecode" "1.9.0" + "@webassemblyjs/ieee754" "1.9.0" + "@webassemblyjs/leb128" "1.9.0" + "@webassemblyjs/utf8" "1.9.0" + +"@webassemblyjs/wast-parser@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/wast-parser/download/@webassemblyjs/wast-parser-1.9.0.tgz?cache=0&sync_timestamp=1625473373987&other_urls=https%3A%2F%2Fregistry.nlark.com%2F%40webassemblyjs%2Fwast-parser%2Fdownload%2F%40webassemblyjs%2Fwast-parser-1.9.0.tgz#3031115d79ac5bd261556cecc3fa90a3ef451914" + integrity sha1-MDERXXmsW9JhVWzsw/qQo+9FGRQ= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/floating-point-hex-parser" "1.9.0" + "@webassemblyjs/helper-api-error" "1.9.0" + "@webassemblyjs/helper-code-frame" "1.9.0" + "@webassemblyjs/helper-fsm" "1.9.0" + "@xtuc/long" "4.2.2" + +"@webassemblyjs/wast-printer@1.9.0": + version "1.9.0" + resolved "https://registry.nlark.com/@webassemblyjs/wast-printer/download/@webassemblyjs/wast-printer-1.9.0.tgz#4935d54c85fef637b00ce9f52377451d00d47899" + integrity sha1-STXVTIX+9jewDOn1I3dFHQDUeJk= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/wast-parser" "1.9.0" + "@xtuc/long" "4.2.2" + +"@xtuc/ieee754@^1.2.0": + version "1.2.0" + resolved "https://registry.nlark.com/@xtuc/ieee754/download/@xtuc/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790" + integrity sha1-7vAUoxRa5Hehy8AM0eVSM23Ot5A= + +"@xtuc/long@4.2.2": + version "4.2.2" + resolved "https://registry.nlark.com/@xtuc/long/download/@xtuc/long-4.2.2.tgz#d291c6a4e97989b5c61d9acf396ae4fe133a718d" + integrity sha1-0pHGpOl5ibXGHZrPOWrk/hM6cY0= + +abab@^2.0.0: + version "2.0.5" + resolved "https://registry.nlark.com/abab/download/abab-2.0.5.tgz#c0b678fb32d60fc1219c784d6a826fe385aeb79a" + integrity sha1-wLZ4+zLWD8EhnHhNaoJv44Wut5o= + +abbrev@1: + version "1.1.1" + resolved "https://registry.nlark.com/abbrev/download/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" + integrity sha1-+PLIh60Qv2f2NPAFtph/7TF5qsg= + +accepts@~1.3.4, accepts@~1.3.5, accepts@~1.3.7: + version "1.3.7" + resolved "https://registry.npm.taobao.org/accepts/download/accepts-1.3.7.tgz#531bc726517a3b2b41f850021c6cc15eaab507cd" + integrity sha1-UxvHJlF6OytB+FACHGzBXqq1B80= + dependencies: + mime-types "~2.1.24" + negotiator "0.6.2" + +acorn-globals@^4.3.2: + version "4.3.4" + resolved "https://registry.nlark.com/acorn-globals/download/acorn-globals-4.3.4.tgz#9fa1926addc11c97308c4e66d7add0d40c3272e7" + integrity sha1-n6GSat3BHJcwjE5m163Q1Awycuc= + dependencies: + acorn "^6.0.1" + acorn-walk "^6.0.1" + +acorn-jsx@^5.2.0: + version "5.3.2" + resolved "https://registry.nlark.com/acorn-jsx/download/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" + integrity sha1-ftW7VZCLOy8bxVxq8WU7rafweTc= + +acorn-walk@^6.0.1: + version "6.2.0" + resolved "https://registry.nlark.com/acorn-walk/download/acorn-walk-6.2.0.tgz#123cb8f3b84c2171f1f7fb252615b1c78a6b1a8c" + integrity sha1-Ejy487hMIXHx9/slJhWxx4prGow= + +acorn-walk@^8.0.0: + version "8.2.0" + resolved "https://registry.nlark.com/acorn-walk/download/acorn-walk-8.2.0.tgz#741210f2e2426454508853a2f44d0ab83b7f69c1" + integrity sha1-dBIQ8uJCZFRQiFOi9E0KuDt/acE= + +acorn@^6.0.1, acorn@^6.4.1: + version "6.4.2" + resolved "https://registry.nlark.com/acorn/download/acorn-6.4.2.tgz#35866fd710528e92de10cf06016498e47e39e1e6" + integrity sha1-NYZv1xBSjpLeEM8GAWSY5H454eY= + +acorn@^7.1.0, acorn@^7.1.1: + version "7.4.1" + resolved "https://registry.nlark.com/acorn/download/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" + integrity sha1-/q7SVZc9LndVW4PbwIhRpsY1IPo= + +acorn@^8.0.4: + version "8.5.0" + resolved "https://registry.nlark.com/acorn/download/acorn-8.5.0.tgz#4512ccb99b3698c752591e9bb4472e38ad43cee2" + integrity sha1-RRLMuZs2mMdSWR6btEcuOK1DzuI= + +address@^1.0.1: + version "1.1.2" + resolved "https://registry.npm.taobao.org/address/download/address-1.1.2.tgz#bf1116c9c758c51b7a933d296b72c221ed9428b6" + integrity sha1-vxEWycdYxRt6kz0pa3LCIe2UKLY= + +adjust-sourcemap-loader@2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/adjust-sourcemap-loader/download/adjust-sourcemap-loader-2.0.0.tgz?cache=0&sync_timestamp=1603701108010&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fadjust-sourcemap-loader%2Fdownload%2Fadjust-sourcemap-loader-2.0.0.tgz#6471143af75ec02334b219f54bc7970c52fb29a4" + integrity sha1-ZHEUOvdewCM0shn1S8eXDFL7KaQ= + dependencies: + assert "1.4.1" + camelcase "5.0.0" + loader-utils "1.2.3" + object-path "0.11.4" + regex-parser "2.2.10" + +adjust-sourcemap-loader@3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/adjust-sourcemap-loader/download/adjust-sourcemap-loader-3.0.0.tgz?cache=0&sync_timestamp=1603701108010&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fadjust-sourcemap-loader%2Fdownload%2Fadjust-sourcemap-loader-3.0.0.tgz#5ae12fb5b7b1c585e80bbb5a63ec163a1a45e61e" + integrity sha1-WuEvtbexxYXoC7taY+wWOhpF5h4= + dependencies: + loader-utils "^2.0.0" + regex-parser "^2.2.11" + +adjust-sourcemap-loader@^4.0.0: + version "4.0.0" + resolved "https://registry.npm.taobao.org/adjust-sourcemap-loader/download/adjust-sourcemap-loader-4.0.0.tgz?cache=0&sync_timestamp=1603701108010&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fadjust-sourcemap-loader%2Fdownload%2Fadjust-sourcemap-loader-4.0.0.tgz#fc4a0fd080f7d10471f30a7320f25560ade28c99" + integrity sha1-/EoP0ID30QRx8wpzIPJVYK3ijJk= + dependencies: + loader-utils "^2.0.0" + regex-parser "^2.2.11" + +aggregate-error@^3.0.0: + version "3.1.0" + resolved "https://registry.nlark.com/aggregate-error/download/aggregate-error-3.1.0.tgz?cache=0&sync_timestamp=1622604530325&other_urls=https%3A%2F%2Fregistry.nlark.com%2Faggregate-error%2Fdownload%2Faggregate-error-3.1.0.tgz#92670ff50f5359bdb7a3e0d40d0ec30c5737687a" + integrity sha1-kmcP9Q9TWb23o+DUDQ7DDFc3aHo= + dependencies: + clean-stack "^2.0.0" + indent-string "^4.0.0" + +ajv-errors@^1.0.0: + version "1.0.1" + resolved "https://registry.nlark.com/ajv-errors/download/ajv-errors-1.0.1.tgz#f35986aceb91afadec4102fbd85014950cefa64d" + integrity sha1-81mGrOuRr63sQQL72FAUlQzvpk0= + +ajv-keywords@^3.0.0, ajv-keywords@^3.1.0, ajv-keywords@^3.4.1, ajv-keywords@^3.5.2: + version "3.5.2" + resolved "https://registry.nlark.com/ajv-keywords/download/ajv-keywords-3.5.2.tgz#31f29da5ab6e00d1c2d329acf7b5929614d5014d" + integrity sha1-MfKdpatuANHC0yms97WSlhTVAU0= + +ajv@^6.0.1, ajv@^6.1.0, ajv@^6.10.0, ajv@^6.10.2, ajv@^6.12.3, ajv@^6.12.4, ajv@^6.12.5: + version "6.12.6" + resolved "https://registry.nlark.com/ajv/download/ajv-6.12.6.tgz?cache=0&sync_timestamp=1631470912358&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fajv%2Fdownload%2Fajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" + integrity sha1-uvWmLoArB9l3A0WG+MO69a3ybfQ= + dependencies: + fast-deep-equal "^3.1.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + +amdefine@>=0.0.4: + version "1.0.1" + resolved "https://registry.nlark.com/amdefine/download/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" + integrity sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU= + +ansi-colors@^3.0.0: + version "3.2.4" + resolved "https://registry.nlark.com/ansi-colors/download/ansi-colors-3.2.4.tgz#e3a3da4bfbae6c86a9c285625de124a234026fbf" + integrity sha1-46PaS/uubIapwoViXeEkojQCb78= + +ansi-escapes@^4.2.1: + version "4.3.2" + resolved "https://registry.nlark.com/ansi-escapes/download/ansi-escapes-4.3.2.tgz?cache=0&sync_timestamp=1618847144938&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fansi-escapes%2Fdownload%2Fansi-escapes-4.3.2.tgz#6b2291d1db7d98b6521d5f1efa42d0f3a9feb65e" + integrity sha1-ayKR0dt9mLZSHV8e+kLQ86n+tl4= + dependencies: + type-fest "^0.21.3" + +ansi-html@0.0.7, ansi-html@^0.0.7: + version "0.0.7" + resolved "https://registry.nlark.com/ansi-html/download/ansi-html-0.0.7.tgz#813584021962a9e9e6fd039f940d12f56ca7859e" + integrity sha1-gTWEAhliqenm/QOflA0S9WynhZ4= + +ansi-regex@^2.0.0: + version "2.1.1" + resolved "https://registry.nlark.com/ansi-regex/download/ansi-regex-2.1.1.tgz?cache=0&sync_timestamp=1631634988487&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fansi-regex%2Fdownload%2Fansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" + integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= + +ansi-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/ansi-regex/download/ansi-regex-3.0.0.tgz?cache=0&sync_timestamp=1631634988487&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fansi-regex%2Fdownload%2Fansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" + integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= + +ansi-regex@^4.1.0: + version "4.1.0" + resolved "https://registry.nlark.com/ansi-regex/download/ansi-regex-4.1.0.tgz?cache=0&sync_timestamp=1631634988487&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fansi-regex%2Fdownload%2Fansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" + integrity sha1-i5+PCM8ay4Q3Vqg5yox+MWjFGZc= + +ansi-regex@^5.0.1: + version "5.0.1" + resolved "https://registry.nlark.com/ansi-regex/download/ansi-regex-5.0.1.tgz?cache=0&sync_timestamp=1631634988487&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fansi-regex%2Fdownload%2Fansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" + integrity sha1-CCyyyJyf6GWaMRpTvWpNxTAdswQ= + +ansi-styles@^2.2.1: + version "2.2.1" + resolved "https://registry.nlark.com/ansi-styles/download/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" + integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= + +ansi-styles@^3.2.0, ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.nlark.com/ansi-styles/download/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + integrity sha1-QfuyAkPlCxK+DwS43tvwdSDOhB0= + dependencies: + color-convert "^1.9.0" + +ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.nlark.com/ansi-styles/download/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" + integrity sha1-7dgDYornHATIWuegkG7a00tkiTc= + dependencies: + color-convert "^2.0.1" + +anymatch@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/anymatch/download/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" + integrity sha1-vLJLTzeTTZqnrBe0ra+J58du8us= + dependencies: + micromatch "^3.1.4" + normalize-path "^2.1.1" + +anymatch@~3.1.1, anymatch@~3.1.2: + version "3.1.2" + resolved "https://registry.nlark.com/anymatch/download/anymatch-3.1.2.tgz#c0557c096af32f106198f4f4e2a383537e378716" + integrity sha1-wFV8CWrzLxBhmPT04qODU343hxY= + dependencies: + normalize-path "^3.0.0" + picomatch "^2.0.4" + +aproba@^1.0.3, aproba@^1.1.1: + version "1.2.0" + resolved "https://registry.nlark.com/aproba/download/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" + integrity sha1-aALmJk79GMeQobDVF/DyYnvyyUo= + +archy@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/archy/download/archy-1.0.0.tgz#f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40" + integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= + +are-we-there-yet@~1.1.2: + version "1.1.7" + resolved "https://registry.nlark.com/are-we-there-yet/download/are-we-there-yet-1.1.7.tgz#b15474a932adab4ff8a50d9adfa7e4e926f21146" + integrity sha1-sVR0qTKtq0/4pQ2a36fk6SbyEUY= + dependencies: + delegates "^1.0.0" + readable-stream "^2.0.6" + +argparse@^1.0.7: + version "1.0.10" + resolved "https://registry.nlark.com/argparse/download/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" + integrity sha1-vNZ5HqWuCXJeF+WtmIE0zUCz2RE= + dependencies: + sprintf-js "~1.0.2" + +arity-n@^1.0.4: + version "1.0.4" + resolved "https://registry.npm.taobao.org/arity-n/download/arity-n-1.0.4.tgz#d9e76b11733e08569c0847ae7b39b2860b30b745" + integrity sha1-2edrEXM+CFacCEeuezmyhgswt0U= + +arr-diff@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/arr-diff/download/arr-diff-2.0.0.tgz#8f3b827f955a8bd669697e4a4256ac3ceae356cf" + integrity sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8= + dependencies: + arr-flatten "^1.0.1" + +arr-diff@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/arr-diff/download/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" + integrity sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA= + +arr-flatten@^1.0.1, arr-flatten@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/arr-flatten/download/arr-flatten-1.1.0.tgz?cache=0&sync_timestamp=1618846805394&other_urls=https%3A%2F%2Fregistry.nlark.com%2Farr-flatten%2Fdownload%2Farr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" + integrity sha1-NgSLv/TntH4TZkQxbJlmnqWukfE= + +arr-union@^3.1.0: + version "3.1.0" + resolved "https://registry.nlark.com/arr-union/download/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" + integrity sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ= + +array-equal@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/array-equal/download/array-equal-1.0.0.tgz#8c2a5ef2472fd9ea742b04c77a75093ba2757c93" + integrity sha1-jCpe8kcv2ep0KwTHenUJO6J1fJM= + +array-find-index@^1.0.1: + version "1.0.2" + resolved "https://registry.nlark.com/array-find-index/download/array-find-index-1.0.2.tgz#df010aa1287e164bbda6f9723b0a96a1ec4187a1" + integrity sha1-3wEKoSh+Fku9pvlyOwqWoexBh6E= + +array-flatten@1.1.1: + version "1.1.1" + resolved "https://registry.nlark.com/array-flatten/download/array-flatten-1.1.1.tgz#9a5f699051b1e7073328f2a008968b64ea2955d2" + integrity sha1-ml9pkFGx5wczKPKgCJaLZOopVdI= + +array-flatten@^2.1.0: + version "2.1.2" + resolved "https://registry.nlark.com/array-flatten/download/array-flatten-2.1.2.tgz#24ef80a28c1a893617e2149b0c6d0d788293b099" + integrity sha1-JO+AoowaiTYX4hSbDG0NeIKTsJk= + +array-includes@^3.1.3, array-includes@^3.1.4: + version "3.1.4" + resolved "https://registry.npmmirror.com/array-includes/download/array-includes-3.1.4.tgz#f5b493162c760f3539631f005ba2bb46acb45ba9" + integrity sha1-9bSTFix2DzU5Yx8AW6K7Rqy0W6k= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.1" + get-intrinsic "^1.1.1" + is-string "^1.0.7" + +array-union@^1.0.1: + version "1.0.2" + resolved "https://registry.npm.taobao.org/array-union/download/array-union-1.0.2.tgz#9a34410e4f4e3da23dea375be5be70f24778ec39" + integrity sha1-mjRBDk9OPaI96jdb5b5w8kd47Dk= + dependencies: + array-uniq "^1.0.1" + +array-union@^2.1.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/array-union/download/array-union-2.1.0.tgz#b798420adbeb1de828d84acd8a2e23d3efe85e8d" + integrity sha1-t5hCCtvrHego2ErNii4j0+/oXo0= + +array-uniq@^1.0.1: + version "1.0.3" + resolved "https://registry.nlark.com/array-uniq/download/array-uniq-1.0.3.tgz?cache=0&sync_timestamp=1622605321175&other_urls=https%3A%2F%2Fregistry.nlark.com%2Farray-uniq%2Fdownload%2Farray-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" + integrity sha1-r2rId6Jcx/dOBYiUdThY39sk/bY= + +array-unique@^0.2.1: + version "0.2.1" + resolved "https://registry.nlark.com/array-unique/download/array-unique-0.2.1.tgz#a1d97ccafcbc2625cc70fadceb36a50c58b01a53" + integrity sha1-odl8yvy8JiXMcPrc6zalDFiwGlM= + +array-unique@^0.3.2: + version "0.3.2" + resolved "https://registry.nlark.com/array-unique/download/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" + integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= + +array.prototype.flat@^1.2.5: + version "1.2.5" + resolved "https://registry.npmmirror.com/array.prototype.flat/download/array.prototype.flat-1.2.5.tgz?cache=0&sync_timestamp=1633109609894&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Farray.prototype.flat%2Fdownload%2Farray.prototype.flat-1.2.5.tgz#07e0975d84bbc7c48cd1879d609e682598d33e13" + integrity sha1-B+CXXYS7x8SM0YedYJ5oJZjTPhM= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.0" + +array.prototype.flatmap@^1.2.4: + version "1.2.5" + resolved "https://registry.npmmirror.com/array.prototype.flatmap/download/array.prototype.flatmap-1.2.5.tgz?cache=0&sync_timestamp=1633121689477&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Farray.prototype.flatmap%2Fdownload%2Farray.prototype.flatmap-1.2.5.tgz#908dc82d8a406930fdf38598d51e7411d18d4446" + integrity sha1-kI3ILYpAaTD984WY1R50EdGNREY= + dependencies: + call-bind "^1.0.0" + define-properties "^1.1.3" + es-abstract "^1.19.0" + +arrify@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/arrify/download/arrify-1.0.1.tgz?cache=0&sync_timestamp=1619599497996&other_urls=https%3A%2F%2Fregistry.nlark.com%2Farrify%2Fdownload%2Farrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" + integrity sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0= + +asap@~2.0.6: + version "2.0.6" + resolved "https://registry.npmmirror.com/asap/-/asap-2.0.6.tgz#e50347611d7e690943208bbdafebcbc2fb866d46" + integrity sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA== + +asn1.js@^5.2.0: + version "5.4.1" + resolved "https://registry.npm.taobao.org/asn1.js/download/asn1.js-5.4.1.tgz#11a980b84ebb91781ce35b0fdc2ee294e3783f07" + integrity sha1-EamAuE67kXgc41sP3C7ilON4Pwc= + dependencies: + bn.js "^4.0.0" + inherits "^2.0.1" + minimalistic-assert "^1.0.0" + safer-buffer "^2.1.0" + +asn1@~0.2.3: + version "0.2.6" + resolved "https://registry.npmmirror.com/asn1/download/asn1-0.2.6.tgz?cache=0&sync_timestamp=1635986760581&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fasn1%2Fdownload%2Fasn1-0.2.6.tgz#0d3a7bb6e64e02a90c0303b31f292868ea09a08d" + integrity sha1-DTp7tuZOAqkMAwOzHykoaOoJoI0= + dependencies: + safer-buffer "~2.1.0" + +assert-plus@1.0.0, assert-plus@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/assert-plus/download/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" + integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= + +assert@1.4.1: + version "1.4.1" + resolved "https://registry.nlark.com/assert/download/assert-1.4.1.tgz?cache=0&sync_timestamp=1618847153747&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fassert%2Fdownload%2Fassert-1.4.1.tgz#99912d591836b5a6f5b345c0f07eefc08fc65d91" + integrity sha1-mZEtWRg2tab1s0XA8H7vwI/GXZE= + dependencies: + util "0.10.3" + +assert@^1.1.1: + version "1.5.0" + resolved "https://registry.nlark.com/assert/download/assert-1.5.0.tgz?cache=0&sync_timestamp=1618847153747&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fassert%2Fdownload%2Fassert-1.5.0.tgz#55c109aaf6e0aefdb3dc4b71240c70bf574b18eb" + integrity sha1-VcEJqvbgrv2z3EtxJAxwv1dLGOs= + dependencies: + object-assign "^4.1.1" + util "0.10.3" + +assign-symbols@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/assign-symbols/download/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" + integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= + +astral-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/astral-regex/download/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" + integrity sha1-bIw/uCfdQ+45GPJ7gngqt2WKb9k= + +astring@^1.7.5: + version "1.7.5" + resolved "https://registry.nlark.com/astring/download/astring-1.7.5.tgz#a7d47fceaf32b052d33a3d07c511efeec67447ca" + integrity sha1-p9R/zq8ysFLTOj0HxRHv7sZ0R8o= + +async-each@^1.0.1: + version "1.0.3" + resolved "https://registry.nlark.com/async-each/download/async-each-1.0.3.tgz#b727dbf87d7651602f06f4d4ac387f47d91b0cbf" + integrity sha1-tyfb+H12UWAvBvTUrDh/R9kbDL8= + +async-foreach@^0.1.3: + version "0.1.3" + resolved "https://registry.nlark.com/async-foreach/download/async-foreach-0.1.3.tgz#36121f845c0578172de419a97dbeb1d16ec34542" + integrity sha1-NhIfhFwFeBct5Bmpfb6x0W7DRUI= + +async-limiter@~1.0.0: + version "1.0.1" + resolved "https://registry.npm.taobao.org/async-limiter/download/async-limiter-1.0.1.tgz#dd379e94f0db8310b08291f9d64c3209766617fd" + integrity sha1-3TeelPDbgxCwgpH51kwyCXZmF/0= + +async@^2.6.2: + version "2.6.3" + resolved "https://registry.npmmirror.com/async/download/async-2.6.3.tgz?cache=0&sync_timestamp=1635441262651&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fasync%2Fdownload%2Fasync-2.6.3.tgz#d72625e2344a3656e3a3ad4fa749fa83299d82ff" + integrity sha1-1yYl4jRKNlbjo61Pp0n6gymdgv8= + dependencies: + lodash "^4.17.14" + +asynckit@^0.4.0: + version "0.4.0" + resolved "https://registry.npm.taobao.org/asynckit/download/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" + integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= + +atob@^2.1.2: + version "2.1.2" + resolved "https://registry.nlark.com/atob/download/atob-2.1.2.tgz#6d9517eb9e030d2436666651e86bd9f6f13533c9" + integrity sha1-bZUX654DDSQ2ZmZR6GvZ9vE1M8k= + +autoprefixer@9.7.4: + version "9.7.4" + resolved "https://registry.npmmirror.com/autoprefixer/download/autoprefixer-9.7.4.tgz#f8bf3e06707d047f0641d87aee8cfb174b2a5378" + integrity sha1-+L8+BnB9BH8GQdh67oz7F0sqU3g= + dependencies: + browserslist "^4.8.3" + caniuse-lite "^1.0.30001020" + chalk "^2.4.2" + normalize-range "^0.1.2" + num2fraction "^1.2.2" + postcss "^7.0.26" + postcss-value-parser "^4.0.2" + +autoprefixer@^8.0.0: + version "8.6.5" + resolved "https://registry.npmmirror.com/autoprefixer/download/autoprefixer-8.6.5.tgz#343f3d193ed568b3208e00117a1b96eb691d4ee9" + integrity sha1-ND89GT7VaLMgjgARehuW62kdTuk= + dependencies: + browserslist "^3.2.8" + caniuse-lite "^1.0.30000864" + normalize-range "^0.1.2" + num2fraction "^1.2.2" + postcss "^6.0.23" + postcss-value-parser "^3.2.3" + +aws-sign2@~0.7.0: + version "0.7.0" + resolved "https://registry.npm.taobao.org/aws-sign2/download/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" + integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= + +aws4@^1.8.0: + version "1.11.0" + resolved "https://registry.nlark.com/aws4/download/aws4-1.11.0.tgz#d61f46d83b2519250e2784daf5b09479a8b41c59" + integrity sha1-1h9G2DslGSUOJ4Ta9bCUeai0HFk= + +axios@0.19.2: + version "0.19.2" + resolved "https://registry.npmmirror.com/axios/download/axios-0.19.2.tgz?cache=0&sync_timestamp=1635213960429&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Faxios%2Fdownload%2Faxios-0.19.2.tgz#3ea36c5d8818d0d5f8a8a97a6d36b86cdc00cb27" + integrity sha1-PqNsXYgY0NX4qKl6bTa4bNwAyyc= + dependencies: + follow-redirects "1.5.10" + +babel-eslint@^10.0.0: + version "10.1.0" + resolved "https://registry.npmmirror.com/babel-eslint/download/babel-eslint-10.1.0.tgz#6968e568a910b78fb3779cdd8b6ac2f479943232" + integrity sha1-aWjlaKkQt4+zd5zdi2rC9HmUMjI= + dependencies: + "@babel/code-frame" "^7.0.0" + "@babel/parser" "^7.7.0" + "@babel/traverse" "^7.7.0" + "@babel/types" "^7.7.0" + eslint-visitor-keys "^1.0.0" + resolve "^1.12.0" + +babel-helper-builder-react-jsx@^6.24.1: + version "6.26.0" + resolved "https://registry.npm.taobao.org/babel-helper-builder-react-jsx/download/babel-helper-builder-react-jsx-6.26.0.tgz#39ff8313b75c8b65dceff1f31d383e0ff2a408a0" + integrity sha1-Of+DE7dci2Xc7/HzHTg+D/KkCKA= + dependencies: + babel-runtime "^6.26.0" + babel-types "^6.26.0" + esutils "^2.0.2" + +babel-loader@8.2.1: + version "8.2.1" + resolved "https://registry.npmmirror.com/babel-loader/download/babel-loader-8.2.1.tgz#e53313254677e86f27536f5071d807e01d24ec00" + integrity sha1-5TMTJUZ36G8nU29QcdgH4B0k7AA= + dependencies: + find-cache-dir "^2.1.0" + loader-utils "^1.4.0" + make-dir "^2.1.0" + pify "^4.0.1" + schema-utils "^2.6.5" + +babel-plugin-dynamic-import-node@^2.3.3: + version "2.3.3" + resolved "https://registry.npm.taobao.org/babel-plugin-dynamic-import-node/download/babel-plugin-dynamic-import-node-2.3.3.tgz#84fda19c976ec5c6defef57f9427b3def66e17a3" + integrity sha1-hP2hnJduxcbe/vV/lCez3vZuF6M= + dependencies: + object.assign "^4.1.0" + +babel-plugin-global-define@^1.0.3: + version "1.0.3" + resolved "https://registry.npm.taobao.org/babel-plugin-global-define/download/babel-plugin-global-define-1.0.3.tgz#262c528f0c26bf318f4ccc77cf21df43a0fa6308" + integrity sha1-JixSjwwmvzGPTMx3zyHfQ6D6Ywg= + +babel-plugin-import@^1.13.3: + version "1.13.3" + resolved "https://registry.npm.taobao.org/babel-plugin-import/download/babel-plugin-import-1.13.3.tgz#9dbbba7d1ac72bd412917a830d445e00941d26d7" + integrity sha1-nbu6fRrHK9QSkXqDDUReAJQdJtc= + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/runtime" "^7.0.0" + +babel-plugin-jsx-attributes-array-to-object@^0.3.0: + version "0.3.0" + resolved "https://registry.nlark.com/babel-plugin-jsx-attributes-array-to-object/download/babel-plugin-jsx-attributes-array-to-object-0.3.0.tgz#ac7b551a2407750ac899460fe5e38b1dceaebed1" + integrity sha1-rHtVGiQHdQrImUYP5eOLHc6uvtE= + +babel-plugin-polyfill-corejs2@^0.2.3: + version "0.2.3" + resolved "https://registry.npmmirror.com/babel-plugin-polyfill-corejs2/download/babel-plugin-polyfill-corejs2-0.2.3.tgz?cache=0&sync_timestamp=1635566922153&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fbabel-plugin-polyfill-corejs2%2Fdownload%2Fbabel-plugin-polyfill-corejs2-0.2.3.tgz#6ed8e30981b062f8fe6aca8873a37ebcc8cc1c0f" + integrity sha1-btjjCYGwYvj+asqIc6N+vMjMHA8= + dependencies: + "@babel/compat-data" "^7.13.11" + "@babel/helper-define-polyfill-provider" "^0.2.4" + semver "^6.1.1" + +babel-plugin-polyfill-corejs2@^0.3.0: + version "0.3.1" + resolved "https://registry.npmmirror.com/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.3.1.tgz#440f1b70ccfaabc6b676d196239b138f8a2cfba5" + integrity sha512-v7/T6EQcNfVLfcN2X8Lulb7DjprieyLWJK/zOWH5DUYcAgex9sP3h25Q+DLsX9TloXe3y1O8l2q2Jv9q8UVB9w== + dependencies: + "@babel/compat-data" "^7.13.11" + "@babel/helper-define-polyfill-provider" "^0.3.1" + semver "^6.1.1" + +babel-plugin-polyfill-corejs3@^0.3.0: + version "0.3.0" + resolved "https://registry.npmmirror.com/babel-plugin-polyfill-corejs3/download/babel-plugin-polyfill-corejs3-0.3.0.tgz?cache=0&sync_timestamp=1635566922706&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fbabel-plugin-polyfill-corejs3%2Fdownload%2Fbabel-plugin-polyfill-corejs3-0.3.0.tgz#fa7ca3d1ee9ddc6193600ffb632c9785d54918af" + integrity sha1-+nyj0e6d3GGTYA/7YyyXhdVJGK8= + dependencies: + "@babel/helper-define-polyfill-provider" "^0.2.4" + core-js-compat "^3.18.0" + +babel-plugin-polyfill-corejs3@^0.5.0: + version "0.5.2" + resolved "https://registry.npmmirror.com/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.5.2.tgz#aabe4b2fa04a6e038b688c5e55d44e78cd3a5f72" + integrity sha512-G3uJih0XWiID451fpeFaYGVuxHEjzKTHtc9uGFEjR6hHrvNzeS/PX+LLLcetJcytsB5m4j+K3o/EpXJNb/5IEQ== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.3.1" + core-js-compat "^3.21.0" + +babel-plugin-polyfill-regenerator@^0.2.3: + version "0.2.3" + resolved "https://registry.npmmirror.com/babel-plugin-polyfill-regenerator/download/babel-plugin-polyfill-regenerator-0.2.3.tgz#2e9808f5027c4336c994992b48a4262580cb8d6d" + integrity sha1-LpgI9QJ8QzbJlJkrSKQmJYDLjW0= + dependencies: + "@babel/helper-define-polyfill-provider" "^0.2.4" + +babel-plugin-polyfill-regenerator@^0.3.0: + version "0.3.1" + resolved "https://registry.npmmirror.com/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.3.1.tgz#2c0678ea47c75c8cc2fbb1852278d8fb68233990" + integrity sha512-Y2B06tvgHYt1x0yz17jGkGeeMr5FeKUu+ASJ+N6nB5lQ8Dapfg42i0OVrf8PNGJ3zKL4A23snMi1IRwrqqND7A== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.3.1" + +babel-plugin-syntax-jsx@^6.8.0: + version "6.18.0" + resolved "https://registry.nlark.com/babel-plugin-syntax-jsx/download/babel-plugin-syntax-jsx-6.18.0.tgz#0af32a9a6e13ca7a3fd5069e62d7b0f58d0d8946" + integrity sha1-CvMqmm4Tyno/1QaeYtew9Y0NiUY= + +babel-plugin-transform-imports-api@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/babel-plugin-transform-imports-api/download/babel-plugin-transform-imports-api-1.0.0.tgz#b9076ebfe8da7ed5f3b44be23823500d22c43bc6" + integrity sha1-uQduv+jaftXztEviOCNQDSLEO8Y= + dependencies: + is-invalid-path "^1.0.2" + +babel-plugin-transform-react-jsx-to-rn-stylesheet@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/babel-plugin-transform-react-jsx-to-rn-stylesheet/download/babel-plugin-transform-react-jsx-to-rn-stylesheet-3.3.12.tgz?cache=0&sync_timestamp=1635492000684&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fbabel-plugin-transform-react-jsx-to-rn-stylesheet%2Fdownload%2Fbabel-plugin-transform-react-jsx-to-rn-stylesheet-3.3.12.tgz#ccc7cdc86d36a36103a8f2ac097a487a32065893" + integrity sha1-zMfNyG02o2EDqPKsCXpIejIGWJM= + dependencies: + camelize "^1.0.0" + taro-css-to-react-native "3.3.12" + +babel-plugin-transform-react-jsx@^6.24.1: + version "6.24.1" + resolved "https://registry.npm.taobao.org/babel-plugin-transform-react-jsx/download/babel-plugin-transform-react-jsx-6.24.1.tgz#840a028e7df460dfc3a2d29f0c0d91f6376e66a3" + integrity sha1-hAoCjn30YN/DotKfDA2R9jduZqM= + dependencies: + babel-helper-builder-react-jsx "^6.24.1" + babel-plugin-syntax-jsx "^6.8.0" + babel-runtime "^6.22.0" + +babel-plugin-transform-react-remove-prop-types@^0.4.24: + version "0.4.24" + resolved "https://registry.npm.taobao.org/babel-plugin-transform-react-remove-prop-types/download/babel-plugin-transform-react-remove-prop-types-0.4.24.tgz#f2edaf9b4c6a5fbe5c1d678bfb531078c1555f3a" + integrity sha1-8u2vm0xqX75cHWeL+1MQeMFVXzo= + +babel-plugin-transform-taroapi@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/babel-plugin-transform-taroapi/download/babel-plugin-transform-taroapi-3.3.12.tgz?cache=0&sync_timestamp=1635490866916&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fbabel-plugin-transform-taroapi%2Fdownload%2Fbabel-plugin-transform-taroapi-3.3.12.tgz#fbe55f78f991a8f16093b18843f6bc41ae295983" + integrity sha1-++VfePmRqPFgk7GIQ/a8Qa4pWYM= + +babel-preset-taro@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/babel-preset-taro/download/babel-preset-taro-3.3.12.tgz#c8478a17717152f0637b44f7be4cdb2443c64157" + integrity sha1-yEeKF3FxUvBje0T3vkzbJEPGQVc= + dependencies: + "@babel/plugin-proposal-class-properties" "7.10.4" + "@babel/plugin-proposal-decorators" "7.10.5" + "@babel/plugin-syntax-jsx" "^7.10.4" + "@babel/plugin-transform-runtime" "7.11.0" + "@babel/preset-env" "^7.11.0" + "@babel/preset-react" "7.12.13" + "@babel/preset-typescript" "7.12.17" + "@babel/runtime" "^7.11.2" + "@babel/runtime-corejs3" "^7.14.8" + "@tarojs/helper" "3.3.12" + "@tarojs/taro-h5" "3.3.12" + "@vue/babel-plugin-jsx" "^1.0.6" + "@vue/babel-preset-jsx" "^1.2.4" + babel-plugin-dynamic-import-node "^2.3.3" + babel-plugin-global-define "^1.0.3" + babel-plugin-jsx-attributes-array-to-object "^0.3.0" + babel-plugin-transform-imports-api "^1.0.0" + babel-plugin-transform-react-jsx-to-rn-stylesheet "3.3.12" + babel-plugin-transform-taroapi "3.3.12" + core-js "^3.6.5" + metro-react-native-babel-preset "^0.66.2" + react-refresh "0.9.0" + +babel-runtime@^6.0.0, babel-runtime@^6.22.0, babel-runtime@^6.23.0, babel-runtime@^6.26.0: + version "6.26.0" + resolved "https://registry.nlark.com/babel-runtime/download/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe" + integrity sha1-llxwWGaOgrVde/4E/yM3vItWR/4= + dependencies: + core-js "^2.4.0" + regenerator-runtime "^0.11.0" + +babel-types@^6.26.0: + version "6.26.0" + resolved "https://registry.nlark.com/babel-types/download/babel-types-6.26.0.tgz#a3b073f94ab49eb6fa55cd65227a334380632497" + integrity sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc= + dependencies: + babel-runtime "^6.26.0" + esutils "^2.0.2" + lodash "^4.17.4" + to-fast-properties "^1.0.3" + +bail@^1.0.0: + version "1.0.5" + resolved "https://registry.npmmirror.com/bail/download/bail-1.0.5.tgz?cache=0&sync_timestamp=1636274472809&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fbail%2Fdownload%2Fbail-1.0.5.tgz#b6fa133404a392cbc1f8c4bf63f5953351e7a776" + integrity sha1-tvoTNASjksvB+MS/Y/WVM1Hnp3Y= + +balanced-match@^1.0.0: + version "1.0.2" + resolved "https://registry.npm.taobao.org/balanced-match/download/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" + integrity sha1-6D46fj8wCzTLnYf2FfoMvzV2kO4= + +base64-js@^1.0.2, base64-js@^1.3.0: + version "1.5.1" + resolved "https://registry.nlark.com/base64-js/download/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" + integrity sha1-GxtEAWClv3rUC2UPCVljSBkDkwo= + +base@^0.11.1: + version "0.11.2" + resolved "https://registry.npm.taobao.org/base/download/base-0.11.2.tgz#7bde5ced145b6d551a90db87f83c558b4eb48a8f" + integrity sha1-e95c7RRbbVUakNuH+DxVi060io8= + dependencies: + cache-base "^1.0.1" + class-utils "^0.3.5" + component-emitter "^1.2.1" + define-property "^1.0.0" + isobject "^3.0.1" + mixin-deep "^1.2.0" + pascalcase "^0.1.1" + +batch@0.6.1: + version "0.6.1" + resolved "https://registry.nlark.com/batch/download/batch-0.6.1.tgz#dc34314f4e679318093fc760272525f94bf25c16" + integrity sha1-3DQxT05nkxgJP8dgJyUl+UvyXBY= + +bcrypt-pbkdf@^1.0.0: + version "1.0.2" + resolved "https://registry.npm.taobao.org/bcrypt-pbkdf/download/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" + integrity sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4= + dependencies: + tweetnacl "^0.14.3" + +better-scroll@^1.14.1: + version "1.15.2" + resolved "https://registry.nlark.com/better-scroll/download/better-scroll-1.15.2.tgz?cache=0&sync_timestamp=1627913074987&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fbetter-scroll%2Fdownload%2Fbetter-scroll-1.15.2.tgz#65ffc6058b8b4ff337b8dfad4bcb334d7699ceb6" + integrity sha1-Zf/GBYuLT/M3uN+tS8szTXaZzrY= + dependencies: + babel-runtime "^6.0.0" + +big.js@^3.1.3: + version "3.2.0" + resolved "https://registry.nlark.com/big.js/download/big.js-3.2.0.tgz#a5fc298b81b9e0dca2e458824784b65c52ba588e" + integrity sha1-pfwpi4G54Nyi5FiCR4S2XFK6WI4= + +big.js@^5.2.2: + version "5.2.2" + resolved "https://registry.nlark.com/big.js/download/big.js-5.2.2.tgz#65f0af382f578bcdc742bd9c281e9cb2d7768328" + integrity sha1-ZfCvOC9Xi83HQr2cKB6cstd2gyg= + +binary-extensions@^1.0.0: + version "1.13.1" + resolved "https://registry.nlark.com/binary-extensions/download/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" + integrity sha1-WYr+VHVbKGilMw0q/51Ou1Mgm2U= + +binary-extensions@^2.0.0: + version "2.2.0" + resolved "https://registry.nlark.com/binary-extensions/download/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" + integrity sha1-dfUC7q+f/eQvyYgpZFvk6na9ni0= + +bindings@^1.5.0: + version "1.5.0" + resolved "https://registry.nlark.com/bindings/download/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" + integrity sha1-EDU8npRTNLwFEabZCzj7x8nFBN8= + dependencies: + file-uri-to-path "1.0.0" + +block-stream@*: + version "0.0.9" + resolved "https://registry.nlark.com/block-stream/download/block-stream-0.0.9.tgz#13ebfe778a03205cfe03751481ebb4b3300c126a" + integrity sha1-E+v+d4oDIFz+A3UUgeu0szAMEmo= + dependencies: + inherits "~2.0.0" + +bluebird@^3.5.5: + version "3.7.2" + resolved "https://registry.npm.taobao.org/bluebird/download/bluebird-3.7.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fbluebird%2Fdownload%2Fbluebird-3.7.2.tgz#9f229c15be272454ffa973ace0dbee79a1b0c36f" + integrity sha1-nyKcFb4nJFT/qXOs4NvueaGww28= + +bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.11.9: + version "4.12.0" + resolved "https://registry.npm.taobao.org/bn.js/download/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" + integrity sha1-d1s/J477uXGO7HNh9IP7Nvu/6og= + +bn.js@^5.0.0, bn.js@^5.1.1: + version "5.2.0" + resolved "https://registry.npm.taobao.org/bn.js/download/bn.js-5.2.0.tgz#358860674396c6997771a9d051fcc1b57d4ae002" + integrity sha1-NYhgZ0OWxpl3canQUfzBtX1K4AI= + +body-parser@1.19.0: + version "1.19.0" + resolved "https://registry.nlark.com/body-parser/download/body-parser-1.19.0.tgz#96b2709e57c9c4e09a6fd66a8fd979844f69f08a" + integrity sha1-lrJwnlfJxOCab9Zqj9l5hE9p8Io= + dependencies: + bytes "3.1.0" + content-type "~1.0.4" + debug "2.6.9" + depd "~1.1.2" + http-errors "1.7.2" + iconv-lite "0.4.24" + on-finished "~2.3.0" + qs "6.7.0" + raw-body "2.4.0" + type-is "~1.6.17" + +bonjour@^3.5.0: + version "3.5.0" + resolved "https://registry.nlark.com/bonjour/download/bonjour-3.5.0.tgz#8e890a183d8ee9a2393b3844c691a42bcf7bc9f5" + integrity sha1-jokKGD2O6aI5OzhExpGkK897yfU= + dependencies: + array-flatten "^2.1.0" + deep-equal "^1.0.1" + dns-equal "^1.0.0" + dns-txt "^2.0.2" + multicast-dns "^6.0.1" + multicast-dns-service-types "^1.1.0" + +boolbase@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/boolbase/download/boolbase-1.0.0.tgz#68dff5fbe60c51eb37725ea9e3ed310dcc1e776e" + integrity sha1-aN/1++YMUes3cl6p4+0xDcwed24= + +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.nlark.com/brace-expansion/download/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" + integrity sha1-PH/L9SnYcibz0vUrlm/1Jx60Qd0= + dependencies: + balanced-match "^1.0.0" + concat-map "0.0.1" + +braces@^1.8.2: + version "1.8.5" + resolved "https://registry.npm.taobao.org/braces/download/braces-1.8.5.tgz#ba77962e12dff969d6b76711e914b737857bf6a7" + integrity sha1-uneWLhLf+WnWt2cR6RS3N4V79qc= + dependencies: + expand-range "^1.8.1" + preserve "^0.2.0" + repeat-element "^1.1.2" + +braces@^2.3.1, braces@^2.3.2: + version "2.3.2" + resolved "https://registry.npm.taobao.org/braces/download/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729" + integrity sha1-WXn9PxTNUxVl5fot8av/8d+u5yk= + dependencies: + arr-flatten "^1.1.0" + array-unique "^0.3.2" + extend-shallow "^2.0.1" + fill-range "^4.0.0" + isobject "^3.0.1" + repeat-element "^1.1.2" + snapdragon "^0.8.1" + snapdragon-node "^2.0.1" + split-string "^3.0.2" + to-regex "^3.0.1" + +braces@^3.0.1, braces@~3.0.2: + version "3.0.2" + resolved "https://registry.npm.taobao.org/braces/download/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" + integrity sha1-NFThpGLujVmeI23zNs2epPiv4Qc= + dependencies: + fill-range "^7.0.1" + +brorand@^1.0.1, brorand@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/brorand/download/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" + integrity sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8= + +browser-process-hrtime@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/browser-process-hrtime/download/browser-process-hrtime-1.0.0.tgz?cache=0&sync_timestamp=1618847049949&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fbrowser-process-hrtime%2Fdownload%2Fbrowser-process-hrtime-1.0.0.tgz#3c9b4b7d782c8121e56f10106d84c0d0ffc94626" + integrity sha1-PJtLfXgsgSHlbxAQbYTA0P/JRiY= + +browserify-aes@^1.0.0, browserify-aes@^1.0.4: + version "1.2.0" + resolved "https://registry.nlark.com/browserify-aes/download/browserify-aes-1.2.0.tgz#326734642f403dabc3003209853bb70ad428ef48" + integrity sha1-Mmc0ZC9APavDADIJhTu3CtQo70g= + dependencies: + buffer-xor "^1.0.3" + cipher-base "^1.0.0" + create-hash "^1.1.0" + evp_bytestokey "^1.0.3" + inherits "^2.0.1" + safe-buffer "^5.0.1" + +browserify-cipher@^1.0.0: + version "1.0.1" + resolved "https://registry.nlark.com/browserify-cipher/download/browserify-cipher-1.0.1.tgz#8d6474c1b870bfdabcd3bcfcc1934a10e94f15f0" + integrity sha1-jWR0wbhwv9q807z8wZNKEOlPFfA= + dependencies: + browserify-aes "^1.0.4" + browserify-des "^1.0.0" + evp_bytestokey "^1.0.0" + +browserify-des@^1.0.0: + version "1.0.2" + resolved "https://registry.nlark.com/browserify-des/download/browserify-des-1.0.2.tgz#3af4f1f59839403572f1c66204375f7a7f703e9c" + integrity sha1-OvTx9Zg5QDVy8cZiBDdfen9wPpw= + dependencies: + cipher-base "^1.0.1" + des.js "^1.0.0" + inherits "^2.0.1" + safe-buffer "^5.1.2" + +browserify-rsa@^4.0.0, browserify-rsa@^4.0.1: + version "4.1.0" + resolved "https://registry.nlark.com/browserify-rsa/download/browserify-rsa-4.1.0.tgz#b2fd06b5b75ae297f7ce2dc651f918f5be158c8d" + integrity sha1-sv0Gtbda4pf3zi3GUfkY9b4VjI0= + dependencies: + bn.js "^5.0.0" + randombytes "^2.0.1" + +browserify-sign@^4.0.0: + version "4.2.1" + resolved "https://registry.nlark.com/browserify-sign/download/browserify-sign-4.2.1.tgz#eaf4add46dd54be3bb3b36c0cf15abbeba7956c3" + integrity sha1-6vSt1G3VS+O7OzbAzxWrvrp5VsM= + dependencies: + bn.js "^5.1.1" + browserify-rsa "^4.0.1" + create-hash "^1.2.0" + create-hmac "^1.1.7" + elliptic "^6.5.3" + inherits "^2.0.4" + parse-asn1 "^5.1.5" + readable-stream "^3.6.0" + safe-buffer "^5.2.0" + +browserify-zlib@^0.2.0: + version "0.2.0" + resolved "https://registry.nlark.com/browserify-zlib/download/browserify-zlib-0.2.0.tgz#2869459d9aa3be245fe8fe2ca1f46e2e7f54d73f" + integrity sha1-KGlFnZqjviRf6P4sofRuLn9U1z8= + dependencies: + pako "~1.0.5" + +browserslist@^3.2.8: + version "3.2.8" + resolved "https://registry.npmmirror.com/browserslist/download/browserslist-3.2.8.tgz#b0005361d6471f0f5952797a76fc985f1f978fc6" + integrity sha1-sABTYdZHHw9ZUnl6dvyYXx+Xj8Y= + dependencies: + caniuse-lite "^1.0.30000844" + electron-to-chromium "^1.3.47" + +browserslist@^4.16.6, browserslist@^4.17.6, browserslist@^4.8.3: + version "4.17.6" + resolved "https://registry.npmmirror.com/browserslist/download/browserslist-4.17.6.tgz#c76be33e7786b497f66cad25a73756c8b938985d" + integrity sha1-x2vjPneGtJf2bK0lpzdWyLk4mF0= + dependencies: + caniuse-lite "^1.0.30001274" + electron-to-chromium "^1.3.886" + escalade "^3.1.1" + node-releases "^2.0.1" + picocolors "^1.0.0" + +browserslist@^4.17.5, browserslist@^4.9.1: + version "4.18.1" + resolved "https://registry.npmmirror.com/browserslist/download/browserslist-4.18.1.tgz#60d3920f25b6860eb917c6c7b185576f4d8b017f" + integrity sha512-8ScCzdpPwR2wQh8IT82CA2VgDwjHyqMovPBZSNH54+tm4Jk2pCuv90gmAdH6J84OCRWi0b4gMe6O6XPXuJnjgQ== + dependencies: + caniuse-lite "^1.0.30001280" + electron-to-chromium "^1.3.896" + escalade "^3.1.1" + node-releases "^2.0.1" + picocolors "^1.0.0" + +browserslist@^4.19.1: + version "4.19.3" + resolved "https://registry.npmmirror.com/browserslist/-/browserslist-4.19.3.tgz#29b7caad327ecf2859485f696f9604214bedd383" + integrity sha512-XK3X4xtKJ+Txj8G5c30B4gsm71s69lqXlkYui4s6EkKxuv49qjYlY6oVd+IFJ73d4YymtM3+djvvt/R/iJwwDg== + dependencies: + caniuse-lite "^1.0.30001312" + electron-to-chromium "^1.4.71" + escalade "^3.1.1" + node-releases "^2.0.2" + picocolors "^1.0.0" + +buffer-crc32@~0.2.3: + version "0.2.13" + resolved "https://registry.npm.taobao.org/buffer-crc32/download/buffer-crc32-0.2.13.tgz#0d333e3f00eac50aa1454abd30ef8c2a5d9a7242" + integrity sha1-DTM+PwDqxQqhRUq9MO+MKl2ackI= + +buffer-from@^1.0.0: + version "1.1.2" + resolved "https://registry.nlark.com/buffer-from/download/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + integrity sha1-KxRqb9cugLT1XSVfNe1Zo6mkG9U= + +buffer-indexof@^1.0.0: + version "1.1.1" + resolved "https://registry.nlark.com/buffer-indexof/download/buffer-indexof-1.1.1.tgz#52fabcc6a606d1a00302802648ef68f639da268c" + integrity sha1-Uvq8xqYG0aADAoAmSO9o9jnaJow= + +buffer-xor@^1.0.3: + version "1.0.3" + resolved "https://registry.npm.taobao.org/buffer-xor/download/buffer-xor-1.0.3.tgz#26e61ed1422fb70dd42e6e36729ed51d855fe8d9" + integrity sha1-JuYe0UIvtw3ULm42cp7VHYVf6Nk= + +buffer@^4.3.0: + version "4.9.2" + resolved "https://registry.nlark.com/buffer/download/buffer-4.9.2.tgz#230ead344002988644841ab0244af8c44bbe3ef8" + integrity sha1-Iw6tNEACmIZEhBqwJEr4xEu+Pvg= + dependencies: + base64-js "^1.0.2" + ieee754 "^1.1.4" + isarray "^1.0.0" + +builtin-status-codes@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/builtin-status-codes/download/builtin-status-codes-3.0.0.tgz#85982878e21b98e1c66425e03d0174788f569ee8" + integrity sha1-hZgoeOIbmOHGZCXgPQF0eI9Wnug= + +bytes@3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/bytes/download/bytes-3.0.0.tgz#d32815404d689699f85a4ea4fa8755dd13a96048" + integrity sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg= + +bytes@3.1.0: + version "3.1.0" + resolved "https://registry.npm.taobao.org/bytes/download/bytes-3.1.0.tgz#f6cf7933a360e0588fa9fde85651cdc7f805d1f6" + integrity sha1-9s95M6Ng4FiPqf3oVlHNx/gF0fY= + +cacache@^12.0.2, cacache@^12.0.3: + version "12.0.4" + resolved "https://registry.nlark.com/cacache/download/cacache-12.0.4.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcacache%2Fdownload%2Fcacache-12.0.4.tgz#668bcbd105aeb5f1d92fe25570ec9525c8faa40c" + integrity sha1-ZovL0QWutfHZL+JVcOyVJcj6pAw= + dependencies: + bluebird "^3.5.5" + chownr "^1.1.1" + figgy-pudding "^3.5.1" + glob "^7.1.4" + graceful-fs "^4.1.15" + infer-owner "^1.0.3" + lru-cache "^5.1.1" + mississippi "^3.0.0" + mkdirp "^0.5.1" + move-concurrently "^1.0.1" + promise-inflight "^1.0.1" + rimraf "^2.6.3" + ssri "^6.0.1" + unique-filename "^1.1.1" + y18n "^4.0.0" + +cacache@^15.0.5: + version "15.3.0" + resolved "https://registry.nlark.com/cacache/download/cacache-15.3.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcacache%2Fdownload%2Fcacache-15.3.0.tgz#dc85380fb2f556fe3dda4c719bfa0ec875a7f1eb" + integrity sha1-3IU4D7L1Vv492kxxm/oOyHWn8es= + dependencies: + "@npmcli/fs" "^1.0.0" + "@npmcli/move-file" "^1.0.1" + chownr "^2.0.0" + fs-minipass "^2.0.0" + glob "^7.1.4" + infer-owner "^1.0.4" + lru-cache "^6.0.0" + minipass "^3.1.1" + minipass-collect "^1.0.2" + minipass-flush "^1.0.5" + minipass-pipeline "^1.2.2" + mkdirp "^1.0.3" + p-map "^4.0.0" + promise-inflight "^1.0.1" + rimraf "^3.0.2" + ssri "^8.0.1" + tar "^6.0.2" + unique-filename "^1.1.1" + +cache-base@^1.0.1: + version "1.0.1" + resolved "https://registry.npmmirror.com/cache-base/download/cache-base-1.0.1.tgz?cache=0&sync_timestamp=1636237266442&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcache-base%2Fdownload%2Fcache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2" + integrity sha1-Cn9GQWgxyLZi7jb+TnxZ129marI= + dependencies: + collection-visit "^1.0.0" + component-emitter "^1.2.1" + get-value "^2.0.6" + has-value "^1.0.0" + isobject "^3.0.1" + set-value "^2.0.0" + to-object-path "^0.3.0" + union-value "^1.0.0" + unset-value "^1.0.0" + +call-bind@^1.0.0, call-bind@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/call-bind/download/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" + integrity sha1-sdTonmiBGcPJqQOtMKuy9qkZvjw= + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + +call-me-maybe@^1.0.1: + version "1.0.1" + resolved "https://registry.npm.taobao.org/call-me-maybe/download/call-me-maybe-1.0.1.tgz#26d208ea89e37b5cbde60250a15f031c16a4d66b" + integrity sha1-JtII6onje1y95gJQoV8DHBak1ms= + +caller-callsite@^2.0.0: + version "2.0.0" + resolved "https://registry.npmmirror.com/caller-callsite/download/caller-callsite-2.0.0.tgz?cache=0&sync_timestamp=1633617041481&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcaller-callsite%2Fdownload%2Fcaller-callsite-2.0.0.tgz#847e0fce0a223750a9a027c54b33731ad3154134" + integrity sha1-hH4PzgoiN1CpoCfFSzNzGtMVQTQ= + dependencies: + callsites "^2.0.0" + +caller-path@^2.0.0: + version "2.0.0" + resolved "https://registry.npmmirror.com/caller-path/download/caller-path-2.0.0.tgz?cache=0&sync_timestamp=1633674209796&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcaller-path%2Fdownload%2Fcaller-path-2.0.0.tgz#468f83044e369ab2010fac5f06ceee15bb2cb1f4" + integrity sha1-Ro+DBE42mrIBD6xfBs7uFbsssfQ= + dependencies: + caller-callsite "^2.0.0" + +callsites@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/callsites/download/callsites-2.0.0.tgz?cache=0&sync_timestamp=1628464722297&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcallsites%2Fdownload%2Fcallsites-2.0.0.tgz#06eb84f00eea413da86affefacbffb36093b3c50" + integrity sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA= + +callsites@^3.0.0: + version "3.1.0" + resolved "https://registry.nlark.com/callsites/download/callsites-3.1.0.tgz?cache=0&sync_timestamp=1628464722297&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcallsites%2Fdownload%2Fcallsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" + integrity sha1-s2MKvYlDQy9Us/BRkjjjPNffL3M= + +camel-case@3.0.x, camel-case@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/camel-case/download/camel-case-3.0.0.tgz#ca3c3688a4e9cf3a4cda777dc4dcbc713249cf73" + integrity sha1-yjw2iKTpzzpM2nd9xNy8cTJJz3M= + dependencies: + no-case "^2.2.0" + upper-case "^1.1.1" + +camelcase-keys@^2.0.0: + version "2.1.0" + resolved "https://registry.npmmirror.com/camelcase-keys/download/camelcase-keys-2.1.0.tgz?cache=0&sync_timestamp=1633332959770&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcamelcase-keys%2Fdownload%2Fcamelcase-keys-2.1.0.tgz#308beeaffdf28119051efa1d932213c91b8f92e7" + integrity sha1-MIvur/3ygRkFHvodkyITyRuPkuc= + dependencies: + camelcase "^2.0.0" + map-obj "^1.0.0" + +camelcase-keys@^4.0.0: + version "4.2.0" + resolved "https://registry.npmmirror.com/camelcase-keys/download/camelcase-keys-4.2.0.tgz?cache=0&sync_timestamp=1633332959770&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcamelcase-keys%2Fdownload%2Fcamelcase-keys-4.2.0.tgz#a2aa5fb1af688758259c32c141426d78923b9b77" + integrity sha1-oqpfsa9oh1glnDLBQUJteJI7m3c= + dependencies: + camelcase "^4.1.0" + map-obj "^2.0.0" + quick-lru "^1.0.0" + +camelcase@5.0.0: + version "5.0.0" + resolved "https://registry.npmmirror.com/camelcase/download/camelcase-5.0.0.tgz?cache=0&sync_timestamp=1636945151239&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcamelcase%2Fdownload%2Fcamelcase-5.0.0.tgz#03295527d58bd3cd4aa75363f35b2e8d97be2f42" + integrity sha1-AylVJ9WL081Kp1Nj81sujZe+L0I= + +camelcase@5.3.1, camelcase@^5.0.0, camelcase@^5.3.1: + version "5.3.1" + resolved "https://registry.npm.taobao.org/camelcase/download/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" + integrity sha1-48mzFWnhBoEd8kL3FXJaH0xJQyA= + +camelcase@^2.0.0: + version "2.1.1" + resolved "https://registry.npmmirror.com/camelcase/download/camelcase-2.1.1.tgz?cache=0&sync_timestamp=1636945151239&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcamelcase%2Fdownload%2Fcamelcase-2.1.1.tgz#7c1d16d679a1bbe59ca02cacecfb011e201f5a1f" + integrity sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8= + +camelcase@^4.1.0: + version "4.1.0" + resolved "https://registry.npm.taobao.org/camelcase/download/camelcase-4.1.0.tgz#d545635be1e33c542649c69173e5de6acfae34dd" + integrity sha1-1UVjW+HjPFQmScaRc+Xeas+uNN0= + +camelcase@^6.0.0: + version "6.2.0" + resolved "https://registry.npm.taobao.org/camelcase/download/camelcase-6.2.0.tgz#924af881c9d525ac9d87f40d964e5cea982a1809" + integrity sha1-kkr4gcnVJaydh/QNlk5c6pgqGAk= + +camelize@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/camelize/download/camelize-1.0.0.tgz#164a5483e630fa4321e5af07020e531831b2609b" + integrity sha1-FkpUg+Yw+kMh5a8HAg5TGDGyYJs= + +caniuse-lite@^1.0.30000844, caniuse-lite@^1.0.30000864, caniuse-lite@^1.0.30001020, caniuse-lite@^1.0.30001274: + version "1.0.30001278" + resolved "https://registry.npmmirror.com/caniuse-lite/download/caniuse-lite-1.0.30001278.tgz?cache=0&sync_timestamp=1636095309539&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcaniuse-lite%2Fdownload%2Fcaniuse-lite-1.0.30001278.tgz#51cafc858df77d966b17f59b5839250b24417fff" + integrity sha1-Ucr8hY33fZZrF/WbWDklCyRBf/8= + +caniuse-lite@^1.0.30001280: + version "1.0.30001282" + resolved "https://registry.npmmirror.com/caniuse-lite/download/caniuse-lite-1.0.30001282.tgz?cache=0&sync_timestamp=1637135323561&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcaniuse-lite%2Fdownload%2Fcaniuse-lite-1.0.30001282.tgz#38c781ee0a90ccfe1fe7fefd00e43f5ffdcb96fd" + integrity sha512-YhF/hG6nqBEllymSIjLtR2iWDDnChvhnVJqp+vloyt2tEHFG1yBR+ac2B/rOw0qOK0m0lEXU2dv4E/sMk5P9Kg== + +caniuse-lite@^1.0.30001312: + version "1.0.30001312" + resolved "https://registry.npmmirror.com/caniuse-lite/-/caniuse-lite-1.0.30001312.tgz#e11eba4b87e24d22697dae05455d5aea28550d5f" + integrity sha512-Wiz1Psk2MEK0pX3rUzWaunLTZzqS2JYZFzNKqAiJGiuxIjRPLgV6+VDPOg6lQOUxmDwhTlh198JsTTi8Hzw6aQ== + +caseless@~0.12.0: + version "0.12.0" + resolved "https://registry.npm.taobao.org/caseless/download/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" + integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= + +ccount@^1.0.0: + version "1.1.0" + resolved "https://registry.npm.taobao.org/ccount/download/ccount-1.1.0.tgz?cache=0&sync_timestamp=1615299949257&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fccount%2Fdownload%2Fccount-1.1.0.tgz#246687debb6014735131be8abab2d93898f8d043" + integrity sha1-JGaH3rtgFHNRMb6KurLZOJj40EM= + +chalk@3.0.0, chalk@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/chalk/download/chalk-3.0.0.tgz?cache=0&sync_timestamp=1627646697260&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fchalk%2Fdownload%2Fchalk-3.0.0.tgz#3f73c2bf526591f574cc492c51e2456349f844e4" + integrity sha1-P3PCv1JlkfV0zEksUeJFY0n4ROQ= + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +chalk@^1.1.1, chalk@^1.1.3: + version "1.1.3" + resolved "https://registry.nlark.com/chalk/download/chalk-1.1.3.tgz?cache=0&sync_timestamp=1627646697260&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fchalk%2Fdownload%2Fchalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" + integrity sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg= + dependencies: + ansi-styles "^2.2.1" + escape-string-regexp "^1.0.2" + has-ansi "^2.0.0" + strip-ansi "^3.0.0" + supports-color "^2.0.0" + +chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.4.1, chalk@^2.4.2: + version "2.4.2" + resolved "https://registry.nlark.com/chalk/download/chalk-2.4.2.tgz?cache=0&sync_timestamp=1627646697260&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fchalk%2Fdownload%2Fchalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" + integrity sha1-zUJUFnelQzPPVBpJEIwUMrRMlCQ= + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + +chalk@^4.1.0: + version "4.1.2" + resolved "https://registry.nlark.com/chalk/download/chalk-4.1.2.tgz?cache=0&sync_timestamp=1627646697260&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fchalk%2Fdownload%2Fchalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" + integrity sha1-qsTit3NKdAhnrrFr8CqtVWoeegE= + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +character-entities-html4@^1.0.0: + version "1.1.4" + resolved "https://registry.npmmirror.com/character-entities-html4/download/character-entities-html4-1.1.4.tgz#0e64b0a3753ddbf1fdc044c5fd01d0199a02e125" + integrity sha1-DmSwo3U92/H9wETF/QHQGZoC4SU= + +character-entities-legacy@^1.0.0: + version "1.1.4" + resolved "https://registry.npmmirror.com/character-entities-legacy/download/character-entities-legacy-1.1.4.tgz?cache=0&sync_timestamp=1635911795757&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcharacter-entities-legacy%2Fdownload%2Fcharacter-entities-legacy-1.1.4.tgz#94bc1845dce70a5bb9d2ecc748725661293d8fc1" + integrity sha1-lLwYRdznClu50uzHSHJWYSk9j8E= + +character-entities@^1.0.0: + version "1.2.4" + resolved "https://registry.npmmirror.com/character-entities/download/character-entities-1.2.4.tgz?cache=0&sync_timestamp=1635869177182&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcharacter-entities%2Fdownload%2Fcharacter-entities-1.2.4.tgz#e12c3939b7eaf4e5b15e7ad4c5e28e1d48c5b16b" + integrity sha1-4Sw5Obfq9OWxXnrUxeKOHUjFsWs= + +character-reference-invalid@^1.0.0: + version "1.1.4" + resolved "https://registry.nlark.com/character-reference-invalid/download/character-reference-invalid-1.1.4.tgz#083329cda0eae272ab3dbbf37e9a382c13af1560" + integrity sha1-CDMpzaDq4nKrPbvzfpo4LBOvFWA= + +chardet@^0.7.0: + version "0.7.0" + resolved "https://registry.npmmirror.com/chardet/download/chardet-0.7.0.tgz?cache=0&sync_timestamp=1634639141514&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fchardet%2Fdownload%2Fchardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" + integrity sha1-kAlISfCTfy7twkJdDSip5fDLrZ4= + +charenc@0.0.2: + version "0.0.2" + resolved "https://registry.npm.taobao.org/charenc/download/charenc-0.0.2.tgz#c0a1d2f3a7092e03774bfa83f14c0fc5790a8667" + integrity sha1-wKHS86cJLgN3S/qD8UwPxXkKhmc= + +chokidar@3.3.1: + version "3.3.1" + resolved "https://registry.nlark.com/chokidar/download/chokidar-3.3.1.tgz?cache=0&sync_timestamp=1623763535523&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fchokidar%2Fdownload%2Fchokidar-3.3.1.tgz#c84e5b3d18d9a4d77558fef466b1bf16bbeb3450" + integrity sha1-yE5bPRjZpNd1WP70ZrG/FrvrNFA= + dependencies: + anymatch "~3.1.1" + braces "~3.0.2" + glob-parent "~5.1.0" + is-binary-path "~2.1.0" + is-glob "~4.0.1" + normalize-path "~3.0.0" + readdirp "~3.3.0" + optionalDependencies: + fsevents "~2.1.2" + +"chokidar@>=3.0.0 <4.0.0", chokidar@^3.3.1, chokidar@^3.4.1: + version "3.5.2" + resolved "https://registry.nlark.com/chokidar/download/chokidar-3.5.2.tgz?cache=0&sync_timestamp=1623763535523&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fchokidar%2Fdownload%2Fchokidar-3.5.2.tgz#dba3976fcadb016f66fd365021d91600d01c1e75" + integrity sha1-26OXb8rbAW9m/TZQIdkWANAcHnU= + dependencies: + anymatch "~3.1.2" + braces "~3.0.2" + glob-parent "~5.1.2" + is-binary-path "~2.1.0" + is-glob "~4.0.1" + normalize-path "~3.0.0" + readdirp "~3.6.0" + optionalDependencies: + fsevents "~2.3.2" + +chokidar@^2.1.8: + version "2.1.8" + resolved "https://registry.nlark.com/chokidar/download/chokidar-2.1.8.tgz?cache=0&sync_timestamp=1623763535523&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fchokidar%2Fdownload%2Fchokidar-2.1.8.tgz#804b3a7b6a99358c3c5c61e71d8728f041cff917" + integrity sha1-gEs6e2qZNYw8XGHnHYco8EHP+Rc= + dependencies: + anymatch "^2.0.0" + async-each "^1.0.1" + braces "^2.3.2" + glob-parent "^3.1.0" + inherits "^2.0.3" + is-binary-path "^1.0.0" + is-glob "^4.0.0" + normalize-path "^3.0.0" + path-is-absolute "^1.0.0" + readdirp "^2.2.1" + upath "^1.1.1" + optionalDependencies: + fsevents "^1.2.7" + +chownr@^1.1.1: + version "1.1.4" + resolved "https://registry.nlark.com/chownr/download/chownr-1.1.4.tgz#6fc9d7b42d32a583596337666e7d08084da2cc6b" + integrity sha1-b8nXtC0ypYNZYzdmbn0ICE2izGs= + +chownr@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/chownr/download/chownr-2.0.0.tgz#15bfbe53d2eab4cf70f18a8cd68ebe5b3cb1dece" + integrity sha1-Fb++U9LqtM9w8YqM1o6+Wzyx3s4= + +chrome-trace-event@^1.0.2: + version "1.0.3" + resolved "https://registry.nlark.com/chrome-trace-event/download/chrome-trace-event-1.0.3.tgz#1015eced4741e15d06664a957dbbf50d041e26ac" + integrity sha1-EBXs7UdB4V0GZkqVfbv1DQQeJqw= + +cipher-base@^1.0.0, cipher-base@^1.0.1, cipher-base@^1.0.3: + version "1.0.4" + resolved "https://registry.nlark.com/cipher-base/download/cipher-base-1.0.4.tgz#8760e4ecc272f4c363532f926d874aae2c1397de" + integrity sha1-h2Dk7MJy9MNjUy+SbYdKriwTl94= + dependencies: + inherits "^2.0.1" + safe-buffer "^5.0.1" + +circular-json@^0.3.1: + version "0.3.3" + resolved "https://registry.npmmirror.com/circular-json/download/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" + integrity sha1-gVyZ6oT2gJUp0vRXkb34JxE1LWY= + +class-utils@^0.3.5: + version "0.3.6" + resolved "https://registry.nlark.com/class-utils/download/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" + integrity sha1-+TNprouafOAv1B+q0MqDAzGQxGM= + dependencies: + arr-union "^3.1.0" + define-property "^0.2.5" + isobject "^3.0.0" + static-extend "^0.1.1" + +classnames@^2.2.5, classnames@^2.2.6: + version "2.3.1" + resolved "https://registry.nlark.com/classnames/download/classnames-2.3.1.tgz#dfcfa3891e306ec1dad105d0e88f4417b8535e8e" + integrity sha1-38+jiR4wbsHa0QXQ6I9EF7hTXo4= + +clean-css@4.2.x, clean-css@^4.2.1: + version "4.2.4" + resolved "https://registry.npmmirror.com/clean-css/download/clean-css-4.2.4.tgz?cache=0&sync_timestamp=1634992314911&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fclean-css%2Fdownload%2Fclean-css-4.2.4.tgz#733bf46eba4e607c6891ea57c24a989356831178" + integrity sha1-czv0brpOYHxokepXwkqYk1aDEXg= + dependencies: + source-map "~0.6.0" + +clean-stack@^2.0.0: + version "2.2.0" + resolved "https://registry.nlark.com/clean-stack/download/clean-stack-2.2.0.tgz?cache=0&sync_timestamp=1622605328444&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fclean-stack%2Fdownload%2Fclean-stack-2.2.0.tgz#ee8472dbb129e727b31e8a10a427dee9dfe4008b" + integrity sha1-7oRy27Ep5yezHooQpCfe6d/kAIs= + +cli-cursor@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/cli-cursor/download/cli-cursor-2.1.0.tgz?cache=0&sync_timestamp=1629747481175&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcli-cursor%2Fdownload%2Fcli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" + integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= + dependencies: + restore-cursor "^2.0.0" + +cli-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.nlark.com/cli-cursor/download/cli-cursor-3.1.0.tgz?cache=0&sync_timestamp=1629747481175&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcli-cursor%2Fdownload%2Fcli-cursor-3.1.0.tgz#264305a7ae490d1d03bf0c9ba7c925d1753af307" + integrity sha1-JkMFp65JDR0Dvwybp8kl0XU68wc= + dependencies: + restore-cursor "^3.1.0" + +cli-spinners@^2.0.0, cli-spinners@^2.2.0: + version "2.6.1" + resolved "https://registry.npmmirror.com/cli-spinners/download/cli-spinners-2.6.1.tgz?cache=0&sync_timestamp=1633109609172&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcli-spinners%2Fdownload%2Fcli-spinners-2.6.1.tgz#adc954ebe281c37a6319bfa401e6dd2488ffb70d" + integrity sha1-rclU6+KBw3pjGb+kAebdJIj/tw0= + +cli-width@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/cli-width/download/cli-width-3.0.0.tgz#a2f48437a2caa9a22436e794bf071ec9e61cedf6" + integrity sha1-ovSEN6LKqaIkNueUvwceyeYc7fY= + +cli@~1.0.0: + version "1.0.1" + resolved "https://registry.npm.taobao.org/cli/download/cli-1.0.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcli%2Fdownload%2Fcli-1.0.1.tgz#22817534f24bfa4950c34d532d48ecbc621b8c14" + integrity sha1-IoF1NPJL+klQw01TLUjsvGIbjBQ= + dependencies: + exit "0.1.2" + glob "^7.1.1" + +cliui@^5.0.0: + version "5.0.0" + resolved "https://registry.nlark.com/cliui/download/cliui-5.0.0.tgz#deefcfdb2e800784aa34f46fa08e06851c7bbbc5" + integrity sha1-3u/P2y6AB4SqNPRvoI4GhRx7u8U= + dependencies: + string-width "^3.1.0" + strip-ansi "^5.2.0" + wrap-ansi "^5.1.0" + +clone-deep@^4.0.1: + version "4.0.1" + resolved "https://registry.nlark.com/clone-deep/download/clone-deep-4.0.1.tgz#c19fd9bdbbf85942b4fd979c84dcf7d5f07c2387" + integrity sha1-wZ/Zvbv4WUK0/ZechNz31fB8I4c= + dependencies: + is-plain-object "^2.0.4" + kind-of "^6.0.2" + shallow-clone "^3.0.0" + +clone-regexp@^1.0.0: + version "1.0.1" + resolved "https://registry.npm.taobao.org/clone-regexp/download/clone-regexp-1.0.1.tgz?cache=0&sync_timestamp=1617892092032&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fclone-regexp%2Fdownload%2Fclone-regexp-1.0.1.tgz#051805cd33173375d82118fc0918606da39fd60f" + integrity sha1-BRgFzTMXM3XYIRj8CRhgbaOf1g8= + dependencies: + is-regexp "^1.0.0" + is-supported-regexp-flag "^1.0.0" + +clone@^1.0.2: + version "1.0.4" + resolved "https://registry.nlark.com/clone/download/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" + integrity sha1-2jCcwmPfFZlMaIypAheco8fNfH4= + +clsx@^1.1.1: + version "1.1.1" + resolved "https://registry.npmmirror.com/clsx/-/clsx-1.1.1.tgz#98b3134f9abbdf23b2663491ace13c5c03a73188" + integrity sha512-6/bPho624p3S2pMyvP5kKBPXnI3ufHLObBFCfgx+LkeR5lg2XYy2hqZqUf45ypD8COn2bhgGJSUE+l5dhNBieA== + +code-point-at@^1.0.0: + version "1.1.0" + resolved "https://registry.npmmirror.com/code-point-at/download/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" + integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= + +collapse-white-space@^1.0.2: + version "1.0.6" + resolved "https://registry.npm.taobao.org/collapse-white-space/download/collapse-white-space-1.0.6.tgz?cache=0&sync_timestamp=1615196586817&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcollapse-white-space%2Fdownload%2Fcollapse-white-space-1.0.6.tgz#e63629c0016665792060dbbeb79c42239d2c5287" + integrity sha1-5jYpwAFmZXkgYNu+t5xCI50sUoc= + +collection-visit@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/collection-visit/download/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" + integrity sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA= + dependencies: + map-visit "^1.0.0" + object-visit "^1.0.0" + +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.npm.taobao.org/color-convert/download/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" + integrity sha1-u3GFBpDh8TZWfeYp0tVHHe2kweg= + dependencies: + color-name "1.1.3" + +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.npm.taobao.org/color-convert/download/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha1-ctOmjVmMm9s68q0ehPIdiWq9TeM= + dependencies: + color-name "~1.1.4" + +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.npm.taobao.org/color-name/download/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" + integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= + +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.npm.taobao.org/color-name/download/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" + integrity sha1-wqCah6y95pVD3m9j+jmVyCbFNqI= + +colorette@^1.2.2: + version "1.4.0" + resolved "https://registry.npmmirror.com/colorette/download/colorette-1.4.0.tgz#5190fbb87276259a86ad700bff2c6d6faa3fca40" + integrity sha1-UZD7uHJ2JZqGrXAL/yxtb6o/ykA= + +combined-stream@^1.0.6, combined-stream@~1.0.6: + version "1.0.8" + resolved "https://registry.nlark.com/combined-stream/download/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" + integrity sha1-w9RaizT9cwYxoRCoolIGgrMdWn8= + dependencies: + delayed-stream "~1.0.0" + +commander@2.17.x: + version "2.17.1" + resolved "https://registry.npmmirror.com/commander/download/commander-2.17.1.tgz?cache=0&sync_timestamp=1634886396986&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcommander%2Fdownload%2Fcommander-2.17.1.tgz#bd77ab7de6de94205ceacc72f1716d29f20a77bf" + integrity sha1-vXerfebelCBc6sxy8XFtKfIKd78= + +commander@^2.19.0, commander@^2.20.0: + version "2.20.3" + resolved "https://registry.npmmirror.com/commander/download/commander-2.20.3.tgz?cache=0&sync_timestamp=1634886396986&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcommander%2Fdownload%2Fcommander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" + integrity sha1-/UhehMA+tIgcIHIrpIA16FMa6zM= + +commander@^4.0.1: + version "4.1.1" + resolved "https://registry.npmmirror.com/commander/download/commander-4.1.1.tgz?cache=0&sync_timestamp=1634886396986&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcommander%2Fdownload%2Fcommander-4.1.1.tgz#9fd602bd936294e9e9ef46a3f4d6964044b18068" + integrity sha1-n9YCvZNilOnp70aj9NaWQESxgGg= + +commander@^7.2.0: + version "7.2.0" + resolved "https://registry.npmmirror.com/commander/download/commander-7.2.0.tgz?cache=0&sync_timestamp=1634886396986&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcommander%2Fdownload%2Fcommander-7.2.0.tgz#a36cb57d0b501ce108e4d20559a150a391d97ab7" + integrity sha1-o2y1fQtQHOEI5NIFWaFQo5HZerc= + +commander@~2.19.0: + version "2.19.0" + resolved "https://registry.npmmirror.com/commander/download/commander-2.19.0.tgz?cache=0&sync_timestamp=1634886396986&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcommander%2Fdownload%2Fcommander-2.19.0.tgz#f6198aa84e5b83c46054b94ddedbfed5ee9ff12a" + integrity sha1-9hmKqE5bg8RgVLlN3tv+1e6f8So= + +commondir@^1.0.1: + version "1.0.1" + resolved "https://registry.npm.taobao.org/commondir/download/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" + integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= + +component-emitter@^1.2.1: + version "1.3.0" + resolved "https://registry.nlark.com/component-emitter/download/component-emitter-1.3.0.tgz#16e4070fba8ae29b679f2215853ee181ab2eabc0" + integrity sha1-FuQHD7qK4ptnnyIVhT7hgasuq8A= + +compose-function@3.0.3: + version "3.0.3" + resolved "https://registry.nlark.com/compose-function/download/compose-function-3.0.3.tgz#9ed675f13cc54501d30950a486ff6a7ba3ab185f" + integrity sha1-ntZ18TzFRQHTCVCkhv9qe6OrGF8= + dependencies: + arity-n "^1.0.4" + +compressible@~2.0.16: + version "2.0.18" + resolved "https://registry.nlark.com/compressible/download/compressible-2.0.18.tgz#af53cca6b070d4c3c0750fbd77286a6d7cc46fba" + integrity sha1-r1PMprBw1MPAdQ+9dyhqbXzEb7o= + dependencies: + mime-db ">= 1.43.0 < 2" + +compression@^1.7.4: + version "1.7.4" + resolved "https://registry.npm.taobao.org/compression/download/compression-1.7.4.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcompression%2Fdownload%2Fcompression-1.7.4.tgz#95523eff170ca57c29a0ca41e6fe131f41e5bb8f" + integrity sha1-lVI+/xcMpXwpoMpB5v4TH0Hlu48= + dependencies: + accepts "~1.3.5" + bytes "3.0.0" + compressible "~2.0.16" + debug "2.6.9" + on-headers "~1.0.2" + safe-buffer "5.1.2" + vary "~1.1.2" + +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.nlark.com/concat-map/download/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" + integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= + +concat-stream@^1.5.0: + version "1.6.2" + resolved "https://registry.nlark.com/concat-stream/download/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" + integrity sha1-kEvfGUzTEi/Gdcd/xKw9T/D9GjQ= + dependencies: + buffer-from "^1.0.0" + inherits "^2.0.3" + readable-stream "^2.2.2" + typedarray "^0.0.6" + +connect-history-api-fallback@^1.6.0: + version "1.6.0" + resolved "https://registry.nlark.com/connect-history-api-fallback/download/connect-history-api-fallback-1.6.0.tgz?cache=0&sync_timestamp=1618847040596&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fconnect-history-api-fallback%2Fdownload%2Fconnect-history-api-fallback-1.6.0.tgz#8b32089359308d111115d81cad3fceab888f97bc" + integrity sha1-izIIk1kwjRERFdgcrT/Oq4iPl7w= + +console-browserify@1.1.x: + version "1.1.0" + resolved "https://registry.nlark.com/console-browserify/download/console-browserify-1.1.0.tgz#f0241c45730a9fc6323b206dbf38edc741d0bb10" + integrity sha1-8CQcRXMKn8YyOyBtvzjtx0HQuxA= + dependencies: + date-now "^0.1.4" + +console-browserify@^1.1.0: + version "1.2.0" + resolved "https://registry.nlark.com/console-browserify/download/console-browserify-1.2.0.tgz#67063cef57ceb6cf4993a2ab3a55840ae8c49336" + integrity sha1-ZwY871fOts9Jk6KrOlWECujEkzY= + +console-control-strings@^1.0.0, console-control-strings@~1.1.0: + version "1.1.0" + resolved "https://registry.npm.taobao.org/console-control-strings/download/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" + integrity sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4= + +constants-browserify@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/constants-browserify/download/constants-browserify-1.0.0.tgz#c20b96d8c617748aaf1c16021760cd27fcb8cb75" + integrity sha1-wguW2MYXdIqvHBYCF2DNJ/y4y3U= + +content-disposition@0.5.3: + version "0.5.3" + resolved "https://registry.nlark.com/content-disposition/download/content-disposition-0.5.3.tgz#e130caf7e7279087c5616c2007d0485698984fbd" + integrity sha1-4TDK9+cnkIfFYWwgB9BIVpiYT70= + dependencies: + safe-buffer "5.1.2" + +content-type@~1.0.4: + version "1.0.4" + resolved "https://registry.nlark.com/content-type/download/content-type-1.0.4.tgz#e138cc75e040c727b1966fe5e5f8c9aee256fe3b" + integrity sha1-4TjMdeBAxyexlm/l5fjJruJW/js= + +convert-source-map@1.7.0: + version "1.7.0" + resolved "https://registry.nlark.com/convert-source-map/download/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" + integrity sha1-F6LLiC1/d9NJBYXizmxSRCSjpEI= + dependencies: + safe-buffer "~5.1.1" + +convert-source-map@^0.3.3: + version "0.3.5" + resolved "https://registry.nlark.com/convert-source-map/download/convert-source-map-0.3.5.tgz#f1d802950af7dd2631a1febe0596550c86ab3190" + integrity sha1-8dgClQr33SYxof6+BZZVDIarMZA= + +convert-source-map@^1.7.0: + version "1.8.0" + resolved "https://registry.nlark.com/convert-source-map/download/convert-source-map-1.8.0.tgz#f3373c32d21b4d780dd8004514684fb791ca4369" + integrity sha1-8zc8MtIbTXgN2ABFFGhPt5HKQ2k= + dependencies: + safe-buffer "~5.1.1" + +cookie-signature@1.0.6: + version "1.0.6" + resolved "https://registry.npm.taobao.org/cookie-signature/download/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c" + integrity sha1-4wOogrNCzD7oylE6eZmXNNqzriw= + +cookie@0.4.0: + version "0.4.0" + resolved "https://registry.npm.taobao.org/cookie/download/cookie-0.4.0.tgz#beb437e7022b3b6d49019d088665303ebe9c14ba" + integrity sha1-vrQ35wIrO21JAZ0IhmUwPr6cFLo= + +copy-anything@^2.0.1: + version "2.0.3" + resolved "https://registry.nlark.com/copy-anything/download/copy-anything-2.0.3.tgz#842407ba02466b0df844819bbe3baebbe5d45d87" + integrity sha1-hCQHugJGaw34RIGbvjuuu+XUXYc= + dependencies: + is-what "^3.12.0" + +copy-concurrently@^1.0.0: + version "1.0.5" + resolved "https://registry.nlark.com/copy-concurrently/download/copy-concurrently-1.0.5.tgz#92297398cae34937fcafd6ec8139c18051f0b5e0" + integrity sha1-kilzmMrjSTf8r9bsgTnBgFHwteA= + dependencies: + aproba "^1.1.1" + fs-write-stream-atomic "^1.0.8" + iferr "^0.1.5" + mkdirp "^0.5.1" + rimraf "^2.5.4" + run-queue "^1.0.0" + +copy-descriptor@^0.1.0: + version "0.1.1" + resolved "https://registry.npm.taobao.org/copy-descriptor/download/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" + integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= + +copy-to-clipboard@^3.3.1: + version "3.3.1" + resolved "https://registry.nlark.com/copy-to-clipboard/download/copy-to-clipboard-3.3.1.tgz#115aa1a9998ffab6196f93076ad6da3b913662ae" + integrity sha1-EVqhqZmP+rYZb5MHatbaO5E2Yq4= + dependencies: + toggle-selection "^1.0.6" + +copy-webpack-plugin@5.1.1: + version "5.1.1" + resolved "https://registry.nlark.com/copy-webpack-plugin/download/copy-webpack-plugin-5.1.1.tgz?cache=0&sync_timestamp=1624628458516&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcopy-webpack-plugin%2Fdownload%2Fcopy-webpack-plugin-5.1.1.tgz#5481a03dea1123d88a988c6ff8b78247214f0b88" + integrity sha1-VIGgPeoRI9iKmIxv+LeCRyFPC4g= + dependencies: + cacache "^12.0.3" + find-cache-dir "^2.1.0" + glob-parent "^3.1.0" + globby "^7.1.1" + is-glob "^4.0.1" + loader-utils "^1.2.3" + minimatch "^3.0.4" + normalize-path "^3.0.0" + p-limit "^2.2.1" + schema-utils "^1.0.0" + serialize-javascript "^2.1.2" + webpack-log "^2.0.0" + +copy-webpack-plugin@5.1.2: + version "5.1.2" + resolved "https://registry.nlark.com/copy-webpack-plugin/download/copy-webpack-plugin-5.1.2.tgz?cache=0&sync_timestamp=1624628458516&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcopy-webpack-plugin%2Fdownload%2Fcopy-webpack-plugin-5.1.2.tgz#8a889e1dcafa6c91c6cd4be1ad158f1d3823bae2" + integrity sha1-ioieHcr6bJHGzUvhrRWPHTgjuuI= + dependencies: + cacache "^12.0.3" + find-cache-dir "^2.1.0" + glob-parent "^3.1.0" + globby "^7.1.1" + is-glob "^4.0.1" + loader-utils "^1.2.3" + minimatch "^3.0.4" + normalize-path "^3.0.0" + p-limit "^2.2.1" + schema-utils "^1.0.0" + serialize-javascript "^4.0.0" + webpack-log "^2.0.0" + +core-js-compat@^3.18.0, core-js-compat@^3.19.0, core-js-compat@^3.6.2: + version "3.19.1" + resolved "https://registry.npmmirror.com/core-js-compat/download/core-js-compat-3.19.1.tgz?cache=0&sync_timestamp=1635883211921&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcore-js-compat%2Fdownload%2Fcore-js-compat-3.19.1.tgz#fe598f1a9bf37310d77c3813968e9f7c7bb99476" + integrity sha1-/lmPGpvzcxDXfDgTlo6ffHu5lHY= + dependencies: + browserslist "^4.17.6" + semver "7.0.0" + +core-js-compat@^3.20.2, core-js-compat@^3.21.0: + version "3.21.1" + resolved "https://registry.npmmirror.com/core-js-compat/-/core-js-compat-3.21.1.tgz#cac369f67c8d134ff8f9bd1623e3bc2c42068c82" + integrity sha512-gbgX5AUvMb8gwxC7FLVWYT7Kkgu/y7+h/h1X43yJkNqhlK2fuYyQimqvKGNZFAY6CKii/GFKJ2cp/1/42TN36g== + dependencies: + browserslist "^4.19.1" + semver "7.0.0" + +core-js-pure@^3.19.0: + version "3.19.1" + resolved "https://registry.npmmirror.com/core-js-pure/download/core-js-pure-3.19.1.tgz?cache=0&sync_timestamp=1635883214117&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcore-js-pure%2Fdownload%2Fcore-js-pure-3.19.1.tgz#edffc1fc7634000a55ba05e95b3f0fe9587a5aa4" + integrity sha1-7f/B/HY0AApVugXpWz8P6Vh6WqQ= + +core-js@^2.4.0: + version "2.6.12" + resolved "https://registry.npmmirror.com/core-js/download/core-js-2.6.12.tgz?cache=0&sync_timestamp=1635883139752&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcore-js%2Fdownload%2Fcore-js-2.6.12.tgz#d9333dfa7b065e347cc5682219d6f690859cc2ec" + integrity sha1-2TM9+nsGXjR8xWgiGdb2kIWcwuw= + +core-js@^3.6.5: + version "3.19.1" + resolved "https://registry.npmmirror.com/core-js/download/core-js-3.19.1.tgz?cache=0&sync_timestamp=1635883139752&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcore-js%2Fdownload%2Fcore-js-3.19.1.tgz#f6f173cae23e73a7d88fa23b6e9da329276c6641" + integrity sha1-9vFzyuI+c6fYj6I7bp2jKSdsZkE= + +core-util-is@1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/core-util-is/download/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" + integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= + +core-util-is@~1.0.0: + version "1.0.3" + resolved "https://registry.nlark.com/core-util-is/download/core-util-is-1.0.3.tgz#a6042d3634c2b27e9328f837b965fac83808db85" + integrity sha1-pgQtNjTCsn6TKPg3uWX6yDgI24U= + +cosmiconfig@^5.0.0, cosmiconfig@^5.1.0: + version "5.2.1" + resolved "https://registry.nlark.com/cosmiconfig/download/cosmiconfig-5.2.1.tgz?cache=0&sync_timestamp=1629585969900&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcosmiconfig%2Fdownload%2Fcosmiconfig-5.2.1.tgz#040f726809c591e77a17c0a3626ca45b4f168b1a" + integrity sha1-BA9yaAnFked6F8CjYmykW08Wixo= + dependencies: + import-fresh "^2.0.0" + is-directory "^0.3.1" + js-yaml "^3.13.1" + parse-json "^4.0.0" + +cosmiconfig@^7.0.0: + version "7.0.1" + resolved "https://registry.nlark.com/cosmiconfig/download/cosmiconfig-7.0.1.tgz?cache=0&sync_timestamp=1629585969900&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcosmiconfig%2Fdownload%2Fcosmiconfig-7.0.1.tgz#714d756522cace867867ccb4474c5d01bbae5d6d" + integrity sha1-cU11ZSLKzoZ4Z8y0R0xdAbuuXW0= + dependencies: + "@types/parse-json" "^4.0.0" + import-fresh "^3.2.1" + parse-json "^5.0.0" + path-type "^4.0.0" + yaml "^1.10.0" + +create-ecdh@^4.0.0: + version "4.0.4" + resolved "https://registry.nlark.com/create-ecdh/download/create-ecdh-4.0.4.tgz#d6e7f4bffa66736085a0762fd3a632684dabcc4e" + integrity sha1-1uf0v/pmc2CFoHYv06YyaE2rzE4= + dependencies: + bn.js "^4.1.0" + elliptic "^6.5.3" + +create-hash@^1.1.0, create-hash@^1.1.2, create-hash@^1.2.0: + version "1.2.0" + resolved "https://registry.nlark.com/create-hash/download/create-hash-1.2.0.tgz#889078af11a63756bcfb59bd221996be3a9ef196" + integrity sha1-iJB4rxGmN1a8+1m9IhmWvjqe8ZY= + dependencies: + cipher-base "^1.0.1" + inherits "^2.0.1" + md5.js "^1.3.4" + ripemd160 "^2.0.1" + sha.js "^2.4.0" + +create-hmac@^1.1.0, create-hmac@^1.1.4, create-hmac@^1.1.7: + version "1.1.7" + resolved "https://registry.nlark.com/create-hmac/download/create-hmac-1.1.7.tgz#69170c78b3ab957147b2b8b04572e47ead2243ff" + integrity sha1-aRcMeLOrlXFHsriwRXLkfq0iQ/8= + dependencies: + cipher-base "^1.0.3" + create-hash "^1.1.0" + inherits "^2.0.1" + ripemd160 "^2.0.0" + safe-buffer "^5.0.1" + sha.js "^2.4.8" + +cross-spawn@7.0.1: + version "7.0.1" + resolved "https://registry.nlark.com/cross-spawn/download/cross-spawn-7.0.1.tgz#0ab56286e0f7c24e153d04cc2aa027e43a9a5d14" + integrity sha1-CrVihuD3wk4VPQTMKqAn5DqaXRQ= + dependencies: + path-key "^3.1.0" + shebang-command "^2.0.0" + which "^2.0.1" + +cross-spawn@7.0.3: + version "7.0.3" + resolved "https://registry.nlark.com/cross-spawn/download/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" + integrity sha1-9zqFudXUHQRVUcF34ogtSshXKKY= + dependencies: + path-key "^3.1.0" + shebang-command "^2.0.0" + which "^2.0.1" + +cross-spawn@^3.0.0: + version "3.0.1" + resolved "https://registry.nlark.com/cross-spawn/download/cross-spawn-3.0.1.tgz#1256037ecb9f0c5f79e3d6ef135e30770184b982" + integrity sha1-ElYDfsufDF9549bvE14wdwGEuYI= + dependencies: + lru-cache "^4.0.1" + which "^1.2.9" + +cross-spawn@^6.0.0, cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.nlark.com/cross-spawn/download/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" + integrity sha1-Sl7Hxk364iw6FBJNus3uhG2Ay8Q= + dependencies: + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" + +crypt@0.0.2: + version "0.0.2" + resolved "https://registry.nlark.com/crypt/download/crypt-0.0.2.tgz#88d7ff7ec0dfb86f713dc87bbb42d044d3e6c41b" + integrity sha1-iNf/fsDfuG9xPch7u0LQRNPmxBs= + +crypto-browserify@^3.11.0: + version "3.12.0" + resolved "https://registry.npm.taobao.org/crypto-browserify/download/crypto-browserify-3.12.0.tgz#396cf9f3137f03e4b8e532c58f698254e00f80ec" + integrity sha1-OWz58xN/A+S45TLFj2mCVOAPgOw= + dependencies: + browserify-cipher "^1.0.0" + browserify-sign "^4.0.0" + create-ecdh "^4.0.0" + create-hash "^1.1.0" + create-hmac "^1.1.0" + diffie-hellman "^5.0.0" + inherits "^2.0.1" + pbkdf2 "^3.0.3" + public-encrypt "^4.0.0" + randombytes "^2.0.0" + randomfill "^1.0.3" + +css-color-keywords@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/css-color-keywords/download/css-color-keywords-1.0.0.tgz#fea2616dc676b2962686b3af8dbdbe180b244e05" + integrity sha1-/qJhbcZ2spYmhrOvjb2+GAskTgU= + +css-loader@3.4.2: + version "3.4.2" + resolved "https://registry.npmmirror.com/css-loader/download/css-loader-3.4.2.tgz?cache=0&sync_timestamp=1635967924209&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcss-loader%2Fdownload%2Fcss-loader-3.4.2.tgz#d3fdb3358b43f233b78501c5ed7b1c6da6133202" + integrity sha1-0/2zNYtD8jO3hQHF7XscbaYTMgI= + dependencies: + camelcase "^5.3.1" + cssesc "^3.0.0" + icss-utils "^4.1.1" + loader-utils "^1.2.3" + normalize-path "^3.0.0" + postcss "^7.0.23" + postcss-modules-extract-imports "^2.0.0" + postcss-modules-local-by-default "^3.0.2" + postcss-modules-scope "^2.1.1" + postcss-modules-values "^3.0.0" + postcss-value-parser "^4.0.2" + schema-utils "^2.6.0" + +css-loader@^3.0.0: + version "3.6.0" + resolved "https://registry.npmmirror.com/css-loader/download/css-loader-3.6.0.tgz?cache=0&sync_timestamp=1635967924209&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fcss-loader%2Fdownload%2Fcss-loader-3.6.0.tgz#2e4b2c7e6e2d27f8c8f28f61bffcd2e6c91ef645" + integrity sha1-Lkssfm4tJ/jI8o9hv/zS5ske9kU= + dependencies: + camelcase "^5.3.1" + cssesc "^3.0.0" + icss-utils "^4.1.1" + loader-utils "^1.2.3" + normalize-path "^3.0.0" + postcss "^7.0.32" + postcss-modules-extract-imports "^2.0.0" + postcss-modules-local-by-default "^3.0.2" + postcss-modules-scope "^2.2.0" + postcss-modules-values "^3.0.0" + postcss-value-parser "^4.1.0" + schema-utils "^2.7.0" + semver "^6.3.0" + +css-mediaquery@^0.1.2: + version "0.1.2" + resolved "https://registry.npm.taobao.org/css-mediaquery/download/css-mediaquery-0.1.2.tgz#6a2c37344928618631c54bd33cedd301da18bea0" + integrity sha1-aiw3NEkoYYYxxUvTPO3TAdoYvqA= + +css-parse@~2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/css-parse/download/css-parse-2.0.0.tgz#a468ee667c16d81ccf05c58c38d2a97c780dbfd4" + integrity sha1-pGjuZnwW2BzPBcWMONKpfHgNv9Q= + dependencies: + css "^2.0.0" + +css-select@^4.1.3: + version "4.1.3" + resolved "https://registry.nlark.com/css-select/download/css-select-4.1.3.tgz?cache=0&sync_timestamp=1622994276976&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcss-select%2Fdownload%2Fcss-select-4.1.3.tgz#a70440f70317f2669118ad74ff105e65849c7067" + integrity sha1-pwRA9wMX8maRGK10/xBeZYSccGc= + dependencies: + boolbase "^1.0.0" + css-what "^5.0.0" + domhandler "^4.2.0" + domutils "^2.6.0" + nth-check "^2.0.0" + +css-tree@1.0.0-alpha.29: + version "1.0.0-alpha.29" + resolved "https://registry.nlark.com/css-tree/download/css-tree-1.0.0-alpha.29.tgz#3fa9d4ef3142cbd1c301e7664c1f352bd82f5a39" + integrity sha1-P6nU7zFCy9HDAedmTB81K9gvWjk= + dependencies: + mdn-data "~1.1.0" + source-map "^0.5.3" + +css-tree@^1.1.2: + version "1.1.3" + resolved "https://registry.nlark.com/css-tree/download/css-tree-1.1.3.tgz#eb4870fb6fd7707327ec95c2ff2ab09b5e8db91d" + integrity sha1-60hw+2/XcHMn7JXC/yqwm16NuR0= + dependencies: + mdn-data "2.0.14" + source-map "^0.6.1" + +css-what@^5.0.0: + version "5.1.0" + resolved "https://registry.npmmirror.com/css-what/download/css-what-5.1.0.tgz#3f7b707aadf633baf62c2ceb8579b545bb40f7fe" + integrity sha1-P3tweq32M7r2LCzrhXm1RbtA9/4= + +css@2.2.4, css@^2.0.0, css@^2.2.4: + version "2.2.4" + resolved "https://registry.npm.taobao.org/css/download/css-2.2.4.tgz#c646755c73971f2bba6a601e2cf2fd71b1298929" + integrity sha1-xkZ1XHOXHyu6amAeLPL9cbEpiSk= + dependencies: + inherits "^2.0.3" + source-map "^0.6.1" + source-map-resolve "^0.5.2" + urix "^0.1.0" + +cssesc@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/cssesc/download/cssesc-3.0.0.tgz#37741919903b868565e1c09ea747445cd18983ee" + integrity sha1-N3QZGZA7hoVl4cCep0dEXNGJg+4= + +csso-webpack-plugin@2.0.0-beta.1: + version "2.0.0-beta.1" + resolved "https://registry.npm.taobao.org/csso-webpack-plugin/download/csso-webpack-plugin-2.0.0-beta.1.tgz#92a133ef697c65b11f7ba3c72db11fcf950d7293" + integrity sha1-kqEz72l8ZbEfe6PHLbEfz5UNcpM= + dependencies: + csso "^4.0.2" + source-map "^0.7.3" + webpack-sources "^1.0.1" + +csso@^3.5.1: + version "3.5.1" + resolved "https://registry.npm.taobao.org/csso/download/csso-3.5.1.tgz?cache=0&sync_timestamp=1606408777341&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcsso%2Fdownload%2Fcsso-3.5.1.tgz#7b9eb8be61628973c1b261e169d2f024008e758b" + integrity sha1-e564vmFiiXPBsmHhadLwJACOdYs= + dependencies: + css-tree "1.0.0-alpha.29" + +csso@^4.0.2: + version "4.2.0" + resolved "https://registry.npm.taobao.org/csso/download/csso-4.2.0.tgz?cache=0&sync_timestamp=1606408777341&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcsso%2Fdownload%2Fcsso-4.2.0.tgz#ea3a561346e8dc9f546d6febedd50187cf389529" + integrity sha1-6jpWE0bo3J9UbW/r7dUBh884lSk= + dependencies: + css-tree "^1.1.2" + +cssom@^0.4.1: + version "0.4.4" + resolved "https://registry.nlark.com/cssom/download/cssom-0.4.4.tgz#5a66cf93d2d0b661d80bf6a44fb65f5c2e4e0a10" + integrity sha1-WmbPk9LQtmHYC/akT7ZfXC5OChA= + +cssom@~0.3.6: + version "0.3.8" + resolved "https://registry.nlark.com/cssom/download/cssom-0.3.8.tgz#9f1276f5b2b463f2114d3f2c75250af8c1a36f4a" + integrity sha1-nxJ29bK0Y/IRTT8sdSUK+MGjb0o= + +cssstyle@^2.0.0: + version "2.3.0" + resolved "https://registry.npm.taobao.org/cssstyle/download/cssstyle-2.3.0.tgz#ff665a0ddbdc31864b09647f34163443d90b0852" + integrity sha1-/2ZaDdvcMYZLCWR/NBY0Q9kLCFI= + dependencies: + cssom "~0.3.6" + +csstype@^3.0.2: + version "3.0.9" + resolved "https://registry.nlark.com/csstype/download/csstype-3.0.9.tgz#6410af31b26bd0520933d02cbc64fce9ce3fbf0b" + integrity sha1-ZBCvMbJr0FIJM9AsvGT86c4/vws= + +cuint@^0.2.2: + version "0.2.2" + resolved "https://registry.nlark.com/cuint/download/cuint-0.2.2.tgz#408086d409550c2631155619e9fa7bcadc3b991b" + integrity sha1-QICG1AlVDCYxFVYZ6fp7ytw7mRs= + +currently-unhandled@^0.4.1: + version "0.4.1" + resolved "https://registry.npm.taobao.org/currently-unhandled/download/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea" + integrity sha1-mI3zP+qxke95mmE2nddsF635V+o= + dependencies: + array-find-index "^1.0.1" + +cyclist@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/cyclist/download/cyclist-1.0.1.tgz#596e9698fd0c80e12038c2b82d6eb1b35b6224d9" + integrity sha1-WW6WmP0MgOEgOMK4LW6xs1tiJNk= + +d@1, d@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/d/download/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" + integrity sha1-hpgJU3LVjb7jRv/Qxwk/mfj561o= + dependencies: + es5-ext "^0.10.50" + type "^1.0.1" + +dashdash@^1.12.0: + version "1.14.1" + resolved "https://registry.npm.taobao.org/dashdash/download/dashdash-1.14.1.tgz?cache=0&sync_timestamp=1601073454623&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fdashdash%2Fdownload%2Fdashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" + integrity sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA= + dependencies: + assert-plus "^1.0.0" + +data-urls@^1.1.0: + version "1.1.0" + resolved "https://registry.npmmirror.com/data-urls/download/data-urls-1.1.0.tgz?cache=0&sync_timestamp=1633539797628&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdata-urls%2Fdownload%2Fdata-urls-1.1.0.tgz#15ee0582baa5e22bb59c77140da8f9c76963bbfe" + integrity sha1-Fe4Fgrql4iu1nHcUDaj5x2lju/4= + dependencies: + abab "^2.0.0" + whatwg-mimetype "^2.2.0" + whatwg-url "^7.0.0" + +date-now@^0.1.4: + version "0.1.4" + resolved "https://registry.nlark.com/date-now/download/date-now-0.1.4.tgz#eaf439fd4d4848ad74e5cc7dbef200672b9e345b" + integrity sha1-6vQ5/U1ISK105cx9vvIAZyueNFs= + +dayjs@^1.10.7: + version "1.10.7" + resolved "https://registry.nlark.com/dayjs/download/dayjs-1.10.7.tgz#2cf5f91add28116748440866a0a1d26f3a6ce468" + integrity sha1-LPX5Gt0oEWdIRAhmoKHSbzps5Gg= + +debug@2.6.9, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.9: + version "2.6.9" + resolved "https://registry.npmmirror.com/debug/download/debug-2.6.9.tgz?cache=0&sync_timestamp=1636300872595&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdebug%2Fdownload%2Fdebug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" + integrity sha1-XRKFFd8TT/Mn6QpMk/Tgd6U2NB8= + dependencies: + ms "2.0.0" + +debug@4.1.1: + version "4.1.1" + resolved "https://registry.npmmirror.com/debug/download/debug-4.1.1.tgz?cache=0&sync_timestamp=1636300872595&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdebug%2Fdownload%2Fdebug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" + integrity sha1-O3ImAlUQnGtYnO4FDx1RYTlmR5E= + dependencies: + ms "^2.1.1" + +debug@=3.1.0, debug@~3.1.0: + version "3.1.0" + resolved "https://registry.npmmirror.com/debug/download/debug-3.1.0.tgz?cache=0&sync_timestamp=1636300872595&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdebug%2Fdownload%2Fdebug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" + integrity sha1-W7WgZyYotkFJVmuhaBnmFRjGcmE= + dependencies: + ms "2.0.0" + +debug@^3.0.0, debug@^3.1.1, debug@^3.2.5, debug@^3.2.6, debug@^3.2.7: + version "3.2.7" + resolved "https://registry.npmmirror.com/debug/download/debug-3.2.7.tgz?cache=0&sync_timestamp=1636300872595&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdebug%2Fdownload%2Fdebug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" + integrity sha1-clgLfpFF+zm2Z2+cXl+xALk0F5o= + dependencies: + ms "^2.1.1" + +debug@^4.0.1, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1: + version "4.3.2" + resolved "https://registry.npmmirror.com/debug/download/debug-4.3.2.tgz?cache=0&sync_timestamp=1636300872595&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdebug%2Fdownload%2Fdebug-4.3.2.tgz#f0a49c18ac8779e31d4a0c6029dfb76873c7428b" + integrity sha1-8KScGKyHeeMdSgxgKd+3aHPHQos= + dependencies: + ms "2.1.2" + +decamelize-keys@^1.0.0: + version "1.1.0" + resolved "https://registry.nlark.com/decamelize-keys/download/decamelize-keys-1.1.0.tgz#d171a87933252807eb3cb61dc1c1445d078df2d9" + integrity sha1-0XGoeTMlKAfrPLYdwcFEXQeN8tk= + dependencies: + decamelize "^1.1.0" + map-obj "^1.0.0" + +decamelize@^1.1.0, decamelize@^1.1.2, decamelize@^1.2.0: + version "1.2.0" + resolved "https://registry.npmmirror.com/decamelize/download/decamelize-1.2.0.tgz?cache=0&sync_timestamp=1633055728451&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdecamelize%2Fdownload%2Fdecamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" + integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= + +decode-uri-component@^0.2.0: + version "0.2.0" + resolved "https://registry.nlark.com/decode-uri-component/download/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" + integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= + +deep-diff@^0.3.5: + version "0.3.8" + resolved "https://registry.npm.taobao.org/deep-diff/download/deep-diff-0.3.8.tgz#c01de63efb0eec9798801d40c7e0dae25b582c84" + integrity sha1-wB3mPvsO7JeYgB1Ax+Da4ltYLIQ= + +deep-diff@^1.0.2: + version "1.0.2" + resolved "https://registry.npm.taobao.org/deep-diff/download/deep-diff-1.0.2.tgz#afd3d1f749115be965e89c63edc7abb1506b9c26" + integrity sha1-r9PR90kRW+ll6Jxj7cersVBrnCY= + +deep-equal@^1.0.1: + version "1.1.1" + resolved "https://registry.npm.taobao.org/deep-equal/download/deep-equal-1.1.1.tgz?cache=0&sync_timestamp=1606859714626&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fdeep-equal%2Fdownload%2Fdeep-equal-1.1.1.tgz#b5c98c942ceffaf7cb051e24e1434a25a2e6076a" + integrity sha1-tcmMlCzv+vfLBR4k4UNKJaLmB2o= + dependencies: + is-arguments "^1.0.4" + is-date-object "^1.0.1" + is-regex "^1.0.4" + object-is "^1.0.1" + object-keys "^1.1.1" + regexp.prototype.flags "^1.2.0" + +deep-is@~0.1.3: + version "0.1.4" + resolved "https://registry.nlark.com/deep-is/download/deep-is-0.1.4.tgz#a6f2dce612fadd2ef1f519b73551f17e85199831" + integrity sha1-pvLc5hL63S7x9Rm3NVHxfoUZmDE= + +deepmerge@^1.5.2: + version "1.5.2" + resolved "https://registry.npm.taobao.org/deepmerge/download/deepmerge-1.5.2.tgz#10499d868844cdad4fee0842df8c7f6f0c95a753" + integrity sha1-EEmdhohEza1P7ghC34x/bwyVp1M= + +default-gateway@^4.2.0: + version "4.2.0" + resolved "https://registry.npmmirror.com/default-gateway/download/default-gateway-4.2.0.tgz#167104c7500c2115f6dd69b0a536bb8ed720552b" + integrity sha1-FnEEx1AMIRX23WmwpTa7jtcgVSs= + dependencies: + execa "^1.0.0" + ip-regex "^2.1.0" + +defaults@^1.0.3: + version "1.0.3" + resolved "https://registry.npm.taobao.org/defaults/download/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d" + integrity sha1-xlYFHpgX2f8I7YgUd/P+QBnz730= + dependencies: + clone "^1.0.2" + +define-properties@^1.1.2, define-properties@^1.1.3: + version "1.1.3" + resolved "https://registry.nlark.com/define-properties/download/define-properties-1.1.3.tgz?cache=0&sync_timestamp=1618847174317&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdefine-properties%2Fdownload%2Fdefine-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" + integrity sha1-z4jabL7ib+bbcJT2HYcMvYTO6fE= + dependencies: + object-keys "^1.0.12" + +define-property@^0.2.5: + version "0.2.5" + resolved "https://registry.npm.taobao.org/define-property/download/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" + integrity sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY= + dependencies: + is-descriptor "^0.1.0" + +define-property@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/define-property/download/define-property-1.0.0.tgz#769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6" + integrity sha1-dp66rz9KY6rTr56NMEybvnm/sOY= + dependencies: + is-descriptor "^1.0.0" + +define-property@^2.0.2: + version "2.0.2" + resolved "https://registry.npm.taobao.org/define-property/download/define-property-2.0.2.tgz#d459689e8d654ba77e02a817f8710d702cb16e9d" + integrity sha1-1Flono1lS6d+AqgX+HENcCyxbp0= + dependencies: + is-descriptor "^1.0.2" + isobject "^3.0.1" + +del@^4.1.1: + version "4.1.1" + resolved "https://registry.npm.taobao.org/del/download/del-4.1.1.tgz?cache=0&sync_timestamp=1601076882347&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fdel%2Fdownload%2Fdel-4.1.1.tgz#9e8f117222ea44a31ff3a156c049b99052a9f0b4" + integrity sha1-no8RciLqRKMf86FWwEm5kFKp8LQ= + dependencies: + "@types/glob" "^7.1.1" + globby "^6.1.0" + is-path-cwd "^2.0.0" + is-path-in-cwd "^2.0.0" + p-map "^2.0.0" + pify "^4.0.1" + rimraf "^2.6.3" + +delayed-stream@~1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/delayed-stream/download/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" + integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= + +delegates@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/delegates/download/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" + integrity sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o= + +depd@~1.1.2: + version "1.1.2" + resolved "https://registry.nlark.com/depd/download/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9" + integrity sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak= + +des.js@^1.0.0: + version "1.0.1" + resolved "https://registry.npm.taobao.org/des.js/download/des.js-1.0.1.tgz#5382142e1bdc53f85d86d53e5f4aa7deb91e0843" + integrity sha1-U4IULhvcU/hdhtU+X0qn3rkeCEM= + dependencies: + inherits "^2.0.1" + minimalistic-assert "^1.0.0" + +destroy@~1.0.4: + version "1.0.4" + resolved "https://registry.nlark.com/destroy/download/destroy-1.0.4.tgz#978857442c44749e4206613e37946205826abd80" + integrity sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA= + +detect-node@^2.0.4: + version "2.1.0" + resolved "https://registry.nlark.com/detect-node/download/detect-node-2.1.0.tgz?cache=0&sync_timestamp=1621146954463&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdetect-node%2Fdownload%2Fdetect-node-2.1.0.tgz#c9c70775a49c3d03bc2c06d9a73be550f978f8b1" + integrity sha1-yccHdaScPQO8LAbZpzvlUPl4+LE= + +detect-port@1.3.0: + version "1.3.0" + resolved "https://registry.nlark.com/detect-port/download/detect-port-1.3.0.tgz#d9c40e9accadd4df5cac6a782aefd014d573d1f1" + integrity sha1-2cQOmsyt1N9crGp4Ku/QFNVz0fE= + dependencies: + address "^1.0.1" + debug "^2.6.0" + +diffie-hellman@^5.0.0: + version "5.0.3" + resolved "https://registry.nlark.com/diffie-hellman/download/diffie-hellman-5.0.3.tgz#40e8ee98f55a2149607146921c63e1ae5f3d2875" + integrity sha1-QOjumPVaIUlgcUaSHGPhrl89KHU= + dependencies: + bn.js "^4.1.0" + miller-rabin "^4.0.0" + randombytes "^2.0.0" + +dir-glob@2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/dir-glob/download/dir-glob-2.0.0.tgz#0b205d2b6aef98238ca286598a8204d29d0a0034" + integrity sha1-CyBdK2rvmCOMooZZioIE0p0KADQ= + dependencies: + arrify "^1.0.1" + path-type "^3.0.0" + +dir-glob@^2.0.0: + version "2.2.2" + resolved "https://registry.npm.taobao.org/dir-glob/download/dir-glob-2.2.2.tgz#fa09f0694153c8918b18ba0deafae94769fc50c4" + integrity sha1-+gnwaUFTyJGLGLoN6vrpR2n8UMQ= + dependencies: + path-type "^3.0.0" + +dir-glob@^3.0.1: + version "3.0.1" + resolved "https://registry.npm.taobao.org/dir-glob/download/dir-glob-3.0.1.tgz#56dbf73d992a4a93ba1584f4534063fd2e41717f" + integrity sha1-Vtv3PZkqSpO6FYT0U0Bj/S5BcX8= + dependencies: + path-type "^4.0.0" + +dns-equal@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/dns-equal/download/dns-equal-1.0.0.tgz#b39e7f1da6eb0a75ba9c17324b34753c47e0654d" + integrity sha1-s55/HabrCnW6nBcySzR1PEfgZU0= + +dns-packet@^1.3.1: + version "1.3.4" + resolved "https://registry.nlark.com/dns-packet/download/dns-packet-1.3.4.tgz#e3455065824a2507ba886c55a89963bb107dec6f" + integrity sha1-40VQZYJKJQe6iGxVqJljuxB97G8= + dependencies: + ip "^1.1.0" + safe-buffer "^5.0.1" + +dns-txt@^2.0.2: + version "2.0.2" + resolved "https://registry.nlark.com/dns-txt/download/dns-txt-2.0.2.tgz#b91d806f5d27188e4ab3e7d107d881a1cc4642b6" + integrity sha1-uR2Ab10nGI5Ks+fRB9iBocxGQrY= + dependencies: + buffer-indexof "^1.0.0" + +doctrine@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/doctrine/download/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" + integrity sha1-XNAfwQFiG0LEzX9dGmYkNxbT850= + dependencies: + esutils "^2.0.2" + +doctrine@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/doctrine/download/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" + integrity sha1-rd6+rXKmV023g2OdyHoSF3OXOWE= + dependencies: + esutils "^2.0.2" + +dom-converter@^0.2.0: + version "0.2.0" + resolved "https://registry.npm.taobao.org/dom-converter/download/dom-converter-0.2.0.tgz#6721a9daee2e293682955b6afe416771627bb768" + integrity sha1-ZyGp2u4uKTaClVtq/kFncWJ7t2g= + dependencies: + utila "~0.4" + +dom-helpers@^5.0.1: + version "5.2.1" + resolved "https://registry.nlark.com/dom-helpers/download/dom-helpers-5.2.1.tgz#d9400536b2bf8225ad98fe052e029451ac40e902" + integrity sha1-2UAFNrK/giWtmP4FLgKUUaxA6QI= + dependencies: + "@babel/runtime" "^7.8.7" + csstype "^3.0.2" + +dom-serializer@0: + version "0.2.2" + resolved "https://registry.nlark.com/dom-serializer/download/dom-serializer-0.2.2.tgz?cache=0&sync_timestamp=1621256830355&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdom-serializer%2Fdownload%2Fdom-serializer-0.2.2.tgz#1afb81f533717175d478655debc5e332d9f9bb51" + integrity sha1-GvuB9TNxcXXUeGVd68XjMtn5u1E= + dependencies: + domelementtype "^2.0.1" + entities "^2.0.0" + +dom-serializer@^1.0.1: + version "1.3.2" + resolved "https://registry.nlark.com/dom-serializer/download/dom-serializer-1.3.2.tgz?cache=0&sync_timestamp=1621256830355&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdom-serializer%2Fdownload%2Fdom-serializer-1.3.2.tgz#6206437d32ceefaec7161803230c7a20bc1b4d91" + integrity sha1-YgZDfTLO767HFhgDIwx6ILwbTZE= + dependencies: + domelementtype "^2.0.1" + domhandler "^4.2.0" + entities "^2.0.0" + +dom7@^3.0.0: + version "3.0.0" + resolved "https://registry.npmmirror.com/dom7/download/dom7-3.0.0.tgz#b861ce5d67a6becd7aaa3ad02942ff14b1240331" + integrity sha1-uGHOXWemvs16qjrQKUL/FLEkAzE= + dependencies: + ssr-window "^3.0.0-alpha.1" + +domain-browser@^1.1.1: + version "1.2.0" + resolved "https://registry.nlark.com/domain-browser/download/domain-browser-1.2.0.tgz?cache=0&sync_timestamp=1627591557212&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdomain-browser%2Fdownload%2Fdomain-browser-1.2.0.tgz#3d31f50191a6749dd1375a7f522e823d42e54eda" + integrity sha1-PTH1AZGmdJ3RN1p/Ui6CPULlTto= + +domelementtype@1, domelementtype@^1.3.1: + version "1.3.1" + resolved "https://registry.npm.taobao.org/domelementtype/download/domelementtype-1.3.1.tgz?cache=0&sync_timestamp=1617298545989&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fdomelementtype%2Fdownload%2Fdomelementtype-1.3.1.tgz#d048c44b37b0d10a7f2a3d5fee3f4333d790481f" + integrity sha1-0EjESzew0Qp/Kj1f7j9DM9eQSB8= + +domelementtype@^2.0.1, domelementtype@^2.2.0: + version "2.2.0" + resolved "https://registry.npm.taobao.org/domelementtype/download/domelementtype-2.2.0.tgz?cache=0&sync_timestamp=1617298545989&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fdomelementtype%2Fdownload%2Fdomelementtype-2.2.0.tgz#9a0b6c2782ed6a1c7323d42267183df9bd8b1d57" + integrity sha1-mgtsJ4LtahxzI9QiZxg9+b2LHVc= + +domexception@^1.0.1: + version "1.0.1" + resolved "https://registry.npmmirror.com/domexception/download/domexception-1.0.1.tgz?cache=0&sync_timestamp=1633538737274&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fdomexception%2Fdownload%2Fdomexception-1.0.1.tgz#937442644ca6a31261ef36e3ec677fe805582c90" + integrity sha1-k3RCZEymoxJh7zbj7Gd/6AVYLJA= + dependencies: + webidl-conversions "^4.0.2" + +domhandler@2.3: + version "2.3.0" + resolved "https://registry.nlark.com/domhandler/download/domhandler-2.3.0.tgz?cache=0&sync_timestamp=1630246778110&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdomhandler%2Fdownload%2Fdomhandler-2.3.0.tgz#2de59a0822d5027fabff6f032c2b25a2a8abe738" + integrity sha1-LeWaCCLVAn+r/28DLCsloqir5zg= + dependencies: + domelementtype "1" + +domhandler@^2.3.0: + version "2.4.2" + resolved "https://registry.nlark.com/domhandler/download/domhandler-2.4.2.tgz?cache=0&sync_timestamp=1630246778110&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdomhandler%2Fdownload%2Fdomhandler-2.4.2.tgz#8805097e933d65e85546f726d60f5eb88b44f803" + integrity sha1-iAUJfpM9ZehVRvcm1g9euItE+AM= + dependencies: + domelementtype "1" + +domhandler@^4.0.0, domhandler@^4.2.0: + version "4.2.2" + resolved "https://registry.nlark.com/domhandler/download/domhandler-4.2.2.tgz?cache=0&sync_timestamp=1630246778110&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdomhandler%2Fdownload%2Fdomhandler-4.2.2.tgz#e825d721d19a86b8c201a35264e226c678ee755f" + integrity sha1-6CXXIdGahrjCAaNSZOImxnjudV8= + dependencies: + domelementtype "^2.2.0" + +domutils@1.5: + version "1.5.1" + resolved "https://registry.nlark.com/domutils/download/domutils-1.5.1.tgz?cache=0&sync_timestamp=1630106606599&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdomutils%2Fdownload%2Fdomutils-1.5.1.tgz#dcd8488a26f563d61079e48c9f7b7e32373682cf" + integrity sha1-3NhIiib1Y9YQeeSMn3t+Mjc2gs8= + dependencies: + dom-serializer "0" + domelementtype "1" + +domutils@^1.5.1: + version "1.7.0" + resolved "https://registry.nlark.com/domutils/download/domutils-1.7.0.tgz?cache=0&sync_timestamp=1630106606599&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdomutils%2Fdownload%2Fdomutils-1.7.0.tgz#56ea341e834e06e6748af7a1cb25da67ea9f8c2a" + integrity sha1-Vuo0HoNOBuZ0ivehyyXaZ+qfjCo= + dependencies: + dom-serializer "0" + domelementtype "1" + +domutils@^2.5.2, domutils@^2.6.0: + version "2.8.0" + resolved "https://registry.nlark.com/domutils/download/domutils-2.8.0.tgz?cache=0&sync_timestamp=1630106606599&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fdomutils%2Fdownload%2Fdomutils-2.8.0.tgz#4437def5db6e2d1f5d6ee859bd95ca7d02048135" + integrity sha1-RDfe9dtuLR9dbuhZvZXKfQIEgTU= + dependencies: + dom-serializer "^1.0.1" + domelementtype "^2.2.0" + domhandler "^4.2.0" + +dot-prop@^5.2.0: + version "5.3.0" + resolved "https://registry.nlark.com/dot-prop/download/dot-prop-5.3.0.tgz#90ccce708cd9cd82cc4dc8c3ddd9abdd55b20e88" + integrity sha1-kMzOcIzZzYLMTcjD3dmr3VWyDog= + dependencies: + is-obj "^2.0.0" + +downloadjs@^1.4.7: + version "1.4.7" + resolved "https://registry.npm.taobao.org/downloadjs/download/downloadjs-1.4.7.tgz#f69f96f940e0d0553dac291139865a3cd0101e3c" + integrity sha1-9p+W+UDg0FU9rCkROYZaPNAQHjw= + +duplexer@^0.1.2: + version "0.1.2" + resolved "https://registry.nlark.com/duplexer/download/duplexer-0.1.2.tgz#3abe43aef3835f8ae077d136ddce0f276b0400e6" + integrity sha1-Or5DrvODX4rgd9E23c4PJ2sEAOY= + +duplexify@^3.4.2, duplexify@^3.6.0: + version "3.7.1" + resolved "https://registry.nlark.com/duplexify/download/duplexify-3.7.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fduplexify%2Fdownload%2Fduplexify-3.7.1.tgz#2a4df5317f6ccfd91f86d6fd25d8d8a103b88309" + integrity sha1-Kk31MX9sz9kfhtb9JdjYoQO4gwk= + dependencies: + end-of-stream "^1.0.0" + inherits "^2.0.1" + readable-stream "^2.0.0" + stream-shift "^1.0.0" + +ecc-jsbn@~0.1.1: + version "0.1.2" + resolved "https://registry.npm.taobao.org/ecc-jsbn/download/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" + integrity sha1-OoOpBOVDUyh4dMVkt1SThoSamMk= + dependencies: + jsbn "~0.1.0" + safer-buffer "^2.1.0" + +ee-first@1.1.1: + version "1.1.1" + resolved "https://registry.nlark.com/ee-first/download/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d" + integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0= + +electron-to-chromium@^1.3.47, electron-to-chromium@^1.3.886: + version "1.3.890" + resolved "https://registry.npmmirror.com/electron-to-chromium/download/electron-to-chromium-1.3.890.tgz?cache=0&sync_timestamp=1636167839637&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Felectron-to-chromium%2Fdownload%2Felectron-to-chromium-1.3.890.tgz#e7143b659f73dc4d0512d1ae4baeb0fb9e7bc835" + integrity sha1-5xQ7ZZ9z3E0FEtGuS66w+557yDU= + +electron-to-chromium@^1.3.896: + version "1.3.906" + resolved "https://registry.npmmirror.com/electron-to-chromium/download/electron-to-chromium-1.3.906.tgz#144e212691e35fa8c294431e2ecb51e4b03f7577" + integrity sha512-UjoECdcOYIVzWmrbtNnYpPrDuu+RtiO5W08Vdbid9ydGQMSdnqtJUtvOqQEAVQqpoXN9kSW9YnQufvzLQMYQOw== + +electron-to-chromium@^1.4.71: + version "1.4.75" + resolved "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.4.75.tgz#d1ad9bb46f2f1bf432118c2be21d27ffeae82fdd" + integrity sha512-LxgUNeu3BVU7sXaKjUDD9xivocQLxFtq6wgERrutdY/yIOps3ODOZExK1jg8DTEg4U8TUCb5MLGeWFOYuxjF3Q== + +elliptic@^6.5.3: + version "6.5.4" + resolved "https://registry.npm.taobao.org/elliptic/download/elliptic-6.5.4.tgz#da37cebd31e79a1367e941b592ed1fbebd58abbb" + integrity sha1-2jfOvTHnmhNn6UG1ku0fvr1Yq7s= + dependencies: + bn.js "^4.11.9" + brorand "^1.1.0" + hash.js "^1.0.0" + hmac-drbg "^1.0.1" + inherits "^2.0.4" + minimalistic-assert "^1.0.1" + minimalistic-crypto-utils "^1.0.1" + +emoji-regex@^7.0.1: + version "7.0.3" + resolved "https://registry.npmmirror.com/emoji-regex/download/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" + integrity sha1-kzoEBShgyF6DwSJHnEdIqOTHIVY= + +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.npmmirror.com/emoji-regex/download/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" + integrity sha1-6Bj9ac5cz8tARZT4QpY79TFkzDc= + +emojis-list@^2.0.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/emojis-list/download/emojis-list-2.1.0.tgz#4daa4d9db00f9819880c79fa457ae5b09a1fd389" + integrity sha1-TapNnbAPmBmIDHn6RXrlsJof04k= + +emojis-list@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/emojis-list/download/emojis-list-3.0.0.tgz#5570662046ad29e2e916e71aae260abdff4f6a78" + integrity sha1-VXBmIEatKeLpFucariYKvf9Pang= + +encodeurl@~1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/encodeurl/download/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" + integrity sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k= + +end-of-stream@^1.0.0, end-of-stream@^1.1.0: + version "1.4.4" + resolved "https://registry.nlark.com/end-of-stream/download/end-of-stream-1.4.4.tgz#5ae64a5f45057baf3626ec14da0ca5e4b2431eb0" + integrity sha1-WuZKX0UFe682JuwU2gyl5LJDHrA= + dependencies: + once "^1.4.0" + +enhanced-resolve@^4.1.0, enhanced-resolve@^4.5.0: + version "4.5.0" + resolved "https://registry.nlark.com/enhanced-resolve/download/enhanced-resolve-4.5.0.tgz?cache=0&sync_timestamp=1632130769099&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fenhanced-resolve%2Fdownload%2Fenhanced-resolve-4.5.0.tgz#2f3cfd84dbe3b487f18f2db2ef1e064a571ca5ec" + integrity sha1-Lzz9hNvjtIfxjy2y7x4GSlccpew= + dependencies: + graceful-fs "^4.1.2" + memory-fs "^0.5.0" + tapable "^1.0.0" + +entities@1.0: + version "1.0.0" + resolved "https://registry.nlark.com/entities/download/entities-1.0.0.tgz?cache=0&sync_timestamp=1628508189267&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fentities%2Fdownload%2Fentities-1.0.0.tgz#b2987aa3821347fcde642b24fdfc9e4fb712bf26" + integrity sha1-sph6o4ITR/zeZCsk/fyeT7cSvyY= + +entities@^1.1.1: + version "1.1.2" + resolved "https://registry.nlark.com/entities/download/entities-1.1.2.tgz?cache=0&sync_timestamp=1628508189267&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fentities%2Fdownload%2Fentities-1.1.2.tgz#bdfa735299664dfafd34529ed4f8522a275fea56" + integrity sha1-vfpzUplmTfr9NFKe1PhSKidf6lY= + +entities@^2.0.0: + version "2.2.0" + resolved "https://registry.nlark.com/entities/download/entities-2.2.0.tgz?cache=0&sync_timestamp=1628508189267&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fentities%2Fdownload%2Fentities-2.2.0.tgz#098dc90ebb83d8dffa089d55256b351d34c4da55" + integrity sha1-CY3JDruD2N/6CJ1VJWs1HTTE2lU= + +errno@^0.1.1, errno@^0.1.3, errno@~0.1.7: + version "0.1.8" + resolved "https://registry.nlark.com/errno/download/errno-0.1.8.tgz#8bb3e9c7d463be4976ff888f76b4809ebc2e811f" + integrity sha1-i7Ppx9Rjvkl2/4iPdrSAnrwugR8= + dependencies: + prr "~1.0.1" + +error-ex@^1.2.0, error-ex@^1.3.1: + version "1.3.2" + resolved "https://registry.nlark.com/error-ex/download/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" + integrity sha1-tKxAZIEH/c3PriQvQovqihTU8b8= + dependencies: + is-arrayish "^0.2.1" + +error-stack-parser@^2.0.6: + version "2.0.6" + resolved "https://registry.npm.taobao.org/error-stack-parser/download/error-stack-parser-2.0.6.tgz#5a99a707bd7a4c58a797902d48d82803ede6aad8" + integrity sha1-WpmnB716TFinl5AtSNgoA+3mqtg= + dependencies: + stackframe "^1.1.1" + +es-abstract@^1.19.0, es-abstract@^1.19.1: + version "1.19.1" + resolved "https://registry.npmmirror.com/es-abstract/download/es-abstract-1.19.1.tgz?cache=0&sync_timestamp=1633234313248&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fes-abstract%2Fdownload%2Fes-abstract-1.19.1.tgz#d4885796876916959de78edaa0df456627115ec3" + integrity sha1-1IhXlodpFpWd547aoN9FZicRXsM= + dependencies: + call-bind "^1.0.2" + es-to-primitive "^1.2.1" + function-bind "^1.1.1" + get-intrinsic "^1.1.1" + get-symbol-description "^1.0.0" + has "^1.0.3" + has-symbols "^1.0.2" + internal-slot "^1.0.3" + is-callable "^1.2.4" + is-negative-zero "^2.0.1" + is-regex "^1.1.4" + is-shared-array-buffer "^1.0.1" + is-string "^1.0.7" + is-weakref "^1.0.1" + object-inspect "^1.11.0" + object-keys "^1.1.1" + object.assign "^4.1.2" + string.prototype.trimend "^1.0.4" + string.prototype.trimstart "^1.0.4" + unbox-primitive "^1.0.1" + +es-to-primitive@^1.2.1: + version "1.2.1" + resolved "https://registry.nlark.com/es-to-primitive/download/es-to-primitive-1.2.1.tgz#e55cd4c9cdc188bcefb03b366c736323fc5c898a" + integrity sha1-5VzUyc3BiLzvsDs2bHNjI/xciYo= + dependencies: + is-callable "^1.1.4" + is-date-object "^1.0.1" + is-symbol "^1.0.2" + +es5-ext@^0.10.35, es5-ext@^0.10.50: + version "0.10.53" + resolved "https://registry.nlark.com/es5-ext/download/es5-ext-0.10.53.tgz#93c5a3acfdbef275220ad72644ad02ee18368de1" + integrity sha1-k8WjrP2+8nUiCtcmRK0C7hg2jeE= + dependencies: + es6-iterator "~2.0.3" + es6-symbol "~3.1.3" + next-tick "~1.0.0" + +es6-error@^4.1.1: + version "4.1.1" + resolved "https://registry.npm.taobao.org/es6-error/download/es6-error-4.1.1.tgz#9e3af407459deed47e9a91f9b885a84eb05c561d" + integrity sha1-njr0B0Wd7tR+mpH5uIWoTrBcVh0= + +es6-iterator@2.0.3, es6-iterator@~2.0.3: + version "2.0.3" + resolved "https://registry.nlark.com/es6-iterator/download/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" + integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= + dependencies: + d "1" + es5-ext "^0.10.35" + es6-symbol "^3.1.1" + +es6-symbol@^3.1.1, es6-symbol@~3.1.3: + version "3.1.3" + resolved "https://registry.npm.taobao.org/es6-symbol/download/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" + integrity sha1-utXTwbzawoJp9MszHkMceKxwXRg= + dependencies: + d "^1.0.1" + ext "^1.1.2" + +escalade@^3.1.1: + version "3.1.1" + resolved "https://registry.nlark.com/escalade/download/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" + integrity sha1-2M/ccACWXFoBdLSoLqpcBVJ0LkA= + +escape-html@~1.0.3: + version "1.0.3" + resolved "https://registry.npm.taobao.org/escape-html/download/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" + integrity sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg= + +escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.nlark.com/escape-string-regexp/download/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" + integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= + +escodegen@^1.11.1: + version "1.14.3" + resolved "https://registry.npm.taobao.org/escodegen/download/escodegen-1.14.3.tgz#4e7b81fba61581dc97582ed78cab7f0e8d63f503" + integrity sha1-TnuB+6YVgdyXWC7XjKt/Do1j9QM= + dependencies: + esprima "^4.0.1" + estraverse "^4.2.0" + esutils "^2.0.2" + optionator "^0.8.1" + optionalDependencies: + source-map "~0.6.1" + +eslint-config-taro@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/eslint-config-taro/download/eslint-config-taro-3.3.12.tgz?cache=0&sync_timestamp=1635491003087&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Feslint-config-taro%2Fdownload%2Feslint-config-taro-3.3.12.tgz#1ac52759bd60c205a44fe721971fe31d5da5b134" + integrity sha1-GsUnWb1gwgWkT+chlx/jHV2lsTQ= + dependencies: + "@typescript-eslint/parser" "^4.15.1" + babel-eslint "^10.0.0" + +eslint-import-resolver-node@^0.3.6: + version "0.3.6" + resolved "https://registry.nlark.com/eslint-import-resolver-node/download/eslint-import-resolver-node-0.3.6.tgz?cache=0&sync_timestamp=1629046536777&other_urls=https%3A%2F%2Fregistry.nlark.com%2Feslint-import-resolver-node%2Fdownload%2Feslint-import-resolver-node-0.3.6.tgz#4048b958395da89668252001dbd9eca6b83bacbd" + integrity sha1-QEi5WDldqJZoJSAB29nsprg7rL0= + dependencies: + debug "^3.2.7" + resolve "^1.20.0" + +eslint-module-utils@^2.7.0: + version "2.7.1" + resolved "https://registry.npmmirror.com/eslint-module-utils/download/eslint-module-utils-2.7.1.tgz?cache=0&sync_timestamp=1634151608499&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Feslint-module-utils%2Fdownload%2Feslint-module-utils-2.7.1.tgz#b435001c9f8dd4ab7f6d0efcae4b9696d4c24b7c" + integrity sha1-tDUAHJ+N1Kt/bQ78rkuWltTCS3w= + dependencies: + debug "^3.2.7" + find-up "^2.1.0" + pkg-dir "^2.0.0" + +eslint-plugin-import@^2.12.0: + version "2.25.2" + resolved "https://registry.npmmirror.com/eslint-plugin-import/download/eslint-plugin-import-2.25.2.tgz?cache=0&sync_timestamp=1634079230761&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Feslint-plugin-import%2Fdownload%2Feslint-plugin-import-2.25.2.tgz#b3b9160efddb702fc1636659e71ba1d10adbe9e9" + integrity sha1-s7kWDv3bcC/BY2ZZ5xuh0Qrb6ek= + dependencies: + array-includes "^3.1.4" + array.prototype.flat "^1.2.5" + debug "^2.6.9" + doctrine "^2.1.0" + eslint-import-resolver-node "^0.3.6" + eslint-module-utils "^2.7.0" + has "^1.0.3" + is-core-module "^2.7.0" + is-glob "^4.0.3" + minimatch "^3.0.4" + object.values "^1.1.5" + resolve "^1.20.0" + tsconfig-paths "^3.11.0" + +eslint-plugin-react-hooks@^4.2.0: + version "4.2.0" + resolved "https://registry.npmmirror.com/eslint-plugin-react-hooks/download/eslint-plugin-react-hooks-4.2.0.tgz#8c229c268d468956334c943bb45fc860280f5556" + integrity sha1-jCKcJo1GiVYzTJQ7tF/IYCgPVVY= + +eslint-plugin-react@^7.8.2: + version "7.26.1" + resolved "https://registry.npmmirror.com/eslint-plugin-react/download/eslint-plugin-react-7.26.1.tgz#41bcfe3e39e6a5ac040971c1af94437c80daa40e" + integrity sha1-Qbz+PjnmpawECXHBr5RDfIDapA4= + dependencies: + array-includes "^3.1.3" + array.prototype.flatmap "^1.2.4" + doctrine "^2.1.0" + estraverse "^5.2.0" + jsx-ast-utils "^2.4.1 || ^3.0.0" + minimatch "^3.0.4" + object.entries "^1.1.4" + object.fromentries "^2.0.4" + object.hasown "^1.0.0" + object.values "^1.1.4" + prop-types "^15.7.2" + resolve "^2.0.0-next.3" + semver "^6.3.0" + string.prototype.matchall "^4.0.5" + +eslint-scope@^4.0.3: + version "4.0.3" + resolved "https://registry.nlark.com/eslint-scope/download/eslint-scope-4.0.3.tgz#ca03833310f6889a3264781aa82e63eb9cfe7848" + integrity sha1-ygODMxD2iJoyZHgaqC5j65z+eEg= + dependencies: + esrecurse "^4.1.0" + estraverse "^4.1.1" + +eslint-scope@^5.0.0, eslint-scope@^5.1.1: + version "5.1.1" + resolved "https://registry.nlark.com/eslint-scope/download/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" + integrity sha1-54blmmbLkrP2wfsNUIqrF0hI9Iw= + dependencies: + esrecurse "^4.3.0" + estraverse "^4.1.1" + +eslint-utils@^1.4.3: + version "1.4.3" + resolved "https://registry.nlark.com/eslint-utils/download/eslint-utils-1.4.3.tgz#74fec7c54d0776b6f67e0251040b5806564e981f" + integrity sha1-dP7HxU0Hdrb2fgJRBAtYBlZOmB8= + dependencies: + eslint-visitor-keys "^1.1.0" + +eslint-utils@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/eslint-utils/download/eslint-utils-3.0.0.tgz#8aebaface7345bb33559db0a1f13a1d2d48c3672" + integrity sha1-iuuvrOc0W7M1WdsKHxOh0tSMNnI= + dependencies: + eslint-visitor-keys "^2.0.0" + +eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0: + version "1.3.0" + resolved "https://registry.nlark.com/eslint-visitor-keys/download/eslint-visitor-keys-1.3.0.tgz#30ebd1ef7c2fdff01c3a4f151044af25fab0523e" + integrity sha1-MOvR73wv3/AcOk8VEESvJfqwUj4= + +eslint-visitor-keys@^2.0.0: + version "2.1.0" + resolved "https://registry.nlark.com/eslint-visitor-keys/download/eslint-visitor-keys-2.1.0.tgz#f65328259305927392c938ed44eb0a5c9b2bd303" + integrity sha1-9lMoJZMFknOSyTjtROsKXJsr0wM= + +eslint@^6.8.0: + version "6.8.0" + resolved "https://registry.npmmirror.com/eslint/download/eslint-6.8.0.tgz?cache=0&sync_timestamp=1636156099337&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Feslint%2Fdownload%2Feslint-6.8.0.tgz#62262d6729739f9275723824302fb227c8c93ffb" + integrity sha1-YiYtZylzn5J1cjgkMC+yJ8jJP/s= + dependencies: + "@babel/code-frame" "^7.0.0" + ajv "^6.10.0" + chalk "^2.1.0" + cross-spawn "^6.0.5" + debug "^4.0.1" + doctrine "^3.0.0" + eslint-scope "^5.0.0" + eslint-utils "^1.4.3" + eslint-visitor-keys "^1.1.0" + espree "^6.1.2" + esquery "^1.0.1" + esutils "^2.0.2" + file-entry-cache "^5.0.1" + functional-red-black-tree "^1.0.1" + glob-parent "^5.0.0" + globals "^12.1.0" + ignore "^4.0.6" + import-fresh "^3.0.0" + imurmurhash "^0.1.4" + inquirer "^7.0.0" + is-glob "^4.0.0" + js-yaml "^3.13.1" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.3.0" + lodash "^4.17.14" + minimatch "^3.0.4" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + optionator "^0.8.3" + progress "^2.0.0" + regexpp "^2.0.1" + semver "^6.1.2" + strip-ansi "^5.2.0" + strip-json-comments "^3.0.1" + table "^5.2.3" + text-table "^0.2.0" + v8-compile-cache "^2.0.3" + +espree@^6.1.2: + version "6.2.1" + resolved "https://registry.nlark.com/espree/download/espree-6.2.1.tgz?cache=0&sync_timestamp=1631307190960&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fespree%2Fdownload%2Fespree-6.2.1.tgz#77fc72e1fd744a2052c20f38a5b575832e82734a" + integrity sha1-d/xy4f10SiBSwg84pbV1gy6Cc0o= + dependencies: + acorn "^7.1.1" + acorn-jsx "^5.2.0" + eslint-visitor-keys "^1.1.0" + +esprima@^4.0.0, esprima@^4.0.1: + version "4.0.1" + resolved "https://registry.nlark.com/esprima/download/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" + integrity sha1-E7BM2z5sXRnfkatph6hpVhmwqnE= + +esquery@^1.0.1: + version "1.4.0" + resolved "https://registry.nlark.com/esquery/download/esquery-1.4.0.tgz#2148ffc38b82e8c7057dfed48425b3e61f0f24a5" + integrity sha1-IUj/w4uC6McFff7UhCWz5h8PJKU= + dependencies: + estraverse "^5.1.0" + +esrecurse@^4.1.0, esrecurse@^4.3.0: + version "4.3.0" + resolved "https://registry.nlark.com/esrecurse/download/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" + integrity sha1-eteWTWeauyi+5yzsY3WLHF0smSE= + dependencies: + estraverse "^5.2.0" + +estraverse@^4.1.1, estraverse@^4.2.0: + version "4.3.0" + resolved "https://registry.npmmirror.com/estraverse/download/estraverse-4.3.0.tgz?cache=0&sync_timestamp=1635237706876&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Festraverse%2Fdownload%2Festraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" + integrity sha1-OYrT88WiSUi+dyXoPRGn3ijNvR0= + +estraverse@^5.1.0, estraverse@^5.2.0: + version "5.3.0" + resolved "https://registry.npmmirror.com/estraverse/download/estraverse-5.3.0.tgz?cache=0&sync_timestamp=1635237706876&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Festraverse%2Fdownload%2Festraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" + integrity sha1-LupSkHAvJquP5TcDcP+GyWXSESM= + +estree-walker@^2.0.1: + version "2.0.2" + resolved "https://registry.npmmirror.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" + integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== + +esutils@^2.0.2: + version "2.0.3" + resolved "https://registry.nlark.com/esutils/download/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" + integrity sha1-dNLrTeC42hKTcRkQ1Qd1ubcQ72Q= + +etag@~1.8.1: + version "1.8.1" + resolved "https://registry.nlark.com/etag/download/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" + integrity sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc= + +eval5@^1.4.7: + version "1.4.7" + resolved "https://registry.npmmirror.com/eval5/download/eval5-1.4.7.tgz#cccc486d5e97dd68078663238fce4fe086c550c6" + integrity sha512-GtNl5TyxeIE1VkZ8p4vgzeLkdh7UEn9qzLnSIh/aXKYiJc31i1tNGB0CZhPaXReIZIE59xTV39IsAdWY7P93UA== + dependencies: + "@babel/runtime" "^7.8.4" + "@types/acorn" "^4.0.5" + "@types/estree" "0.0.41" + acorn "^7.1.0" + +eventemitter3@^4.0.0: + version "4.0.7" + resolved "https://registry.nlark.com/eventemitter3/download/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f" + integrity sha1-Lem2j2Uo1WRO9cWVJqG0oHMGFp8= + +events@^3.0.0: + version "3.3.0" + resolved "https://registry.nlark.com/events/download/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" + integrity sha1-Mala0Kkk4tLEGagTrrLE6HjqdAA= + +eventsource@^1.0.7: + version "1.1.0" + resolved "https://registry.npm.taobao.org/eventsource/download/eventsource-1.1.0.tgz?cache=0&sync_timestamp=1616041716084&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Feventsource%2Fdownload%2Feventsource-1.1.0.tgz#00e8ca7c92109e94b0ddf32dac677d841028cfaf" + integrity sha1-AOjKfJIQnpSw3fMtrGd9hBAoz68= + dependencies: + original "^1.0.0" + +evp_bytestokey@^1.0.0, evp_bytestokey@^1.0.3: + version "1.0.3" + resolved "https://registry.nlark.com/evp_bytestokey/download/evp_bytestokey-1.0.3.tgz#7fcbdb198dc71959432efe13842684e0525acb02" + integrity sha1-f8vbGY3HGVlDLv4ThCaE4FJaywI= + dependencies: + md5.js "^1.3.4" + safe-buffer "^5.1.1" + +execa@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/execa/download/execa-1.0.0.tgz?cache=0&sync_timestamp=1622825396605&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fexeca%2Fdownload%2Fexeca-1.0.0.tgz#c6236a5bb4df6d6f15e88e7f017798216749ddd8" + integrity sha1-xiNqW7TfbW8V6I5/AXeYIWdJ3dg= + dependencies: + cross-spawn "^6.0.0" + get-stream "^4.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" + +execall@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/execall/download/execall-1.0.0.tgz?cache=0&sync_timestamp=1617892727559&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fexecall%2Fdownload%2Fexecall-1.0.0.tgz#73d0904e395b3cab0658b08d09ec25307f29bb73" + integrity sha1-c9CQTjlbPKsGWLCNCewlMH8pu3M= + dependencies: + clone-regexp "^1.0.0" + +exit@0.1.2, exit@0.1.x: + version "0.1.2" + resolved "https://registry.nlark.com/exit/download/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" + integrity sha1-BjJjj42HfMghB9MKD/8aF8uhzQw= + +expand-brackets@^0.1.4: + version "0.1.5" + resolved "https://registry.npm.taobao.org/expand-brackets/download/expand-brackets-0.1.5.tgz#df07284e342a807cd733ac5af72411e581d1177b" + integrity sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s= + dependencies: + is-posix-bracket "^0.1.0" + +expand-brackets@^2.1.4: + version "2.1.4" + resolved "https://registry.npm.taobao.org/expand-brackets/download/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" + integrity sha1-t3c14xXOMPa27/D4OwQVGiJEliI= + dependencies: + debug "^2.3.3" + define-property "^0.2.5" + extend-shallow "^2.0.1" + posix-character-classes "^0.1.0" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.1" + +expand-range@^1.8.1: + version "1.8.2" + resolved "https://registry.nlark.com/expand-range/download/expand-range-1.8.2.tgz#a299effd335fe2721ebae8e257ec79644fc85337" + integrity sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc= + dependencies: + fill-range "^2.1.0" + +expr-parser@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/expr-parser/download/expr-parser-1.0.0.tgz#b85be870efce3c764977578d4a505795233f9022" + integrity sha1-uFvocO/OPHZJd1eNSlBXlSM/kCI= + +express@^4.17.1: + version "4.17.1" + resolved "https://registry.nlark.com/express/download/express-4.17.1.tgz?cache=0&sync_timestamp=1618847120573&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fexpress%2Fdownload%2Fexpress-4.17.1.tgz#4491fc38605cf51f8629d39c2b5d026f98a4c134" + integrity sha1-RJH8OGBc9R+GKdOcK10Cb5ikwTQ= + dependencies: + accepts "~1.3.7" + array-flatten "1.1.1" + body-parser "1.19.0" + content-disposition "0.5.3" + content-type "~1.0.4" + cookie "0.4.0" + cookie-signature "1.0.6" + debug "2.6.9" + depd "~1.1.2" + encodeurl "~1.0.2" + escape-html "~1.0.3" + etag "~1.8.1" + finalhandler "~1.1.2" + fresh "0.5.2" + merge-descriptors "1.0.1" + methods "~1.1.2" + on-finished "~2.3.0" + parseurl "~1.3.3" + path-to-regexp "0.1.7" + proxy-addr "~2.0.5" + qs "6.7.0" + range-parser "~1.2.1" + safe-buffer "5.1.2" + send "0.17.1" + serve-static "1.14.1" + setprototypeof "1.1.1" + statuses "~1.5.0" + type-is "~1.6.18" + utils-merge "1.0.1" + vary "~1.1.2" + +ext@^1.1.2: + version "1.6.0" + resolved "https://registry.npmmirror.com/ext/download/ext-1.6.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fext%2Fdownload%2Fext-1.6.0.tgz#3871d50641e874cc172e2b53f919842d19db4c52" + integrity sha1-OHHVBkHodMwXLitT+RmELRnbTFI= + dependencies: + type "^2.5.0" + +extend-shallow@^2.0.1: + version "2.0.1" + resolved "https://registry.nlark.com/extend-shallow/download/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" + integrity sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8= + dependencies: + is-extendable "^0.1.0" + +extend-shallow@^3.0.0, extend-shallow@^3.0.2: + version "3.0.2" + resolved "https://registry.nlark.com/extend-shallow/download/extend-shallow-3.0.2.tgz#26a71aaf073b39fb2127172746131c2704028db8" + integrity sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg= + dependencies: + assign-symbols "^1.0.0" + is-extendable "^1.0.1" + +extend@^3.0.0, extend@~3.0.2: + version "3.0.2" + resolved "https://registry.nlark.com/extend/download/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" + integrity sha1-+LETa0Bx+9jrFAr/hYsQGewpFfo= + +external-editor@^3.0.3: + version "3.1.0" + resolved "https://registry.nlark.com/external-editor/download/external-editor-3.1.0.tgz#cb03f740befae03ea4d283caed2741a83f335495" + integrity sha1-ywP3QL764D6k0oPK7SdBqD8zVJU= + dependencies: + chardet "^0.7.0" + iconv-lite "^0.4.24" + tmp "^0.0.33" + +extglob@^0.3.1: + version "0.3.2" + resolved "https://registry.nlark.com/extglob/download/extglob-0.3.2.tgz#2e18ff3d2f49ab2765cec9023f011daa8d8349a1" + integrity sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE= + dependencies: + is-extglob "^1.0.0" + +extglob@^2.0.4: + version "2.0.4" + resolved "https://registry.nlark.com/extglob/download/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" + integrity sha1-rQD+TcYSqSMuhxhxHcXLWrAoVUM= + dependencies: + array-unique "^0.3.2" + define-property "^1.0.0" + expand-brackets "^2.1.4" + extend-shallow "^2.0.1" + fragment-cache "^0.2.1" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.1" + +extsprintf@1.3.0: + version "1.3.0" + resolved "https://registry.npmmirror.com/extsprintf/download/extsprintf-1.3.0.tgz?cache=0&sync_timestamp=1635889740043&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fextsprintf%2Fdownload%2Fextsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" + integrity sha1-lpGEQOMEGnpBT4xS48V06zw+HgU= + +extsprintf@^1.2.0: + version "1.4.1" + resolved "https://registry.npmmirror.com/extsprintf/download/extsprintf-1.4.1.tgz?cache=0&sync_timestamp=1635889740043&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fextsprintf%2Fdownload%2Fextsprintf-1.4.1.tgz#8d172c064867f235c0c84a596806d279bf4bcc07" + integrity sha1-jRcsBkhn8jXAyEpZaAbSeb9LzAc= + +fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: + version "3.1.3" + resolved "https://registry.npm.taobao.org/fast-deep-equal/download/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" + integrity sha1-On1WtVnWy8PrUSMlJE5hmmXGxSU= + +fast-glob@^2.0.2: + version "2.2.7" + resolved "https://registry.nlark.com/fast-glob/download/fast-glob-2.2.7.tgz#6953857c3afa475fff92ee6015d52da70a4cd39d" + integrity sha1-aVOFfDr6R1//ku5gFdUtpwpM050= + dependencies: + "@mrmlnc/readdir-enhanced" "^2.2.1" + "@nodelib/fs.stat" "^1.1.2" + glob-parent "^3.1.0" + is-glob "^4.0.0" + merge2 "^1.2.3" + micromatch "^3.1.10" + +fast-glob@^3.1.1: + version "3.2.7" + resolved "https://registry.nlark.com/fast-glob/download/fast-glob-3.2.7.tgz#fd6cb7a2d7e9aa7a7846111e85a196d6b2f766a1" + integrity sha1-/Wy3otfpqnp4RhEehaGW1rL3ZqE= + dependencies: + "@nodelib/fs.stat" "^2.0.2" + "@nodelib/fs.walk" "^1.2.3" + glob-parent "^5.1.2" + merge2 "^1.3.0" + micromatch "^4.0.4" + +fast-json-stable-stringify@^2.0.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/fast-json-stable-stringify/download/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" + integrity sha1-h0v2nG9ATCtdmcSBNBOZ/VWJJjM= + +fast-levenshtein@~2.0.6: + version "2.0.6" + resolved "https://registry.nlark.com/fast-levenshtein/download/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" + integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= + +fast-xml-parser@^3.21.1: + version "3.21.1" + resolved "https://registry.npmmirror.com/fast-xml-parser/download/fast-xml-parser-3.21.1.tgz?cache=0&sync_timestamp=1635657386471&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ffast-xml-parser%2Fdownload%2Ffast-xml-parser-3.21.1.tgz#152a1d51d445380f7046b304672dd55d15c9e736" + integrity sha1-FSodUdRFOA9wRrMEZy3VXRXJ5zY= + dependencies: + strnum "^1.0.4" + +fastq@^1.6.0: + version "1.13.0" + resolved "https://registry.nlark.com/fastq/download/fastq-1.13.0.tgz#616760f88a7526bdfc596b7cab8c18938c36b98c" + integrity sha1-YWdg+Ip1Jr38WWt8q4wYk4w2uYw= + dependencies: + reusify "^1.0.4" + +faye-websocket@^0.10.0: + version "0.10.0" + resolved "https://registry.nlark.com/faye-websocket/download/faye-websocket-0.10.0.tgz#4e492f8d04dfb6f89003507f6edbf2d501e7c6f4" + integrity sha1-TkkvjQTftviQA1B/btvy1QHnxvQ= + dependencies: + websocket-driver ">=0.5.1" + +faye-websocket@~0.11.1: + version "0.11.4" + resolved "https://registry.nlark.com/faye-websocket/download/faye-websocket-0.11.4.tgz#7f0d9275cfdd86a1c963dc8b65fcc451edcbb1da" + integrity sha1-fw2Sdc/dhqHJY9yLZfzEUe3Lsdo= + dependencies: + websocket-driver ">=0.5.1" + +fd-slicer@~1.1.0: + version "1.1.0" + resolved "https://registry.npm.taobao.org/fd-slicer/download/fd-slicer-1.1.0.tgz#25c7c89cb1f9077f8891bbe61d8f390eae256f1e" + integrity sha1-JcfInLH5B3+IkbvmHY85Dq4lbx4= + dependencies: + pend "~1.2.0" + +figgy-pudding@^3.5.1: + version "3.5.2" + resolved "https://registry.nlark.com/figgy-pudding/download/figgy-pudding-3.5.2.tgz#b4eee8148abb01dcf1d1ac34367d59e12fa61d6e" + integrity sha1-tO7oFIq7Adzx0aw0Nn1Z4S+mHW4= + +figures@^3.0.0: + version "3.2.0" + resolved "https://registry.nlark.com/figures/download/figures-3.2.0.tgz?cache=0&sync_timestamp=1625254307578&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ffigures%2Fdownload%2Ffigures-3.2.0.tgz#625c18bd293c604dc4a8ddb2febf0c88341746af" + integrity sha1-YlwYvSk8YE3EqN2y/r8MiDQXRq8= + dependencies: + escape-string-regexp "^1.0.5" + +file-entry-cache@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/file-entry-cache/download/file-entry-cache-2.0.0.tgz?cache=0&sync_timestamp=1613794357372&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Ffile-entry-cache%2Fdownload%2Ffile-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" + integrity sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E= + dependencies: + flat-cache "^1.2.1" + object-assign "^4.0.1" + +file-entry-cache@^5.0.1: + version "5.0.1" + resolved "https://registry.npm.taobao.org/file-entry-cache/download/file-entry-cache-5.0.1.tgz?cache=0&sync_timestamp=1613794357372&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Ffile-entry-cache%2Fdownload%2Ffile-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c" + integrity sha1-yg9u+m3T1WEzP7FFFQZcL6/fQ5w= + dependencies: + flat-cache "^2.0.1" + +file-loader@^6.0.0: + version "6.2.0" + resolved "https://registry.nlark.com/file-loader/download/file-loader-6.2.0.tgz#baef7cf8e1840df325e4390b4484879480eebe4d" + integrity sha1-uu98+OGEDfMl5DkLRISHlIDuvk0= + dependencies: + loader-utils "^2.0.0" + schema-utils "^3.0.0" + +file-uri-to-path@1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/file-uri-to-path/download/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" + integrity sha1-VTp7hEb/b2hDWcRF8eN6BdrMM90= + +filename-regex@^2.0.0: + version "2.0.1" + resolved "https://registry.npm.taobao.org/filename-regex/download/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26" + integrity sha1-wcS5vuPglyXdsQa3XB4wH+LxiyY= + +fill-range@^2.1.0: + version "2.2.4" + resolved "https://registry.nlark.com/fill-range/download/fill-range-2.2.4.tgz#eb1e773abb056dcd8df2bfdf6af59b8b3a936565" + integrity sha1-6x53OrsFbc2N8r/favWbizqTZWU= + dependencies: + is-number "^2.1.0" + isobject "^2.0.0" + randomatic "^3.0.0" + repeat-element "^1.1.2" + repeat-string "^1.5.2" + +fill-range@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/fill-range/download/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" + integrity sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc= + dependencies: + extend-shallow "^2.0.1" + is-number "^3.0.0" + repeat-string "^1.6.1" + to-regex-range "^2.1.0" + +fill-range@^7.0.1: + version "7.0.1" + resolved "https://registry.nlark.com/fill-range/download/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" + integrity sha1-GRmmp8df44ssfHflGYU12prN2kA= + dependencies: + to-regex-range "^5.0.1" + +filter-obj@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/filter-obj/download/filter-obj-1.1.0.tgz?cache=0&sync_timestamp=1630004180503&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ffilter-obj%2Fdownload%2Ffilter-obj-1.1.0.tgz#9b311112bc6c6127a16e016c6c5d7f19e0805c5b" + integrity sha1-mzERErxsYSehbgFsbF1/GeCAXFs= + +finalhandler@~1.1.2: + version "1.1.2" + resolved "https://registry.nlark.com/finalhandler/download/finalhandler-1.1.2.tgz#b7e7d000ffd11938d0fdb053506f6ebabe9f587d" + integrity sha1-t+fQAP/RGTjQ/bBTUG9uur6fWH0= + dependencies: + debug "2.6.9" + encodeurl "~1.0.2" + escape-html "~1.0.3" + on-finished "~2.3.0" + parseurl "~1.3.3" + statuses "~1.5.0" + unpipe "~1.0.0" + +find-cache-dir@^2.0.0, find-cache-dir@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/find-cache-dir/download/find-cache-dir-2.1.0.tgz?cache=0&sync_timestamp=1630260009898&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ffind-cache-dir%2Fdownload%2Ffind-cache-dir-2.1.0.tgz#8d0f94cd13fe43c6c7c261a0d86115ca918c05f7" + integrity sha1-jQ+UzRP+Q8bHwmGg2GEVypGMBfc= + dependencies: + commondir "^1.0.1" + make-dir "^2.0.0" + pkg-dir "^3.0.0" + +find-cache-dir@^3.3.1: + version "3.3.2" + resolved "https://registry.nlark.com/find-cache-dir/download/find-cache-dir-3.3.2.tgz?cache=0&sync_timestamp=1630260009898&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ffind-cache-dir%2Fdownload%2Ffind-cache-dir-3.3.2.tgz#b30c5b6eff0730731aea9bbd9dbecbd80256d64b" + integrity sha1-swxbbv8HMHMa6pu9nb7L2AJW1ks= + dependencies: + commondir "^1.0.1" + make-dir "^3.0.2" + pkg-dir "^4.1.0" + +find-up@^1.0.0: + version "1.1.2" + resolved "https://registry.npmmirror.com/find-up/download/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" + integrity sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8= + dependencies: + path-exists "^2.0.0" + pinkie-promise "^2.0.0" + +find-up@^2.0.0, find-up@^2.1.0: + version "2.1.0" + resolved "https://registry.npmmirror.com/find-up/download/find-up-2.1.0.tgz#45d1b7e506c717ddd482775a2b77920a3c0c57a7" + integrity sha1-RdG35QbHF93UgndaK3eSCjwMV6c= + dependencies: + locate-path "^2.0.0" + +find-up@^3.0.0: + version "3.0.0" + resolved "https://registry.npmmirror.com/find-up/download/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" + integrity sha1-SRafHXmTQwZG2mHsxa41XCHJe3M= + dependencies: + locate-path "^3.0.0" + +find-up@^4.0.0: + version "4.1.0" + resolved "https://registry.npmmirror.com/find-up/download/find-up-4.1.0.tgz#97afe7d6cdc0bc5928584b7c8d7b16e8a9aa5d19" + integrity sha1-l6/n1s3AvFkoWEt8jXsW6KmqXRk= + dependencies: + locate-path "^5.0.0" + path-exists "^4.0.0" + +find-yarn-workspace-root@1.2.1: + version "1.2.1" + resolved "https://registry.npm.taobao.org/find-yarn-workspace-root/download/find-yarn-workspace-root-1.2.1.tgz#40eb8e6e7c2502ddfaa2577c176f221422f860db" + integrity sha1-QOuObnwlAt36old8F28iFCL4YNs= + dependencies: + fs-extra "^4.0.3" + micromatch "^3.1.4" + +find-yarn-workspace-root@2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/find-yarn-workspace-root/download/find-yarn-workspace-root-2.0.0.tgz#f47fb8d239c900eb78179aa81b66673eac88f7bd" + integrity sha1-9H+40jnJAOt4F5qoG2ZnPqyI970= + dependencies: + micromatch "^4.0.2" + +flat-cache@^1.2.1: + version "1.3.4" + resolved "https://registry.nlark.com/flat-cache/download/flat-cache-1.3.4.tgz#2c2ef77525cc2929007dfffa1dd314aa9c9dee6f" + integrity sha1-LC73dSXMKSkAff/6HdMUqpyd7m8= + dependencies: + circular-json "^0.3.1" + graceful-fs "^4.1.2" + rimraf "~2.6.2" + write "^0.2.1" + +flat-cache@^2.0.1: + version "2.0.1" + resolved "https://registry.nlark.com/flat-cache/download/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0" + integrity sha1-XSltbwS9pEpGMKMBQTvbwuwIXsA= + dependencies: + flatted "^2.0.0" + rimraf "2.6.3" + write "1.0.3" + +flatted@^2.0.0: + version "2.0.2" + resolved "https://registry.nlark.com/flatted/download/flatted-2.0.2.tgz?cache=0&sync_timestamp=1627541315228&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fflatted%2Fdownload%2Fflatted-2.0.2.tgz#4575b21e2bcee7434aa9be662f4b7b5f9c2b5138" + integrity sha1-RXWyHivO50NKqb5mL0t7X5wrUTg= + +flush-write-stream@^1.0.0: + version "1.1.1" + resolved "https://registry.npm.taobao.org/flush-write-stream/download/flush-write-stream-1.1.1.tgz#8dd7d873a1babc207d94ead0c2e0e44276ebf2e8" + integrity sha1-jdfYc6G6vCB9lOrQwuDkQnbr8ug= + dependencies: + inherits "^2.0.3" + readable-stream "^2.3.6" + +follow-redirects@1.5.10: + version "1.5.10" + resolved "https://registry.npmmirror.com/follow-redirects/download/follow-redirects-1.5.10.tgz?cache=0&sync_timestamp=1635857764332&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ffollow-redirects%2Fdownload%2Ffollow-redirects-1.5.10.tgz#7b7a9f9aea2fdff36786a94ff643ed07f4ff5e2a" + integrity sha1-e3qfmuov3/NnhqlP9kPtB/T/Xio= + dependencies: + debug "=3.1.0" + +follow-redirects@^1.0.0: + version "1.14.5" + resolved "https://registry.npmmirror.com/follow-redirects/download/follow-redirects-1.14.5.tgz?cache=0&sync_timestamp=1635857764332&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ffollow-redirects%2Fdownload%2Ffollow-redirects-1.14.5.tgz#f09a5848981d3c772b5392309778523f8d85c381" + integrity sha1-8JpYSJgdPHcrU5Iwl3hSP42Fw4E= + +for-in@^1.0.1, for-in@^1.0.2: + version "1.0.2" + resolved "https://registry.npm.taobao.org/for-in/download/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" + integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= + +for-own@^0.1.4: + version "0.1.5" + resolved "https://registry.nlark.com/for-own/download/for-own-0.1.5.tgz#5265c681a4f294dabbf17c9509b6763aa84510ce" + integrity sha1-UmXGgaTylNq78XyVCbZ2OqhFEM4= + dependencies: + for-in "^1.0.1" + +forever-agent@~0.6.1: + version "0.6.1" + resolved "https://registry.npm.taobao.org/forever-agent/download/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" + integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE= + +form-data@~2.3.2: + version "2.3.3" + resolved "https://registry.npm.taobao.org/form-data/download/form-data-2.3.3.tgz#dcce52c05f644f298c6a7ab936bd724ceffbf3a6" + integrity sha1-3M5SwF9kTymManq5Nr1yTO/786Y= + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.6" + mime-types "^2.1.12" + +forwarded@0.2.0: + version "0.2.0" + resolved "https://registry.nlark.com/forwarded/download/forwarded-0.2.0.tgz?cache=0&sync_timestamp=1622503408398&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fforwarded%2Fdownload%2Fforwarded-0.2.0.tgz#2269936428aad4c15c7ebe9779a84bf0b2a81811" + integrity sha1-ImmTZCiq1MFcfr6XeahL8LKoGBE= + +fragment-cache@^0.2.1: + version "0.2.1" + resolved "https://registry.nlark.com/fragment-cache/download/fragment-cache-0.2.1.tgz#4290fad27f13e89be7f33799c6bc5a0abfff0d19" + integrity sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk= + dependencies: + map-cache "^0.2.2" + +fresh@0.5.2: + version "0.5.2" + resolved "https://registry.npm.taobao.org/fresh/download/fresh-0.5.2.tgz#3d8cadd90d976569fa835ab1f8e4b23a105605a7" + integrity sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac= + +from2@^2.1.0: + version "2.3.0" + resolved "https://registry.npm.taobao.org/from2/download/from2-2.3.0.tgz#8bfb5502bde4a4d36cfdeea007fcca21d7e382af" + integrity sha1-i/tVAr3kpNNs/e6gB/zKIdfjgq8= + dependencies: + inherits "^2.0.1" + readable-stream "^2.0.0" + +fs-extra@8.1.0, fs-extra@^8.0.1, fs-extra@^8.1.0: + version "8.1.0" + resolved "https://registry.nlark.com/fs-extra/download/fs-extra-8.1.0.tgz#49d43c45a88cd9677668cb7be1b46efdb8d2e1c0" + integrity sha1-SdQ8RaiM2Wd2aMt74bRu/bjS4cA= + dependencies: + graceful-fs "^4.2.0" + jsonfile "^4.0.0" + universalify "^0.1.0" + +fs-extra@^4.0.3: + version "4.0.3" + resolved "https://registry.nlark.com/fs-extra/download/fs-extra-4.0.3.tgz#0d852122e5bc5beb453fb028e9c0c9bf36340c94" + integrity sha1-DYUhIuW8W+tFP7Ao6cDJvzY0DJQ= + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + +fs-extra@^5.0.0: + version "5.0.0" + resolved "https://registry.nlark.com/fs-extra/download/fs-extra-5.0.0.tgz#414d0110cdd06705734d055652c5411260c31abd" + integrity sha1-QU0BEM3QZwVzTQVWUsVBEmDDGr0= + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + +fs-minipass@^2.0.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/fs-minipass/download/fs-minipass-2.1.0.tgz#7f5036fdbf12c63c169190cbe4199c852271f9fb" + integrity sha1-f1A2/b8SxjwWkZDL5BmchSJx+fs= + dependencies: + minipass "^3.0.0" + +fs-write-stream-atomic@^1.0.8: + version "1.0.10" + resolved "https://registry.npmmirror.com/fs-write-stream-atomic/download/fs-write-stream-atomic-1.0.10.tgz#b47df53493ef911df75731e70a9ded0189db40c9" + integrity sha1-tH31NJPvkR33VzHnCp3tAYnbQMk= + dependencies: + graceful-fs "^4.1.2" + iferr "^0.1.5" + imurmurhash "^0.1.4" + readable-stream "1 || 2" + +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/fs.realpath/download/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" + integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= + +fsevents@^1.2.7: + version "1.2.13" + resolved "https://registry.npmmirror.com/fsevents/download/fsevents-1.2.13.tgz#f325cb0455592428bcf11b383370ef70e3bfcc38" + integrity sha1-8yXLBFVZJCi88Rs4M3DvcOO/zDg= + dependencies: + bindings "^1.5.0" + nan "^2.12.1" + +fsevents@~2.1.2: + version "2.1.3" + resolved "https://registry.npmmirror.com/fsevents/download/fsevents-2.1.3.tgz#fb738703ae8d2f9fe900c33836ddebee8b97f23e" + integrity sha1-+3OHA66NL5/pAMM4Nt3r7ouX8j4= + +fsevents@~2.3.2: + version "2.3.2" + resolved "https://registry.npmmirror.com/fsevents/download/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" + integrity sha1-ilJveLj99GI7cJ4Ll1xSwkwC/Ro= + +fstream@^1.0.0, fstream@^1.0.12: + version "1.0.12" + resolved "https://registry.npm.taobao.org/fstream/download/fstream-1.0.12.tgz#4e8ba8ee2d48be4f7d0de505455548eae5932045" + integrity sha1-Touo7i1Ivk99DeUFRVVI6uWTIEU= + dependencies: + graceful-fs "^4.1.2" + inherits "~2.0.0" + mkdirp ">=0.5 0" + rimraf "2" + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.npm.taobao.org/function-bind/download/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha1-pWiZ0+o8m6uHS7l3O3xe3pL0iV0= + +functional-red-black-tree@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/functional-red-black-tree/download/functional-red-black-tree-1.0.1.tgz?cache=0&sync_timestamp=1622605293770&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ffunctional-red-black-tree%2Fdownload%2Ffunctional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" + integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= + +fuse.js@^6.4.6: + version "6.4.6" + resolved "https://registry.npm.taobao.org/fuse.js/download/fuse.js-6.4.6.tgz#62f216c110e5aa22486aff20be7896d19a059b79" + integrity sha1-YvIWwRDlqiJIav8gvniW0ZoFm3k= + +gauge@~2.7.3: + version "2.7.4" + resolved "https://registry.npmmirror.com/gauge/download/gauge-2.7.4.tgz?cache=0&sync_timestamp=1636989413004&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fgauge%2Fdownload%2Fgauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7" + integrity sha1-LANAXHU4w51+s3sxcCLjJfsBi/c= + dependencies: + aproba "^1.0.3" + console-control-strings "^1.0.0" + has-unicode "^2.0.0" + object-assign "^4.1.0" + signal-exit "^3.0.0" + string-width "^1.0.1" + strip-ansi "^3.0.1" + wide-align "^1.1.0" + +gaze@^1.0.0: + version "1.1.3" + resolved "https://registry.nlark.com/gaze/download/gaze-1.1.3.tgz#c441733e13b927ac8c0ff0b4c3b033f28812924a" + integrity sha1-xEFzPhO5J6yMD/C0w7Az8ogSkko= + dependencies: + globule "^1.0.0" + +gensync@^1.0.0-beta.1, gensync@^1.0.0-beta.2: + version "1.0.0-beta.2" + resolved "https://registry.npm.taobao.org/gensync/download/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" + integrity sha1-MqbudsPX9S1GsrGuXZP+qFgKJeA= + +get-caller-file@^2.0.1: + version "2.0.5" + resolved "https://registry.npm.taobao.org/get-caller-file/download/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" + integrity sha1-T5RBKoLbMvNuOwuXQfipf+sDH34= + +get-intrinsic@^1.0.2, get-intrinsic@^1.1.0, get-intrinsic@^1.1.1: + version "1.1.1" + resolved "https://registry.nlark.com/get-intrinsic/download/get-intrinsic-1.1.1.tgz#15f59f376f855c446963948f0d24cd3637b4abc6" + integrity sha1-FfWfN2+FXERpY5SPDSTNNje0q8Y= + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-symbols "^1.0.1" + +get-stdin@^4.0.1: + version "4.0.1" + resolved "https://registry.nlark.com/get-stdin/download/get-stdin-4.0.1.tgz#b968c6b0a04384324902e8bf1a5df32579a450fe" + integrity sha1-uWjGsKBDhDJJAui/Gl3zJXmkUP4= + +get-stdin@^6.0.0: + version "6.0.0" + resolved "https://registry.nlark.com/get-stdin/download/get-stdin-6.0.0.tgz#9e09bf712b360ab9225e812048f71fde9c89657b" + integrity sha1-ngm/cSs2CrkiXoEgSPcf3pyJZXs= + +get-stream@^4.0.0: + version "4.1.0" + resolved "https://registry.npm.taobao.org/get-stream/download/get-stream-4.1.0.tgz#c1b255575f3dc21d59bfc79cd3d2b46b1c3a54b5" + integrity sha1-wbJVV189wh1Zv8ec09K0axw6VLU= + dependencies: + pump "^3.0.0" + +get-symbol-description@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/get-symbol-description/download/get-symbol-description-1.0.0.tgz#7fdb81c900101fbd564dd5f1a30af5aadc1e58d6" + integrity sha1-f9uByQAQH71WTdXxowr1qtweWNY= + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.1" + +get-value@^2.0.3, get-value@^2.0.6: + version "2.0.6" + resolved "https://registry.nlark.com/get-value/download/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" + integrity sha1-3BXKHGcjh8p2vTesCjlbogQqLCg= + +getpass@^0.1.1: + version "0.1.7" + resolved "https://registry.nlark.com/getpass/download/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" + integrity sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo= + dependencies: + assert-plus "^1.0.0" + +glob-base@^0.3.0: + version "0.3.0" + resolved "https://registry.npm.taobao.org/glob-base/download/glob-base-0.3.0.tgz#dbb164f6221b1c0b1ccf82aea328b497df0ea3c4" + integrity sha1-27Fk9iIbHAscz4Kuoyi0l98Oo8Q= + dependencies: + glob-parent "^2.0.0" + is-glob "^2.0.0" + +glob-parent@^2.0.0: + version "2.0.0" + resolved "https://registry.npmmirror.com/glob-parent/download/glob-parent-2.0.0.tgz?cache=0&sync_timestamp=1632953697891&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fglob-parent%2Fdownload%2Fglob-parent-2.0.0.tgz#81383d72db054fcccf5336daa902f182f6edbb28" + integrity sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg= + dependencies: + is-glob "^2.0.0" + +glob-parent@^3.1.0: + version "3.1.0" + resolved "https://registry.npmmirror.com/glob-parent/download/glob-parent-3.1.0.tgz?cache=0&sync_timestamp=1632953697891&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fglob-parent%2Fdownload%2Fglob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" + integrity sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4= + dependencies: + is-glob "^3.1.0" + path-dirname "^1.0.0" + +glob-parent@^5.0.0, glob-parent@^5.1.2, glob-parent@~5.1.0, glob-parent@~5.1.2: + version "5.1.2" + resolved "https://registry.npmmirror.com/glob-parent/download/glob-parent-5.1.2.tgz?cache=0&sync_timestamp=1632953697891&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fglob-parent%2Fdownload%2Fglob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" + integrity sha1-hpgyxYA0/mikCTwX3BXoNA2EAcQ= + dependencies: + is-glob "^4.0.1" + +glob-to-regexp@^0.3.0: + version "0.3.0" + resolved "https://registry.nlark.com/glob-to-regexp/download/glob-to-regexp-0.3.0.tgz#8c5a1494d2066c570cc3bfe4496175acc4d502ab" + integrity sha1-jFoUlNIGbFcMw7/kSWF1rMTVAqs= + +glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@^7.1.4, glob@^7.1.6: + version "7.2.0" + resolved "https://registry.npmmirror.com/glob/download/glob-7.2.0.tgz?cache=0&sync_timestamp=1632353796482&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fglob%2Fdownload%2Fglob-7.2.0.tgz#d15535af7732e02e948f4c41628bd910293f6023" + integrity sha1-0VU1r3cy4C6Uj0xBYovZECk/YCM= + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + +glob@~7.1.1: + version "7.1.7" + resolved "https://registry.npmmirror.com/glob/download/glob-7.1.7.tgz#3b193e9233f01d42d0b3f78294bbeeb418f94a90" + integrity sha1-Oxk+kjPwHULQs/eClLvutBj5SpA= + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + +globals@^11.1.0: + version "11.12.0" + resolved "https://registry.npmmirror.com/globals/download/globals-11.12.0.tgz?cache=0&sync_timestamp=1635390798667&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fglobals%2Fdownload%2Fglobals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" + integrity sha1-q4eVM4hooLq9hSV1gBjCp+uVxC4= + +globals@^12.1.0: + version "12.4.0" + resolved "https://registry.npmmirror.com/globals/download/globals-12.4.0.tgz?cache=0&sync_timestamp=1635390798667&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fglobals%2Fdownload%2Fglobals-12.4.0.tgz#a18813576a41b00a24a97e7f815918c2e19925f8" + integrity sha1-oYgTV2pBsAokqX5/gVkYwuGZJfg= + dependencies: + type-fest "^0.8.1" + +globby@^11.0.3: + version "11.0.4" + resolved "https://registry.nlark.com/globby/download/globby-11.0.4.tgz#2cbaff77c2f2a62e71e9b2813a67b97a3a3001a5" + integrity sha1-LLr/d8Lypi5x6bKBOme5ejowAaU= + dependencies: + array-union "^2.1.0" + dir-glob "^3.0.1" + fast-glob "^3.1.1" + ignore "^5.1.4" + merge2 "^1.3.0" + slash "^3.0.0" + +globby@^6.1.0: + version "6.1.0" + resolved "https://registry.nlark.com/globby/download/globby-6.1.0.tgz#f5a6d70e8395e21c858fb0489d64df02424d506c" + integrity sha1-9abXDoOV4hyFj7BInWTfAkJNUGw= + dependencies: + array-union "^1.0.1" + glob "^7.0.3" + object-assign "^4.0.1" + pify "^2.0.0" + pinkie-promise "^2.0.0" + +globby@^7.1.1: + version "7.1.1" + resolved "https://registry.nlark.com/globby/download/globby-7.1.1.tgz#fb2ccff9401f8600945dfada97440cca972b8680" + integrity sha1-+yzP+UAfhgCUXfral0QMypcrhoA= + dependencies: + array-union "^1.0.1" + dir-glob "^2.0.0" + glob "^7.1.2" + ignore "^3.3.5" + pify "^3.0.0" + slash "^1.0.0" + +globby@^8.0.0: + version "8.0.2" + resolved "https://registry.nlark.com/globby/download/globby-8.0.2.tgz#5697619ccd95c5275dbb2d6faa42087c1a941d8d" + integrity sha1-VpdhnM2VxSdduy1vqkIIfBqUHY0= + dependencies: + array-union "^1.0.1" + dir-glob "2.0.0" + fast-glob "^2.0.2" + glob "^7.1.2" + ignore "^3.3.5" + pify "^3.0.0" + slash "^1.0.0" + +globjoin@^0.1.4: + version "0.1.4" + resolved "https://registry.nlark.com/globjoin/download/globjoin-0.1.4.tgz#2f4494ac8919e3767c5cbb691e9f463324285d43" + integrity sha1-L0SUrIkZ43Z8XLtpHp9GMyQoXUM= + +globs@^0.1.4: + version "0.1.4" + resolved "https://registry.npm.taobao.org/globs/download/globs-0.1.4.tgz#1d13639f6174e4ae73a7f936da7d9a079f657c1c" + integrity sha1-HRNjn2F05K5zp/k22n2aB59lfBw= + dependencies: + glob "^7.1.1" + +globule@^1.0.0: + version "1.3.3" + resolved "https://registry.nlark.com/globule/download/globule-1.3.3.tgz#811919eeac1ab7344e905f2e3be80a13447973c2" + integrity sha1-gRkZ7qwatzROkF8uO+gKE0R5c8I= + dependencies: + glob "~7.1.1" + lodash "~4.17.10" + minimatch "~3.0.2" + +gonzales-pe@^4.2.3: + version "4.3.0" + resolved "https://registry.nlark.com/gonzales-pe/download/gonzales-pe-4.3.0.tgz#fe9dec5f3c557eead09ff868c65826be54d067b3" + integrity sha1-/p3sXzxVfurQn/hoxlgmvlTQZ7M= + dependencies: + minimist "^1.2.5" + +graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0: + version "4.2.8" + resolved "https://registry.npmmirror.com/graceful-fs/download/graceful-fs-4.2.8.tgz#e412b8d33f5e006593cbd3cee6df9f2cebbe802a" + integrity sha1-5BK40z9eAGWTy9PO5t+fLOu+gCo= + +gzip-size@^6.0.0: + version "6.0.0" + resolved "https://registry.npmmirror.com/gzip-size/download/gzip-size-6.0.0.tgz#065367fd50c239c0671cbcbad5be3e2eeb10e462" + integrity sha1-BlNn/VDCOcBnHLy61b4+LusQ5GI= + dependencies: + duplexer "^0.1.2" + +handle-thing@^2.0.0: + version "2.0.1" + resolved "https://registry.npm.taobao.org/handle-thing/download/handle-thing-2.0.1.tgz#857f79ce359580c340d43081cc648970d0bb234e" + integrity sha1-hX95zjWVgMNA1DCBzGSJcNC7I04= + +har-schema@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/har-schema/download/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" + integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= + +har-validator@~5.1.3: + version "5.1.5" + resolved "https://registry.npmmirror.com/har-validator/download/har-validator-5.1.5.tgz#1f0803b9f8cb20c0fa13822df1ecddb36bde1efd" + integrity sha1-HwgDufjLIMD6E4It8ezds2veHv0= + dependencies: + ajv "^6.12.3" + har-schema "^2.0.0" + +has-ansi@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/has-ansi/download/has-ansi-2.0.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fhas-ansi%2Fdownload%2Fhas-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" + integrity sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE= + dependencies: + ansi-regex "^2.0.0" + +has-bigints@^1.0.1: + version "1.0.1" + resolved "https://registry.npm.taobao.org/has-bigints/download/has-bigints-1.0.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fhas-bigints%2Fdownload%2Fhas-bigints-1.0.1.tgz#64fe6acb020673e3b78db035a5af69aa9d07b113" + integrity sha1-ZP5qywIGc+O3jbA1pa9pqp0HsRM= + +has-flag@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/has-flag/download/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" + integrity sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo= + +has-flag@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/has-flag/download/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" + integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= + +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/has-flag/download/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha1-lEdx/ZyByBJlxNaUGGDaBrtZR5s= + +has-symbols@^1.0.1, has-symbols@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/has-symbols/download/has-symbols-1.0.2.tgz#165d3070c00309752a1236a479331e3ac56f1423" + integrity sha1-Fl0wcMADCXUqEjakeTMeOsVvFCM= + +has-tostringtag@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/has-tostringtag/download/has-tostringtag-1.0.0.tgz?cache=0&sync_timestamp=1628196402801&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fhas-tostringtag%2Fdownload%2Fhas-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" + integrity sha1-fhM4GKfTlHNPlB5zw9P5KR5liyU= + dependencies: + has-symbols "^1.0.2" + +has-unicode@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/has-unicode/download/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" + integrity sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk= + +has-value@^0.3.1: + version "0.3.1" + resolved "https://registry.nlark.com/has-value/download/has-value-0.3.1.tgz#7b1f58bada62ca827ec0a2078025654845995e1f" + integrity sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8= + dependencies: + get-value "^2.0.3" + has-values "^0.1.4" + isobject "^2.0.0" + +has-value@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/has-value/download/has-value-1.0.0.tgz#18b281da585b1c5c51def24c930ed29a0be6b177" + integrity sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc= + dependencies: + get-value "^2.0.6" + has-values "^1.0.0" + isobject "^3.0.0" + +has-values@^0.1.4: + version "0.1.4" + resolved "https://registry.npm.taobao.org/has-values/download/has-values-0.1.4.tgz#6d61de95d91dfca9b9a02089ad384bff8f62b771" + integrity sha1-bWHeldkd/Km5oCCJrThL/49it3E= + +has-values@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/has-values/download/has-values-1.0.0.tgz#95b0b63fec2146619a6fe57fe75628d5a39efe4f" + integrity sha1-lbC2P+whRmGab+V/51Yo1aOe/k8= + dependencies: + is-number "^3.0.0" + kind-of "^4.0.0" + +has@^1.0.3: + version "1.0.3" + resolved "https://registry.nlark.com/has/download/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha1-ci18v8H2qoJB8W3YFOAR4fQeh5Y= + dependencies: + function-bind "^1.1.1" + +hash-base@^3.0.0: + version "3.1.0" + resolved "https://registry.nlark.com/hash-base/download/hash-base-3.1.0.tgz#55c381d9e06e1d2997a883b4a3fddfe7f0d3af33" + integrity sha1-VcOB2eBuHSmXqIO0o/3f5/DTrzM= + dependencies: + inherits "^2.0.4" + readable-stream "^3.6.0" + safe-buffer "^5.2.0" + +hash.js@^1.0.0, hash.js@^1.0.3: + version "1.1.7" + resolved "https://registry.nlark.com/hash.js/download/hash.js-1.1.7.tgz?cache=0&sync_timestamp=1622643346539&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fhash.js%2Fdownload%2Fhash.js-1.1.7.tgz#0babca538e8d4ee4a0f8988d68866537a003cf42" + integrity sha1-C6vKU46NTuSg+JiNaIZlN6ADz0I= + dependencies: + inherits "^2.0.3" + minimalistic-assert "^1.0.1" + +he@1.2.x, he@^1.2.0: + version "1.2.0" + resolved "https://registry.nlark.com/he/download/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f" + integrity sha1-hK5l+n6vsWX922FWauFLrwVmTw8= + +history@^5.0.0: + version "5.1.0" + resolved "https://registry.npmmirror.com/history/download/history-5.1.0.tgz?cache=0&sync_timestamp=1635887414026&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fhistory%2Fdownload%2Fhistory-5.1.0.tgz#2e93c09c064194d38d52ed62afd0afc9d9b01ece" + integrity sha1-LpPAnAZBlNONUu1ir9CvydmwHs4= + dependencies: + "@babel/runtime" "^7.7.6" + +hmac-drbg@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/hmac-drbg/download/hmac-drbg-1.0.1.tgz#d2745701025a6c775a6c545793ed502fc0c649a1" + integrity sha1-0nRXAQJabHdabFRXk+1QL8DGSaE= + dependencies: + hash.js "^1.0.3" + minimalistic-assert "^1.0.0" + minimalistic-crypto-utils "^1.0.1" + +hoist-non-react-statics@^3.3.0, hoist-non-react-statics@^3.3.2: + version "3.3.2" + resolved "https://registry.npm.taobao.org/hoist-non-react-statics/download/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45" + integrity sha1-7OCsr3HWLClpwuxZ/v9CpLGoW0U= + dependencies: + react-is "^16.7.0" + +hosted-git-info@^2.1.4: + version "2.8.9" + resolved "https://registry.nlark.com/hosted-git-info/download/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9" + integrity sha1-3/wL+aIcAiCQkPKqaUKeFBTa8/k= + +hpack.js@^2.1.6: + version "2.1.6" + resolved "https://registry.nlark.com/hpack.js/download/hpack.js-2.1.6.tgz#87774c0949e513f42e84575b3c45681fade2a0b2" + integrity sha1-h3dMCUnlE/QuhFdbPEVoH63ioLI= + dependencies: + inherits "^2.0.1" + obuf "^1.0.0" + readable-stream "^2.0.1" + wbuf "^1.1.0" + +html-encoding-sniffer@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/html-encoding-sniffer/download/html-encoding-sniffer-1.0.2.tgz?cache=0&sync_timestamp=1632006268441&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fhtml-encoding-sniffer%2Fdownload%2Fhtml-encoding-sniffer-1.0.2.tgz#e70d84b94da53aa375e11fe3a351be6642ca46f8" + integrity sha1-5w2EuU2lOqN14R/jo1G+ZkLKRvg= + dependencies: + whatwg-encoding "^1.0.1" + +html-entities@^1.2.1, html-entities@^1.3.1: + version "1.4.0" + resolved "https://registry.nlark.com/html-entities/download/html-entities-1.4.0.tgz#cfbd1b01d2afaf9adca1b10ae7dffab98c71d2dc" + integrity sha1-z70bAdKvr5rcobEK59/6uYxx0tw= + +html-minifier@^3.2.3: + version "3.5.21" + resolved "https://registry.nlark.com/html-minifier/download/html-minifier-3.5.21.tgz#d0040e054730e354db008463593194015212d20c" + integrity sha1-0AQOBUcw41TbAIRjWTGUAVIS0gw= + dependencies: + camel-case "3.0.x" + clean-css "4.2.x" + commander "2.17.x" + he "1.2.x" + param-case "2.1.x" + relateurl "0.2.x" + uglify-js "3.4.x" + +html-minifier@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/html-minifier/download/html-minifier-4.0.0.tgz#cca9aad8bce1175e02e17a8c33e46d8988889f56" + integrity sha1-zKmq2LzhF14C4XqMM+RtiYiIn1Y= + dependencies: + camel-case "^3.0.0" + clean-css "^4.2.1" + commander "^2.19.0" + he "^1.2.0" + param-case "^2.1.1" + relateurl "^0.2.7" + uglify-js "^3.5.1" + +html-tags@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/html-tags/download/html-tags-2.0.0.tgz#10b30a386085f43cede353cc8fa7cb0deeea668b" + integrity sha1-ELMKOGCF9Dzt41PMj6fLDe7qZos= + +html-tags@^3.1.0: + version "3.1.0" + resolved "https://registry.npm.taobao.org/html-tags/download/html-tags-3.1.0.tgz#7b5e6f7e665e9fb41f30007ed9e0d41e97fb2140" + integrity sha1-e15vfmZen7QfMAB+2eDUHpf7IUA= + +html-webpack-include-assets-plugin@1.0.5: + version "1.0.5" + resolved "https://registry.npmmirror.com/html-webpack-include-assets-plugin/download/html-webpack-include-assets-plugin-1.0.5.tgz#12770c227290451633351b5ed72dda8ce8c0642e" + integrity sha1-EncMInKQRRYzNRte1y3ajOjAZC4= + dependencies: + glob "^7.1.3" + minimatch "^3.0.4" + slash "^2.0.0" + +html-webpack-plugin@3.2.0: + version "3.2.0" + resolved "https://registry.npmmirror.com/html-webpack-plugin/download/html-webpack-plugin-3.2.0.tgz#b01abbd723acaaa7b37b6af4492ebda03d9dd37b" + integrity sha1-sBq71yOsqqeze2r0SS69oD2d03s= + dependencies: + html-minifier "^3.2.3" + loader-utils "^0.2.16" + lodash "^4.17.3" + pretty-error "^2.0.2" + tapable "^1.0.0" + toposort "^1.0.0" + util.promisify "1.0.0" + +htmlparser2@3.8.x: + version "3.8.3" + resolved "https://registry.nlark.com/htmlparser2/download/htmlparser2-3.8.3.tgz#996c28b191516a8be86501a7d79757e5c70c1068" + integrity sha1-mWwosZFRaovoZQGn15dX5ccMEGg= + dependencies: + domelementtype "1" + domhandler "2.3" + domutils "1.5" + entities "1.0" + readable-stream "1.1" + +htmlparser2@^3.9.2: + version "3.10.1" + resolved "https://registry.nlark.com/htmlparser2/download/htmlparser2-3.10.1.tgz#bd679dc3f59897b6a34bb10749c855bb53a9392f" + integrity sha1-vWedw/WYl7ajS7EHSchVu1OpOS8= + dependencies: + domelementtype "^1.3.1" + domhandler "^2.3.0" + domutils "^1.5.1" + entities "^1.1.1" + inherits "^2.0.1" + readable-stream "^3.1.1" + +htmlparser2@^6.1.0: + version "6.1.0" + resolved "https://registry.nlark.com/htmlparser2/download/htmlparser2-6.1.0.tgz#c4d762b6c3371a05dbe65e94ae43a9f845fb8fb7" + integrity sha1-xNditsM3GgXb5l6UrkOp+EX7j7c= + dependencies: + domelementtype "^2.0.1" + domhandler "^4.0.0" + domutils "^2.5.2" + entities "^2.0.0" + +http-deceiver@^1.2.7: + version "1.2.7" + resolved "https://registry.nlark.com/http-deceiver/download/http-deceiver-1.2.7.tgz#fa7168944ab9a519d337cb0bec7284dc3e723d87" + integrity sha1-+nFolEq5pRnTN8sL7HKE3D5yPYc= + +http-errors@1.7.2: + version "1.7.2" + resolved "https://registry.npm.taobao.org/http-errors/download/http-errors-1.7.2.tgz#4f5029cf13239f31036e5b2e55292bcfbcc85c8f" + integrity sha1-T1ApzxMjnzEDblsuVSkrz7zIXI8= + dependencies: + depd "~1.1.2" + inherits "2.0.3" + setprototypeof "1.1.1" + statuses ">= 1.5.0 < 2" + toidentifier "1.0.0" + +http-errors@~1.6.2: + version "1.6.3" + resolved "https://registry.npm.taobao.org/http-errors/download/http-errors-1.6.3.tgz#8b55680bb4be283a0b5bf4ea2e38580be1d9320d" + integrity sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0= + dependencies: + depd "~1.1.2" + inherits "2.0.3" + setprototypeof "1.1.0" + statuses ">= 1.4.0 < 2" + +http-errors@~1.7.2: + version "1.7.3" + resolved "https://registry.npm.taobao.org/http-errors/download/http-errors-1.7.3.tgz#6c619e4f9c60308c38519498c14fbb10aacebb06" + integrity sha1-bGGeT5xgMIw4UZSYwU+7EKrOuwY= + dependencies: + depd "~1.1.2" + inherits "2.0.4" + setprototypeof "1.1.1" + statuses ">= 1.5.0 < 2" + toidentifier "1.0.0" + +http-parser-js@>=0.5.1: + version "0.5.3" + resolved "https://registry.npm.taobao.org/http-parser-js/download/http-parser-js-0.5.3.tgz#01d2709c79d41698bb01d4decc5e9da4e4a033d9" + integrity sha1-AdJwnHnUFpi7AdTezF6dpOSgM9k= + +http-proxy-middleware@0.19.1: + version "0.19.1" + resolved "https://registry.nlark.com/http-proxy-middleware/download/http-proxy-middleware-0.19.1.tgz#183c7dc4aa1479150306498c210cdaf96080a43a" + integrity sha1-GDx9xKoUeRUDBkmMIQza+WCApDo= + dependencies: + http-proxy "^1.17.0" + is-glob "^4.0.0" + lodash "^4.17.11" + micromatch "^3.1.10" + +http-proxy@^1.17.0: + version "1.18.1" + resolved "https://registry.nlark.com/http-proxy/download/http-proxy-1.18.1.tgz#401541f0534884bbf95260334e72f88ee3976549" + integrity sha1-QBVB8FNIhLv5UmAzTnL4juOXZUk= + dependencies: + eventemitter3 "^4.0.0" + follow-redirects "^1.0.0" + requires-port "^1.0.0" + +http-signature@~1.2.0: + version "1.2.0" + resolved "https://registry.nlark.com/http-signature/download/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" + integrity sha1-muzZJRFHcvPZW2WmCruPfBj7rOE= + dependencies: + assert-plus "^1.0.0" + jsprim "^1.2.2" + sshpk "^1.7.0" + +https-browserify@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/https-browserify/download/https-browserify-1.0.0.tgz#ec06c10e0a34c0f2faf199f7fd7fc78fffd03c73" + integrity sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM= + +iconv-lite@0.4.24, iconv-lite@^0.4.24, iconv-lite@^0.4.4: + version "0.4.24" + resolved "https://registry.nlark.com/iconv-lite/download/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" + integrity sha1-ICK0sl+93CHS9SSXSkdKr+czkIs= + dependencies: + safer-buffer ">= 2.1.2 < 3" + +icss-utils@^4.0.0, icss-utils@^4.1.1: + version "4.1.1" + resolved "https://registry.nlark.com/icss-utils/download/icss-utils-4.1.1.tgz#21170b53789ee27447c2f47dd683081403f9a467" + integrity sha1-IRcLU3ie4nRHwvR91oMIFAP5pGc= + dependencies: + postcss "^7.0.14" + +ieee754@^1.1.4: + version "1.2.1" + resolved "https://registry.nlark.com/ieee754/download/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" + integrity sha1-jrehCmP/8l0VpXsAFYbRd9Gw01I= + +iferr@^0.1.5: + version "0.1.5" + resolved "https://registry.nlark.com/iferr/download/iferr-0.1.5.tgz#c60eed69e6d8fdb6b3104a1fcbca1c192dc5b501" + integrity sha1-xg7taebY/bazEEofy8ocGS3FtQE= + +ignore@^3.3.3, ignore@^3.3.5: + version "3.3.10" + resolved "https://registry.npmmirror.com/ignore/download/ignore-3.3.10.tgz?cache=0&sync_timestamp=1635926632542&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fignore%2Fdownload%2Fignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" + integrity sha1-Cpf7h2mG6AgcYxFg+PnziRV/AEM= + +ignore@^4.0.6: + version "4.0.6" + resolved "https://registry.npmmirror.com/ignore/download/ignore-4.0.6.tgz?cache=0&sync_timestamp=1635926632542&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fignore%2Fdownload%2Fignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" + integrity sha1-dQ49tYYgh7RzfrrIIH/9HvJ7Jfw= + +ignore@^5.1.4, ignore@^5.1.8: + version "5.1.9" + resolved "https://registry.npmmirror.com/ignore/download/ignore-5.1.9.tgz?cache=0&sync_timestamp=1635926632542&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fignore%2Fdownload%2Fignore-5.1.9.tgz#9ec1a5cbe8e1446ec60d4420060d43aa6e7382fb" + integrity sha1-nsGly+jhRG7GDUQgBg1Dqm5zgvs= + +image-size@~0.5.0: + version "0.5.5" + resolved "https://registry.npm.taobao.org/image-size/download/image-size-0.5.5.tgz?cache=0&sync_timestamp=1618422657851&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fimage-size%2Fdownload%2Fimage-size-0.5.5.tgz#09dfd4ab9d20e29eb1c3e80b8990378df9e3cb9c" + integrity sha1-Cd/Uq50g4p6xw+gLiZA3jfnjy5w= + +immer@^9.0.6: + version "9.0.6" + resolved "https://registry.nlark.com/immer/download/immer-9.0.6.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fimmer%2Fdownload%2Fimmer-9.0.6.tgz#7a96bf2674d06c8143e327cbf73539388ddf1a73" + integrity sha1-epa/JnTQbIFD4yfL9zU5OI3fGnM= + +import-fresh@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/import-fresh/download/import-fresh-2.0.0.tgz#d81355c15612d386c61f9ddd3922d4304822a546" + integrity sha1-2BNVwVYS04bGH53dOSLUMEgipUY= + dependencies: + caller-path "^2.0.0" + resolve-from "^3.0.0" + +import-fresh@^3.0.0, import-fresh@^3.2.1: + version "3.3.0" + resolved "https://registry.nlark.com/import-fresh/download/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" + integrity sha1-NxYsJfy566oublPVtNiM4X2eDCs= + dependencies: + parent-module "^1.0.0" + resolve-from "^4.0.0" + +import-lazy@^3.1.0: + version "3.1.0" + resolved "https://registry.nlark.com/import-lazy/download/import-lazy-3.1.0.tgz#891279202c8a2280fdbd6674dbd8da1a1dfc67cc" + integrity sha1-iRJ5ICyKIoD9vWZ029jaGh38Z8w= + +import-local@^2.0.0: + version "2.0.0" + resolved "https://registry.npmmirror.com/import-local/download/import-local-2.0.0.tgz?cache=0&sync_timestamp=1633327317807&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fimport-local%2Fdownload%2Fimport-local-2.0.0.tgz#55070be38a5993cf18ef6db7e961f5bee5c5a09d" + integrity sha1-VQcL44pZk88Y72236WH1vuXFoJ0= + dependencies: + pkg-dir "^3.0.0" + resolve-cwd "^2.0.0" + +imurmurhash@^0.1.4: + version "0.1.4" + resolved "https://registry.nlark.com/imurmurhash/download/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" + integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= + +in-publish@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/in-publish/download/in-publish-2.0.1.tgz#948b1a535c8030561cea522f73f78f4be357e00c" + integrity sha1-lIsaU1yAMFYc6lIvc/ePS+NX4Aw= + +indent-string@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/indent-string/download/indent-string-2.1.0.tgz?cache=0&sync_timestamp=1622604582006&other_urls=https%3A%2F%2Fregistry.nlark.com%2Findent-string%2Fdownload%2Findent-string-2.1.0.tgz#8e2d48348742121b4a8218b7a137e9a52049dc80" + integrity sha1-ji1INIdCEhtKghi3oTfppSBJ3IA= + dependencies: + repeating "^2.0.0" + +indent-string@^3.0.0: + version "3.2.0" + resolved "https://registry.nlark.com/indent-string/download/indent-string-3.2.0.tgz?cache=0&sync_timestamp=1622604582006&other_urls=https%3A%2F%2Fregistry.nlark.com%2Findent-string%2Fdownload%2Findent-string-3.2.0.tgz#4a5fd6d27cc332f37e5419a504dbb837105c9289" + integrity sha1-Sl/W0nzDMvN+VBmlBNu4NxBckok= + +indent-string@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/indent-string/download/indent-string-4.0.0.tgz?cache=0&sync_timestamp=1622604582006&other_urls=https%3A%2F%2Fregistry.nlark.com%2Findent-string%2Fdownload%2Findent-string-4.0.0.tgz#624f8f4497d619b2d9768531d58f4122854d7251" + integrity sha1-Yk+PRJfWGbLZdoUx1Y9BIoVNclE= + +indexes-of@^1.0.1: + version "1.0.1" + resolved "https://registry.npm.taobao.org/indexes-of/download/indexes-of-1.0.1.tgz#f30f716c8e2bd346c7b67d3df3915566a7c05607" + integrity sha1-8w9xbI4r00bHtn0985FVZqfAVgc= + +infer-owner@^1.0.3, infer-owner@^1.0.4: + version "1.0.4" + resolved "https://registry.npm.taobao.org/infer-owner/download/infer-owner-1.0.4.tgz#c4cefcaa8e51051c2a40ba2ce8a3d27295af9467" + integrity sha1-xM78qo5RBRwqQLos6KPScpWvlGc= + +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.nlark.com/inflight/download/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" + integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= + dependencies: + once "^1.3.0" + wrappy "1" + +inherits@2, inherits@2.0.4, inherits@^2.0.0, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: + version "2.0.4" + resolved "https://registry.nlark.com/inherits/download/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha1-D6LGT5MpF8NDOg3tVTY6rjdBa3w= + +inherits@2.0.1: + version "2.0.1" + resolved "https://registry.nlark.com/inherits/download/inherits-2.0.1.tgz#b17d08d326b4423e568eff719f91b0b1cbdf69f1" + integrity sha1-sX0I0ya0Qj5Wjv9xn5GwscvfafE= + +inherits@2.0.3: + version "2.0.3" + resolved "https://registry.nlark.com/inherits/download/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" + integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4= + +inquirer@^7.0.0: + version "7.3.3" + resolved "https://registry.npmmirror.com/inquirer/download/inquirer-7.3.3.tgz?cache=0&sync_timestamp=1633472964335&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Finquirer%2Fdownload%2Finquirer-7.3.3.tgz#04d176b2af04afc157a83fd7c100e98ee0aad003" + integrity sha1-BNF2sq8Er8FXqD/XwQDpjuCq0AM= + dependencies: + ansi-escapes "^4.2.1" + chalk "^4.1.0" + cli-cursor "^3.1.0" + cli-width "^3.0.0" + external-editor "^3.0.3" + figures "^3.0.0" + lodash "^4.17.19" + mute-stream "0.0.8" + run-async "^2.4.0" + rxjs "^6.6.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + through "^2.3.6" + +internal-ip@^4.3.0: + version "4.3.0" + resolved "https://registry.npmmirror.com/internal-ip/download/internal-ip-4.3.0.tgz?cache=0&sync_timestamp=1634404775654&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Finternal-ip%2Fdownload%2Finternal-ip-4.3.0.tgz#845452baad9d2ca3b69c635a137acb9a0dad0907" + integrity sha1-hFRSuq2dLKO2nGNaE3rLmg2tCQc= + dependencies: + default-gateway "^4.2.0" + ipaddr.js "^1.9.0" + +internal-slot@^1.0.3: + version "1.0.3" + resolved "https://registry.nlark.com/internal-slot/download/internal-slot-1.0.3.tgz#7347e307deeea2faac2ac6205d4bc7d34967f59c" + integrity sha1-c0fjB97uovqsKsYgXUvH00ln9Zw= + dependencies: + get-intrinsic "^1.1.0" + has "^1.0.3" + side-channel "^1.0.4" + +intersection-observer@^0.7.0: + version "0.7.0" + resolved "https://registry.npm.taobao.org/intersection-observer/download/intersection-observer-0.7.0.tgz#ee16bee978db53516ead2f0a8154b09b400bbdc9" + integrity sha1-7ha+6XjbU1FurS8KgVSwm0ALvck= + +invariant@^2.2.2, invariant@^2.2.4: + version "2.2.4" + resolved "https://registry.nlark.com/invariant/download/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" + integrity sha1-YQ88ksk1nOHbYW5TgAjSP/NRWOY= + dependencies: + loose-envify "^1.0.0" + +inversify@5.1.1: + version "5.1.1" + resolved "https://registry.npmmirror.com/inversify/download/inversify-5.1.1.tgz?cache=0&sync_timestamp=1634218892257&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Finversify%2Fdownload%2Finversify-5.1.1.tgz#6fbd668c591337404e005a1946bfe0d802c08730" + integrity sha1-b71mjFkTN0BOAFoZRr/g2ALAhzA= + +ip-regex@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/ip-regex/download/ip-regex-2.1.0.tgz#fa78bf5d2e6913c911ce9f819ee5146bb6d844e9" + integrity sha1-+ni/XS5pE8kRzp+BnuUUa7bYROk= + +ip@^1.1.0, ip@^1.1.5: + version "1.1.5" + resolved "https://registry.nlark.com/ip/download/ip-1.1.5.tgz#bdded70114290828c0a039e72ef25f5aaec4354a" + integrity sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo= + +ipaddr.js@1.9.1, ipaddr.js@^1.9.0: + version "1.9.1" + resolved "https://registry.nlark.com/ipaddr.js/download/ipaddr.js-1.9.1.tgz#bff38543eeb8984825079ff3a2a8e6cbd46781b3" + integrity sha1-v/OFQ+64mEglB5/zoqjmy9RngbM= + +is-absolute-url@^3.0.3: + version "3.0.3" + resolved "https://registry.nlark.com/is-absolute-url/download/is-absolute-url-3.0.3.tgz?cache=0&sync_timestamp=1628691761253&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-absolute-url%2Fdownload%2Fis-absolute-url-3.0.3.tgz#96c6a22b6a23929b11ea0afb1836c36ad4a5d698" + integrity sha1-lsaiK2ojkpsR6gr7GDbDatSl1pg= + +is-accessor-descriptor@^0.1.6: + version "0.1.6" + resolved "https://registry.nlark.com/is-accessor-descriptor/download/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" + integrity sha1-qeEss66Nh2cn7u84Q/igiXtcmNY= + dependencies: + kind-of "^3.0.2" + +is-accessor-descriptor@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/is-accessor-descriptor/download/is-accessor-descriptor-1.0.0.tgz#169c2f6d3df1f992618072365c9b0ea1f6878656" + integrity sha1-FpwvbT3x+ZJhgHI2XJsOofaHhlY= + dependencies: + kind-of "^6.0.0" + +is-alphabetical@^1.0.0: + version "1.0.4" + resolved "https://registry.npmmirror.com/is-alphabetical/download/is-alphabetical-1.0.4.tgz#9e7d6b94916be22153745d184c298cbf986a686d" + integrity sha1-nn1rlJFr4iFTdF0YTCmMv5hqaG0= + +is-alphanumeric@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/is-alphanumeric/download/is-alphanumeric-1.0.0.tgz#4a9cef71daf4c001c1d81d63d140cf53fd6889f4" + integrity sha1-Spzvcdr0wAHB2B1j0UDPU/1oifQ= + +is-alphanumerical@^1.0.0: + version "1.0.4" + resolved "https://registry.npmmirror.com/is-alphanumerical/download/is-alphanumerical-1.0.4.tgz?cache=0&sync_timestamp=1636009316820&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fis-alphanumerical%2Fdownload%2Fis-alphanumerical-1.0.4.tgz#7eb9a2431f855f6b1ef1a78e326df515696c4dbf" + integrity sha1-frmiQx+FX2se8aeOMm31FWlsTb8= + dependencies: + is-alphabetical "^1.0.0" + is-decimal "^1.0.0" + +is-arguments@^1.0.4: + version "1.1.1" + resolved "https://registry.nlark.com/is-arguments/download/is-arguments-1.1.1.tgz?cache=0&sync_timestamp=1628201919104&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-arguments%2Fdownload%2Fis-arguments-1.1.1.tgz#15b3f88fda01f2a97fec84ca761a560f123efa9b" + integrity sha1-FbP4j9oB8ql/7ITKdhpWDxI++ps= + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.npm.taobao.org/is-arrayish/download/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" + integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= + +is-bigint@^1.0.1: + version "1.0.4" + resolved "https://registry.nlark.com/is-bigint/download/is-bigint-1.0.4.tgz?cache=0&sync_timestamp=1628747504782&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-bigint%2Fdownload%2Fis-bigint-1.0.4.tgz#08147a1875bc2b32005d41ccd8291dffc6691df3" + integrity sha1-CBR6GHW8KzIAXUHM2Ckd/8ZpHfM= + dependencies: + has-bigints "^1.0.1" + +is-binary-path@^1.0.0: + version "1.0.1" + resolved "https://registry.nlark.com/is-binary-path/download/is-binary-path-1.0.1.tgz#75f16642b480f187a711c814161fd3a4a7655898" + integrity sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg= + dependencies: + binary-extensions "^1.0.0" + +is-binary-path@~2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/is-binary-path/download/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09" + integrity sha1-6h9/O4DwZCNug0cPhsCcJU+0Wwk= + dependencies: + binary-extensions "^2.0.0" + +is-boolean-object@^1.1.0: + version "1.1.2" + resolved "https://registry.nlark.com/is-boolean-object/download/is-boolean-object-1.1.2.tgz#5c6dc200246dd9321ae4b885a114bb1f75f63719" + integrity sha1-XG3CACRt2TIa5LiFoRS7H3X2Nxk= + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-buffer@^1.1.4, is-buffer@^1.1.5, is-buffer@~1.1.6: + version "1.1.6" + resolved "https://registry.nlark.com/is-buffer/download/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" + integrity sha1-76ouqdqg16suoTqXsritUf776L4= + +is-callable@^1.1.4, is-callable@^1.2.4: + version "1.2.4" + resolved "https://registry.nlark.com/is-callable/download/is-callable-1.2.4.tgz#47301d58dd0259407865547853df6d61fe471945" + integrity sha1-RzAdWN0CWUB4ZVR4U99tYf5HGUU= + +is-core-module@^2.2.0, is-core-module@^2.7.0: + version "2.8.0" + resolved "https://registry.npmmirror.com/is-core-module/download/is-core-module-2.8.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fis-core-module%2Fdownload%2Fis-core-module-2.8.0.tgz#0321336c3d0925e497fd97f5d95cb114a5ccd548" + integrity sha1-AyEzbD0JJeSX/Zf12VyxFKXM1Ug= + dependencies: + has "^1.0.3" + +is-data-descriptor@^0.1.4: + version "0.1.4" + resolved "https://registry.nlark.com/is-data-descriptor/download/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" + integrity sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y= + dependencies: + kind-of "^3.0.2" + +is-data-descriptor@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/is-data-descriptor/download/is-data-descriptor-1.0.0.tgz#d84876321d0e7add03990406abbbbd36ba9268c7" + integrity sha1-2Eh2Mh0Oet0DmQQGq7u9NrqSaMc= + dependencies: + kind-of "^6.0.0" + +is-date-object@^1.0.1: + version "1.0.5" + resolved "https://registry.nlark.com/is-date-object/download/is-date-object-1.0.5.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-date-object%2Fdownload%2Fis-date-object-1.0.5.tgz#0841d5536e724c25597bf6ea62e1bd38298df31f" + integrity sha1-CEHVU25yTCVZe/bqYuG9OCmN8x8= + dependencies: + has-tostringtag "^1.0.0" + +is-decimal@^1.0.0: + version "1.0.4" + resolved "https://registry.npmmirror.com/is-decimal/download/is-decimal-1.0.4.tgz?cache=0&sync_timestamp=1636008960795&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fis-decimal%2Fdownload%2Fis-decimal-1.0.4.tgz#65a3a5958a1c5b63a706e1b333d7cd9f630d3fa5" + integrity sha1-ZaOllYocW2OnBuGzM9fNn2MNP6U= + +is-descriptor@^0.1.0: + version "0.1.6" + resolved "https://registry.npm.taobao.org/is-descriptor/download/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" + integrity sha1-Nm2CQN3kh8pRgjsaufB6EKeCUco= + dependencies: + is-accessor-descriptor "^0.1.6" + is-data-descriptor "^0.1.4" + kind-of "^5.0.0" + +is-descriptor@^1.0.0, is-descriptor@^1.0.2: + version "1.0.2" + resolved "https://registry.npm.taobao.org/is-descriptor/download/is-descriptor-1.0.2.tgz#3b159746a66604b04f8c81524ba365c5f14d86ec" + integrity sha1-OxWXRqZmBLBPjIFSS6NlxfFNhuw= + dependencies: + is-accessor-descriptor "^1.0.0" + is-data-descriptor "^1.0.0" + kind-of "^6.0.2" + +is-directory@^0.3.1: + version "0.3.1" + resolved "https://registry.npm.taobao.org/is-directory/download/is-directory-0.3.1.tgz#61339b6f2475fc772fd9c9d83f5c8575dc154ae1" + integrity sha1-YTObbyR1/Hcv2cnYP1yFddwVSuE= + +is-docker@^2.0.0: + version "2.2.1" + resolved "https://registry.nlark.com/is-docker/download/is-docker-2.2.1.tgz?cache=0&sync_timestamp=1630451108035&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-docker%2Fdownload%2Fis-docker-2.2.1.tgz#33eeabe23cfe86f14bde4408a02c0cfb853acdaa" + integrity sha1-M+6r4jz+hvFL3kQIoCwM+4U6zao= + +is-dotfile@^1.0.0: + version "1.0.3" + resolved "https://registry.nlark.com/is-dotfile/download/is-dotfile-1.0.3.tgz#a6a2f32ffd2dfb04f5ca25ecd0f6b83cf798a1e1" + integrity sha1-pqLzL/0t+wT1yiXs0Pa4PPeYoeE= + +is-equal-shallow@^0.1.3: + version "0.1.3" + resolved "https://registry.nlark.com/is-equal-shallow/download/is-equal-shallow-0.1.3.tgz#2238098fc221de0bcfa5d9eac4c45d638aa1c534" + integrity sha1-IjgJj8Ih3gvPpdnqxMRdY4qhxTQ= + dependencies: + is-primitive "^2.0.0" + +is-extendable@^0.1.0, is-extendable@^0.1.1: + version "0.1.1" + resolved "https://registry.npm.taobao.org/is-extendable/download/is-extendable-0.1.1.tgz#62b110e289a471418e3ec36a617d472e301dfc89" + integrity sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik= + +is-extendable@^1.0.1: + version "1.0.1" + resolved "https://registry.npm.taobao.org/is-extendable/download/is-extendable-1.0.1.tgz#a7470f9e426733d81bd81e1155264e3a3507cab4" + integrity sha1-p0cPnkJnM9gb2B4RVSZOOjUHyrQ= + dependencies: + is-plain-object "^2.0.4" + +is-extglob@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/is-extglob/download/is-extglob-1.0.0.tgz#ac468177c4943405a092fc8f29760c6ffc6206c0" + integrity sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA= + +is-extglob@^2.1.0, is-extglob@^2.1.1: + version "2.1.1" + resolved "https://registry.npm.taobao.org/is-extglob/download/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" + integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= + +is-finite@^1.0.0: + version "1.1.0" + resolved "https://registry.npmmirror.com/is-finite/download/is-finite-1.1.0.tgz#904135c77fb42c0641d6aa1bcdbc4daa8da082f3" + integrity sha1-kEE1x3+0LAZB1qobzbxNqo2ggvM= + +is-fullwidth-code-point@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/is-fullwidth-code-point/download/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" + integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= + dependencies: + number-is-nan "^1.0.0" + +is-fullwidth-code-point@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/is-fullwidth-code-point/download/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" + integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= + +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/is-fullwidth-code-point/download/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" + integrity sha1-8Rb4Bk/pCz94RKOJl8C3UFEmnx0= + +is-glob@^2.0.0, is-glob@^2.0.1: + version "2.0.1" + resolved "https://registry.npmmirror.com/is-glob/download/is-glob-2.0.1.tgz#d096f926a3ded5600f3fdfd91198cb0888c2d863" + integrity sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM= + dependencies: + is-extglob "^1.0.0" + +is-glob@^3.1.0: + version "3.1.0" + resolved "https://registry.npmmirror.com/is-glob/download/is-glob-3.1.0.tgz#7ba5ae24217804ac70707b96922567486cc3e84a" + integrity sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo= + dependencies: + is-extglob "^2.1.0" + +is-glob@^4.0.0, is-glob@^4.0.1, is-glob@^4.0.3, is-glob@~4.0.1: + version "4.0.3" + resolved "https://registry.npmmirror.com/is-glob/download/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084" + integrity sha1-ZPYeQsu7LuwgcanawLKLoeZdUIQ= + dependencies: + is-extglob "^2.1.1" + +is-hexadecimal@^1.0.0: + version "1.0.4" + resolved "https://registry.npmmirror.com/is-hexadecimal/download/is-hexadecimal-1.0.4.tgz?cache=0&sync_timestamp=1636011536406&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fis-hexadecimal%2Fdownload%2Fis-hexadecimal-1.0.4.tgz#cc35c97588da4bd49a8eedd6bc4082d44dcb23a7" + integrity sha1-zDXJdYjaS9Saju3WvECC1E3LI6c= + +is-interactive@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/is-interactive/download/is-interactive-1.0.0.tgz#cea6e6ae5c870a7b0a0004070b7b587e0252912e" + integrity sha1-zqbmrlyHCnsKAAQHC3tYfgJSkS4= + +is-invalid-path@^1.0.2: + version "1.0.2" + resolved "https://registry.npm.taobao.org/is-invalid-path/download/is-invalid-path-1.0.2.tgz#2f84731559f4936abcf1b227632719cf45c5dc0e" + integrity sha1-L4RzFVn0k2q88bInYycZz0XF3A4= + +is-negative-zero@^2.0.1: + version "2.0.1" + resolved "https://registry.nlark.com/is-negative-zero/download/is-negative-zero-2.0.1.tgz#3de746c18dda2319241a53675908d8f766f11c24" + integrity sha1-PedGwY3aIxkkGlNnWQjY92bxHCQ= + +is-number-object@^1.0.4: + version "1.0.6" + resolved "https://registry.nlark.com/is-number-object/download/is-number-object-1.0.6.tgz#6a7aaf838c7f0686a50b4553f7e54a96494e89f0" + integrity sha1-anqvg4x/BoalC0VT9+VKlklOifA= + dependencies: + has-tostringtag "^1.0.0" + +is-number@^2.1.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/is-number/download/is-number-2.1.0.tgz#01fcbbb393463a548f2f466cce16dece49db908f" + integrity sha1-Afy7s5NGOlSPL0ZszhbezknbkI8= + dependencies: + kind-of "^3.0.2" + +is-number@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/is-number/download/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195" + integrity sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU= + dependencies: + kind-of "^3.0.2" + +is-number@^4.0.0: + version "4.0.0" + resolved "https://registry.npm.taobao.org/is-number/download/is-number-4.0.0.tgz#0026e37f5454d73e356dfe6564699867c6a7f0ff" + integrity sha1-ACbjf1RU1z41bf5lZGmYZ8an8P8= + +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.npm.taobao.org/is-number/download/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" + integrity sha1-dTU0W4lnNNX4DE0GxQlVUnoU8Ss= + +is-obj@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/is-obj/download/is-obj-2.0.0.tgz#473fb05d973705e3fd9620545018ca8e22ef4982" + integrity sha1-Rz+wXZc3BeP9liBUUBjKjiLvSYI= + +is-path-cwd@^2.0.0: + version "2.2.0" + resolved "https://registry.nlark.com/is-path-cwd/download/is-path-cwd-2.2.0.tgz?cache=0&sync_timestamp=1628686555851&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-path-cwd%2Fdownload%2Fis-path-cwd-2.2.0.tgz#67d43b82664a7b5191fd9119127eb300048a9fdb" + integrity sha1-Z9Q7gmZKe1GR/ZEZEn6zAASKn9s= + +is-path-in-cwd@^2.0.0: + version "2.1.0" + resolved "https://registry.nlark.com/is-path-in-cwd/download/is-path-in-cwd-2.1.0.tgz?cache=0&sync_timestamp=1620047110449&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-path-in-cwd%2Fdownload%2Fis-path-in-cwd-2.1.0.tgz#bfe2dca26c69f397265a4009963602935a053acb" + integrity sha1-v+Lcomxp85cmWkAJljYCk1oFOss= + dependencies: + is-path-inside "^2.1.0" + +is-path-inside@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/is-path-inside/download/is-path-inside-2.1.0.tgz?cache=0&sync_timestamp=1620046845369&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-path-inside%2Fdownload%2Fis-path-inside-2.1.0.tgz#7c9810587d659a40d27bcdb4d5616eab059494b2" + integrity sha1-fJgQWH1lmkDSe8201WFuqwWUlLI= + dependencies: + path-is-inside "^1.0.2" + +is-plain-obj@^1.0.0, is-plain-obj@^1.1.0: + version "1.1.0" + resolved "https://registry.npm.taobao.org/is-plain-obj/download/is-plain-obj-1.1.0.tgz?cache=0&sync_timestamp=1618600489644&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fis-plain-obj%2Fdownload%2Fis-plain-obj-1.1.0.tgz#71a50c8429dfca773c92a390a4a03b39fcd51d3e" + integrity sha1-caUMhCnfync8kqOQpKA7OfzVHT4= + +is-plain-object@^2.0.3, is-plain-object@^2.0.4: + version "2.0.4" + resolved "https://registry.nlark.com/is-plain-object/download/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" + integrity sha1-LBY7P6+xtgbZ0Xko8FwqHDjgdnc= + dependencies: + isobject "^3.0.1" + +is-posix-bracket@^0.1.0: + version "0.1.1" + resolved "https://registry.nlark.com/is-posix-bracket/download/is-posix-bracket-0.1.1.tgz#3334dc79774368e92f016e6fbc0a88f5cd6e6bc4" + integrity sha1-MzTceXdDaOkvAW5vvAqI9c1ua8Q= + +is-primitive@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/is-primitive/download/is-primitive-2.0.0.tgz#207bab91638499c07b2adf240a41a87210034575" + integrity sha1-IHurkWOEmcB7Kt8kCkGochADRXU= + +is-promise@^2.1.0: + version "2.2.2" + resolved "https://registry.nlark.com/is-promise/download/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1" + integrity sha1-OauVnMv5p3TPB597QMeib3YxNfE= + +is-regex@^1.0.4, is-regex@^1.1.4: + version "1.1.4" + resolved "https://registry.nlark.com/is-regex/download/is-regex-1.1.4.tgz?cache=0&sync_timestamp=1628221905423&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-regex%2Fdownload%2Fis-regex-1.1.4.tgz#eef5663cd59fa4c0ae339505323df6854bb15958" + integrity sha1-7vVmPNWfpMCuM5UFMj32hUuxWVg= + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-regexp@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/is-regexp/download/is-regexp-1.0.0.tgz#fd2d883545c46bac5a633e7b9a09e87fa2cb5069" + integrity sha1-/S2INUXEa6xaYz57mgnof6LLUGk= + +is-shared-array-buffer@^1.0.1: + version "1.0.1" + resolved "https://registry.npmmirror.com/is-shared-array-buffer/download/is-shared-array-buffer-1.0.1.tgz#97b0c85fbdacb59c9c446fe653b82cf2b5b7cfe6" + integrity sha1-l7DIX72stZycRG/mU7gs8rW3z+Y= + +is-stream@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/is-stream/download/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" + integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= + +is-string@^1.0.5, is-string@^1.0.7: + version "1.0.7" + resolved "https://registry.nlark.com/is-string/download/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" + integrity sha1-DdEr8gBvJVu1j2lREO/3SR7rwP0= + dependencies: + has-tostringtag "^1.0.0" + +is-supported-regexp-flag@^1.0.0: + version "1.0.1" + resolved "https://registry.nlark.com/is-supported-regexp-flag/download/is-supported-regexp-flag-1.0.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-supported-regexp-flag%2Fdownload%2Fis-supported-regexp-flag-1.0.1.tgz#21ee16518d2c1dd3edd3e9a0d57e50207ac364ca" + integrity sha1-Ie4WUY0sHdPt0+mg1X5QIHrDZMo= + +is-symbol@^1.0.2, is-symbol@^1.0.3: + version "1.0.4" + resolved "https://registry.nlark.com/is-symbol/download/is-symbol-1.0.4.tgz?cache=0&sync_timestamp=1620501174327&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-symbol%2Fdownload%2Fis-symbol-1.0.4.tgz#a6dac93b635b063ca6872236de88910a57af139c" + integrity sha1-ptrJO2NbBjymhyI23oiRClevE5w= + dependencies: + has-symbols "^1.0.2" + +is-typedarray@~1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/is-typedarray/download/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" + integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= + +is-utf8@^0.2.0: + version "0.2.1" + resolved "https://registry.npm.taobao.org/is-utf8/download/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72" + integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI= + +is-weakref@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/is-weakref/download/is-weakref-1.0.1.tgz#842dba4ec17fa9ac9850df2d6efbc1737274f2a2" + integrity sha1-hC26TsF/qayYUN8tbvvBc3J08qI= + dependencies: + call-bind "^1.0.0" + +is-what@^3.12.0: + version "3.14.1" + resolved "https://registry.npmmirror.com/is-what/download/is-what-3.14.1.tgz?cache=0&sync_timestamp=1634283360064&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fis-what%2Fdownload%2Fis-what-3.14.1.tgz#e1222f46ddda85dead0fd1c9df131760e77755c1" + integrity sha1-4SIvRt3ahd6tD9HJ3xMXYOd3VcE= + +is-whitespace-character@^1.0.0: + version "1.0.4" + resolved "https://registry.npmmirror.com/is-whitespace-character/download/is-whitespace-character-1.0.4.tgz#0858edd94a95594c7c9dd0b5c174ec6e45ee4aa7" + integrity sha1-CFjt2UqVWUx8ndC1wXTsbkXuSqc= + +is-windows@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/is-windows/download/is-windows-1.0.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fis-windows%2Fdownload%2Fis-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" + integrity sha1-0YUOuXkezRjmGCzhKjDzlmNLsZ0= + +is-word-character@^1.0.0: + version "1.0.4" + resolved "https://registry.npmmirror.com/is-word-character/download/is-word-character-1.0.4.tgz?cache=0&sync_timestamp=1636011535947&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fis-word-character%2Fdownload%2Fis-word-character-1.0.4.tgz#ce0e73216f98599060592f62ff31354ddbeb0230" + integrity sha1-zg5zIW+YWZBgWS9i/zE1TdvrAjA= + +is-wsl@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/is-wsl/download/is-wsl-1.1.0.tgz#1f16e4aa22b04d1336b66188a66af3c600c3a66d" + integrity sha1-HxbkqiKwTRM2tmGIpmrzxgDDpm0= + +is-wsl@^2.1.1: + version "2.2.0" + resolved "https://registry.nlark.com/is-wsl/download/is-wsl-2.2.0.tgz#74a4c76e77ca9fd3f932f290c17ea326cd157271" + integrity sha1-dKTHbnfKn9P5MvKQwX6jJs0VcnE= + dependencies: + is-docker "^2.0.0" + +isarray@0.0.1: + version "0.0.1" + resolved "https://registry.npm.taobao.org/isarray/download/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" + integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= + +isarray@1.0.0, isarray@^1.0.0, isarray@~1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/isarray/download/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" + integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= + +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/isexe/download/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= + +isobject@^2.0.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/isobject/download/isobject-2.1.0.tgz#f065561096a3f1da2ef46272f815c840d87e0c89" + integrity sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk= + dependencies: + isarray "1.0.0" + +isobject@^3.0.0, isobject@^3.0.1: + version "3.0.1" + resolved "https://registry.npm.taobao.org/isobject/download/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" + integrity sha1-TkMekrEalzFjaqH5yNHMvP2reN8= + +isstream@~0.1.2: + version "0.1.2" + resolved "https://registry.nlark.com/isstream/download/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" + integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= + +j-component@^1.4.4: + version "1.4.4" + resolved "https://registry.nlark.com/j-component/download/j-component-1.4.4.tgz?cache=0&sync_timestamp=1629881307677&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fj-component%2Fdownload%2Fj-component-1.4.4.tgz#f9b46db2fe67b57b6637e70b007d9d9504a89553" + integrity sha1-+bRtsv5ntXtmN+cLAH2dlQSolVM= + dependencies: + expr-parser "^1.0.0" + miniprogram-api-typings "^3.2.2" + miniprogram-exparser "2.15.0" + +javascript-stringify@^1.6.0: + version "1.6.0" + resolved "https://registry.npm.taobao.org/javascript-stringify/download/javascript-stringify-1.6.0.tgz#142d111f3a6e3dae8f4a9afd77d45855b5a9cce3" + integrity sha1-FC0RHzpuPa6PSpr9d9RYVbWpzOM= + +jest-worker@^26.2.1, jest-worker@^26.5.0: + version "26.6.2" + resolved "https://registry.npmmirror.com/jest-worker/download/jest-worker-26.6.2.tgz?cache=0&sync_timestamp=1634626737887&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fjest-worker%2Fdownload%2Fjest-worker-26.6.2.tgz#7f72cbc4d643c365e27b9fd775f9d0eaa9c7a8ed" + integrity sha1-f3LLxNZDw2Xie5/XdfnQ6qnHqO0= + dependencies: + "@types/node" "*" + merge-stream "^2.0.0" + supports-color "^7.0.0" + +js-base64@^2.1.8, js-base64@^2.1.9: + version "2.6.4" + resolved "https://registry.npmmirror.com/js-base64/download/js-base64-2.6.4.tgz#f4e686c5de1ea1f867dbcad3d46d969428df98c4" + integrity sha1-9OaGxd4eofhn28rT1G2WlCjfmMQ= + +"js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/js-tokens/download/js-tokens-4.0.0.tgz?cache=0&sync_timestamp=1619345098261&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fjs-tokens%2Fdownload%2Fjs-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha1-GSA/tZmR35jjoocFDUZHzerzJJk= + +js-yaml@^3.13.1: + version "3.14.1" + resolved "https://registry.npm.taobao.org/js-yaml/download/js-yaml-3.14.1.tgz?cache=0&sync_timestamp=1618435004368&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fjs-yaml%2Fdownload%2Fjs-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" + integrity sha1-2ugS/bOCX6MGYJqHFzg8UMNqBTc= + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + +jsbn@~0.1.0: + version "0.1.1" + resolved "https://registry.nlark.com/jsbn/download/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" + integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= + +jsdom@^15.2.1: + version "15.2.1" + resolved "https://registry.npmmirror.com/jsdom/download/jsdom-15.2.1.tgz#d2feb1aef7183f86be521b8c6833ff5296d07ec5" + integrity sha1-0v6xrvcYP4a+UhuMaDP/UpbQfsU= + dependencies: + abab "^2.0.0" + acorn "^7.1.0" + acorn-globals "^4.3.2" + array-equal "^1.0.0" + cssom "^0.4.1" + cssstyle "^2.0.0" + data-urls "^1.1.0" + domexception "^1.0.1" + escodegen "^1.11.1" + html-encoding-sniffer "^1.0.2" + nwsapi "^2.2.0" + parse5 "5.1.0" + pn "^1.1.0" + request "^2.88.0" + request-promise-native "^1.0.7" + saxes "^3.1.9" + symbol-tree "^3.2.2" + tough-cookie "^3.0.1" + w3c-hr-time "^1.0.1" + w3c-xmlserializer "^1.1.2" + webidl-conversions "^4.0.2" + whatwg-encoding "^1.0.5" + whatwg-mimetype "^2.3.0" + whatwg-url "^7.0.0" + ws "^7.0.0" + xml-name-validator "^3.0.0" + +jsesc@^2.5.1: + version "2.5.2" + resolved "https://registry.nlark.com/jsesc/download/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" + integrity sha1-gFZNLkg9rPbo7yCWUKZ98/DCg6Q= + +jsesc@~0.5.0: + version "0.5.0" + resolved "https://registry.nlark.com/jsesc/download/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" + integrity sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0= + +jshint@^2.13.1: + version "2.13.1" + resolved "https://registry.nlark.com/jshint/download/jshint-2.13.1.tgz?cache=0&sync_timestamp=1628642106255&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fjshint%2Fdownload%2Fjshint-2.13.1.tgz#16bbbecdbb4564d3758d9de4f24926f8c7f8f835" + integrity sha1-Fru+zbtFZNN1jZ3k8kkm+Mf4+DU= + dependencies: + cli "~1.0.0" + console-browserify "1.1.x" + exit "0.1.x" + htmlparser2 "3.8.x" + lodash "~4.17.21" + minimatch "~3.0.2" + shelljs "0.3.x" + strip-json-comments "1.0.x" + +json-parse-better-errors@^1.0.1, json-parse-better-errors@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/json-parse-better-errors/download/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" + integrity sha1-u4Z8+zRQ5pEHwTHRxRS6s9yLyqk= + +json-parse-even-better-errors@^2.3.0: + version "2.3.1" + resolved "https://registry.nlark.com/json-parse-even-better-errors/download/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" + integrity sha1-fEeAWpQxmSjgV3dAXcEuH3pO4C0= + +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.nlark.com/json-schema-traverse/download/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + integrity sha1-afaofZUTq4u4/mO9sJecRI5oRmA= + +json-schema@0.2.3: + version "0.2.3" + resolved "https://registry.npm.taobao.org/json-schema/download/json-schema-0.2.3.tgz?cache=0&sync_timestamp=1609553637722&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fjson-schema%2Fdownload%2Fjson-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" + integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= + +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/json-stable-stringify-without-jsonify/download/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= + +json-stringify-safe@~5.0.1: + version "5.0.1" + resolved "https://registry.npm.taobao.org/json-stringify-safe/download/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" + integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= + +json3@^3.3.2: + version "3.3.3" + resolved "https://registry.npmmirror.com/json3/download/json3-3.3.3.tgz#7fc10e375fc5ae42c4705a5cc0aa6f62be305b81" + integrity sha1-f8EON1/FrkLEcFpcwKpvYr4wW4E= + +json5@^0.5.0: + version "0.5.1" + resolved "https://registry.nlark.com/json5/download/json5-0.5.1.tgz#1eade7acc012034ad84e2396767ead9fa5495821" + integrity sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE= + +json5@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/json5/download/json5-1.0.1.tgz#779fb0018604fa854eacbf6252180d83543e3dbe" + integrity sha1-d5+wAYYE+oVOrL9iUhgNg1Q+Pb4= + dependencies: + minimist "^1.2.0" + +json5@^2.1.2: + version "2.2.0" + resolved "https://registry.nlark.com/json5/download/json5-2.2.0.tgz#2dfefe720c6ba525d9ebd909950f0515316c89a3" + integrity sha1-Lf7+cgxrpSXZ69kJlQ8FFTFsiaM= + dependencies: + minimist "^1.2.5" + +jsonfile@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/jsonfile/download/jsonfile-4.0.0.tgz#8771aae0799b64076b76640fca058f9c10e33ecb" + integrity sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss= + optionalDependencies: + graceful-fs "^4.1.6" + +jsonp-retry@^1.0.3: + version "1.0.3" + resolved "https://registry.npm.taobao.org/jsonp-retry/download/jsonp-retry-1.0.3.tgz#9e6b18b02ec767a621dd44b4e99439a8a43a6419" + integrity sha1-nmsYsC7HZ6Yh3US06ZQ5qKQ6ZBk= + dependencies: + object-assign "^4.1.1" + +jsprim@^1.2.2: + version "1.4.1" + resolved "https://registry.npmmirror.com/jsprim/download/jsprim-1.4.1.tgz?cache=0&sync_timestamp=1635970868806&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fjsprim%2Fdownload%2Fjsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" + integrity sha1-MT5mvB5cwG5Di8G3SZwuXFastqI= + dependencies: + assert-plus "1.0.0" + extsprintf "1.3.0" + json-schema "0.2.3" + verror "1.10.0" + +"jsx-ast-utils@^2.4.1 || ^3.0.0": + version "3.2.1" + resolved "https://registry.nlark.com/jsx-ast-utils/download/jsx-ast-utils-3.2.1.tgz?cache=0&sync_timestamp=1631856190709&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fjsx-ast-utils%2Fdownload%2Fjsx-ast-utils-3.2.1.tgz#720b97bfe7d901b927d87c3773637ae8ea48781b" + integrity sha1-cguXv+fZAbkn2Hw3c2N66OpIeBs= + dependencies: + array-includes "^3.1.3" + object.assign "^4.1.2" + +killable@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/killable/download/killable-1.0.1.tgz#4c8ce441187a061c7474fb87ca08e2a638194892" + integrity sha1-TIzkQRh6Bhx0dPuHygjipjgZSJI= + +kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: + version "3.2.2" + resolved "https://registry.nlark.com/kind-of/download/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" + integrity sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ= + dependencies: + is-buffer "^1.1.5" + +kind-of@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/kind-of/download/kind-of-4.0.0.tgz#20813df3d712928b207378691a45066fae72dd57" + integrity sha1-IIE989cSkosgc3hpGkUGb65y3Vc= + dependencies: + is-buffer "^1.1.5" + +kind-of@^5.0.0: + version "5.1.0" + resolved "https://registry.nlark.com/kind-of/download/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" + integrity sha1-cpyR4thXt6QZofmqZWhcTDP1hF0= + +kind-of@^6.0.0, kind-of@^6.0.2: + version "6.0.3" + resolved "https://registry.nlark.com/kind-of/download/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" + integrity sha1-B8BQNKbDSfoG4k+jWqdttFgM5N0= + +kleur@^3.0.0: + version "3.0.3" + resolved "https://registry.nlark.com/kleur/download/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" + integrity sha1-p5yezIbuHOP6YgbRIWxQHxR/wH4= + +klona@^2.0.4: + version "2.0.5" + resolved "https://registry.npmmirror.com/klona/download/klona-2.0.5.tgz?cache=0&sync_timestamp=1635385383825&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fklona%2Fdownload%2Fklona-2.0.5.tgz#d166574d90076395d9963aa7a928fabb8d76afbc" + integrity sha1-0WZXTZAHY5XZljqnqSj6u412r7w= + +known-css-properties@^0.6.0: + version "0.6.1" + resolved "https://registry.nlark.com/known-css-properties/download/known-css-properties-0.6.1.tgz#31b5123ad03d8d1a3f36bd4155459c981173478b" + integrity sha1-MbUSOtA9jRo/Nr1BVUWcmBFzR4s= + +less-loader@7.3.0: + version "7.3.0" + resolved "https://registry.npmmirror.com/less-loader/download/less-loader-7.3.0.tgz?cache=0&sync_timestamp=1634563244377&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fless-loader%2Fdownload%2Fless-loader-7.3.0.tgz#f9d6d36d18739d642067a05fb5bd70c8c61317e5" + integrity sha1-+dbTbRhznWQgZ6Bftb1wyMYTF+U= + dependencies: + klona "^2.0.4" + loader-utils "^2.0.0" + schema-utils "^3.0.0" + +less@^3.10.3: + version "3.13.1" + resolved "https://registry.npmmirror.com/less/download/less-3.13.1.tgz?cache=0&sync_timestamp=1633303651089&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fless%2Fdownload%2Fless-3.13.1.tgz#0ebc91d2a0e9c0c6735b83d496b0ab0583077909" + integrity sha1-DryR0qDpwMZzW4PUlrCrBYMHeQk= + dependencies: + copy-anything "^2.0.1" + tslib "^1.10.0" + optionalDependencies: + errno "^0.1.1" + graceful-fs "^4.1.2" + image-size "~0.5.0" + make-dir "^2.1.0" + mime "^1.4.1" + native-request "^1.0.5" + source-map "~0.6.0" + +less@^4.1.0: + version "4.1.2" + resolved "https://registry.npmmirror.com/less/download/less-4.1.2.tgz?cache=0&sync_timestamp=1633303651089&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fless%2Fdownload%2Fless-4.1.2.tgz#6099ee584999750c2624b65f80145f8674e4b4b0" + integrity sha1-YJnuWEmZdQwmJLZfgBRfhnTktLA= + dependencies: + copy-anything "^2.0.1" + parse-node-version "^1.0.1" + tslib "^2.3.0" + optionalDependencies: + errno "^0.1.1" + graceful-fs "^4.1.2" + image-size "~0.5.0" + make-dir "^2.1.0" + mime "^1.4.1" + needle "^2.5.2" + source-map "~0.6.0" + +leven@^3.1.0: + version "3.1.0" + resolved "https://registry.nlark.com/leven/download/leven-3.1.0.tgz?cache=0&sync_timestamp=1628597917913&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fleven%2Fdownload%2Fleven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2" + integrity sha1-d4kd6DQGTMy6gq54QrtrFKE+1/I= + +levenary@^1.1.1: + version "1.1.1" + resolved "https://registry.npm.taobao.org/levenary/download/levenary-1.1.1.tgz#842a9ee98d2075aa7faeedbe32679e9205f46f77" + integrity sha1-hCqe6Y0gdap/ru2+MmeekgX0b3c= + dependencies: + leven "^3.1.0" + +levn@^0.3.0, levn@~0.3.0: + version "0.3.0" + resolved "https://registry.npm.taobao.org/levn/download/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" + integrity sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4= + dependencies: + prelude-ls "~1.1.2" + type-check "~0.3.2" + +linaria@^3.0.0-beta.17: + version "3.0.0-beta.17" + resolved "https://registry.npmmirror.com/linaria/-/linaria-3.0.0-beta.17.tgz#b9aef04e4dc2115e9c3d7fb8a8bcb8a329683efe" + integrity sha512-RJnt5o03w9ITOAgfsZ38a2LqupQCnOufP6IeNcRdtC+mLVuxEFQjLOY84b7vOWTSTG5I6qnckuqRrvihOeUR3g== + dependencies: + "@linaria/babel-preset" "^3.0.0-beta.17" + "@linaria/core" "^3.0.0-beta.15" + "@linaria/extractor" "^3.0.0-beta.17" + "@linaria/react" "^3.0.0-beta.17" + "@linaria/rollup" "^3.0.0-beta.17" + "@linaria/server" "^3.0.0-beta.13" + "@linaria/shaker" "^3.0.0-beta.17" + "@linaria/stylelint" "^3.0.0-beta.17" + "@linaria/webpack4-loader" "^3.0.0-beta.17" + +lines-and-columns@^1.1.6: + version "1.1.6" + resolved "https://registry.nlark.com/lines-and-columns/download/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00" + integrity sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA= + +load-json-file@^1.0.0: + version "1.1.0" + resolved "https://registry.nlark.com/load-json-file/download/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" + integrity sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA= + dependencies: + graceful-fs "^4.1.2" + parse-json "^2.2.0" + pify "^2.0.0" + pinkie-promise "^2.0.0" + strip-bom "^2.0.0" + +load-json-file@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/load-json-file/download/load-json-file-4.0.0.tgz#2f5f45ab91e33216234fd53adab668eb4ec0993b" + integrity sha1-L19Fq5HjMhYjT9U62rZo607AmTs= + dependencies: + graceful-fs "^4.1.2" + parse-json "^4.0.0" + pify "^3.0.0" + strip-bom "^3.0.0" + +loader-runner@^2.4.0: + version "2.4.0" + resolved "https://registry.nlark.com/loader-runner/download/loader-runner-2.4.0.tgz#ed47066bfe534d7e84c4c7b9998c2a75607d9357" + integrity sha1-7UcGa/5TTX6ExMe5mYwqdWB9k1c= + +loader-utils@1.2.3: + version "1.2.3" + resolved "https://registry.npmmirror.com/loader-utils/download/loader-utils-1.2.3.tgz?cache=0&sync_timestamp=1636039915957&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Floader-utils%2Fdownload%2Floader-utils-1.2.3.tgz#1ff5dc6911c9f0a062531a4c04b609406108c2c7" + integrity sha1-H/XcaRHJ8KBiUxpMBLYJQGEIwsc= + dependencies: + big.js "^5.2.2" + emojis-list "^2.0.0" + json5 "^1.0.1" + +loader-utils@^0.2.16: + version "0.2.17" + resolved "https://registry.npmmirror.com/loader-utils/download/loader-utils-0.2.17.tgz?cache=0&sync_timestamp=1636039915957&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Floader-utils%2Fdownload%2Floader-utils-0.2.17.tgz#f86e6374d43205a6e6c60e9196f17c0299bfb348" + integrity sha1-+G5jdNQyBabmxg6RlvF8Apm/s0g= + dependencies: + big.js "^3.1.3" + emojis-list "^2.0.0" + json5 "^0.5.0" + object-assign "^4.0.1" + +loader-utils@^1.0.2, loader-utils@^1.1.0, loader-utils@^1.2.3, loader-utils@^1.4.0: + version "1.4.0" + resolved "https://registry.npmmirror.com/loader-utils/download/loader-utils-1.4.0.tgz?cache=0&sync_timestamp=1636039915957&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Floader-utils%2Fdownload%2Floader-utils-1.4.0.tgz#c579b5e34cb34b1a74edc6c1fb36bfa371d5a613" + integrity sha1-xXm140yzSxp07cbB+za/o3HVphM= + dependencies: + big.js "^5.2.2" + emojis-list "^3.0.0" + json5 "^1.0.1" + +loader-utils@^2.0.0: + version "2.0.2" + resolved "https://registry.npmmirror.com/loader-utils/download/loader-utils-2.0.2.tgz?cache=0&sync_timestamp=1636039915957&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Floader-utils%2Fdownload%2Floader-utils-2.0.2.tgz#d6e3b4fb81870721ae4e0868ab11dd638368c129" + integrity sha1-1uO0+4GHByGuTghoqxHdY4NowSk= + dependencies: + big.js "^5.2.2" + emojis-list "^3.0.0" + json5 "^2.1.2" + +locate-path@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/locate-path/download/locate-path-2.0.0.tgz?cache=0&sync_timestamp=1629895724478&other_urls=https%3A%2F%2Fregistry.nlark.com%2Flocate-path%2Fdownload%2Flocate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e" + integrity sha1-K1aLJl7slExtnA3pw9u7ygNUzY4= + dependencies: + p-locate "^2.0.0" + path-exists "^3.0.0" + +locate-path@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/locate-path/download/locate-path-3.0.0.tgz?cache=0&sync_timestamp=1629895724478&other_urls=https%3A%2F%2Fregistry.nlark.com%2Flocate-path%2Fdownload%2Flocate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" + integrity sha1-2+w7OrdZdYBxtY/ln8QYca8hQA4= + dependencies: + p-locate "^3.0.0" + path-exists "^3.0.0" + +locate-path@^5.0.0: + version "5.0.0" + resolved "https://registry.nlark.com/locate-path/download/locate-path-5.0.0.tgz?cache=0&sync_timestamp=1629895724478&other_urls=https%3A%2F%2Fregistry.nlark.com%2Flocate-path%2Fdownload%2Flocate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" + integrity sha1-Gvujlq/WdqbUJQTQpno6frn2KqA= + dependencies: + p-locate "^4.1.0" + +lodash-es@4.17.15: + version "4.17.15" + resolved "https://registry.npm.taobao.org/lodash-es/download/lodash-es-4.17.15.tgz?cache=0&sync_timestamp=1613835893273&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Flodash-es%2Fdownload%2Flodash-es-4.17.15.tgz#21bd96839354412f23d7a10340e5eac6ee455d78" + integrity sha1-Ib2Wg5NUQS8j16EDQOXqxu5FXXg= + +lodash-webpack-plugin@^0.11.6: + version "0.11.6" + resolved "https://registry.npm.taobao.org/lodash-webpack-plugin/download/lodash-webpack-plugin-0.11.6.tgz#8204c6b78beb62ce5211217dfe783c21557ecd33" + integrity sha1-ggTGt4vrYs5SESF9/ng8IVV+zTM= + dependencies: + lodash "^4.17.20" + +lodash.clonedeep@^4.5.0: + version "4.5.0" + resolved "https://registry.npm.taobao.org/lodash.clonedeep/download/lodash.clonedeep-4.5.0.tgz?cache=0&sync_timestamp=1599054271708&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Flodash.clonedeep%2Fdownload%2Flodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" + integrity sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8= + +lodash.debounce@^4.0.8: + version "4.0.8" + resolved "https://registry.npm.taobao.org/lodash.debounce/download/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af" + integrity sha1-gteb/zCmfEAF/9XiUVMArZyk168= + +lodash.kebabcase@^4.1.1: + version "4.1.1" + resolved "https://registry.nlark.com/lodash.kebabcase/download/lodash.kebabcase-4.1.1.tgz#8489b1cb0d29ff88195cceca448ff6d6cc295c36" + integrity sha1-hImxyw0p/4gZXM7KRI/21swpXDY= + +lodash.sortby@^4.7.0: + version "4.7.0" + resolved "https://registry.npm.taobao.org/lodash.sortby/download/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438" + integrity sha1-7dFMgk4sycHgsKG0K7UhBRakJDg= + +lodash@4.17.19: + version "4.17.19" + resolved "https://registry.nlark.com/lodash/download/lodash-4.17.19.tgz?cache=0&sync_timestamp=1624543041613&other_urls=https%3A%2F%2Fregistry.nlark.com%2Flodash%2Fdownload%2Flodash-4.17.19.tgz#e48ddedbe30b3321783c5b4301fbd353bc1e4a4b" + integrity sha1-5I3e2+MLMyF4PFtDAfvTU7weSks= + +lodash@4.17.21, lodash@^4.0.0, lodash@^4.17.11, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.17.3, lodash@^4.17.4, lodash@~4.17.10, lodash@~4.17.21: + version "4.17.21" + resolved "https://registry.nlark.com/lodash/download/lodash-4.17.21.tgz?cache=0&sync_timestamp=1624543041613&other_urls=https%3A%2F%2Fregistry.nlark.com%2Flodash%2Fdownload%2Flodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" + integrity sha1-Z5WRxWTDv/quhFTPCz3zcMPWkRw= + +log-symbols@^2.0.0, log-symbols@^2.2.0: + version "2.2.0" + resolved "https://registry.nlark.com/log-symbols/download/log-symbols-2.2.0.tgz?cache=0&sync_timestamp=1618847128438&other_urls=https%3A%2F%2Fregistry.nlark.com%2Flog-symbols%2Fdownload%2Flog-symbols-2.2.0.tgz#5740e1c5d6f0dfda4ad9323b5332107ef6b4c40a" + integrity sha1-V0Dhxdbw39pK2TI7UzIQfva0xAo= + dependencies: + chalk "^2.0.1" + +log-symbols@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/log-symbols/download/log-symbols-3.0.0.tgz?cache=0&sync_timestamp=1618847128438&other_urls=https%3A%2F%2Fregistry.nlark.com%2Flog-symbols%2Fdownload%2Flog-symbols-3.0.0.tgz#f3a08516a5dea893336a7dee14d18a1cfdab77c4" + integrity sha1-86CFFqXeqJMzan3uFNGKHP2rd8Q= + dependencies: + chalk "^2.4.2" + +loglevel-plugin-prefix@^0.8.4: + version "0.8.4" + resolved "https://registry.npm.taobao.org/loglevel-plugin-prefix/download/loglevel-plugin-prefix-0.8.4.tgz#2fe0e05f1a820317d98d8c123e634c1bd84ff644" + integrity sha1-L+DgXxqCAxfZjYwSPmNMG9hP9kQ= + +loglevel@^1.6.6, loglevel@^1.6.8, loglevel@^1.7.1: + version "1.7.1" + resolved "https://registry.nlark.com/loglevel/download/loglevel-1.7.1.tgz#005fde2f5e6e47068f935ff28573e125ef72f197" + integrity sha1-AF/eL15uRwaPk1/yhXPhJe9y8Zc= + +longest-streak@^2.0.1: + version "2.0.4" + resolved "https://registry.npm.taobao.org/longest-streak/download/longest-streak-2.0.4.tgz#b8599957da5b5dab64dee3fe316fa774597d90e4" + integrity sha1-uFmZV9pbXatk3uP+MW+ndFl9kOQ= + +loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0: + version "1.4.0" + resolved "https://registry.nlark.com/loose-envify/download/loose-envify-1.4.0.tgz#71ee51fa7be4caec1a63839f7e682d8132d30caf" + integrity sha1-ce5R+nvkyuwaY4OffmgtgTLTDK8= + dependencies: + js-tokens "^3.0.0 || ^4.0.0" + +loud-rejection@^1.0.0: + version "1.6.0" + resolved "https://registry.nlark.com/loud-rejection/download/loud-rejection-1.6.0.tgz#5b46f80147edee578870f086d04821cf998e551f" + integrity sha1-W0b4AUft7leIcPCG0Eghz5mOVR8= + dependencies: + currently-unhandled "^0.4.1" + signal-exit "^3.0.0" + +lower-case@^1.1.1: + version "1.1.4" + resolved "https://registry.nlark.com/lower-case/download/lower-case-1.1.4.tgz#9a2cabd1b9e8e0ae993a4bf7d5875c39c42e8eac" + integrity sha1-miyr0bno4K6ZOkv31YdcOcQujqw= + +lru-cache@^4.0.1: + version "4.1.5" + resolved "https://registry.nlark.com/lru-cache/download/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" + integrity sha1-i75Q6oW+1ZvJ4z3KuCNe6bz0Q80= + dependencies: + pseudomap "^1.0.2" + yallist "^2.1.2" + +lru-cache@^5.1.1: + version "5.1.1" + resolved "https://registry.nlark.com/lru-cache/download/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" + integrity sha1-HaJ+ZxAnGUdpXa9oSOhH8B2EuSA= + dependencies: + yallist "^3.0.2" + +lru-cache@^6.0.0: + version "6.0.0" + resolved "https://registry.nlark.com/lru-cache/download/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" + integrity sha1-bW/mVw69lqr5D8rR2vo7JWbbOpQ= + dependencies: + yallist "^4.0.0" + +make-dir@^2.0.0, make-dir@^2.1.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/make-dir/download/make-dir-2.1.0.tgz#5f0310e18b8be898cc07009295a30ae41e91e6f5" + integrity sha1-XwMQ4YuL6JjMBwCSlaMK5B6R5vU= + dependencies: + pify "^4.0.1" + semver "^5.6.0" + +make-dir@^3.0.2: + version "3.1.0" + resolved "https://registry.npm.taobao.org/make-dir/download/make-dir-3.1.0.tgz#415e967046b3a7f1d185277d84aa58203726a13f" + integrity sha1-QV6WcEazp/HRhSd9hKpYIDcmoT8= + dependencies: + semver "^6.0.0" + +map-cache@^0.2.2: + version "0.2.2" + resolved "https://registry.nlark.com/map-cache/download/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" + integrity sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8= + +map-obj@^1.0.0, map-obj@^1.0.1: + version "1.0.1" + resolved "https://registry.npmmirror.com/map-obj/download/map-obj-1.0.1.tgz?cache=0&sync_timestamp=1634552719803&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fmap-obj%2Fdownload%2Fmap-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" + integrity sha1-2TPOuSBdgr3PSIb2dCvcK03qFG0= + +map-obj@^2.0.0: + version "2.0.0" + resolved "https://registry.npmmirror.com/map-obj/download/map-obj-2.0.0.tgz?cache=0&sync_timestamp=1634552719803&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fmap-obj%2Fdownload%2Fmap-obj-2.0.0.tgz#a65cd29087a92598b8791257a523e021222ac1f9" + integrity sha1-plzSkIepJZi4eRJXpSPgISIqwfk= + +map-visit@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/map-visit/download/map-visit-1.0.0.tgz#ecdca8f13144e660f1b5bd41f12f3479d98dfb8f" + integrity sha1-7Nyo8TFE5mDxtb1B8S80edmN+48= + dependencies: + object-visit "^1.0.0" + +markdown-escapes@^1.0.0: + version "1.0.4" + resolved "https://registry.npmmirror.com/markdown-escapes/download/markdown-escapes-1.0.4.tgz?cache=0&sync_timestamp=1635887464232&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fmarkdown-escapes%2Fdownload%2Fmarkdown-escapes-1.0.4.tgz#c95415ef451499d7602b91095f3c8e8975f78535" + integrity sha1-yVQV70UUmddgK5EJXzyOiXX3hTU= + +markdown-table@^1.1.0: + version "1.1.3" + resolved "https://registry.nlark.com/markdown-table/download/markdown-table-1.1.3.tgz#9fcb69bcfdb8717bfd0398c6ec2d93036ef8de60" + integrity sha1-n8tpvP24cXv9A5jG7C2TA2743mA= + +math-random@^1.0.1: + version "1.0.4" + resolved "https://registry.npm.taobao.org/math-random/download/math-random-1.0.4.tgz#5dd6943c938548267016d4e34f057583080c514c" + integrity sha1-XdaUPJOFSCZwFtTjTwV1gwgMUUw= + +mathml-tag-names@^2.0.1: + version "2.1.3" + resolved "https://registry.npmmirror.com/mathml-tag-names/download/mathml-tag-names-2.1.3.tgz#4ddadd67308e780cf16a47685878ee27b736a0a3" + integrity sha1-TdrdZzCOeAzxakdoWHjuJ7c2oKM= + +md5.js@^1.3.4: + version "1.3.5" + resolved "https://registry.npm.taobao.org/md5.js/download/md5.js-1.3.5.tgz#b5d07b8e3216e3e27cd728d72f70d1e6a342005f" + integrity sha1-tdB7jjIW4+J81yjXL3DR5qNCAF8= + dependencies: + hash-base "^3.0.0" + inherits "^2.0.1" + safe-buffer "^5.1.2" + +md5@^2.3.0: + version "2.3.0" + resolved "https://registry.npm.taobao.org/md5/download/md5-2.3.0.tgz#c3da9a6aae3a30b46b7b0c349b87b110dc3bda4f" + integrity sha1-w9qaaq46MLRreww0m4exENw72k8= + dependencies: + charenc "0.0.2" + crypt "0.0.2" + is-buffer "~1.1.6" + +mdast-util-compact@^1.0.0: + version "1.0.4" + resolved "https://registry.nlark.com/mdast-util-compact/download/mdast-util-compact-1.0.4.tgz?cache=0&sync_timestamp=1627636001332&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fmdast-util-compact%2Fdownload%2Fmdast-util-compact-1.0.4.tgz#d531bb7667b5123abf20859be086c4d06c894593" + integrity sha1-1TG7dme1Ejq/IIWb4IbE0GyJRZM= + dependencies: + unist-util-visit "^1.1.0" + +mdn-data@2.0.14: + version "2.0.14" + resolved "https://registry.nlark.com/mdn-data/download/mdn-data-2.0.14.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fmdn-data%2Fdownload%2Fmdn-data-2.0.14.tgz#7113fc4281917d63ce29b43446f701e68c25ba50" + integrity sha1-cRP8QoGRfWPOKbQ0RvcB5owlulA= + +mdn-data@~1.1.0: + version "1.1.4" + resolved "https://registry.nlark.com/mdn-data/download/mdn-data-1.1.4.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fmdn-data%2Fdownload%2Fmdn-data-1.1.4.tgz#50b5d4ffc4575276573c4eedb8780812a8419f01" + integrity sha1-ULXU/8RXUnZXPE7tuHgIEqhBnwE= + +media-typer@0.3.0: + version "0.3.0" + resolved "https://registry.nlark.com/media-typer/download/media-typer-0.3.0.tgz#8710d7af0aa626f8fffa1ce00168545263255748" + integrity sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g= + +memory-fs@^0.4.1: + version "0.4.1" + resolved "https://registry.nlark.com/memory-fs/download/memory-fs-0.4.1.tgz#3a9a20b8462523e447cfbc7e8bb80ed667bfc552" + integrity sha1-OpoguEYlI+RHz7x+i7gO1me/xVI= + dependencies: + errno "^0.1.3" + readable-stream "^2.0.1" + +memory-fs@^0.5.0: + version "0.5.0" + resolved "https://registry.nlark.com/memory-fs/download/memory-fs-0.5.0.tgz#324c01288b88652966d161db77838720845a8e3c" + integrity sha1-MkwBKIuIZSlm0WHbd4OHIIRajjw= + dependencies: + errno "^0.1.3" + readable-stream "^2.0.1" + +meow@^3.7.0: + version "3.7.0" + resolved "https://registry.npmmirror.com/meow/download/meow-3.7.0.tgz?cache=0&sync_timestamp=1637477569022&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fmeow%2Fdownload%2Fmeow-3.7.0.tgz#72cb668b425228290abbfa856892587308a801fb" + integrity sha1-cstmi0JSKCkKu/qFaJJYcwioAfs= + dependencies: + camelcase-keys "^2.0.0" + decamelize "^1.1.2" + loud-rejection "^1.0.0" + map-obj "^1.0.1" + minimist "^1.1.3" + normalize-package-data "^2.3.4" + object-assign "^4.0.1" + read-pkg-up "^1.0.1" + redent "^1.0.0" + trim-newlines "^1.0.0" + +meow@^5.0.0: + version "5.0.0" + resolved "https://registry.nlark.com/meow/download/meow-5.0.0.tgz#dfc73d63a9afc714a5e371760eb5c88b91078aa4" + integrity sha1-38c9Y6mvxxSl43F2DrXIi5EHiqQ= + dependencies: + camelcase-keys "^4.0.0" + decamelize-keys "^1.0.0" + loud-rejection "^1.0.0" + minimist-options "^3.0.1" + normalize-package-data "^2.3.4" + read-pkg-up "^3.0.0" + redent "^2.0.0" + trim-newlines "^2.0.0" + yargs-parser "^10.0.0" + +merge-descriptors@1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/merge-descriptors/download/merge-descriptors-1.0.1.tgz#b00aaa556dd8b44568150ec9d1b953f3f90cbb61" + integrity sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E= + +merge-stream@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/merge-stream/download/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" + integrity sha1-UoI2KaFN0AyXcPtq1H3GMQ8sH2A= + +merge2@^1.2.3, merge2@^1.3.0: + version "1.4.1" + resolved "https://registry.npm.taobao.org/merge2/download/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" + integrity sha1-Q2iJL4hekHRVpv19xVwMnUBJkK4= + +methods@~1.1.2: + version "1.1.2" + resolved "https://registry.nlark.com/methods/download/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee" + integrity sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4= + +metro-react-native-babel-preset@^0.66.2: + version "0.66.2" + resolved "https://registry.nlark.com/metro-react-native-babel-preset/download/metro-react-native-babel-preset-0.66.2.tgz#fddebcf413ad4ea617d4f47f7c1da401052de734" + integrity sha1-/d689BOtTqYX1PR/fB2kAQUt5zQ= + dependencies: + "@babel/core" "^7.14.0" + "@babel/plugin-proposal-class-properties" "^7.0.0" + "@babel/plugin-proposal-export-default-from" "^7.0.0" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.0.0" + "@babel/plugin-proposal-object-rest-spread" "^7.0.0" + "@babel/plugin-proposal-optional-catch-binding" "^7.0.0" + "@babel/plugin-proposal-optional-chaining" "^7.0.0" + "@babel/plugin-syntax-dynamic-import" "^7.0.0" + "@babel/plugin-syntax-export-default-from" "^7.0.0" + "@babel/plugin-syntax-flow" "^7.2.0" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.0.0" + "@babel/plugin-syntax-optional-chaining" "^7.0.0" + "@babel/plugin-transform-arrow-functions" "^7.0.0" + "@babel/plugin-transform-async-to-generator" "^7.0.0" + "@babel/plugin-transform-block-scoping" "^7.0.0" + "@babel/plugin-transform-classes" "^7.0.0" + "@babel/plugin-transform-computed-properties" "^7.0.0" + "@babel/plugin-transform-destructuring" "^7.0.0" + "@babel/plugin-transform-exponentiation-operator" "^7.0.0" + "@babel/plugin-transform-flow-strip-types" "^7.0.0" + "@babel/plugin-transform-for-of" "^7.0.0" + "@babel/plugin-transform-function-name" "^7.0.0" + "@babel/plugin-transform-literals" "^7.0.0" + "@babel/plugin-transform-modules-commonjs" "^7.0.0" + "@babel/plugin-transform-object-assign" "^7.0.0" + "@babel/plugin-transform-parameters" "^7.0.0" + "@babel/plugin-transform-react-display-name" "^7.0.0" + "@babel/plugin-transform-react-jsx" "^7.0.0" + "@babel/plugin-transform-react-jsx-self" "^7.0.0" + "@babel/plugin-transform-react-jsx-source" "^7.0.0" + "@babel/plugin-transform-regenerator" "^7.0.0" + "@babel/plugin-transform-runtime" "^7.0.0" + "@babel/plugin-transform-shorthand-properties" "^7.0.0" + "@babel/plugin-transform-spread" "^7.0.0" + "@babel/plugin-transform-sticky-regex" "^7.0.0" + "@babel/plugin-transform-template-literals" "^7.0.0" + "@babel/plugin-transform-typescript" "^7.5.0" + "@babel/plugin-transform-unicode-regex" "^7.0.0" + "@babel/template" "^7.0.0" + react-refresh "^0.4.0" + +micromatch@^2.3.11: + version "2.3.11" + resolved "https://registry.npm.taobao.org/micromatch/download/micromatch-2.3.11.tgz?cache=0&sync_timestamp=1618054740956&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fmicromatch%2Fdownload%2Fmicromatch-2.3.11.tgz#86677c97d1720b363431d04d0d15293bd38c1565" + integrity sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU= + dependencies: + arr-diff "^2.0.0" + array-unique "^0.2.1" + braces "^1.8.2" + expand-brackets "^0.1.4" + extglob "^0.3.1" + filename-regex "^2.0.0" + is-extglob "^1.0.0" + is-glob "^2.0.1" + kind-of "^3.0.2" + normalize-path "^2.0.1" + object.omit "^2.0.0" + parse-glob "^3.0.4" + regex-cache "^0.4.2" + +micromatch@^3.1.10, micromatch@^3.1.4: + version "3.1.10" + resolved "https://registry.npm.taobao.org/micromatch/download/micromatch-3.1.10.tgz?cache=0&sync_timestamp=1618054740956&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fmicromatch%2Fdownload%2Fmicromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" + integrity sha1-cIWbyVyYQJUvNZoGij/En57PrCM= + dependencies: + arr-diff "^4.0.0" + array-unique "^0.3.2" + braces "^2.3.1" + define-property "^2.0.2" + extend-shallow "^3.0.2" + extglob "^2.0.4" + fragment-cache "^0.2.1" + kind-of "^6.0.2" + nanomatch "^1.2.9" + object.pick "^1.3.0" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.2" + +micromatch@^4.0.2, micromatch@^4.0.4: + version "4.0.4" + resolved "https://registry.npm.taobao.org/micromatch/download/micromatch-4.0.4.tgz?cache=0&sync_timestamp=1618054740956&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fmicromatch%2Fdownload%2Fmicromatch-4.0.4.tgz#896d519dfe9db25fce94ceb7a500919bf881ebf9" + integrity sha1-iW1Rnf6dsl/OlM63pQCRm/iB6/k= + dependencies: + braces "^3.0.1" + picomatch "^2.2.3" + +miller-rabin@^4.0.0: + version "4.0.1" + resolved "https://registry.nlark.com/miller-rabin/download/miller-rabin-4.0.1.tgz#f080351c865b0dc562a8462966daa53543c78a4d" + integrity sha1-8IA1HIZbDcViqEYpZtqlNUPHik0= + dependencies: + bn.js "^4.0.0" + brorand "^1.0.1" + +mime-db@1.50.0, "mime-db@>= 1.43.0 < 2": + version "1.50.0" + resolved "https://registry.nlark.com/mime-db/download/mime-db-1.50.0.tgz#abd4ac94e98d3c0e185016c67ab45d5fde40c11f" + integrity sha1-q9SslOmNPA4YUBbGerRdX95AwR8= + +mime-types@^2.1.12, mime-types@^2.1.27, mime-types@~2.1.17, mime-types@~2.1.19, mime-types@~2.1.24: + version "2.1.33" + resolved "https://registry.npmmirror.com/mime-types/download/mime-types-2.1.33.tgz?cache=0&sync_timestamp=1633108176041&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fmime-types%2Fdownload%2Fmime-types-2.1.33.tgz#1fa12a904472fafd068e48d9e8401f74d3f70edb" + integrity sha1-H6EqkERy+v0GjkjZ6EAfdNP3Dts= + dependencies: + mime-db "1.50.0" + +mime@1.6.0, mime@^1.4.1: + version "1.6.0" + resolved "https://registry.npmmirror.com/mime/download/mime-1.6.0.tgz?cache=0&sync_timestamp=1635900726749&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fmime%2Fdownload%2Fmime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" + integrity sha1-Ms2eXGRVO9WNGaVor0Uqz/BJgbE= + +mime@^2.3.1, mime@^2.4.4: + version "2.6.0" + resolved "https://registry.npmmirror.com/mime/download/mime-2.6.0.tgz?cache=0&sync_timestamp=1635900726749&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fmime%2Fdownload%2Fmime-2.6.0.tgz#a2a682a95cd4d0cb1d6257e28f83da7e35800367" + integrity sha1-oqaCqVzU0MsdYlfij4PafjWAA2c= + +mimic-fn@^1.0.0: + version "1.2.0" + resolved "https://registry.npm.taobao.org/mimic-fn/download/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" + integrity sha1-ggyGo5M0ZA6ZUWkovQP8qIBX0CI= + +mimic-fn@^2.1.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/mimic-fn/download/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" + integrity sha1-ftLCzMyvhNP/y3pptXcR/CCDQBs= + +mini-css-extract-plugin@0.8.0: + version "0.8.0" + resolved "https://registry.npmmirror.com/mini-css-extract-plugin/download/mini-css-extract-plugin-0.8.0.tgz#81d41ec4fe58c713a96ad7c723cdb2d0bd4d70e1" + integrity sha1-gdQexP5YxxOpatfHI82y0L1NcOE= + dependencies: + loader-utils "^1.1.0" + normalize-url "1.9.1" + schema-utils "^1.0.0" + webpack-sources "^1.1.0" + +mini-css-extract-plugin@0.9.0: + version "0.9.0" + resolved "https://registry.npmmirror.com/mini-css-extract-plugin/download/mini-css-extract-plugin-0.9.0.tgz#47f2cf07aa165ab35733b1fc97d4c46c0564339e" + integrity sha1-R/LPB6oWWrNXM7H8l9TEbAVkM54= + dependencies: + loader-utils "^1.1.0" + normalize-url "1.9.1" + schema-utils "^1.0.0" + webpack-sources "^1.1.0" + +minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/minimalistic-assert/download/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" + integrity sha1-LhlN4ERibUoQ5/f7wAznPoPk1cc= + +minimalistic-crypto-utils@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/minimalistic-crypto-utils/download/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" + integrity sha1-9sAMHAsIIkblxNmd+4x8CDsrWCo= + +minimatch@^3.0.4, minimatch@~3.0.2: + version "3.0.4" + resolved "https://registry.nlark.com/minimatch/download/minimatch-3.0.4.tgz?cache=0&sync_timestamp=1618846754554&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fminimatch%2Fdownload%2Fminimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" + integrity sha1-UWbihkV/AzBgZL5Ul+jbsMPTIIM= + dependencies: + brace-expansion "^1.1.7" + +minimist-options@^3.0.1: + version "3.0.2" + resolved "https://registry.nlark.com/minimist-options/download/minimist-options-3.0.2.tgz#fba4c8191339e13ecf4d61beb03f070103f3d954" + integrity sha1-+6TIGRM54T7PTWG+sD8HAQPz2VQ= + dependencies: + arrify "^1.0.1" + is-plain-obj "^1.1.0" + +minimist@^1.1.3, minimist@^1.2.0, minimist@^1.2.5: + version "1.2.5" + resolved "https://registry.nlark.com/minimist/download/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" + integrity sha1-Z9ZgFLZqaoqqDAg8X9WN9OTpdgI= + +minipass-collect@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/minipass-collect/download/minipass-collect-1.0.2.tgz#22b813bf745dc6edba2576b940022ad6edc8c617" + integrity sha1-IrgTv3Rdxu26JXa5QAIq1u3Ixhc= + dependencies: + minipass "^3.0.0" + +minipass-flush@^1.0.5: + version "1.0.5" + resolved "https://registry.nlark.com/minipass-flush/download/minipass-flush-1.0.5.tgz#82e7135d7e89a50ffe64610a787953c4c4cbb373" + integrity sha1-gucTXX6JpQ/+ZGEKeHlTxMTLs3M= + dependencies: + minipass "^3.0.0" + +minipass-pipeline@^1.2.2: + version "1.2.4" + resolved "https://registry.nlark.com/minipass-pipeline/download/minipass-pipeline-1.2.4.tgz#68472f79711c084657c067c5c6ad93cddea8214c" + integrity sha1-aEcveXEcCEZXwGfFxq2Tzd6oIUw= + dependencies: + minipass "^3.0.0" + +minipass@^3.0.0, minipass@^3.1.1: + version "3.1.5" + resolved "https://registry.nlark.com/minipass/download/minipass-3.1.5.tgz?cache=0&sync_timestamp=1631656314228&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fminipass%2Fdownload%2Fminipass-3.1.5.tgz#71f6251b0a33a49c01b3cf97ff77eda030dff732" + integrity sha1-cfYlGwozpJwBs8+X/3ftoDDf9zI= + dependencies: + yallist "^4.0.0" + +miniprogram-api-typings@^3.2.2: + version "3.4.4" + resolved "https://registry.npmmirror.com/miniprogram-api-typings/download/miniprogram-api-typings-3.4.4.tgz?cache=0&sync_timestamp=1635559997264&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fminiprogram-api-typings%2Fdownload%2Fminiprogram-api-typings-3.4.4.tgz#a68ce1f10ff2479b521cd4af276a23041b90f2f6" + integrity sha1-pozh8Q/yR5tSHNSvJ2ojBBuQ8vY= + +miniprogram-compiler@latest: + version "0.1.3" + resolved "https://registry.nlark.com/miniprogram-compiler/download/miniprogram-compiler-0.1.3.tgz?cache=0&sync_timestamp=1619345445302&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fminiprogram-compiler%2Fdownload%2Fminiprogram-compiler-0.1.3.tgz#e5e29786db3dc93e5749b67127f563292ca0690f" + integrity sha1-5eKXhts9yT5XSbZxJ/VjKSygaQ8= + dependencies: + glob "^7.1.3" + unescape-js "^1.1.1" + +miniprogram-exparser@2.15.0: + version "2.15.0" + resolved "https://registry.npm.taobao.org/miniprogram-exparser/download/miniprogram-exparser-2.15.0.tgz?cache=0&sync_timestamp=1612337945256&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fminiprogram-exparser%2Fdownload%2Fminiprogram-exparser-2.15.0.tgz#8893a250dfed768802c061b13ff9ae1958b1223c" + integrity sha1-iJOiUN/tdogCwGGxP/muGVixIjw= + +miniprogram-simulate@^1.1.5: + version "1.4.2" + resolved "https://registry.nlark.com/miniprogram-simulate/download/miniprogram-simulate-1.4.2.tgz?cache=0&sync_timestamp=1629881307931&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fminiprogram-simulate%2Fdownload%2Fminiprogram-simulate-1.4.2.tgz#6a1c21432df830900979dc1e512bb55676f003a2" + integrity sha1-ahwhQy34MJAJedweUSu1VnbwA6I= + dependencies: + csso "^3.5.1" + j-component "^1.4.4" + less "^3.10.3" + miniprogram-compiler latest + postcss "^7.0.23" + +minizlib@^2.1.1: + version "2.1.2" + resolved "https://registry.nlark.com/minizlib/download/minizlib-2.1.2.tgz#e90d3466ba209b932451508a11ce3d3632145931" + integrity sha1-6Q00Zrogm5MkUVCKEc49NjIUWTE= + dependencies: + minipass "^3.0.0" + yallist "^4.0.0" + +mississippi@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/mississippi/download/mississippi-3.0.0.tgz#ea0a3291f97e0b5e8776b363d5f0a12d94c67022" + integrity sha1-6goykfl+C16HdrNj1fChLZTGcCI= + dependencies: + concat-stream "^1.5.0" + duplexify "^3.4.2" + end-of-stream "^1.1.0" + flush-write-stream "^1.0.0" + from2 "^2.1.0" + parallel-transform "^1.1.0" + pump "^3.0.0" + pumpify "^1.3.3" + stream-each "^1.1.0" + through2 "^2.0.0" + +mixin-deep@^1.2.0: + version "1.3.2" + resolved "https://registry.nlark.com/mixin-deep/download/mixin-deep-1.3.2.tgz#1120b43dc359a785dce65b55b82e257ccf479566" + integrity sha1-ESC0PcNZp4Xc5ltVuC4lfM9HlWY= + dependencies: + for-in "^1.0.2" + is-extendable "^1.0.1" + +"mkdirp@>=0.5 0", mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@^0.5.3, mkdirp@^0.5.5, mkdirp@~0.5.x: + version "0.5.5" + resolved "https://registry.npmmirror.com/mkdirp/download/mkdirp-0.5.5.tgz#d91cefd62d1436ca0f41620e251288d420099def" + integrity sha1-2Rzv1i0UNsoPQWIOJRKI1CAJne8= + dependencies: + minimist "^1.2.5" + +mkdirp@^1.0.3, mkdirp@^1.0.4, mkdirp@~1.0.4: + version "1.0.4" + resolved "https://registry.npmmirror.com/mkdirp/download/mkdirp-1.0.4.tgz#3eb5ed62622756d79a5f0e2a221dfebad75c2f7e" + integrity sha1-PrXtYmInVteaXw4qIh3+utdcL34= + +mobile-detect@^1.4.2: + version "1.4.5" + resolved "https://registry.npm.taobao.org/mobile-detect/download/mobile-detect-1.4.5.tgz?cache=0&sync_timestamp=1615628315030&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fmobile-detect%2Fdownload%2Fmobile-detect-1.4.5.tgz#da393c3c413ca1a9bcdd9ced653c38281c0fb6ad" + integrity sha1-2jk8PEE8oam83ZztZTw4KBwPtq0= + +move-concurrently@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/move-concurrently/download/move-concurrently-1.0.1.tgz#be2c005fda32e0b29af1f05d7c4b33214c701f92" + integrity sha1-viwAX9oy4LKa8fBdfEszIUxwH5I= + dependencies: + aproba "^1.1.1" + copy-concurrently "^1.0.0" + fs-write-stream-atomic "^1.0.8" + mkdirp "^0.5.1" + rimraf "^2.5.4" + run-queue "^1.0.3" + +ms@2.0.0: + version "2.0.0" + resolved "https://registry.npmmirror.com/ms/download/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" + integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= + +ms@2.1.1: + version "2.1.1" + resolved "https://registry.npmmirror.com/ms/download/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" + integrity sha1-MKWGTrPrsKZvLr5tcnrwagnYbgo= + +ms@2.1.2: + version "2.1.2" + resolved "https://registry.npmmirror.com/ms/download/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha1-0J0fNXtEP0kzgqjrPM0YOHKuYAk= + +ms@^2.1.1: + version "2.1.3" + resolved "https://registry.npmmirror.com/ms/download/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha1-V0yBOM4dK1hh8LRFedut1gxmFbI= + +multicast-dns-service-types@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/multicast-dns-service-types/download/multicast-dns-service-types-1.1.0.tgz#899f11d9686e5e05cb91b35d5f0e63b773cfc901" + integrity sha1-iZ8R2WhuXgXLkbNdXw5jt3PPyQE= + +multicast-dns@^6.0.1: + version "6.2.3" + resolved "https://registry.npmmirror.com/multicast-dns/download/multicast-dns-6.2.3.tgz#a0ec7bd9055c4282f790c3c82f4e28db3b31b229" + integrity sha1-oOx72QVcQoL3kMPIL04o2zsxsik= + dependencies: + dns-packet "^1.3.1" + thunky "^1.0.2" + +mute-stream@0.0.8: + version "0.0.8" + resolved "https://registry.nlark.com/mute-stream/download/mute-stream-0.0.8.tgz#1630c42b2251ff81e2a283de96a5497ea92e5e0d" + integrity sha1-FjDEKyJR/4HiooPelqVJfqkuXg0= + +nan@^2.12.1, nan@^2.13.2: + version "2.15.0" + resolved "https://registry.nlark.com/nan/download/nan-2.15.0.tgz#3f34a473ff18e15c1b5626b62903b5ad6e665fee" + integrity sha1-PzSkc/8Y4VwbVia2KQO1rW5mX+4= + +nanoid@*, nanoid@^3.1.23, nanoid@^3.1.30: + version "3.1.30" + resolved "https://registry.npmmirror.com/nanoid/download/nanoid-3.1.30.tgz?cache=0&sync_timestamp=1634166192601&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fnanoid%2Fdownload%2Fnanoid-3.1.30.tgz#63f93cc548d2a113dc5dfbc63bfa09e2b9b64362" + integrity sha1-Y/k8xUjSoRPcXfvGO/oJ4rm2Q2I= + +nanomatch@^1.2.9: + version "1.2.13" + resolved "https://registry.nlark.com/nanomatch/download/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" + integrity sha1-uHqKpPwN6P5r6IiVs4mD/yZb0Rk= + dependencies: + arr-diff "^4.0.0" + array-unique "^0.3.2" + define-property "^2.0.2" + extend-shallow "^3.0.2" + fragment-cache "^0.2.1" + is-windows "^1.0.2" + kind-of "^6.0.2" + object.pick "^1.3.0" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.1" + +native-request@^1.0.5: + version "1.1.0" + resolved "https://registry.nlark.com/native-request/download/native-request-1.1.0.tgz#acdb30fe2eefa3e1bc8c54b3a6852e9c5c0d3cb0" + integrity sha1-rNsw/i7vo+G8jFSzpoUunFwNPLA= + +native-url@^0.2.6: + version "0.2.6" + resolved "https://registry.npm.taobao.org/native-url/download/native-url-0.2.6.tgz#ca1258f5ace169c716ff44eccbddb674e10399ae" + integrity sha1-yhJY9azhaccW/0Tsy922dOEDma4= + dependencies: + querystring "^0.2.0" + +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.npm.taobao.org/natural-compare/download/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= + +needle@^2.5.2: + version "2.9.1" + resolved "https://registry.nlark.com/needle/download/needle-2.9.1.tgz?cache=0&sync_timestamp=1630674995929&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fneedle%2Fdownload%2Fneedle-2.9.1.tgz#22d1dffbe3490c2b83e301f7709b6736cd8f2684" + integrity sha1-ItHf++NJDCuD4wH3cJtnNs2PJoQ= + dependencies: + debug "^3.2.6" + iconv-lite "^0.4.4" + sax "^1.2.4" + +negotiator@0.6.2: + version "0.6.2" + resolved "https://registry.npm.taobao.org/negotiator/download/negotiator-0.6.2.tgz#feacf7ccf525a77ae9634436a64883ffeca346fb" + integrity sha1-/qz3zPUlp3rpY0Q2pkiD/+yjRvs= + +neo-async@^2.5.0, neo-async@^2.6.1, neo-async@^2.6.2: + version "2.6.2" + resolved "https://registry.nlark.com/neo-async/download/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" + integrity sha1-tKr7k+OustgXTKU88WOrfXMIMF8= + +next-tick@~1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/next-tick/download/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" + integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= + +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.npm.taobao.org/nice-try/download/nice-try-1.0.5.tgz?cache=0&sync_timestamp=1614510016909&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fnice-try%2Fdownload%2Fnice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" + integrity sha1-ozeKdpbOfSI+iPybdkvX7xCJ42Y= + +no-case@^2.2.0: + version "2.3.2" + resolved "https://registry.npm.taobao.org/no-case/download/no-case-2.3.2.tgz#60b813396be39b3f1288a4c1ed5d1e7d28b464ac" + integrity sha1-YLgTOWvjmz8SiKTB7V0efSi0ZKw= + dependencies: + lower-case "^1.1.1" + +node-forge@^0.10.0: + version "0.10.0" + resolved "https://registry.nlark.com/node-forge/download/node-forge-0.10.0.tgz#32dea2afb3e9926f02ee5ce8794902691a676bf3" + integrity sha1-Mt6ir7Ppkm8C7lzoeUkCaRpna/M= + +node-gyp@^3.8.0: + version "3.8.0" + resolved "https://registry.npmmirror.com/node-gyp/download/node-gyp-3.8.0.tgz?cache=0&sync_timestamp=1637570177658&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fnode-gyp%2Fdownload%2Fnode-gyp-3.8.0.tgz#540304261c330e80d0d5edce253a68cb3964218c" + integrity sha1-VAMEJhwzDoDQ1e3OJTpoyzlkIYw= + dependencies: + fstream "^1.0.0" + glob "^7.0.3" + graceful-fs "^4.1.2" + mkdirp "^0.5.0" + nopt "2 || 3" + npmlog "0 || 1 || 2 || 3 || 4" + osenv "0" + request "^2.87.0" + rimraf "2" + semver "~5.3.0" + tar "^2.0.0" + which "1" + +node-libs-browser@^2.2.1: + version "2.2.1" + resolved "https://registry.nlark.com/node-libs-browser/download/node-libs-browser-2.2.1.tgz#b64f513d18338625f90346d27b0d235e631f6425" + integrity sha1-tk9RPRgzhiX5A0bSew0jXmMfZCU= + dependencies: + assert "^1.1.1" + browserify-zlib "^0.2.0" + buffer "^4.3.0" + console-browserify "^1.1.0" + constants-browserify "^1.0.0" + crypto-browserify "^3.11.0" + domain-browser "^1.1.1" + events "^3.0.0" + https-browserify "^1.0.0" + os-browserify "^0.3.0" + path-browserify "0.0.1" + process "^0.11.10" + punycode "^1.2.4" + querystring-es3 "^0.2.0" + readable-stream "^2.3.3" + stream-browserify "^2.0.1" + stream-http "^2.7.2" + string_decoder "^1.0.0" + timers-browserify "^2.0.4" + tty-browserify "0.0.0" + url "^0.11.0" + util "^0.11.0" + vm-browserify "^1.0.1" + +node-modules-regexp@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/node-modules-regexp/download/node-modules-regexp-1.0.0.tgz#8d9dbe28964a4ac5712e9131642107c71e90ec40" + integrity sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA= + +node-releases@^2.0.1: + version "2.0.1" + resolved "https://registry.npmmirror.com/node-releases/download/node-releases-2.0.1.tgz?cache=0&sync_timestamp=1634806960337&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fnode-releases%2Fdownload%2Fnode-releases-2.0.1.tgz#3d1d395f204f1f2f29a54358b9fb678765ad2fc5" + integrity sha1-PR05XyBPHy8ppUNYuftnh2WtL8U= + +node-releases@^2.0.2: + version "2.0.2" + resolved "https://registry.npmmirror.com/node-releases/-/node-releases-2.0.2.tgz#7139fe71e2f4f11b47d4d2986aaf8c48699e0c01" + integrity sha512-XxYDdcQ6eKqp/YjI+tb2C5WM2LgjnZrfYg4vgQt49EK268b6gYCHsBLrK2qvJo4FmCtqmKezb0WZFK4fkrZNsg== + +node-sass@4.14.1: + version "4.14.1" + resolved "https://registry.npmmirror.com/node-sass/download/node-sass-4.14.1.tgz#99c87ec2efb7047ed638fb4c9db7f3a42e2217b5" + integrity sha1-mch+wu+3BH7WOPtMnbfzpC4iF7U= + dependencies: + async-foreach "^0.1.3" + chalk "^1.1.1" + cross-spawn "^3.0.0" + gaze "^1.0.0" + get-stdin "^4.0.1" + glob "^7.0.3" + in-publish "^2.0.0" + lodash "^4.17.15" + meow "^3.7.0" + mkdirp "^0.5.1" + nan "^2.13.2" + node-gyp "^3.8.0" + npmlog "^4.0.0" + request "^2.88.0" + sass-graph "2.2.5" + stdout-stream "^1.4.0" + "true-case-path" "^1.0.2" + +"nopt@2 || 3": + version "3.0.6" + resolved "https://registry.npm.taobao.org/nopt/download/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9" + integrity sha1-xkZdvwirzU2zWTF/eaxopkayj/k= + dependencies: + abbrev "1" + +normalize-package-data@^2.3.2, normalize-package-data@^2.3.4: + version "2.5.0" + resolved "https://registry.nlark.com/normalize-package-data/download/normalize-package-data-2.5.0.tgz?cache=0&sync_timestamp=1629301872905&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fnormalize-package-data%2Fdownload%2Fnormalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" + integrity sha1-5m2xg4sgDB38IzIl0SyzZSDiNKg= + dependencies: + hosted-git-info "^2.1.4" + resolve "^1.10.0" + semver "2 || 3 || 4 || 5" + validate-npm-package-license "^3.0.1" + +normalize-path@^2.0.1, normalize-path@^2.1.1: + version "2.1.1" + resolved "https://registry.npm.taobao.org/normalize-path/download/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" + integrity sha1-GrKLVW4Zg2Oowab35vogE3/mrtk= + dependencies: + remove-trailing-separator "^1.0.1" + +normalize-path@^3.0.0, normalize-path@~3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/normalize-path/download/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" + integrity sha1-Dc1p/yOhybEf0JeDFmRKA4ghamU= + +normalize-range@^0.1.2: + version "0.1.2" + resolved "https://registry.npm.taobao.org/normalize-range/download/normalize-range-0.1.2.tgz#2d10c06bdfd312ea9777695a4d28439456b75942" + integrity sha1-LRDAa9/TEuqXd2laTShDlFa3WUI= + +normalize-selector@^0.2.0: + version "0.2.0" + resolved "https://registry.npm.taobao.org/normalize-selector/download/normalize-selector-0.2.0.tgz#d0b145eb691189c63a78d201dc4fdb1293ef0c03" + integrity sha1-0LFF62kRicY6eNIB3E/bEpPvDAM= + +normalize-url@1.9.1: + version "1.9.1" + resolved "https://registry.nlark.com/normalize-url/download/normalize-url-1.9.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fnormalize-url%2Fdownload%2Fnormalize-url-1.9.1.tgz#2cc0d66b31ea23036458436e3620d85954c66c3c" + integrity sha1-LMDWazHqIwNkWENuNiDYWVTGbDw= + dependencies: + object-assign "^4.0.1" + prepend-http "^1.0.0" + query-string "^4.1.0" + sort-keys "^1.0.0" + +normalizr@^3.6.1: + version "3.6.1" + resolved "https://registry.npm.taobao.org/normalizr/download/normalizr-3.6.1.tgz#d367ab840e031ff382141b8d81ce279292ff69fe" + integrity sha1-02erhA4DH/OCFBuNgc4nkpL/af4= + +npm-run-path@^2.0.0: + version "2.0.2" + resolved "https://registry.npmmirror.com/npm-run-path/download/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" + integrity sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8= + dependencies: + path-key "^2.0.0" + +"npmlog@0 || 1 || 2 || 3 || 4", npmlog@^4.0.0: + version "4.1.2" + resolved "https://registry.npmmirror.com/npmlog/download/npmlog-4.1.2.tgz?cache=0&sync_timestamp=1637085007288&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fnpmlog%2Fdownload%2Fnpmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" + integrity sha1-CKfyqL9zRgR3mp76StXMcXq7lUs= + dependencies: + are-we-there-yet "~1.1.2" + console-control-strings "~1.1.0" + gauge "~2.7.3" + set-blocking "~2.0.0" + +nth-check@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/nth-check/download/nth-check-2.0.1.tgz#2efe162f5c3da06a28959fbd3db75dbeea9f0fc2" + integrity sha1-Lv4WL1w9oGoolZ+9PbddvuqfD8I= + dependencies: + boolbase "^1.0.0" + +num2fraction@^1.2.2: + version "1.2.2" + resolved "https://registry.nlark.com/num2fraction/download/num2fraction-1.2.2.tgz#6f682b6a027a4e9ddfa4564cd2589d1d4e669ede" + integrity sha1-b2gragJ6Tp3fpFZM0lidHU5mnt4= + +number-is-nan@^1.0.0: + version "1.0.1" + resolved "https://registry.npmmirror.com/number-is-nan/download/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" + integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= + +nwsapi@^2.2.0: + version "2.2.0" + resolved "https://registry.nlark.com/nwsapi/download/nwsapi-2.2.0.tgz#204879a9e3d068ff2a55139c2c772780681a38b7" + integrity sha1-IEh5qePQaP8qVROcLHcngGgaOLc= + +oauth-sign@~0.9.0: + version "0.9.0" + resolved "https://registry.nlark.com/oauth-sign/download/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" + integrity sha1-R6ewFrqmi1+g7PPe4IqFxnmsZFU= + +object-assign@^4.0.1, object-assign@^4.1.0, object-assign@^4.1.1: + version "4.1.1" + resolved "https://registry.nlark.com/object-assign/download/object-assign-4.1.1.tgz?cache=0&sync_timestamp=1618847043548&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fobject-assign%2Fdownload%2Fobject-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" + integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= + +object-copy@^0.1.0: + version "0.1.0" + resolved "https://registry.nlark.com/object-copy/download/object-copy-0.1.0.tgz#7e7d858b781bd7c991a41ba975ed3812754e998c" + integrity sha1-fn2Fi3gb18mRpBupde04EnVOmYw= + dependencies: + copy-descriptor "^0.1.0" + define-property "^0.2.5" + kind-of "^3.0.3" + +object-inspect@^1.11.0, object-inspect@^1.9.0: + version "1.11.0" + resolved "https://registry.nlark.com/object-inspect/download/object-inspect-1.11.0.tgz?cache=0&sync_timestamp=1626120241132&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fobject-inspect%2Fdownload%2Fobject-inspect-1.11.0.tgz#9dceb146cedd4148a0d9e51ab88d34cf509922b1" + integrity sha1-nc6xRs7dQUig2eUauI00z1CZIrE= + +object-is@^1.0.1: + version "1.1.5" + resolved "https://registry.npm.taobao.org/object-is/download/object-is-1.1.5.tgz?cache=0&sync_timestamp=1613857698573&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fobject-is%2Fdownload%2Fobject-is-1.1.5.tgz#b9deeaa5fc7f1846a0faecdceec138e5778f53ac" + integrity sha1-ud7qpfx/GEag+uzc7sE45XePU6w= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + +object-keys@^1.0.12, object-keys@^1.1.1: + version "1.1.1" + resolved "https://registry.nlark.com/object-keys/download/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" + integrity sha1-HEfyct8nfzsdrwYWd9nILiMixg4= + +object-path@0.11.4: + version "0.11.4" + resolved "https://registry.nlark.com/object-path/download/object-path-0.11.4.tgz?cache=0&sync_timestamp=1631790059393&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fobject-path%2Fdownload%2Fobject-path-0.11.4.tgz#370ae752fbf37de3ea70a861c23bba8915691949" + integrity sha1-NwrnUvvzfePqcKhhwju6iRVpGUk= + +object-visit@^1.0.0: + version "1.0.1" + resolved "https://registry.nlark.com/object-visit/download/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" + integrity sha1-95xEk68MU3e1n+OdOV5BBC3QRbs= + dependencies: + isobject "^3.0.0" + +object.assign@^4.1.0, object.assign@^4.1.2: + version "4.1.2" + resolved "https://registry.nlark.com/object.assign/download/object.assign-4.1.2.tgz#0ed54a342eceb37b38ff76eb831a0e788cb63940" + integrity sha1-DtVKNC7Os3s4/3brgxoOeIy2OUA= + dependencies: + call-bind "^1.0.0" + define-properties "^1.1.3" + has-symbols "^1.0.1" + object-keys "^1.1.1" + +object.entries@^1.1.4: + version "1.1.5" + resolved "https://registry.npmmirror.com/object.entries/download/object.entries-1.1.5.tgz#e1acdd17c4de2cd96d5a08487cfb9db84d881861" + integrity sha1-4azdF8TeLNltWghIfPuduE2IGGE= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.1" + +object.fromentries@^2.0.4: + version "2.0.5" + resolved "https://registry.npmmirror.com/object.fromentries/download/object.fromentries-2.0.5.tgz#7b37b205109c21e741e605727fe8b0ad5fa08251" + integrity sha1-ezeyBRCcIedB5gVyf+iwrV+gglE= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.1" + +object.getownpropertydescriptors@^2.0.3: + version "2.1.3" + resolved "https://registry.npmmirror.com/object.getownpropertydescriptors/download/object.getownpropertydescriptors-2.1.3.tgz?cache=0&sync_timestamp=1633321770416&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fobject.getownpropertydescriptors%2Fdownload%2Fobject.getownpropertydescriptors-2.1.3.tgz#b223cf38e17fefb97a63c10c91df72ccb386df9e" + integrity sha1-siPPOOF/77l6Y8EMkd9yzLOG354= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.1" + +object.hasown@^1.0.0: + version "1.1.0" + resolved "https://registry.npmmirror.com/object.hasown/download/object.hasown-1.1.0.tgz#7232ed266f34d197d15cac5880232f7a4790afe5" + integrity sha1-cjLtJm800ZfRXKxYgCMvekeQr+U= + dependencies: + define-properties "^1.1.3" + es-abstract "^1.19.1" + +object.omit@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/object.omit/download/object.omit-2.0.1.tgz#1a9c744829f39dbb858c76ca3579ae2a54ebd1fa" + integrity sha1-Gpx0SCnznbuFjHbKNXmuKlTr0fo= + dependencies: + for-own "^0.1.4" + is-extendable "^0.1.1" + +object.pick@^1.3.0: + version "1.3.0" + resolved "https://registry.nlark.com/object.pick/download/object.pick-1.3.0.tgz#87a10ac4c1694bd2e1cbf53591a66141fb5dd747" + integrity sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c= + dependencies: + isobject "^3.0.1" + +object.values@^1.1.4, object.values@^1.1.5: + version "1.1.5" + resolved "https://registry.npmmirror.com/object.values/download/object.values-1.1.5.tgz#959f63e3ce9ef108720333082131e4a459b716ac" + integrity sha1-lZ9j486e8QhyAzMIITHkpFm3Fqw= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.1" + +obuf@^1.0.0, obuf@^1.1.2: + version "1.1.2" + resolved "https://registry.nlark.com/obuf/download/obuf-1.1.2.tgz#09bea3343d41859ebd446292d11c9d4db619084e" + integrity sha1-Cb6jND1BhZ69RGKS0RydTbYZCE4= + +omit.js@^1.0.0: + version "1.0.2" + resolved "https://registry.npm.taobao.org/omit.js/download/omit.js-1.0.2.tgz#91a14f0eba84066dfa015bf30e474c47f30bc858" + integrity sha1-kaFPDrqEBm36AVvzDkdMR/MLyFg= + dependencies: + babel-runtime "^6.23.0" + +on-finished@~2.3.0: + version "2.3.0" + resolved "https://registry.nlark.com/on-finished/download/on-finished-2.3.0.tgz#20f1336481b083cd75337992a16971aa2d906947" + integrity sha1-IPEzZIGwg811M3mSoWlxqi2QaUc= + dependencies: + ee-first "1.1.1" + +on-headers@~1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/on-headers/download/on-headers-1.0.2.tgz#772b0ae6aaa525c399e489adfad90c403eb3c28f" + integrity sha1-dysK5qqlJcOZ5Imt+tkMQD6zwo8= + +once@^1.3.0, once@^1.3.1, once@^1.4.0: + version "1.4.0" + resolved "https://registry.nlark.com/once/download/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= + dependencies: + wrappy "1" + +onetime@^2.0.0: + version "2.0.1" + resolved "https://registry.npm.taobao.org/onetime/download/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" + integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= + dependencies: + mimic-fn "^1.0.0" + +onetime@^5.1.0: + version "5.1.2" + resolved "https://registry.npm.taobao.org/onetime/download/onetime-5.1.2.tgz#d0e96ebb56b07476df1dd9c4806e5237985ca45e" + integrity sha1-0Oluu1awdHbfHdnEgG5SN5hcpF4= + dependencies: + mimic-fn "^2.1.0" + +open@7.0.2: + version "7.0.2" + resolved "https://registry.npmmirror.com/open/download/open-7.0.2.tgz#fb3681f11f157f2361d2392307548ca1792960e8" + integrity sha1-+zaB8R8VfyNh0jkjB1SMoXkpYOg= + dependencies: + is-docker "^2.0.0" + is-wsl "^2.1.1" + +opener@^1.5.2: + version "1.5.2" + resolved "https://registry.npm.taobao.org/opener/download/opener-1.5.2.tgz#5d37e1f35077b9dcac4301372271afdeb2a13598" + integrity sha1-XTfh81B3udysQwE3InGv3rKhNZg= + +opn@^5.5.0: + version "5.5.0" + resolved "https://registry.npmmirror.com/opn/download/opn-5.5.0.tgz#fc7164fab56d235904c51c3b27da6758ca3b9bfc" + integrity sha1-/HFk+rVtI1kExRw7J9pnWMo7m/w= + dependencies: + is-wsl "^1.1.0" + +optionator@^0.8.1, optionator@^0.8.3: + version "0.8.3" + resolved "https://registry.nlark.com/optionator/download/optionator-0.8.3.tgz#84fa1d036fe9d3c7e21d99884b601167ec8fb495" + integrity sha1-hPodA2/p08fiHZmIS2ARZ+yPtJU= + dependencies: + deep-is "~0.1.3" + fast-levenshtein "~2.0.6" + levn "~0.3.0" + prelude-ls "~1.1.2" + type-check "~0.3.2" + word-wrap "~1.2.3" + +ora@4.0.3: + version "4.0.3" + resolved "https://registry.nlark.com/ora/download/ora-4.0.3.tgz?cache=0&sync_timestamp=1631556430183&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fora%2Fdownload%2Fora-4.0.3.tgz#752a1b7b4be4825546a7a3d59256fa523b6b6d05" + integrity sha1-dSobe0vkglVGp6PVklb6UjtrbQU= + dependencies: + chalk "^3.0.0" + cli-cursor "^3.1.0" + cli-spinners "^2.2.0" + is-interactive "^1.0.0" + log-symbols "^3.0.0" + mute-stream "0.0.8" + strip-ansi "^6.0.0" + wcwidth "^1.0.1" + +ora@^3.4.0: + version "3.4.0" + resolved "https://registry.nlark.com/ora/download/ora-3.4.0.tgz?cache=0&sync_timestamp=1631556430183&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fora%2Fdownload%2Fora-3.4.0.tgz#bf0752491059a3ef3ed4c85097531de9fdbcd318" + integrity sha1-vwdSSRBZo+8+1MhQl1Md6f280xg= + dependencies: + chalk "^2.4.2" + cli-cursor "^2.1.0" + cli-spinners "^2.0.0" + log-symbols "^2.2.0" + strip-ansi "^5.2.0" + wcwidth "^1.0.1" + +original@^1.0.0: + version "1.0.2" + resolved "https://registry.npm.taobao.org/original/download/original-1.0.2.tgz#e442a61cffe1c5fd20a65f3261c26663b303f25f" + integrity sha1-5EKmHP/hxf0gpl8yYcJmY7MD8l8= + dependencies: + url-parse "^1.4.3" + +os-browserify@^0.3.0: + version "0.3.0" + resolved "https://registry.nlark.com/os-browserify/download/os-browserify-0.3.0.tgz#854373c7f5c2315914fc9bfc6bd8238fdda1ec27" + integrity sha1-hUNzx/XCMVkU/Jv8a9gjj92h7Cc= + +os-homedir@^1.0.0: + version "1.0.2" + resolved "https://registry.npm.taobao.org/os-homedir/download/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" + integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= + +os-tmpdir@^1.0.0, os-tmpdir@~1.0.2: + version "1.0.2" + resolved "https://registry.npm.taobao.org/os-tmpdir/download/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" + integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= + +osenv@0: + version "0.1.5" + resolved "https://registry.nlark.com/osenv/download/osenv-0.1.5.tgz#85cdfafaeb28e8677f416e287592b5f3f49ea410" + integrity sha1-hc36+uso6Gd/QW4odZK18/SepBA= + dependencies: + os-homedir "^1.0.0" + os-tmpdir "^1.0.0" + +p-finally@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/p-finally/download/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" + integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= + +p-limit@^1.1.0: + version "1.3.0" + resolved "https://registry.nlark.com/p-limit/download/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" + integrity sha1-uGvV8MJWkJEcdZD8v8IBDVSzzLg= + dependencies: + p-try "^1.0.0" + +p-limit@^2.0.0, p-limit@^2.2.0, p-limit@^2.2.1: + version "2.3.0" + resolved "https://registry.nlark.com/p-limit/download/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" + integrity sha1-PdM8ZHohT9//2DWTPrCG2g3CHbE= + dependencies: + p-try "^2.0.0" + +p-limit@^3.0.2: + version "3.1.0" + resolved "https://registry.nlark.com/p-limit/download/p-limit-3.1.0.tgz#e1daccbe78d0d1388ca18c64fea38e3e57e3706b" + integrity sha1-4drMvnjQ0TiMoYxk/qOOPlfjcGs= + dependencies: + yocto-queue "^0.1.0" + +p-locate@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/p-locate/download/p-locate-2.0.0.tgz#20a0103b222a70c8fd39cc2e580680f3dde5ec43" + integrity sha1-IKAQOyIqcMj9OcwuWAaA893l7EM= + dependencies: + p-limit "^1.1.0" + +p-locate@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/p-locate/download/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" + integrity sha1-Mi1poFwCZLJZl9n0DNiokasAZKQ= + dependencies: + p-limit "^2.0.0" + +p-locate@^4.1.0: + version "4.1.0" + resolved "https://registry.nlark.com/p-locate/download/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" + integrity sha1-o0KLtwiLOmApL2aRkni3wpetTwc= + dependencies: + p-limit "^2.2.0" + +p-map@^2.0.0: + version "2.1.0" + resolved "https://registry.npmmirror.com/p-map/download/p-map-2.1.0.tgz#310928feef9c9ecc65b68b17693018a665cea175" + integrity sha1-MQko/u+cnsxltosXaTAYpmXOoXU= + +p-map@^4.0.0: + version "4.0.0" + resolved "https://registry.npmmirror.com/p-map/download/p-map-4.0.0.tgz#bb2f95a5eda2ec168ec9274e06a747c3e2904d2b" + integrity sha1-uy+Vpe2i7BaOySdOBqdHw+KQTSs= + dependencies: + aggregate-error "^3.0.0" + +p-retry@^3.0.1: + version "3.0.1" + resolved "https://registry.npmmirror.com/p-retry/download/p-retry-3.0.1.tgz#316b4c8893e2c8dc1cfa891f406c4b422bebf328" + integrity sha1-MWtMiJPiyNwc+okfQGxLQivr8yg= + dependencies: + retry "^0.12.0" + +p-try@^1.0.0: + version "1.0.0" + resolved "https://registry.npmmirror.com/p-try/download/p-try-1.0.0.tgz?cache=0&sync_timestamp=1633364462890&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fp-try%2Fdownload%2Fp-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" + integrity sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M= + +p-try@^2.0.0: + version "2.2.0" + resolved "https://registry.npmmirror.com/p-try/download/p-try-2.2.0.tgz?cache=0&sync_timestamp=1633364462890&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fp-try%2Fdownload%2Fp-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" + integrity sha1-yyhoVA4xPWHeWPr741zpAE1VQOY= + +pako@~1.0.5: + version "1.0.11" + resolved "https://registry.nlark.com/pako/download/pako-1.0.11.tgz#6c9599d340d54dfd3946380252a35705a6b992bf" + integrity sha1-bJWZ00DVTf05RjgCUqNXBaa5kr8= + +parallel-transform@^1.1.0: + version "1.2.0" + resolved "https://registry.npm.taobao.org/parallel-transform/download/parallel-transform-1.2.0.tgz#9049ca37d6cb2182c3b1d2c720be94d14a5814fc" + integrity sha1-kEnKN9bLIYLDsdLHIL6U0UpYFPw= + dependencies: + cyclist "^1.0.1" + inherits "^2.0.3" + readable-stream "^2.1.5" + +param-case@2.1.x, param-case@^2.1.1: + version "2.1.1" + resolved "https://registry.nlark.com/param-case/download/param-case-2.1.1.tgz#df94fd8cf6531ecf75e6bef9a0858fbc72be2247" + integrity sha1-35T9jPZTHs915r75oIWPvHK+Ikc= + dependencies: + no-case "^2.2.0" + +parent-module@^1.0.0: + version "1.0.1" + resolved "https://registry.npmmirror.com/parent-module/download/parent-module-1.0.1.tgz?cache=0&sync_timestamp=1633337513286&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fparent-module%2Fdownload%2Fparent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" + integrity sha1-aR0nCeeMefrjoVZiJFLQB2LKqqI= + dependencies: + callsites "^3.0.0" + +parse-asn1@^5.0.0, parse-asn1@^5.1.5: + version "5.1.6" + resolved "https://registry.nlark.com/parse-asn1/download/parse-asn1-5.1.6.tgz#385080a3ec13cb62a62d39409cb3e88844cdaed4" + integrity sha1-OFCAo+wTy2KmLTlAnLPoiETNrtQ= + dependencies: + asn1.js "^5.2.0" + browserify-aes "^1.0.0" + evp_bytestokey "^1.0.0" + pbkdf2 "^3.0.3" + safe-buffer "^5.1.1" + +parse-entities@^1.0.2, parse-entities@^1.1.0: + version "1.2.2" + resolved "https://registry.npmmirror.com/parse-entities/download/parse-entities-1.2.2.tgz#c31bf0f653b6661354f8973559cb86dd1d5edf50" + integrity sha1-wxvw9lO2ZhNU+Jc1WcuG3R1e31A= + dependencies: + character-entities "^1.0.0" + character-entities-legacy "^1.0.0" + character-reference-invalid "^1.0.0" + is-alphanumerical "^1.0.0" + is-decimal "^1.0.0" + is-hexadecimal "^1.0.0" + +parse-glob@^3.0.4: + version "3.0.4" + resolved "https://registry.npm.taobao.org/parse-glob/download/parse-glob-3.0.4.tgz#b2c376cfb11f35513badd173ef0bb6e3a388391c" + integrity sha1-ssN2z7EfNVE7rdFz7wu246OIORw= + dependencies: + glob-base "^0.3.0" + is-dotfile "^1.0.0" + is-extglob "^1.0.0" + is-glob "^2.0.0" + +parse-json@^2.2.0: + version "2.2.0" + resolved "https://registry.npmmirror.com/parse-json/download/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" + integrity sha1-9ID0BDTvgHQfhGkJn43qGPVaTck= + dependencies: + error-ex "^1.2.0" + +parse-json@^4.0.0: + version "4.0.0" + resolved "https://registry.npmmirror.com/parse-json/download/parse-json-4.0.0.tgz?cache=0&sync_timestamp=1636012033195&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fparse-json%2Fdownload%2Fparse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" + integrity sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA= + dependencies: + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" + +parse-json@^5.0.0: + version "5.2.0" + resolved "https://registry.npmmirror.com/parse-json/download/parse-json-5.2.0.tgz?cache=0&sync_timestamp=1636012033195&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fparse-json%2Fdownload%2Fparse-json-5.2.0.tgz#c76fc66dee54231c962b22bcc8a72cf2f99753cd" + integrity sha1-x2/Gbe5UIxyWKyK8yKcs8vmXU80= + dependencies: + "@babel/code-frame" "^7.0.0" + error-ex "^1.3.1" + json-parse-even-better-errors "^2.3.0" + lines-and-columns "^1.1.6" + +parse-node-version@^1.0.1: + version "1.0.1" + resolved "https://registry.npm.taobao.org/parse-node-version/download/parse-node-version-1.0.1.tgz#e2b5dbede00e7fa9bc363607f53327e8b073189b" + integrity sha1-4rXb7eAOf6m8NjYH9TMn6LBzGJs= + +parse5@5.1.0: + version "5.1.0" + resolved "https://registry.nlark.com/parse5/download/parse5-5.1.0.tgz#c59341c9723f414c452975564c7c00a68d58acd2" + integrity sha1-xZNByXI/QUxFKXVWTHwApo1YrNI= + +parseurl@~1.3.2, parseurl@~1.3.3: + version "1.3.3" + resolved "https://registry.nlark.com/parseurl/download/parseurl-1.3.3.tgz#9da19e7bee8d12dff0513ed5b76957793bc2e8d4" + integrity sha1-naGee+6NEt/wUT7Vt2lXeTvC6NQ= + +pascalcase@^0.1.1: + version "0.1.1" + resolved "https://registry.npm.taobao.org/pascalcase/download/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14" + integrity sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ= + +path-browserify@0.0.1: + version "0.0.1" + resolved "https://registry.nlark.com/path-browserify/download/path-browserify-0.0.1.tgz#e6c4ddd7ed3aa27c68a20cc4e50e1a4ee83bbc4a" + integrity sha1-5sTd1+06onxoogzE5Q4aTug7vEo= + +path-dirname@^1.0.0: + version "1.0.2" + resolved "https://registry.npm.taobao.org/path-dirname/download/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" + integrity sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA= + +path-exists@^2.0.0: + version "2.1.0" + resolved "https://registry.nlark.com/path-exists/download/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b" + integrity sha1-D+tsZPD8UY2adU3V77YscCJ2H0s= + dependencies: + pinkie-promise "^2.0.0" + +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/path-exists/download/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + integrity sha1-zg6+ql94yxiSXqfYENe1mwEP1RU= + +path-exists@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/path-exists/download/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" + integrity sha1-UTvb4tO5XXdi6METfvoZXGxhtbM= + +path-is-absolute@^1.0.0: + version "1.0.1" + resolved "https://registry.npm.taobao.org/path-is-absolute/download/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" + integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= + +path-is-inside@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/path-is-inside/download/path-is-inside-1.0.2.tgz?cache=0&sync_timestamp=1622604553837&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpath-is-inside%2Fdownload%2Fpath-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" + integrity sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM= + +path-key@^2.0.0, path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.npm.taobao.org/path-key/download/path-key-2.0.1.tgz?cache=0&sync_timestamp=1617971695678&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fpath-key%2Fdownload%2Fpath-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" + integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A= + +path-key@^3.1.0: + version "3.1.1" + resolved "https://registry.npm.taobao.org/path-key/download/path-key-3.1.1.tgz?cache=0&sync_timestamp=1617971695678&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fpath-key%2Fdownload%2Fpath-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" + integrity sha1-WB9q3mWMu6ZaDTOA3ndTKVBU83U= + +path-parse@^1.0.6: + version "1.0.7" + resolved "https://registry.nlark.com/path-parse/download/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" + integrity sha1-+8EUtgykKzDZ2vWFjkvWi77bZzU= + +path-to-regexp@0.1.7: + version "0.1.7" + resolved "https://registry.npm.taobao.org/path-to-regexp/download/path-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c" + integrity sha1-32BBeABfUi8V60SQ5yR6G/qmf4w= + +path-to-regexp@^3.1.0: + version "3.2.0" + resolved "https://registry.npm.taobao.org/path-to-regexp/download/path-to-regexp-3.2.0.tgz#fa7877ecbc495c601907562222453c43cc204a5f" + integrity sha1-+nh37LxJXGAZB1YiIkU8Q8wgSl8= + +path-to-regexp@^6.2.0: + version "6.2.0" + resolved "https://registry.npm.taobao.org/path-to-regexp/download/path-to-regexp-6.2.0.tgz#f7b3803336104c346889adece614669230645f38" + integrity sha1-97OAMzYQTDRoia3s5hRmkjBkXzg= + +path-type@^1.0.0: + version "1.1.0" + resolved "https://registry.nlark.com/path-type/download/path-type-1.1.0.tgz#59c44f7ee491da704da415da5a4070ba4f8fe441" + integrity sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE= + dependencies: + graceful-fs "^4.1.2" + pify "^2.0.0" + pinkie-promise "^2.0.0" + +path-type@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/path-type/download/path-type-3.0.0.tgz#cef31dc8e0a1a3bb0d105c0cd97cf3bf47f4e36f" + integrity sha1-zvMdyOCho7sNEFwM2Xzzv0f0428= + dependencies: + pify "^3.0.0" + +path-type@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/path-type/download/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" + integrity sha1-hO0BwKe6OAr+CdkKjBgNzZ0DBDs= + +pbkdf2@^3.0.3: + version "3.1.2" + resolved "https://registry.nlark.com/pbkdf2/download/pbkdf2-3.1.2.tgz#dd822aa0887580e52f1a039dc3eda108efae3075" + integrity sha1-3YIqoIh1gOUvGgOdw+2hCO+uMHU= + dependencies: + create-hash "^1.1.2" + create-hmac "^1.1.4" + ripemd160 "^2.0.1" + safe-buffer "^5.0.1" + sha.js "^2.4.8" + +pend@~1.2.0: + version "1.2.0" + resolved "https://registry.npm.taobao.org/pend/download/pend-1.2.0.tgz#7a57eb550a6783f9115331fcf4663d5c8e007a50" + integrity sha1-elfrVQpng/kRUzH89GY9XI4AelA= + +performance-now@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/performance-now/download/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" + integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= + +picocolors@^0.2.1: + version "0.2.1" + resolved "https://registry.npmmirror.com/picocolors/download/picocolors-0.2.1.tgz?cache=0&sync_timestamp=1634093442271&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpicocolors%2Fdownload%2Fpicocolors-0.2.1.tgz#570670f793646851d1ba135996962abad587859f" + integrity sha1-VwZw95NkaFHRuhNZlpYqutWHhZ8= + +picocolors@^1.0.0: + version "1.0.0" + resolved "https://registry.npmmirror.com/picocolors/download/picocolors-1.0.0.tgz?cache=0&sync_timestamp=1634093442271&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpicocolors%2Fdownload%2Fpicocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" + integrity sha1-y1vcdP8/UYkiNur3nWi8RFZKuBw= + +picomatch@^2.0.4, picomatch@^2.0.7, picomatch@^2.2.1, picomatch@^2.2.3: + version "2.3.0" + resolved "https://registry.nlark.com/picomatch/download/picomatch-2.3.0.tgz#f1f061de8f6a4bf022892e2d128234fb98302972" + integrity sha1-8fBh3o9qS/AiiS4tEoI0+5gwKXI= + +picomatch@^2.2.2: + version "2.3.1" + resolved "https://registry.npmmirror.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" + integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== + +pify@^2.0.0, pify@^2.3.0: + version "2.3.0" + resolved "https://registry.npm.taobao.org/pify/download/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" + integrity sha1-7RQaasBDqEnqWISY59yosVMw6Qw= + +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/pify/download/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" + integrity sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY= + +pify@^4.0.1: + version "4.0.1" + resolved "https://registry.npm.taobao.org/pify/download/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" + integrity sha1-SyzSXFDVmHNcUCkiJP2MbfQeMjE= + +pinkie-promise@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/pinkie-promise/download/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa" + integrity sha1-ITXW36ejWMBprJsXh3YogihFD/o= + dependencies: + pinkie "^2.0.0" + +pinkie@^2.0.0: + version "2.0.4" + resolved "https://registry.npm.taobao.org/pinkie/download/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" + integrity sha1-clVrgM+g1IqXToDnckjoDtT3+HA= + +pirates@^4.0.0: + version "4.0.1" + resolved "https://registry.nlark.com/pirates/download/pirates-4.0.1.tgz#643a92caf894566f91b2b986d2c66950a8e2fb87" + integrity sha1-ZDqSyviUVm+RsrmG0sZpUKji+4c= + dependencies: + node-modules-regexp "^1.0.0" + +pkg-dir@^2.0.0: + version "2.0.0" + resolved "https://registry.npmmirror.com/pkg-dir/download/pkg-dir-2.0.0.tgz?cache=0&sync_timestamp=1633498133295&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpkg-dir%2Fdownload%2Fpkg-dir-2.0.0.tgz#f6d5d1109e19d63edf428e0bd57e12777615334b" + integrity sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s= + dependencies: + find-up "^2.1.0" + +pkg-dir@^3.0.0: + version "3.0.0" + resolved "https://registry.npmmirror.com/pkg-dir/download/pkg-dir-3.0.0.tgz?cache=0&sync_timestamp=1633498133295&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpkg-dir%2Fdownload%2Fpkg-dir-3.0.0.tgz#2749020f239ed990881b1f71210d51eb6523bea3" + integrity sha1-J0kCDyOe2ZCIGx9xIQ1R62UjvqM= + dependencies: + find-up "^3.0.0" + +pkg-dir@^4.1.0: + version "4.2.0" + resolved "https://registry.npmmirror.com/pkg-dir/download/pkg-dir-4.2.0.tgz?cache=0&sync_timestamp=1633498133295&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpkg-dir%2Fdownload%2Fpkg-dir-4.2.0.tgz#f099133df7ede422e81d1d8448270eeb3e4261f3" + integrity sha1-8JkTPfft5CLoHR2ESCcO6z5CYfM= + dependencies: + find-up "^4.0.0" + +pn@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/pn/download/pn-1.1.0.tgz#e2f4cef0e219f463c179ab37463e4e1ecdccbafb" + integrity sha1-4vTO8OIZ9GPBeas3Rj5OHs3Muvs= + +portfinder@^1.0.26: + version "1.0.28" + resolved "https://registry.nlark.com/portfinder/download/portfinder-1.0.28.tgz#67c4622852bd5374dd1dd900f779f53462fac778" + integrity sha1-Z8RiKFK9U3TdHdkA93n1NGL6x3g= + dependencies: + async "^2.6.2" + debug "^3.1.1" + mkdirp "^0.5.5" + +posix-character-classes@^0.1.0: + version "0.1.1" + resolved "https://registry.nlark.com/posix-character-classes/download/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" + integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= + +postcss-html-transform@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/postcss-html-transform/download/postcss-html-transform-3.3.12.tgz?cache=0&sync_timestamp=1635492013021&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpostcss-html-transform%2Fdownload%2Fpostcss-html-transform-3.3.12.tgz#f70ffd679c8cb03def728873b9187466c853f593" + integrity sha1-9w/9Z5yMsD3vcohzuRh0ZshT9ZM= + dependencies: + postcss "^6.0.22" + +postcss-html@^0.28.0: + version "0.28.0" + resolved "https://registry.npmmirror.com/postcss-html/download/postcss-html-0.28.0.tgz?cache=0&sync_timestamp=1635469691376&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpostcss-html%2Fdownload%2Fpostcss-html-0.28.0.tgz#3dd0f5b5d7f886b8181bf844396d43a7898162cb" + integrity sha1-PdD1tdf4hrgYG/hEOW1Dp4mBYss= + dependencies: + htmlparser2 "^3.9.2" + +postcss-import@12.0.1: + version "12.0.1" + resolved "https://registry.nlark.com/postcss-import/download/postcss-import-12.0.1.tgz#cf8c7ab0b5ccab5649024536e565f841928b7153" + integrity sha1-z4x6sLXMq1ZJAkU25WX4QZKLcVM= + dependencies: + postcss "^7.0.1" + postcss-value-parser "^3.2.3" + read-cache "^1.0.0" + resolve "^1.1.7" + +postcss-less@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/postcss-less/download/postcss-less-2.0.0.tgz?cache=0&sync_timestamp=1627346502477&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpostcss-less%2Fdownload%2Fpostcss-less-2.0.0.tgz#5d190b8e057ca446d60fe2e2587ad791c9029fb8" + integrity sha1-XRkLjgV8pEbWD+LiWHrXkckCn7g= + dependencies: + postcss "^5.2.16" + +postcss-loader@4.3.0: + version "4.3.0" + resolved "https://registry.npmmirror.com/postcss-loader/download/postcss-loader-4.3.0.tgz?cache=0&sync_timestamp=1634140473743&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpostcss-loader%2Fdownload%2Fpostcss-loader-4.3.0.tgz#2c4de9657cd4f07af5ab42bd60a673004da1b8cc" + integrity sha1-LE3pZXzU8Hr1q0K9YKZzAE2huMw= + dependencies: + cosmiconfig "^7.0.0" + klona "^2.0.4" + loader-utils "^2.0.0" + schema-utils "^3.0.0" + semver "^7.3.4" + +postcss-markdown@^0.28.0: + version "0.28.0" + resolved "https://registry.nlark.com/postcss-markdown/download/postcss-markdown-0.28.0.tgz#99d1c4e74967af9e9c98acb2e2b66df4b3c6ed86" + integrity sha1-mdHE50lnr56cmKyy4rZt9LPG7YY= + dependencies: + remark "^9.0.0" + unist-util-find-all-after "^1.0.2" + +postcss-media-query-parser@^0.2.3: + version "0.2.3" + resolved "https://registry.npm.taobao.org/postcss-media-query-parser/download/postcss-media-query-parser-0.2.3.tgz#27b39c6f4d94f81b1a73b8f76351c609e5cef244" + integrity sha1-J7Ocb02U+Bsac7j3Y1HGCeXO8kQ= + +postcss-modules-extract-imports@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/postcss-modules-extract-imports/download/postcss-modules-extract-imports-2.0.0.tgz#818719a1ae1da325f9832446b01136eeb493cd7e" + integrity sha1-gYcZoa4doyX5gyRGsBE27rSTzX4= + dependencies: + postcss "^7.0.5" + +postcss-modules-local-by-default@^3.0.2: + version "3.0.3" + resolved "https://registry.nlark.com/postcss-modules-local-by-default/download/postcss-modules-local-by-default-3.0.3.tgz#bb14e0cc78279d504dbdcbfd7e0ca28993ffbbb0" + integrity sha1-uxTgzHgnnVBNvcv9fgyiiZP/u7A= + dependencies: + icss-utils "^4.1.1" + postcss "^7.0.32" + postcss-selector-parser "^6.0.2" + postcss-value-parser "^4.1.0" + +postcss-modules-scope@^2.1.1, postcss-modules-scope@^2.2.0: + version "2.2.0" + resolved "https://registry.nlark.com/postcss-modules-scope/download/postcss-modules-scope-2.2.0.tgz#385cae013cc7743f5a7d7602d1073a89eaae62ee" + integrity sha1-OFyuATzHdD9afXYC0Qc6iequYu4= + dependencies: + postcss "^7.0.6" + postcss-selector-parser "^6.0.0" + +postcss-modules-values@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/postcss-modules-values/download/postcss-modules-values-3.0.0.tgz#5b5000d6ebae29b4255301b4a3a54574423e7f10" + integrity sha1-W1AA1uuuKbQlUwG0o6VFdEI+fxA= + dependencies: + icss-utils "^4.0.0" + postcss "^7.0.6" + +postcss-plugin-constparse@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/postcss-plugin-constparse/download/postcss-plugin-constparse-3.3.12.tgz#6b4ed309570fb94fd8049d6ca8ca99d7b484c9ed" + integrity sha1-a07TCVcPuU/YBJ1sqMqZ17SEye0= + dependencies: + postcss "^6.0.22" + +postcss-pxtorem@^4.0.1: + version "4.0.1" + resolved "https://registry.nlark.com/postcss-pxtorem/download/postcss-pxtorem-4.0.1.tgz#9c64d0efe4885473cc1cb0305c6ffc3ebb45b1cd" + integrity sha1-nGTQ7+SIVHPMHLAwXG/8PrtFsc0= + dependencies: + object-assign "^4.1.0" + postcss "^5.2.10" + +postcss-pxtransform@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/postcss-pxtransform/download/postcss-pxtransform-3.3.12.tgz?cache=0&sync_timestamp=1635491345097&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpostcss-pxtransform%2Fdownload%2Fpostcss-pxtransform-3.3.12.tgz#92411dd69d35a9fdd7f0973dd38316af28d65822" + integrity sha1-kkEd1p01qf3X8Jc904MWryjWWCI= + dependencies: + postcss "^6.0.16" + postcss-pxtorem "^4.0.1" + +postcss-reporter@^5.0.0: + version "5.0.0" + resolved "https://registry.npmmirror.com/postcss-reporter/download/postcss-reporter-5.0.0.tgz?cache=0&sync_timestamp=1634124713965&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fpostcss-reporter%2Fdownload%2Fpostcss-reporter-5.0.0.tgz#a14177fd1342829d291653f2786efd67110332c3" + integrity sha1-oUF3/RNCgp0pFlPyeG79ZxEDMsM= + dependencies: + chalk "^2.0.1" + lodash "^4.17.4" + log-symbols "^2.0.0" + postcss "^6.0.8" + +postcss-resolve-nested-selector@^0.1.1: + version "0.1.1" + resolved "https://registry.npm.taobao.org/postcss-resolve-nested-selector/download/postcss-resolve-nested-selector-0.1.1.tgz#29ccbc7c37dedfac304e9fff0bf1596b3f6a0e4e" + integrity sha1-Kcy8fDfe36wwTp//C/FZaz9qDk4= + +postcss-safe-parser@^3.0.1: + version "3.0.1" + resolved "https://registry.nlark.com/postcss-safe-parser/download/postcss-safe-parser-3.0.1.tgz#b753eff6c7c0aea5e8375fbe4cde8bf9063ff142" + integrity sha1-t1Pv9sfArqXoN1++TN6L+QY/8UI= + dependencies: + postcss "^6.0.6" + +postcss-sass@^0.3.0: + version "0.3.5" + resolved "https://registry.nlark.com/postcss-sass/download/postcss-sass-0.3.5.tgz#6d3e39f101a53d2efa091f953493116d32beb68c" + integrity sha1-bT458QGlPS76CR+VNJMRbTK+tow= + dependencies: + gonzales-pe "^4.2.3" + postcss "^7.0.1" + +postcss-scss@^1.0.2: + version "1.0.6" + resolved "https://registry.npmmirror.com/postcss-scss/download/postcss-scss-1.0.6.tgz#ab903f3bb20161bc177896462293a53d4bff5f7a" + integrity sha1-q5A/O7IBYbwXeJZGIpOlPUv/X3o= + dependencies: + postcss "^6.0.23" + +postcss-selector-parser@^3.1.0: + version "3.1.2" + resolved "https://registry.nlark.com/postcss-selector-parser/download/postcss-selector-parser-3.1.2.tgz?cache=0&sync_timestamp=1620752939806&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpostcss-selector-parser%2Fdownload%2Fpostcss-selector-parser-3.1.2.tgz#b310f5c4c0fdaf76f94902bbaa30db6aa84f5270" + integrity sha1-sxD1xMD9r3b5SQK7qjDbaqhPUnA= + dependencies: + dot-prop "^5.2.0" + indexes-of "^1.0.1" + uniq "^1.0.1" + +postcss-selector-parser@^6.0.0, postcss-selector-parser@^6.0.2: + version "6.0.6" + resolved "https://registry.nlark.com/postcss-selector-parser/download/postcss-selector-parser-6.0.6.tgz?cache=0&sync_timestamp=1620752939806&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpostcss-selector-parser%2Fdownload%2Fpostcss-selector-parser-6.0.6.tgz#2c5bba8174ac2f6981ab631a42ab0ee54af332ea" + integrity sha1-LFu6gXSsL2mBq2MaQqsO5UrzMuo= + dependencies: + cssesc "^3.0.0" + util-deprecate "^1.0.2" + +postcss-syntax@^0.28.0: + version "0.28.0" + resolved "https://registry.npm.taobao.org/postcss-syntax/download/postcss-syntax-0.28.0.tgz#e17572a7dcf5388f0c9b68232d2dad48fa7f0b12" + integrity sha1-4XVyp9z1OI8Mm2gjLS2tSPp/CxI= + +postcss-url@8.0.0: + version "8.0.0" + resolved "https://registry.nlark.com/postcss-url/download/postcss-url-8.0.0.tgz#7b10059bd12929cdbb1971c60f61a0e5af86b4ca" + integrity sha1-exAFm9EpKc27GXHGD2Gg5a+GtMo= + dependencies: + mime "^2.3.1" + minimatch "^3.0.4" + mkdirp "^0.5.0" + postcss "^7.0.2" + xxhashjs "^0.2.1" + +postcss-value-parser@^3.2.3, postcss-value-parser@^3.3.0: + version "3.3.1" + resolved "https://registry.nlark.com/postcss-value-parser/download/postcss-value-parser-3.3.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpostcss-value-parser%2Fdownload%2Fpostcss-value-parser-3.3.1.tgz#9ff822547e2893213cf1c30efa51ac5fd1ba8281" + integrity sha1-n/giVH4okyE88cMO+lGsX9G6goE= + +postcss-value-parser@^4.0.2, postcss-value-parser@^4.1.0: + version "4.1.0" + resolved "https://registry.nlark.com/postcss-value-parser/download/postcss-value-parser-4.1.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpostcss-value-parser%2Fdownload%2Fpostcss-value-parser-4.1.0.tgz#443f6a20ced6481a2bda4fa8532a6e55d789a2cb" + integrity sha1-RD9qIM7WSBor2k+oUypuVdeJoss= + +postcss@7.0.21: + version "7.0.21" + resolved "https://registry.npmmirror.com/postcss/download/postcss-7.0.21.tgz#06bb07824c19c2021c5d056d5b10c35b989f7e17" + integrity sha1-BrsHgkwZwgIcXQVtWxDDW5iffhc= + dependencies: + chalk "^2.4.2" + source-map "^0.6.1" + supports-color "^6.1.0" + +postcss@8.3.5: + version "8.3.5" + resolved "https://registry.npmmirror.com/postcss/download/postcss-8.3.5.tgz#982216b113412bc20a86289e91eb994952a5b709" + integrity sha1-mCIWsRNBK8IKhiiekeuZSVKltwk= + dependencies: + colorette "^1.2.2" + nanoid "^3.1.23" + source-map-js "^0.6.2" + +postcss@^5.2.10, postcss@^5.2.16: + version "5.2.18" + resolved "https://registry.npmmirror.com/postcss/download/postcss-5.2.18.tgz#badfa1497d46244f6390f58b319830d9107853c5" + integrity sha1-ut+hSX1GJE9jkPWLMZgw2RB4U8U= + dependencies: + chalk "^1.1.3" + js-base64 "^2.1.9" + source-map "^0.5.6" + supports-color "^3.2.3" + +postcss@^6.0.14, postcss@^6.0.16, postcss@^6.0.22, postcss@^6.0.23, postcss@^6.0.6, postcss@^6.0.8: + version "6.0.23" + resolved "https://registry.npmmirror.com/postcss/download/postcss-6.0.23.tgz#61c82cc328ac60e677645f979054eb98bc0e3324" + integrity sha1-YcgswyisYOZ3ZF+XkFTrmLwOMyQ= + dependencies: + chalk "^2.4.1" + source-map "^0.6.1" + supports-color "^5.4.0" + +postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.2, postcss@^7.0.23, postcss@^7.0.26, postcss@^7.0.32, postcss@^7.0.35, postcss@^7.0.5, postcss@^7.0.6: + version "7.0.39" + resolved "https://registry.npmmirror.com/postcss/download/postcss-7.0.39.tgz#9624375d965630e2e1f2c02a935c82a59cb48309" + integrity sha1-liQ3XZZWMOLh8sAqk1yCpZy0gwk= + dependencies: + picocolors "^0.2.1" + source-map "^0.6.1" + +prelude-ls@~1.1.2: + version "1.1.2" + resolved "https://registry.nlark.com/prelude-ls/download/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" + integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= + +prepend-http@^1.0.0: + version "1.0.4" + resolved "https://registry.nlark.com/prepend-http/download/prepend-http-1.0.4.tgz?cache=0&sync_timestamp=1628547439455&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fprepend-http%2Fdownload%2Fprepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc" + integrity sha1-1PRWKwzjaW5BrFLQ4ALlemNdxtw= + +preserve@^0.2.0: + version "0.2.0" + resolved "https://registry.nlark.com/preserve/download/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b" + integrity sha1-gV7R9uvGWSb4ZbMQwHE7yzMVzks= + +pretty-bytes@^5.3.0: + version "5.6.0" + resolved "https://registry.npm.taobao.org/pretty-bytes/download/pretty-bytes-5.6.0.tgz#356256f643804773c82f64723fe78c92c62beaeb" + integrity sha1-NWJW9kOAR3PIL2RyP+eMksYr6us= + +pretty-error@^2.0.2: + version "2.1.2" + resolved "https://registry.npmmirror.com/pretty-error/download/pretty-error-2.1.2.tgz#be89f82d81b1c86ec8fdfbc385045882727f93b6" + integrity sha1-von4LYGxyG7I/fvDhQRYgnJ/k7Y= + dependencies: + lodash "^4.17.20" + renderkid "^2.0.4" + +process-nextick-args@~2.0.0: + version "2.0.1" + resolved "https://registry.npm.taobao.org/process-nextick-args/download/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" + integrity sha1-eCDZsWEgzFXKmud5JoCufbptf+I= + +process@^0.11.10: + version "0.11.10" + resolved "https://registry.npm.taobao.org/process/download/process-0.11.10.tgz#7332300e840161bda3e69a1d1d91a7d4bc16f182" + integrity sha1-czIwDoQBYb2j5podHZGn1LwW8YI= + +progress@^2.0.0: + version "2.0.3" + resolved "https://registry.nlark.com/progress/download/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" + integrity sha1-foz42PW48jnBvGi+tOt4Vn1XLvg= + +promise-inflight@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/promise-inflight/download/promise-inflight-1.0.1.tgz#98472870bf228132fcbdd868129bad12c3c029e3" + integrity sha1-mEcocL8igTL8vdhoEputEsPAKeM= + +promise@^8.1.0: + version "8.1.0" + resolved "https://registry.npmmirror.com/promise/-/promise-8.1.0.tgz#697c25c3dfe7435dd79fcd58c38a135888eaf05e" + integrity sha512-W04AqnILOL/sPRXziNicCjSNRruLAuIHEOVBazepu0545DDNGYHz7ar9ZgZ1fMU8/MA4mVxp5rkBWRi6OXIy3Q== + dependencies: + asap "~2.0.6" + +prop-types@^15.6.1, prop-types@^15.6.2, prop-types@^15.7.2: + version "15.7.2" + resolved "https://registry.nlark.com/prop-types/download/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5" + integrity sha1-UsQedbjIfnK52TYOAga5ncv/psU= + dependencies: + loose-envify "^1.4.0" + object-assign "^4.1.1" + react-is "^16.8.1" + +proxy-addr@~2.0.5: + version "2.0.7" + resolved "https://registry.nlark.com/proxy-addr/download/proxy-addr-2.0.7.tgz#f19fe69ceab311eeb94b42e70e8c2070f9ba1025" + integrity sha1-8Z/mnOqzEe65S0LnDowgcPm6ECU= + dependencies: + forwarded "0.2.0" + ipaddr.js "1.9.1" + +prr@~1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/prr/download/prr-1.0.1.tgz#d3fc114ba06995a45ec6893f484ceb1d78f5f476" + integrity sha1-0/wRS6BplaRexok/SEzrHXj19HY= + +pseudomap@^1.0.2: + version "1.0.2" + resolved "https://registry.npm.taobao.org/pseudomap/download/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" + integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= + +psl@^1.1.28: + version "1.8.0" + resolved "https://registry.npm.taobao.org/psl/download/psl-1.8.0.tgz#9326f8bcfb013adcc005fdff056acce020e51c24" + integrity sha1-kyb4vPsBOtzABf3/BWrM4CDlHCQ= + +public-encrypt@^4.0.0: + version "4.0.3" + resolved "https://registry.npm.taobao.org/public-encrypt/download/public-encrypt-4.0.3.tgz#4fcc9d77a07e48ba7527e7cbe0de33d0701331e0" + integrity sha1-T8ydd6B+SLp1J+fL4N4z0HATMeA= + dependencies: + bn.js "^4.1.0" + browserify-rsa "^4.0.0" + create-hash "^1.1.0" + parse-asn1 "^5.0.0" + randombytes "^2.0.1" + safe-buffer "^5.1.2" + +pump@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/pump/download/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909" + integrity sha1-Ejma3W5M91Jtlzy8i1zi4pCLOQk= + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + +pump@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/pump/download/pump-3.0.0.tgz#b4a2116815bde2f4e1ea602354e8c75565107a64" + integrity sha1-tKIRaBW94vTh6mAjVOjHVWUQemQ= + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + +pumpify@^1.3.3: + version "1.5.1" + resolved "https://registry.npm.taobao.org/pumpify/download/pumpify-1.5.1.tgz#36513be246ab27570b1a374a5ce278bfd74370ce" + integrity sha1-NlE74karJ1cLGjdKXOJ4v9dDcM4= + dependencies: + duplexify "^3.6.0" + inherits "^2.0.3" + pump "^2.0.0" + +punycode@1.3.2: + version "1.3.2" + resolved "https://registry.nlark.com/punycode/download/punycode-1.3.2.tgz?cache=0&sync_timestamp=1622604519710&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpunycode%2Fdownload%2Fpunycode-1.3.2.tgz#9653a036fb7c1ee42342f2325cceefea3926c48d" + integrity sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0= + +punycode@^1.2.4: + version "1.4.1" + resolved "https://registry.nlark.com/punycode/download/punycode-1.4.1.tgz?cache=0&sync_timestamp=1622604519710&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpunycode%2Fdownload%2Fpunycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" + integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= + +punycode@^2.1.0, punycode@^2.1.1: + version "2.1.1" + resolved "https://registry.nlark.com/punycode/download/punycode-2.1.1.tgz?cache=0&sync_timestamp=1622604519710&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fpunycode%2Fdownload%2Fpunycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" + integrity sha1-tYsBCsQMIsVldhbI0sLALHv0eew= + +qs@6.7.0: + version "6.7.0" + resolved "https://registry.nlark.com/qs/download/qs-6.7.0.tgz#41dc1a015e3d581f1621776be31afb2876a9b1bc" + integrity sha1-QdwaAV49WB8WIXdr4xr7KHapsbw= + +qs@~6.5.2: + version "6.5.2" + resolved "https://registry.nlark.com/qs/download/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" + integrity sha1-yzroBuh0BERYTvFUzo7pjUA/PjY= + +query-string@^4.1.0: + version "4.3.4" + resolved "https://registry.nlark.com/query-string/download/query-string-4.3.4.tgz?cache=0&sync_timestamp=1624297034221&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fquery-string%2Fdownload%2Fquery-string-4.3.4.tgz#bbb693b9ca915c232515b228b1a02b609043dbeb" + integrity sha1-u7aTucqRXCMlFbIosaArYJBD2+s= + dependencies: + object-assign "^4.1.0" + strict-uri-encode "^1.0.0" + +query-string@^6.13.8: + version "6.14.1" + resolved "https://registry.nlark.com/query-string/download/query-string-6.14.1.tgz?cache=0&sync_timestamp=1624297034221&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fquery-string%2Fdownload%2Fquery-string-6.14.1.tgz#7ac2dca46da7f309449ba0f86b1fd28255b0c86a" + integrity sha1-esLcpG2n8wlEm6D4ax/SglWwyGo= + dependencies: + decode-uri-component "^0.2.0" + filter-obj "^1.1.0" + split-on-first "^1.0.0" + strict-uri-encode "^2.0.0" + +querystring-es3@^0.2.0: + version "0.2.1" + resolved "https://registry.nlark.com/querystring-es3/download/querystring-es3-0.2.1.tgz#9ec61f79049875707d69414596fd907a4d711e73" + integrity sha1-nsYfeQSYdXB9aUFFlv2Qek1xHnM= + +querystring@0.2.0: + version "0.2.0" + resolved "https://registry.npmmirror.com/querystring/download/querystring-0.2.0.tgz#b209849203bb25df820da756e747005878521620" + integrity sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA= + +querystring@^0.2.0: + version "0.2.1" + resolved "https://registry.npmmirror.com/querystring/download/querystring-0.2.1.tgz#40d77615bb09d16902a85c3e38aa8b5ed761c2dd" + integrity sha1-QNd2FbsJ0WkCqFw+OKqLXtdhwt0= + +querystringify@^2.1.1: + version "2.2.0" + resolved "https://registry.npm.taobao.org/querystringify/download/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" + integrity sha1-M0WUG0FTy50ILY7uTNogFqmu9/Y= + +queue-microtask@^1.2.2: + version "1.2.3" + resolved "https://registry.nlark.com/queue-microtask/download/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" + integrity sha1-SSkii7xyTfrEPg77BYyve2z7YkM= + +quick-lru@^1.0.0: + version "1.1.0" + resolved "https://registry.nlark.com/quick-lru/download/quick-lru-1.1.0.tgz#4360b17c61136ad38078397ff11416e186dcfbb8" + integrity sha1-Q2CxfGETatOAeDl/8RQW4Ybc+7g= + +raf@^3.4.1: + version "3.4.1" + resolved "https://registry.npm.taobao.org/raf/download/raf-3.4.1.tgz#0742e99a4a6552f445d73e3ee0328af0ff1ede39" + integrity sha1-B0LpmkplUvRF1z4+4DKK8P8e3jk= + dependencies: + performance-now "^2.1.0" + +randomatic@^3.0.0: + version "3.1.1" + resolved "https://registry.npm.taobao.org/randomatic/download/randomatic-3.1.1.tgz#b776efc59375984e36c537b2f51a1f0aff0da1ed" + integrity sha1-t3bvxZN1mE42xTey9RofCv8Noe0= + dependencies: + is-number "^4.0.0" + kind-of "^6.0.0" + math-random "^1.0.1" + +randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.5, randombytes@^2.1.0: + version "2.1.0" + resolved "https://registry.npm.taobao.org/randombytes/download/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" + integrity sha1-32+ENy8CcNxlzfYpE0mrekc9Tyo= + dependencies: + safe-buffer "^5.1.0" + +randomfill@^1.0.3: + version "1.0.4" + resolved "https://registry.nlark.com/randomfill/download/randomfill-1.0.4.tgz#c92196fc86ab42be983f1bf31778224931d61458" + integrity sha1-ySGW/IarQr6YPxvzF3giSTHWFFg= + dependencies: + randombytes "^2.0.5" + safe-buffer "^5.1.0" + +range-parser@^1.2.1, range-parser@~1.2.1: + version "1.2.1" + resolved "https://registry.npm.taobao.org/range-parser/download/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" + integrity sha1-PPNwI9GZ4cJNGlW4SADC8+ZGgDE= + +raw-body@2.4.0: + version "2.4.0" + resolved "https://registry.nlark.com/raw-body/download/raw-body-2.4.0.tgz#a1ce6fb9c9bc356ca52e89256ab59059e13d0332" + integrity sha1-oc5vucm8NWylLoklarWQWeE9AzI= + dependencies: + bytes "3.1.0" + http-errors "1.7.2" + iconv-lite "0.4.24" + unpipe "1.0.0" + +react-dom@^17.0.0: + version "17.0.2" + resolved "https://registry.npmmirror.com/react-dom/download/react-dom-17.0.2.tgz?cache=0&sync_timestamp=1636128949790&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freact-dom%2Fdownload%2Freact-dom-17.0.2.tgz#ecffb6845e3ad8dbfcdc498f0d0a939736502c23" + integrity sha1-7P+2hF462Nv83EmPDQqTlzZQLCM= + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + scheduler "^0.20.2" + +react-is@^16.4.2, react-is@^16.7.0, react-is@^16.8.1: + version "16.13.1" + resolved "https://registry.npmmirror.com/react-is/download/react-is-16.13.1.tgz?cache=0&sync_timestamp=1636128974679&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freact-is%2Fdownload%2Freact-is-16.13.1.tgz#789729a4dc36de2999dc156dd6c1d9c18cea56a4" + integrity sha1-eJcppNw23imZ3BVt1sHZwYzqVqQ= + +react-is@^17.0.2: + version "17.0.2" + resolved "https://registry.npmmirror.com/react-is/download/react-is-17.0.2.tgz?cache=0&sync_timestamp=1636128974679&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freact-is%2Fdownload%2Freact-is-17.0.2.tgz#e691d4a8e9c789365655539ab372762b0efb54f0" + integrity sha1-5pHUqOnHiTZWVVOas3J2Kw77VPA= + +react-reconciler@0.26.1: + version "0.26.1" + resolved "https://registry.npmmirror.com/react-reconciler/download/react-reconciler-0.26.1.tgz?cache=0&sync_timestamp=1636129571513&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freact-reconciler%2Fdownload%2Freact-reconciler-0.26.1.tgz#860952dd359fd870f94895c254271e3a9de3b2d6" + integrity sha1-hglS3TWf2HD5SJXCVCceOp3jstY= + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + scheduler "^0.20.1" + +react-redux@^7.2.0: + version "7.2.6" + resolved "https://registry.npmmirror.com/react-redux/download/react-redux-7.2.6.tgz?cache=0&sync_timestamp=1635866045304&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freact-redux%2Fdownload%2Freact-redux-7.2.6.tgz#49633a24fe552b5f9caf58feb8a138936ddfe9aa" + integrity sha1-SWM6JP5VK1+cr1j+uKE4k23f6ao= + dependencies: + "@babel/runtime" "^7.15.4" + "@types/react-redux" "^7.1.20" + hoist-non-react-statics "^3.3.2" + loose-envify "^1.4.0" + prop-types "^15.7.2" + react-is "^17.0.2" + +react-refresh@0.9.0: + version "0.9.0" + resolved "https://registry.npmmirror.com/react-refresh/download/react-refresh-0.9.0.tgz?cache=0&sync_timestamp=1636128953145&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freact-refresh%2Fdownload%2Freact-refresh-0.9.0.tgz#71863337adc3e5c2f8a6bfddd12ae3bfe32aafbf" + integrity sha1-cYYzN63D5cL4pr/d0Srjv+Mqr78= + +react-refresh@^0.4.0: + version "0.4.3" + resolved "https://registry.npmmirror.com/react-refresh/download/react-refresh-0.4.3.tgz?cache=0&sync_timestamp=1636128953145&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freact-refresh%2Fdownload%2Freact-refresh-0.4.3.tgz#966f1750c191672e76e16c2efa569150cc73ab53" + integrity sha1-lm8XUMGRZy524Wwu+laRUMxzq1M= + +react-transition-group@^4.4.1: + version "4.4.2" + resolved "https://registry.nlark.com/react-transition-group/download/react-transition-group-4.4.2.tgz?cache=0&sync_timestamp=1622301030407&other_urls=https%3A%2F%2Fregistry.nlark.com%2Freact-transition-group%2Fdownload%2Freact-transition-group-4.4.2.tgz#8b59a56f09ced7b55cbd53c36768b922890d5470" + integrity sha1-i1mlbwnO17VcvVPDZ2i5IokNVHA= + dependencies: + "@babel/runtime" "^7.5.5" + dom-helpers "^5.0.1" + loose-envify "^1.4.0" + prop-types "^15.6.2" + +react@^17.0.0, react@^17.0.2: + version "17.0.2" + resolved "https://registry.npmmirror.com/react/download/react-17.0.2.tgz#d0b5cc516d29eb3eee383f75b62864cfb6800037" + integrity sha1-0LXMUW0p6z7uOD91tihkz7aAADc= + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + +read-cache@^1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/read-cache/download/read-cache-1.0.0.tgz#e664ef31161166c9751cdbe8dbcf86b5fb58f774" + integrity sha1-5mTvMRYRZsl1HNvo28+GtftY93Q= + dependencies: + pify "^2.3.0" + +read-pkg-up@^1.0.1: + version "1.0.1" + resolved "https://registry.npmmirror.com/read-pkg-up/download/read-pkg-up-1.0.1.tgz#9d63c13276c065918d57f002a57f40a1b643fb02" + integrity sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI= + dependencies: + find-up "^1.0.0" + read-pkg "^1.0.0" + +read-pkg-up@^3.0.0: + version "3.0.0" + resolved "https://registry.npmmirror.com/read-pkg-up/download/read-pkg-up-3.0.0.tgz#3ed496685dba0f8fe118d0691dc51f4a1ff96f07" + integrity sha1-PtSWaF26D4/hGNBpHcUfSh/5bwc= + dependencies: + find-up "^2.0.0" + read-pkg "^3.0.0" + +read-pkg@^1.0.0: + version "1.1.0" + resolved "https://registry.nlark.com/read-pkg/download/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" + integrity sha1-9f+qXs0pyzHAR0vKfXVra7KePyg= + dependencies: + load-json-file "^1.0.0" + normalize-package-data "^2.3.2" + path-type "^1.0.0" + +read-pkg@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/read-pkg/download/read-pkg-3.0.0.tgz#9cbc686978fee65d16c00e2b19c237fcf6e38389" + integrity sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k= + dependencies: + load-json-file "^4.0.0" + normalize-package-data "^2.3.2" + path-type "^3.0.0" + +"readable-stream@1 || 2", readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.3, readable-stream@^2.3.6, readable-stream@~2.3.6: + version "2.3.7" + resolved "https://registry.npm.taobao.org/readable-stream/download/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" + integrity sha1-Hsoc9xGu+BTAT2IlKjamL2yyO1c= + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.3" + isarray "~1.0.0" + process-nextick-args "~2.0.0" + safe-buffer "~5.1.1" + string_decoder "~1.1.1" + util-deprecate "~1.0.1" + +readable-stream@1.1: + version "1.1.13" + resolved "https://registry.npm.taobao.org/readable-stream/download/readable-stream-1.1.13.tgz#f6eef764f514c89e2b9e23146a75ba106756d23e" + integrity sha1-9u73ZPUUyJ4rniMUanW6EGdW0j4= + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.1" + isarray "0.0.1" + string_decoder "~0.10.x" + +readable-stream@^3.0.6, readable-stream@^3.1.1, readable-stream@^3.6.0: + version "3.6.0" + resolved "https://registry.npm.taobao.org/readable-stream/download/readable-stream-3.6.0.tgz#337bbda3adc0706bd3e024426a286d4b4b2c9198" + integrity sha1-M3u9o63AcGvT4CRCaihtS0sskZg= + dependencies: + inherits "^2.0.3" + string_decoder "^1.1.1" + util-deprecate "^1.0.1" + +readdirp@^2.2.1: + version "2.2.1" + resolved "https://registry.nlark.com/readdirp/download/readdirp-2.2.1.tgz#0e87622a3325aa33e892285caf8b4e846529a525" + integrity sha1-DodiKjMlqjPokihcr4tOhGUppSU= + dependencies: + graceful-fs "^4.1.11" + micromatch "^3.1.10" + readable-stream "^2.0.2" + +readdirp@~3.3.0: + version "3.3.0" + resolved "https://registry.nlark.com/readdirp/download/readdirp-3.3.0.tgz#984458d13a1e42e2e9f5841b129e162f369aff17" + integrity sha1-mERY0ToeQuLp9YQbEp4WLzaa/xc= + dependencies: + picomatch "^2.0.7" + +readdirp@~3.6.0: + version "3.6.0" + resolved "https://registry.nlark.com/readdirp/download/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7" + integrity sha1-dKNwvYVxFuJFspzJc0DNQxoCpsc= + dependencies: + picomatch "^2.2.1" + +redent@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/redent/download/redent-1.0.0.tgz#cf916ab1fd5f1f16dfb20822dd6ec7f730c2afde" + integrity sha1-z5Fqsf1fHxbfsggi3W7H9zDCr94= + dependencies: + indent-string "^2.1.0" + strip-indent "^1.0.1" + +redent@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/redent/download/redent-2.0.0.tgz#c1b2007b42d57eb1389079b3c8333639d5e1ccaa" + integrity sha1-wbIAe0LVfrE4kHmzyDM2OdXhzKo= + dependencies: + indent-string "^3.0.0" + strip-indent "^2.0.0" + +redux-devtools-extension@^2.13.9: + version "2.13.9" + resolved "https://registry.nlark.com/redux-devtools-extension/download/redux-devtools-extension-2.13.9.tgz#6b764e8028b507adcb75a1cae790f71e6be08ae7" + integrity sha1-a3ZOgCi1B63LdaHK55D3Hmvgiuc= + +redux-form@^8.3.7: + version "8.3.7" + resolved "https://registry.npm.taobao.org/redux-form/download/redux-form-8.3.7.tgz#24eb6d8b8b37098b4702fc4c52b6596b01a71c82" + integrity sha1-JOtti4s3CYtHAvxMUrZZawGnHII= + dependencies: + "@babel/runtime" "^7.9.2" + es6-error "^4.1.1" + hoist-non-react-statics "^3.3.2" + invariant "^2.2.4" + is-promise "^2.1.0" + lodash "^4.17.15" + prop-types "^15.6.1" + react-is "^16.4.2" + +redux-logger@^3.0.6: + version "3.0.6" + resolved "https://registry.npm.taobao.org/redux-logger/download/redux-logger-3.0.6.tgz#f7555966f3098f3c88604c449cf0baf5778274bf" + integrity sha1-91VZZvMJjzyIYExEnPC69XeCdL8= + dependencies: + deep-diff "^0.3.5" + +redux-saga@^1.1.3: + version "1.1.3" + resolved "https://registry.npm.taobao.org/redux-saga/download/redux-saga-1.1.3.tgz#9f3e6aebd3c994bbc0f6901a625f9a42b51d1112" + integrity sha1-nz5q69PJlLvA9pAaYl+aQrUdERI= + dependencies: + "@redux-saga/core" "^1.1.3" + +redux@^4.0.0, redux@^4.0.4: + version "4.1.2" + resolved "https://registry.npmmirror.com/redux/download/redux-4.1.2.tgz?cache=0&sync_timestamp=1635662905052&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fredux%2Fdownload%2Fredux-4.1.2.tgz#140f35426d99bb4729af760afcf79eaaac407104" + integrity sha1-FA81Qm2Zu0cpr3YK/PeeqqxAcQQ= + dependencies: + "@babel/runtime" "^7.9.2" + +reflect-metadata@^0.1.13: + version "0.1.13" + resolved "https://registry.npm.taobao.org/reflect-metadata/download/reflect-metadata-0.1.13.tgz#67ae3ca57c972a2aa1642b10fe363fe32d49dc08" + integrity sha1-Z648pXyXKiqhZCsQ/jY/4y1J3Ag= + +regenerate-unicode-properties@^10.0.1: + version "10.0.1" + resolved "https://registry.npmmirror.com/regenerate-unicode-properties/-/regenerate-unicode-properties-10.0.1.tgz#7f442732aa7934a3740c779bb9b3340dccc1fb56" + integrity sha512-vn5DU6yg6h8hP/2OkQo3K7uVILvY4iu0oI4t3HFa81UPkhGJwkRwM10JEc3upjdhHjs/k8GJY1sRBhk5sr69Bw== + dependencies: + regenerate "^1.4.2" + +regenerate-unicode-properties@^9.0.0: + version "9.0.0" + resolved "https://registry.nlark.com/regenerate-unicode-properties/download/regenerate-unicode-properties-9.0.0.tgz?cache=0&sync_timestamp=1631617161322&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregenerate-unicode-properties%2Fdownload%2Fregenerate-unicode-properties-9.0.0.tgz#54d09c7115e1f53dc2314a974b32c1c344efe326" + integrity sha1-VNCccRXh9T3CMUqXSzLBw0Tv4yY= + dependencies: + regenerate "^1.4.2" + +regenerate@^1.4.2: + version "1.4.2" + resolved "https://registry.npm.taobao.org/regenerate/download/regenerate-1.4.2.tgz?cache=0&sync_timestamp=1604218353677&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fregenerate%2Fdownload%2Fregenerate-1.4.2.tgz#b9346d8827e8f5a32f7ba29637d398b69014848a" + integrity sha1-uTRtiCfo9aMve6KWN9OYtpAUhIo= + +regenerator-runtime@0.11, regenerator-runtime@^0.11.0: + version "0.11.1" + resolved "https://registry.nlark.com/regenerator-runtime/download/regenerator-runtime-0.11.1.tgz?cache=0&sync_timestamp=1626993001371&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregenerator-runtime%2Fdownload%2Fregenerator-runtime-0.11.1.tgz#be05ad7f9bf7d22e056f9726cee5017fbf19e2e9" + integrity sha1-vgWtf5v30i4Fb5cmzuUBf78Z4uk= + +regenerator-runtime@^0.13.4: + version "0.13.9" + resolved "https://registry.nlark.com/regenerator-runtime/download/regenerator-runtime-0.13.9.tgz?cache=0&sync_timestamp=1626993001371&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregenerator-runtime%2Fdownload%2Fregenerator-runtime-0.13.9.tgz#8925742a98ffd90814988d7566ad30ca3b263b52" + integrity sha1-iSV0Kpj/2QgUmI11Zq0wyjsmO1I= + +regenerator-transform@^0.14.2: + version "0.14.5" + resolved "https://registry.nlark.com/regenerator-transform/download/regenerator-transform-0.14.5.tgz?cache=0&sync_timestamp=1627057533376&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregenerator-transform%2Fdownload%2Fregenerator-transform-0.14.5.tgz#c98da154683671c9c4dcb16ece736517e1b7feb4" + integrity sha1-yY2hVGg2ccnE3LFuznNlF+G3/rQ= + dependencies: + "@babel/runtime" "^7.8.4" + +regex-cache@^0.4.2: + version "0.4.4" + resolved "https://registry.nlark.com/regex-cache/download/regex-cache-0.4.4.tgz#75bdc58a2a1496cec48a12835bc54c8d562336dd" + integrity sha1-db3FiioUls7EihKDW8VMjVYjNt0= + dependencies: + is-equal-shallow "^0.1.3" + +regex-not@^1.0.0, regex-not@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/regex-not/download/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" + integrity sha1-H07OJ+ALC2XgJHpoEOaoXYOldSw= + dependencies: + extend-shallow "^3.0.2" + safe-regex "^1.1.0" + +regex-parser@2.2.10: + version "2.2.10" + resolved "https://registry.nlark.com/regex-parser/download/regex-parser-2.2.10.tgz#9e66a8f73d89a107616e63b39d4deddfee912b37" + integrity sha1-nmao9z2JoQdhbmOznU3t3+6RKzc= + +regex-parser@^2.2.11: + version "2.2.11" + resolved "https://registry.nlark.com/regex-parser/download/regex-parser-2.2.11.tgz#3b37ec9049e19479806e878cabe7c1ca83ccfe58" + integrity sha1-OzfskEnhlHmAboeMq+fByoPM/lg= + +regexp.prototype.flags@^1.2.0, regexp.prototype.flags@^1.3.1: + version "1.3.1" + resolved "https://registry.nlark.com/regexp.prototype.flags/download/regexp.prototype.flags-1.3.1.tgz#7ef352ae8d159e758c0eadca6f8fcb4eef07be26" + integrity sha1-fvNSro0VnnWMDq3Kb4/LTu8HviY= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + +regexpp@^2.0.1: + version "2.0.1" + resolved "https://registry.nlark.com/regexpp/download/regexpp-2.0.1.tgz?cache=0&sync_timestamp=1623669331185&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregexpp%2Fdownload%2Fregexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" + integrity sha1-jRnTHPYySCtYkEn4KB+T28uk0H8= + +regexpp@^3.1.0: + version "3.2.0" + resolved "https://registry.nlark.com/regexpp/download/regexpp-3.2.0.tgz?cache=0&sync_timestamp=1623669331185&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregexpp%2Fdownload%2Fregexpp-3.2.0.tgz#0425a2768d8f23bad70ca4b90461fa2f1213e1b2" + integrity sha1-BCWido2PI7rXDKS5BGH6LxIT4bI= + +regexpu-core@^4.7.1: + version "4.8.0" + resolved "https://registry.nlark.com/regexpu-core/download/regexpu-core-4.8.0.tgz?cache=0&sync_timestamp=1631619113277&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregexpu-core%2Fdownload%2Fregexpu-core-4.8.0.tgz#e5605ba361b67b1718478501327502f4479a98f0" + integrity sha1-5WBbo2G2excYR4UBMnUC9EeamPA= + dependencies: + regenerate "^1.4.2" + regenerate-unicode-properties "^9.0.0" + regjsgen "^0.5.2" + regjsparser "^0.7.0" + unicode-match-property-ecmascript "^2.0.0" + unicode-match-property-value-ecmascript "^2.0.0" + +regexpu-core@^5.0.1: + version "5.0.1" + resolved "https://registry.npmmirror.com/regexpu-core/-/regexpu-core-5.0.1.tgz#c531122a7840de743dcf9c83e923b5560323ced3" + integrity sha512-CriEZlrKK9VJw/xQGJpQM5rY88BtuL8DM+AEwvcThHilbxiTAy8vq4iJnd2tqq8wLmjbGZzP7ZcKFjbGkmEFrw== + dependencies: + regenerate "^1.4.2" + regenerate-unicode-properties "^10.0.1" + regjsgen "^0.6.0" + regjsparser "^0.8.2" + unicode-match-property-ecmascript "^2.0.0" + unicode-match-property-value-ecmascript "^2.0.0" + +regjsgen@^0.5.2: + version "0.5.2" + resolved "https://registry.npmmirror.com/regjsgen/download/regjsgen-0.5.2.tgz#92ff295fb1deecbf6ecdab2543d207e91aa33733" + integrity sha1-kv8pX7He7L9uzaslQ9IH6RqjNzM= + +regjsgen@^0.6.0: + version "0.6.0" + resolved "https://registry.npmmirror.com/regjsgen/-/regjsgen-0.6.0.tgz#83414c5354afd7d6627b16af5f10f41c4e71808d" + integrity sha512-ozE883Uigtqj3bx7OhL1KNbCzGyW2NQZPl6Hs09WTvCuZD5sTI4JY58bkbQWa/Y9hxIsvJ3M8Nbf7j54IqeZbA== + +regjsparser@^0.7.0: + version "0.7.0" + resolved "https://registry.nlark.com/regjsparser/download/regjsparser-0.7.0.tgz?cache=0&sync_timestamp=1630946816794&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fregjsparser%2Fdownload%2Fregjsparser-0.7.0.tgz#a6b667b54c885e18b52554cb4960ef71187e9968" + integrity sha1-prZntUyIXhi1JVTLSWDvcRh+mWg= + dependencies: + jsesc "~0.5.0" + +regjsparser@^0.8.2: + version "0.8.4" + resolved "https://registry.npmmirror.com/regjsparser/-/regjsparser-0.8.4.tgz#8a14285ffcc5de78c5b95d62bbf413b6bc132d5f" + integrity sha512-J3LABycON/VNEu3abOviqGHuB/LOtOQj8SKmfP9anY5GfAVw/SPjwzSjxGjbZXIxbGfqTHtJw58C2Li/WkStmA== + dependencies: + jsesc "~0.5.0" + +relateurl@0.2.x, relateurl@^0.2.7: + version "0.2.7" + resolved "https://registry.nlark.com/relateurl/download/relateurl-0.2.7.tgz#54dbf377e51440aca90a4cd274600d3ff2d888a9" + integrity sha1-VNvzd+UUQKypCkzSdGANP/LYiKk= + +remark-parse@^5.0.0: + version "5.0.0" + resolved "https://registry.nlark.com/remark-parse/download/remark-parse-5.0.0.tgz?cache=0&sync_timestamp=1627989796888&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fremark-parse%2Fdownload%2Fremark-parse-5.0.0.tgz#4c077f9e499044d1d5c13f80d7a98cf7b9285d95" + integrity sha1-TAd/nkmQRNHVwT+A16mM97koXZU= + dependencies: + collapse-white-space "^1.0.2" + is-alphabetical "^1.0.0" + is-decimal "^1.0.0" + is-whitespace-character "^1.0.0" + is-word-character "^1.0.0" + markdown-escapes "^1.0.0" + parse-entities "^1.1.0" + repeat-string "^1.5.4" + state-toggle "^1.0.0" + trim "0.0.1" + trim-trailing-lines "^1.0.0" + unherit "^1.0.4" + unist-util-remove-position "^1.0.0" + vfile-location "^2.0.0" + xtend "^4.0.1" + +remark-stringify@^5.0.0: + version "5.0.0" + resolved "https://registry.npmmirror.com/remark-stringify/download/remark-stringify-5.0.0.tgz#336d3a4d4a6a3390d933eeba62e8de4bd280afba" + integrity sha1-M206TUpqM5DZM+66YujeS9KAr7o= + dependencies: + ccount "^1.0.0" + is-alphanumeric "^1.0.0" + is-decimal "^1.0.0" + is-whitespace-character "^1.0.0" + longest-streak "^2.0.1" + markdown-escapes "^1.0.0" + markdown-table "^1.1.0" + mdast-util-compact "^1.0.0" + parse-entities "^1.0.2" + repeat-string "^1.5.4" + state-toggle "^1.0.0" + stringify-entities "^1.0.1" + unherit "^1.0.4" + xtend "^4.0.1" + +remark@^9.0.0: + version "9.0.0" + resolved "https://registry.nlark.com/remark/download/remark-9.0.0.tgz?cache=0&sync_timestamp=1628001517141&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fremark%2Fdownload%2Fremark-9.0.0.tgz#c5cfa8ec535c73a67c4b0f12bfdbd3a67d8b2f60" + integrity sha1-xc+o7FNcc6Z8Sw8Sv9vTpn2LL2A= + dependencies: + remark-parse "^5.0.0" + remark-stringify "^5.0.0" + unified "^6.0.0" + +remove-trailing-separator@^1.0.1: + version "1.1.0" + resolved "https://registry.nlark.com/remove-trailing-separator/download/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" + integrity sha1-wkvOKig62tW8P1jg1IJJuSN52O8= + +renderkid@^2.0.4: + version "2.0.7" + resolved "https://registry.npmmirror.com/renderkid/download/renderkid-2.0.7.tgz#464f276a6bdcee606f4a15993f9b29fc74ca8609" + integrity sha1-Rk8namvc7mBvShWZP5sp/HTKhgk= + dependencies: + css-select "^4.1.3" + dom-converter "^0.2.0" + htmlparser2 "^6.1.0" + lodash "^4.17.21" + strip-ansi "^3.0.1" + +repeat-element@^1.1.2: + version "1.1.4" + resolved "https://registry.npm.taobao.org/repeat-element/download/repeat-element-1.1.4.tgz#be681520847ab58c7568ac75fbfad28ed42d39e9" + integrity sha1-vmgVIIR6tYx1aKx1+/rSjtQtOek= + +repeat-string@^1.5.2, repeat-string@^1.5.4, repeat-string@^1.6.1: + version "1.6.1" + resolved "https://registry.nlark.com/repeat-string/download/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" + integrity sha1-jcrkcOHIirwtYA//Sndihtp15jc= + +repeating@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/repeating/download/repeating-2.0.1.tgz?cache=0&sync_timestamp=1622605325095&other_urls=https%3A%2F%2Fregistry.nlark.com%2Frepeating%2Fdownload%2Frepeating-2.0.1.tgz#5214c53a926d3552707527fbab415dbc08d06dda" + integrity sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo= + dependencies: + is-finite "^1.0.0" + +replace-ext@1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/replace-ext/download/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" + integrity sha1-3mMSg3P8v3w8z6TeWkgMRaZ5WOs= + +request-promise-core@1.1.4: + version "1.1.4" + resolved "https://registry.nlark.com/request-promise-core/download/request-promise-core-1.1.4.tgz#3eedd4223208d419867b78ce815167d10593a22f" + integrity sha1-Pu3UIjII1BmGe3jOgVFn0QWToi8= + dependencies: + lodash "^4.17.19" + +request-promise-native@^1.0.7: + version "1.0.9" + resolved "https://registry.npmmirror.com/request-promise-native/download/request-promise-native-1.0.9.tgz#e407120526a5efdc9a39b28a5679bf47b9d9dc28" + integrity sha1-5AcSBSal79yaObKKVnm/R7nZ3Cg= + dependencies: + request-promise-core "1.1.4" + stealthy-require "^1.1.1" + tough-cookie "^2.3.3" + +request@^2.87.0, request@^2.88.0: + version "2.88.2" + resolved "https://registry.npmmirror.com/request/download/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" + integrity sha1-1zyRhzHLWofaBH4gcjQUb2ZNErM= + dependencies: + aws-sign2 "~0.7.0" + aws4 "^1.8.0" + caseless "~0.12.0" + combined-stream "~1.0.6" + extend "~3.0.2" + forever-agent "~0.6.1" + form-data "~2.3.2" + har-validator "~5.1.3" + http-signature "~1.2.0" + is-typedarray "~1.0.0" + isstream "~0.1.2" + json-stringify-safe "~5.0.1" + mime-types "~2.1.19" + oauth-sign "~0.9.0" + performance-now "^2.1.0" + qs "~6.5.2" + safe-buffer "^5.1.2" + tough-cookie "~2.5.0" + tunnel-agent "^0.6.0" + uuid "^3.3.2" + +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.nlark.com/require-directory/download/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= + +require-main-filename@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/require-main-filename/download/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" + integrity sha1-0LMp7MfMD2Fkn2IhW+aa9UqomJs= + +requires-port@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/requires-port/download/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" + integrity sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8= + +reselect@^4.1.2: + version "4.1.2" + resolved "https://registry.npmmirror.com/reselect/download/reselect-4.1.2.tgz?cache=0&sync_timestamp=1635990641563&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Freselect%2Fdownload%2Freselect-4.1.2.tgz#7bf642992d143d4f3b0f2dca8aa52018808a1d51" + integrity sha1-e/ZCmS0UPU87Dy3KiqUgGICKHVE= + +resolve-cwd@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/resolve-cwd/download/resolve-cwd-2.0.0.tgz#00a9f7387556e27038eae232caa372a6a59b665a" + integrity sha1-AKn3OHVW4nA46uIyyqNypqWbZlo= + dependencies: + resolve-from "^3.0.0" + +resolve-from@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/resolve-from/download/resolve-from-3.0.0.tgz#b22c7af7d9d6881bc8b6e653335eebcb0a188748" + integrity sha1-six699nWiBvItuZTM17rywoYh0g= + +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/resolve-from/download/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + integrity sha1-SrzYUq0y3Xuqv+m0DgCjbbXzkuY= + +resolve-pathname@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/resolve-pathname/download/resolve-pathname-3.0.0.tgz#99d02224d3cf263689becbb393bc560313025dcd" + integrity sha1-mdAiJNPPJjaJvsuzk7xWAxMCXc0= + +resolve-url-loader@3.1.1: + version "3.1.1" + resolved "https://registry.npmmirror.com/resolve-url-loader/download/resolve-url-loader-3.1.1.tgz#28931895fa1eab9be0647d3b2958c100ae3c0bf0" + integrity sha1-KJMYlfoeq5vgZH07KVjBAK48C/A= + dependencies: + adjust-sourcemap-loader "2.0.0" + camelcase "5.3.1" + compose-function "3.0.3" + convert-source-map "1.7.0" + es6-iterator "2.0.3" + loader-utils "1.2.3" + postcss "7.0.21" + rework "1.0.1" + rework-visit "1.0.0" + source-map "0.6.1" + +resolve-url-loader@3.1.3: + version "3.1.3" + resolved "https://registry.npmmirror.com/resolve-url-loader/download/resolve-url-loader-3.1.3.tgz#49ec68340f67d8d2ab6b401948d5def3ab2d0367" + integrity sha1-SexoNA9n2NKra0AZSNXe86stA2c= + dependencies: + adjust-sourcemap-loader "3.0.0" + camelcase "5.3.1" + compose-function "3.0.3" + convert-source-map "1.7.0" + es6-iterator "2.0.3" + loader-utils "1.2.3" + postcss "7.0.21" + rework "1.0.1" + rework-visit "1.0.0" + source-map "0.6.1" + +resolve-url-loader@4.0.0: + version "4.0.0" + resolved "https://registry.npmmirror.com/resolve-url-loader/download/resolve-url-loader-4.0.0.tgz#d50d4ddc746bb10468443167acf800dcd6c3ad57" + integrity sha1-1Q1N3HRrsQRoRDFnrPgA3NbDrVc= + dependencies: + adjust-sourcemap-loader "^4.0.0" + convert-source-map "^1.7.0" + loader-utils "^2.0.0" + postcss "^7.0.35" + source-map "0.6.1" + +resolve-url@^0.2.1: + version "0.2.1" + resolved "https://registry.npmmirror.com/resolve-url/download/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" + integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= + +resolve@1.15.1: + version "1.15.1" + resolved "https://registry.npm.taobao.org/resolve/download/resolve-1.15.1.tgz#27bdcdeffeaf2d6244b95bb0f9f4b4653451f3e8" + integrity sha1-J73N7/6vLWJEuVuw+fS0ZTRR8+g= + dependencies: + path-parse "^1.0.6" + +resolve@^1.1.7, resolve@^1.10.0, resolve@^1.11.1, resolve@^1.12.0, resolve@^1.14.2, resolve@^1.20.0, resolve@^1.3.2, resolve@^1.8.1: + version "1.20.0" + resolved "https://registry.npm.taobao.org/resolve/download/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" + integrity sha1-YpoBP7P3B1XW8LeTXMHCxTeLGXU= + dependencies: + is-core-module "^2.2.0" + path-parse "^1.0.6" + +resolve@^2.0.0-next.0, resolve@^2.0.0-next.3: + version "2.0.0-next.3" + resolved "https://registry.npm.taobao.org/resolve/download/resolve-2.0.0-next.3.tgz#d41016293d4a8586a39ca5d9b5f15cbea1f55e46" + integrity sha1-1BAWKT1KhYajnKXZtfFcvqH1XkY= + dependencies: + is-core-module "^2.2.0" + path-parse "^1.0.6" + +restore-cursor@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/restore-cursor/download/restore-cursor-2.0.0.tgz?cache=0&sync_timestamp=1629746923086&other_urls=https%3A%2F%2Fregistry.nlark.com%2Frestore-cursor%2Fdownload%2Frestore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" + integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= + dependencies: + onetime "^2.0.0" + signal-exit "^3.0.2" + +restore-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.nlark.com/restore-cursor/download/restore-cursor-3.1.0.tgz?cache=0&sync_timestamp=1629746923086&other_urls=https%3A%2F%2Fregistry.nlark.com%2Frestore-cursor%2Fdownload%2Frestore-cursor-3.1.0.tgz#39f67c54b3a7a58cea5236d95cf0034239631f7e" + integrity sha1-OfZ8VLOnpYzqUjbZXPADQjljH34= + dependencies: + onetime "^5.1.0" + signal-exit "^3.0.2" + +ret@~0.1.10: + version "0.1.15" + resolved "https://registry.npm.taobao.org/ret/download/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" + integrity sha1-uKSCXVvbH8P29Twrwz+BOIaBx7w= + +retry@^0.12.0: + version "0.12.0" + resolved "https://registry.nlark.com/retry/download/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" + integrity sha1-G0KmJmoh8HQh0bC1S33BZ7AcATs= + +reusify@^1.0.4: + version "1.0.4" + resolved "https://registry.nlark.com/reusify/download/reusify-1.0.4.tgz#90da382b1e126efc02146e90845a88db12925d76" + integrity sha1-kNo4Kx4SbvwCFG6QhFqI2xKSXXY= + +rework-visit@1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/rework-visit/download/rework-visit-1.0.0.tgz#9945b2803f219e2f7aca00adb8bc9f640f842c9a" + integrity sha1-mUWygD8hni96ygCtuLyfZA+ELJo= + +rework@1.0.1: + version "1.0.1" + resolved "https://registry.npmmirror.com/rework/download/rework-1.0.1.tgz#30806a841342b54510aa4110850cd48534144aa7" + integrity sha1-MIBqhBNCtUUQqkEQhQzUhTQUSqc= + dependencies: + convert-source-map "^0.3.3" + css "^2.0.0" + +rimraf@2, rimraf@^2.5.4, rimraf@^2.6.3: + version "2.7.1" + resolved "https://registry.npm.taobao.org/rimraf/download/rimraf-2.7.1.tgz#35797f13a7fdadc566142c29d4f07ccad483e3ec" + integrity sha1-NXl/E6f9rcVmFCwp1PB8ytSD4+w= + dependencies: + glob "^7.1.3" + +rimraf@2.6.3, rimraf@~2.6.2: + version "2.6.3" + resolved "https://registry.npm.taobao.org/rimraf/download/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" + integrity sha1-stEE/g2Psnz54KHNqCYt04M8bKs= + dependencies: + glob "^7.1.3" + +rimraf@^3.0.2: + version "3.0.2" + resolved "https://registry.npm.taobao.org/rimraf/download/rimraf-3.0.2.tgz#f1a5402ba6220ad52cc1282bac1ae3aa49fd061a" + integrity sha1-8aVAK6YiCtUswSgrrBrjqkn9Bho= + dependencies: + glob "^7.1.3" + +ripemd160@^2.0.0, ripemd160@^2.0.1: + version "2.0.2" + resolved "https://registry.nlark.com/ripemd160/download/ripemd160-2.0.2.tgz#a1c1a6f624751577ba5d07914cbc92850585890c" + integrity sha1-ocGm9iR1FXe6XQeRTLyShQWFiQw= + dependencies: + hash-base "^3.0.0" + inherits "^2.0.1" + +run-async@^2.4.0: + version "2.4.1" + resolved "https://registry.nlark.com/run-async/download/run-async-2.4.1.tgz#8440eccf99ea3e70bd409d49aab88e10c189a455" + integrity sha1-hEDsz5nqPnC9QJ1JqriOEMGJpFU= + +run-parallel@^1.1.9: + version "1.2.0" + resolved "https://registry.npm.taobao.org/run-parallel/download/run-parallel-1.2.0.tgz?cache=0&sync_timestamp=1612925943325&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Frun-parallel%2Fdownload%2Frun-parallel-1.2.0.tgz#66d1368da7bdf921eb9d95bd1a9229e7f21a43ee" + integrity sha1-ZtE2jae9+SHrnZW9GpIp5/IaQ+4= + dependencies: + queue-microtask "^1.2.2" + +run-queue@^1.0.0, run-queue@^1.0.3: + version "1.0.3" + resolved "https://registry.npm.taobao.org/run-queue/download/run-queue-1.0.3.tgz#e848396f057d223f24386924618e25694161ec47" + integrity sha1-6Eg5bwV9Ij8kOGkkYY4laUFh7Ec= + dependencies: + aproba "^1.1.1" + +rxjs@^6.6.0: + version "6.6.7" + resolved "https://registry.npmmirror.com/rxjs/download/rxjs-6.6.7.tgz?cache=0&sync_timestamp=1633554235070&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Frxjs%2Fdownload%2Frxjs-6.6.7.tgz#90ac018acabf491bf65044235d5863c4dab804c9" + integrity sha1-kKwBisq/SRv2UEQjXVhjxNq4BMk= + dependencies: + tslib "^1.9.0" + +safe-buffer@5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: + version "5.1.2" + resolved "https://registry.nlark.com/safe-buffer/download/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" + integrity sha1-mR7GnSluAxN0fVm9/St0XDX4go0= + +safe-buffer@>=5.1.0, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@^5.2.0, safe-buffer@~5.2.0: + version "5.2.1" + resolved "https://registry.nlark.com/safe-buffer/download/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" + integrity sha1-Hq+fqb2x/dTsdfWPnNtOa3gn7sY= + +safe-regex@^1.1.0: + version "1.1.0" + resolved "https://registry.nlark.com/safe-regex/download/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" + integrity sha1-QKNmnzsHfR6UPURinhV91IAjvy4= + dependencies: + ret "~0.1.10" + +"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@^2.1.2, safer-buffer@~2.1.0: + version "2.1.2" + resolved "https://registry.nlark.com/safer-buffer/download/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" + integrity sha1-RPoWGwGHuVSd2Eu5GAL5vYOFzWo= + +sass-graph@2.2.5: + version "2.2.5" + resolved "https://registry.nlark.com/sass-graph/download/sass-graph-2.2.5.tgz#a981c87446b8319d96dce0671e487879bd24c2e8" + integrity sha1-qYHIdEa4MZ2W3OBnHkh4eb0kwug= + dependencies: + glob "^7.0.0" + lodash "^4.0.0" + scss-tokenizer "^0.2.3" + yargs "^13.3.2" + +sass-loader@10.1.1: + version "10.1.1" + resolved "https://registry.npmmirror.com/sass-loader/download/sass-loader-10.1.1.tgz#4ddd5a3d7638e7949065dd6e9c7c04037f7e663d" + integrity sha1-Td1aPXY455SQZd1unHwEA39+Zj0= + dependencies: + klona "^2.0.4" + loader-utils "^2.0.0" + neo-async "^2.6.2" + schema-utils "^3.0.0" + semver "^7.3.2" + +sass-loader@8.0.2: + version "8.0.2" + resolved "https://registry.npmmirror.com/sass-loader/download/sass-loader-8.0.2.tgz#debecd8c3ce243c76454f2e8290482150380090d" + integrity sha1-3r7NjDziQ8dkVPLoKQSCFQOACQ0= + dependencies: + clone-deep "^4.0.1" + loader-utils "^1.2.3" + neo-async "^2.6.1" + schema-utils "^2.6.1" + semver "^6.3.0" + +sass@1.32.11: + version "1.32.11" + resolved "https://registry.npmmirror.com/sass/download/sass-1.32.11.tgz?cache=0&sync_timestamp=1635300346226&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fsass%2Fdownload%2Fsass-1.32.11.tgz#b236b3ea55c76602c2ef2bd0445f0db581baa218" + integrity sha1-sjaz6lXHZgLC7yvQRF8NtYG6ohg= + dependencies: + chokidar ">=3.0.0 <4.0.0" + +sass@^1.23.7: + version "1.43.4" + resolved "https://registry.npmmirror.com/sass/download/sass-1.43.4.tgz?cache=0&sync_timestamp=1635300346226&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fsass%2Fdownload%2Fsass-1.43.4.tgz#68c7d6a1b004bef49af0d9caf750e9b252105d1f" + integrity sha1-aMfWobAEvvSa8NnK91DpslIQXR8= + dependencies: + chokidar ">=3.0.0 <4.0.0" + +sax@1.2.4, sax@^1.2.4, sax@~1.2.4: + version "1.2.4" + resolved "https://registry.npm.taobao.org/sax/download/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" + integrity sha1-KBYjTiN4vdxOU1T6tcqold9xANk= + +saxes@^3.1.9: + version "3.1.11" + resolved "https://registry.npmmirror.com/saxes/download/saxes-3.1.11.tgz?cache=0&sync_timestamp=1636312078741&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fsaxes%2Fdownload%2Fsaxes-3.1.11.tgz#d59d1fd332ec92ad98a2e0b2ee644702384b1c5b" + integrity sha1-1Z0f0zLskq2YouCy7mRHAjhLHFs= + dependencies: + xmlchars "^2.1.1" + +scheduler@^0.20.1, scheduler@^0.20.2: + version "0.20.2" + resolved "https://registry.npmmirror.com/scheduler/download/scheduler-0.20.2.tgz?cache=0&sync_timestamp=1636129443663&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fscheduler%2Fdownload%2Fscheduler-0.20.2.tgz#4baee39436e34aa93b4874bddcbf0fe8b8b50e91" + integrity sha1-S67jlDbjSqk7SHS93L8P6Li1DpE= + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + +schema-utils@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/schema-utils/download/schema-utils-1.0.0.tgz?cache=0&sync_timestamp=1626694740261&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fschema-utils%2Fdownload%2Fschema-utils-1.0.0.tgz#0b79a93204d7b600d4b2850d1f66c2a34951c770" + integrity sha1-C3mpMgTXtgDUsoUNH2bCo0lRx3A= + dependencies: + ajv "^6.1.0" + ajv-errors "^1.0.0" + ajv-keywords "^3.1.0" + +schema-utils@^2.6.0, schema-utils@^2.6.1, schema-utils@^2.6.5, schema-utils@^2.6.6, schema-utils@^2.7.0: + version "2.7.1" + resolved "https://registry.nlark.com/schema-utils/download/schema-utils-2.7.1.tgz?cache=0&sync_timestamp=1626694740261&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fschema-utils%2Fdownload%2Fschema-utils-2.7.1.tgz#1ca4f32d1b24c590c203b8e7a50bf0ea4cd394d7" + integrity sha1-HKTzLRskxZDCA7jnpQvw6kzTlNc= + dependencies: + "@types/json-schema" "^7.0.5" + ajv "^6.12.4" + ajv-keywords "^3.5.2" + +schema-utils@^3.0.0: + version "3.1.1" + resolved "https://registry.nlark.com/schema-utils/download/schema-utils-3.1.1.tgz?cache=0&sync_timestamp=1626694740261&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fschema-utils%2Fdownload%2Fschema-utils-3.1.1.tgz#bc74c4b6b6995c1d88f76a8b77bea7219e0c8281" + integrity sha1-vHTEtraZXB2I92qLd76nIZ4MgoE= + dependencies: + "@types/json-schema" "^7.0.8" + ajv "^6.12.5" + ajv-keywords "^3.5.2" + +scss-bundle@^3.0.2: + version "3.1.2" + resolved "https://registry.npm.taobao.org/scss-bundle/download/scss-bundle-3.1.2.tgz#8919dd7603d01a84822e8aab5210e5b0b50c548b" + integrity sha1-iRnddgPQGoSCLoqrUhDlsLUMVIs= + dependencies: + "@types/archy" "^0.0.31" + "@types/debug" "^4.1.5" + "@types/fs-extra" "^8.0.1" + "@types/glob" "^7.1.1" + "@types/lodash.debounce" "^4.0.6" + "@types/sass" "^1.16.0" + archy "^1.0.0" + chalk "^3.0.0" + chokidar "^3.3.1" + commander "^4.0.1" + fs-extra "^8.1.0" + globs "^0.1.4" + lodash.debounce "^4.0.8" + loglevel "^1.6.6" + loglevel-plugin-prefix "^0.8.4" + pretty-bytes "^5.3.0" + sass "^1.23.7" + tslib "^1.10.0" + +scss-tokenizer@^0.2.3: + version "0.2.3" + resolved "https://registry.nlark.com/scss-tokenizer/download/scss-tokenizer-0.2.3.tgz#8eb06db9a9723333824d3f5530641149847ce5d1" + integrity sha1-jrBtualyMzOCTT9VMGQRSYR85dE= + dependencies: + js-base64 "^2.1.8" + source-map "^0.4.2" + +select-hose@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/select-hose/download/select-hose-2.0.0.tgz#625d8658f865af43ec962bfc376a37359a4994ca" + integrity sha1-Yl2GWPhlr0Psliv8N2o3NZpJlMo= + +selfsigned@^1.10.7: + version "1.10.11" + resolved "https://registry.nlark.com/selfsigned/download/selfsigned-1.10.11.tgz#24929cd906fe0f44b6d01fb23999a739537acbe9" + integrity sha1-JJKc2Qb+D0S20B+yOZmnOVN6y+k= + dependencies: + node-forge "^0.10.0" + +"semver@2 || 3 || 4 || 5", semver@^5.4.1, semver@^5.5.0, semver@^5.5.1, semver@^5.6.0: + version "5.7.1" + resolved "https://registry.nlark.com/semver/download/semver-5.7.1.tgz?cache=0&sync_timestamp=1622604551741&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsemver%2Fdownload%2Fsemver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" + integrity sha1-qVT5Ma66UI0we78Gnv8MAclhFvc= + +semver@7.0.0: + version "7.0.0" + resolved "https://registry.nlark.com/semver/download/semver-7.0.0.tgz?cache=0&sync_timestamp=1622604551741&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsemver%2Fdownload%2Fsemver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" + integrity sha1-XzyjV2HkfgWyBsba/yz4FPAxa44= + +semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: + version "6.3.0" + resolved "https://registry.nlark.com/semver/download/semver-6.3.0.tgz?cache=0&sync_timestamp=1622604551741&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsemver%2Fdownload%2Fsemver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" + integrity sha1-7gpkyK9ejO6mdoexM3YeG+y9HT0= + +semver@^7.3.2, semver@^7.3.4, semver@^7.3.5: + version "7.3.5" + resolved "https://registry.nlark.com/semver/download/semver-7.3.5.tgz?cache=0&sync_timestamp=1622604551741&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsemver%2Fdownload%2Fsemver-7.3.5.tgz#0b621c879348d8998e4b0e4be94b3f12e6018ef7" + integrity sha1-C2Ich5NI2JmOSw5L6Us/EuYBjvc= + dependencies: + lru-cache "^6.0.0" + +semver@~5.3.0: + version "5.3.0" + resolved "https://registry.nlark.com/semver/download/semver-5.3.0.tgz?cache=0&sync_timestamp=1622604551741&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsemver%2Fdownload%2Fsemver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f" + integrity sha1-myzl094C0XxgEq0yaqa00M9U+U8= + +send@0.17.1: + version "0.17.1" + resolved "https://registry.nlark.com/send/download/send-0.17.1.tgz#c1d8b059f7900f7466dd4938bdc44e11ddb376c8" + integrity sha1-wdiwWfeQD3Rm3Uk4vcROEd2zdsg= + dependencies: + debug "2.6.9" + depd "~1.1.2" + destroy "~1.0.4" + encodeurl "~1.0.2" + escape-html "~1.0.3" + etag "~1.8.1" + fresh "0.5.2" + http-errors "~1.7.2" + mime "1.6.0" + ms "2.1.1" + on-finished "~2.3.0" + range-parser "~1.2.1" + statuses "~1.5.0" + +serialize-javascript@^2.1.2: + version "2.1.2" + resolved "https://registry.nlark.com/serialize-javascript/download/serialize-javascript-2.1.2.tgz#ecec53b0e0317bdc95ef76ab7074b7384785fa61" + integrity sha1-7OxTsOAxe9yV73arcHS3OEeF+mE= + +serialize-javascript@^4.0.0: + version "4.0.0" + resolved "https://registry.nlark.com/serialize-javascript/download/serialize-javascript-4.0.0.tgz#b525e1238489a5ecfc42afacc3fe99e666f4b1aa" + integrity sha1-tSXhI4SJpez8Qq+sw/6Z5mb0sao= + dependencies: + randombytes "^2.1.0" + +serialize-javascript@^5.0.1: + version "5.0.1" + resolved "https://registry.nlark.com/serialize-javascript/download/serialize-javascript-5.0.1.tgz#7886ec848049a462467a97d3d918ebb2aaf934f4" + integrity sha1-eIbshIBJpGJGepfT2Rjrsqr5NPQ= + dependencies: + randombytes "^2.1.0" + +serve-index@^1.9.1: + version "1.9.1" + resolved "https://registry.nlark.com/serve-index/download/serve-index-1.9.1.tgz#d3768d69b1e7d82e5ce050fff5b453bea12a9239" + integrity sha1-03aNabHn2C5c4FD/9bRTvqEqkjk= + dependencies: + accepts "~1.3.4" + batch "0.6.1" + debug "2.6.9" + escape-html "~1.0.3" + http-errors "~1.6.2" + mime-types "~2.1.17" + parseurl "~1.3.2" + +serve-static@1.14.1: + version "1.14.1" + resolved "https://registry.npm.taobao.org/serve-static/download/serve-static-1.14.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fserve-static%2Fdownload%2Fserve-static-1.14.1.tgz#666e636dc4f010f7ef29970a88a674320898b2f9" + integrity sha1-Zm5jbcTwEPfvKZcKiKZ0MgiYsvk= + dependencies: + encodeurl "~1.0.2" + escape-html "~1.0.3" + parseurl "~1.3.3" + send "0.17.1" + +set-blocking@^2.0.0, set-blocking@~2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/set-blocking/download/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" + integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= + +set-value@^2.0.0, set-value@^2.0.1: + version "2.0.1" + resolved "https://registry.nlark.com/set-value/download/set-value-2.0.1.tgz?cache=0&sync_timestamp=1631437857327&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fset-value%2Fdownload%2Fset-value-2.0.1.tgz#a18d40530e6f07de4228c7defe4227af8cad005b" + integrity sha1-oY1AUw5vB95CKMfe/kInr4ytAFs= + dependencies: + extend-shallow "^2.0.1" + is-extendable "^0.1.1" + is-plain-object "^2.0.3" + split-string "^3.0.1" + +setimmediate@^1.0.4: + version "1.0.5" + resolved "https://registry.npm.taobao.org/setimmediate/download/setimmediate-1.0.5.tgz#290cbb232e306942d7d7ea9b83732ab7856f8285" + integrity sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU= + +setprototypeof@1.1.0: + version "1.1.0" + resolved "https://registry.npm.taobao.org/setprototypeof/download/setprototypeof-1.1.0.tgz#d0bd85536887b6fe7c0d818cb962d9d91c54e656" + integrity sha1-0L2FU2iHtv58DYGMuWLZ2RxU5lY= + +setprototypeof@1.1.1: + version "1.1.1" + resolved "https://registry.npm.taobao.org/setprototypeof/download/setprototypeof-1.1.1.tgz#7e95acb24aa92f5885e0abef5ba131330d4ae683" + integrity sha1-fpWsskqpL1iF4KvvW6ExMw1K5oM= + +sha.js@^2.4.0, sha.js@^2.4.8: + version "2.4.11" + resolved "https://registry.npm.taobao.org/sha.js/download/sha.js-2.4.11.tgz#37a5cf0b81ecbc6943de109ba2960d1b26584ae7" + integrity sha1-N6XPC4HsvGlD3hCbopYNGyZYSuc= + dependencies: + inherits "^2.0.1" + safe-buffer "^5.0.1" + +shallow-clone@^3.0.0: + version "3.0.1" + resolved "https://registry.npm.taobao.org/shallow-clone/download/shallow-clone-3.0.1.tgz#8f2981ad92531f55035b01fb230769a40e02efa3" + integrity sha1-jymBrZJTH1UDWwH7IwdppA4C76M= + dependencies: + kind-of "^6.0.2" + +shallowequal@^1.1.0: + version "1.1.0" + resolved "https://registry.npm.taobao.org/shallowequal/download/shallowequal-1.1.0.tgz#188d521de95b9087404fd4dcb68b13df0ae4e7f8" + integrity sha1-GI1SHelbkIdAT9TctosT3wrk5/g= + +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.nlark.com/shebang-command/download/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" + integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= + dependencies: + shebang-regex "^1.0.0" + +shebang-command@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/shebang-command/download/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" + integrity sha1-zNCvT4g1+9wmW4JGGq8MNmY/NOo= + dependencies: + shebang-regex "^3.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/shebang-regex/download/shebang-regex-1.0.0.tgz?cache=0&sync_timestamp=1628896299850&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fshebang-regex%2Fdownload%2Fshebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" + integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= + +shebang-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/shebang-regex/download/shebang-regex-3.0.0.tgz?cache=0&sync_timestamp=1628896299850&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fshebang-regex%2Fdownload%2Fshebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" + integrity sha1-rhbxZE2HPsrYQ7AwexQzYtTEIXI= + +shelljs@0.3.x: + version "0.3.0" + resolved "https://registry.nlark.com/shelljs/download/shelljs-0.3.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fshelljs%2Fdownload%2Fshelljs-0.3.0.tgz#3596e6307a781544f591f37da618360f31db57b1" + integrity sha1-NZbmMHp4FUT1kfN9phg2DzHbV7E= + +side-channel@^1.0.4: + version "1.0.4" + resolved "https://registry.nlark.com/side-channel/download/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" + integrity sha1-785cj9wQTudRslxY1CkAEfpeos8= + dependencies: + call-bind "^1.0.0" + get-intrinsic "^1.0.2" + object-inspect "^1.9.0" + +signal-exit@^3.0.0, signal-exit@^3.0.2: + version "3.0.5" + resolved "https://registry.npmmirror.com/signal-exit/download/signal-exit-3.0.5.tgz?cache=0&sync_timestamp=1632948384106&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fsignal-exit%2Fdownload%2Fsignal-exit-3.0.5.tgz#9e3e8cc0c75a99472b44321033a7702e7738252f" + integrity sha1-nj6MwMdamUcrRDIQM6dwLnc4JS8= + +sirv@^1.0.7: + version "1.0.18" + resolved "https://registry.npmmirror.com/sirv/download/sirv-1.0.18.tgz?cache=0&sync_timestamp=1634319972820&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fsirv%2Fdownload%2Fsirv-1.0.18.tgz#105fab52fb656ce8a2bebbf36b11052005952899" + integrity sha1-EF+rUvtlbOiivrvzaxEFIAWVKJk= + dependencies: + "@polka/url" "^1.0.0-next.20" + mime "^2.3.1" + totalist "^1.0.0" + +slash@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/slash/download/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55" + integrity sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU= + +slash@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/slash/download/slash-2.0.0.tgz#de552851a1759df3a8f206535442f5ec4ddeab44" + integrity sha1-3lUoUaF1nfOo8gZTVEL17E3eq0Q= + +slash@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/slash/download/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" + integrity sha1-ZTm+hwwWWtvVJAIg2+Nh8bxNRjQ= + +slice-ansi@1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/slice-ansi/download/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" + integrity sha1-BE8aSdiEL/MHqta1Be0Xi9lQE00= + dependencies: + is-fullwidth-code-point "^2.0.0" + +slice-ansi@^2.1.0: + version "2.1.0" + resolved "https://registry.nlark.com/slice-ansi/download/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636" + integrity sha1-ys12k0YaY3pXiNkqfdT7oGjoFjY= + dependencies: + ansi-styles "^3.2.0" + astral-regex "^1.0.0" + is-fullwidth-code-point "^2.0.0" + +snapdragon-node@^2.0.1: + version "2.1.1" + resolved "https://registry.npm.taobao.org/snapdragon-node/download/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" + integrity sha1-bBdfhv8UvbByRWPo88GwIaKGhTs= + dependencies: + define-property "^1.0.0" + isobject "^3.0.0" + snapdragon-util "^3.0.1" + +snapdragon-util@^3.0.1: + version "3.0.1" + resolved "https://registry.nlark.com/snapdragon-util/download/snapdragon-util-3.0.1.tgz#f956479486f2acd79700693f6f7b805e45ab56e2" + integrity sha1-+VZHlIbyrNeXAGk/b3uAXkWrVuI= + dependencies: + kind-of "^3.2.0" + +snapdragon@^0.8.1: + version "0.8.2" + resolved "https://registry.npm.taobao.org/snapdragon/download/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d" + integrity sha1-ZJIufFZbDhQgS6GqfWlkJ40lGC0= + dependencies: + base "^0.11.1" + debug "^2.2.0" + define-property "^0.2.5" + extend-shallow "^2.0.1" + map-cache "^0.2.2" + source-map "^0.5.6" + source-map-resolve "^0.5.0" + use "^3.1.0" + +sockjs-client@1.4.0: + version "1.4.0" + resolved "https://registry.nlark.com/sockjs-client/download/sockjs-client-1.4.0.tgz?cache=0&sync_timestamp=1629825055862&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsockjs-client%2Fdownload%2Fsockjs-client-1.4.0.tgz#c9f2568e19c8fd8173b4997ea3420e0bb306c7d5" + integrity sha1-yfJWjhnI/YFztJl+o0IOC7MGx9U= + dependencies: + debug "^3.2.5" + eventsource "^1.0.7" + faye-websocket "~0.11.1" + inherits "^2.0.3" + json3 "^3.3.2" + url-parse "^1.4.3" + +sockjs@0.3.20: + version "0.3.20" + resolved "https://registry.nlark.com/sockjs/download/sockjs-0.3.20.tgz#b26a283ec562ef8b2687b44033a4eeceac75d855" + integrity sha1-smooPsVi74smh7RAM6Tuzqx12FU= + dependencies: + faye-websocket "^0.10.0" + uuid "^3.4.0" + websocket-driver "0.6.5" + +sort-keys@^1.0.0: + version "1.1.2" + resolved "https://registry.nlark.com/sort-keys/download/sort-keys-1.1.2.tgz#441b6d4d346798f1b4e49e8920adfba0e543f9ad" + integrity sha1-RBttTTRnmPG05J6JIK37oOVD+a0= + dependencies: + is-plain-obj "^1.0.0" + +source-list-map@^2.0.0: + version "2.0.1" + resolved "https://registry.nlark.com/source-list-map/download/source-list-map-2.0.1.tgz#3993bd873bfc48479cca9ea3a547835c7c154b34" + integrity sha1-OZO9hzv8SEecyp6jpUeDXHwVSzQ= + +source-map-js@^0.6.2: + version "0.6.2" + resolved "https://registry.npmmirror.com/source-map-js/download/source-map-js-0.6.2.tgz?cache=0&sync_timestamp=1636059119319&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fsource-map-js%2Fdownload%2Fsource-map-js-0.6.2.tgz#0bb5de631b41cfbda6cfba8bd05a80efdfd2385e" + integrity sha1-C7XeYxtBz72mz7qL0FqA79/SOF4= + +source-map-resolve@^0.5.0, source-map-resolve@^0.5.2: + version "0.5.3" + resolved "https://registry.nlark.com/source-map-resolve/download/source-map-resolve-0.5.3.tgz#190866bece7553e1f8f267a2ee82c606b5509a1a" + integrity sha1-GQhmvs51U+H48mei7oLGBrVQmho= + dependencies: + atob "^2.1.2" + decode-uri-component "^0.2.0" + resolve-url "^0.2.1" + source-map-url "^0.4.0" + urix "^0.1.0" + +source-map-support@^0.5.16, source-map-support@~0.5.12: + version "0.5.20" + resolved "https://registry.nlark.com/source-map-support/download/source-map-support-0.5.20.tgz?cache=0&sync_timestamp=1631179636992&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsource-map-support%2Fdownload%2Fsource-map-support-0.5.20.tgz#12166089f8f5e5e8c56926b377633392dd2cb6c9" + integrity sha1-EhZgifj15ejFaSazd2Mzkt0stsk= + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map-support@~0.5.20: + version "0.5.21" + resolved "https://registry.npmmirror.com/source-map-support/download/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" + integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map-url@^0.4.0: + version "0.4.1" + resolved "https://registry.nlark.com/source-map-url/download/source-map-url-0.4.1.tgz#0af66605a745a5a2f91cf1bbf8a7afbc283dec56" + integrity sha1-CvZmBadFpaL5HPG7+KevvCg97FY= + +source-map@0.6.1, source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0, source-map@~0.6.1: + version "0.6.1" + resolved "https://registry.nlark.com/source-map/download/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha1-dHIq8y6WFOnCh6jQu95IteLxomM= + +source-map@^0.4.2: + version "0.4.4" + resolved "https://registry.nlark.com/source-map/download/source-map-0.4.4.tgz#eba4f5da9c0dc999de68032d8b4f76173652036b" + integrity sha1-66T12pwNyZneaAMti092FzZSA2s= + dependencies: + amdefine ">=0.0.4" + +source-map@^0.5.0, source-map@^0.5.3, source-map@^0.5.6: + version "0.5.7" + resolved "https://registry.nlark.com/source-map/download/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" + integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= + +source-map@^0.7.3, source-map@~0.7.2: + version "0.7.3" + resolved "https://registry.nlark.com/source-map/download/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383" + integrity sha1-UwL4FpAxc1ImVECS5kmB91F1A4M= + +spdx-correct@^3.0.0: + version "3.1.1" + resolved "https://registry.npm.taobao.org/spdx-correct/download/spdx-correct-3.1.1.tgz#dece81ac9c1e6713e5f7d1b6f17d468fa53d89a9" + integrity sha1-3s6BrJweZxPl99G28X1Gj6U9iak= + dependencies: + spdx-expression-parse "^3.0.0" + spdx-license-ids "^3.0.0" + +spdx-exceptions@^2.1.0: + version "2.3.0" + resolved "https://registry.npm.taobao.org/spdx-exceptions/download/spdx-exceptions-2.3.0.tgz#3f28ce1a77a00372683eade4a433183527a2163d" + integrity sha1-PyjOGnegA3JoPq3kpDMYNSeiFj0= + +spdx-expression-parse@^3.0.0: + version "3.0.1" + resolved "https://registry.npm.taobao.org/spdx-expression-parse/download/spdx-expression-parse-3.0.1.tgz#cf70f50482eefdc98e3ce0a6833e4a53ceeba679" + integrity sha1-z3D1BILu/cmOPOCmgz5KU87rpnk= + dependencies: + spdx-exceptions "^2.1.0" + spdx-license-ids "^3.0.0" + +spdx-license-ids@^3.0.0: + version "3.0.10" + resolved "https://registry.nlark.com/spdx-license-ids/download/spdx-license-ids-3.0.10.tgz?cache=0&sync_timestamp=1628483278047&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fspdx-license-ids%2Fdownload%2Fspdx-license-ids-3.0.10.tgz#0d9becccde7003d6c658d487dd48a32f0bf3014b" + integrity sha1-DZvszN5wA9bGWNSH3UijLwvzAUs= + +spdy-transport@^3.0.0: + version "3.0.0" + resolved "https://registry.npm.taobao.org/spdy-transport/download/spdy-transport-3.0.0.tgz#00d4863a6400ad75df93361a1608605e5dcdcf31" + integrity sha1-ANSGOmQArXXfkzYaFghgXl3NzzE= + dependencies: + debug "^4.1.0" + detect-node "^2.0.4" + hpack.js "^2.1.6" + obuf "^1.1.2" + readable-stream "^3.0.6" + wbuf "^1.7.3" + +spdy@^4.0.2: + version "4.0.2" + resolved "https://registry.npm.taobao.org/spdy/download/spdy-4.0.2.tgz#b74f466203a3eda452c02492b91fb9e84a27677b" + integrity sha1-t09GYgOj7aRSwCSSuR+56EonZ3s= + dependencies: + debug "^4.1.0" + handle-thing "^2.0.0" + http-deceiver "^1.2.7" + select-hose "^2.0.0" + spdy-transport "^3.0.0" + +specificity@^0.3.1: + version "0.3.2" + resolved "https://registry.npmmirror.com/specificity/download/specificity-0.3.2.tgz#99e6511eceef0f8d9b57924937aac2cb13d13c42" + integrity sha1-meZRHs7vD42bV5JJN6rCyxPRPEI= + +split-on-first@^1.0.0: + version "1.1.0" + resolved "https://registry.nlark.com/split-on-first/download/split-on-first-1.1.0.tgz#f610afeee3b12bce1d0c30425e76398b78249a5f" + integrity sha1-9hCv7uOxK84dDDBCXnY5i3gkml8= + +split-string@^3.0.1, split-string@^3.0.2: + version "3.1.0" + resolved "https://registry.npm.taobao.org/split-string/download/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2" + integrity sha1-fLCd2jqGWFcFxks5pkZgOGguj+I= + dependencies: + extend-shallow "^3.0.0" + +sprintf-js@~1.0.2: + version "1.0.3" + resolved "https://registry.nlark.com/sprintf-js/download/sprintf-js-1.0.3.tgz?cache=0&sync_timestamp=1618847174560&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsprintf-js%2Fdownload%2Fsprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" + integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= + +sshpk@^1.7.0: + version "1.16.1" + resolved "https://registry.npm.taobao.org/sshpk/download/sshpk-1.16.1.tgz#fb661c0bef29b39db40769ee39fa70093d6f6877" + integrity sha1-+2YcC+8ps520B2nuOfpwCT1vaHc= + dependencies: + asn1 "~0.2.3" + assert-plus "^1.0.0" + bcrypt-pbkdf "^1.0.0" + dashdash "^1.12.0" + ecc-jsbn "~0.1.1" + getpass "^0.1.1" + jsbn "~0.1.0" + safer-buffer "^2.0.2" + tweetnacl "~0.14.0" + +ssr-window@^3.0.0, ssr-window@^3.0.0-alpha.1: + version "3.0.0" + resolved "https://registry.npmmirror.com/ssr-window/download/ssr-window-3.0.0.tgz#fd5b82801638943e0cc704c4691801435af7ac37" + integrity sha1-/VuCgBY4lD4MxwTEaRgBQ1r3rDc= + +ssri@^6.0.1: + version "6.0.2" + resolved "https://registry.nlark.com/ssri/download/ssri-6.0.2.tgz?cache=0&sync_timestamp=1621364626710&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fssri%2Fdownload%2Fssri-6.0.2.tgz#157939134f20464e7301ddba3e90ffa8f7728ac5" + integrity sha1-FXk5E08gRk5zAd26PpD/qPdyisU= + dependencies: + figgy-pudding "^3.5.1" + +ssri@^8.0.1: + version "8.0.1" + resolved "https://registry.nlark.com/ssri/download/ssri-8.0.1.tgz?cache=0&sync_timestamp=1621364626710&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fssri%2Fdownload%2Fssri-8.0.1.tgz#638e4e439e2ffbd2cd289776d5ca457c4f51a2af" + integrity sha1-Y45OQ54v+9LNKJd21cpFfE9Roq8= + dependencies: + minipass "^3.1.1" + +stackframe@^1.1.1: + version "1.2.0" + resolved "https://registry.npm.taobao.org/stackframe/download/stackframe-1.2.0.tgz#52429492d63c62eb989804c11552e3d22e779303" + integrity sha1-UkKUktY8YuuYmATBFVLj0i53kwM= + +state-toggle@^1.0.0: + version "1.0.3" + resolved "https://registry.npm.taobao.org/state-toggle/download/state-toggle-1.0.3.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fstate-toggle%2Fdownload%2Fstate-toggle-1.0.3.tgz#e123b16a88e143139b09c6852221bc9815917dfe" + integrity sha1-4SOxaojhQxObCcaFIiG8mBWRff4= + +static-extend@^0.1.1: + version "0.1.2" + resolved "https://registry.npm.taobao.org/static-extend/download/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" + integrity sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY= + dependencies: + define-property "^0.2.5" + object-copy "^0.1.0" + +"statuses@>= 1.4.0 < 2", "statuses@>= 1.5.0 < 2", statuses@~1.5.0: + version "1.5.0" + resolved "https://registry.npm.taobao.org/statuses/download/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" + integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= + +stdout-stream@^1.4.0: + version "1.4.1" + resolved "https://registry.npm.taobao.org/stdout-stream/download/stdout-stream-1.4.1.tgz#5ac174cdd5cd726104aa0c0b2bd83815d8d535de" + integrity sha1-WsF0zdXNcmEEqgwLK9g4FdjVNd4= + dependencies: + readable-stream "^2.0.1" + +stealthy-require@^1.1.1: + version "1.1.1" + resolved "https://registry.npm.taobao.org/stealthy-require/download/stealthy-require-1.1.1.tgz#35b09875b4ff49f26a777e509b3090a3226bf24b" + integrity sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks= + +stream-browserify@^2.0.1: + version "2.0.2" + resolved "https://registry.npm.taobao.org/stream-browserify/download/stream-browserify-2.0.2.tgz#87521d38a44aa7ee91ce1cd2a47df0cb49dd660b" + integrity sha1-h1IdOKRKp+6RzhzSpH3wy0ndZgs= + dependencies: + inherits "~2.0.1" + readable-stream "^2.0.2" + +stream-each@^1.1.0: + version "1.2.3" + resolved "https://registry.npm.taobao.org/stream-each/download/stream-each-1.2.3.tgz#ebe27a0c389b04fbcc233642952e10731afa9bae" + integrity sha1-6+J6DDibBPvMIzZClS4Qcxr6m64= + dependencies: + end-of-stream "^1.1.0" + stream-shift "^1.0.0" + +stream-http@^2.7.2: + version "2.8.3" + resolved "https://registry.nlark.com/stream-http/download/stream-http-2.8.3.tgz#b2d242469288a5a27ec4fe8933acf623de6514fc" + integrity sha1-stJCRpKIpaJ+xP6JM6z2I95lFPw= + dependencies: + builtin-status-codes "^3.0.0" + inherits "^2.0.1" + readable-stream "^2.3.6" + to-arraybuffer "^1.0.0" + xtend "^4.0.0" + +stream-shift@^1.0.0: + version "1.0.1" + resolved "https://registry.npm.taobao.org/stream-shift/download/stream-shift-1.0.1.tgz#d7088281559ab2778424279b0877da3c392d5a3d" + integrity sha1-1wiCgVWasneEJCebCHfaPDktWj0= + +strict-uri-encode@^1.0.0: + version "1.1.0" + resolved "https://registry.npm.taobao.org/strict-uri-encode/download/strict-uri-encode-1.1.0.tgz#279b225df1d582b1f54e65addd4352e18faa0713" + integrity sha1-J5siXfHVgrH1TmWt3UNS4Y+qBxM= + +strict-uri-encode@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/strict-uri-encode/download/strict-uri-encode-2.0.0.tgz#b9c7330c7042862f6b142dc274bbcc5866ce3546" + integrity sha1-ucczDHBChi9rFC3CdLvMWGbONUY= + +string-width@^1.0.1: + version "1.0.2" + resolved "https://registry.npmmirror.com/string-width/download/string-width-1.0.2.tgz?cache=0&sync_timestamp=1632420968947&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fstring-width%2Fdownload%2Fstring-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" + integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= + dependencies: + code-point-at "^1.0.0" + is-fullwidth-code-point "^1.0.0" + strip-ansi "^3.0.0" + +"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0: + version "4.2.3" + resolved "https://registry.npmmirror.com/string-width/download/string-width-4.2.3.tgz?cache=0&sync_timestamp=1632420968947&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fstring-width%2Fdownload%2Fstring-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha1-JpxxF9J7Ba0uU2gwqOyJXvnG0BA= + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string-width@^2.1.0, string-width@^2.1.1: + version "2.1.1" + resolved "https://registry.npmmirror.com/string-width/download/string-width-2.1.1.tgz?cache=0&sync_timestamp=1632420968947&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fstring-width%2Fdownload%2Fstring-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" + integrity sha1-q5Pyeo3BPSjKyBXEYhQ6bZASrp4= + dependencies: + is-fullwidth-code-point "^2.0.0" + strip-ansi "^4.0.0" + +string-width@^3.0.0, string-width@^3.1.0: + version "3.1.0" + resolved "https://registry.npmmirror.com/string-width/download/string-width-3.1.0.tgz?cache=0&sync_timestamp=1632420968947&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fstring-width%2Fdownload%2Fstring-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" + integrity sha1-InZ74htirxCBV0MG9prFG2IgOWE= + dependencies: + emoji-regex "^7.0.1" + is-fullwidth-code-point "^2.0.0" + strip-ansi "^5.1.0" + +string.fromcodepoint@^0.2.1: + version "0.2.1" + resolved "https://registry.npm.taobao.org/string.fromcodepoint/download/string.fromcodepoint-0.2.1.tgz#8d978333c0bc92538f50f383e4888f3e5619d653" + integrity sha1-jZeDM8C8klOPUPOD5IiPPlYZ1lM= + +string.prototype.matchall@^4.0.5: + version "4.0.6" + resolved "https://registry.npmmirror.com/string.prototype.matchall/download/string.prototype.matchall-4.0.6.tgz?cache=0&sync_timestamp=1633405130057&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fstring.prototype.matchall%2Fdownload%2Fstring.prototype.matchall-4.0.6.tgz#5abb5dabc94c7b0ea2380f65ba610b3a544b15fa" + integrity sha1-Wrtdq8lMew6iOA9lumELOlRLFfo= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.1" + get-intrinsic "^1.1.1" + has-symbols "^1.0.2" + internal-slot "^1.0.3" + regexp.prototype.flags "^1.3.1" + side-channel "^1.0.4" + +string.prototype.trimend@^1.0.4: + version "1.0.4" + resolved "https://registry.npm.taobao.org/string.prototype.trimend/download/string.prototype.trimend-1.0.4.tgz?cache=0&sync_timestamp=1614127461586&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fstring.prototype.trimend%2Fdownload%2Fstring.prototype.trimend-1.0.4.tgz#e75ae90c2942c63504686c18b287b4a0b1a45f80" + integrity sha1-51rpDClCxjUEaGwYsoe0oLGkX4A= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + +string.prototype.trimstart@^1.0.4: + version "1.0.4" + resolved "https://registry.npm.taobao.org/string.prototype.trimstart/download/string.prototype.trimstart-1.0.4.tgz?cache=0&sync_timestamp=1614127357785&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fstring.prototype.trimstart%2Fdownload%2Fstring.prototype.trimstart-1.0.4.tgz#b36399af4ab2999b4c9c648bd7a3fb2bb26feeed" + integrity sha1-s2OZr0qymZtMnGSL16P7K7Jv7u0= + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + +string_decoder@^1.0.0, string_decoder@^1.1.1: + version "1.3.0" + resolved "https://registry.nlark.com/string_decoder/download/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" + integrity sha1-QvEUWUpGzxqOMLCoT1bHjD7awh4= + dependencies: + safe-buffer "~5.2.0" + +string_decoder@~0.10.x: + version "0.10.31" + resolved "https://registry.nlark.com/string_decoder/download/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" + integrity sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ= + +string_decoder@~1.1.1: + version "1.1.1" + resolved "https://registry.nlark.com/string_decoder/download/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" + integrity sha1-nPFhG6YmhdcDCunkujQUnDrwP8g= + dependencies: + safe-buffer "~5.1.0" + +stringify-entities@^1.0.1: + version "1.3.2" + resolved "https://registry.nlark.com/stringify-entities/download/stringify-entities-1.3.2.tgz#a98417e5471fd227b3e45d3db1861c11caf668f7" + integrity sha1-qYQX5Ucf0iez5F09sYYcEcr2aPc= + dependencies: + character-entities-html4 "^1.0.0" + character-entities-legacy "^1.0.0" + is-alphanumerical "^1.0.0" + is-hexadecimal "^1.0.0" + +strip-ansi@^3.0.0, strip-ansi@^3.0.1: + version "3.0.1" + resolved "https://registry.npmmirror.com/strip-ansi/download/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" + integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= + dependencies: + ansi-regex "^2.0.0" + +strip-ansi@^4.0.0: + version "4.0.0" + resolved "https://registry.npmmirror.com/strip-ansi/download/strip-ansi-4.0.0.tgz#a8479022eb1ac368a871389b635262c505ee368f" + integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= + dependencies: + ansi-regex "^3.0.0" + +strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0: + version "5.2.0" + resolved "https://registry.npmmirror.com/strip-ansi/download/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" + integrity sha1-jJpTb+tq/JYr36WxBKUJHBrZwK4= + dependencies: + ansi-regex "^4.1.0" + +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.npmmirror.com/strip-ansi/download/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha1-nibGPTD1NEPpSJSVshBdN7Z6hdk= + dependencies: + ansi-regex "^5.0.1" + +strip-bom@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/strip-bom/download/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" + integrity sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4= + dependencies: + is-utf8 "^0.2.0" + +strip-bom@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/strip-bom/download/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" + integrity sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM= + +strip-eof@^1.0.0: + version "1.0.0" + resolved "https://registry.npmmirror.com/strip-eof/download/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" + integrity sha1-u0P/VZim6wXYm1n80SnJgzE2Br8= + +strip-indent@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/strip-indent/download/strip-indent-1.0.1.tgz?cache=0&sync_timestamp=1620053310624&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fstrip-indent%2Fdownload%2Fstrip-indent-1.0.1.tgz#0c7962a6adefa7bbd4ac366460a638552ae1a0a2" + integrity sha1-DHlipq3vp7vUrDZkYKY4VSrhoKI= + dependencies: + get-stdin "^4.0.1" + +strip-indent@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/strip-indent/download/strip-indent-2.0.0.tgz?cache=0&sync_timestamp=1620053310624&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fstrip-indent%2Fdownload%2Fstrip-indent-2.0.0.tgz#5ef8db295d01e6ed6cbf7aab96998d7822527b68" + integrity sha1-XvjbKV0B5u1sv3qrlpmNeCJSe2g= + +strip-json-comments@1.0.x: + version "1.0.4" + resolved "https://registry.nlark.com/strip-json-comments/download/strip-json-comments-1.0.4.tgz#1e15fbcac97d3ee99bf2d73b4c656b082bbafb91" + integrity sha1-HhX7ysl9Pumb8tc7TGVrCCu6+5E= + +strip-json-comments@^3.0.1: + version "3.1.1" + resolved "https://registry.nlark.com/strip-json-comments/download/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" + integrity sha1-MfEoGzgyYwQ0gxwxDAHMzajL4AY= + +strnum@^1.0.4: + version "1.0.4" + resolved "https://registry.npmmirror.com/strnum/download/strnum-1.0.4.tgz#e97e36a7d6ba9f93d0d6b496b2ed0678d422832b" + integrity sha1-6X42p9a6n5PQ1rSWsu0GeNQigys= + +style-loader@1.3.0: + version "1.3.0" + resolved "https://registry.npmmirror.com/style-loader/download/style-loader-1.3.0.tgz?cache=0&sync_timestamp=1634872439692&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fstyle-loader%2Fdownload%2Fstyle-loader-1.3.0.tgz#828b4a3b3b7e7aa5847ce7bae9e874512114249e" + integrity sha1-gotKOzt+eqWEfOe66eh0USEUJJ4= + dependencies: + loader-utils "^2.0.0" + schema-utils "^2.7.0" + +style-search@^0.1.0: + version "0.1.0" + resolved "https://registry.npmmirror.com/style-search/download/style-search-0.1.0.tgz#7958c793e47e32e07d2b5cafe5c0bf8e12e77902" + integrity sha1-eVjHk+R+MuB9K1yv5cC/jhLneQI= + +stylelint@9.3.0: + version "9.3.0" + resolved "https://registry.npmmirror.com/stylelint/download/stylelint-9.3.0.tgz#fe176e4e421ac10eac1a6b6d9f28e908eb58c5db" + integrity sha1-/hduTkIawQ6sGmttnyjpCOtYxds= + dependencies: + autoprefixer "^8.0.0" + balanced-match "^1.0.0" + chalk "^2.4.1" + cosmiconfig "^5.0.0" + debug "^3.0.0" + execall "^1.0.0" + file-entry-cache "^2.0.0" + get-stdin "^6.0.0" + globby "^8.0.0" + globjoin "^0.1.4" + html-tags "^2.0.0" + ignore "^3.3.3" + import-lazy "^3.1.0" + imurmurhash "^0.1.4" + known-css-properties "^0.6.0" + lodash "^4.17.4" + log-symbols "^2.0.0" + mathml-tag-names "^2.0.1" + meow "^5.0.0" + micromatch "^2.3.11" + normalize-selector "^0.2.0" + pify "^3.0.0" + postcss "^6.0.16" + postcss-html "^0.28.0" + postcss-less "^2.0.0" + postcss-markdown "^0.28.0" + postcss-media-query-parser "^0.2.3" + postcss-reporter "^5.0.0" + postcss-resolve-nested-selector "^0.1.1" + postcss-safe-parser "^3.0.1" + postcss-sass "^0.3.0" + postcss-scss "^1.0.2" + postcss-selector-parser "^3.1.0" + postcss-syntax "^0.28.0" + postcss-value-parser "^3.3.0" + resolve-from "^4.0.0" + signal-exit "^3.0.2" + specificity "^0.3.1" + string-width "^2.1.0" + style-search "^0.1.0" + sugarss "^1.0.0" + svg-tags "^1.0.0" + table "^4.0.1" + +stylis@^3.5.4: + version "3.5.4" + resolved "https://registry.npm.taobao.org/stylis/download/stylis-3.5.4.tgz?cache=0&sync_timestamp=1617798385355&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fstylis%2Fdownload%2Fstylis-3.5.4.tgz#f665f25f5e299cf3d64654ab949a57c768b73fbe" + integrity sha1-9mXyX14pnPPWRlSrlJpXx2i3P74= + +stylus-loader@3.0.2, stylus-loader@^3.0.2: + version "3.0.2" + resolved "https://registry.npmmirror.com/stylus-loader/download/stylus-loader-3.0.2.tgz?cache=0&sync_timestamp=1634037061456&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fstylus-loader%2Fdownload%2Fstylus-loader-3.0.2.tgz#27a706420b05a38e038e7cacb153578d450513c6" + integrity sha1-J6cGQgsFo44DjnyssVNXjUUFE8Y= + dependencies: + loader-utils "^1.0.2" + lodash.clonedeep "^4.5.0" + when "~3.6.x" + +stylus@0.54.7: + version "0.54.7" + resolved "https://registry.nlark.com/stylus/download/stylus-0.54.7.tgz#c6ce4793965ee538bcebe50f31537bfc04d88cd2" + integrity sha1-xs5Hk5Ze5Ti86+UPMVN7/ATYjNI= + dependencies: + css-parse "~2.0.0" + debug "~3.1.0" + glob "^7.1.3" + mkdirp "~0.5.x" + safer-buffer "^2.1.2" + sax "~1.2.4" + semver "^6.0.0" + source-map "^0.7.3" + +stylus@^0.54.7: + version "0.54.8" + resolved "https://registry.nlark.com/stylus/download/stylus-0.54.8.tgz#3da3e65966bc567a7b044bfe0eece653e099d147" + integrity sha1-PaPmWWa8Vnp7BEv+DuzmU+CZ0Uc= + dependencies: + css-parse "~2.0.0" + debug "~3.1.0" + glob "^7.1.6" + mkdirp "~1.0.4" + safer-buffer "^2.1.2" + sax "~1.2.4" + semver "^6.3.0" + source-map "^0.7.3" + +sugarss@^1.0.0: + version "1.0.1" + resolved "https://registry.nlark.com/sugarss/download/sugarss-1.0.1.tgz?cache=0&sync_timestamp=1623651869315&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsugarss%2Fdownload%2Fsugarss-1.0.1.tgz#be826d9003e0f247735f92365dc3fd7f1bae9e44" + integrity sha1-voJtkAPg8kdzX5I2XcP9fxuunkQ= + dependencies: + postcss "^6.0.14" + +supports-color@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/supports-color/download/supports-color-2.0.0.tgz?cache=0&sync_timestamp=1626703414084&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsupports-color%2Fdownload%2Fsupports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" + integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= + +supports-color@^3.2.3: + version "3.2.3" + resolved "https://registry.nlark.com/supports-color/download/supports-color-3.2.3.tgz?cache=0&sync_timestamp=1626703414084&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsupports-color%2Fdownload%2Fsupports-color-3.2.3.tgz#65ac0504b3954171d8a64946b2ae3cbb8a5f54f6" + integrity sha1-ZawFBLOVQXHYpklGsq48u4pfVPY= + dependencies: + has-flag "^1.0.0" + +supports-color@^5.3.0, supports-color@^5.4.0: + version "5.5.0" + resolved "https://registry.nlark.com/supports-color/download/supports-color-5.5.0.tgz?cache=0&sync_timestamp=1626703414084&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsupports-color%2Fdownload%2Fsupports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" + integrity sha1-4uaaRKyHcveKHsCzW2id9lMO/I8= + dependencies: + has-flag "^3.0.0" + +supports-color@^6.1.0: + version "6.1.0" + resolved "https://registry.nlark.com/supports-color/download/supports-color-6.1.0.tgz?cache=0&sync_timestamp=1626703414084&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsupports-color%2Fdownload%2Fsupports-color-6.1.0.tgz#0764abc69c63d5ac842dd4867e8d025e880df8f3" + integrity sha1-B2Srxpxj1ayELdSGfo0CXogN+PM= + dependencies: + has-flag "^3.0.0" + +supports-color@^7.0.0, supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.nlark.com/supports-color/download/supports-color-7.2.0.tgz?cache=0&sync_timestamp=1626703414084&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fsupports-color%2Fdownload%2Fsupports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" + integrity sha1-G33NyzK4E4gBs+R4umpRyqiWSNo= + dependencies: + has-flag "^4.0.0" + +svg-tags@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/svg-tags/download/svg-tags-1.0.0.tgz#58f71cee3bd519b59d4b2a843b6c7de64ac04764" + integrity sha1-WPcc7jvVGbWdSyqEO2x95krAR2Q= + +swiper@6.8.0: + version "6.8.0" + resolved "https://registry.npmmirror.com/swiper/download/swiper-6.8.0.tgz#61c850f49ba778e403f00a01fe0b768bd85d0d20" + integrity sha1-YchQ9JuneOQD8AoB/gt2i9hdDSA= + dependencies: + dom7 "^3.0.0" + ssr-window "^3.0.0" + +symbol-tree@^3.2.2: + version "3.2.4" + resolved "https://registry.npm.taobao.org/symbol-tree/download/symbol-tree-3.2.4.tgz#430637d248ba77e078883951fb9aa0eed7c63fa2" + integrity sha1-QwY30ki6d+B4iDlR+5qg7tfGP6I= + +table@^4.0.1: + version "4.0.3" + resolved "https://registry.npmmirror.com/table/download/table-4.0.3.tgz?cache=0&sync_timestamp=1636037180431&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ftable%2Fdownload%2Ftable-4.0.3.tgz#00b5e2b602f1794b9acaf9ca908a76386a7813bc" + integrity sha1-ALXitgLxeUuayvnKkIp2OGp4E7w= + dependencies: + ajv "^6.0.1" + ajv-keywords "^3.0.0" + chalk "^2.1.0" + lodash "^4.17.4" + slice-ansi "1.0.0" + string-width "^2.1.1" + +table@^5.2.3: + version "5.4.6" + resolved "https://registry.npmmirror.com/table/download/table-5.4.6.tgz?cache=0&sync_timestamp=1636037180431&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ftable%2Fdownload%2Ftable-5.4.6.tgz#1292d19500ce3f86053b05f0e8e7e4a3bb21079e" + integrity sha1-EpLRlQDOP4YFOwXw6Ofko7shB54= + dependencies: + ajv "^6.10.2" + lodash "^4.17.14" + slice-ansi "^2.1.0" + string-width "^3.0.0" + +tapable@1.1.3, tapable@^1.0.0, tapable@^1.1.3: + version "1.1.3" + resolved "https://registry.nlark.com/tapable/download/tapable-1.1.3.tgz#a1fccc06b58db61fd7a45da2da44f5f3a3e67ba2" + integrity sha1-ofzMBrWNth/XpF2i2kT186Pme6I= + +tar@^2.0.0: + version "2.2.2" + resolved "https://registry.nlark.com/tar/download/tar-2.2.2.tgz?cache=0&sync_timestamp=1629994598621&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftar%2Fdownload%2Ftar-2.2.2.tgz#0ca8848562c7299b8b446ff6a4d60cdbb23edc40" + integrity sha1-DKiEhWLHKZuLRG/2pNYM27I+3EA= + dependencies: + block-stream "*" + fstream "^1.0.12" + inherits "2" + +tar@^6.0.2: + version "6.1.11" + resolved "https://registry.nlark.com/tar/download/tar-6.1.11.tgz?cache=0&sync_timestamp=1629994598621&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftar%2Fdownload%2Ftar-6.1.11.tgz#6760a38f003afa1b2ffd0ffe9e9abbd0eab3d621" + integrity sha1-Z2CjjwA6+hsv/Q/+npq70Oqz1iE= + dependencies: + chownr "^2.0.0" + fs-minipass "^2.0.0" + minipass "^3.0.0" + minizlib "^2.1.1" + mkdirp "^1.0.3" + yallist "^4.0.0" + +taro-axios@^1.1.1: + version "1.1.1" + resolved "https://registry.npm.taobao.org/taro-axios/download/taro-axios-1.1.1.tgz#93fae855cbbce8fc002180c5ee33a7731475ad1b" + integrity sha1-k/roVcu86PwAIYDF7jOncxR1rRs= + dependencies: + axios "0.19.2" + +taro-css-to-react-native@3.3.12: + version "3.3.12" + resolved "https://registry.npmmirror.com/taro-css-to-react-native/download/taro-css-to-react-native-3.3.12.tgz?cache=0&sync_timestamp=1635491345604&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ftaro-css-to-react-native%2Fdownload%2Ftaro-css-to-react-native-3.3.12.tgz#6ff3cdb781478e92ceb89d4706f65714e889ed00" + integrity sha1-b/PNt4FHjpLOuJ1HBvZXFOiJ7QA= + dependencies: + camelize "^1.0.0" + css "^2.2.4" + css-color-keywords "^1.0.0" + css-mediaquery "^0.1.2" + postcss-value-parser "^3.3.0" + +terser-webpack-plugin@4: + version "4.2.3" + resolved "https://registry.npmmirror.com/terser-webpack-plugin/download/terser-webpack-plugin-4.2.3.tgz?cache=0&sync_timestamp=1636385924926&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fterser-webpack-plugin%2Fdownload%2Fterser-webpack-plugin-4.2.3.tgz#28daef4a83bd17c1db0297070adc07fc8cfc6a9a" + integrity sha1-KNrvSoO9F8HbApcHCtwH/Iz8apo= + dependencies: + cacache "^15.0.5" + find-cache-dir "^3.3.1" + jest-worker "^26.5.0" + p-limit "^3.0.2" + schema-utils "^3.0.0" + serialize-javascript "^5.0.1" + source-map "^0.6.1" + terser "^5.3.4" + webpack-sources "^1.4.3" + +terser-webpack-plugin@^1.4.3: + version "1.4.5" + resolved "https://registry.npmmirror.com/terser-webpack-plugin/download/terser-webpack-plugin-1.4.5.tgz#a217aefaea330e734ffacb6120ec1fa312d6040b" + integrity sha1-oheu+uozDnNP+sthIOwfoxLWBAs= + dependencies: + cacache "^12.0.2" + find-cache-dir "^2.1.0" + is-wsl "^1.1.0" + schema-utils "^1.0.0" + serialize-javascript "^4.0.0" + source-map "^0.6.1" + terser "^4.1.2" + webpack-sources "^1.4.0" + worker-farm "^1.7.0" + +terser-webpack-plugin@^3.0.5: + version "3.1.0" + resolved "https://registry.npmmirror.com/terser-webpack-plugin/download/terser-webpack-plugin-3.1.0.tgz#91e6d39571460ed240c0cf69d295bcf30ebf98cb" + integrity sha1-kebTlXFGDtJAwM9p0pW88w6/mMs= + dependencies: + cacache "^15.0.5" + find-cache-dir "^3.3.1" + jest-worker "^26.2.1" + p-limit "^3.0.2" + schema-utils "^2.6.6" + serialize-javascript "^4.0.0" + source-map "^0.6.1" + terser "^4.8.0" + webpack-sources "^1.4.3" + +terser@^4.1.2, terser@^4.8.0: + version "4.8.0" + resolved "https://registry.nlark.com/terser/download/terser-4.8.0.tgz?cache=0&sync_timestamp=1632229839325&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fterser%2Fdownload%2Fterser-4.8.0.tgz#63056343d7c70bb29f3af665865a46fe03a0df17" + integrity sha1-YwVjQ9fHC7KfOvZlhlpG/gOg3xc= + dependencies: + commander "^2.20.0" + source-map "~0.6.1" + source-map-support "~0.5.12" + +terser@^5.3.4: + version "5.10.0" + resolved "https://registry.npmmirror.com/terser/download/terser-5.10.0.tgz#b86390809c0389105eb0a0b62397563096ddafcc" + integrity sha512-AMmF99DMfEDiRJfxfY5jj5wNH/bYO09cniSqhfoyxc8sFoYIgkJy86G04UoZU5VjlpnplVu0K6Tx6E9b5+DlHA== + dependencies: + commander "^2.20.0" + source-map "~0.7.2" + source-map-support "~0.5.20" + +text-table@^0.2.0: + version "0.2.0" + resolved "https://registry.nlark.com/text-table/download/text-table-0.2.0.tgz?cache=0&sync_timestamp=1618847142316&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftext-table%2Fdownload%2Ftext-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" + integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= + +through2@^2.0.0: + version "2.0.5" + resolved "https://registry.npm.taobao.org/through2/download/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" + integrity sha1-AcHjnrMdB8t9A6lqcIIyYLIxMs0= + dependencies: + readable-stream "~2.3.6" + xtend "~4.0.1" + +through@^2.3.6: + version "2.3.8" + resolved "https://registry.npm.taobao.org/through/download/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" + integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= + +thunky@^1.0.2: + version "1.1.0" + resolved "https://registry.nlark.com/thunky/download/thunky-1.1.0.tgz#5abaf714a9405db0504732bbccd2cedd9ef9537d" + integrity sha1-Wrr3FKlAXbBQRzK7zNLO3Z75U30= + +timers-browserify@^2.0.4: + version "2.0.12" + resolved "https://registry.nlark.com/timers-browserify/download/timers-browserify-2.0.12.tgz#44a45c11fbf407f34f97bccd1577c652361b00ee" + integrity sha1-RKRcEfv0B/NPl7zNFXfGUjYbAO4= + dependencies: + setimmediate "^1.0.4" + +tinycolor2@^1.4.2: + version "1.4.2" + resolved "https://registry.nlark.com/tinycolor2/download/tinycolor2-1.4.2.tgz#3f6a4d1071ad07676d7fa472e1fac40a719d8803" + integrity sha1-P2pNEHGtB2dtf6Ry4frECnGdiAM= + +tmp@^0.0.33: + version "0.0.33" + resolved "https://registry.nlark.com/tmp/download/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + integrity sha1-bTQzWIl2jSGyvNoKonfO07G/rfk= + dependencies: + os-tmpdir "~1.0.2" + +to-arraybuffer@^1.0.0: + version "1.0.1" + resolved "https://registry.npm.taobao.org/to-arraybuffer/download/to-arraybuffer-1.0.1.tgz#7d229b1fcc637e466ca081180836a7aabff83f43" + integrity sha1-fSKbH8xjfkZsoIEYCDanqr/4P0M= + +to-fast-properties@^1.0.3: + version "1.0.3" + resolved "https://registry.nlark.com/to-fast-properties/download/to-fast-properties-1.0.3.tgz?cache=0&sync_timestamp=1628418855671&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fto-fast-properties%2Fdownload%2Fto-fast-properties-1.0.3.tgz#b83571fa4d8c25b82e231b06e3a3055de4ca1a47" + integrity sha1-uDVx+k2MJbguIxsG46MFXeTKGkc= + +to-fast-properties@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/to-fast-properties/download/to-fast-properties-2.0.0.tgz?cache=0&sync_timestamp=1628418855671&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fto-fast-properties%2Fdownload%2Fto-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" + integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= + +to-object-path@^0.3.0: + version "0.3.0" + resolved "https://registry.nlark.com/to-object-path/download/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" + integrity sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68= + dependencies: + kind-of "^3.0.2" + +to-regex-range@^2.1.0: + version "2.1.1" + resolved "https://registry.nlark.com/to-regex-range/download/to-regex-range-2.1.1.tgz#7c80c17b9dfebe599e27367e0d4dd5590141db38" + integrity sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg= + dependencies: + is-number "^3.0.0" + repeat-string "^1.6.1" + +to-regex-range@^5.0.1: + version "5.0.1" + resolved "https://registry.nlark.com/to-regex-range/download/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" + integrity sha1-FkjESq58jZiKMmAY7XL1tN0DkuQ= + dependencies: + is-number "^7.0.0" + +to-regex@^3.0.1, to-regex@^3.0.2: + version "3.0.2" + resolved "https://registry.nlark.com/to-regex/download/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce" + integrity sha1-E8/dmzNlUvMLUfM6iuG0Knp1mc4= + dependencies: + define-property "^2.0.2" + extend-shallow "^3.0.2" + regex-not "^1.0.2" + safe-regex "^1.1.0" + +toggle-selection@^1.0.6: + version "1.0.6" + resolved "https://registry.nlark.com/toggle-selection/download/toggle-selection-1.0.6.tgz#6e45b1263f2017fa0acc7d89d78b15b8bf77da32" + integrity sha1-bkWxJj8gF/oKzH2J14sVuL932jI= + +toidentifier@1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/toidentifier/download/toidentifier-1.0.0.tgz#7e1be3470f1e77948bc43d94a3c8f4d7752ba553" + integrity sha1-fhvjRw8ed5SLxD2Uo8j013UrpVM= + +toposort@^1.0.0: + version "1.0.7" + resolved "https://registry.npm.taobao.org/toposort/download/toposort-1.0.7.tgz#2e68442d9f64ec720b8cc89e6443ac6caa950029" + integrity sha1-LmhELZ9k7HILjMieZEOsbKqVACk= + +toposort@^2.0.2: + version "2.0.2" + resolved "https://registry.npm.taobao.org/toposort/download/toposort-2.0.2.tgz#ae21768175d1559d48bef35420b2f4962f09c330" + integrity sha1-riF2gXXRVZ1IvvNUILL0li8JwzA= + +totalist@^1.0.0: + version "1.1.0" + resolved "https://registry.nlark.com/totalist/download/totalist-1.1.0.tgz#a4d65a3e546517701e3e5c37a47a70ac97fe56df" + integrity sha1-pNZaPlRlF3AePlw3pHpwrJf+Vt8= + +tough-cookie@^2.3.3, tough-cookie@~2.5.0: + version "2.5.0" + resolved "https://registry.npm.taobao.org/tough-cookie/download/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" + integrity sha1-zZ+yoKodWhK0c72fuW+j3P9lreI= + dependencies: + psl "^1.1.28" + punycode "^2.1.1" + +tough-cookie@^3.0.1: + version "3.0.1" + resolved "https://registry.npm.taobao.org/tough-cookie/download/tough-cookie-3.0.1.tgz#9df4f57e739c26930a018184887f4adb7dca73b2" + integrity sha1-nfT1fnOcJpMKAYGEiH9K233Kc7I= + dependencies: + ip-regex "^2.1.0" + psl "^1.1.28" + punycode "^2.1.1" + +tr46@^1.0.1: + version "1.0.1" + resolved "https://registry.npmmirror.com/tr46/download/tr46-1.0.1.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ftr46%2Fdownload%2Ftr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09" + integrity sha1-qLE/1r/SSJUZZ0zN5VujaTtwbQk= + dependencies: + punycode "^2.1.0" + +trim-newlines@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/trim-newlines/download/trim-newlines-1.0.0.tgz?cache=0&sync_timestamp=1623341510447&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftrim-newlines%2Fdownload%2Ftrim-newlines-1.0.0.tgz#5887966bb582a4503a41eb524f7d35011815a613" + integrity sha1-WIeWa7WCpFA6QetST301ARgVphM= + +trim-newlines@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/trim-newlines/download/trim-newlines-2.0.0.tgz?cache=0&sync_timestamp=1623341510447&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftrim-newlines%2Fdownload%2Ftrim-newlines-2.0.0.tgz#b403d0b91be50c331dfc4b82eeceb22c3de16d20" + integrity sha1-tAPQuRvlDDMd/EuC7s6yLD3hbSA= + +trim-trailing-lines@^1.0.0: + version "1.1.4" + resolved "https://registry.nlark.com/trim-trailing-lines/download/trim-trailing-lines-1.1.4.tgz#bd4abbec7cc880462f10b2c8b5ce1d8d1ec7c2c0" + integrity sha1-vUq77HzIgEYvELLItc4djR7HwsA= + +trim@0.0.1: + version "0.0.1" + resolved "https://registry.npm.taobao.org/trim/download/trim-0.0.1.tgz?cache=0&sync_timestamp=1617310803947&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Ftrim%2Fdownload%2Ftrim-0.0.1.tgz#5858547f6b290757ee95cccc666fb50084c460dd" + integrity sha1-WFhUf2spB1fulczMZm+1AITEYN0= + +trough@^1.0.0: + version "1.0.5" + resolved "https://registry.nlark.com/trough/download/trough-1.0.5.tgz?cache=0&sync_timestamp=1625400622069&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftrough%2Fdownload%2Ftrough-1.0.5.tgz#b8b639cefad7d0bb2abd37d433ff8293efa5f406" + integrity sha1-uLY5zvrX0LsqvTfUM/+Ck++l9AY= + +"true-case-path@^1.0.2": + version "1.0.3" + resolved "https://registry.nlark.com/true-case-path/download/true-case-path-1.0.3.tgz#f813b5a8c86b40da59606722b144e3225799f47d" + integrity sha1-+BO1qMhrQNpZYGcisUTjIleZ9H0= + dependencies: + glob "^7.1.2" + +ts-invariant@^0.9.0: + version "0.9.4" + resolved "https://registry.npmmirror.com/ts-invariant/-/ts-invariant-0.9.4.tgz#42ac6c791aade267dd9dc65276549df5c5d71cac" + integrity sha512-63jtX/ZSwnUNi/WhXjnK8kz4cHHpYS60AnmA6ixz17l7E12a5puCWFlNpkne5Rl0J8TBPVHpGjsj4fxs8ObVLQ== + dependencies: + tslib "^2.1.0" + +tsconfig-paths@^3.11.0: + version "3.11.0" + resolved "https://registry.nlark.com/tsconfig-paths/download/tsconfig-paths-3.11.0.tgz?cache=0&sync_timestamp=1629839757813&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftsconfig-paths%2Fdownload%2Ftsconfig-paths-3.11.0.tgz#954c1fe973da6339c78e06b03ce2e48810b65f36" + integrity sha1-lUwf6XPaYznHjgawPOLkiBC2XzY= + dependencies: + "@types/json5" "^0.0.29" + json5 "^1.0.1" + minimist "^1.2.0" + strip-bom "^3.0.0" + +tslib@^1.10.0, tslib@^1.8.1, tslib@^1.9.0: + version "1.14.1" + resolved "https://registry.nlark.com/tslib/download/tslib-1.14.1.tgz?cache=0&sync_timestamp=1628722556410&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftslib%2Fdownload%2Ftslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" + integrity sha1-zy04vcNKE0vK8QkcQfZhni9nLQA= + +tslib@^2.1.0, tslib@^2.3.0: + version "2.3.1" + resolved "https://registry.nlark.com/tslib/download/tslib-2.3.1.tgz?cache=0&sync_timestamp=1628722556410&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftslib%2Fdownload%2Ftslib-2.3.1.tgz#e8a335add5ceae51aa261d32a490158ef042ef01" + integrity sha1-6KM1rdXOrlGqJh0ypJAVjvBC7wE= + +tsutils@^3.21.0: + version "3.21.0" + resolved "https://registry.nlark.com/tsutils/download/tsutils-3.21.0.tgz?cache=0&sync_timestamp=1622604538827&other_urls=https%3A%2F%2Fregistry.nlark.com%2Ftsutils%2Fdownload%2Ftsutils-3.21.0.tgz#b48717d394cea6c1e096983eed58e9d61715b623" + integrity sha1-tIcX05TOpsHglpg+7Vjp1hcVtiM= + dependencies: + tslib "^1.8.1" + +tty-browserify@0.0.0: + version "0.0.0" + resolved "https://registry.nlark.com/tty-browserify/download/tty-browserify-0.0.0.tgz#a157ba402da24e9bf957f9aa69d524eed42901a6" + integrity sha1-oVe6QC2iTpv5V/mqadUk7tQpAaY= + +tunnel-agent@^0.6.0: + version "0.6.0" + resolved "https://registry.nlark.com/tunnel-agent/download/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" + integrity sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0= + dependencies: + safe-buffer "^5.0.1" + +tweetnacl@^0.14.3, tweetnacl@~0.14.0: + version "0.14.5" + resolved "https://registry.npm.taobao.org/tweetnacl/download/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" + integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= + +type-check@~0.3.2: + version "0.3.2" + resolved "https://registry.npm.taobao.org/type-check/download/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" + integrity sha1-WITKtRLPHTVeP7eE8wgEsrUg23I= + dependencies: + prelude-ls "~1.1.2" + +type-fest@^0.21.3: + version "0.21.3" + resolved "https://registry.npmmirror.com/type-fest/download/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" + integrity sha1-0mCiSwGYQ24TP6JqUkptZfo7Ljc= + +type-fest@^0.8.1: + version "0.8.1" + resolved "https://registry.npmmirror.com/type-fest/download/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" + integrity sha1-CeJJ696FHTseSNJ8EFREZn8XuD0= + +type-is@~1.6.17, type-is@~1.6.18: + version "1.6.18" + resolved "https://registry.nlark.com/type-is/download/type-is-1.6.18.tgz#4e552cd05df09467dcbc4ef739de89f2cf37c131" + integrity sha1-TlUs0F3wlGfcvE73Od6J8s83wTE= + dependencies: + media-typer "0.3.0" + mime-types "~2.1.24" + +type@^1.0.1: + version "1.2.0" + resolved "https://registry.npm.taobao.org/type/download/type-1.2.0.tgz#848dd7698dafa3e54a6c479e759c4bc3f18847a0" + integrity sha1-hI3XaY2vo+VKbEeedZxLw/GIR6A= + +type@^2.5.0: + version "2.5.0" + resolved "https://registry.npm.taobao.org/type/download/type-2.5.0.tgz#0a2e78c2e77907b252abe5f298c1b01c63f0db3d" + integrity sha1-Ci54wud5B7JSq+XymMGwHGPw2z0= + +typedarray@^0.0.6: + version "0.0.6" + resolved "https://registry.nlark.com/typedarray/download/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" + integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= + +typescript-compare@^0.0.2: + version "0.0.2" + resolved "https://registry.npm.taobao.org/typescript-compare/download/typescript-compare-0.0.2.tgz#7ee40a400a406c2ea0a7e551efd3309021d5f425" + integrity sha1-fuQKQApAbC6gp+VR79MwkCHV9CU= + dependencies: + typescript-logic "^0.0.0" + +typescript-logic@^0.0.0: + version "0.0.0" + resolved "https://registry.nlark.com/typescript-logic/download/typescript-logic-0.0.0.tgz#66ebd82a2548f2b444a43667bec120b496890196" + integrity sha1-ZuvYKiVI8rREpDZnvsEgtJaJAZY= + +typescript-tuple@^2.2.1: + version "2.2.1" + resolved "https://registry.npm.taobao.org/typescript-tuple/download/typescript-tuple-2.2.1.tgz#7d9813fb4b355f69ac55032e0363e8bb0f04dad2" + integrity sha1-fZgT+0s1X2msVQMuA2Pouw8E2tI= + dependencies: + typescript-compare "^0.0.2" + +typescript@^4.1.0: + version "4.4.4" + resolved "https://registry.npmmirror.com/typescript/download/typescript-4.4.4.tgz?cache=0&sync_timestamp=1636269639490&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Ftypescript%2Fdownload%2Ftypescript-4.4.4.tgz#2cd01a1a1f160704d3101fd5a58ff0f9fcb8030c" + integrity sha1-LNAaGh8WBwTTEB/VpY/w+fy4Aww= + +uglify-js@3.4.x: + version "3.4.10" + resolved "https://registry.npmmirror.com/uglify-js/download/uglify-js-3.4.10.tgz#9ad9563d8eb3acdfb8d38597d2af1d815f6a755f" + integrity sha1-mtlWPY6zrN+404WX0q8dgV9qdV8= + dependencies: + commander "~2.19.0" + source-map "~0.6.1" + +uglify-js@^3.5.1: + version "3.14.3" + resolved "https://registry.npmmirror.com/uglify-js/download/uglify-js-3.14.3.tgz#c0f25dfea1e8e5323eccf59610be08b6043c15cf" + integrity sha1-wPJd/qHo5TI+zPWWEL4ItgQ8Fc8= + +unbox-primitive@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/unbox-primitive/download/unbox-primitive-1.0.1.tgz#085e215625ec3162574dc8859abee78a59b14471" + integrity sha1-CF4hViXsMWJXTciFmr7nilmxRHE= + dependencies: + function-bind "^1.1.1" + has-bigints "^1.0.1" + has-symbols "^1.0.2" + which-boxed-primitive "^1.0.2" + +unescape-js@^1.1.1, unescape-js@^1.1.4: + version "1.1.4" + resolved "https://registry.npm.taobao.org/unescape-js/download/unescape-js-1.1.4.tgz#4bc6389c499cb055a98364a0b3094e1c3d5da395" + integrity sha1-S8Y4nEmcsFWpg2SgswlOHD1do5U= + dependencies: + string.fromcodepoint "^0.2.1" + +unherit@^1.0.4: + version "1.1.3" + resolved "https://registry.nlark.com/unherit/download/unherit-1.1.3.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funherit%2Fdownload%2Funherit-1.1.3.tgz#6c9b503f2b41b262330c80e91c8614abdaa69c22" + integrity sha1-bJtQPytBsmIzDIDpHIYUq9qmnCI= + dependencies: + inherits "^2.0.0" + xtend "^4.0.0" + +unicode-canonical-property-names-ecmascript@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/unicode-canonical-property-names-ecmascript/download/unicode-canonical-property-names-ecmascript-2.0.0.tgz#301acdc525631670d39f6146e0e77ff6bbdebddc" + integrity sha1-MBrNxSVjFnDTn2FG4Od/9rvevdw= + +unicode-match-property-ecmascript@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/unicode-match-property-ecmascript/download/unicode-match-property-ecmascript-2.0.0.tgz?cache=0&sync_timestamp=1631618696521&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funicode-match-property-ecmascript%2Fdownload%2Funicode-match-property-ecmascript-2.0.0.tgz#54fd16e0ecb167cf04cf1f756bdcc92eba7976c3" + integrity sha1-VP0W4OyxZ88Ezx91a9zJLrp5dsM= + dependencies: + unicode-canonical-property-names-ecmascript "^2.0.0" + unicode-property-aliases-ecmascript "^2.0.0" + +unicode-match-property-value-ecmascript@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/unicode-match-property-value-ecmascript/download/unicode-match-property-value-ecmascript-2.0.0.tgz#1a01aa57247c14c568b89775a54938788189a714" + integrity sha1-GgGqVyR8FMVouJd1pUk4eIGJpxQ= + +unicode-property-aliases-ecmascript@^2.0.0: + version "2.0.0" + resolved "https://registry.nlark.com/unicode-property-aliases-ecmascript/download/unicode-property-aliases-ecmascript-2.0.0.tgz?cache=0&sync_timestamp=1631609457921&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funicode-property-aliases-ecmascript%2Fdownload%2Funicode-property-aliases-ecmascript-2.0.0.tgz#0a36cb9a585c4f6abd51ad1deddb285c165297c8" + integrity sha1-CjbLmlhcT2q9Ua0d7dsoXBZSl8g= + +unified@^6.0.0: + version "6.2.0" + resolved "https://registry.nlark.com/unified/download/unified-6.2.0.tgz?cache=0&sync_timestamp=1627639621063&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funified%2Fdownload%2Funified-6.2.0.tgz#7fbd630f719126d67d40c644b7e3f617035f6dba" + integrity sha1-f71jD3GRJtZ9QMZEt+P2FwNfbbo= + dependencies: + bail "^1.0.0" + extend "^3.0.0" + is-plain-obj "^1.1.0" + trough "^1.0.0" + vfile "^2.0.0" + x-is-string "^0.1.0" + +union-value@^1.0.0: + version "1.0.1" + resolved "https://registry.nlark.com/union-value/download/union-value-1.0.1.tgz#0b6fe7b835aecda61c6ea4d4f02c14221e109847" + integrity sha1-C2/nuDWuzaYcbqTU8CwUIh4QmEc= + dependencies: + arr-union "^3.1.0" + get-value "^2.0.6" + is-extendable "^0.1.1" + set-value "^2.0.1" + +uniq@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/uniq/download/uniq-1.0.1.tgz#b31c5ae8254844a3a8281541ce2b04b865a734ff" + integrity sha1-sxxa6CVIRKOoKBVBzisEuGWnNP8= + +unique-filename@^1.1.1: + version "1.1.1" + resolved "https://registry.npm.taobao.org/unique-filename/download/unique-filename-1.1.1.tgz#1d69769369ada0583103a1e6ae87681b56573230" + integrity sha1-HWl2k2mtoFgxA6HmrodoG1ZXMjA= + dependencies: + unique-slug "^2.0.0" + +unique-slug@^2.0.0: + version "2.0.2" + resolved "https://registry.nlark.com/unique-slug/download/unique-slug-2.0.2.tgz#baabce91083fc64e945b0f3ad613e264f7cd4e6c" + integrity sha1-uqvOkQg/xk6UWw861hPiZPfNTmw= + dependencies: + imurmurhash "^0.1.4" + +unist-util-find-all-after@^1.0.2: + version "1.0.5" + resolved "https://registry.nlark.com/unist-util-find-all-after/download/unist-util-find-all-after-1.0.5.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funist-util-find-all-after%2Fdownload%2Funist-util-find-all-after-1.0.5.tgz#5751a8608834f41d117ad9c577770c5f2f1b2899" + integrity sha1-V1GoYIg09B0RetnFd3cMXy8bKJk= + dependencies: + unist-util-is "^3.0.0" + +unist-util-is@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/unist-util-is/download/unist-util-is-3.0.0.tgz?cache=0&sync_timestamp=1626874922677&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funist-util-is%2Fdownload%2Funist-util-is-3.0.0.tgz#d9e84381c2468e82629e4a5be9d7d05a2dd324cd" + integrity sha1-2ehDgcJGjoJinkpb6dfQWi3TJM0= + +unist-util-remove-position@^1.0.0: + version "1.1.4" + resolved "https://registry.nlark.com/unist-util-remove-position/download/unist-util-remove-position-1.1.4.tgz?cache=0&sync_timestamp=1627848251490&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funist-util-remove-position%2Fdownload%2Funist-util-remove-position-1.1.4.tgz#ec037348b6102c897703eee6d0294ca4755a2020" + integrity sha1-7ANzSLYQLIl3A+7m0ClMpHVaICA= + dependencies: + unist-util-visit "^1.1.0" + +unist-util-stringify-position@^1.0.0, unist-util-stringify-position@^1.1.1: + version "1.1.2" + resolved "https://registry.nlark.com/unist-util-stringify-position/download/unist-util-stringify-position-1.1.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funist-util-stringify-position%2Fdownload%2Funist-util-stringify-position-1.1.2.tgz#3f37fcf351279dcbca7480ab5889bb8a832ee1c6" + integrity sha1-Pzf881EnncvKdICrWIm7ioMu4cY= + +unist-util-visit-parents@^2.0.0: + version "2.1.2" + resolved "https://registry.nlark.com/unist-util-visit-parents/download/unist-util-visit-parents-2.1.2.tgz?cache=0&sync_timestamp=1632208991791&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funist-util-visit-parents%2Fdownload%2Funist-util-visit-parents-2.1.2.tgz#25e43e55312166f3348cae6743588781d112c1e9" + integrity sha1-JeQ+VTEhZvM0jK5nQ1iHgdESwek= + dependencies: + unist-util-is "^3.0.0" + +unist-util-visit@^1.1.0: + version "1.4.1" + resolved "https://registry.npmmirror.com/unist-util-visit/download/unist-util-visit-1.4.1.tgz?cache=0&sync_timestamp=1632405298952&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Funist-util-visit%2Fdownload%2Funist-util-visit-1.4.1.tgz#4724aaa8486e6ee6e26d7ff3c8685960d560b1e3" + integrity sha1-RySqqEhububibX/zyGhZYNVgseM= + dependencies: + unist-util-visit-parents "^2.0.0" + +universal-router@^8.3.0: + version "8.3.0" + resolved "https://registry.nlark.com/universal-router/download/universal-router-8.3.0.tgz?cache=0&sync_timestamp=1624462107331&other_urls=https%3A%2F%2Fregistry.nlark.com%2Funiversal-router%2Fdownload%2Funiversal-router-8.3.0.tgz#533bce135d7b1abf591421c5d2028d54407a34a0" + integrity sha1-UzvOE117Gr9ZFCHF0gKNVEB6NKA= + dependencies: + path-to-regexp "^3.1.0" + +universalify@^0.1.0: + version "0.1.2" + resolved "https://registry.nlark.com/universalify/download/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" + integrity sha1-tkb2m+OULavOzJ1mOcgNwQXvqmY= + +unpipe@1.0.0, unpipe@~1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/unpipe/download/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec" + integrity sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw= + +unset-value@^1.0.0: + version "1.0.0" + resolved "https://registry.nlark.com/unset-value/download/unset-value-1.0.0.tgz#8376873f7d2335179ffb1e6fc3a8ed0dfc8ab559" + integrity sha1-g3aHP30jNRef+x5vw6jtDfyKtVk= + dependencies: + has-value "^0.3.1" + isobject "^3.0.0" + +upath@^1.1.1: + version "1.2.0" + resolved "https://registry.npm.taobao.org/upath/download/upath-1.2.0.tgz#8f66dbcd55a883acdae4408af8b035a5044c1894" + integrity sha1-j2bbzVWog6za5ECK+LA1pQRMGJQ= + +upper-case@^1.1.1: + version "1.1.3" + resolved "https://registry.nlark.com/upper-case/download/upper-case-1.1.3.tgz#f6b4501c2ec4cdd26ba78be7222961de77621598" + integrity sha1-9rRQHC7EzdJrp4vnIilh3ndiFZg= + +uri-js@^4.2.2: + version "4.4.1" + resolved "https://registry.npm.taobao.org/uri-js/download/uri-js-4.4.1.tgz?cache=0&sync_timestamp=1610237624359&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Furi-js%2Fdownload%2Furi-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" + integrity sha1-mxpSWVIlhZ5V9mnZKPiMbFfyp34= + dependencies: + punycode "^2.1.0" + +urix@^0.1.0: + version "0.1.0" + resolved "https://registry.npmmirror.com/urix/download/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" + integrity sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI= + +url-loader@^4.1.0: + version "4.1.1" + resolved "https://registry.npmmirror.com/url-loader/download/url-loader-4.1.1.tgz#28505e905cae158cf07c92ca622d7f237e70a4e2" + integrity sha1-KFBekFyuFYzwfJLKYi1/I35wpOI= + dependencies: + loader-utils "^2.0.0" + mime-types "^2.1.27" + schema-utils "^3.0.0" + +url-parse@^1.4.3, url-parse@^1.4.7: + version "1.5.3" + resolved "https://registry.nlark.com/url-parse/download/url-parse-1.5.3.tgz#71c1303d38fb6639ade183c2992c8cc0686df862" + integrity sha1-ccEwPTj7Zjmt4YPCmSyMwGht+GI= + dependencies: + querystringify "^2.1.1" + requires-port "^1.0.0" + +url-search-params-polyfill@^8.1.1: + version "8.1.1" + resolved "https://registry.npm.taobao.org/url-search-params-polyfill/download/url-search-params-polyfill-8.1.1.tgz?cache=0&sync_timestamp=1616725028225&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Furl-search-params-polyfill%2Fdownload%2Furl-search-params-polyfill-8.1.1.tgz#9e69e4dba300a71ae7ad3cead62c7717fd99329f" + integrity sha1-nmnk26MApxrnrTzq1ix3F/2ZMp8= + +url@^0.11.0: + version "0.11.0" + resolved "https://registry.nlark.com/url/download/url-0.11.0.tgz?cache=0&sync_timestamp=1618847135337&other_urls=https%3A%2F%2Fregistry.nlark.com%2Furl%2Fdownload%2Furl-0.11.0.tgz#3838e97cfc60521eb73c525a8e55bfdd9e2e28f1" + integrity sha1-ODjpfPxgUh63PFJajlW/3Z4uKPE= + dependencies: + punycode "1.3.2" + querystring "0.2.0" + +use@^3.1.0: + version "3.1.1" + resolved "https://registry.nlark.com/use/download/use-3.1.1.tgz#d50c8cac79a19fbc20f2911f56eb973f4e10070f" + integrity sha1-1QyMrHmhn7wg8pEfVuuXP04QBw8= + +util-deprecate@^1.0.1, util-deprecate@^1.0.2, util-deprecate@~1.0.1: + version "1.0.2" + resolved "https://registry.nlark.com/util-deprecate/download/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" + integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= + +util.promisify@1.0.0: + version "1.0.0" + resolved "https://registry.npm.taobao.org/util.promisify/download/util.promisify-1.0.0.tgz?cache=0&sync_timestamp=1610159895694&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Futil.promisify%2Fdownload%2Futil.promisify-1.0.0.tgz#440f7165a459c9a16dc145eb8e72f35687097030" + integrity sha1-RA9xZaRZyaFtwUXrjnLzVocJcDA= + dependencies: + define-properties "^1.1.2" + object.getownpropertydescriptors "^2.0.3" + +util@0.10.3: + version "0.10.3" + resolved "https://registry.nlark.com/util/download/util-0.10.3.tgz?cache=0&sync_timestamp=1622212984161&other_urls=https%3A%2F%2Fregistry.nlark.com%2Futil%2Fdownload%2Futil-0.10.3.tgz#7afb1afe50805246489e3db7fe0ed379336ac0f9" + integrity sha1-evsa/lCAUkZInj23/g7TeTNqwPk= + dependencies: + inherits "2.0.1" + +util@^0.11.0: + version "0.11.1" + resolved "https://registry.nlark.com/util/download/util-0.11.1.tgz?cache=0&sync_timestamp=1622212984161&other_urls=https%3A%2F%2Fregistry.nlark.com%2Futil%2Fdownload%2Futil-0.11.1.tgz#3236733720ec64bb27f6e26f421aaa2e1b588d61" + integrity sha1-MjZzNyDsZLsn9uJvQhqqLhtYjWE= + dependencies: + inherits "2.0.3" + +utila@~0.4: + version "0.4.0" + resolved "https://registry.nlark.com/utila/download/utila-0.4.0.tgz#8a16a05d445657a3aea5eecc5b12a4fa5379772c" + integrity sha1-ihagXURWV6Oupe7MWxKk+lN5dyw= + +utils-merge@1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/utils-merge/download/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" + integrity sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM= + +uuid@^3.3.2, uuid@^3.4.0: + version "3.4.0" + resolved "https://registry.npmmirror.com/uuid/download/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" + integrity sha1-sj5DWK+oogL+ehAK8fX4g/AgB+4= + +v8-compile-cache@^2.0.3: + version "2.3.0" + resolved "https://registry.nlark.com/v8-compile-cache/download/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" + integrity sha1-LeGWGMZtwkfc+2+ZM4A12CRaLO4= + +validate-npm-package-license@^3.0.1: + version "3.0.4" + resolved "https://registry.nlark.com/validate-npm-package-license/download/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a" + integrity sha1-/JH2uce6FchX9MssXe/uw51PQQo= + dependencies: + spdx-correct "^3.0.0" + spdx-expression-parse "^3.0.0" + +vary@~1.1.2: + version "1.1.2" + resolved "https://registry.nlark.com/vary/download/vary-1.1.2.tgz#2299f02c6ded30d4a5961b0b9f74524a18f634fc" + integrity sha1-IpnwLG3tMNSllhsLn3RSShj2NPw= + +verror@1.10.0: + version "1.10.0" + resolved "https://registry.npmmirror.com/verror/download/verror-1.10.0.tgz?cache=0&sync_timestamp=1635885078723&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fverror%2Fdownload%2Fverror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" + integrity sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA= + dependencies: + assert-plus "^1.0.0" + core-util-is "1.0.2" + extsprintf "^1.2.0" + +vfile-location@^2.0.0: + version "2.0.6" + resolved "https://registry.nlark.com/vfile-location/download/vfile-location-2.0.6.tgz#8a274f39411b8719ea5728802e10d9e0dff1519e" + integrity sha1-iidPOUEbhxnqVyiALhDZ4N/xUZ4= + +vfile-message@^1.0.0: + version "1.1.1" + resolved "https://registry.nlark.com/vfile-message/download/vfile-message-1.1.1.tgz?cache=0&sync_timestamp=1628780833868&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fvfile-message%2Fdownload%2Fvfile-message-1.1.1.tgz#5833ae078a1dfa2d96e9647886cd32993ab313e1" + integrity sha1-WDOuB4od+i2W6WR4hs0ymTqzE+E= + dependencies: + unist-util-stringify-position "^1.1.1" + +vfile@^2.0.0: + version "2.3.0" + resolved "https://registry.npmmirror.com/vfile/download/vfile-2.3.0.tgz?cache=0&sync_timestamp=1635657387660&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fvfile%2Fdownload%2Fvfile-2.3.0.tgz#e62d8e72b20e83c324bc6c67278ee272488bf84a" + integrity sha1-5i2OcrIOg8MkvGxnJ47ickiL+Eo= + dependencies: + is-buffer "^1.1.4" + replace-ext "1.0.0" + unist-util-stringify-position "^1.0.0" + vfile-message "^1.0.0" + +vm-browserify@^1.0.1: + version "1.1.2" + resolved "https://registry.nlark.com/vm-browserify/download/vm-browserify-1.1.2.tgz#78641c488b8e6ca91a75f511e7a3b32a86e5dda0" + integrity sha1-eGQcSIuObKkadfUR56OzKobl3aA= + +vm2@^3.8.4: + version "3.9.5" + resolved "https://registry.npmmirror.com/vm2/download/vm2-3.9.5.tgz#5288044860b4bbace443101fcd3bddb2a0aa2496" + integrity sha1-UogESGC0u6zkQxAfzTvdsqCqJJY= + +w3c-hr-time@^1.0.1: + version "1.0.2" + resolved "https://registry.nlark.com/w3c-hr-time/download/w3c-hr-time-1.0.2.tgz#0a89cdf5cc15822df9c360543676963e0cc308cd" + integrity sha1-ConN9cwVgi35w2BUNnaWPgzDCM0= + dependencies: + browser-process-hrtime "^1.0.0" + +w3c-xmlserializer@^1.1.2: + version "1.1.2" + resolved "https://registry.nlark.com/w3c-xmlserializer/download/w3c-xmlserializer-1.1.2.tgz?cache=0&sync_timestamp=1632004166700&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fw3c-xmlserializer%2Fdownload%2Fw3c-xmlserializer-1.1.2.tgz#30485ca7d70a6fd052420a3d12fd90e6339ce794" + integrity sha1-MEhcp9cKb9BSQgo9Ev2Q5jOc55Q= + dependencies: + domexception "^1.0.1" + webidl-conversions "^4.0.2" + xml-name-validator "^3.0.0" + +watchpack-chokidar2@^2.0.1: + version "2.0.1" + resolved "https://registry.nlark.com/watchpack-chokidar2/download/watchpack-chokidar2-2.0.1.tgz#38500072ee6ece66f3769936950ea1771be1c957" + integrity sha1-OFAAcu5uzmbzdpk2lQ6hdxvhyVc= + dependencies: + chokidar "^2.1.8" + +watchpack@^1.7.4: + version "1.7.5" + resolved "https://registry.nlark.com/watchpack/download/watchpack-1.7.5.tgz#1267e6c55e0b9b5be44c2023aed5437a2c26c453" + integrity sha1-EmfmxV4Lm1vkTCAjrtVDeiwmxFM= + dependencies: + graceful-fs "^4.1.2" + neo-async "^2.5.0" + optionalDependencies: + chokidar "^3.4.1" + watchpack-chokidar2 "^2.0.1" + +wbuf@^1.1.0, wbuf@^1.7.3: + version "1.7.3" + resolved "https://registry.npm.taobao.org/wbuf/download/wbuf-1.7.3.tgz#c1d8d149316d3ea852848895cb6a0bfe887b87df" + integrity sha1-wdjRSTFtPqhShIiVy2oL/oh7h98= + dependencies: + minimalistic-assert "^1.0.0" + +wcwidth@^1.0.1: + version "1.0.1" + resolved "https://registry.nlark.com/wcwidth/download/wcwidth-1.0.1.tgz#f0b0dcf915bc5ff1528afadb2c0e17b532da2fe8" + integrity sha1-8LDc+RW8X/FSivrbLA4XtTLaL+g= + dependencies: + defaults "^1.0.3" + +webidl-conversions@^4.0.2: + version "4.0.2" + resolved "https://registry.nlark.com/webidl-conversions/download/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" + integrity sha1-qFWYCx8LazWbodXZ+zmulB+qY60= + +webpack-bundle-analyzer@^4.5.0: + version "4.5.0" + resolved "https://registry.npmmirror.com/webpack-bundle-analyzer/download/webpack-bundle-analyzer-4.5.0.tgz?cache=0&sync_timestamp=1634019921368&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fwebpack-bundle-analyzer%2Fdownload%2Fwebpack-bundle-analyzer-4.5.0.tgz#1b0eea2947e73528754a6f9af3e91b2b6e0f79d5" + integrity sha1-Gw7qKUfnNSh1Sm+a8+kbK24PedU= + dependencies: + acorn "^8.0.4" + acorn-walk "^8.0.0" + chalk "^4.1.0" + commander "^7.2.0" + gzip-size "^6.0.0" + lodash "^4.17.20" + opener "^1.5.2" + sirv "^1.0.7" + ws "^7.3.1" + +webpack-chain@4.9.0: + version "4.9.0" + resolved "https://registry.npm.taobao.org/webpack-chain/download/webpack-chain-4.9.0.tgz#2f0794d34d79a7cc5db1416f497b76ad33df30ee" + integrity sha1-LweU0015p8xdsUFvSXt2rTPfMO4= + dependencies: + deepmerge "^1.5.2" + javascript-stringify "^1.6.0" + +webpack-dev-middleware@^3.7.2: + version "3.7.3" + resolved "https://registry.npmmirror.com/webpack-dev-middleware/download/webpack-dev-middleware-3.7.3.tgz#0639372b143262e2b84ab95d3b91a7597061c2c5" + integrity sha1-Bjk3KxQyYuK4SrldO5GnWXBhwsU= + dependencies: + memory-fs "^0.4.1" + mime "^2.4.4" + mkdirp "^0.5.1" + range-parser "^1.2.1" + webpack-log "^2.0.0" + +webpack-dev-server@3.11.0: + version "3.11.0" + resolved "https://registry.npmmirror.com/webpack-dev-server/download/webpack-dev-server-3.11.0.tgz#8f154a3bce1bcfd1cc618ef4e703278855e7ff8c" + integrity sha1-jxVKO84bz9HMYY705wMniFXn/4w= + dependencies: + ansi-html "0.0.7" + bonjour "^3.5.0" + chokidar "^2.1.8" + compression "^1.7.4" + connect-history-api-fallback "^1.6.0" + debug "^4.1.1" + del "^4.1.1" + express "^4.17.1" + html-entities "^1.3.1" + http-proxy-middleware "0.19.1" + import-local "^2.0.0" + internal-ip "^4.3.0" + ip "^1.1.5" + is-absolute-url "^3.0.3" + killable "^1.0.1" + loglevel "^1.6.8" + opn "^5.5.0" + p-retry "^3.0.1" + portfinder "^1.0.26" + schema-utils "^1.0.0" + selfsigned "^1.10.7" + semver "^6.3.0" + serve-index "^1.9.1" + sockjs "0.3.20" + sockjs-client "1.4.0" + spdy "^4.0.2" + strip-ansi "^3.0.1" + supports-color "^6.1.0" + url "^0.11.0" + webpack-dev-middleware "^3.7.2" + webpack-log "^2.0.0" + ws "^6.2.1" + yargs "^13.3.2" + +webpack-format-messages@^2.0.5: + version "2.0.6" + resolved "https://registry.nlark.com/webpack-format-messages/download/webpack-format-messages-2.0.6.tgz#d8bb0d4fb2e9171efc8a252d6294f29c50d7ecd2" + integrity sha1-2LsNT7LpFx78iiUtYpTynFDX7NI= + dependencies: + kleur "^3.0.0" + +webpack-log@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/webpack-log/download/webpack-log-2.0.0.tgz?cache=0&sync_timestamp=1615477439589&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fwebpack-log%2Fdownload%2Fwebpack-log-2.0.0.tgz#5b7928e0637593f119d32f6227c1e0ac31e1b47f" + integrity sha1-W3ko4GN1k/EZ0y9iJ8HgrDHhtH8= + dependencies: + ansi-colors "^3.0.0" + uuid "^3.3.2" + +webpack-sources@^1.0.1, webpack-sources@^1.1.0, webpack-sources@^1.4.0, webpack-sources@^1.4.1, webpack-sources@^1.4.3: + version "1.4.3" + resolved "https://registry.nlark.com/webpack-sources/download/webpack-sources-1.4.3.tgz#eedd8ec0b928fbf1cbfe994e22d2d890f330a933" + integrity sha1-7t2OwLko+/HL/plOItLYkPMwqTM= + dependencies: + source-list-map "^2.0.0" + source-map "~0.6.1" + +webpack@4.46.0: + version "4.46.0" + resolved "https://registry.npmmirror.com/webpack/download/webpack-4.46.0.tgz?cache=0&sync_timestamp=1636129625466&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fwebpack%2Fdownload%2Fwebpack-4.46.0.tgz#bf9b4404ea20a073605e0a011d188d77cb6ad542" + integrity sha1-v5tEBOogoHNgXgoBHRiNd8tq1UI= + dependencies: + "@webassemblyjs/ast" "1.9.0" + "@webassemblyjs/helper-module-context" "1.9.0" + "@webassemblyjs/wasm-edit" "1.9.0" + "@webassemblyjs/wasm-parser" "1.9.0" + acorn "^6.4.1" + ajv "^6.10.2" + ajv-keywords "^3.4.1" + chrome-trace-event "^1.0.2" + enhanced-resolve "^4.5.0" + eslint-scope "^4.0.3" + json-parse-better-errors "^1.0.2" + loader-runner "^2.4.0" + loader-utils "^1.2.3" + memory-fs "^0.4.1" + micromatch "^3.1.10" + mkdirp "^0.5.3" + neo-async "^2.6.1" + node-libs-browser "^2.2.1" + schema-utils "^1.0.0" + tapable "^1.1.3" + terser-webpack-plugin "^1.4.3" + watchpack "^1.7.4" + webpack-sources "^1.4.1" + +websocket-driver@0.6.5: + version "0.6.5" + resolved "https://registry.nlark.com/websocket-driver/download/websocket-driver-0.6.5.tgz#5cb2556ceb85f4373c6d8238aa691c8454e13a36" + integrity sha1-XLJVbOuF9Dc8bYI4qmkchFThOjY= + dependencies: + websocket-extensions ">=0.1.1" + +websocket-driver@>=0.5.1: + version "0.7.4" + resolved "https://registry.nlark.com/websocket-driver/download/websocket-driver-0.7.4.tgz#89ad5295bbf64b480abcba31e4953aca706f5760" + integrity sha1-ia1Slbv2S0gKvLox5JU6ynBvV2A= + dependencies: + http-parser-js ">=0.5.1" + safe-buffer ">=5.1.0" + websocket-extensions ">=0.1.1" + +websocket-extensions@>=0.1.1: + version "0.1.4" + resolved "https://registry.npm.taobao.org/websocket-extensions/download/websocket-extensions-0.1.4.tgz#7f8473bc839dfd87608adb95d7eb075211578a42" + integrity sha1-f4RzvIOd/YdgituV1+sHUhFXikI= + +weui@^1.1.2: + version "1.1.3" + resolved "https://registry.npmmirror.com/weui/download/weui-1.1.3.tgz?cache=0&sync_timestamp=1634013113866&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fweui%2Fdownload%2Fweui-1.1.3.tgz#0f0899bb61bb2ec603b2648367a8139298f81514" + integrity sha1-DwiZu2G7LsYDsmSDZ6gTkpj4FRQ= + +whatwg-encoding@^1.0.1, whatwg-encoding@^1.0.5: + version "1.0.5" + resolved "https://registry.nlark.com/whatwg-encoding/download/whatwg-encoding-1.0.5.tgz#5abacf777c32166a51d085d6b4f3e7d27113ddb0" + integrity sha1-WrrPd3wyFmpR0IXWtPPn0nET3bA= + dependencies: + iconv-lite "0.4.24" + +whatwg-fetch@^3.4.0: + version "3.6.2" + resolved "https://registry.npm.taobao.org/whatwg-fetch/download/whatwg-fetch-3.6.2.tgz?cache=0&sync_timestamp=1614452314097&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fwhatwg-fetch%2Fdownload%2Fwhatwg-fetch-3.6.2.tgz#dced24f37f2624ed0281725d51d0e2e3fe677f8c" + integrity sha1-3O0k838mJO0CgXJdUdDi4/5nf4w= + +whatwg-mimetype@^2.2.0, whatwg-mimetype@^2.3.0: + version "2.3.0" + resolved "https://registry.nlark.com/whatwg-mimetype/download/whatwg-mimetype-2.3.0.tgz?cache=0&sync_timestamp=1631993439192&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fwhatwg-mimetype%2Fdownload%2Fwhatwg-mimetype-2.3.0.tgz#3d4b1e0312d2079879f826aff18dbeeca5960fbf" + integrity sha1-PUseAxLSB5h5+Cav8Y2+7KWWD78= + +whatwg-url@^7.0.0: + version "7.1.0" + resolved "https://registry.npmmirror.com/whatwg-url/download/whatwg-url-7.1.0.tgz?cache=0&sync_timestamp=1634673646149&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fwhatwg-url%2Fdownload%2Fwhatwg-url-7.1.0.tgz#c2c492f1eca612988efd3d2266be1b9fc6170d06" + integrity sha1-wsSS8eymEpiO/T0iZr4bn8YXDQY= + dependencies: + lodash.sortby "^4.7.0" + tr46 "^1.0.1" + webidl-conversions "^4.0.2" + +when@~3.6.x: + version "3.6.4" + resolved "https://registry.npm.taobao.org/when/download/when-3.6.4.tgz#473b517ec159e2b85005497a13983f095412e34e" + integrity sha1-RztRfsFZ4rhQBUl6E5g/CVQS404= + +which-boxed-primitive@^1.0.2: + version "1.0.2" + resolved "https://registry.nlark.com/which-boxed-primitive/download/which-boxed-primitive-1.0.2.tgz#13757bc89b209b049fe5d86430e21cf40a89a8e6" + integrity sha1-E3V7yJsgmwSf5dhkMOIc9AqJqOY= + dependencies: + is-bigint "^1.0.1" + is-boolean-object "^1.1.0" + is-number-object "^1.0.4" + is-string "^1.0.5" + is-symbol "^1.0.3" + +which-module@^2.0.0: + version "2.0.0" + resolved "https://registry.npm.taobao.org/which-module/download/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a" + integrity sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho= + +which@1, which@^1.2.9: + version "1.3.1" + resolved "https://registry.nlark.com/which/download/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" + integrity sha1-pFBD1U9YBTFtqNYvn1CRjT2nCwo= + dependencies: + isexe "^2.0.0" + +which@^2.0.1: + version "2.0.2" + resolved "https://registry.nlark.com/which/download/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" + integrity sha1-fGqN0KY2oDJ+ELWckobu6T8/UbE= + dependencies: + isexe "^2.0.0" + +wide-align@^1.1.0: + version "1.1.5" + resolved "https://registry.npmmirror.com/wide-align/download/wide-align-1.1.5.tgz#df1d4c206854369ecf3c9a4898f1b23fbd9d15d3" + integrity sha1-3x1MIGhUNp7PPJpImPGyP72dFdM= + dependencies: + string-width "^1.0.2 || 2 || 3 || 4" + +word-wrap@~1.2.3: + version "1.2.3" + resolved "https://registry.nlark.com/word-wrap/download/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" + integrity sha1-YQY29rH3A4kb00dxzLF/uTtHB5w= + +worker-farm@^1.7.0: + version "1.7.0" + resolved "https://registry.nlark.com/worker-farm/download/worker-farm-1.7.0.tgz#26a94c5391bbca926152002f69b84a4bf772e5a8" + integrity sha1-JqlMU5G7ypJhUgAvabhKS/dy5ag= + dependencies: + errno "~0.1.7" + +worker-loader@^3.0.8: + version "3.0.8" + resolved "https://registry.npm.taobao.org/worker-loader/download/worker-loader-3.0.8.tgz#5fc5cda4a3d3163d9c274a4e3a811ce8b60dbb37" + integrity sha1-X8XNpKPTFj2cJ0pOOoEc6LYNuzc= + dependencies: + loader-utils "^2.0.0" + schema-utils "^3.0.0" + +wrap-ansi@^5.1.0: + version "5.1.0" + resolved "https://registry.nlark.com/wrap-ansi/download/wrap-ansi-5.1.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fwrap-ansi%2Fdownload%2Fwrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09" + integrity sha1-H9H2cjXVttD+54EFYAG/tpTAOwk= + dependencies: + ansi-styles "^3.2.0" + string-width "^3.0.0" + strip-ansi "^5.0.0" + +wrappy@1: + version "1.0.2" + resolved "https://registry.nlark.com/wrappy/download/wrappy-1.0.2.tgz?cache=0&sync_timestamp=1619133505879&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fwrappy%2Fdownload%2Fwrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" + integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= + +write@1.0.3: + version "1.0.3" + resolved "https://registry.nlark.com/write/download/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3" + integrity sha1-CADhRSO5I6OH5BUSPIZWFqrg9cM= + dependencies: + mkdirp "^0.5.1" + +write@^0.2.1: + version "0.2.1" + resolved "https://registry.nlark.com/write/download/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" + integrity sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c= + dependencies: + mkdirp "^0.5.1" + +ws@^6.2.1: + version "6.2.2" + resolved "https://registry.npmmirror.com/ws/download/ws-6.2.2.tgz?cache=0&sync_timestamp=1633200039582&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fws%2Fdownload%2Fws-6.2.2.tgz#dd5cdbd57a9979916097652d78f1cc5faea0c32e" + integrity sha1-3Vzb1XqZeZFgl2UtePHMX66gwy4= + dependencies: + async-limiter "~1.0.0" + +ws@^7.0.0, ws@^7.3.1: + version "7.5.5" + resolved "https://registry.npmmirror.com/ws/download/ws-7.5.5.tgz?cache=0&sync_timestamp=1633200039582&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fws%2Fdownload%2Fws-7.5.5.tgz#8b4bc4af518cfabd0473ae4f99144287b33eb881" + integrity sha1-i0vEr1GM+r0Ec65PmRRCh7M+uIE= + +x-is-string@^0.1.0: + version "0.1.0" + resolved "https://registry.npm.taobao.org/x-is-string/download/x-is-string-0.1.0.tgz#474b50865af3a49a9c4657f05acd145458f77d82" + integrity sha1-R0tQhlrzpJqcRlfwWs0UVFj3fYI= + +xml-name-validator@^3.0.0: + version "3.0.0" + resolved "https://registry.nlark.com/xml-name-validator/download/xml-name-validator-3.0.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fxml-name-validator%2Fdownload%2Fxml-name-validator-3.0.0.tgz#6ae73e06de4d8c6e47f9fb181f78d648ad457c6a" + integrity sha1-auc+Bt5NjG5H+fsYH3jWSK1FfGo= + +xmlchars@^2.1.1: + version "2.2.0" + resolved "https://registry.npm.taobao.org/xmlchars/download/xmlchars-2.2.0.tgz#060fe1bcb7f9c76fe2a17db86a9bc3ab894210cb" + integrity sha1-Bg/hvLf5x2/ioX24apvDq4lCEMs= + +xtend@^4.0.0, xtend@^4.0.1, xtend@~4.0.1: + version "4.0.2" + resolved "https://registry.nlark.com/xtend/download/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" + integrity sha1-u3J3n1+kZRhrH0OPZ0+jR/2121Q= + +xxhashjs@^0.2.1: + version "0.2.2" + resolved "https://registry.npm.taobao.org/xxhashjs/download/xxhashjs-0.2.2.tgz#8a6251567621a1c46a5ae204da0249c7f8caa9d8" + integrity sha1-imJRVnYhocRqWuIE2gJJx/jKqdg= + dependencies: + cuint "^0.2.2" + +y18n@^4.0.0: + version "4.0.3" + resolved "https://registry.npm.taobao.org/y18n/download/y18n-4.0.3.tgz?cache=0&sync_timestamp=1617822684820&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fy18n%2Fdownload%2Fy18n-4.0.3.tgz#b5f259c82cd6e336921efd7bfd8bf560de9eeedf" + integrity sha1-tfJZyCzW4zaSHv17/Yv1YN6e7t8= + +yallist@^2.1.2: + version "2.1.2" + resolved "https://registry.npm.taobao.org/yallist/download/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" + integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= + +yallist@^3.0.2: + version "3.1.1" + resolved "https://registry.npm.taobao.org/yallist/download/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" + integrity sha1-27fa+b/YusmrRev2ArjLrQ1dCP0= + +yallist@^4.0.0: + version "4.0.0" + resolved "https://registry.npm.taobao.org/yallist/download/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" + integrity sha1-m7knkNnA7/7GO+c1GeEaNQGaOnI= + +yaml@^1.10.0: + version "1.10.2" + resolved "https://registry.nlark.com/yaml/download/yaml-1.10.2.tgz?cache=0&sync_timestamp=1630949706790&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fyaml%2Fdownload%2Fyaml-1.10.2.tgz#2301c5ffbf12b467de8da2333a459e29e7920e4b" + integrity sha1-IwHF/78StGfejaIzOkWeKeeSDks= + +yargs-parser@^10.0.0: + version "10.1.0" + resolved "https://registry.nlark.com/yargs-parser/download/yargs-parser-10.1.0.tgz#7202265b89f7e9e9f2e5765e0fe735a905edbaa8" + integrity sha1-cgImW4n36eny5XZeD+c1qQXtuqg= + dependencies: + camelcase "^4.1.0" + +yargs-parser@^13.1.2: + version "13.1.2" + resolved "https://registry.nlark.com/yargs-parser/download/yargs-parser-13.1.2.tgz#130f09702ebaeef2650d54ce6e3e5706f7a4fb38" + integrity sha1-Ew8JcC667vJlDVTObj5XBvek+zg= + dependencies: + camelcase "^5.0.0" + decamelize "^1.2.0" + +yargs@^13.3.2: + version "13.3.2" + resolved "https://registry.npmmirror.com/yargs/download/yargs-13.3.2.tgz?cache=0&sync_timestamp=1632605487521&other_urls=https%3A%2F%2Fregistry.npmmirror.com%2Fyargs%2Fdownload%2Fyargs-13.3.2.tgz#ad7ffefec1aa59565ac915f82dccb38a9c31a2dd" + integrity sha1-rX/+/sGqWVZayRX4Lcyzipwxot0= + dependencies: + cliui "^5.0.0" + find-up "^3.0.0" + get-caller-file "^2.0.1" + require-directory "^2.1.1" + require-main-filename "^2.0.0" + set-blocking "^2.0.0" + string-width "^3.0.0" + which-module "^2.0.0" + y18n "^4.0.0" + yargs-parser "^13.1.2" + +yauzl@2.10.0: + version "2.10.0" + resolved "https://registry.npm.taobao.org/yauzl/download/yauzl-2.10.0.tgz#c7eb17c93e112cb1086fa6d8e51fb0667b79a5f9" + integrity sha1-x+sXyT4RLLEIb6bY5R+wZnt5pfk= + dependencies: + buffer-crc32 "~0.2.3" + fd-slicer "~1.1.0" + +yocto-queue@^0.1.0: + version "0.1.0" + resolved "https://registry.nlark.com/yocto-queue/download/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" + integrity sha1-ApTrPe4FAo0x7hpfosVWpqrxChs= diff --git a/cloudos_deploy/Dockerfile b/cloudos_deploy/Dockerfile deleted file mode 100644 index 011abd2ff9..0000000000 --- a/cloudos_deploy/Dockerfile +++ /dev/null @@ -1,12 +0,0 @@ -FROM nginx:1.17.9-alpine - -COPY ./html /var/www/pageplug - -EXPOSE 80 - -COPY ./templates/nginx-app.conf.template /nginx.conf.template -COPY ./templates/nginx-root.conf.template /nginx-root.conf.template - -# This is the script that is used to start Nginx when the Docker container starts -COPY ./start-nginx.sh /start-nginx.sh -CMD ["/start-nginx.sh"] diff --git a/cloudos_deploy/html/favicon.ico b/cloudos_deploy/html/favicon.ico deleted file mode 100644 index 09995ddacf279abe102c2138467c6825e27f55d8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23462 zcmeI4O-vkR7{`aAqV@w#wANGw+s0O5mnw&9(nw<(P1&8Q2jW4~=%oiQc;m==ve86^ zva`_LrP`Pt)`KS1gVqR1i6Wh~(iFA9+Kuck^h^6?3oS7IpLb@KVY=+j?9LZOn%VjD z&il^$JimQEpBc(=75EnjaQLj{K7O6!R&yM;2?vrm0SBeiPx>{ETkn?-mf*1uDHOUR z8x`Kj#Drt%Sh)L4udvQzCc18p*wb@oIv(ByMkjGdnqwvt7Y>16qw7YxY`{n&aThVl z#)LmKe6*}oJxk2e@$TnbHres&Ck}kDJR1wQW}-s62qTr1_B@b@g?Yz~cDTZ`;qVG# zgm#oIfsvLM>0{I;r9`6AVK;28?!srCtKeH3jtdqr(la~3m|(u80ndvrZzj4`0yT^-Lmxd6OqVju-Sv-Uk4b?XBHRE(D!qC|3~*(>XgMd%f`BD zGVyQ+#_Vg3Gn&8FAbyv~mb3fAYb14>Hm-n_{-cg^gvpZL0WKRPZZ|rWXMtJu^r40-0FkX{?PB;4`}j z8R?lx7*`Kly%)&F!&_;Oaa-`Ybq*kgY%d^5QiZ7wrpe40#UkI`#*FlB&GcR%(<^L8 zUmILPjP%S#5!={J@efVY$w|bHmeHORe8eTpNY5;#-wULp!n0U|{PsVid9kw`w`^Q^ zM{QK3J;rGUW57kP*yKf4j1Sh>6gwX6?5tvOz-Z*S+sr)0DjG@BScv28iS8NuG_tl3mqORh#p5ff9Xd51 zxxi`wd&m}gu2qPGnQLsFgLbLxDQw$!ImGI6Ixh5#?ceJ&!=RMB;I&bS3t1jtw3*ci z*0pa_Un#}!a>}r{bxg=uIiA_TYKHdhwDvD&4_XcW73ZlALj zugNT6CDL5v#pfm&tk+!cgY20@IG*k8ddBUxQ>cEdORS2KT&MVNdSBNQYJJqk3VjdA ze+t*zXxvoGc=-%lj}-E!=rwwG0ME_FdpjT0`?&xsHdeDW(IR^ej&{{ol*g^{QA7Uf zSY4tu(Rgq7Q+lS0<#)`*-x_A6%uV#%&WL}E72;PE*P?e=jFjV3i z?PLv3Uo5~1&!UAcdah|_{fp_|*?8phd937^Z=2WOad3liCLTEmR;FVe7mOV$UT6#c;t99Kkt;NU{}mTLOwh8dhlsg*u z#8PFV_gk#rvHqw(_&(U2%kj~&@&~@ums!le_tkE@+l>7Z7g~1I7uYVM&4ABzenv{$ z^6_7pxwjYdj?}f>rRg)RMr<6c-}w;Av|$W7U67BqUHO9F7`e9>^N5WvJuLeh98>*G z`UAOVsrhV9`T~td8~7gNzpj=se&)Z=cTX>;k-r#s4~TyLhThM7tOhpjT!}Kfk#|_1 z-{kK{yv#+lZO&i*cp?9^tS}C(1EX%_$9%7u&q~((plXj7&$PZtHU#&IzThPz{%To~ zHd4k!9?@%za&wbEcnE&Xn(#%knbojYSPlDMU2S@9()A~sS^erZE6v<=%}g80m)B-i z>A@{KRyoa!){IGC@GbZ&=JUDKG@Dt`e&;f+IcOZUo7pc7!L`^&giz-K`-t-9D+gGq z`@BV2Iy}ruW#*Oh zpNQFQRmTX#wN`*>D~|L+Y?omADK_6WHs<|16N&|5O}7hNXm0n)_v*AACx}7cwrz&q zYo$Fo%|GCkTtdu-i4o1cYJW3xrnRxc?8n=c8TkA_K3ch_pz#g7DE8xYpRlREzyL8a z({{|}9opQy8Fe5oUF2DgXPFWs{spssmy>^}fv;1T*}8AFs2$UqAAO>EOF2H5TlU!I zS88DgJ)18(re+ZrZJ%X(D2n@)>!+3FDOQVd5-}vUFV@=YhMu8kzD~r>%3(+`6J;-V z-iCHkggbwO#)Y36nse_Bm*b05WrzJQE(a^x3*?^P+Q@E-Vz5K?FF)#(e|FTP*$ez` z11pMUbx;i14%^+jr)Do;#dCwp#E4=yZu#R>y%gJ{^>PXA>^#jM$9;kOowC&{^=S42 z#bTak*&K`aE4^a7TXq!K3rw&%wTx#OZuw+)y~(Y0aDW+$+>YSeBDsviF+toZFj;m4hEKIFZ^dxkJqLG~n;Do!Au3?(8Q-KuH zDLWM)je~yLQ_vw&99NyBN$B3br-LntXYeB+_f3-%~W%)F - - - - - - - Methodot - - - - - - - - - diff --git a/cloudos_deploy/start-nginx.sh b/cloudos_deploy/start-nginx.sh deleted file mode 100644 index b529e69297..0000000000 --- a/cloudos_deploy/start-nginx.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh -# This script is used to boot Nginx when the Docker container starts -set -ue -cat /nginx.conf.template | envsubst "$(printf '$%s,' $(env | grep -Eo '^PAGEPLUG_[A-Z0-9_]+'))" | sed -e 's|\${\(PAGEPLUG_[A-Z0-9_]*\)}||g' > /etc/nginx/conf.d/default.conf -cat /nginx-root.conf.template | envsubst "$(printf '$%s,' $(env | grep -Eo '^PAGEPLUG_[A-Z0-9_]+'))" | sed -e 's|\${\(PAGEPLUG_[A-Z0-9_]*\)}||g' > /etc/nginx/nginx.conf -exec nginx -g 'daemon off;' diff --git a/cloudos_deploy/templates/nginx-app.conf.template b/cloudos_deploy/templates/nginx-app.conf.template deleted file mode 100644 index 3fd7bc4c45..0000000000 --- a/cloudos_deploy/templates/nginx-app.conf.template +++ /dev/null @@ -1,22 +0,0 @@ - -server { - listen 80; - - client_max_body_size 100m; - gzip on; - proxy_set_header X-Forwarded-Proto $scheme; - proxy_set_header X-Forwarded-Host $host; - - root /var/www/pageplug; - index index.html index.htm; - - location / { - try_files $uri /index.html =404; - - sub_filter __PAGEPLUG_APP_URL__ '${PAGEPLUG_APP_URL}'; - } - - location /favicon.ico { - try_files $uri /favicon.ico =404; - } -} diff --git a/cloudos_deploy/templates/nginx-root.conf.template b/cloudos_deploy/templates/nginx-root.conf.template deleted file mode 100644 index 23637571ee..0000000000 --- a/cloudos_deploy/templates/nginx-root.conf.template +++ /dev/null @@ -1,41 +0,0 @@ -user nginx; -worker_processes 1; - -error_log /var/log/nginx/error.log warn; -pid /var/run/nginx.pid; - -events { - worker_connections 1024; -} - - -http { - include /etc/nginx/mime.types; - default_type application/octet-stream; - - log_format main '"$time_local" client=$remote_addr ' - 'method=$request_method request="$request" ' - 'request_length=$request_length ' - 'status=$status bytes_sent=$bytes_sent ' - 'body_bytes_sent=$body_bytes_sent ' - 'referer=$http_referer ' - 'http_x_forwarded_for=$http_x_forwarded_for ' - 'user_agent="$http_user_agent" ' - 'upstream_addr=$upstream_addr ' - 'upstream_status=$upstream_status ' - 'request_time=$request_time ' - 'upstream_response_time=$upstream_response_time ' - 'upstream_connect_time=$upstream_connect_time ' - 'upstream_header_time=$upstream_header_time'; - - access_log /var/log/nginx/access.log main; - - sendfile on; - #tcp_nopush on; - - keepalive_timeout 65; - - #gzip on; - - include /etc/nginx/conf.d/*.conf; -}