diff --git a/.github/.codecov.yml b/.github/.codecov.yml
index 1ce321b650d3..ba7dd34e7473 100644
--- a/.github/.codecov.yml
+++ b/.github/.codecov.yml
@@ -1,7 +1,11 @@
# https://docs.codecov.com/docs/codecov-yaml
+codecov:
+ require_ci_to_pass: yes
+
coverage:
status:
project:
default:
- # https://docs.codecov.com/docs/commit-status#target
- target: auto # coverage must be equal or above the previous commit
+ target: auto
+ threshold: 2% # the leniency in hitting the target
+
diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md
index 9bd61e660b6c..2a9e814b5fe3 100644
--- a/.github/pull_request_template.md
+++ b/.github/pull_request_template.md
@@ -4,8 +4,20 @@
### Issues Resolved
-
-
+
+
+
+## Screenshot
+
+
+
+## Testing the changes
+
+
### Check List
diff --git a/.github/workflows/build_and_test_workflow.yml b/.github/workflows/build_and_test_workflow.yml
index fd4cdbbefa78..8fd3a402d547 100644
--- a/.github/workflows/build_and_test_workflow.yml
+++ b/.github/workflows/build_and_test_workflow.yml
@@ -25,11 +25,13 @@ env:
TEST_OPENSEARCH_TRANSPORT_PORT: 9403
TEST_OPENSEARCH_PORT: 9400
OSD_SNAPSHOT_SKIP_VERIFY_CHECKSUM: true
+ NODE_OPTIONS: "--max-old-space-size=6144 --dns-result-order=ipv4first"
jobs:
build-lint-test:
name: Build and Verify on ${{ matrix.name }}
strategy:
+ fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
include:
@@ -122,6 +124,7 @@ jobs:
functional-tests:
name: Run functional tests on ${{ matrix.name }} (ciGroup${{ matrix.group }})
strategy:
+ fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
group: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]
@@ -384,6 +387,7 @@ jobs:
with:
name: ${{ matrix.version }}-test-failures
path: |
- ./artifacts/bwc_tmp/test/cypress/videos/without-security/*
- ./artifacts/bwc_tmp/test/cypress/screenshots/without-security/*
+ ./artifacts/bwc_tmp/test/cypress/videos/*
+ ./artifacts/bwc_tmp/test/cypress/screenshots/*
+ ./artifacts/bwc_tmp/test/cypress/results/*
retention-days: 1
diff --git a/.i18nrc.json b/.i18nrc.json
index 234aa8de0c25..64ca6528aa5e 100644
--- a/.i18nrc.json
+++ b/.i18nrc.json
@@ -48,7 +48,7 @@
"src/plugins/telemetry_management_section"
],
"tileMap": "src/plugins/tile_map",
- "timeline": ["src/plugins/timeline", "src/plugins/vis_type_timeline"],
+ "timeline": ["src/plugins/vis_type_timeline"],
"uiActions": "src/plugins/ui_actions",
"visDefaultEditor": "src/plugins/vis_default_editor",
"visTypeMarkdown": "src/plugins/vis_type_markdown",
diff --git a/.lycheeexclude b/.lycheeexclude
index 07317835aabf..35ae861e8f91 100644
--- a/.lycheeexclude
+++ b/.lycheeexclude
@@ -88,6 +88,8 @@ https://opensearch.org/redirect
http://www.opensearch.org/painlessDocs
https://www.hostedgraphite.com/
https://connectionurl.com
+http://169.254.169.254/latest/meta-data/
+http://company.net/*
# External urls
https://www.zeek.org/
@@ -117,3 +119,5 @@ http://www.creedthoughts.gov
https://media-for-the-masses.theacademyofperformingartsandscience.org/
https://yarnpkg.com/latest.msi
https://forum.opensearch.org/
+https://facebook.github.io/jest/
+https://facebook.github.io/jest/docs/cli.html
diff --git a/.node-version b/.node-version
index f46d5e394243..6d80269a4f04 100644
--- a/.node-version
+++ b/.node-version
@@ -1 +1 @@
-14.21.3
+18.16.0
diff --git a/.nvmrc b/.nvmrc
index f46d5e394243..6d80269a4f04 100644
--- a/.nvmrc
+++ b/.nvmrc
@@ -1 +1 @@
-14.21.3
+18.16.0
diff --git a/CHANGELOG.md b/CHANGELOG.md
index fb7c3fd87322..3a7acdd0a965 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -14,7 +14,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Eliminate dependency on `got` versions older than 11.8.5 ([#2801](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2801))
- [Multi DataSource] Add explicit no spellcheck on password fields ([#2818](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2818))
- [CVE-2022-25912] Bumps simple-git from 3.4.0 to 3.15.0 ([#3036](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3036))
-- [CVE-2022-35256] Bumps node version from 14.20.0 to 14.20.1 [#3166](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3166))
+- [CVE-2022-35256] Bumps node version from 14.20.0 to 14.20.1 ([#3166](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3166))
- [CVE-2022-46175] Bumps json5 version from 1.0.1 and 2.2.1 to 1.0.2 and 2.2.3 ([#3201](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3201))
- [CVE-2022-25860] Bumps simple-git from 3.15.1 to 3.16.0 ([#3345](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3345))
- [Security] Bumps hapi/statehood to 7.0.4 ([#3411](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3411))
@@ -22,6 +22,9 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- [CVE-2023-25653] Bump node-jose to 2.2.0 ([#3445](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3445))
- [CVE-2023-26486][cve-2023-26487] Bump vega from 5.22.1 to 5.23.0 ([#3533](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3533))
- [CVE-2023-0842] Bump xml2js from 0.4.23 to 0.5.0 ([#3842](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3842))
+- [Multi DataSource] Add private IP blocking validation on server side ([#3912](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3912))
+- Bump `joi` to v14 to avoid the possibility of prototype poisoning in a nested dependency ([#3952](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3952))
+- [CVE-2023-2251] Bump yaml to 2.2.2 ([#3947](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3947))
### π Features/Enhancements
@@ -82,6 +85,9 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Add satisfaction survey link to help menu ([#3676] (https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3676))
- [Vis Builder] Add persistence to visualizations inner state ([#3751](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3751))
- [Table Visualization] Move format table, consolidate types and add unit tests ([#3397](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3397))
+- [Multiple Datasource] Support Amazon OpenSearch Serverless ([#3957](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3957))
+- Add support for Node.js >=14.20.1 <19 ([#4071](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4071))
+- Bundle Node.js 14 as a fallback for operating systems that cannot run Node.js 18 ([#4151](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4151))
### π Bug Fixes
@@ -131,6 +137,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- [Table Visualization] Fix table rendering empty unused space ([#3797](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3797))
- [Table Visualization] Fix data table not adjusting height on the initial load ([#3816](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3816))
- Cleanup unused url ([#3847](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3847))
+- [BUG] Docked navigation impacts visibility of bottom bar component ([#3978](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3978))
### π Infrastructure
@@ -145,6 +152,8 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Upgrade yarn version to be compatible with @openearch-project/opensearch ([#3443](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3443))
- [CI] Reduce redundancy by using matrix strategy on Windows and Linux workflows ([#3514](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3514))
- Add an achievement badger to the PR ([#3721](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3721))
+- Install chrome driver for functional tests from path set by environment variable `TEST_BROWSER_BINARY_PATH`([#3997](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3997))
+- Adds threshold to code coverage config to prevent workflow failures ([#4040](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4040))
### π Documentation
@@ -164,7 +173,9 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- [Doc] Update SECURITY.md with instructions for nested dependencies and backporting ([#3497](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3497))
- [Doc] [Console] Fix/update documentation links in Dev Tools console ([#3724](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3724))
- [Doc] Update DEVELOPER_GUIDE.md with added manual bootstrap timeout solution and max virtual memory error solution with docker ([#3764](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3764))
+- [Doc] Add COMMUNICATIONS.md with info about Slack, forum, office hours ([#3837](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3837))
- [Doc] Add docker files and instructions for debugging Selenium functional tests ([#3747](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3747))
+- [Saved Object Service] Adds design doc for new Saved Object Service Interface for Custom Repository [#3954](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3954)
### π Maintenance
@@ -181,7 +192,11 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Remove the unused `renovate.json5` file ([3489](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3489))
- Allow selecting the Node.js binary using `NODE_HOME` and `OSD_NODE_HOME` ([3508](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3508))
- Bump `styled-components` from 5.3.5 to 5.3.9 ([#3678](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3678))
+- Bump `js-yaml` from 3.14.0 to 4.1.0 ([#3770](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3770))
- Bump `oui` from `1.0.0` to `1.1.1` ([#3884](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3884))
+- Use `exec` in the CLI shell scripts to prevent new process creation ([#3955](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3955))
+- Adding @ZilongX and @Flyingliuhub as maintainers. ([#4137](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4137))
+- Remove timeline application ([#3971](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3971))
### πͺ Refactoring
@@ -191,7 +206,9 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- [Console] Replace jQuery.ajax with core.http when calling OSD APIs in console ([#3080](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3080))
- [I18n] Fix Listr type errors and error handlers ([#3629](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3629))
- [Multiple DataSource] Present the authentication type choices in a drop-down ([#3693](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3693))
-- [Console] Replace jQuery usage in console plugin with native methods ([#3733](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3733))
+- [Console] Remove unused ul element and its custom styling ([#3993](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3993))
+- Fix EUI/OUI type errors ([#3798](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3798))
+- Remove unused Sass in `tile_map` plugin ([#4110](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4110))
### π© Tests
@@ -238,6 +255,8 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- [Multi DataSource] UX enhancement on Data source management stack ([#2521](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2521))
- [Multi DataSource] UX enhancement on Update stored password modal for Data source management stack ([#2532](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2532))
- [Monaco editor] Add json worker support ([#3424](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3424))
+- Enhance grouping for context menus ([#3169](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3169))
+- Replace re2 with RegExp in timeline and add unit tests ([#3908](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3908))
### π Bug Fixes
@@ -249,6 +268,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- [Console] Fix dev tool console autocomplete not loading issue ([#3775](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3775))
- [Console] Fix dev tool console run command with query parameter error ([#3813](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3813))
- Add clarifying tooltips to header navigation ([#3573](https://github.com/opensearch-project/OpenSearch-Dashboards/issues/3573))
+- [Dashboards Listing] Fix listing limit to utilize `savedObjects:listingLimit` instead of `savedObjects:perPage` ([#4021](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4021))
### π Infrastructure
diff --git a/COMMUNICATIONS.md b/COMMUNICATIONS.md
new file mode 100644
index 000000000000..c1dbfc114ce7
--- /dev/null
+++ b/COMMUNICATIONS.md
@@ -0,0 +1,83 @@
+# OpenSearch Dashboards Communication
+
+- [Overview](#overview)
+- [Slack](#slack)
+- [Forum](#forum)
+- [Developer Office Hours](#developer-office-hours)
+ - [What it is](#what-it-is)
+ - [When](#when)
+ - [How to sign up](#how-to-sign-up)
+ - [FAQ](#faq)
+
+## Overview
+
+The purpose of this document is to provide information regarding the communication channels for OpenSearch Dashboards. All communication is subject to the [OpenSearch Code of Conduct](CODE_OF_CONDUCT.md). Please see [CONTRIBUTING](CONTRIBUTING.md) if you're interested in contributing to the project.
+
+## Slack
+
+The OpenSearch project has a public workspace on [Slack](https://opensearch.slack.com). See the [Getting Started guide]() for steps to register and setup the workspace.
+
+Once registered, check out these channels for discussion of OpenSearch Dashboards topics:
+
+- [#dashboards](https://opensearch.slack.com/archives/C01QENNTGUD)
+- [#dashboards-ux](https://opensearch.slack.com/archives/C05389T9LJC)
+
+## Forum
+
+Slack conversations are not searchable outside the workspace. For this reason we encourage using the [OpenSearch Dashboards category](https://forum.opensearch.org/c/opensearch-dashboards/57) of the forum for technical support discussions or summarizing findings for the rest of the community.
+
+## Developer Office Hours
+
+### What it is
+
+A recurring 1-hour virtual meeting for community developers to chat with [OpenSearch Dashboards project maintainers](MAINTAINERS.md). Priority will be given to topics that are signed-up in advance, but ad-hoc discussions are welcome in any remaining time.
+
+While we'll always prioritize asynchronous communication, sometimes a community call is the most effective and efficient venue to share information and knowledge. Some reasons to sign up:
+
+1. Review a proposal or technical design for a new feature in OpenSearch Dashboards or an OpenSearch Dashboards plugin
+2. Learn more about how to build and extend OpenSearch Dashboards - which APIs, plugins, resources, and services are available to speed development
+3. Discuss OpenSearch Dashboard roadmap and technical initiatives
+
+Signing up isn't required to attend - all OpenSearch Dashboards contributors or interested developers are welcome as participants.
+
+Bring your ideas and projects early, while you still have time and flexibility to make significant changes.
+
+### When
+
+Every other Thursday, 10AM-11AM PT.
+
+### How to sign up
+
+There will be a forum post for each iteration of the meeting, with pre-defined slots. To sign-up, simply reply in the forum thread with the following template:
+
+* Topic: [a brief description of what you'd like to discuss]
+* Requested by: [provide GitHub aliases of attendees]
+* GitHub issues or PRs: [before signing up, make sure to create an issue, whether in the OpenSearch Dashboards repository or your own plugin repository]
+* Time required [choose 15, 30, 45, or 60 minutes]
+* Requested maintainer: [optional; provide GitHub alias of any particular maintainer youβd like to attend]
+
+### FAQ
+
+#### Will the meetings be recorded?
+
+Yes, we plan to record each office hours session and post to our YouTube channel so the information can be more easily shared and referenced.
+
+#### Will all maintainers attend?
+
+Generally no, but there will always be at least one maintainer. We'll review the sign-ups ahead of time to make sure the right subject-matter experts will attend, depending on the topics.
+
+#### What happens if there are no sign-ups for a particular session?
+
+The session will still occur, and the maintainers will present a brief knowledge-sharing session or demo. We'll also hold ad-hoc discussions, but the session may end early.
+
+#### Is it first come first serve or do we get to decide which topics we discuss in a session?
+
+For sign-ups, itβs first-come first served, until we decide we need another method.
+
+#### Will there also be meeting notes? or is the recording the only available transcript?
+
+No. But weβll also post the chat transcript and any slides shared (see https://forum.opensearch.org/t/opensearch-community-meeting-2023-0131/11892/5 as example)
+
+#### How can I cancel or reschedule?
+
+Just leave another forum reply, as early as possible so other folks have the opportunity to sign-up for the same spot.
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 045b17019b7d..4a605d04c052 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -1,6 +1,7 @@
- [Contributing to OpenSearch](#contributing-to-opensearch-dashboards)
- [First Things First](#first-things-first)
- [Ways to Contribute](#ways-to-contribute)
+ - [Join the Discussion](#join-the-discussion)
- [Bug Reports](#bug-reports)
- [Feature Requests](#feature-requests)
- [Documentation Changes](#documentation-changes)
@@ -19,6 +20,11 @@ OpenSearch is a community project that is built and maintained by people just li
**Only submit your own work** (or work you have sufficient rights to submit) - Please make sure that any code or documentation you submit is your work or you have the rights to submit. We respect the intellectual property rights of others, and as part of contributing, we'll ask you to sign your contribution with a "Developer Certificate of Origin" (DCO) that states you have the rights to submit this work and you understand we'll use your contribution. There's more information about this topic in the [DCO section](#developer-certificate-of-origin).
## Ways to Contribute
+
+### Join the Discussion
+
+See the [communication guide](COMMUNICATION.md)for information on how to join our slack workspace, forum, or developer office hours.
+
### Bug Reports
A bug is when software behaves in a way that you didn't expect and the developer didn't intend. To help us understand what's going on, we first want to make sure you're working from the latest version. Please make sure you're testing against the [latest version](https://github.com/opensearch-project/OpenSearch-Dashboards).
diff --git a/DEVELOPER_GUIDE.md b/DEVELOPER_GUIDE.md
index d3c8b269c4c0..3df2106e9678 100644
--- a/DEVELOPER_GUIDE.md
+++ b/DEVELOPER_GUIDE.md
@@ -209,6 +209,10 @@ $ yarn start --run-examples
- [Project testing guidelines](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/TESTING.md)
- [Plugin conventions](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/CONVENTIONS.md#technical-conventions)
+#### Join the discussion
+
+See the [communication guide](COMMUNICATION.md)for information on how to join our slack workspace, forum, or developer office hours.
+
## Alternative development installations
Although the [getting started guide](#getting-started-guide) covers the recommended development environment setup, there are several alternatives worth being aware of.
diff --git a/Dockerfile b/Dockerfile
index 8f2742a6c1f2..9337b827810e 100755
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-ARG NODE_VERSION=14.20.1
+ARG NODE_VERSION=18.16.0
FROM node:${NODE_VERSION} AS base
ENV HOME '.'
diff --git a/MAINTAINERS.md b/MAINTAINERS.md
index ecb3f2928616..ae42e47b014b 100644
--- a/MAINTAINERS.md
+++ b/MAINTAINERS.md
@@ -17,6 +17,8 @@ This document contains a list of maintainers in this repo. See [opensearch-proje
| Kristen Tian | [kristenTian](https://github.com/kristenTian) | Amazon |
| Zhongnan Su | [zhongnansu](https://github.com/zhongnansu) | Amazon |
| Manasvini B Suryanarayana | [manasvinibs](https://github.com/manasvinibs) | Amazon |
+| Tao Liu | [Flyingliuhub](https://github.com/Flyingliuhub) | Amazon |
+| Zilong Xia | [ZilongX](https://github.com/ZilongX) | Amazon |
## Emeritus
diff --git a/README.md b/README.md
index d1b8fc9ed9dd..5c6c764f87f6 100644
--- a/README.md
+++ b/README.md
@@ -8,9 +8,13 @@
## Welcome
-OpenSearch Dashboards is an open source search and analytics visualization. We aim to be the best community-driven platform and provide all the contributors a great open source experience.
+OpenSearch Dashboards is an open-source data visualization tool designed to work with OpenSearch. OpenSearch Dashboards gives you data visualization tools to improve and automate business intelligence and support data-driven decision-making and strategic planning.
-Feel free to take a look at what the community has been up to, and then head over to the [Project Board](https://github.com/opensearch-project/OpenSearch-Dashboards/projects) to track release targets, or jump in and [start opening issues](https://github.com/opensearch-project/OpenSearch-Dashboards/issues/new/choose), [set up your development environment](DEVELOPER_GUIDE.md#getting-started), or [start contributing](CONTRIBUTING.md).
+We aim to be an exceptional community-driven platform and to foster open participation and collective contribution with all contributors. Stay up to date on what's happening with the OpenSearch Project by tracking GitHub [issues](https://github.com/opensearch-project/OpenSearch-Dashboards/issues) and [pull requests](https://github.com/opensearch-project/OpenSearch-Dashboards/pulls).
+
+You can [contribute to this project](https://github.com/opensearch-project/OpenSearch-Dashboards/issues/CONTRIBUTING.md) by [opening issues](https://github.com/opensearch-project/OpenSearch-Dashboards/issues/new/choose) to give feedback, share ideas, identify bugs, and contribute code.
+
+Set up your [OpenSearch Dashboards development environment](ttps://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/DEVELOPER_GUIDE.md#getting-started-guide) today! The project team looks forward to your contributions.
## Code Summary
@@ -23,7 +27,7 @@ Feel free to take a look at what the community has been up to, and then head ove
* [Project Website](https://opensearch.org/)
* [Downloads](https://opensearch.org/downloads.html)
* [Documentation](https://opensearch.org/docs/)
-* Need help? Try [Forums](https://discuss.opendistrocommunity.dev/)
+* Need help? See the [communication guide](COMMUNICATION.md) for various options
* [Project Principles](https://opensearch.org/#principles)
* [Developer Guide](DEVELOPER_GUIDE.md)
* [Contributing to OpenSearch](CONTRIBUTING.md)
diff --git a/config/opensearch_dashboards.yml b/config/opensearch_dashboards.yml
index f6f1486e5499..a28a2301dcf6 100644
--- a/config/opensearch_dashboards.yml
+++ b/config/opensearch_dashboards.yml
@@ -229,8 +229,7 @@
# functionality in Visualization.
# vis_builder.enabled: false
-# Set the value of this setting to true to enable the experimental multiple data source
-# support feature. Use with caution.
+# Set the value of this setting to true to enable multiple data source feature.
#data_source.enabled: false
# Set the value of these settings to customize crypto materials to encryption saved credentials
# in data sources.
@@ -238,6 +237,31 @@
#data_source.encryption.wrappingKeyNamespace: 'changeme'
#data_source.encryption.wrappingKey: [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]
+#data_source.endpointDeniedIPs: [
+# '127.0.0.0/8',
+# '::1/128',
+# '169.254.0.0/16',
+# 'fe80::/10',
+# '10.0.0.0/8',
+# '172.16.0.0/12',
+# '192.168.0.0/16',
+# 'fc00::/7',
+# '0.0.0.0/8',
+# '100.64.0.0/10',
+# '192.0.0.0/24',
+# '192.0.2.0/24',
+# '198.18.0.0/15',
+# '192.88.99.0/24',
+# '198.51.100.0/24',
+# '203.0.113.0/24',
+# '224.0.0.0/4',
+# '240.0.0.0/4',
+# '255.255.255.255/32',
+# '::/128',
+# '2001:db8::/32',
+# 'ff00::/8',
+# ]
+
# Set the value of this setting to false to hide the help menu link to the OpenSearch Dashboards user survey
# opensearchDashboards.survey.url: "https://survey.opensearch.org"
diff --git a/cypress/integration/with-security/check_advanced_settings.js b/cypress/integration/with-security/check_advanced_settings.js
index 502ee150a33f..9ca41207724e 100644
--- a/cypress/integration/with-security/check_advanced_settings.js
+++ b/cypress/integration/with-security/check_advanced_settings.js
@@ -25,13 +25,6 @@ describe('verify the advanced settings are saved', () => {
.should('eq', 'true');
});
- it('the Timeline default columns field is set to 4', () => {
- cy.get('[data-test-subj="advancedSetting-editField-timeline:default_columns"]').should(
- 'have.value',
- 4
- );
- });
-
it('the Timeline Maximum buckets field is set to 4', () => {
cy.get('[data-test-subj="advancedSetting-editField-timeline:max_buckets"]').should(
'have.value',
diff --git a/cypress/integration/with-security/helpers/generate_data.js b/cypress/integration/with-security/helpers/generate_data.js
index 1509dca7b012..4833a81a1398 100755
--- a/cypress/integration/with-security/helpers/generate_data.js
+++ b/cypress/integration/with-security/helpers/generate_data.js
@@ -31,9 +31,6 @@ describe('Generating BWC test data with security', () => {
it('adds advanced settings', () => {
miscUtils.visitPage('app/management/opensearch-dashboards/settings');
cy.get('[data-test-subj="advancedSetting-editField-theme:darkMode"]').click();
- cy.get('[data-test-subj="advancedSetting-editField-timeline:default_columns"]').type(
- '{selectAll}4'
- );
cy.get('[data-test-subj="advancedSetting-editField-timeline:max_buckets"]').type(
'{selectAll}4'
);
diff --git a/cypress/integration/without-security/check_advanced_settings.js b/cypress/integration/without-security/check_advanced_settings.js
index 474a8178441a..9268d86a16e5 100644
--- a/cypress/integration/without-security/check_advanced_settings.js
+++ b/cypress/integration/without-security/check_advanced_settings.js
@@ -18,13 +18,6 @@ describe('verify the advanced settings are saved', () => {
.should('eq', 'true');
});
- it('the Timeline default columns field is set to 4', () => {
- cy.get('[data-test-subj="advancedSetting-editField-timeline:default_columns"]').should(
- 'have.value',
- 4
- );
- });
-
it('the Timeline Maximum buckets field is set to 4', () => {
cy.get('[data-test-subj="advancedSetting-editField-timeline:max_buckets"]').should(
'have.value',
diff --git a/cypress/integration/without-security/helpers/generate_data.js b/cypress/integration/without-security/helpers/generate_data.js
index f792a9b304a1..4f2962769c16 100755
--- a/cypress/integration/without-security/helpers/generate_data.js
+++ b/cypress/integration/without-security/helpers/generate_data.js
@@ -14,9 +14,6 @@ describe('Generating BWC test data without security', () => {
it('adds advanced settings', () => {
miscUtils.visitPage('app/management/opensearch-dashboards/settings');
cy.get('[data-test-subj="advancedSetting-editField-theme:darkMode"]').click();
- cy.get('[data-test-subj="advancedSetting-editField-timeline:default_columns"]').type(
- '{selectAll}4'
- );
cy.get('[data-test-subj="advancedSetting-editField-timeline:max_buckets"]').type(
'{selectAll}4'
);
diff --git a/docs/saved_objects/img/current_saved_object_service_workflow.png b/docs/saved_objects/img/current_saved_object_service_workflow.png
new file mode 100644
index 000000000000..b763101b6987
Binary files /dev/null and b/docs/saved_objects/img/current_saved_object_service_workflow.png differ
diff --git a/docs/saved_objects/img/proposed_saved_object_service_workflow.png b/docs/saved_objects/img/proposed_saved_object_service_workflow.png
new file mode 100644
index 000000000000..117fd0217d51
Binary files /dev/null and b/docs/saved_objects/img/proposed_saved_object_service_workflow.png differ
diff --git a/docs/saved_objects/resources/current_saved_object_service_workflow.puml b/docs/saved_objects/resources/current_saved_object_service_workflow.puml
new file mode 100644
index 000000000000..bc5bbf82c621
--- /dev/null
+++ b/docs/saved_objects/resources/current_saved_object_service_workflow.puml
@@ -0,0 +1,19 @@
+@startuml
+title: Current Saved Object Service Flow
+actor User
+participant "Saved Object Client" as Client
+participant "Saved Object Repository" as Repo
+participant "Opensearch" as OS
+
+User -> Client: Create Saved Object
+Client -> Repo: Create Saved Object
+Repo -> OS: Index Saved Object
+OS --> Repo: Saved Object Saved
+Client -> User: Saved Object Created
+User -> Client: Get Saved Object
+Client -> Repo: Get Saved Object
+Repo -> OS: Get Saved Object
+OS --> Repo: Return Saved Object
+Repo -> Client: Return Saved Object
+Client -> User: Saved Object Data
+@enduml
\ No newline at end of file
diff --git a/docs/saved_objects/resources/proposed_saved_object_service_workflow.puml b/docs/saved_objects/resources/proposed_saved_object_service_workflow.puml
new file mode 100644
index 000000000000..27a5e1cd49ed
--- /dev/null
+++ b/docs/saved_objects/resources/proposed_saved_object_service_workflow.puml
@@ -0,0 +1,38 @@
+@startuml
+
+title: Proposed Saved Object Service Flow
+
+actor User
+
+participant "OpenSearch-Dashboards" as OSD
+
+box "Saved Object Service" #LightBlue
+participant "Saved Object Client" as Client
+participant "Repository Factory Provider" as Factory
+end box
+
+box "Dashboards Storage Plugin" #LightYellow
+participant "Repository\n(e.g. PostgresRepository,\nDynamoDBRepository)" as Repo
+participant "Metadata Storage\n(e.g. Postgres, \nDynamoDB etc)" as Meta
+end box
+
+autonumber
+group OSD Bootstrap
+Repo -> Factory: Register custom repository
+Factory -> Client: Returns repository
+Client -> OSD: Returns Saved Object Client
+end group
+User -> Client: Create Saved Object
+Client -> Repo: Create Saved Object
+Repo -> Meta: Create/Update Record
+Meta --> Repo: Saved Object Saved
+Client -> User: Saved Object Created
+User -> Client: Get Saved Object
+Client -> Repo: Get Saved Object
+Repo -> Meta: Fetch Saved Object from storage
+Meta --> Repo: Return Saved Object
+Repo -> Client: Return Saved Object
+Client -> User: Saved Object Data
+
+skinparam BoxPadding 15
+@enduml
\ No newline at end of file
diff --git a/docs/saved_objects/saved_object_repository_factory_design.md b/docs/saved_objects/saved_object_repository_factory_design.md
new file mode 100644
index 000000000000..d3fedd3575dc
--- /dev/null
+++ b/docs/saved_objects/saved_object_repository_factory_design.md
@@ -0,0 +1,171 @@
+# Proposed Saved Object Service Interface for Custom Repository
+
+## Introduction
+
+The new saved object service interface for custom repository is a project that aims to improve scalability of the existing saved object service by introducing a new interface. The goal of this project is to provide a more efficient and flexible interface that will make it easier for developers to configure metadata of Dashboards in any different storage than OpenSearch, such as mysql, postgres, DDB, serverless (S3+ Athena).
+
+Currently, Dashboards stores its metadata configuration inside OpenSearch index (called .kibana). This approach is by design of Dashboards and biased towards product decision by upstream which works seamlessly and out of the box for customers but it introduces challenges while operating at scale and providing high availability for Dashboards. While choosing OpenSearch as a storage for Dashboards metadata, availability of Dashboards depends on OpenSearch clusterβs availability and other cluster parameters such as cluster health, state, versions which could make Dashboards unavailable.
+
+To mitigate above problem and unblock future extensibility of Dashboards, we are building Dashboards Meta storage adaptor to decouple Dashboards metadata storage from OpenSearch. This project will focus on introducing new interface in Saved Object Service using which developer can build their custom repository and save Dashboards metadata in storage of their choice.
+
+The stakeholders of this new interface include the developers of the Dashboards and community contributors who wants to use other metadata store.
+
+## Architecture Overview
+
+The Saved Object Service is a critical component of Dashboards that provides a way to store and manage application data. It is built using a modular architecture that provides a high degree of flexibility and extensibility. The new interface will be designed to replace [ISavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L134) implementation so that developers can build plugins that leverage the power of existing saved object service and use their own database to store and retrieve metadata of OpenSearch Dashboards.
+
+### Current Architecture
+
+The repository interface named [ISavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L134) in OpenSearch-Dashboards is a module that provides an interface for managing saved objects. The [SavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L139) is the implementation of [ISavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L134), which uses OpenSearch index as itβs data store. It is responsible for storing, retrieving, and deleting saved objects for Dashboards, such as visualizations, dashboards, and searches.
+
+The Saved Object Repository is built on top of the OpenSearch client and provides a simplified interface for working with OpenSearch. It uses the Saved Object Serializer to convert saved objects between their internal and external representations. The repository is then being consumed by Saved object client to create scoped saved object client.
+
+![img](./img/current_saved_object_service_workflow.png)
+
+### Proposed Architecture
+
+- **Approach 1 (Preferred)**: The proposed architecture will add one more layer of abstraction in Saved Object Service. `The Repository Factory Provider` in OpenSearch Dashboards will be responsible for creating and managing instances of the Repository (e.g. SavedObjectRepository, PostgresRepository, DynamoDBRepository etc.), which is used to interact with the metadata storage that stores the saved objects. Currently we have an repository interface named [ISavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L134), and the [SavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L139) is the implementation, which use an OpenSearch index as its data store. This approach would make the implementation of [ISavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L134) replaceable by plugin.
+
+ ![img](./img/proposed_saved_object_service_workflow.png)
+
+ * Pros:
+ * Only change needed in Dashboard is to introduce one more abstraction layer in Saved Object Service.
+ * Adds opportunity for community developers to contribute for other meta store.
+
+ * Cons
+ * Code reusability is low.
+
+
+**POC**:
+1) Core Dashboards Change: https://github.com/bandinib-amzn/OpenSearch-Dashboards/commit/b9cfc14
+2) Postgres Repository Plugin: https://github.com/bandinib-amzn/metadata_plugin/commit/dac35f0
+
+`SavedObjectsServiceSetup` provides interface to create custom Saved Object Repository.
+```
+/**
+* Set the default {@link SavedObjectRepositoryFactoryProvider | factory provider} for creating Saved Objects repository.
+* Only one repository can be set, subsequent calls to this method will fail.
+*/
+registerRepositoryFactoryProvider: (
+respositoryFactoryProvider: SavedObjectRepositoryFactoryProvider
+) => void;
+```
+
+Here are the main steps involved in using the Saved Objects Repository Factory in Dashboards:
+1. Define the dependencies: The Saved Object Repository Factory Provider requires the function which creates instance of [ISavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L134).
+ ```
+ export const repositoryFactoryProvider: SavedObjectRepositoryFactoryProvider = (
+ options: SavedObjectsRepositoryOptions
+ ) => {
+ .
+ .
+ .
+ return new PostgresRepository({
+ typeRegistry,
+ serializer,
+ migrator,
+ allowedTypes,
+ });
+ }
+ ```
+2. Register the provider: Register the repository factory provider with right dependencies.
+ ```
+ core.savedObjects.registerRepositoryFactoryProvider(repositoryFactoryProvider);
+ ```
+3. Implement the Saved Object Operations for chosen storage type: Implement the CRUD and other operations for contracts defined in [ISavedObjectRepository](https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/core/server/saved_objects/service/lib/repository.ts#L134)
+ ```
+ async create(
+ type: string,
+ attributes: T,
+ options: SavedObjectsCreateOptions = {}
+ ): Promise> {
+ ...
+ }
+
+ async get(
+ type: string,
+ id: string,
+ options: SavedObjectsBaseOptions = {}
+ ): Promise> {
+ ...
+ }
+
+ async update(
+ type: string,
+ id: string,
+ attributes: Partial,
+ options: SavedObjectsUpdateOptions = {}
+ ): Promise> {
+ ...
+ }
+
+ async deleteFromNamespaces(
+ type: string,
+ id: string,
+ namespaces: string[],
+ options: SavedObjectsDeleteFromNamespacesOptions = {}
+ ): Promise {
+ ...
+ }
+ .
+ .
+ .
+ ```
+
+- **Approach 2**: Build external plugin and using saved object client wrapper or client factory provider injection mechanism we can build custom object for Postgres or other DB.
+
+ * Pros:
+ * No changes in core Dashboards. That means we can keep Dashboards as it is with very minimal changes.
+
+
+ * Cons
+ * Code reusability is low.
+ * Some components of Saved object service such as Serializer, Type registry, interface to create internal and scoped repository are only available during Saved Object Service Start. As per the current architecture, first Saved Object Service Setup β Plugin Setup β Saved Object Service Start β Plugin Start. Some core plugin (e.g. opensearch_dashboards_usage_collection) calls find operation before plugin start and it fails because some components are still not available before plugin start.
+
+
+ **POC**: https://github.com/bandinib-amzn/metadata_plugin/compare/f040daf...89213eb
+
+
+- **Approach 3**: In this approach, we just extend the `SavedObjectsRepository` class and override CRUD and other saved object operation in core Dashboards.
+
+ * Pros:
+ * As we are extending the repository in core saved object service itself, we can reuse the validation and utility functions for other database options.
+
+
+ * Cons
+ * Changes in core Dashboards : We will be making considerable changes in critical component of Dashboards.
+ * With this approach, user will have to use the data storage option that we choose.
+
+
+ **POC**: https://github.com/bandinib-amzn/OpenSearch-Dashboards/compare/main...22d7f30
+
+## Implementation Details
+
+
+| Repository | Component | Change |
+| ----------- | ----------- | ----------- |
+| OpenSearch-Dashboards | Saved Object Service | Add Saved object repository factory provider |
+| OpenSearch-Dashboards | Config | Configuration for metadata storage |
+| MetaStorage-Plugin [Name TBD] | Plugin / Extension | We will build new plugin for Postgres. This is use case for new interface in Saved Object Repository. |
+
+### Configuration for metadata storage:
+```
+metaStorage.enabled: true
+metaStorage.config: {
+ type: 'xxxx',
+ hostName: 'xxxx',
+ userName: 'xxxx',
+ password: 'xxxx',
+ port: xxxx,
+}
+```
+
+## Testing and Quality Assurance
+
+### Testing Approach
+
+The following testing approach will be used to ensure the quality of the system:
+
+1. **Unit testing**: Metadata store plugin will be thoroughly unit tested to ensure it meets its requirements and performs as expected. Also we will add new test cases in OpenSearch-Dashboards to test new repository factory provider.
+2. **Integration testing**: Components will be integrated and tested together to ensure they work together seamlessly and without conflicts.
+
diff --git a/examples/embeddable_examples/public/searchable_list_container/searchable_list_container_component.tsx b/examples/embeddable_examples/public/searchable_list_container/searchable_list_container_component.tsx
index c24d258fd7d8..7e742aba7cc7 100644
--- a/examples/embeddable_examples/public/searchable_list_container/searchable_list_container_component.tsx
+++ b/examples/embeddable_examples/public/searchable_list_container/searchable_list_container_component.tsx
@@ -82,7 +82,6 @@ export class SearchableListContainerComponentInner extends Component (checked[id] = false));
this.state = {
checked,
hasMatch,
diff --git a/examples/embeddable_explorer/public/list_container_example.tsx b/examples/embeddable_explorer/public/list_container_example.tsx
index 797b87513039..f466d120e218 100644
--- a/examples/embeddable_explorer/public/list_container_example.tsx
+++ b/examples/embeddable_explorer/public/list_container_example.tsx
@@ -164,6 +164,15 @@ export function ListContainerExample({
The first HelloWorldEmbeddable does not emit the hasMatch output variable, so the
container chooses to hide it.
+
+ Type some strings in the search bar, and press Check matching button. If the search
+ string matches with any strings from the title or the description of the children
+ embeddables, the child embeddable's check box will be checked. Noted that the
+ search filter is case sensitive. However, even if the search string matches with the
+ strings in the HelloWorldEmbeddable, its check box will not be checked because of the
+ reason explained above. If we click Delete checked, all the selected child embeddables
+ will be deleted from the container.
+
Check out the "Dynamically adding children" section, to see how to add
diff --git a/examples/ui_actions_explorer/public/context_menu_examples/context_menu_examples.tsx b/examples/ui_actions_explorer/public/context_menu_examples/context_menu_examples.tsx
index d38d80d0fac0..b01d04c1608b 100644
--- a/examples/ui_actions_explorer/public/context_menu_examples/context_menu_examples.tsx
+++ b/examples/ui_actions_explorer/public/context_menu_examples/context_menu_examples.tsx
@@ -44,6 +44,8 @@ export const ContextMenuExamples: React.FC = () => {
Below examples show how context menu panels look with varying number of actions and how the
actions can be grouped into different panels using grouping field.
+ Grouping can only be one layer deep. A group needs to have at least two items for grouping
+ to work. A separator is automatically added between groups.
diff --git a/package.json b/package.json
index b9eb244f7756..30e6756ca108 100644
--- a/package.json
+++ b/package.json
@@ -49,7 +49,7 @@
"test:jest:ci": "scripts/use_node scripts/jest --ci --colors --runInBand",
"test:jest:ci:coverage": "scripts/use_node scripts/jest --ci --colors --runInBand --coverage",
"test:jest_integration": "scripts/use_node scripts/jest_integration",
- "test:jest_integration:ci": "scripts/use_node scripts/jest_integration --ci --colors --max-old-space-size=5120",
+ "test:jest_integration:ci": "scripts/use_node scripts/jest_integration --ci --colors",
"test:mocha": "scripts/use_node scripts/mocha",
"test:mocha:coverage": "yarn nyc --reporter=text-summary --reporter=lcov --report-dir=./target/opensearch-dashboards-coverage/mocha scripts/use_node scripts/mocha",
"test:ftr": "scripts/use_node scripts/functional_tests",
@@ -81,7 +81,7 @@
"url": "https://github.com/opensearch-project/opensearch-dashboards.git"
},
"resolutions": {
- "**/@types/node": "^14.17.32",
+ "**/@types/node": "~18.7.0",
"**/ansi-regex": "^5.0.1",
"**/async": "^3.2.3",
"**/d3-color": "^3.1.0",
@@ -97,7 +97,9 @@
"**/unset-value": "^2.0.1",
"**/jest-config": "npm:@amoo-miki/jest-config@27.5.1",
"**/jest-jasmine2": "npm:@amoo-miki/jest-jasmine2@27.5.1",
- "**/xml2js": "^0.5.0"
+ "**/set-value": "^4.1.0",
+ "**/xml2js": "^0.5.0",
+ "**/yaml": "^2.2.2"
},
"workspaces": {
"packages": [
@@ -135,7 +137,7 @@
"@hapi/podium": "^4.1.3",
"@hapi/vision": "^6.1.0",
"@hapi/wreck": "^17.1.0",
- "@opensearch-project/opensearch": "^2.1.0",
+ "@opensearch-project/opensearch": "^2.2.0",
"@osd/ace": "1.0.0",
"@osd/analytics": "1.0.0",
"@osd/apm-config-loader": "1.0.0",
@@ -166,9 +168,9 @@
"deep-freeze-strict": "^1.1.1",
"del": "^6.1.1",
"dns-sync": "^0.2.1",
- "elastic-apm-node": "^3.7.0",
+ "elastic-apm-node": "^3.43.0",
"elasticsearch": "^16.7.0",
- "http-aws-es": "6.0.0",
+ "http-aws-es": "npm:@zhongnansu/http-aws-es@6.0.1",
"execa": "^4.0.2",
"expiry-js": "0.1.7",
"fast-deep-equal": "^3.1.1",
@@ -176,15 +178,15 @@
"getos": "^3.2.1",
"glob": "^7.1.7",
"glob-all": "^3.2.1",
- "globby": "^8.0.1",
+ "globby": "^11.1.0",
"handlebars": "4.7.7",
"hjson": "3.2.1",
"http-proxy-agent": "^2.1.0",
"https-proxy-agent": "^5.0.0",
"inline-style": "^2.0.0",
"ip-cidr": "^2.1.0",
- "joi": "^13.5.2",
- "js-yaml": "^3.14.0",
+ "joi": "^14.3.1",
+ "js-yaml": "^4.1.0",
"json-stable-stringify": "^1.0.1",
"json-stringify-safe": "5.0.1",
"lodash": "^4.17.21",
@@ -199,7 +201,6 @@
"pegjs": "0.10.0",
"proxy-from-env": "1.0.0",
"query-string": "^6.13.2",
- "re2": "1.17.4",
"react": "^16.14.0",
"react-dom": "^16.12.0",
"react-input-range": "^1.3.0",
@@ -211,6 +212,7 @@
"rison-node": "1.0.2",
"rxjs": "^6.5.5",
"semver": "^5.7.0",
+ "set-value": "^4.1.0",
"source-map-support": "^0.5.19",
"symbol-observable": "^1.2.0",
"tar": "^6.1.11",
@@ -288,7 +290,7 @@
"@types/jest": "^27.4.0",
"@types/joi": "^13.4.2",
"@types/jquery": "^3.3.31",
- "@types/js-yaml": "^3.11.1",
+ "@types/js-yaml": "^4.0.5",
"@types/json-stable-stringify": "^1.0.32",
"@types/json5": "^0.0.30",
"@types/license-checker": "15.0.0",
@@ -301,7 +303,7 @@
"@types/mock-fs": "^4.10.0",
"@types/moment-timezone": "^0.5.12",
"@types/mustache": "^0.8.31",
- "@types/node": "^14.17.32",
+ "@types/node": "~18.7.0",
"@types/node-forge": "^1.0.1",
"@types/normalize-path": "^3.0.0",
"@types/pegjs": "^0.10.1",
@@ -342,7 +344,6 @@
"angular-mocks": "^1.8.2",
"angular-recursion": "^1.0.5",
"angular-route": "^1.8.0",
- "angular-sortable-view": "^0.0.17",
"archiver": "^5.3.0",
"axe-core": "^4.0.2",
"babel-eslint": "^10.0.3",
@@ -396,7 +397,7 @@
"immer": "^9.0.6",
"intl-messageformat-parser": "^1.4.0",
"jest": "^27.5.1",
- "jest-canvas-mock": "^2.3.1",
+ "jest-canvas-mock": "^2.5.1",
"jest-raw-loader": "^1.0.1",
"jimp": "^0.14.0",
"jquery": "^3.5.0",
@@ -468,7 +469,7 @@
"zlib": "^1.0.5"
},
"engines": {
- "node": "^14.20.1",
+ "node": ">=14.20.1 <19",
"yarn": "^1.22.10"
}
}
diff --git a/packages/opensearch-eslint-config-opensearch-dashboards/README.md b/packages/opensearch-eslint-config-opensearch-dashboards/README.md
index 4fb3f13c8f29..a2f60c437e57 100644
--- a/packages/opensearch-eslint-config-opensearch-dashboards/README.md
+++ b/packages/opensearch-eslint-config-opensearch-dashboards/README.md
@@ -4,7 +4,7 @@ The eslint config used by the opensearch dashboards team
## Usage
-To use this eslint config, just install the peer dependencies and reference it
+To use this eslint config, just install the peer dependencies and reference it
in your `.eslintrc`:
```javascript
@@ -17,8 +17,8 @@ in your `.eslintrc`:
## Optional jest config
-If the project uses the [jest test runner](https://facebook.github.io/jest/),
-the `@elastic/eslint-config-kibana/jest` config can be extended as well to use
+If the project uses the [jest test runner](https://jestjs.io),
+the `@elastic/eslint-config-kibana/jest` config can be extended as well to use
`eslint-plugin-jest` and add settings specific to it:
```javascript
diff --git a/packages/osd-ace/package.json b/packages/osd-ace/package.json
index a93467058179..b78ca5e44074 100644
--- a/packages/osd-ace/package.json
+++ b/packages/osd-ace/package.json
@@ -16,6 +16,6 @@
"@osd/babel-preset": "1.0.0",
"raw-loader": "^4.0.2",
"typescript": "4.0.2",
- "webpack": "^4.41.5"
+ "webpack": "npm:@amoo-miki/webpack@4.46.0-rc.2"
}
}
diff --git a/packages/osd-apm-config-loader/package.json b/packages/osd-apm-config-loader/package.json
index c3c0249bd73e..fc06ff025e8a 100644
--- a/packages/osd-apm-config-loader/package.json
+++ b/packages/osd-apm-config-loader/package.json
@@ -13,7 +13,7 @@
"dependencies": {
"@elastic/safer-lodash-set": "0.0.0",
"@osd/utils": "1.0.0",
- "js-yaml": "^3.14.0",
+ "js-yaml": "^4.1.0",
"lodash": "^4.17.21"
},
"devDependencies": {
diff --git a/packages/osd-apm-config-loader/src/utils/read_config.ts b/packages/osd-apm-config-loader/src/utils/read_config.ts
index 806a1ad2e92a..7076060cb04d 100644
--- a/packages/osd-apm-config-loader/src/utils/read_config.ts
+++ b/packages/osd-apm-config-loader/src/utils/read_config.ts
@@ -29,13 +29,13 @@
*/
import { readFileSync } from 'fs';
-import { safeLoad } from 'js-yaml';
+import { load } from 'js-yaml';
import { set } from '@elastic/safer-lodash-set';
import { isPlainObject } from 'lodash';
import { ensureDeepObject } from './ensure_deep_object';
-const readYaml = (path: string) => safeLoad(readFileSync(path, 'utf8'));
+const readYaml = (path: string) => load(readFileSync(path, 'utf8'));
function replaceEnvVarRefs(val: string) {
return val.replace(/\$\{(\w+)\}/g, (match, envVarName) => {
diff --git a/packages/osd-config-schema/package.json b/packages/osd-config-schema/package.json
index 52471e29527c..c88afe609e1f 100644
--- a/packages/osd-config-schema/package.json
+++ b/packages/osd-config-schema/package.json
@@ -16,7 +16,7 @@
},
"peerDependencies": {
"lodash": "^4.17.21",
- "joi": "^13.5.2",
+ "joi": "^14.3.1",
"moment": "^2.24.0",
"type-detect": "^4.0.8"
}
diff --git a/packages/osd-config-schema/src/errors/__snapshots__/schema_error.test.ts.snap b/packages/osd-config-schema/src/errors/__snapshots__/schema_error.test.ts.snap
index 38f81a0cc62b..1f5e056ba69a 100644
--- a/packages/osd-config-schema/src/errors/__snapshots__/schema_error.test.ts.snap
+++ b/packages/osd-config-schema/src/errors/__snapshots__/schema_error.test.ts.snap
@@ -1,8 +1,7 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`includes stack 1`] = `
-"Error: test
- at new SchemaError (packages/osd-config-schema/src/errors/schema_error.ts:35:5)
- at Object. (packages/osd-config-schema/src/errors/schema_error.test.ts:59:11)
+"SchemaError: test
+ at Object. (packages/osd-config-schema/src/errors/schema_error.test.ts:67:11)
at new Promise ()"
`;
diff --git a/packages/osd-config-schema/src/errors/schema_error.test.ts b/packages/osd-config-schema/src/errors/schema_error.test.ts
index c134c888d510..c00add75719b 100644
--- a/packages/osd-config-schema/src/errors/schema_error.test.ts
+++ b/packages/osd-config-schema/src/errors/schema_error.test.ts
@@ -33,11 +33,14 @@ import { SchemaError } from '.';
import { standardize, getRepoRoot } from '@osd/cross-platform';
+// ToDo: Remove this logic when Node 14 support is removed
+const isNode14 = process.version.startsWith('v14.');
+
/**
* Make all paths in stacktrace relative.
*/
-export const cleanStack = (stack: string) =>
- stack
+export const cleanStack = (stack: string) => {
+ const result = stack
.split('\n')
.filter((line) => !line.includes('node_modules' + sep) && !line.includes('internal/'))
.map((line) => {
@@ -54,6 +57,11 @@ export const cleanStack = (stack: string) =>
})
.join('\n');
+ return isNode14
+ ? result.replace(/Error:\s([^\n]+)\n\s*at new ([^ ]+) [^\n]*\n/, '$2: $1\n')
+ : result;
+};
+
it('includes stack', () => {
try {
throw new SchemaError('test');
diff --git a/packages/osd-config-schema/src/errors/schema_error.ts b/packages/osd-config-schema/src/errors/schema_error.ts
index fd67de08af47..a47453813fcd 100644
--- a/packages/osd-config-schema/src/errors/schema_error.ts
+++ b/packages/osd-config-schema/src/errors/schema_error.ts
@@ -34,6 +34,7 @@ export class SchemaError extends Error {
constructor(message: string, cause?: Error) {
super(message);
this.cause = cause;
+ this.name = this.constructor.name;
// Set the prototype explicitly, see:
// https://github.com/Microsoft/TypeScript/wiki/Breaking-Changes#extending-built-ins-like-error-array-and-map-may-no-longer-work
diff --git a/packages/osd-config/package.json b/packages/osd-config/package.json
index 7d2f68abc8d8..f6d363c9c386 100644
--- a/packages/osd-config/package.json
+++ b/packages/osd-config/package.json
@@ -14,7 +14,7 @@
"@osd/config-schema": "1.0.0",
"@osd/logging": "1.0.0",
"@osd/std": "1.0.0",
- "js-yaml": "^3.14.0",
+ "js-yaml": "^4.1.0",
"load-json-file": "^6.2.0",
"lodash": "^4.17.21",
"moment": "^2.24.0",
diff --git a/packages/osd-config/src/config_service.test.ts b/packages/osd-config/src/config_service.test.ts
index 0ae49dab6015..0f634537be7e 100644
--- a/packages/osd-config/src/config_service.test.ts
+++ b/packages/osd-config/src/config_service.test.ts
@@ -94,10 +94,10 @@ test('throws if config at path does not match schema', async () => {
);
await expect(valuesReceived).toMatchInlineSnapshot(`
- Array [
- [Error: [config validation of [key]]: expected value of type [string] but got [number]],
- ]
- `);
+ Array [
+ [ValidationError: [config validation of [key]]: expected value of type [string] but got [number]],
+ ]
+ `);
});
test('re-validate config when updated', async () => {
@@ -120,11 +120,11 @@ test('re-validate config when updated', async () => {
rawConfig$.next({ key: 123 });
await expect(valuesReceived).toMatchInlineSnapshot(`
- Array [
- "value",
- [Error: [config validation of [key]]: expected value of type [string] but got [number]],
- ]
- `);
+ Array [
+ "value",
+ [ValidationError: [config validation of [key]]: expected value of type [string] but got [number]],
+ ]
+ `);
});
test("returns undefined if fetching optional config at a path that doesn't exist", async () => {
diff --git a/packages/osd-config/src/raw/read_config.ts b/packages/osd-config/src/raw/read_config.ts
index 0c4a7c2330de..ad7820381eee 100644
--- a/packages/osd-config/src/raw/read_config.ts
+++ b/packages/osd-config/src/raw/read_config.ts
@@ -29,13 +29,13 @@
*/
import { readFileSync } from 'fs';
-import { safeLoad } from 'js-yaml';
+import { load } from 'js-yaml';
import { set } from '@elastic/safer-lodash-set';
import { isPlainObject } from 'lodash';
import { ensureDeepObject } from './ensure_deep_object';
-const readYaml = (path: string) => safeLoad(readFileSync(path, 'utf8'));
+const readYaml = (path: string) => load(readFileSync(path, 'utf8'));
function replaceEnvVarRefs(val: string) {
return val.replace(/\$\{(\w+)\}/g, (match, envVarName) => {
diff --git a/packages/osd-cross-platform/src/path.test.ts b/packages/osd-cross-platform/src/path.test.ts
index ed405298ad13..3e338a426fda 100644
--- a/packages/osd-cross-platform/src/path.test.ts
+++ b/packages/osd-cross-platform/src/path.test.ts
@@ -5,7 +5,7 @@
import path from 'path';
import fs from 'fs';
-import { access, rmdir, mkdir, writeFile, symlink } from 'fs/promises';
+import { access, rm, mkdir, writeFile, symlink } from 'fs/promises';
import {
resolveToFullNameSync,
@@ -43,9 +43,9 @@ describe('Cross Platform', () => {
try {
// If leftover artifacts were found, get rid of them
await access(tmpTestFolder);
- await rmdir(tmpTestFolder, { recursive: true });
+ await rm(tmpTestFolder, { recursive: true });
} catch (ex) {
- // Do nothing; if `rmdir` failed, let the `mkdir` below throw the error
+ // Do nothing; if `rm` failed, let the `mkdir` below throw the error
}
await mkdir(tmpTestFolder);
@@ -60,7 +60,7 @@ describe('Cross Platform', () => {
afterAll(async () => {
try {
- await rmdir(tmpTestFolder, { recursive: true });
+ await rm(tmpTestFolder, { recursive: true });
} catch (ex) {
// Do nothing
}
diff --git a/packages/osd-dev-utils/package.json b/packages/osd-dev-utils/package.json
index ea433fa5e101..6a7a4fd9d647 100644
--- a/packages/osd-dev-utils/package.json
+++ b/packages/osd-dev-utils/package.json
@@ -22,7 +22,7 @@
"execa": "^4.0.2",
"exit-hook": "^2.2.0",
"getopts": "^2.2.5",
- "globby": "^8.0.1",
+ "globby": "^11.1.0",
"load-json-file": "^6.2.0",
"markdown-it": "^12.3.2",
"moment": "^2.24.0",
diff --git a/packages/osd-dev-utils/src/proc_runner/proc.ts b/packages/osd-dev-utils/src/proc_runner/proc.ts
index 1de472df40b2..c5e905204915 100644
--- a/packages/osd-dev-utils/src/proc_runner/proc.ts
+++ b/packages/osd-dev-utils/src/proc_runner/proc.ts
@@ -153,7 +153,7 @@ export function startProc(name: string, options: ProcOptions, log: ToolingLog) {
await withTimeout(
async () => {
log.debug(`Sending "${signal}" to proc "${name}"`);
- await treeKillAsync(childProcess.pid, signal);
+ await treeKillAsync(childProcess.pid!, signal);
await outcomePromise;
},
STOP_TIMEOUT,
@@ -161,7 +161,7 @@ export function startProc(name: string, options: ProcOptions, log: ToolingLog) {
log.warning(
`Proc "${name}" was sent "${signal}" didn't emit the "exit" or "error" events after ${STOP_TIMEOUT} ms, sending SIGKILL`
);
- await treeKillAsync(childProcess.pid, 'SIGKILL');
+ await treeKillAsync(childProcess.pid!, 'SIGKILL');
}
);
diff --git a/packages/osd-dev-utils/src/serializers/absolute_path_serializer.ts b/packages/osd-dev-utils/src/serializers/absolute_path_serializer.ts
index 939b6e9924df..b7c6f8fe9139 100644
--- a/packages/osd-dev-utils/src/serializers/absolute_path_serializer.ts
+++ b/packages/osd-dev-utils/src/serializers/absolute_path_serializer.ts
@@ -37,6 +37,10 @@ export function createAbsolutePathSerializer(
) {
const rootPaths = Array.isArray(rootPath) ? rootPath : [rootPath];
+ if (process.platform === 'win32') {
+ rootPaths.push(...rootPaths.map((name) => name.replace(/\\/g, '/')));
+ }
+
return {
test: (value: any) =>
typeof value === 'string' && rootPaths.some((path) => value.startsWith(path)),
diff --git a/packages/osd-dev-utils/src/serializers/index.ts b/packages/osd-dev-utils/src/serializers/index.ts
index 4ea72efe3f53..2755a5a79147 100644
--- a/packages/osd-dev-utils/src/serializers/index.ts
+++ b/packages/osd-dev-utils/src/serializers/index.ts
@@ -33,3 +33,4 @@ export * from './strip_ansi_serializer';
export * from './recursive_serializer';
export * from './any_instance_serizlizer';
export * from './replace_serializer';
+export * from './strip_promises_serizlizer';
diff --git a/packages/osd-dev-utils/src/serializers/strip_promises_serizlizer.ts b/packages/osd-dev-utils/src/serializers/strip_promises_serizlizer.ts
new file mode 100644
index 000000000000..eda8422c77c4
--- /dev/null
+++ b/packages/osd-dev-utils/src/serializers/strip_promises_serizlizer.ts
@@ -0,0 +1,9 @@
+/*
+ * Copyright OpenSearch Contributors
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+export const createStripPromisesSerializer = () => ({
+ serialize: (value: string) => value.replace(/("value": Promise) \{[^}]+}/gm, '$1 {}'),
+ test: (value: any) => typeof value === 'string',
+});
diff --git a/packages/osd-dev-utils/src/simple_opensearch_dashboards_platform_plugin_discovery.ts b/packages/osd-dev-utils/src/simple_opensearch_dashboards_platform_plugin_discovery.ts
index ef6c5913d9b4..b84579a36d3e 100644
--- a/packages/osd-dev-utils/src/simple_opensearch_dashboards_platform_plugin_discovery.ts
+++ b/packages/osd-dev-utils/src/simple_opensearch_dashboards_platform_plugin_discovery.ts
@@ -28,7 +28,8 @@
* under the License.
*/
-import Path from 'path';
+import { resolve } from 'path';
+import { standardize } from '@osd/cross-platform';
import globby from 'globby';
@@ -47,24 +48,23 @@ export function simpleOpenSearchDashboardsPlatformPluginDiscovery(
...scanDirs.reduce(
(acc: string[], dir) => [
...acc,
- Path.resolve(dir, '*/opensearch_dashboards.json'),
- Path.resolve(dir, '*/*/opensearch_dashboards.json'),
- Path.resolve(dir, '*/*/*/opensearch_dashboards.json'),
- Path.resolve(dir, '*/*/*/*/opensearch_dashboards.json'),
- Path.resolve(dir, '*/*/*/*/*/opensearch_dashboards.json'),
+ resolve(dir, '*/opensearch_dashboards.json'),
+ resolve(dir, '*/*/opensearch_dashboards.json'),
+ resolve(dir, '*/*/*/opensearch_dashboards.json'),
+ resolve(dir, '*/*/*/*/opensearch_dashboards.json'),
+ resolve(dir, '*/*/*/*/*/opensearch_dashboards.json'),
],
[]
),
- ...pluginPaths.map((path) => Path.resolve(path, `opensearch_dashboards.json`)),
+ ...pluginPaths.map((path) => resolve(path, `opensearch_dashboards.json`)),
])
);
- const manifestPaths = globby.sync(patterns, { absolute: true }).map((path) =>
- // absolute paths returned from globby are using normalize or
- // something so the path separators are `/` even on windows,
- // Path.resolve solves this
- Path.resolve(path)
- );
+ const standardizedPatterns = patterns.map((pattern) => standardize(pattern));
+
+ const manifestPaths = globby
+ .sync(standardizedPatterns, { absolute: true })
+ .map((path) => standardize(resolve(path)));
return manifestPaths.map(parseOpenSearchDashboardsPlatformPlugin);
}
diff --git a/packages/osd-eslint-import-resolver-opensearch-dashboards/package.json b/packages/osd-eslint-import-resolver-opensearch-dashboards/package.json
index 1594e45e50b5..1112cb1ed223 100755
--- a/packages/osd-eslint-import-resolver-opensearch-dashboards/package.json
+++ b/packages/osd-eslint-import-resolver-opensearch-dashboards/package.json
@@ -19,6 +19,6 @@
"glob-all": "^3.2.1",
"lru-cache": "^4.1.5",
"resolve": "^1.7.1",
- "webpack": "^4.41.5"
+ "webpack": "npm:@amoo-miki/webpack@4.46.0-rc.2"
}
}
diff --git a/packages/osd-interpreter/package.json b/packages/osd-interpreter/package.json
index 77ec29c839dd..6d11eb3bc1ee 100644
--- a/packages/osd-interpreter/package.json
+++ b/packages/osd-interpreter/package.json
@@ -27,11 +27,11 @@
"del": "^6.1.1",
"getopts": "^2.2.5",
"pegjs": "0.10.0",
- "sass-loader": "^10.2.0",
+ "sass-loader": "^10.4.1",
"style-loader": "^1.1.3",
"supports-color": "^7.0.0",
"url-loader": "^2.2.0",
- "webpack": "^4.41.5",
+ "webpack": "npm:@amoo-miki/webpack@4.46.0-rc.2",
"webpack-cli": "^4.9.2"
}
}
diff --git a/packages/osd-monaco/package.json b/packages/osd-monaco/package.json
index a3f973d11fd0..ae9cfaddc53a 100644
--- a/packages/osd-monaco/package.json
+++ b/packages/osd-monaco/package.json
@@ -13,6 +13,7 @@
"monaco-editor": "~0.17.0"
},
"devDependencies": {
+ "@node-rs/xxhash": "^1.3.0",
"@osd/babel-preset": "1.0.0",
"@osd/dev-utils": "1.0.0",
"babel-loader": "^8.2.3",
@@ -21,7 +22,7 @@
"raw-loader": "^4.0.2",
"supports-color": "^7.0.0",
"typescript": "4.0.2",
- "webpack": "^4.41.5",
+ "webpack": "npm:@amoo-miki/webpack@4.46.0-rc.2",
"webpack-cli": "^4.9.2"
}
}
diff --git a/packages/osd-monaco/webpack.config.js b/packages/osd-monaco/webpack.config.js
index 1e3f108b95e5..b111fcb2608d 100644
--- a/packages/osd-monaco/webpack.config.js
+++ b/packages/osd-monaco/webpack.config.js
@@ -36,6 +36,7 @@ const createLangWorkerConfig = (lang) => ({
output: {
path: path.resolve(__dirname, 'target/public'),
filename: `${lang}.editor.worker.js`,
+ hashFunction: 'Xxh64',
},
resolve: {
modules: ['node_modules'],
diff --git a/packages/osd-opensearch/package.json b/packages/osd-opensearch/package.json
index 02fcddb36e6f..44404a9ae5a3 100644
--- a/packages/osd-opensearch/package.json
+++ b/packages/osd-opensearch/package.json
@@ -12,7 +12,7 @@
"osd:watch": "../../scripts/use_node scripts/build --watch"
},
"dependencies": {
- "@opensearch-project/opensearch": "^2.1.0",
+ "@opensearch-project/opensearch": "^2.2.0",
"@osd/dev-utils": "1.0.0",
"abort-controller": "^3.0.0",
"chalk": "^4.1.0",
diff --git a/packages/osd-optimizer/limits.yml b/packages/osd-optimizer/limits.yml
index d39f9316c80d..516ebae80abf 100644
--- a/packages/osd-optimizer/limits.yml
+++ b/packages/osd-optimizer/limits.yml
@@ -74,7 +74,6 @@ pageLoadAssetSize:
telemetry: 91832
telemetryManagementSection: 52443
tileMap: 65337
- timeline: 29920
transform: 41151
triggersActionsUi: 170145
uiActions: 95074
diff --git a/packages/osd-optimizer/package.json b/packages/osd-optimizer/package.json
index 2aec5681ba91..27047c7b4ef5 100644
--- a/packages/osd-optimizer/package.json
+++ b/packages/osd-optimizer/package.json
@@ -19,22 +19,21 @@
"@osd/ui-shared-deps": "1.0.0",
"autoprefixer": "^10.4.1",
"clean-webpack-plugin": "^3.0.0",
- "compression-webpack-plugin": "^4.0.0",
+ "compression-webpack-plugin": "npm:@amoo-miki/compression-webpack-plugin@4.0.1-rc.1",
"cpy": "^8.0.0",
"core-js": "^3.6.5",
"dedent": "^0.7.0",
"del": "^6.1.1",
"execa": "^4.0.2",
- "fibers": "^5.0.3",
"jest-diff": "^27.5.1",
- "js-yaml": "^3.14.0",
+ "js-yaml": "^4.1.0",
"json-stable-stringify": "^1.0.1",
- "lmdb-store": "^1.6.11",
+ "lmdb": "^2.8.0",
"normalize-path": "^3.0.0",
"pirates": "^4.0.1",
"postcss": "^8.4.5",
"rxjs": "^6.5.5",
- "sass": "~1.26.11",
+ "node-sass": "^8.0.0",
"source-map-support": "^0.5.19",
"terser-webpack-plugin": "^2.1.2",
"tinymath": "1.2.1",
@@ -42,8 +41,9 @@
"webpack-merge": "^4.2.2"
},
"devDependencies": {
+ "@node-rs/xxhash": "^1.3.0",
"@types/babel__core": "^7.1.17",
- "@types/compression-webpack-plugin": "^2.0.2",
+ "@types/compression-webpack-plugin": "^6.0.6",
"@types/loader-utils": "^1.1.3",
"@types/source-map-support": "^0.5.3",
"@types/watchpack": "^1.1.6",
@@ -54,10 +54,10 @@
"loader-utils": "^2.0.4",
"postcss-loader": "^4.2.0",
"raw-loader": "^4.0.2",
- "sass-loader": "^10.2.0",
+ "sass-loader": "^10.4.1",
"style-loader": "^1.1.3",
"url-loader": "^2.2.0",
"val-loader": "^2.1.2",
- "webpack": "^4.41.5"
+ "webpack": "npm:@amoo-miki/webpack@4.46.0-rc.2"
}
}
diff --git a/packages/osd-optimizer/src/__mocks__/lmdb.ts b/packages/osd-optimizer/src/__mocks__/lmdb.ts
new file mode 100644
index 000000000000..d0bfe969d207
--- /dev/null
+++ b/packages/osd-optimizer/src/__mocks__/lmdb.ts
@@ -0,0 +1,17 @@
+/*
+ * Copyright OpenSearch Contributors
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+jest.mock('lmdb', () => {
+ const mockedLmdb = {
+ open: jest.fn(() => ({
+ openDB: jest.fn(() => ({
+ get: jest.fn(),
+ putSync: jest.fn(),
+ remove: jest.fn(),
+ })),
+ })),
+ };
+ return mockedLmdb;
+});
diff --git a/packages/osd-optimizer/src/integration_tests/__snapshots__/basic_optimization.test.ts.snap b/packages/osd-optimizer/src/integration_tests/__snapshots__/basic_optimization.test.ts.snap
index aaa485172c5f..63b7e44fea07 100644
--- a/packages/osd-optimizer/src/integration_tests/__snapshots__/basic_optimization.test.ts.snap
+++ b/packages/osd-optimizer/src/integration_tests/__snapshots__/basic_optimization.test.ts.snap
@@ -74,7 +74,7 @@ OptimizerConfig {
}
`;
-exports[`prepares assets for distribution: bar bundle 1`] = `"(function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId]){return installedModules[moduleId].exports}var module=installedModules[moduleId]={i:moduleId,l:false,exports:{}};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.l=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.d=function(exports,name,getter){if(!__webpack_require__.o(exports,name)){Object.defineProperty(exports,name,{enumerable:true,get:getter})}};__webpack_require__.r=function(exports){if(typeof Symbol!==\\"undefined\\"&&Symbol.toStringTag){Object.defineProperty(exports,Symbol.toStringTag,{value:\\"Module\\"})}Object.defineProperty(exports,\\"__esModule\\",{value:true})};__webpack_require__.t=function(value,mode){if(mode&1)value=__webpack_require__(value);if(mode&8)return value;if(mode&4&&typeof value===\\"object\\"&&value&&value.__esModule)return value;var ns=Object.create(null);__webpack_require__.r(ns);Object.defineProperty(ns,\\"default\\",{enumerable:true,value:value});if(mode&2&&typeof value!=\\"string\\")for(var key in value)__webpack_require__.d(ns,key,function(key){return value[key]}.bind(null,key));return ns};__webpack_require__.n=function(module){var getter=module&&module.__esModule?function getDefault(){return module[\\"default\\"]}:function getModuleExports(){return module};__webpack_require__.d(getter,\\"a\\",getter);return getter};__webpack_require__.o=function(object,property){return Object.prototype.hasOwnProperty.call(object,property)};__webpack_require__.p=\\"\\";return __webpack_require__(__webpack_require__.s=3)})([function(module,exports,__webpack_require__){\\"use strict\\";module.exports=function(cssWithMappingToString){var list=[];list.toString=function toString(){return this.map((function(item){var content=cssWithMappingToString(item);if(item[2]){return\\"@media \\".concat(item[2],\\" {\\").concat(content,\\"}\\")}return content})).join(\\"\\")};list.i=function(modules,mediaQuery,dedupe){if(typeof modules===\\"string\\"){modules=[[null,modules,\\"\\"]]}var alreadyImportedModules={};if(dedupe){for(var i=0;i value.split(REPO_ROOT).join('').replace(/\\/g, '/'),
- test: (value: any) => typeof value === 'string' && value.includes(REPO_ROOT),
-});
+const absolutePathSerializer = createAbsolutePathSerializer();
+expect.addSnapshotSerializer(absolutePathSerializer);
const log = new ToolingLog({
level: 'error',
@@ -159,15 +158,16 @@ it('builds expected bundles, saves bundle counts to metadata', async () => {
expect(foo).toBeTruthy();
foo.cache.refresh();
expect(foo.cache.getModuleCount()).toBe(6);
- expect(foo.cache.getReferencedFiles()).toMatchInlineSnapshot(`
+ expect(foo.cache.getReferencedFiles()?.map(absolutePathSerializer.serialize).sort())
+ .toMatchInlineSnapshot(`
Array [
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/opensearch_dashboards.json,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/async_import.ts,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/ext.ts,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/index.ts,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/lib.ts,
- /packages/osd-optimizer/target/worker/entry_point_creator.js,
- /packages/osd-ui-shared-deps/public_path_module_creator.js,
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/opensearch_dashboards.json",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/async_import.ts",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/ext.ts",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/index.ts",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/public/lib.ts",
+ "/packages/osd-optimizer/target/worker/entry_point_creator.js",
+ "/packages/osd-ui-shared-deps/public_path_module_creator.js",
]
`);
@@ -179,21 +179,22 @@ it('builds expected bundles, saves bundle counts to metadata', async () => {
17
);
- expect(bar.cache.getReferencedFiles()).toMatchInlineSnapshot(`
+ expect(bar.cache.getReferencedFiles()?.map(absolutePathSerializer.serialize).sort())
+ .toMatchInlineSnapshot(`
Array [
- /node_modules/css-loader/package.json,
- /node_modules/style-loader/package.json,
- /packages/osd-optimizer/postcss.config.js,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/opensearch_dashboards.json,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/index.scss,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/index.ts,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/legacy/_other_styles.scss,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/legacy/styles.scss,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/lib.ts,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/src/core/public/core_app/styles/_globals_v7dark.scss,
- /packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/src/core/public/core_app/styles/_globals_v7light.scss,
- /packages/osd-optimizer/target/worker/entry_point_creator.js,
- /packages/osd-ui-shared-deps/public_path_module_creator.js,
+ "/node_modules/css-loader/package.json",
+ "/node_modules/style-loader/package.json",
+ "/packages/osd-optimizer/postcss.config.js",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/opensearch_dashboards.json",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/index.scss",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/index.ts",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/legacy/_other_styles.scss",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/legacy/styles.scss",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/public/lib.ts",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/src/core/public/core_app/styles/_globals_v7dark.scss",
+ "/packages/osd-optimizer/src/__fixtures__/__tmp__/mock_repo/src/core/public/core_app/styles/_globals_v7light.scss",
+ "/packages/osd-optimizer/target/worker/entry_point_creator.js",
+ "/packages/osd-ui-shared-deps/public_path_module_creator.js",
]
`);
});
@@ -256,7 +257,6 @@ const expectFileMatchesSnapshotWithCompression = (filePath: string, snapshotLabe
// Verify the brotli variant matches
expect(
- // @ts-expect-error @types/node is missing the brotli functions
Zlib.brotliDecompressSync(
Fs.readFileSync(Path.resolve(MOCK_REPO_DIR, `${filePath}.br`))
).toString()
diff --git a/packages/osd-optimizer/src/limits.ts b/packages/osd-optimizer/src/limits.ts
index 86b186930275..d81137c3a9a4 100644
--- a/packages/osd-optimizer/src/limits.ts
+++ b/packages/osd-optimizer/src/limits.ts
@@ -51,7 +51,7 @@ export function readLimits(): Limits {
}
}
- return yaml ? (Yaml.safeLoad(yaml) as any) : {};
+ return yaml ? (Yaml.load(yaml) as any) : {};
}
export function validateLimitsForAllBundles(log: ToolingLog, config: OptimizerConfig) {
@@ -109,6 +109,6 @@ export function updateBundleLimits(log: ToolingLog, config: OptimizerConfig) {
pageLoadAssetSize,
};
- Fs.writeFileSync(LIMITS_PATH, Yaml.safeDump(newLimits));
+ Fs.writeFileSync(LIMITS_PATH, Yaml.dump(newLimits));
log.success(`wrote updated limits to ${LIMITS_PATH}`);
}
diff --git a/packages/osd-optimizer/src/node/cache.ts b/packages/osd-optimizer/src/node/cache.ts
index e60038102fb5..a81c656267bf 100644
--- a/packages/osd-optimizer/src/node/cache.ts
+++ b/packages/osd-optimizer/src/node/cache.ts
@@ -32,7 +32,7 @@ import Path from 'path';
import { Writable } from 'stream';
import chalk from 'chalk';
-import * as LmdbStore from 'lmdb-store';
+import LMDB from 'lmdb';
import { getMatchingRoot } from '@osd/cross-platform';
const GLOBAL_ATIME = `${Date.now()}`;
@@ -40,15 +40,15 @@ const MINUTE = 1000 * 60;
const HOUR = MINUTE * 60;
const DAY = HOUR * 24;
-const dbName = (db: LmdbStore.Database) =>
+const dbName = (db: LMDB.Database) =>
// @ts-expect-error db.name is not a documented/typed property
db.name;
export class Cache {
- private readonly codes: LmdbStore.RootDatabase;
- private readonly atimes: LmdbStore.Database;
- private readonly mtimes: LmdbStore.Database;
- private readonly sourceMaps: LmdbStore.Database;
+ private readonly codes: LMDB.RootDatabase;
+ private readonly atimes: LMDB.Database;
+ private readonly mtimes: LMDB.Database;
+ private readonly sourceMaps: LMDB.Database;
private readonly pathRoots: string[];
private readonly prefix: string;
private readonly log?: Writable;
@@ -70,7 +70,7 @@ export class Cache {
this.prefix = config.prefix;
this.log = config.log;
- this.codes = LmdbStore.open(config.dir, {
+ this.codes = LMDB.open(config.dir, {
name: 'codes',
encoding: 'string',
maxReaders: 500,
@@ -144,6 +144,7 @@ export class Cache {
close() {
clearTimeout(this.timer);
+ return this.codes?.close?.();
}
private getKey(path: string) {
@@ -162,7 +163,7 @@ export class Cache {
return `${this.prefix}${normalizedPath}`;
}
- private safeGet(db: LmdbStore.Database, key: string) {
+ private safeGet(db: LMDB.Database, key: string) {
try {
const value = db.get(key);
this.debug(value === undefined ? 'MISS' : 'HIT', db, key);
@@ -172,7 +173,7 @@ export class Cache {
}
}
- private async safePut(db: LmdbStore.Database, key: string, value: V) {
+ private async safePut(db: LMDB.Database, key: string, value: V) {
try {
await db.put(key, value);
this.debug('PUT', db, key);
@@ -181,13 +182,13 @@ export class Cache {
}
}
- private debug(type: string, db: LmdbStore.Database, key: LmdbStore.Key) {
+ private debug(type: string, db: LMDB.Database, key: LMDB.Key) {
if (this.log) {
this.log.write(`${type} [${dbName(db)}] ${String(key)}\n`);
}
}
- private logError(type: 'GET' | 'PUT', db: LmdbStore.Database, key: LmdbStore.Key, error: Error) {
+ private logError(type: 'GET' | 'PUT', db: LMDB.Database, key: LMDB.Key, error: Error) {
this.debug(`ERROR/${type}`, db, `${String(key)}: ${error.stack}`);
process.stderr.write(
chalk.red(
@@ -204,7 +205,6 @@ export class Cache {
const validKeys: string[] = [];
const invalidKeys: string[] = [];
- // @ts-expect-error See https://github.com/DoctorEvidence/lmdb-store/pull/18
for (const { key, value } of this.atimes.getRange()) {
const atime = parseInt(`${value}`, 10);
if (Number.isNaN(atime) || atime < ATIME_LIMIT) {
diff --git a/packages/osd-optimizer/src/optimizer/optimizer_config.test.ts b/packages/osd-optimizer/src/optimizer/optimizer_config.test.ts
index a8a950726592..30620478349d 100644
--- a/packages/osd-optimizer/src/optimizer/optimizer_config.test.ts
+++ b/packages/osd-optimizer/src/optimizer/optimizer_config.test.ts
@@ -43,7 +43,17 @@ jest.mock('os', () => {
return realOs;
});
+jest.mock('fs', () => {
+ const originalFs = jest.requireActual('fs');
+ return {
+ ...originalFs,
+ existsSync: jest.fn(),
+ realpathSync: originalFs.realpathSync,
+ };
+});
+
import Path from 'path';
+import { existsSync } from 'fs';
import { REPO_ROOT } from '@osd/utils';
import { createAbsolutePathSerializer } from '@osd/dev-utils';
@@ -122,7 +132,265 @@ describe('OptimizerConfig::parseOptions()', () => {
expect(parseThemeTags).toBeCalledWith('foo');
});
- it('applies defaults', () => {
+ it('applies defaults if opensearch-dashboards-extra path does not exist', () => {
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": true,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 2,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [
+ /src/plugins,
+ /plugins,
+ /opensearch-dashboards-extra,
+ ],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ cache: false,
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": false,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 2,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [
+ /src/plugins,
+ /plugins,
+ /opensearch-dashboards-extra,
+ ],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ examples: true,
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": true,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 2,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [
+ /src/plugins,
+ /plugins,
+ /examples,
+ /opensearch-dashboards-extra,
+ ],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": true,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 2,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [
+ /src/plugins,
+ /plugins,
+ /opensearch-dashboards-extra,
+ ],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ pluginScanDirs: [Path.resolve(REPO_ROOT, 'x/y/z'), '/outside/of/repo'],
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": true,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 2,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [
+ /x/y/z,
+ "/outside/of/repo",
+ ],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ process.env.OSD_OPTIMIZER_MAX_WORKERS = '100';
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ pluginScanDirs: [],
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": true,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 100,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ process.env.OSD_OPTIMIZER_NO_CACHE = '0';
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ pluginScanDirs: [],
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": false,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 100,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ process.env.OSD_OPTIMIZER_NO_CACHE = '1';
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ pluginScanDirs: [],
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": false,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 100,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ process.env.OSD_OPTIMIZER_NO_CACHE = '1';
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ pluginScanDirs: [],
+ cache: true,
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": false,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 100,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+
+ delete process.env.OSD_OPTIMIZER_NO_CACHE;
+ expect(
+ OptimizerConfig.parseOptions({
+ repoRoot: REPO_ROOT,
+ pluginScanDirs: [],
+ cache: true,
+ })
+ ).toMatchInlineSnapshot(`
+ Object {
+ "cache": true,
+ "dist": false,
+ "filters": Array [],
+ "includeCoreBundle": false,
+ "inspectWorkers": false,
+ "maxWorkerCount": 100,
+ "outputRoot": ,
+ "pluginPaths": Array [],
+ "pluginScanDirs": Array [],
+ "profileWebpack": false,
+ "repoRoot": ,
+ "themeTags": undefined,
+ "watch": false,
+ }
+ `);
+ });
+
+ it('applies defaults if opensearch-dashboards-extra path exists', () => {
+ (existsSync as jest.Mock).mockReturnValue(true);
expect(
OptimizerConfig.parseOptions({
repoRoot: REPO_ROOT,
@@ -461,7 +729,7 @@ describe('OptimizerConfig::create()', () => {
[Window],
],
"invocationCallOrder": Array [
- 21,
+ 39,
],
"lastCall": Array [
Symbol(parsed plugin scan dirs),
@@ -491,7 +759,7 @@ describe('OptimizerConfig::create()', () => {
[Window],
],
"invocationCallOrder": Array [
- 23,
+ 41,
],
"lastCall": Array [
Array [],
@@ -522,7 +790,7 @@ describe('OptimizerConfig::create()', () => {
[Window],
],
"invocationCallOrder": Array [
- 22,
+ 40,
],
"lastCall": Array [
Symbol(new platform plugins),
diff --git a/packages/osd-optimizer/src/worker/webpack.config.ts b/packages/osd-optimizer/src/worker/webpack.config.ts
index caeed72a3bb1..f5272c207548 100644
--- a/packages/osd-optimizer/src/worker/webpack.config.ts
+++ b/packages/osd-optimizer/src/worker/webpack.config.ts
@@ -50,7 +50,7 @@ export function getWebpackConfig(bundle: Bundle, bundleRefs: BundleRefs, worker:
const commonConfig: webpack.Configuration = {
node: { fs: 'empty' },
- context: bundle.contextDir,
+ context: Path.normalize(bundle.contextDir),
cache: true,
entry: {
[bundle.id]: ENTRY_CREATOR,
@@ -69,6 +69,7 @@ export function getWebpackConfig(bundle: Bundle, bundleRefs: BundleRefs, worker:
info.absoluteResourcePath
)}${info.query}`,
jsonpFunction: `${bundle.id}_bundle_jsonpfunction`,
+ hashFunction: 'Xxh64',
},
optimization: {
@@ -176,12 +177,11 @@ export function getWebpackConfig(bundle: Bundle, bundleRefs: BundleRefs, worker:
)};\n${content}`;
},
webpackImporter: false,
- implementation: require('sass'),
+ implementation: require('node-sass'),
sassOptions: {
outputStyle: 'compressed',
includePaths: [Path.resolve(worker.repoRoot, 'node_modules')],
sourceMapRoot: `/${bundle.type}:${bundle.id}`,
- fiber: require('fibers'),
},
},
},
diff --git a/packages/osd-pm/dist/index.js b/packages/osd-pm/dist/index.js
index 944856a8dd13..e43a9bfe407e 100644
--- a/packages/osd-pm/dist/index.js
+++ b/packages/osd-pm/dist/index.js
@@ -134,7 +134,7 @@ Object.defineProperty(exports, "run", {
var _cli = __webpack_require__(1);
-var _production = __webpack_require__(516);
+var _production = __webpack_require__(515);
var _projects = __webpack_require__(146);
@@ -783,245 +783,245 @@ __webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__importDefault", function() { return __importDefault; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__classPrivateFieldGet", function() { return __classPrivateFieldGet; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__classPrivateFieldSet", function() { return __classPrivateFieldSet; });
-/*! *****************************************************************************
-Copyright (c) Microsoft Corporation.
-
-Permission to use, copy, modify, and/or distribute this software for any
-purpose with or without fee is hereby granted.
-
-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
-REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
-INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
-LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
-OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-PERFORMANCE OF THIS SOFTWARE.
-***************************************************************************** */
-/* global Reflect, Promise */
-
-var extendStatics = function(d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
- return extendStatics(d, b);
-};
-
-function __extends(d, b) {
- if (typeof b !== "function" && b !== null)
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
-}
-
-var __assign = function() {
- __assign = Object.assign || function __assign(t) {
- for (var s, i = 1, n = arguments.length; i < n; i++) {
- s = arguments[i];
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
- }
- return t;
- }
- return __assign.apply(this, arguments);
-}
-
-function __rest(s, e) {
- var t = {};
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
- t[p] = s[p];
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
- t[p[i]] = s[p[i]];
- }
- return t;
-}
-
-function __decorate(decorators, target, key, desc) {
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
- return c > 3 && r && Object.defineProperty(target, key, r), r;
-}
-
-function __param(paramIndex, decorator) {
- return function (target, key) { decorator(target, key, paramIndex); }
-}
-
-function __metadata(metadataKey, metadataValue) {
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
-}
-
-function __awaiter(thisArg, _arguments, P, generator) {
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
- return new (P || (P = Promise))(function (resolve, reject) {
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
- step((generator = generator.apply(thisArg, _arguments || [])).next());
- });
-}
-
-function __generator(thisArg, body) {
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
- function verb(n) { return function (v) { return step([n, v]); }; }
- function step(op) {
- if (f) throw new TypeError("Generator is already executing.");
- while (_) try {
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
- if (y = 0, t) op = [op[0] & 2, t.value];
- switch (op[0]) {
- case 0: case 1: t = op; break;
- case 4: _.label++; return { value: op[1], done: false };
- case 5: _.label++; y = op[1]; op = [0]; continue;
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
- default:
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
- if (t[2]) _.ops.pop();
- _.trys.pop(); continue;
- }
- op = body.call(thisArg, _);
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
- }
-}
-
-var __createBinding = Object.create ? (function(o, m, k, k2) {
- if (k2 === undefined) k2 = k;
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
-}) : (function(o, m, k, k2) {
- if (k2 === undefined) k2 = k;
- o[k2] = m[k];
-});
-
-function __exportStar(m, o) {
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);
-}
-
-function __values(o) {
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
- if (m) return m.call(o);
- if (o && typeof o.length === "number") return {
- next: function () {
- if (o && i >= o.length) o = void 0;
- return { value: o && o[i++], done: !o };
- }
- };
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
-}
-
-function __read(o, n) {
- var m = typeof Symbol === "function" && o[Symbol.iterator];
- if (!m) return o;
- var i = m.call(o), r, ar = [], e;
- try {
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
- }
- catch (error) { e = { error: error }; }
- finally {
- try {
- if (r && !r.done && (m = i["return"])) m.call(i);
- }
- finally { if (e) throw e.error; }
- }
- return ar;
-}
-
-/** @deprecated */
-function __spread() {
- for (var ar = [], i = 0; i < arguments.length; i++)
- ar = ar.concat(__read(arguments[i]));
- return ar;
-}
-
-/** @deprecated */
-function __spreadArrays() {
- for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
- for (var r = Array(s), k = 0, i = 0; i < il; i++)
- for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
- r[k] = a[j];
- return r;
-}
-
-function __spreadArray(to, from, pack) {
- if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
- if (ar || !(i in from)) {
- if (!ar) ar = Array.prototype.slice.call(from, 0, i);
- ar[i] = from[i];
- }
- }
- return to.concat(ar || Array.prototype.slice.call(from));
-}
-
-function __await(v) {
- return this instanceof __await ? (this.v = v, this) : new __await(v);
-}
-
-function __asyncGenerator(thisArg, _arguments, generator) {
- if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
- var g = generator.apply(thisArg, _arguments || []), i, q = [];
- return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
- function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
- function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
- function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
- function fulfill(value) { resume("next", value); }
- function reject(value) { resume("throw", value); }
- function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
-}
-
-function __asyncDelegator(o) {
- var i, p;
- return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
- function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
-}
-
-function __asyncValues(o) {
- if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
- var m = o[Symbol.asyncIterator], i;
- return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
- function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
- function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
-}
-
-function __makeTemplateObject(cooked, raw) {
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
- return cooked;
-};
-
-var __setModuleDefault = Object.create ? (function(o, v) {
- Object.defineProperty(o, "default", { enumerable: true, value: v });
-}) : function(o, v) {
- o["default"] = v;
-};
-
-function __importStar(mod) {
- if (mod && mod.__esModule) return mod;
- var result = {};
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
- __setModuleDefault(result, mod);
- return result;
-}
-
-function __importDefault(mod) {
- return (mod && mod.__esModule) ? mod : { default: mod };
-}
-
-function __classPrivateFieldGet(receiver, state, kind, f) {
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
- return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
-}
-
-function __classPrivateFieldSet(receiver, state, value, kind, f) {
- if (kind === "m") throw new TypeError("Private method is not writable");
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
- return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
-}
+/*! *****************************************************************************
+Copyright (c) Microsoft Corporation.
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
+REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
+AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
+INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
+OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+PERFORMANCE OF THIS SOFTWARE.
+***************************************************************************** */
+/* global Reflect, Promise */
+
+var extendStatics = function(d, b) {
+ extendStatics = Object.setPrototypeOf ||
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
+ return extendStatics(d, b);
+};
+
+function __extends(d, b) {
+ if (typeof b !== "function" && b !== null)
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
+ extendStatics(d, b);
+ function __() { this.constructor = d; }
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+}
+
+var __assign = function() {
+ __assign = Object.assign || function __assign(t) {
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
+ s = arguments[i];
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
+ }
+ return t;
+ }
+ return __assign.apply(this, arguments);
+}
+
+function __rest(s, e) {
+ var t = {};
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
+ t[p] = s[p];
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
+ t[p[i]] = s[p[i]];
+ }
+ return t;
+}
+
+function __decorate(decorators, target, key, desc) {
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
+}
+
+function __param(paramIndex, decorator) {
+ return function (target, key) { decorator(target, key, paramIndex); }
+}
+
+function __metadata(metadataKey, metadataValue) {
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
+}
+
+function __awaiter(thisArg, _arguments, P, generator) {
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
+ return new (P || (P = Promise))(function (resolve, reject) {
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
+ });
+}
+
+function __generator(thisArg, body) {
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
+ function verb(n) { return function (v) { return step([n, v]); }; }
+ function step(op) {
+ if (f) throw new TypeError("Generator is already executing.");
+ while (_) try {
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
+ if (y = 0, t) op = [op[0] & 2, t.value];
+ switch (op[0]) {
+ case 0: case 1: t = op; break;
+ case 4: _.label++; return { value: op[1], done: false };
+ case 5: _.label++; y = op[1]; op = [0]; continue;
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
+ default:
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
+ if (t[2]) _.ops.pop();
+ _.trys.pop(); continue;
+ }
+ op = body.call(thisArg, _);
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
+ }
+}
+
+var __createBinding = Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+});
+
+function __exportStar(m, o) {
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);
+}
+
+function __values(o) {
+ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
+ if (m) return m.call(o);
+ if (o && typeof o.length === "number") return {
+ next: function () {
+ if (o && i >= o.length) o = void 0;
+ return { value: o && o[i++], done: !o };
+ }
+ };
+ throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
+}
+
+function __read(o, n) {
+ var m = typeof Symbol === "function" && o[Symbol.iterator];
+ if (!m) return o;
+ var i = m.call(o), r, ar = [], e;
+ try {
+ while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
+ }
+ catch (error) { e = { error: error }; }
+ finally {
+ try {
+ if (r && !r.done && (m = i["return"])) m.call(i);
+ }
+ finally { if (e) throw e.error; }
+ }
+ return ar;
+}
+
+/** @deprecated */
+function __spread() {
+ for (var ar = [], i = 0; i < arguments.length; i++)
+ ar = ar.concat(__read(arguments[i]));
+ return ar;
+}
+
+/** @deprecated */
+function __spreadArrays() {
+ for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
+ for (var r = Array(s), k = 0, i = 0; i < il; i++)
+ for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
+ r[k] = a[j];
+ return r;
+}
+
+function __spreadArray(to, from, pack) {
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
+ if (ar || !(i in from)) {
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
+ ar[i] = from[i];
+ }
+ }
+ return to.concat(ar || Array.prototype.slice.call(from));
+}
+
+function __await(v) {
+ return this instanceof __await ? (this.v = v, this) : new __await(v);
+}
+
+function __asyncGenerator(thisArg, _arguments, generator) {
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
+ var g = generator.apply(thisArg, _arguments || []), i, q = [];
+ return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
+ function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
+ function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
+ function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
+ function fulfill(value) { resume("next", value); }
+ function reject(value) { resume("throw", value); }
+ function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
+}
+
+function __asyncDelegator(o) {
+ var i, p;
+ return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
+ function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
+}
+
+function __asyncValues(o) {
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
+ var m = o[Symbol.asyncIterator], i;
+ return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
+ function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
+ function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
+}
+
+function __makeTemplateObject(cooked, raw) {
+ if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
+ return cooked;
+};
+
+var __setModuleDefault = Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+};
+
+function __importStar(mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+}
+
+function __importDefault(mod) {
+ return (mod && mod.__esModule) ? mod : { default: mod };
+}
+
+function __classPrivateFieldGet(receiver, state, kind, f) {
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
+}
+
+function __classPrivateFieldSet(receiver, state, value, kind, f) {
+ if (kind === "m") throw new TypeError("Private method is not writable");
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
+}
/***/ }),
@@ -1701,224 +1701,224 @@ __webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__importDefault", function() { return __importDefault; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__classPrivateFieldGet", function() { return __classPrivateFieldGet; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__classPrivateFieldSet", function() { return __classPrivateFieldSet; });
-/*! *****************************************************************************
-Copyright (c) Microsoft Corporation.
-
-Permission to use, copy, modify, and/or distribute this software for any
-purpose with or without fee is hereby granted.
-
-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
-REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
-INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
-LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
-OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-PERFORMANCE OF THIS SOFTWARE.
-***************************************************************************** */
-/* global Reflect, Promise */
-
-var extendStatics = function(d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
- return extendStatics(d, b);
-};
-
-function __extends(d, b) {
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
-}
-
-var __assign = function() {
- __assign = Object.assign || function __assign(t) {
- for (var s, i = 1, n = arguments.length; i < n; i++) {
- s = arguments[i];
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
- }
- return t;
- }
- return __assign.apply(this, arguments);
-}
-
-function __rest(s, e) {
- var t = {};
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
- t[p] = s[p];
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
- t[p[i]] = s[p[i]];
- }
- return t;
-}
-
-function __decorate(decorators, target, key, desc) {
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
- return c > 3 && r && Object.defineProperty(target, key, r), r;
-}
-
-function __param(paramIndex, decorator) {
- return function (target, key) { decorator(target, key, paramIndex); }
-}
-
-function __metadata(metadataKey, metadataValue) {
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
-}
-
-function __awaiter(thisArg, _arguments, P, generator) {
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
- return new (P || (P = Promise))(function (resolve, reject) {
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
- step((generator = generator.apply(thisArg, _arguments || [])).next());
- });
-}
-
-function __generator(thisArg, body) {
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
- function verb(n) { return function (v) { return step([n, v]); }; }
- function step(op) {
- if (f) throw new TypeError("Generator is already executing.");
- while (_) try {
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
- if (y = 0, t) op = [op[0] & 2, t.value];
- switch (op[0]) {
- case 0: case 1: t = op; break;
- case 4: _.label++; return { value: op[1], done: false };
- case 5: _.label++; y = op[1]; op = [0]; continue;
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
- default:
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
- if (t[2]) _.ops.pop();
- _.trys.pop(); continue;
- }
- op = body.call(thisArg, _);
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
- }
-}
-
-function __createBinding(o, m, k, k2) {
- if (k2 === undefined) k2 = k;
- o[k2] = m[k];
-}
-
-function __exportStar(m, exports) {
- for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) exports[p] = m[p];
-}
-
-function __values(o) {
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
- if (m) return m.call(o);
- if (o && typeof o.length === "number") return {
- next: function () {
- if (o && i >= o.length) o = void 0;
- return { value: o && o[i++], done: !o };
- }
- };
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
-}
-
-function __read(o, n) {
- var m = typeof Symbol === "function" && o[Symbol.iterator];
- if (!m) return o;
- var i = m.call(o), r, ar = [], e;
- try {
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
- }
- catch (error) { e = { error: error }; }
- finally {
- try {
- if (r && !r.done && (m = i["return"])) m.call(i);
- }
- finally { if (e) throw e.error; }
- }
- return ar;
-}
-
-function __spread() {
- for (var ar = [], i = 0; i < arguments.length; i++)
- ar = ar.concat(__read(arguments[i]));
- return ar;
-}
-
-function __spreadArrays() {
- for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
- for (var r = Array(s), k = 0, i = 0; i < il; i++)
- for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
- r[k] = a[j];
- return r;
-};
-
-function __await(v) {
- return this instanceof __await ? (this.v = v, this) : new __await(v);
-}
-
-function __asyncGenerator(thisArg, _arguments, generator) {
- if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
- var g = generator.apply(thisArg, _arguments || []), i, q = [];
- return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
- function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
- function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
- function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
- function fulfill(value) { resume("next", value); }
- function reject(value) { resume("throw", value); }
- function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
-}
-
-function __asyncDelegator(o) {
- var i, p;
- return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
- function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
-}
-
-function __asyncValues(o) {
- if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
- var m = o[Symbol.asyncIterator], i;
- return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
- function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
- function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
-}
-
-function __makeTemplateObject(cooked, raw) {
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
- return cooked;
-};
-
-function __importStar(mod) {
- if (mod && mod.__esModule) return mod;
- var result = {};
- if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
- result.default = mod;
- return result;
-}
-
-function __importDefault(mod) {
- return (mod && mod.__esModule) ? mod : { default: mod };
-}
-
-function __classPrivateFieldGet(receiver, privateMap) {
- if (!privateMap.has(receiver)) {
- throw new TypeError("attempted to get private field on non-instance");
- }
- return privateMap.get(receiver);
-}
-
-function __classPrivateFieldSet(receiver, privateMap, value) {
- if (!privateMap.has(receiver)) {
- throw new TypeError("attempted to set private field on non-instance");
- }
- privateMap.set(receiver, value);
- return value;
-}
+/*! *****************************************************************************
+Copyright (c) Microsoft Corporation.
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
+REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
+AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
+INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
+OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+PERFORMANCE OF THIS SOFTWARE.
+***************************************************************************** */
+/* global Reflect, Promise */
+
+var extendStatics = function(d, b) {
+ extendStatics = Object.setPrototypeOf ||
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
+ return extendStatics(d, b);
+};
+
+function __extends(d, b) {
+ extendStatics(d, b);
+ function __() { this.constructor = d; }
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+}
+
+var __assign = function() {
+ __assign = Object.assign || function __assign(t) {
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
+ s = arguments[i];
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
+ }
+ return t;
+ }
+ return __assign.apply(this, arguments);
+}
+
+function __rest(s, e) {
+ var t = {};
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
+ t[p] = s[p];
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
+ t[p[i]] = s[p[i]];
+ }
+ return t;
+}
+
+function __decorate(decorators, target, key, desc) {
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
+}
+
+function __param(paramIndex, decorator) {
+ return function (target, key) { decorator(target, key, paramIndex); }
+}
+
+function __metadata(metadataKey, metadataValue) {
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
+}
+
+function __awaiter(thisArg, _arguments, P, generator) {
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
+ return new (P || (P = Promise))(function (resolve, reject) {
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
+ });
+}
+
+function __generator(thisArg, body) {
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
+ function verb(n) { return function (v) { return step([n, v]); }; }
+ function step(op) {
+ if (f) throw new TypeError("Generator is already executing.");
+ while (_) try {
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
+ if (y = 0, t) op = [op[0] & 2, t.value];
+ switch (op[0]) {
+ case 0: case 1: t = op; break;
+ case 4: _.label++; return { value: op[1], done: false };
+ case 5: _.label++; y = op[1]; op = [0]; continue;
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
+ default:
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
+ if (t[2]) _.ops.pop();
+ _.trys.pop(); continue;
+ }
+ op = body.call(thisArg, _);
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
+ }
+}
+
+function __createBinding(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}
+
+function __exportStar(m, exports) {
+ for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) exports[p] = m[p];
+}
+
+function __values(o) {
+ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
+ if (m) return m.call(o);
+ if (o && typeof o.length === "number") return {
+ next: function () {
+ if (o && i >= o.length) o = void 0;
+ return { value: o && o[i++], done: !o };
+ }
+ };
+ throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
+}
+
+function __read(o, n) {
+ var m = typeof Symbol === "function" && o[Symbol.iterator];
+ if (!m) return o;
+ var i = m.call(o), r, ar = [], e;
+ try {
+ while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
+ }
+ catch (error) { e = { error: error }; }
+ finally {
+ try {
+ if (r && !r.done && (m = i["return"])) m.call(i);
+ }
+ finally { if (e) throw e.error; }
+ }
+ return ar;
+}
+
+function __spread() {
+ for (var ar = [], i = 0; i < arguments.length; i++)
+ ar = ar.concat(__read(arguments[i]));
+ return ar;
+}
+
+function __spreadArrays() {
+ for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
+ for (var r = Array(s), k = 0, i = 0; i < il; i++)
+ for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
+ r[k] = a[j];
+ return r;
+};
+
+function __await(v) {
+ return this instanceof __await ? (this.v = v, this) : new __await(v);
+}
+
+function __asyncGenerator(thisArg, _arguments, generator) {
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
+ var g = generator.apply(thisArg, _arguments || []), i, q = [];
+ return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
+ function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
+ function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
+ function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
+ function fulfill(value) { resume("next", value); }
+ function reject(value) { resume("throw", value); }
+ function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
+}
+
+function __asyncDelegator(o) {
+ var i, p;
+ return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
+ function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
+}
+
+function __asyncValues(o) {
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
+ var m = o[Symbol.asyncIterator], i;
+ return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
+ function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
+ function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
+}
+
+function __makeTemplateObject(cooked, raw) {
+ if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
+ return cooked;
+};
+
+function __importStar(mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
+ result.default = mod;
+ return result;
+}
+
+function __importDefault(mod) {
+ return (mod && mod.__esModule) ? mod : { default: mod };
+}
+
+function __classPrivateFieldGet(receiver, privateMap) {
+ if (!privateMap.has(receiver)) {
+ throw new TypeError("attempted to get private field on non-instance");
+ }
+ return privateMap.get(receiver);
+}
+
+function __classPrivateFieldSet(receiver, privateMap, value) {
+ if (!privateMap.has(receiver)) {
+ throw new TypeError("attempted to set private field on non-instance");
+ }
+ privateMap.set(receiver, value);
+ return value;
+}
/***/ }),
@@ -8322,158 +8322,158 @@ convert.rgb.gray = function (rgb) {
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-
-module.exports = {
- "aliceblue": [240, 248, 255],
- "antiquewhite": [250, 235, 215],
- "aqua": [0, 255, 255],
- "aquamarine": [127, 255, 212],
- "azure": [240, 255, 255],
- "beige": [245, 245, 220],
- "bisque": [255, 228, 196],
- "black": [0, 0, 0],
- "blanchedalmond": [255, 235, 205],
- "blue": [0, 0, 255],
- "blueviolet": [138, 43, 226],
- "brown": [165, 42, 42],
- "burlywood": [222, 184, 135],
- "cadetblue": [95, 158, 160],
- "chartreuse": [127, 255, 0],
- "chocolate": [210, 105, 30],
- "coral": [255, 127, 80],
- "cornflowerblue": [100, 149, 237],
- "cornsilk": [255, 248, 220],
- "crimson": [220, 20, 60],
- "cyan": [0, 255, 255],
- "darkblue": [0, 0, 139],
- "darkcyan": [0, 139, 139],
- "darkgoldenrod": [184, 134, 11],
- "darkgray": [169, 169, 169],
- "darkgreen": [0, 100, 0],
- "darkgrey": [169, 169, 169],
- "darkkhaki": [189, 183, 107],
- "darkmagenta": [139, 0, 139],
- "darkolivegreen": [85, 107, 47],
- "darkorange": [255, 140, 0],
- "darkorchid": [153, 50, 204],
- "darkred": [139, 0, 0],
- "darksalmon": [233, 150, 122],
- "darkseagreen": [143, 188, 143],
- "darkslateblue": [72, 61, 139],
- "darkslategray": [47, 79, 79],
- "darkslategrey": [47, 79, 79],
- "darkturquoise": [0, 206, 209],
- "darkviolet": [148, 0, 211],
- "deeppink": [255, 20, 147],
- "deepskyblue": [0, 191, 255],
- "dimgray": [105, 105, 105],
- "dimgrey": [105, 105, 105],
- "dodgerblue": [30, 144, 255],
- "firebrick": [178, 34, 34],
- "floralwhite": [255, 250, 240],
- "forestgreen": [34, 139, 34],
- "fuchsia": [255, 0, 255],
- "gainsboro": [220, 220, 220],
- "ghostwhite": [248, 248, 255],
- "gold": [255, 215, 0],
- "goldenrod": [218, 165, 32],
- "gray": [128, 128, 128],
- "green": [0, 128, 0],
- "greenyellow": [173, 255, 47],
- "grey": [128, 128, 128],
- "honeydew": [240, 255, 240],
- "hotpink": [255, 105, 180],
- "indianred": [205, 92, 92],
- "indigo": [75, 0, 130],
- "ivory": [255, 255, 240],
- "khaki": [240, 230, 140],
- "lavender": [230, 230, 250],
- "lavenderblush": [255, 240, 245],
- "lawngreen": [124, 252, 0],
- "lemonchiffon": [255, 250, 205],
- "lightblue": [173, 216, 230],
- "lightcoral": [240, 128, 128],
- "lightcyan": [224, 255, 255],
- "lightgoldenrodyellow": [250, 250, 210],
- "lightgray": [211, 211, 211],
- "lightgreen": [144, 238, 144],
- "lightgrey": [211, 211, 211],
- "lightpink": [255, 182, 193],
- "lightsalmon": [255, 160, 122],
- "lightseagreen": [32, 178, 170],
- "lightskyblue": [135, 206, 250],
- "lightslategray": [119, 136, 153],
- "lightslategrey": [119, 136, 153],
- "lightsteelblue": [176, 196, 222],
- "lightyellow": [255, 255, 224],
- "lime": [0, 255, 0],
- "limegreen": [50, 205, 50],
- "linen": [250, 240, 230],
- "magenta": [255, 0, 255],
- "maroon": [128, 0, 0],
- "mediumaquamarine": [102, 205, 170],
- "mediumblue": [0, 0, 205],
- "mediumorchid": [186, 85, 211],
- "mediumpurple": [147, 112, 219],
- "mediumseagreen": [60, 179, 113],
- "mediumslateblue": [123, 104, 238],
- "mediumspringgreen": [0, 250, 154],
- "mediumturquoise": [72, 209, 204],
- "mediumvioletred": [199, 21, 133],
- "midnightblue": [25, 25, 112],
- "mintcream": [245, 255, 250],
- "mistyrose": [255, 228, 225],
- "moccasin": [255, 228, 181],
- "navajowhite": [255, 222, 173],
- "navy": [0, 0, 128],
- "oldlace": [253, 245, 230],
- "olive": [128, 128, 0],
- "olivedrab": [107, 142, 35],
- "orange": [255, 165, 0],
- "orangered": [255, 69, 0],
- "orchid": [218, 112, 214],
- "palegoldenrod": [238, 232, 170],
- "palegreen": [152, 251, 152],
- "paleturquoise": [175, 238, 238],
- "palevioletred": [219, 112, 147],
- "papayawhip": [255, 239, 213],
- "peachpuff": [255, 218, 185],
- "peru": [205, 133, 63],
- "pink": [255, 192, 203],
- "plum": [221, 160, 221],
- "powderblue": [176, 224, 230],
- "purple": [128, 0, 128],
- "rebeccapurple": [102, 51, 153],
- "red": [255, 0, 0],
- "rosybrown": [188, 143, 143],
- "royalblue": [65, 105, 225],
- "saddlebrown": [139, 69, 19],
- "salmon": [250, 128, 114],
- "sandybrown": [244, 164, 96],
- "seagreen": [46, 139, 87],
- "seashell": [255, 245, 238],
- "sienna": [160, 82, 45],
- "silver": [192, 192, 192],
- "skyblue": [135, 206, 235],
- "slateblue": [106, 90, 205],
- "slategray": [112, 128, 144],
- "slategrey": [112, 128, 144],
- "snow": [255, 250, 250],
- "springgreen": [0, 255, 127],
- "steelblue": [70, 130, 180],
- "tan": [210, 180, 140],
- "teal": [0, 128, 128],
- "thistle": [216, 191, 216],
- "tomato": [255, 99, 71],
- "turquoise": [64, 224, 208],
- "violet": [238, 130, 238],
- "wheat": [245, 222, 179],
- "white": [255, 255, 255],
- "whitesmoke": [245, 245, 245],
- "yellow": [255, 255, 0],
- "yellowgreen": [154, 205, 50]
-};
+
+
+module.exports = {
+ "aliceblue": [240, 248, 255],
+ "antiquewhite": [250, 235, 215],
+ "aqua": [0, 255, 255],
+ "aquamarine": [127, 255, 212],
+ "azure": [240, 255, 255],
+ "beige": [245, 245, 220],
+ "bisque": [255, 228, 196],
+ "black": [0, 0, 0],
+ "blanchedalmond": [255, 235, 205],
+ "blue": [0, 0, 255],
+ "blueviolet": [138, 43, 226],
+ "brown": [165, 42, 42],
+ "burlywood": [222, 184, 135],
+ "cadetblue": [95, 158, 160],
+ "chartreuse": [127, 255, 0],
+ "chocolate": [210, 105, 30],
+ "coral": [255, 127, 80],
+ "cornflowerblue": [100, 149, 237],
+ "cornsilk": [255, 248, 220],
+ "crimson": [220, 20, 60],
+ "cyan": [0, 255, 255],
+ "darkblue": [0, 0, 139],
+ "darkcyan": [0, 139, 139],
+ "darkgoldenrod": [184, 134, 11],
+ "darkgray": [169, 169, 169],
+ "darkgreen": [0, 100, 0],
+ "darkgrey": [169, 169, 169],
+ "darkkhaki": [189, 183, 107],
+ "darkmagenta": [139, 0, 139],
+ "darkolivegreen": [85, 107, 47],
+ "darkorange": [255, 140, 0],
+ "darkorchid": [153, 50, 204],
+ "darkred": [139, 0, 0],
+ "darksalmon": [233, 150, 122],
+ "darkseagreen": [143, 188, 143],
+ "darkslateblue": [72, 61, 139],
+ "darkslategray": [47, 79, 79],
+ "darkslategrey": [47, 79, 79],
+ "darkturquoise": [0, 206, 209],
+ "darkviolet": [148, 0, 211],
+ "deeppink": [255, 20, 147],
+ "deepskyblue": [0, 191, 255],
+ "dimgray": [105, 105, 105],
+ "dimgrey": [105, 105, 105],
+ "dodgerblue": [30, 144, 255],
+ "firebrick": [178, 34, 34],
+ "floralwhite": [255, 250, 240],
+ "forestgreen": [34, 139, 34],
+ "fuchsia": [255, 0, 255],
+ "gainsboro": [220, 220, 220],
+ "ghostwhite": [248, 248, 255],
+ "gold": [255, 215, 0],
+ "goldenrod": [218, 165, 32],
+ "gray": [128, 128, 128],
+ "green": [0, 128, 0],
+ "greenyellow": [173, 255, 47],
+ "grey": [128, 128, 128],
+ "honeydew": [240, 255, 240],
+ "hotpink": [255, 105, 180],
+ "indianred": [205, 92, 92],
+ "indigo": [75, 0, 130],
+ "ivory": [255, 255, 240],
+ "khaki": [240, 230, 140],
+ "lavender": [230, 230, 250],
+ "lavenderblush": [255, 240, 245],
+ "lawngreen": [124, 252, 0],
+ "lemonchiffon": [255, 250, 205],
+ "lightblue": [173, 216, 230],
+ "lightcoral": [240, 128, 128],
+ "lightcyan": [224, 255, 255],
+ "lightgoldenrodyellow": [250, 250, 210],
+ "lightgray": [211, 211, 211],
+ "lightgreen": [144, 238, 144],
+ "lightgrey": [211, 211, 211],
+ "lightpink": [255, 182, 193],
+ "lightsalmon": [255, 160, 122],
+ "lightseagreen": [32, 178, 170],
+ "lightskyblue": [135, 206, 250],
+ "lightslategray": [119, 136, 153],
+ "lightslategrey": [119, 136, 153],
+ "lightsteelblue": [176, 196, 222],
+ "lightyellow": [255, 255, 224],
+ "lime": [0, 255, 0],
+ "limegreen": [50, 205, 50],
+ "linen": [250, 240, 230],
+ "magenta": [255, 0, 255],
+ "maroon": [128, 0, 0],
+ "mediumaquamarine": [102, 205, 170],
+ "mediumblue": [0, 0, 205],
+ "mediumorchid": [186, 85, 211],
+ "mediumpurple": [147, 112, 219],
+ "mediumseagreen": [60, 179, 113],
+ "mediumslateblue": [123, 104, 238],
+ "mediumspringgreen": [0, 250, 154],
+ "mediumturquoise": [72, 209, 204],
+ "mediumvioletred": [199, 21, 133],
+ "midnightblue": [25, 25, 112],
+ "mintcream": [245, 255, 250],
+ "mistyrose": [255, 228, 225],
+ "moccasin": [255, 228, 181],
+ "navajowhite": [255, 222, 173],
+ "navy": [0, 0, 128],
+ "oldlace": [253, 245, 230],
+ "olive": [128, 128, 0],
+ "olivedrab": [107, 142, 35],
+ "orange": [255, 165, 0],
+ "orangered": [255, 69, 0],
+ "orchid": [218, 112, 214],
+ "palegoldenrod": [238, 232, 170],
+ "palegreen": [152, 251, 152],
+ "paleturquoise": [175, 238, 238],
+ "palevioletred": [219, 112, 147],
+ "papayawhip": [255, 239, 213],
+ "peachpuff": [255, 218, 185],
+ "peru": [205, 133, 63],
+ "pink": [255, 192, 203],
+ "plum": [221, 160, 221],
+ "powderblue": [176, 224, 230],
+ "purple": [128, 0, 128],
+ "rebeccapurple": [102, 51, 153],
+ "red": [255, 0, 0],
+ "rosybrown": [188, 143, 143],
+ "royalblue": [65, 105, 225],
+ "saddlebrown": [139, 69, 19],
+ "salmon": [250, 128, 114],
+ "sandybrown": [244, 164, 96],
+ "seagreen": [46, 139, 87],
+ "seashell": [255, 245, 238],
+ "sienna": [160, 82, 45],
+ "silver": [192, 192, 192],
+ "skyblue": [135, 206, 235],
+ "slateblue": [106, 90, 205],
+ "slategray": [112, 128, 144],
+ "slategrey": [112, 128, 144],
+ "snow": [255, 250, 250],
+ "springgreen": [0, 255, 127],
+ "steelblue": [70, 130, 180],
+ "tan": [210, 180, 140],
+ "teal": [0, 128, 128],
+ "thistle": [216, 191, 216],
+ "tomato": [255, 99, 71],
+ "turquoise": [64, 224, 208],
+ "violet": [238, 130, 238],
+ "wheat": [245, 222, 179],
+ "white": [255, 255, 255],
+ "whitesmoke": [245, 245, 245],
+ "yellow": [255, 255, 0],
+ "yellowgreen": [154, 205, 50]
+};
/***/ }),
@@ -10848,58 +10848,58 @@ mkdirP.sync = function sync (p, opts, made) {
/* 142 */
/***/ (function(module, exports) {
-exports.replaceDollarWithPercentPair = replaceDollarWithPercentPair
-exports.convertToSetCommand = convertToSetCommand
-exports.convertToSetCommands = convertToSetCommands
-
-function convertToSetCommand(key, value) {
- var line = ""
- key = key || ""
- key = key.trim()
- value = value || ""
- value = value.trim()
- if(key && value && value.length > 0) {
- line = "@SET " + key + "=" + replaceDollarWithPercentPair(value) + "\r\n"
- }
- return line
-}
-
-function extractVariableValuePairs(declarations) {
- var pairs = {}
- declarations.map(function(declaration) {
- var split = declaration.split("=")
- pairs[split[0]]=split[1]
- })
- return pairs
-}
-
-function convertToSetCommands(variableString) {
- var variableValuePairs = extractVariableValuePairs(variableString.split(" "))
- var variableDeclarationsAsBatch = ""
- Object.keys(variableValuePairs).forEach(function (key) {
- variableDeclarationsAsBatch += convertToSetCommand(key, variableValuePairs[key])
- })
- return variableDeclarationsAsBatch
-}
-
-function replaceDollarWithPercentPair(value) {
- var dollarExpressions = /\$\{?([^\$@#\?\- \t{}:]+)\}?/g
- var result = ""
- var startIndex = 0
- value = value || ""
- do {
- var match = dollarExpressions.exec(value)
- if(match) {
- var betweenMatches = value.substring(startIndex, match.index) || ""
- result += betweenMatches + "%" + match[1] + "%"
- startIndex = dollarExpressions.lastIndex
- }
- } while (dollarExpressions.lastIndex > 0)
- result += value.substr(startIndex)
- return result
-}
-
-
+exports.replaceDollarWithPercentPair = replaceDollarWithPercentPair
+exports.convertToSetCommand = convertToSetCommand
+exports.convertToSetCommands = convertToSetCommands
+
+function convertToSetCommand(key, value) {
+ var line = ""
+ key = key || ""
+ key = key.trim()
+ value = value || ""
+ value = value.trim()
+ if(key && value && value.length > 0) {
+ line = "@SET " + key + "=" + replaceDollarWithPercentPair(value) + "\r\n"
+ }
+ return line
+}
+
+function extractVariableValuePairs(declarations) {
+ var pairs = {}
+ declarations.map(function(declaration) {
+ var split = declaration.split("=")
+ pairs[split[0]]=split[1]
+ })
+ return pairs
+}
+
+function convertToSetCommands(variableString) {
+ var variableValuePairs = extractVariableValuePairs(variableString.split(" "))
+ var variableDeclarationsAsBatch = ""
+ Object.keys(variableValuePairs).forEach(function (key) {
+ variableDeclarationsAsBatch += convertToSetCommand(key, variableValuePairs[key])
+ })
+ return variableDeclarationsAsBatch
+}
+
+function replaceDollarWithPercentPair(value) {
+ var dollarExpressions = /\$\{?([^\$@#\?\- \t{}:]+)\}?/g
+ var result = ""
+ var startIndex = 0
+ value = value || ""
+ do {
+ var match = dollarExpressions.exec(value)
+ if(match) {
+ var betweenMatches = value.substring(startIndex, match.index) || ""
+ result += betweenMatches + "%" + match[1] + "%"
+ startIndex = dollarExpressions.lastIndex
+ }
+ } while (dollarExpressions.lastIndex > 0)
+ result += value.substr(startIndex)
+ return result
+}
+
+
/***/ }),
@@ -17661,158 +17661,158 @@ convert.rgb.gray = function (rgb) {
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-
-module.exports = {
- "aliceblue": [240, 248, 255],
- "antiquewhite": [250, 235, 215],
- "aqua": [0, 255, 255],
- "aquamarine": [127, 255, 212],
- "azure": [240, 255, 255],
- "beige": [245, 245, 220],
- "bisque": [255, 228, 196],
- "black": [0, 0, 0],
- "blanchedalmond": [255, 235, 205],
- "blue": [0, 0, 255],
- "blueviolet": [138, 43, 226],
- "brown": [165, 42, 42],
- "burlywood": [222, 184, 135],
- "cadetblue": [95, 158, 160],
- "chartreuse": [127, 255, 0],
- "chocolate": [210, 105, 30],
- "coral": [255, 127, 80],
- "cornflowerblue": [100, 149, 237],
- "cornsilk": [255, 248, 220],
- "crimson": [220, 20, 60],
- "cyan": [0, 255, 255],
- "darkblue": [0, 0, 139],
- "darkcyan": [0, 139, 139],
- "darkgoldenrod": [184, 134, 11],
- "darkgray": [169, 169, 169],
- "darkgreen": [0, 100, 0],
- "darkgrey": [169, 169, 169],
- "darkkhaki": [189, 183, 107],
- "darkmagenta": [139, 0, 139],
- "darkolivegreen": [85, 107, 47],
- "darkorange": [255, 140, 0],
- "darkorchid": [153, 50, 204],
- "darkred": [139, 0, 0],
- "darksalmon": [233, 150, 122],
- "darkseagreen": [143, 188, 143],
- "darkslateblue": [72, 61, 139],
- "darkslategray": [47, 79, 79],
- "darkslategrey": [47, 79, 79],
- "darkturquoise": [0, 206, 209],
- "darkviolet": [148, 0, 211],
- "deeppink": [255, 20, 147],
- "deepskyblue": [0, 191, 255],
- "dimgray": [105, 105, 105],
- "dimgrey": [105, 105, 105],
- "dodgerblue": [30, 144, 255],
- "firebrick": [178, 34, 34],
- "floralwhite": [255, 250, 240],
- "forestgreen": [34, 139, 34],
- "fuchsia": [255, 0, 255],
- "gainsboro": [220, 220, 220],
- "ghostwhite": [248, 248, 255],
- "gold": [255, 215, 0],
- "goldenrod": [218, 165, 32],
- "gray": [128, 128, 128],
- "green": [0, 128, 0],
- "greenyellow": [173, 255, 47],
- "grey": [128, 128, 128],
- "honeydew": [240, 255, 240],
- "hotpink": [255, 105, 180],
- "indianred": [205, 92, 92],
- "indigo": [75, 0, 130],
- "ivory": [255, 255, 240],
- "khaki": [240, 230, 140],
- "lavender": [230, 230, 250],
- "lavenderblush": [255, 240, 245],
- "lawngreen": [124, 252, 0],
- "lemonchiffon": [255, 250, 205],
- "lightblue": [173, 216, 230],
- "lightcoral": [240, 128, 128],
- "lightcyan": [224, 255, 255],
- "lightgoldenrodyellow": [250, 250, 210],
- "lightgray": [211, 211, 211],
- "lightgreen": [144, 238, 144],
- "lightgrey": [211, 211, 211],
- "lightpink": [255, 182, 193],
- "lightsalmon": [255, 160, 122],
- "lightseagreen": [32, 178, 170],
- "lightskyblue": [135, 206, 250],
- "lightslategray": [119, 136, 153],
- "lightslategrey": [119, 136, 153],
- "lightsteelblue": [176, 196, 222],
- "lightyellow": [255, 255, 224],
- "lime": [0, 255, 0],
- "limegreen": [50, 205, 50],
- "linen": [250, 240, 230],
- "magenta": [255, 0, 255],
- "maroon": [128, 0, 0],
- "mediumaquamarine": [102, 205, 170],
- "mediumblue": [0, 0, 205],
- "mediumorchid": [186, 85, 211],
- "mediumpurple": [147, 112, 219],
- "mediumseagreen": [60, 179, 113],
- "mediumslateblue": [123, 104, 238],
- "mediumspringgreen": [0, 250, 154],
- "mediumturquoise": [72, 209, 204],
- "mediumvioletred": [199, 21, 133],
- "midnightblue": [25, 25, 112],
- "mintcream": [245, 255, 250],
- "mistyrose": [255, 228, 225],
- "moccasin": [255, 228, 181],
- "navajowhite": [255, 222, 173],
- "navy": [0, 0, 128],
- "oldlace": [253, 245, 230],
- "olive": [128, 128, 0],
- "olivedrab": [107, 142, 35],
- "orange": [255, 165, 0],
- "orangered": [255, 69, 0],
- "orchid": [218, 112, 214],
- "palegoldenrod": [238, 232, 170],
- "palegreen": [152, 251, 152],
- "paleturquoise": [175, 238, 238],
- "palevioletred": [219, 112, 147],
- "papayawhip": [255, 239, 213],
- "peachpuff": [255, 218, 185],
- "peru": [205, 133, 63],
- "pink": [255, 192, 203],
- "plum": [221, 160, 221],
- "powderblue": [176, 224, 230],
- "purple": [128, 0, 128],
- "rebeccapurple": [102, 51, 153],
- "red": [255, 0, 0],
- "rosybrown": [188, 143, 143],
- "royalblue": [65, 105, 225],
- "saddlebrown": [139, 69, 19],
- "salmon": [250, 128, 114],
- "sandybrown": [244, 164, 96],
- "seagreen": [46, 139, 87],
- "seashell": [255, 245, 238],
- "sienna": [160, 82, 45],
- "silver": [192, 192, 192],
- "skyblue": [135, 206, 235],
- "slateblue": [106, 90, 205],
- "slategray": [112, 128, 144],
- "slategrey": [112, 128, 144],
- "snow": [255, 250, 250],
- "springgreen": [0, 255, 127],
- "steelblue": [70, 130, 180],
- "tan": [210, 180, 140],
- "teal": [0, 128, 128],
- "thistle": [216, 191, 216],
- "tomato": [255, 99, 71],
- "turquoise": [64, 224, 208],
- "violet": [238, 130, 238],
- "wheat": [245, 222, 179],
- "white": [255, 255, 255],
- "whitesmoke": [245, 245, 245],
- "yellow": [255, 255, 0],
- "yellowgreen": [154, 205, 50]
-};
+
+
+module.exports = {
+ "aliceblue": [240, 248, 255],
+ "antiquewhite": [250, 235, 215],
+ "aqua": [0, 255, 255],
+ "aquamarine": [127, 255, 212],
+ "azure": [240, 255, 255],
+ "beige": [245, 245, 220],
+ "bisque": [255, 228, 196],
+ "black": [0, 0, 0],
+ "blanchedalmond": [255, 235, 205],
+ "blue": [0, 0, 255],
+ "blueviolet": [138, 43, 226],
+ "brown": [165, 42, 42],
+ "burlywood": [222, 184, 135],
+ "cadetblue": [95, 158, 160],
+ "chartreuse": [127, 255, 0],
+ "chocolate": [210, 105, 30],
+ "coral": [255, 127, 80],
+ "cornflowerblue": [100, 149, 237],
+ "cornsilk": [255, 248, 220],
+ "crimson": [220, 20, 60],
+ "cyan": [0, 255, 255],
+ "darkblue": [0, 0, 139],
+ "darkcyan": [0, 139, 139],
+ "darkgoldenrod": [184, 134, 11],
+ "darkgray": [169, 169, 169],
+ "darkgreen": [0, 100, 0],
+ "darkgrey": [169, 169, 169],
+ "darkkhaki": [189, 183, 107],
+ "darkmagenta": [139, 0, 139],
+ "darkolivegreen": [85, 107, 47],
+ "darkorange": [255, 140, 0],
+ "darkorchid": [153, 50, 204],
+ "darkred": [139, 0, 0],
+ "darksalmon": [233, 150, 122],
+ "darkseagreen": [143, 188, 143],
+ "darkslateblue": [72, 61, 139],
+ "darkslategray": [47, 79, 79],
+ "darkslategrey": [47, 79, 79],
+ "darkturquoise": [0, 206, 209],
+ "darkviolet": [148, 0, 211],
+ "deeppink": [255, 20, 147],
+ "deepskyblue": [0, 191, 255],
+ "dimgray": [105, 105, 105],
+ "dimgrey": [105, 105, 105],
+ "dodgerblue": [30, 144, 255],
+ "firebrick": [178, 34, 34],
+ "floralwhite": [255, 250, 240],
+ "forestgreen": [34, 139, 34],
+ "fuchsia": [255, 0, 255],
+ "gainsboro": [220, 220, 220],
+ "ghostwhite": [248, 248, 255],
+ "gold": [255, 215, 0],
+ "goldenrod": [218, 165, 32],
+ "gray": [128, 128, 128],
+ "green": [0, 128, 0],
+ "greenyellow": [173, 255, 47],
+ "grey": [128, 128, 128],
+ "honeydew": [240, 255, 240],
+ "hotpink": [255, 105, 180],
+ "indianred": [205, 92, 92],
+ "indigo": [75, 0, 130],
+ "ivory": [255, 255, 240],
+ "khaki": [240, 230, 140],
+ "lavender": [230, 230, 250],
+ "lavenderblush": [255, 240, 245],
+ "lawngreen": [124, 252, 0],
+ "lemonchiffon": [255, 250, 205],
+ "lightblue": [173, 216, 230],
+ "lightcoral": [240, 128, 128],
+ "lightcyan": [224, 255, 255],
+ "lightgoldenrodyellow": [250, 250, 210],
+ "lightgray": [211, 211, 211],
+ "lightgreen": [144, 238, 144],
+ "lightgrey": [211, 211, 211],
+ "lightpink": [255, 182, 193],
+ "lightsalmon": [255, 160, 122],
+ "lightseagreen": [32, 178, 170],
+ "lightskyblue": [135, 206, 250],
+ "lightslategray": [119, 136, 153],
+ "lightslategrey": [119, 136, 153],
+ "lightsteelblue": [176, 196, 222],
+ "lightyellow": [255, 255, 224],
+ "lime": [0, 255, 0],
+ "limegreen": [50, 205, 50],
+ "linen": [250, 240, 230],
+ "magenta": [255, 0, 255],
+ "maroon": [128, 0, 0],
+ "mediumaquamarine": [102, 205, 170],
+ "mediumblue": [0, 0, 205],
+ "mediumorchid": [186, 85, 211],
+ "mediumpurple": [147, 112, 219],
+ "mediumseagreen": [60, 179, 113],
+ "mediumslateblue": [123, 104, 238],
+ "mediumspringgreen": [0, 250, 154],
+ "mediumturquoise": [72, 209, 204],
+ "mediumvioletred": [199, 21, 133],
+ "midnightblue": [25, 25, 112],
+ "mintcream": [245, 255, 250],
+ "mistyrose": [255, 228, 225],
+ "moccasin": [255, 228, 181],
+ "navajowhite": [255, 222, 173],
+ "navy": [0, 0, 128],
+ "oldlace": [253, 245, 230],
+ "olive": [128, 128, 0],
+ "olivedrab": [107, 142, 35],
+ "orange": [255, 165, 0],
+ "orangered": [255, 69, 0],
+ "orchid": [218, 112, 214],
+ "palegoldenrod": [238, 232, 170],
+ "palegreen": [152, 251, 152],
+ "paleturquoise": [175, 238, 238],
+ "palevioletred": [219, 112, 147],
+ "papayawhip": [255, 239, 213],
+ "peachpuff": [255, 218, 185],
+ "peru": [205, 133, 63],
+ "pink": [255, 192, 203],
+ "plum": [221, 160, 221],
+ "powderblue": [176, 224, 230],
+ "purple": [128, 0, 128],
+ "rebeccapurple": [102, 51, 153],
+ "red": [255, 0, 0],
+ "rosybrown": [188, 143, 143],
+ "royalblue": [65, 105, 225],
+ "saddlebrown": [139, 69, 19],
+ "salmon": [250, 128, 114],
+ "sandybrown": [244, 164, 96],
+ "seagreen": [46, 139, 87],
+ "seashell": [255, 245, 238],
+ "sienna": [160, 82, 45],
+ "silver": [192, 192, 192],
+ "skyblue": [135, 206, 235],
+ "slateblue": [106, 90, 205],
+ "slategray": [112, 128, 144],
+ "slategrey": [112, 128, 144],
+ "snow": [255, 250, 250],
+ "springgreen": [0, 255, 127],
+ "steelblue": [70, 130, 180],
+ "tan": [210, 180, 140],
+ "teal": [0, 128, 128],
+ "thistle": [216, 191, 216],
+ "tomato": [255, 99, 71],
+ "turquoise": [64, 224, 208],
+ "violet": [238, 130, 238],
+ "wheat": [245, 222, 179],
+ "white": [255, 255, 255],
+ "whitesmoke": [245, 245, 245],
+ "yellow": [255, 255, 0],
+ "yellowgreen": [154, 205, 50]
+};
/***/ }),
@@ -21376,7 +21376,7 @@ var nodeModulesPaths = __webpack_require__(207);
var normalizeOptions = __webpack_require__(209);
var isCore = __webpack_require__(210);
-var realpathFS = fs.realpath && typeof fs.realpath.native === 'function' ? fs.realpath.native : fs.realpath;
+var realpathFS = process.platform !== 'win32' && fs.realpath && typeof fs.realpath.native === 'function' ? fs.realpath.native : fs.realpath;
var homedir = getHomedir();
var defaultPaths = function () {
@@ -22053,7 +22053,7 @@ module.exports = function bind(that) {
/* 214 */
/***/ (function(module) {
-module.exports = JSON.parse("{\"assert\":true,\"node:assert\":[\">= 14.18 && < 15\",\">= 16\"],\"assert/strict\":\">= 15\",\"node:assert/strict\":\">= 16\",\"async_hooks\":\">= 8\",\"node:async_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"buffer_ieee754\":\">= 0.5 && < 0.9.7\",\"buffer\":true,\"node:buffer\":[\">= 14.18 && < 15\",\">= 16\"],\"child_process\":true,\"node:child_process\":[\">= 14.18 && < 15\",\">= 16\"],\"cluster\":\">= 0.5\",\"node:cluster\":[\">= 14.18 && < 15\",\">= 16\"],\"console\":true,\"node:console\":[\">= 14.18 && < 15\",\">= 16\"],\"constants\":true,\"node:constants\":[\">= 14.18 && < 15\",\">= 16\"],\"crypto\":true,\"node:crypto\":[\">= 14.18 && < 15\",\">= 16\"],\"_debug_agent\":\">= 1 && < 8\",\"_debugger\":\"< 8\",\"dgram\":true,\"node:dgram\":[\">= 14.18 && < 15\",\">= 16\"],\"diagnostics_channel\":[\">= 14.17 && < 15\",\">= 15.1\"],\"node:diagnostics_channel\":[\">= 14.18 && < 15\",\">= 16\"],\"dns\":true,\"node:dns\":[\">= 14.18 && < 15\",\">= 16\"],\"dns/promises\":\">= 15\",\"node:dns/promises\":\">= 16\",\"domain\":\">= 0.7.12\",\"node:domain\":[\">= 14.18 && < 15\",\">= 16\"],\"events\":true,\"node:events\":[\">= 14.18 && < 15\",\">= 16\"],\"freelist\":\"< 6\",\"fs\":true,\"node:fs\":[\">= 14.18 && < 15\",\">= 16\"],\"fs/promises\":[\">= 10 && < 10.1\",\">= 14\"],\"node:fs/promises\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_agent\":\">= 0.11.1\",\"node:_http_agent\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_client\":\">= 0.11.1\",\"node:_http_client\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_common\":\">= 0.11.1\",\"node:_http_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_incoming\":\">= 0.11.1\",\"node:_http_incoming\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_outgoing\":\">= 0.11.1\",\"node:_http_outgoing\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_server\":\">= 0.11.1\",\"node:_http_server\":[\">= 14.18 && < 15\",\">= 16\"],\"http\":true,\"node:http\":[\">= 14.18 && < 15\",\">= 16\"],\"http2\":\">= 8.8\",\"node:http2\":[\">= 14.18 && < 15\",\">= 16\"],\"https\":true,\"node:https\":[\">= 14.18 && < 15\",\">= 16\"],\"inspector\":\">= 8\",\"node:inspector\":[\">= 14.18 && < 15\",\">= 16\"],\"_linklist\":\"< 8\",\"module\":true,\"node:module\":[\">= 14.18 && < 15\",\">= 16\"],\"net\":true,\"node:net\":[\">= 14.18 && < 15\",\">= 16\"],\"node-inspect/lib/_inspect\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_client\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_repl\":\">= 7.6 && < 12\",\"os\":true,\"node:os\":[\">= 14.18 && < 15\",\">= 16\"],\"path\":true,\"node:path\":[\">= 14.18 && < 15\",\">= 16\"],\"path/posix\":\">= 15.3\",\"node:path/posix\":\">= 16\",\"path/win32\":\">= 15.3\",\"node:path/win32\":\">= 16\",\"perf_hooks\":\">= 8.5\",\"node:perf_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"process\":\">= 1\",\"node:process\":[\">= 14.18 && < 15\",\">= 16\"],\"punycode\":\">= 0.5\",\"node:punycode\":[\">= 14.18 && < 15\",\">= 16\"],\"querystring\":true,\"node:querystring\":[\">= 14.18 && < 15\",\">= 16\"],\"readline\":true,\"node:readline\":[\">= 14.18 && < 15\",\">= 16\"],\"readline/promises\":\">= 17\",\"node:readline/promises\":\">= 17\",\"repl\":true,\"node:repl\":[\">= 14.18 && < 15\",\">= 16\"],\"smalloc\":\">= 0.11.5 && < 3\",\"_stream_duplex\":\">= 0.9.4\",\"node:_stream_duplex\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_transform\":\">= 0.9.4\",\"node:_stream_transform\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_wrap\":\">= 1.4.1\",\"node:_stream_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_passthrough\":\">= 0.9.4\",\"node:_stream_passthrough\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_readable\":\">= 0.9.4\",\"node:_stream_readable\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_writable\":\">= 0.9.4\",\"node:_stream_writable\":[\">= 14.18 && < 15\",\">= 16\"],\"stream\":true,\"node:stream\":[\">= 14.18 && < 15\",\">= 16\"],\"stream/consumers\":\">= 16.7\",\"node:stream/consumers\":\">= 16.7\",\"stream/promises\":\">= 15\",\"node:stream/promises\":\">= 16\",\"stream/web\":\">= 16.5\",\"node:stream/web\":\">= 16.5\",\"string_decoder\":true,\"node:string_decoder\":[\">= 14.18 && < 15\",\">= 16\"],\"sys\":[\">= 0.4 && < 0.7\",\">= 0.8\"],\"node:sys\":[\">= 14.18 && < 15\",\">= 16\"],\"timers\":true,\"node:timers\":[\">= 14.18 && < 15\",\">= 16\"],\"timers/promises\":\">= 15\",\"node:timers/promises\":\">= 16\",\"_tls_common\":\">= 0.11.13\",\"node:_tls_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_tls_legacy\":\">= 0.11.3 && < 10\",\"_tls_wrap\":\">= 0.11.3\",\"node:_tls_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"tls\":true,\"node:tls\":[\">= 14.18 && < 15\",\">= 16\"],\"trace_events\":\">= 10\",\"node:trace_events\":[\">= 14.18 && < 15\",\">= 16\"],\"tty\":true,\"node:tty\":[\">= 14.18 && < 15\",\">= 16\"],\"url\":true,\"node:url\":[\">= 14.18 && < 15\",\">= 16\"],\"util\":true,\"node:util\":[\">= 14.18 && < 15\",\">= 16\"],\"util/types\":\">= 15.3\",\"node:util/types\":\">= 16\",\"v8/tools/arguments\":\">= 10 && < 12\",\"v8/tools/codemap\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/consarray\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/csvparser\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/logreader\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/profile_view\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/splaytree\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8\":\">= 1\",\"node:v8\":[\">= 14.18 && < 15\",\">= 16\"],\"vm\":true,\"node:vm\":[\">= 14.18 && < 15\",\">= 16\"],\"wasi\":\">= 13.4 && < 13.5\",\"worker_threads\":\">= 11.7\",\"node:worker_threads\":[\">= 14.18 && < 15\",\">= 16\"],\"zlib\":\">= 0.5\",\"node:zlib\":[\">= 14.18 && < 15\",\">= 16\"]}");
+module.exports = JSON.parse("{\"assert\":true,\"node:assert\":[\">= 14.18 && < 15\",\">= 16\"],\"assert/strict\":\">= 15\",\"node:assert/strict\":\">= 16\",\"async_hooks\":\">= 8\",\"node:async_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"buffer_ieee754\":\">= 0.5 && < 0.9.7\",\"buffer\":true,\"node:buffer\":[\">= 14.18 && < 15\",\">= 16\"],\"child_process\":true,\"node:child_process\":[\">= 14.18 && < 15\",\">= 16\"],\"cluster\":\">= 0.5\",\"node:cluster\":[\">= 14.18 && < 15\",\">= 16\"],\"console\":true,\"node:console\":[\">= 14.18 && < 15\",\">= 16\"],\"constants\":true,\"node:constants\":[\">= 14.18 && < 15\",\">= 16\"],\"crypto\":true,\"node:crypto\":[\">= 14.18 && < 15\",\">= 16\"],\"_debug_agent\":\">= 1 && < 8\",\"_debugger\":\"< 8\",\"dgram\":true,\"node:dgram\":[\">= 14.18 && < 15\",\">= 16\"],\"diagnostics_channel\":[\">= 14.17 && < 15\",\">= 15.1\"],\"node:diagnostics_channel\":[\">= 14.18 && < 15\",\">= 16\"],\"dns\":true,\"node:dns\":[\">= 14.18 && < 15\",\">= 16\"],\"dns/promises\":\">= 15\",\"node:dns/promises\":\">= 16\",\"domain\":\">= 0.7.12\",\"node:domain\":[\">= 14.18 && < 15\",\">= 16\"],\"events\":true,\"node:events\":[\">= 14.18 && < 15\",\">= 16\"],\"freelist\":\"< 6\",\"fs\":true,\"node:fs\":[\">= 14.18 && < 15\",\">= 16\"],\"fs/promises\":[\">= 10 && < 10.1\",\">= 14\"],\"node:fs/promises\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_agent\":\">= 0.11.1\",\"node:_http_agent\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_client\":\">= 0.11.1\",\"node:_http_client\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_common\":\">= 0.11.1\",\"node:_http_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_incoming\":\">= 0.11.1\",\"node:_http_incoming\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_outgoing\":\">= 0.11.1\",\"node:_http_outgoing\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_server\":\">= 0.11.1\",\"node:_http_server\":[\">= 14.18 && < 15\",\">= 16\"],\"http\":true,\"node:http\":[\">= 14.18 && < 15\",\">= 16\"],\"http2\":\">= 8.8\",\"node:http2\":[\">= 14.18 && < 15\",\">= 16\"],\"https\":true,\"node:https\":[\">= 14.18 && < 15\",\">= 16\"],\"inspector\":\">= 8\",\"node:inspector\":[\">= 14.18 && < 15\",\">= 16\"],\"inspector/promises\":[\">= 19\"],\"node:inspector/promises\":[\">= 19\"],\"_linklist\":\"< 8\",\"module\":true,\"node:module\":[\">= 14.18 && < 15\",\">= 16\"],\"net\":true,\"node:net\":[\">= 14.18 && < 15\",\">= 16\"],\"node-inspect/lib/_inspect\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_client\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_repl\":\">= 7.6 && < 12\",\"os\":true,\"node:os\":[\">= 14.18 && < 15\",\">= 16\"],\"path\":true,\"node:path\":[\">= 14.18 && < 15\",\">= 16\"],\"path/posix\":\">= 15.3\",\"node:path/posix\":\">= 16\",\"path/win32\":\">= 15.3\",\"node:path/win32\":\">= 16\",\"perf_hooks\":\">= 8.5\",\"node:perf_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"process\":\">= 1\",\"node:process\":[\">= 14.18 && < 15\",\">= 16\"],\"punycode\":\">= 0.5\",\"node:punycode\":[\">= 14.18 && < 15\",\">= 16\"],\"querystring\":true,\"node:querystring\":[\">= 14.18 && < 15\",\">= 16\"],\"readline\":true,\"node:readline\":[\">= 14.18 && < 15\",\">= 16\"],\"readline/promises\":\">= 17\",\"node:readline/promises\":\">= 17\",\"repl\":true,\"node:repl\":[\">= 14.18 && < 15\",\">= 16\"],\"smalloc\":\">= 0.11.5 && < 3\",\"_stream_duplex\":\">= 0.9.4\",\"node:_stream_duplex\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_transform\":\">= 0.9.4\",\"node:_stream_transform\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_wrap\":\">= 1.4.1\",\"node:_stream_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_passthrough\":\">= 0.9.4\",\"node:_stream_passthrough\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_readable\":\">= 0.9.4\",\"node:_stream_readable\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_writable\":\">= 0.9.4\",\"node:_stream_writable\":[\">= 14.18 && < 15\",\">= 16\"],\"stream\":true,\"node:stream\":[\">= 14.18 && < 15\",\">= 16\"],\"stream/consumers\":\">= 16.7\",\"node:stream/consumers\":\">= 16.7\",\"stream/promises\":\">= 15\",\"node:stream/promises\":\">= 16\",\"stream/web\":\">= 16.5\",\"node:stream/web\":\">= 16.5\",\"string_decoder\":true,\"node:string_decoder\":[\">= 14.18 && < 15\",\">= 16\"],\"sys\":[\">= 0.4 && < 0.7\",\">= 0.8\"],\"node:sys\":[\">= 14.18 && < 15\",\">= 16\"],\"node:test\":[\">= 16.17 && < 17\",\">= 18\"],\"timers\":true,\"node:timers\":[\">= 14.18 && < 15\",\">= 16\"],\"timers/promises\":\">= 15\",\"node:timers/promises\":\">= 16\",\"_tls_common\":\">= 0.11.13\",\"node:_tls_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_tls_legacy\":\">= 0.11.3 && < 10\",\"_tls_wrap\":\">= 0.11.3\",\"node:_tls_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"tls\":true,\"node:tls\":[\">= 14.18 && < 15\",\">= 16\"],\"trace_events\":\">= 10\",\"node:trace_events\":[\">= 14.18 && < 15\",\">= 16\"],\"tty\":true,\"node:tty\":[\">= 14.18 && < 15\",\">= 16\"],\"url\":true,\"node:url\":[\">= 14.18 && < 15\",\">= 16\"],\"util\":true,\"node:util\":[\">= 14.18 && < 15\",\">= 16\"],\"util/types\":\">= 15.3\",\"node:util/types\":\">= 16\",\"v8/tools/arguments\":\">= 10 && < 12\",\"v8/tools/codemap\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/consarray\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/csvparser\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/logreader\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/profile_view\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/splaytree\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8\":\">= 1\",\"node:v8\":[\">= 14.18 && < 15\",\">= 16\"],\"vm\":true,\"node:vm\":[\">= 14.18 && < 15\",\">= 16\"],\"wasi\":\">= 13.4 && < 13.5\",\"worker_threads\":\">= 11.7\",\"node:worker_threads\":[\">= 14.18 && < 15\",\">= 16\"],\"zlib\":\">= 0.5\",\"node:zlib\":[\">= 14.18 && < 15\",\">= 16\"]}");
/***/ }),
/* 215 */
@@ -22117,7 +22117,7 @@ module.exports = core;
/* 216 */
/***/ (function(module) {
-module.exports = JSON.parse("{\"assert\":true,\"node:assert\":[\">= 14.18 && < 15\",\">= 16\"],\"assert/strict\":\">= 15\",\"node:assert/strict\":\">= 16\",\"async_hooks\":\">= 8\",\"node:async_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"buffer_ieee754\":\">= 0.5 && < 0.9.7\",\"buffer\":true,\"node:buffer\":[\">= 14.18 && < 15\",\">= 16\"],\"child_process\":true,\"node:child_process\":[\">= 14.18 && < 15\",\">= 16\"],\"cluster\":\">= 0.5\",\"node:cluster\":[\">= 14.18 && < 15\",\">= 16\"],\"console\":true,\"node:console\":[\">= 14.18 && < 15\",\">= 16\"],\"constants\":true,\"node:constants\":[\">= 14.18 && < 15\",\">= 16\"],\"crypto\":true,\"node:crypto\":[\">= 14.18 && < 15\",\">= 16\"],\"_debug_agent\":\">= 1 && < 8\",\"_debugger\":\"< 8\",\"dgram\":true,\"node:dgram\":[\">= 14.18 && < 15\",\">= 16\"],\"diagnostics_channel\":[\">= 14.17 && < 15\",\">= 15.1\"],\"node:diagnostics_channel\":[\">= 14.18 && < 15\",\">= 16\"],\"dns\":true,\"node:dns\":[\">= 14.18 && < 15\",\">= 16\"],\"dns/promises\":\">= 15\",\"node:dns/promises\":\">= 16\",\"domain\":\">= 0.7.12\",\"node:domain\":[\">= 14.18 && < 15\",\">= 16\"],\"events\":true,\"node:events\":[\">= 14.18 && < 15\",\">= 16\"],\"freelist\":\"< 6\",\"fs\":true,\"node:fs\":[\">= 14.18 && < 15\",\">= 16\"],\"fs/promises\":[\">= 10 && < 10.1\",\">= 14\"],\"node:fs/promises\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_agent\":\">= 0.11.1\",\"node:_http_agent\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_client\":\">= 0.11.1\",\"node:_http_client\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_common\":\">= 0.11.1\",\"node:_http_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_incoming\":\">= 0.11.1\",\"node:_http_incoming\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_outgoing\":\">= 0.11.1\",\"node:_http_outgoing\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_server\":\">= 0.11.1\",\"node:_http_server\":[\">= 14.18 && < 15\",\">= 16\"],\"http\":true,\"node:http\":[\">= 14.18 && < 15\",\">= 16\"],\"http2\":\">= 8.8\",\"node:http2\":[\">= 14.18 && < 15\",\">= 16\"],\"https\":true,\"node:https\":[\">= 14.18 && < 15\",\">= 16\"],\"inspector\":\">= 8\",\"node:inspector\":[\">= 14.18 && < 15\",\">= 16\"],\"_linklist\":\"< 8\",\"module\":true,\"node:module\":[\">= 14.18 && < 15\",\">= 16\"],\"net\":true,\"node:net\":[\">= 14.18 && < 15\",\">= 16\"],\"node-inspect/lib/_inspect\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_client\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_repl\":\">= 7.6 && < 12\",\"os\":true,\"node:os\":[\">= 14.18 && < 15\",\">= 16\"],\"path\":true,\"node:path\":[\">= 14.18 && < 15\",\">= 16\"],\"path/posix\":\">= 15.3\",\"node:path/posix\":\">= 16\",\"path/win32\":\">= 15.3\",\"node:path/win32\":\">= 16\",\"perf_hooks\":\">= 8.5\",\"node:perf_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"process\":\">= 1\",\"node:process\":[\">= 14.18 && < 15\",\">= 16\"],\"punycode\":\">= 0.5\",\"node:punycode\":[\">= 14.18 && < 15\",\">= 16\"],\"querystring\":true,\"node:querystring\":[\">= 14.18 && < 15\",\">= 16\"],\"readline\":true,\"node:readline\":[\">= 14.18 && < 15\",\">= 16\"],\"readline/promises\":\">= 17\",\"node:readline/promises\":\">= 17\",\"repl\":true,\"node:repl\":[\">= 14.18 && < 15\",\">= 16\"],\"smalloc\":\">= 0.11.5 && < 3\",\"_stream_duplex\":\">= 0.9.4\",\"node:_stream_duplex\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_transform\":\">= 0.9.4\",\"node:_stream_transform\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_wrap\":\">= 1.4.1\",\"node:_stream_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_passthrough\":\">= 0.9.4\",\"node:_stream_passthrough\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_readable\":\">= 0.9.4\",\"node:_stream_readable\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_writable\":\">= 0.9.4\",\"node:_stream_writable\":[\">= 14.18 && < 15\",\">= 16\"],\"stream\":true,\"node:stream\":[\">= 14.18 && < 15\",\">= 16\"],\"stream/consumers\":\">= 16.7\",\"node:stream/consumers\":\">= 16.7\",\"stream/promises\":\">= 15\",\"node:stream/promises\":\">= 16\",\"stream/web\":\">= 16.5\",\"node:stream/web\":\">= 16.5\",\"string_decoder\":true,\"node:string_decoder\":[\">= 14.18 && < 15\",\">= 16\"],\"sys\":[\">= 0.4 && < 0.7\",\">= 0.8\"],\"node:sys\":[\">= 14.18 && < 15\",\">= 16\"],\"timers\":true,\"node:timers\":[\">= 14.18 && < 15\",\">= 16\"],\"timers/promises\":\">= 15\",\"node:timers/promises\":\">= 16\",\"_tls_common\":\">= 0.11.13\",\"node:_tls_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_tls_legacy\":\">= 0.11.3 && < 10\",\"_tls_wrap\":\">= 0.11.3\",\"node:_tls_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"tls\":true,\"node:tls\":[\">= 14.18 && < 15\",\">= 16\"],\"trace_events\":\">= 10\",\"node:trace_events\":[\">= 14.18 && < 15\",\">= 16\"],\"tty\":true,\"node:tty\":[\">= 14.18 && < 15\",\">= 16\"],\"url\":true,\"node:url\":[\">= 14.18 && < 15\",\">= 16\"],\"util\":true,\"node:util\":[\">= 14.18 && < 15\",\">= 16\"],\"util/types\":\">= 15.3\",\"node:util/types\":\">= 16\",\"v8/tools/arguments\":\">= 10 && < 12\",\"v8/tools/codemap\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/consarray\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/csvparser\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/logreader\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/profile_view\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/splaytree\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8\":\">= 1\",\"node:v8\":[\">= 14.18 && < 15\",\">= 16\"],\"vm\":true,\"node:vm\":[\">= 14.18 && < 15\",\">= 16\"],\"wasi\":\">= 13.4 && < 13.5\",\"worker_threads\":\">= 11.7\",\"node:worker_threads\":[\">= 14.18 && < 15\",\">= 16\"],\"zlib\":\">= 0.5\",\"node:zlib\":[\">= 14.18 && < 15\",\">= 16\"]}");
+module.exports = JSON.parse("{\"assert\":true,\"node:assert\":[\">= 14.18 && < 15\",\">= 16\"],\"assert/strict\":\">= 15\",\"node:assert/strict\":\">= 16\",\"async_hooks\":\">= 8\",\"node:async_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"buffer_ieee754\":\">= 0.5 && < 0.9.7\",\"buffer\":true,\"node:buffer\":[\">= 14.18 && < 15\",\">= 16\"],\"child_process\":true,\"node:child_process\":[\">= 14.18 && < 15\",\">= 16\"],\"cluster\":\">= 0.5\",\"node:cluster\":[\">= 14.18 && < 15\",\">= 16\"],\"console\":true,\"node:console\":[\">= 14.18 && < 15\",\">= 16\"],\"constants\":true,\"node:constants\":[\">= 14.18 && < 15\",\">= 16\"],\"crypto\":true,\"node:crypto\":[\">= 14.18 && < 15\",\">= 16\"],\"_debug_agent\":\">= 1 && < 8\",\"_debugger\":\"< 8\",\"dgram\":true,\"node:dgram\":[\">= 14.18 && < 15\",\">= 16\"],\"diagnostics_channel\":[\">= 14.17 && < 15\",\">= 15.1\"],\"node:diagnostics_channel\":[\">= 14.18 && < 15\",\">= 16\"],\"dns\":true,\"node:dns\":[\">= 14.18 && < 15\",\">= 16\"],\"dns/promises\":\">= 15\",\"node:dns/promises\":\">= 16\",\"domain\":\">= 0.7.12\",\"node:domain\":[\">= 14.18 && < 15\",\">= 16\"],\"events\":true,\"node:events\":[\">= 14.18 && < 15\",\">= 16\"],\"freelist\":\"< 6\",\"fs\":true,\"node:fs\":[\">= 14.18 && < 15\",\">= 16\"],\"fs/promises\":[\">= 10 && < 10.1\",\">= 14\"],\"node:fs/promises\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_agent\":\">= 0.11.1\",\"node:_http_agent\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_client\":\">= 0.11.1\",\"node:_http_client\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_common\":\">= 0.11.1\",\"node:_http_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_incoming\":\">= 0.11.1\",\"node:_http_incoming\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_outgoing\":\">= 0.11.1\",\"node:_http_outgoing\":[\">= 14.18 && < 15\",\">= 16\"],\"_http_server\":\">= 0.11.1\",\"node:_http_server\":[\">= 14.18 && < 15\",\">= 16\"],\"http\":true,\"node:http\":[\">= 14.18 && < 15\",\">= 16\"],\"http2\":\">= 8.8\",\"node:http2\":[\">= 14.18 && < 15\",\">= 16\"],\"https\":true,\"node:https\":[\">= 14.18 && < 15\",\">= 16\"],\"inspector\":\">= 8\",\"node:inspector\":[\">= 14.18 && < 15\",\">= 16\"],\"_linklist\":\"< 8\",\"module\":true,\"node:module\":[\">= 14.18 && < 15\",\">= 16\"],\"net\":true,\"node:net\":[\">= 14.18 && < 15\",\">= 16\"],\"node-inspect/lib/_inspect\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_client\":\">= 7.6 && < 12\",\"node-inspect/lib/internal/inspect_repl\":\">= 7.6 && < 12\",\"os\":true,\"node:os\":[\">= 14.18 && < 15\",\">= 16\"],\"path\":true,\"node:path\":[\">= 14.18 && < 15\",\">= 16\"],\"path/posix\":\">= 15.3\",\"node:path/posix\":\">= 16\",\"path/win32\":\">= 15.3\",\"node:path/win32\":\">= 16\",\"perf_hooks\":\">= 8.5\",\"node:perf_hooks\":[\">= 14.18 && < 15\",\">= 16\"],\"process\":\">= 1\",\"node:process\":[\">= 14.18 && < 15\",\">= 16\"],\"punycode\":\">= 0.5\",\"node:punycode\":[\">= 14.18 && < 15\",\">= 16\"],\"querystring\":true,\"node:querystring\":[\">= 14.18 && < 15\",\">= 16\"],\"readline\":true,\"node:readline\":[\">= 14.18 && < 15\",\">= 16\"],\"readline/promises\":\">= 17\",\"node:readline/promises\":\">= 17\",\"repl\":true,\"node:repl\":[\">= 14.18 && < 15\",\">= 16\"],\"smalloc\":\">= 0.11.5 && < 3\",\"_stream_duplex\":\">= 0.9.4\",\"node:_stream_duplex\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_transform\":\">= 0.9.4\",\"node:_stream_transform\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_wrap\":\">= 1.4.1\",\"node:_stream_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_passthrough\":\">= 0.9.4\",\"node:_stream_passthrough\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_readable\":\">= 0.9.4\",\"node:_stream_readable\":[\">= 14.18 && < 15\",\">= 16\"],\"_stream_writable\":\">= 0.9.4\",\"node:_stream_writable\":[\">= 14.18 && < 15\",\">= 16\"],\"stream\":true,\"node:stream\":[\">= 14.18 && < 15\",\">= 16\"],\"stream/consumers\":\">= 16.7\",\"node:stream/consumers\":\">= 16.7\",\"stream/promises\":\">= 15\",\"node:stream/promises\":\">= 16\",\"stream/web\":\">= 16.5\",\"node:stream/web\":\">= 16.5\",\"string_decoder\":true,\"node:string_decoder\":[\">= 14.18 && < 15\",\">= 16\"],\"sys\":[\">= 0.4 && < 0.7\",\">= 0.8\"],\"node:sys\":[\">= 14.18 && < 15\",\">= 16\"],\"node:test\":\">= 18\",\"timers\":true,\"node:timers\":[\">= 14.18 && < 15\",\">= 16\"],\"timers/promises\":\">= 15\",\"node:timers/promises\":\">= 16\",\"_tls_common\":\">= 0.11.13\",\"node:_tls_common\":[\">= 14.18 && < 15\",\">= 16\"],\"_tls_legacy\":\">= 0.11.3 && < 10\",\"_tls_wrap\":\">= 0.11.3\",\"node:_tls_wrap\":[\">= 14.18 && < 15\",\">= 16\"],\"tls\":true,\"node:tls\":[\">= 14.18 && < 15\",\">= 16\"],\"trace_events\":\">= 10\",\"node:trace_events\":[\">= 14.18 && < 15\",\">= 16\"],\"tty\":true,\"node:tty\":[\">= 14.18 && < 15\",\">= 16\"],\"url\":true,\"node:url\":[\">= 14.18 && < 15\",\">= 16\"],\"util\":true,\"node:util\":[\">= 14.18 && < 15\",\">= 16\"],\"util/types\":\">= 15.3\",\"node:util/types\":\">= 16\",\"v8/tools/arguments\":\">= 10 && < 12\",\"v8/tools/codemap\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/consarray\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/csvparser\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/logreader\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/profile_view\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8/tools/splaytree\":[\">= 4.4 && < 5\",\">= 5.2 && < 12\"],\"v8\":\">= 1\",\"node:v8\":[\">= 14.18 && < 15\",\">= 16\"],\"vm\":true,\"node:vm\":[\">= 14.18 && < 15\",\">= 16\"],\"wasi\":\">= 13.4 && < 13.5\",\"worker_threads\":\">= 11.7\",\"node:worker_threads\":[\">= 14.18 && < 15\",\">= 16\"],\"zlib\":\">= 0.5\",\"node:zlib\":[\">= 14.18 && < 15\",\">= 16\"]}");
/***/ }),
/* 217 */
@@ -22142,7 +22142,7 @@ var caller = __webpack_require__(206);
var nodeModulesPaths = __webpack_require__(207);
var normalizeOptions = __webpack_require__(209);
-var realpathFS = fs.realpathSync && typeof fs.realpathSync.native === 'function' ? fs.realpathSync.native : fs.realpathSync;
+var realpathFS = process.platform !== 'win32' && fs.realpathSync && typeof fs.realpathSync.native === 'function' ? fs.realpathSync.native : fs.realpathSync;
var homedir = getHomedir();
var defaultPaths = function () {
@@ -56551,9 +56551,9 @@ exports.OpenSearchDashboards = OpenSearchDashboards;
"use strict";
const minimatch = __webpack_require__(150);
-const arrayUnion = __webpack_require__(513);
-const arrayDiffer = __webpack_require__(514);
-const arrify = __webpack_require__(515);
+const arrayUnion = __webpack_require__(299);
+const arrayDiffer = __webpack_require__(513);
+const arrify = __webpack_require__(514);
module.exports = (list, patterns, options = {}) => {
list = arrify(list);
@@ -56583,18 +56583,6 @@ module.exports = (list, patterns, options = {}) => {
"use strict";
-module.exports = (...arguments_) => {
- return [...new Set([].concat(...arguments_))];
-};
-
-
-/***/ }),
-/* 514 */
-/***/ (function(module, exports, __webpack_require__) {
-
-"use strict";
-
-
const arrayDiffer = (array, ...values) => {
const rest = new Set([].concat(...values));
return array.filter(element => !rest.has(element));
@@ -56604,7 +56592,7 @@ module.exports = arrayDiffer;
/***/ }),
-/* 515 */
+/* 514 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -56634,7 +56622,7 @@ module.exports = arrify;
/***/ }),
-/* 516 */
+/* 515 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -56650,10 +56638,10 @@ Object.defineProperty(exports, "buildProductionProjects", {
}
});
-var _build_production_projects = __webpack_require__(517);
+var _build_production_projects = __webpack_require__(516);
/***/ }),
-/* 517 */
+/* 516 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -56664,7 +56652,7 @@ Object.defineProperty(exports, "__esModule", {
});
exports.buildProductionProjects = buildProductionProjects;
-var _cpy = _interopRequireDefault(__webpack_require__(518));
+var _cpy = _interopRequireDefault(__webpack_require__(517));
var _del = _interopRequireDefault(__webpack_require__(297));
@@ -56808,7 +56796,7 @@ async function copyToBuild(project, opensearchDashboardsRoot, buildRoot) {
}
/***/ }),
-/* 518 */
+/* 517 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -56816,14 +56804,14 @@ async function copyToBuild(project, opensearchDashboardsRoot, buildRoot) {
const EventEmitter = __webpack_require__(156);
const path = __webpack_require__(4);
const os = __webpack_require__(121);
-const pMap = __webpack_require__(519);
-const arrify = __webpack_require__(515);
-const globby = __webpack_require__(520);
-const hasGlob = __webpack_require__(703);
-const cpFile = __webpack_require__(705);
-const junk = __webpack_require__(715);
-const pFilter = __webpack_require__(716);
-const CpyError = __webpack_require__(718);
+const pMap = __webpack_require__(518);
+const arrify = __webpack_require__(514);
+const globby = __webpack_require__(519);
+const hasGlob = __webpack_require__(702);
+const cpFile = __webpack_require__(704);
+const junk = __webpack_require__(714);
+const pFilter = __webpack_require__(715);
+const CpyError = __webpack_require__(717);
const defaultOptions = {
ignoreJunk: true
@@ -56974,7 +56962,7 @@ module.exports = (source, destination, {
/***/ }),
-/* 519 */
+/* 518 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -57062,17 +57050,17 @@ module.exports = async (
/***/ }),
-/* 520 */
+/* 519 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const fs = __webpack_require__(134);
-const arrayUnion = __webpack_require__(521);
+const arrayUnion = __webpack_require__(520);
const glob = __webpack_require__(147);
-const fastGlob = __webpack_require__(523);
-const dirGlob = __webpack_require__(697);
-const gitignore = __webpack_require__(700);
+const fastGlob = __webpack_require__(522);
+const dirGlob = __webpack_require__(696);
+const gitignore = __webpack_require__(699);
const DEFAULT_FILTER = () => false;
@@ -57217,12 +57205,12 @@ module.exports.gitignore = gitignore;
/***/ }),
-/* 521 */
+/* 520 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var arrayUniq = __webpack_require__(522);
+var arrayUniq = __webpack_require__(521);
module.exports = function () {
return arrayUniq([].concat.apply([], arguments));
@@ -57230,7 +57218,7 @@ module.exports = function () {
/***/ }),
-/* 522 */
+/* 521 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -57299,10 +57287,10 @@ if ('Set' in global) {
/***/ }),
-/* 523 */
+/* 522 */
/***/ (function(module, exports, __webpack_require__) {
-const pkg = __webpack_require__(524);
+const pkg = __webpack_require__(523);
module.exports = pkg.async;
module.exports.default = pkg.async;
@@ -57315,375 +57303,375 @@ module.exports.generateTasks = pkg.generateTasks;
/***/ }),
-/* 524 */
+/* 523 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var optionsManager = __webpack_require__(525);
-var taskManager = __webpack_require__(526);
-var reader_async_1 = __webpack_require__(668);
-var reader_stream_1 = __webpack_require__(692);
-var reader_sync_1 = __webpack_require__(693);
-var arrayUtils = __webpack_require__(695);
-var streamUtils = __webpack_require__(696);
-/**
- * Synchronous API.
- */
-function sync(source, opts) {
- assertPatternsInput(source);
- var works = getWorks(source, reader_sync_1.default, opts);
- return arrayUtils.flatten(works);
-}
-exports.sync = sync;
-/**
- * Asynchronous API.
- */
-function async(source, opts) {
- try {
- assertPatternsInput(source);
- }
- catch (error) {
- return Promise.reject(error);
- }
- var works = getWorks(source, reader_async_1.default, opts);
- return Promise.all(works).then(arrayUtils.flatten);
-}
-exports.async = async;
-/**
- * Stream API.
- */
-function stream(source, opts) {
- assertPatternsInput(source);
- var works = getWorks(source, reader_stream_1.default, opts);
- return streamUtils.merge(works);
-}
-exports.stream = stream;
-/**
- * Return a set of tasks based on provided patterns.
- */
-function generateTasks(source, opts) {
- assertPatternsInput(source);
- var patterns = [].concat(source);
- var options = optionsManager.prepare(opts);
- return taskManager.generate(patterns, options);
-}
-exports.generateTasks = generateTasks;
-/**
- * Returns a set of works based on provided tasks and class of the reader.
- */
-function getWorks(source, _Reader, opts) {
- var patterns = [].concat(source);
- var options = optionsManager.prepare(opts);
- var tasks = taskManager.generate(patterns, options);
- var reader = new _Reader(options);
- return tasks.map(reader.read, reader);
-}
-function assertPatternsInput(source) {
- if ([].concat(source).every(isString)) {
- return;
- }
- throw new TypeError('Patterns must be a string or an array of strings');
-}
-function isString(source) {
- /* tslint:disable-next-line strict-type-predicates */
- return typeof source === 'string';
-}
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var optionsManager = __webpack_require__(524);
+var taskManager = __webpack_require__(525);
+var reader_async_1 = __webpack_require__(667);
+var reader_stream_1 = __webpack_require__(691);
+var reader_sync_1 = __webpack_require__(692);
+var arrayUtils = __webpack_require__(694);
+var streamUtils = __webpack_require__(695);
+/**
+ * Synchronous API.
+ */
+function sync(source, opts) {
+ assertPatternsInput(source);
+ var works = getWorks(source, reader_sync_1.default, opts);
+ return arrayUtils.flatten(works);
+}
+exports.sync = sync;
+/**
+ * Asynchronous API.
+ */
+function async(source, opts) {
+ try {
+ assertPatternsInput(source);
+ }
+ catch (error) {
+ return Promise.reject(error);
+ }
+ var works = getWorks(source, reader_async_1.default, opts);
+ return Promise.all(works).then(arrayUtils.flatten);
+}
+exports.async = async;
+/**
+ * Stream API.
+ */
+function stream(source, opts) {
+ assertPatternsInput(source);
+ var works = getWorks(source, reader_stream_1.default, opts);
+ return streamUtils.merge(works);
+}
+exports.stream = stream;
+/**
+ * Return a set of tasks based on provided patterns.
+ */
+function generateTasks(source, opts) {
+ assertPatternsInput(source);
+ var patterns = [].concat(source);
+ var options = optionsManager.prepare(opts);
+ return taskManager.generate(patterns, options);
+}
+exports.generateTasks = generateTasks;
+/**
+ * Returns a set of works based on provided tasks and class of the reader.
+ */
+function getWorks(source, _Reader, opts) {
+ var patterns = [].concat(source);
+ var options = optionsManager.prepare(opts);
+ var tasks = taskManager.generate(patterns, options);
+ var reader = new _Reader(options);
+ return tasks.map(reader.read, reader);
+}
+function assertPatternsInput(source) {
+ if ([].concat(source).every(isString)) {
+ return;
+ }
+ throw new TypeError('Patterns must be a string or an array of strings');
+}
+function isString(source) {
+ /* tslint:disable-next-line strict-type-predicates */
+ return typeof source === 'string';
+}
/***/ }),
-/* 525 */
+/* 524 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-var __assign = (this && this.__assign) || function () {
- __assign = Object.assign || function(t) {
- for (var s, i = 1, n = arguments.length; i < n; i++) {
- s = arguments[i];
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
- t[p] = s[p];
- }
- return t;
- };
- return __assign.apply(this, arguments);
-};
-Object.defineProperty(exports, "__esModule", { value: true });
-function prepare(options) {
- var opts = __assign({ cwd: process.cwd(), deep: true, ignore: [], dot: false, stats: false, onlyFiles: true, onlyDirectories: false, followSymlinkedDirectories: true, unique: true, markDirectories: false, absolute: false, nobrace: false, brace: true, noglobstar: false, globstar: true, noext: false, extension: true, nocase: false, case: true, matchBase: false, transform: null }, options);
- if (opts.onlyDirectories) {
- opts.onlyFiles = false;
- }
- opts.brace = !opts.nobrace;
- opts.globstar = !opts.noglobstar;
- opts.extension = !opts.noext;
- opts.case = !opts.nocase;
- if (options) {
- opts.brace = ('brace' in options ? options.brace : opts.brace);
- opts.globstar = ('globstar' in options ? options.globstar : opts.globstar);
- opts.extension = ('extension' in options ? options.extension : opts.extension);
- opts.case = ('case' in options ? options.case : opts.case);
- }
- return opts;
-}
-exports.prepare = prepare;
+
+var __assign = (this && this.__assign) || function () {
+ __assign = Object.assign || function(t) {
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
+ s = arguments[i];
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
+ t[p] = s[p];
+ }
+ return t;
+ };
+ return __assign.apply(this, arguments);
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+function prepare(options) {
+ var opts = __assign({ cwd: process.cwd(), deep: true, ignore: [], dot: false, stats: false, onlyFiles: true, onlyDirectories: false, followSymlinkedDirectories: true, unique: true, markDirectories: false, absolute: false, nobrace: false, brace: true, noglobstar: false, globstar: true, noext: false, extension: true, nocase: false, case: true, matchBase: false, transform: null }, options);
+ if (opts.onlyDirectories) {
+ opts.onlyFiles = false;
+ }
+ opts.brace = !opts.nobrace;
+ opts.globstar = !opts.noglobstar;
+ opts.extension = !opts.noext;
+ opts.case = !opts.nocase;
+ if (options) {
+ opts.brace = ('brace' in options ? options.brace : opts.brace);
+ opts.globstar = ('globstar' in options ? options.globstar : opts.globstar);
+ opts.extension = ('extension' in options ? options.extension : opts.extension);
+ opts.case = ('case' in options ? options.case : opts.case);
+ }
+ return opts;
+}
+exports.prepare = prepare;
/***/ }),
-/* 526 */
+/* 525 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var patternUtils = __webpack_require__(527);
-/**
- * Generate tasks based on parent directory of each pattern.
- */
-function generate(patterns, options) {
- var unixPatterns = patterns.map(patternUtils.unixifyPattern);
- var unixIgnore = options.ignore.map(patternUtils.unixifyPattern);
- var positivePatterns = getPositivePatterns(unixPatterns);
- var negativePatterns = getNegativePatternsAsPositive(unixPatterns, unixIgnore);
- /**
- * When the `case` option is disabled, all patterns must be marked as dynamic, because we cannot check filepath
- * directly (without read directory).
- */
- var staticPatterns = !options.case ? [] : positivePatterns.filter(patternUtils.isStaticPattern);
- var dynamicPatterns = !options.case ? positivePatterns : positivePatterns.filter(patternUtils.isDynamicPattern);
- var staticTasks = convertPatternsToTasks(staticPatterns, negativePatterns, /* dynamic */ false);
- var dynamicTasks = convertPatternsToTasks(dynamicPatterns, negativePatterns, /* dynamic */ true);
- return staticTasks.concat(dynamicTasks);
-}
-exports.generate = generate;
-/**
- * Convert patterns to tasks based on parent directory of each pattern.
- */
-function convertPatternsToTasks(positive, negative, dynamic) {
- var positivePatternsGroup = groupPatternsByBaseDirectory(positive);
- // When we have a global group β there is no reason to divide the patterns into independent tasks.
- // In this case, the global task covers the rest.
- if ('.' in positivePatternsGroup) {
- var task = convertPatternGroupToTask('.', positive, negative, dynamic);
- return [task];
- }
- return convertPatternGroupsToTasks(positivePatternsGroup, negative, dynamic);
-}
-exports.convertPatternsToTasks = convertPatternsToTasks;
-/**
- * Return only positive patterns.
- */
-function getPositivePatterns(patterns) {
- return patternUtils.getPositivePatterns(patterns);
-}
-exports.getPositivePatterns = getPositivePatterns;
-/**
- * Return only negative patterns.
- */
-function getNegativePatternsAsPositive(patterns, ignore) {
- var negative = patternUtils.getNegativePatterns(patterns).concat(ignore);
- var positive = negative.map(patternUtils.convertToPositivePattern);
- return positive;
-}
-exports.getNegativePatternsAsPositive = getNegativePatternsAsPositive;
-/**
- * Group patterns by base directory of each pattern.
- */
-function groupPatternsByBaseDirectory(patterns) {
- return patterns.reduce(function (collection, pattern) {
- var base = patternUtils.getBaseDirectory(pattern);
- if (base in collection) {
- collection[base].push(pattern);
- }
- else {
- collection[base] = [pattern];
- }
- return collection;
- }, {});
-}
-exports.groupPatternsByBaseDirectory = groupPatternsByBaseDirectory;
-/**
- * Convert group of patterns to tasks.
- */
-function convertPatternGroupsToTasks(positive, negative, dynamic) {
- return Object.keys(positive).map(function (base) {
- return convertPatternGroupToTask(base, positive[base], negative, dynamic);
- });
-}
-exports.convertPatternGroupsToTasks = convertPatternGroupsToTasks;
-/**
- * Create a task for positive and negative patterns.
- */
-function convertPatternGroupToTask(base, positive, negative, dynamic) {
- return {
- base: base,
- dynamic: dynamic,
- positive: positive,
- negative: negative,
- patterns: [].concat(positive, negative.map(patternUtils.convertToNegativePattern))
- };
-}
-exports.convertPatternGroupToTask = convertPatternGroupToTask;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var patternUtils = __webpack_require__(526);
+/**
+ * Generate tasks based on parent directory of each pattern.
+ */
+function generate(patterns, options) {
+ var unixPatterns = patterns.map(patternUtils.unixifyPattern);
+ var unixIgnore = options.ignore.map(patternUtils.unixifyPattern);
+ var positivePatterns = getPositivePatterns(unixPatterns);
+ var negativePatterns = getNegativePatternsAsPositive(unixPatterns, unixIgnore);
+ /**
+ * When the `case` option is disabled, all patterns must be marked as dynamic, because we cannot check filepath
+ * directly (without read directory).
+ */
+ var staticPatterns = !options.case ? [] : positivePatterns.filter(patternUtils.isStaticPattern);
+ var dynamicPatterns = !options.case ? positivePatterns : positivePatterns.filter(patternUtils.isDynamicPattern);
+ var staticTasks = convertPatternsToTasks(staticPatterns, negativePatterns, /* dynamic */ false);
+ var dynamicTasks = convertPatternsToTasks(dynamicPatterns, negativePatterns, /* dynamic */ true);
+ return staticTasks.concat(dynamicTasks);
+}
+exports.generate = generate;
+/**
+ * Convert patterns to tasks based on parent directory of each pattern.
+ */
+function convertPatternsToTasks(positive, negative, dynamic) {
+ var positivePatternsGroup = groupPatternsByBaseDirectory(positive);
+ // When we have a global group β there is no reason to divide the patterns into independent tasks.
+ // In this case, the global task covers the rest.
+ if ('.' in positivePatternsGroup) {
+ var task = convertPatternGroupToTask('.', positive, negative, dynamic);
+ return [task];
+ }
+ return convertPatternGroupsToTasks(positivePatternsGroup, negative, dynamic);
+}
+exports.convertPatternsToTasks = convertPatternsToTasks;
+/**
+ * Return only positive patterns.
+ */
+function getPositivePatterns(patterns) {
+ return patternUtils.getPositivePatterns(patterns);
+}
+exports.getPositivePatterns = getPositivePatterns;
+/**
+ * Return only negative patterns.
+ */
+function getNegativePatternsAsPositive(patterns, ignore) {
+ var negative = patternUtils.getNegativePatterns(patterns).concat(ignore);
+ var positive = negative.map(patternUtils.convertToPositivePattern);
+ return positive;
+}
+exports.getNegativePatternsAsPositive = getNegativePatternsAsPositive;
+/**
+ * Group patterns by base directory of each pattern.
+ */
+function groupPatternsByBaseDirectory(patterns) {
+ return patterns.reduce(function (collection, pattern) {
+ var base = patternUtils.getBaseDirectory(pattern);
+ if (base in collection) {
+ collection[base].push(pattern);
+ }
+ else {
+ collection[base] = [pattern];
+ }
+ return collection;
+ }, {});
+}
+exports.groupPatternsByBaseDirectory = groupPatternsByBaseDirectory;
+/**
+ * Convert group of patterns to tasks.
+ */
+function convertPatternGroupsToTasks(positive, negative, dynamic) {
+ return Object.keys(positive).map(function (base) {
+ return convertPatternGroupToTask(base, positive[base], negative, dynamic);
+ });
+}
+exports.convertPatternGroupsToTasks = convertPatternGroupsToTasks;
+/**
+ * Create a task for positive and negative patterns.
+ */
+function convertPatternGroupToTask(base, positive, negative, dynamic) {
+ return {
+ base: base,
+ dynamic: dynamic,
+ positive: positive,
+ negative: negative,
+ patterns: [].concat(positive, negative.map(patternUtils.convertToNegativePattern))
+ };
+}
+exports.convertPatternGroupToTask = convertPatternGroupToTask;
/***/ }),
-/* 527 */
+/* 526 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var path = __webpack_require__(4);
-var globParent = __webpack_require__(309);
-var isGlob = __webpack_require__(310);
-var micromatch = __webpack_require__(528);
-var GLOBSTAR = '**';
-/**
- * Return true for static pattern.
- */
-function isStaticPattern(pattern) {
- return !isDynamicPattern(pattern);
-}
-exports.isStaticPattern = isStaticPattern;
-/**
- * Return true for pattern that looks like glob.
- */
-function isDynamicPattern(pattern) {
- return isGlob(pattern, { strict: false });
-}
-exports.isDynamicPattern = isDynamicPattern;
-/**
- * Convert a windows Β«pathΒ» to a unix-style Β«pathΒ».
- */
-function unixifyPattern(pattern) {
- return pattern.replace(/\\/g, '/');
-}
-exports.unixifyPattern = unixifyPattern;
-/**
- * Returns negative pattern as positive pattern.
- */
-function convertToPositivePattern(pattern) {
- return isNegativePattern(pattern) ? pattern.slice(1) : pattern;
-}
-exports.convertToPositivePattern = convertToPositivePattern;
-/**
- * Returns positive pattern as negative pattern.
- */
-function convertToNegativePattern(pattern) {
- return '!' + pattern;
-}
-exports.convertToNegativePattern = convertToNegativePattern;
-/**
- * Return true if provided pattern is negative pattern.
- */
-function isNegativePattern(pattern) {
- return pattern.startsWith('!') && pattern[1] !== '(';
-}
-exports.isNegativePattern = isNegativePattern;
-/**
- * Return true if provided pattern is positive pattern.
- */
-function isPositivePattern(pattern) {
- return !isNegativePattern(pattern);
-}
-exports.isPositivePattern = isPositivePattern;
-/**
- * Extracts negative patterns from array of patterns.
- */
-function getNegativePatterns(patterns) {
- return patterns.filter(isNegativePattern);
-}
-exports.getNegativePatterns = getNegativePatterns;
-/**
- * Extracts positive patterns from array of patterns.
- */
-function getPositivePatterns(patterns) {
- return patterns.filter(isPositivePattern);
-}
-exports.getPositivePatterns = getPositivePatterns;
-/**
- * Extract base directory from provided pattern.
- */
-function getBaseDirectory(pattern) {
- return globParent(pattern);
-}
-exports.getBaseDirectory = getBaseDirectory;
-/**
- * Return true if provided pattern has globstar.
- */
-function hasGlobStar(pattern) {
- return pattern.indexOf(GLOBSTAR) !== -1;
-}
-exports.hasGlobStar = hasGlobStar;
-/**
- * Return true if provided pattern ends with slash and globstar.
- */
-function endsWithSlashGlobStar(pattern) {
- return pattern.endsWith('/' + GLOBSTAR);
-}
-exports.endsWithSlashGlobStar = endsWithSlashGlobStar;
-/**
- * Returns Β«trueΒ» when pattern ends with a slash and globstar or the last partial of the pattern is static pattern.
- */
-function isAffectDepthOfReadingPattern(pattern) {
- var basename = path.basename(pattern);
- return endsWithSlashGlobStar(pattern) || isStaticPattern(basename);
-}
-exports.isAffectDepthOfReadingPattern = isAffectDepthOfReadingPattern;
-/**
- * Return naive depth of provided pattern without depth of the base directory.
- */
-function getNaiveDepth(pattern) {
- var base = getBaseDirectory(pattern);
- var patternDepth = pattern.split('/').length;
- var patternBaseDepth = base.split('/').length;
- /**
- * This is a hack for pattern that has no base directory.
- *
- * This is related to the `*\something\*` pattern.
- */
- if (base === '.') {
- return patternDepth - patternBaseDepth;
- }
- return patternDepth - patternBaseDepth - 1;
-}
-exports.getNaiveDepth = getNaiveDepth;
-/**
- * Return max naive depth of provided patterns without depth of the base directory.
- */
-function getMaxNaivePatternsDepth(patterns) {
- return patterns.reduce(function (max, pattern) {
- var depth = getNaiveDepth(pattern);
- return depth > max ? depth : max;
- }, 0);
-}
-exports.getMaxNaivePatternsDepth = getMaxNaivePatternsDepth;
-/**
- * Make RegExp for provided pattern.
- */
-function makeRe(pattern, options) {
- return micromatch.makeRe(pattern, options);
-}
-exports.makeRe = makeRe;
-/**
- * Convert patterns to regexps.
- */
-function convertPatternsToRe(patterns, options) {
- return patterns.map(function (pattern) { return makeRe(pattern, options); });
-}
-exports.convertPatternsToRe = convertPatternsToRe;
-/**
- * Returns true if the entry match any of the given RegExp's.
- */
-function matchAny(entry, patternsRe) {
- return patternsRe.some(function (patternRe) { return patternRe.test(entry); });
-}
-exports.matchAny = matchAny;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var path = __webpack_require__(4);
+var globParent = __webpack_require__(309);
+var isGlob = __webpack_require__(310);
+var micromatch = __webpack_require__(527);
+var GLOBSTAR = '**';
+/**
+ * Return true for static pattern.
+ */
+function isStaticPattern(pattern) {
+ return !isDynamicPattern(pattern);
+}
+exports.isStaticPattern = isStaticPattern;
+/**
+ * Return true for pattern that looks like glob.
+ */
+function isDynamicPattern(pattern) {
+ return isGlob(pattern, { strict: false });
+}
+exports.isDynamicPattern = isDynamicPattern;
+/**
+ * Convert a windows Β«pathΒ» to a unix-style Β«pathΒ».
+ */
+function unixifyPattern(pattern) {
+ return pattern.replace(/\\/g, '/');
+}
+exports.unixifyPattern = unixifyPattern;
+/**
+ * Returns negative pattern as positive pattern.
+ */
+function convertToPositivePattern(pattern) {
+ return isNegativePattern(pattern) ? pattern.slice(1) : pattern;
+}
+exports.convertToPositivePattern = convertToPositivePattern;
+/**
+ * Returns positive pattern as negative pattern.
+ */
+function convertToNegativePattern(pattern) {
+ return '!' + pattern;
+}
+exports.convertToNegativePattern = convertToNegativePattern;
+/**
+ * Return true if provided pattern is negative pattern.
+ */
+function isNegativePattern(pattern) {
+ return pattern.startsWith('!') && pattern[1] !== '(';
+}
+exports.isNegativePattern = isNegativePattern;
+/**
+ * Return true if provided pattern is positive pattern.
+ */
+function isPositivePattern(pattern) {
+ return !isNegativePattern(pattern);
+}
+exports.isPositivePattern = isPositivePattern;
+/**
+ * Extracts negative patterns from array of patterns.
+ */
+function getNegativePatterns(patterns) {
+ return patterns.filter(isNegativePattern);
+}
+exports.getNegativePatterns = getNegativePatterns;
+/**
+ * Extracts positive patterns from array of patterns.
+ */
+function getPositivePatterns(patterns) {
+ return patterns.filter(isPositivePattern);
+}
+exports.getPositivePatterns = getPositivePatterns;
+/**
+ * Extract base directory from provided pattern.
+ */
+function getBaseDirectory(pattern) {
+ return globParent(pattern);
+}
+exports.getBaseDirectory = getBaseDirectory;
+/**
+ * Return true if provided pattern has globstar.
+ */
+function hasGlobStar(pattern) {
+ return pattern.indexOf(GLOBSTAR) !== -1;
+}
+exports.hasGlobStar = hasGlobStar;
+/**
+ * Return true if provided pattern ends with slash and globstar.
+ */
+function endsWithSlashGlobStar(pattern) {
+ return pattern.endsWith('/' + GLOBSTAR);
+}
+exports.endsWithSlashGlobStar = endsWithSlashGlobStar;
+/**
+ * Returns Β«trueΒ» when pattern ends with a slash and globstar or the last partial of the pattern is static pattern.
+ */
+function isAffectDepthOfReadingPattern(pattern) {
+ var basename = path.basename(pattern);
+ return endsWithSlashGlobStar(pattern) || isStaticPattern(basename);
+}
+exports.isAffectDepthOfReadingPattern = isAffectDepthOfReadingPattern;
+/**
+ * Return naive depth of provided pattern without depth of the base directory.
+ */
+function getNaiveDepth(pattern) {
+ var base = getBaseDirectory(pattern);
+ var patternDepth = pattern.split('/').length;
+ var patternBaseDepth = base.split('/').length;
+ /**
+ * This is a hack for pattern that has no base directory.
+ *
+ * This is related to the `*\something\*` pattern.
+ */
+ if (base === '.') {
+ return patternDepth - patternBaseDepth;
+ }
+ return patternDepth - patternBaseDepth - 1;
+}
+exports.getNaiveDepth = getNaiveDepth;
+/**
+ * Return max naive depth of provided patterns without depth of the base directory.
+ */
+function getMaxNaivePatternsDepth(patterns) {
+ return patterns.reduce(function (max, pattern) {
+ var depth = getNaiveDepth(pattern);
+ return depth > max ? depth : max;
+ }, 0);
+}
+exports.getMaxNaivePatternsDepth = getMaxNaivePatternsDepth;
+/**
+ * Make RegExp for provided pattern.
+ */
+function makeRe(pattern, options) {
+ return micromatch.makeRe(pattern, options);
+}
+exports.makeRe = makeRe;
+/**
+ * Convert patterns to regexps.
+ */
+function convertPatternsToRe(patterns, options) {
+ return patterns.map(function (pattern) { return makeRe(pattern, options); });
+}
+exports.convertPatternsToRe = convertPatternsToRe;
+/**
+ * Returns true if the entry match any of the given RegExp's.
+ */
+function matchAny(entry, patternsRe) {
+ return patternsRe.some(function (patternRe) { return patternRe.test(entry); });
+}
+exports.matchAny = matchAny;
/***/ }),
-/* 528 */
+/* 527 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -57694,18 +57682,18 @@ exports.matchAny = matchAny;
*/
var util = __webpack_require__(112);
-var braces = __webpack_require__(529);
-var toRegex = __webpack_require__(530);
-var extend = __webpack_require__(633);
+var braces = __webpack_require__(528);
+var toRegex = __webpack_require__(529);
+var extend = __webpack_require__(632);
/**
* Local dependencies
*/
-var compilers = __webpack_require__(635);
-var parsers = __webpack_require__(664);
-var cache = __webpack_require__(665);
-var utils = __webpack_require__(666);
+var compilers = __webpack_require__(634);
+var parsers = __webpack_require__(663);
+var cache = __webpack_require__(664);
+var utils = __webpack_require__(665);
var MAX_LENGTH = 1024 * 64;
/**
@@ -58567,7 +58555,7 @@ module.exports = micromatch;
/***/ }),
-/* 529 */
+/* 528 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -58577,18 +58565,18 @@ module.exports = micromatch;
* Module dependencies
*/
-var toRegex = __webpack_require__(530);
-var unique = __webpack_require__(550);
-var extend = __webpack_require__(551);
+var toRegex = __webpack_require__(529);
+var unique = __webpack_require__(549);
+var extend = __webpack_require__(550);
/**
* Local dependencies
*/
-var compilers = __webpack_require__(553);
-var parsers = __webpack_require__(564);
-var Braces = __webpack_require__(568);
-var utils = __webpack_require__(554);
+var compilers = __webpack_require__(552);
+var parsers = __webpack_require__(563);
+var Braces = __webpack_require__(567);
+var utils = __webpack_require__(553);
var MAX_LENGTH = 1024 * 64;
var cache = {};
@@ -58892,16 +58880,16 @@ module.exports = braces;
/***/ }),
-/* 530 */
+/* 529 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var safe = __webpack_require__(531);
-var define = __webpack_require__(537);
-var extend = __webpack_require__(543);
-var not = __webpack_require__(547);
+var safe = __webpack_require__(530);
+var define = __webpack_require__(536);
+var extend = __webpack_require__(542);
+var not = __webpack_require__(546);
var MAX_LENGTH = 1024 * 64;
/**
@@ -59054,10 +59042,10 @@ module.exports.makeRe = makeRe;
/***/ }),
-/* 531 */
+/* 530 */
/***/ (function(module, exports, __webpack_require__) {
-var parse = __webpack_require__(532);
+var parse = __webpack_require__(531);
var types = parse.types;
module.exports = function (re, opts) {
@@ -59103,13 +59091,13 @@ function isRegExp (x) {
/***/ }),
-/* 532 */
+/* 531 */
/***/ (function(module, exports, __webpack_require__) {
-var util = __webpack_require__(533);
-var types = __webpack_require__(534);
-var sets = __webpack_require__(535);
-var positions = __webpack_require__(536);
+var util = __webpack_require__(532);
+var types = __webpack_require__(533);
+var sets = __webpack_require__(534);
+var positions = __webpack_require__(535);
module.exports = function(regexpStr) {
@@ -59391,11 +59379,11 @@ module.exports.types = types;
/***/ }),
-/* 533 */
+/* 532 */
/***/ (function(module, exports, __webpack_require__) {
-var types = __webpack_require__(534);
-var sets = __webpack_require__(535);
+var types = __webpack_require__(533);
+var sets = __webpack_require__(534);
// All of these are private and only used by randexp.
@@ -59508,7 +59496,7 @@ exports.error = function(regexp, msg) {
/***/ }),
-/* 534 */
+/* 533 */
/***/ (function(module, exports) {
module.exports = {
@@ -59524,10 +59512,10 @@ module.exports = {
/***/ }),
-/* 535 */
+/* 534 */
/***/ (function(module, exports, __webpack_require__) {
-var types = __webpack_require__(534);
+var types = __webpack_require__(533);
var INTS = function() {
return [{ type: types.RANGE , from: 48, to: 57 }];
@@ -59612,10 +59600,10 @@ exports.anyChar = function() {
/***/ }),
-/* 536 */
+/* 535 */
/***/ (function(module, exports, __webpack_require__) {
-var types = __webpack_require__(534);
+var types = __webpack_require__(533);
exports.wordBoundary = function() {
return { type: types.POSITION, value: 'b' };
@@ -59635,7 +59623,7 @@ exports.end = function() {
/***/ }),
-/* 537 */
+/* 536 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -59648,8 +59636,8 @@ exports.end = function() {
-var isobject = __webpack_require__(538);
-var isDescriptor = __webpack_require__(539);
+var isobject = __webpack_require__(537);
+var isDescriptor = __webpack_require__(538);
var define = (typeof Reflect !== 'undefined' && Reflect.defineProperty)
? Reflect.defineProperty
: Object.defineProperty;
@@ -59680,7 +59668,7 @@ module.exports = function defineProperty(obj, key, val) {
/***/ }),
-/* 538 */
+/* 537 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -59699,7 +59687,7 @@ module.exports = function isObject(val) {
/***/ }),
-/* 539 */
+/* 538 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -59712,9 +59700,9 @@ module.exports = function isObject(val) {
-var typeOf = __webpack_require__(540);
-var isAccessor = __webpack_require__(541);
-var isData = __webpack_require__(542);
+var typeOf = __webpack_require__(539);
+var isAccessor = __webpack_require__(540);
+var isData = __webpack_require__(541);
module.exports = function isDescriptor(obj, key) {
if (typeOf(obj) !== 'object') {
@@ -59728,7 +59716,7 @@ module.exports = function isDescriptor(obj, key) {
/***/ }),
-/* 540 */
+/* 539 */
/***/ (function(module, exports) {
var toString = Object.prototype.toString;
@@ -59863,7 +59851,7 @@ function isBuffer(val) {
/***/ }),
-/* 541 */
+/* 540 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -59876,7 +59864,7 @@ function isBuffer(val) {
-var typeOf = __webpack_require__(540);
+var typeOf = __webpack_require__(539);
// accessor descriptor properties
var accessor = {
@@ -59939,7 +59927,7 @@ module.exports = isAccessorDescriptor;
/***/ }),
-/* 542 */
+/* 541 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -59952,7 +59940,7 @@ module.exports = isAccessorDescriptor;
-var typeOf = __webpack_require__(540);
+var typeOf = __webpack_require__(539);
module.exports = function isDataDescriptor(obj, prop) {
// data descriptor properties
@@ -59995,14 +59983,14 @@ module.exports = function isDataDescriptor(obj, prop) {
/***/ }),
-/* 543 */
+/* 542 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isExtendable = __webpack_require__(544);
-var assignSymbols = __webpack_require__(546);
+var isExtendable = __webpack_require__(543);
+var assignSymbols = __webpack_require__(545);
module.exports = Object.assign || function(obj/*, objects*/) {
if (obj === null || typeof obj === 'undefined') {
@@ -60062,7 +60050,7 @@ function isEnum(obj, key) {
/***/ }),
-/* 544 */
+/* 543 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -60075,7 +60063,7 @@ function isEnum(obj, key) {
-var isPlainObject = __webpack_require__(545);
+var isPlainObject = __webpack_require__(544);
module.exports = function isExtendable(val) {
return isPlainObject(val) || typeof val === 'function' || Array.isArray(val);
@@ -60083,7 +60071,7 @@ module.exports = function isExtendable(val) {
/***/ }),
-/* 545 */
+/* 544 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -60096,7 +60084,7 @@ module.exports = function isExtendable(val) {
-var isObject = __webpack_require__(538);
+var isObject = __webpack_require__(537);
function isObjectObject(o) {
return isObject(o) === true
@@ -60127,7 +60115,7 @@ module.exports = function isPlainObject(o) {
/***/ }),
-/* 546 */
+/* 545 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -60174,14 +60162,14 @@ module.exports = function(receiver, objects) {
/***/ }),
-/* 547 */
+/* 546 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var extend = __webpack_require__(548);
-var safe = __webpack_require__(531);
+var extend = __webpack_require__(547);
+var safe = __webpack_require__(530);
/**
* The main export is a function that takes a `pattern` string and an `options` object.
@@ -60253,14 +60241,14 @@ module.exports = toRegex;
/***/ }),
-/* 548 */
+/* 547 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isExtendable = __webpack_require__(549);
-var assignSymbols = __webpack_require__(546);
+var isExtendable = __webpack_require__(548);
+var assignSymbols = __webpack_require__(545);
module.exports = Object.assign || function(obj/*, objects*/) {
if (obj === null || typeof obj === 'undefined') {
@@ -60320,7 +60308,7 @@ function isEnum(obj, key) {
/***/ }),
-/* 549 */
+/* 548 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -60333,7 +60321,7 @@ function isEnum(obj, key) {
-var isPlainObject = __webpack_require__(545);
+var isPlainObject = __webpack_require__(544);
module.exports = function isExtendable(val) {
return isPlainObject(val) || typeof val === 'function' || Array.isArray(val);
@@ -60341,7 +60329,7 @@ module.exports = function isExtendable(val) {
/***/ }),
-/* 550 */
+/* 549 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -60391,13 +60379,13 @@ module.exports.immutable = function uniqueImmutable(arr) {
/***/ }),
-/* 551 */
+/* 550 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isObject = __webpack_require__(552);
+var isObject = __webpack_require__(551);
module.exports = function extend(o/*, objects*/) {
if (!isObject(o)) { o = {}; }
@@ -60431,7 +60419,7 @@ function hasOwn(obj, key) {
/***/ }),
-/* 552 */
+/* 551 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -60451,13 +60439,13 @@ module.exports = function isExtendable(val) {
/***/ }),
-/* 553 */
+/* 552 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var utils = __webpack_require__(554);
+var utils = __webpack_require__(553);
module.exports = function(braces, options) {
braces.compiler
@@ -60740,25 +60728,25 @@ function hasQueue(node) {
/***/ }),
-/* 554 */
+/* 553 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var splitString = __webpack_require__(555);
+var splitString = __webpack_require__(554);
var utils = module.exports;
/**
* Module dependencies
*/
-utils.extend = __webpack_require__(551);
-utils.flatten = __webpack_require__(558);
-utils.isObject = __webpack_require__(538);
-utils.fillRange = __webpack_require__(559);
-utils.repeat = __webpack_require__(563);
-utils.unique = __webpack_require__(550);
+utils.extend = __webpack_require__(550);
+utils.flatten = __webpack_require__(557);
+utils.isObject = __webpack_require__(537);
+utils.fillRange = __webpack_require__(558);
+utils.repeat = __webpack_require__(562);
+utils.unique = __webpack_require__(549);
utils.define = function(obj, key, val) {
Object.defineProperty(obj, key, {
@@ -61090,7 +61078,7 @@ utils.escapeRegex = function(str) {
/***/ }),
-/* 555 */
+/* 554 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -61103,7 +61091,7 @@ utils.escapeRegex = function(str) {
-var extend = __webpack_require__(556);
+var extend = __webpack_require__(555);
module.exports = function(str, options, fn) {
if (typeof str !== 'string') {
@@ -61268,14 +61256,14 @@ function keepEscaping(opts, str, idx) {
/***/ }),
-/* 556 */
+/* 555 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isExtendable = __webpack_require__(557);
-var assignSymbols = __webpack_require__(546);
+var isExtendable = __webpack_require__(556);
+var assignSymbols = __webpack_require__(545);
module.exports = Object.assign || function(obj/*, objects*/) {
if (obj === null || typeof obj === 'undefined') {
@@ -61335,7 +61323,7 @@ function isEnum(obj, key) {
/***/ }),
-/* 557 */
+/* 556 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -61348,7 +61336,7 @@ function isEnum(obj, key) {
-var isPlainObject = __webpack_require__(545);
+var isPlainObject = __webpack_require__(544);
module.exports = function isExtendable(val) {
return isPlainObject(val) || typeof val === 'function' || Array.isArray(val);
@@ -61356,7 +61344,7 @@ module.exports = function isExtendable(val) {
/***/ }),
-/* 558 */
+/* 557 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -61385,7 +61373,7 @@ function flat(arr, res) {
/***/ }),
-/* 559 */
+/* 558 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -61399,10 +61387,10 @@ function flat(arr, res) {
var util = __webpack_require__(112);
-var isNumber = __webpack_require__(560);
-var extend = __webpack_require__(551);
-var repeat = __webpack_require__(561);
-var toRegex = __webpack_require__(562);
+var isNumber = __webpack_require__(559);
+var extend = __webpack_require__(550);
+var repeat = __webpack_require__(560);
+var toRegex = __webpack_require__(561);
/**
* Return a range of numbers or letters.
@@ -61600,7 +61588,7 @@ module.exports = fillRange;
/***/ }),
-/* 560 */
+/* 559 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -61613,7 +61601,7 @@ module.exports = fillRange;
-var typeOf = __webpack_require__(540);
+var typeOf = __webpack_require__(539);
module.exports = function isNumber(num) {
var type = typeOf(num);
@@ -61629,7 +61617,7 @@ module.exports = function isNumber(num) {
/***/ }),
-/* 561 */
+/* 560 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -61706,7 +61694,7 @@ function repeat(str, num) {
/***/ }),
-/* 562 */
+/* 561 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -61719,8 +61707,8 @@ function repeat(str, num) {
-var repeat = __webpack_require__(561);
-var isNumber = __webpack_require__(560);
+var repeat = __webpack_require__(560);
+var isNumber = __webpack_require__(559);
var cache = {};
function toRegexRange(min, max, options) {
@@ -62007,7 +61995,7 @@ module.exports = toRegexRange;
/***/ }),
-/* 563 */
+/* 562 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -62036,14 +62024,14 @@ module.exports = function repeat(ele, num) {
/***/ }),
-/* 564 */
+/* 563 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var Node = __webpack_require__(565);
-var utils = __webpack_require__(554);
+var Node = __webpack_require__(564);
+var utils = __webpack_require__(553);
/**
* Braces parsers
@@ -62403,15 +62391,15 @@ function concatNodes(pos, node, parent, options) {
/***/ }),
-/* 565 */
+/* 564 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isObject = __webpack_require__(538);
-var define = __webpack_require__(566);
-var utils = __webpack_require__(567);
+var isObject = __webpack_require__(537);
+var define = __webpack_require__(565);
+var utils = __webpack_require__(566);
var ownNames;
/**
@@ -62902,7 +62890,7 @@ exports = module.exports = Node;
/***/ }),
-/* 566 */
+/* 565 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -62915,7 +62903,7 @@ exports = module.exports = Node;
-var isDescriptor = __webpack_require__(539);
+var isDescriptor = __webpack_require__(538);
module.exports = function defineProperty(obj, prop, val) {
if (typeof obj !== 'object' && typeof obj !== 'function') {
@@ -62940,13 +62928,13 @@ module.exports = function defineProperty(obj, prop, val) {
/***/ }),
-/* 567 */
+/* 566 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var typeOf = __webpack_require__(540);
+var typeOf = __webpack_require__(539);
var utils = module.exports;
/**
@@ -63966,17 +63954,17 @@ function assert(val, message) {
/***/ }),
-/* 568 */
+/* 567 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var extend = __webpack_require__(551);
-var Snapdragon = __webpack_require__(569);
-var compilers = __webpack_require__(553);
-var parsers = __webpack_require__(564);
-var utils = __webpack_require__(554);
+var extend = __webpack_require__(550);
+var Snapdragon = __webpack_require__(568);
+var compilers = __webpack_require__(552);
+var parsers = __webpack_require__(563);
+var utils = __webpack_require__(553);
/**
* Customize Snapdragon parser and renderer
@@ -64077,17 +64065,17 @@ module.exports = Braces;
/***/ }),
-/* 569 */
+/* 568 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var Base = __webpack_require__(570);
-var define = __webpack_require__(595);
-var Compiler = __webpack_require__(602);
-var Parser = __webpack_require__(630);
-var utils = __webpack_require__(610);
+var Base = __webpack_require__(569);
+var define = __webpack_require__(594);
+var Compiler = __webpack_require__(601);
+var Parser = __webpack_require__(629);
+var utils = __webpack_require__(609);
var regexCache = {};
var cache = {};
@@ -64258,20 +64246,20 @@ module.exports.Parser = Parser;
/***/ }),
-/* 570 */
+/* 569 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var util = __webpack_require__(112);
-var define = __webpack_require__(571);
-var CacheBase = __webpack_require__(572);
-var Emitter = __webpack_require__(573);
-var isObject = __webpack_require__(538);
-var merge = __webpack_require__(590);
-var pascal = __webpack_require__(593);
-var cu = __webpack_require__(594);
+var define = __webpack_require__(570);
+var CacheBase = __webpack_require__(571);
+var Emitter = __webpack_require__(572);
+var isObject = __webpack_require__(537);
+var merge = __webpack_require__(589);
+var pascal = __webpack_require__(592);
+var cu = __webpack_require__(593);
/**
* Optionally define a custom `cache` namespace to use.
@@ -64700,7 +64688,7 @@ module.exports.namespace = namespace;
/***/ }),
-/* 571 */
+/* 570 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -64713,7 +64701,7 @@ module.exports.namespace = namespace;
-var isDescriptor = __webpack_require__(539);
+var isDescriptor = __webpack_require__(538);
module.exports = function defineProperty(obj, prop, val) {
if (typeof obj !== 'object' && typeof obj !== 'function') {
@@ -64738,21 +64726,21 @@ module.exports = function defineProperty(obj, prop, val) {
/***/ }),
-/* 572 */
+/* 571 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isObject = __webpack_require__(538);
-var Emitter = __webpack_require__(573);
-var visit = __webpack_require__(574);
-var toPath = __webpack_require__(577);
-var union = __webpack_require__(578);
-var del = __webpack_require__(582);
-var get = __webpack_require__(580);
-var has = __webpack_require__(588);
-var set = __webpack_require__(581);
+var isObject = __webpack_require__(537);
+var Emitter = __webpack_require__(572);
+var visit = __webpack_require__(573);
+var toPath = __webpack_require__(576);
+var union = __webpack_require__(577);
+var del = __webpack_require__(581);
+var get = __webpack_require__(579);
+var has = __webpack_require__(587);
+var set = __webpack_require__(580);
/**
* Create a `Cache` constructor that when instantiated will
@@ -65006,188 +64994,188 @@ module.exports.namespace = namespace;
/***/ }),
-/* 573 */
+/* 572 */
/***/ (function(module, exports, __webpack_require__) {
-
-/**
- * Expose `Emitter`.
- */
-
-if (true) {
- module.exports = Emitter;
-}
-
-/**
- * Initialize a new `Emitter`.
- *
- * @api public
- */
-
-function Emitter(obj) {
- if (obj) return mixin(obj);
-};
-
-/**
- * Mixin the emitter properties.
- *
- * @param {Object} obj
- * @return {Object}
- * @api private
- */
-
-function mixin(obj) {
- for (var key in Emitter.prototype) {
- obj[key] = Emitter.prototype[key];
- }
- return obj;
-}
-
-/**
- * Listen on the given `event` with `fn`.
- *
- * @param {String} event
- * @param {Function} fn
- * @return {Emitter}
- * @api public
- */
-
-Emitter.prototype.on =
-Emitter.prototype.addEventListener = function(event, fn){
- this._callbacks = this._callbacks || {};
- (this._callbacks['$' + event] = this._callbacks['$' + event] || [])
- .push(fn);
- return this;
-};
-
-/**
- * Adds an `event` listener that will be invoked a single
- * time then automatically removed.
- *
- * @param {String} event
- * @param {Function} fn
- * @return {Emitter}
- * @api public
- */
-
-Emitter.prototype.once = function(event, fn){
- function on() {
- this.off(event, on);
- fn.apply(this, arguments);
- }
-
- on.fn = fn;
- this.on(event, on);
- return this;
-};
-
-/**
- * Remove the given callback for `event` or all
- * registered callbacks.
- *
- * @param {String} event
- * @param {Function} fn
- * @return {Emitter}
- * @api public
- */
-
-Emitter.prototype.off =
-Emitter.prototype.removeListener =
-Emitter.prototype.removeAllListeners =
-Emitter.prototype.removeEventListener = function(event, fn){
- this._callbacks = this._callbacks || {};
-
- // all
- if (0 == arguments.length) {
- this._callbacks = {};
- return this;
- }
-
- // specific event
- var callbacks = this._callbacks['$' + event];
- if (!callbacks) return this;
-
- // remove all handlers
- if (1 == arguments.length) {
- delete this._callbacks['$' + event];
- return this;
- }
-
- // remove specific handler
- var cb;
- for (var i = 0; i < callbacks.length; i++) {
- cb = callbacks[i];
- if (cb === fn || cb.fn === fn) {
- callbacks.splice(i, 1);
- break;
- }
- }
-
- // Remove event specific arrays for event types that no
- // one is subscribed for to avoid memory leak.
- if (callbacks.length === 0) {
- delete this._callbacks['$' + event];
- }
-
- return this;
-};
-
-/**
- * Emit `event` with the given args.
- *
- * @param {String} event
- * @param {Mixed} ...
- * @return {Emitter}
- */
-
-Emitter.prototype.emit = function(event){
- this._callbacks = this._callbacks || {};
-
- var args = new Array(arguments.length - 1)
- , callbacks = this._callbacks['$' + event];
-
- for (var i = 1; i < arguments.length; i++) {
- args[i - 1] = arguments[i];
- }
-
- if (callbacks) {
- callbacks = callbacks.slice(0);
- for (var i = 0, len = callbacks.length; i < len; ++i) {
- callbacks[i].apply(this, args);
- }
- }
-
- return this;
-};
-
-/**
- * Return array of callbacks for `event`.
- *
- * @param {String} event
- * @return {Array}
- * @api public
- */
-
-Emitter.prototype.listeners = function(event){
- this._callbacks = this._callbacks || {};
- return this._callbacks['$' + event] || [];
-};
-
-/**
- * Check if this emitter has `event` handlers.
- *
- * @param {String} event
- * @return {Boolean}
- * @api public
- */
-
-Emitter.prototype.hasListeners = function(event){
- return !! this.listeners(event).length;
-};
+
+/**
+ * Expose `Emitter`.
+ */
+
+if (true) {
+ module.exports = Emitter;
+}
+
+/**
+ * Initialize a new `Emitter`.
+ *
+ * @api public
+ */
+
+function Emitter(obj) {
+ if (obj) return mixin(obj);
+};
+
+/**
+ * Mixin the emitter properties.
+ *
+ * @param {Object} obj
+ * @return {Object}
+ * @api private
+ */
+
+function mixin(obj) {
+ for (var key in Emitter.prototype) {
+ obj[key] = Emitter.prototype[key];
+ }
+ return obj;
+}
+
+/**
+ * Listen on the given `event` with `fn`.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ * @return {Emitter}
+ * @api public
+ */
+
+Emitter.prototype.on =
+Emitter.prototype.addEventListener = function(event, fn){
+ this._callbacks = this._callbacks || {};
+ (this._callbacks['$' + event] = this._callbacks['$' + event] || [])
+ .push(fn);
+ return this;
+};
+
+/**
+ * Adds an `event` listener that will be invoked a single
+ * time then automatically removed.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ * @return {Emitter}
+ * @api public
+ */
+
+Emitter.prototype.once = function(event, fn){
+ function on() {
+ this.off(event, on);
+ fn.apply(this, arguments);
+ }
+
+ on.fn = fn;
+ this.on(event, on);
+ return this;
+};
+
+/**
+ * Remove the given callback for `event` or all
+ * registered callbacks.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ * @return {Emitter}
+ * @api public
+ */
+
+Emitter.prototype.off =
+Emitter.prototype.removeListener =
+Emitter.prototype.removeAllListeners =
+Emitter.prototype.removeEventListener = function(event, fn){
+ this._callbacks = this._callbacks || {};
+
+ // all
+ if (0 == arguments.length) {
+ this._callbacks = {};
+ return this;
+ }
+
+ // specific event
+ var callbacks = this._callbacks['$' + event];
+ if (!callbacks) return this;
+
+ // remove all handlers
+ if (1 == arguments.length) {
+ delete this._callbacks['$' + event];
+ return this;
+ }
+
+ // remove specific handler
+ var cb;
+ for (var i = 0; i < callbacks.length; i++) {
+ cb = callbacks[i];
+ if (cb === fn || cb.fn === fn) {
+ callbacks.splice(i, 1);
+ break;
+ }
+ }
+
+ // Remove event specific arrays for event types that no
+ // one is subscribed for to avoid memory leak.
+ if (callbacks.length === 0) {
+ delete this._callbacks['$' + event];
+ }
+
+ return this;
+};
+
+/**
+ * Emit `event` with the given args.
+ *
+ * @param {String} event
+ * @param {Mixed} ...
+ * @return {Emitter}
+ */
+
+Emitter.prototype.emit = function(event){
+ this._callbacks = this._callbacks || {};
+
+ var args = new Array(arguments.length - 1)
+ , callbacks = this._callbacks['$' + event];
+
+ for (var i = 1; i < arguments.length; i++) {
+ args[i - 1] = arguments[i];
+ }
+
+ if (callbacks) {
+ callbacks = callbacks.slice(0);
+ for (var i = 0, len = callbacks.length; i < len; ++i) {
+ callbacks[i].apply(this, args);
+ }
+ }
+
+ return this;
+};
+
+/**
+ * Return array of callbacks for `event`.
+ *
+ * @param {String} event
+ * @return {Array}
+ * @api public
+ */
+
+Emitter.prototype.listeners = function(event){
+ this._callbacks = this._callbacks || {};
+ return this._callbacks['$' + event] || [];
+};
+
+/**
+ * Check if this emitter has `event` handlers.
+ *
+ * @param {String} event
+ * @return {Boolean}
+ * @api public
+ */
+
+Emitter.prototype.hasListeners = function(event){
+ return !! this.listeners(event).length;
+};
/***/ }),
-/* 574 */
+/* 573 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65200,8 +65188,8 @@ Emitter.prototype.hasListeners = function(event){
-var visit = __webpack_require__(575);
-var mapVisit = __webpack_require__(576);
+var visit = __webpack_require__(574);
+var mapVisit = __webpack_require__(575);
module.exports = function(collection, method, val) {
var result;
@@ -65224,7 +65212,7 @@ module.exports = function(collection, method, val) {
/***/ }),
-/* 575 */
+/* 574 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65237,7 +65225,7 @@ module.exports = function(collection, method, val) {
-var isObject = __webpack_require__(538);
+var isObject = __webpack_require__(537);
module.exports = function visit(thisArg, method, target, val) {
if (!isObject(thisArg) && typeof thisArg !== 'function') {
@@ -65264,14 +65252,14 @@ module.exports = function visit(thisArg, method, target, val) {
/***/ }),
-/* 576 */
+/* 575 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var util = __webpack_require__(112);
-var visit = __webpack_require__(575);
+var visit = __webpack_require__(574);
/**
* Map `visit` over an array of objects.
@@ -65308,7 +65296,7 @@ function isObject(val) {
/***/ }),
-/* 577 */
+/* 576 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65321,7 +65309,7 @@ function isObject(val) {
-var typeOf = __webpack_require__(540);
+var typeOf = __webpack_require__(539);
module.exports = function toPath(args) {
if (typeOf(args) !== 'arguments') {
@@ -65348,16 +65336,16 @@ function filter(arr) {
/***/ }),
-/* 578 */
+/* 577 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isObject = __webpack_require__(552);
-var union = __webpack_require__(579);
-var get = __webpack_require__(580);
-var set = __webpack_require__(581);
+var isObject = __webpack_require__(551);
+var union = __webpack_require__(578);
+var get = __webpack_require__(579);
+var set = __webpack_require__(580);
module.exports = function unionValue(obj, prop, value) {
if (!isObject(obj)) {
@@ -65385,7 +65373,7 @@ function arrayify(val) {
/***/ }),
-/* 579 */
+/* 578 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65421,7 +65409,7 @@ module.exports = function union(init) {
/***/ }),
-/* 580 */
+/* 579 */
/***/ (function(module, exports) {
/*!
@@ -65477,7 +65465,7 @@ function toString(val) {
/***/ }),
-/* 581 */
+/* 580 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65490,10 +65478,10 @@ function toString(val) {
-var split = __webpack_require__(555);
-var extend = __webpack_require__(551);
-var isPlainObject = __webpack_require__(545);
-var isObject = __webpack_require__(552);
+var split = __webpack_require__(554);
+var extend = __webpack_require__(550);
+var isPlainObject = __webpack_require__(544);
+var isObject = __webpack_require__(551);
module.exports = function(obj, prop, val) {
if (!isObject(obj)) {
@@ -65539,7 +65527,7 @@ function isValidKey(key) {
/***/ }),
-/* 582 */
+/* 581 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65552,8 +65540,8 @@ function isValidKey(key) {
-var isObject = __webpack_require__(583);
-var has = __webpack_require__(584);
+var isObject = __webpack_require__(582);
+var has = __webpack_require__(583);
const isUnsafeKey = key => {
return key === '__proto__' || key === 'constructor' || key === 'prototype';
@@ -65595,7 +65583,7 @@ module.exports = function unset(obj, prop) {
/***/ }),
-/* 583 */
+/* 582 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
@@ -65614,7 +65602,7 @@ function isObject(val) {
/***/ }),
-/* 584 */
+/* 583 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65627,8 +65615,8 @@ function isObject(val) {
-const get = __webpack_require__(585);
-const has = __webpack_require__(587);
+const get = __webpack_require__(584);
+const has = __webpack_require__(586);
module.exports = function(obj, path, options) {
if (isObject(obj) && (typeof path === 'string' || Array.isArray(path))) {
@@ -65643,7 +65631,7 @@ function isObject(val) {
/***/ }),
-/* 585 */
+/* 584 */
/***/ (function(module, exports, __webpack_require__) {
/*!
@@ -65653,7 +65641,7 @@ function isObject(val) {
* Released under the MIT License.
*/
-const isObject = __webpack_require__(586);
+const isObject = __webpack_require__(585);
module.exports = function(target, path, options) {
if (!isObject(options)) {
@@ -65759,7 +65747,7 @@ function isValidObject(val) {
/***/ }),
-/* 586 */
+/* 585 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65778,7 +65766,7 @@ module.exports = function isObject(val) {
/***/ }),
-/* 587 */
+/* 586 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65791,7 +65779,7 @@ module.exports = function isObject(val) {
-const typeOf = __webpack_require__(540);
+const typeOf = __webpack_require__(539);
module.exports = function has(val) {
switch (typeOf(val)) {
@@ -65834,7 +65822,7 @@ module.exports = function has(val) {
/***/ }),
-/* 588 */
+/* 587 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65847,9 +65835,9 @@ module.exports = function has(val) {
-var isObject = __webpack_require__(538);
-var hasValues = __webpack_require__(589);
-var get = __webpack_require__(580);
+var isObject = __webpack_require__(537);
+var hasValues = __webpack_require__(588);
+var get = __webpack_require__(579);
module.exports = function(val, prop) {
return hasValues(isObject(val) && prop ? get(val, prop) : val);
@@ -65857,7 +65845,7 @@ module.exports = function(val, prop) {
/***/ }),
-/* 589 */
+/* 588 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -65870,8 +65858,8 @@ module.exports = function(val, prop) {
-var typeOf = __webpack_require__(540);
-var isNumber = __webpack_require__(560);
+var typeOf = __webpack_require__(539);
+var isNumber = __webpack_require__(559);
module.exports = function hasValue(val) {
// is-number checks for NaN and other edge cases
@@ -65924,14 +65912,14 @@ module.exports = function hasValue(val) {
/***/ }),
-/* 590 */
+/* 589 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isExtendable = __webpack_require__(591);
-var forIn = __webpack_require__(592);
+var isExtendable = __webpack_require__(590);
+var forIn = __webpack_require__(591);
function mixinDeep(target, objects) {
var len = arguments.length, i = 0;
@@ -65995,7 +65983,7 @@ module.exports = mixinDeep;
/***/ }),
-/* 591 */
+/* 590 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -66008,7 +65996,7 @@ module.exports = mixinDeep;
-var isPlainObject = __webpack_require__(545);
+var isPlainObject = __webpack_require__(544);
module.exports = function isExtendable(val) {
return isPlainObject(val) || typeof val === 'function' || Array.isArray(val);
@@ -66016,7 +66004,7 @@ module.exports = function isExtendable(val) {
/***/ }),
-/* 592 */
+/* 591 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -66039,7 +66027,7 @@ module.exports = function forIn(obj, fn, thisArg) {
/***/ }),
-/* 593 */
+/* 592 */
/***/ (function(module, exports) {
/*!
@@ -66066,17 +66054,17 @@ module.exports = pascalcase;
/***/ }),
-/* 594 */
+/* 593 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var util = __webpack_require__(112);
-var union = __webpack_require__(579);
-var define = __webpack_require__(595);
-var staticExtend = __webpack_require__(599);
-var isObj = __webpack_require__(538);
+var union = __webpack_require__(578);
+var define = __webpack_require__(594);
+var staticExtend = __webpack_require__(598);
+var isObj = __webpack_require__(537);
/**
* Expose class utils
@@ -66443,7 +66431,7 @@ cu.bubble = function(Parent, events) {
/***/ }),
-/* 595 */
+/* 594 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -66456,7 +66444,7 @@ cu.bubble = function(Parent, events) {
-var isDescriptor = __webpack_require__(596);
+var isDescriptor = __webpack_require__(595);
module.exports = function defineProperty(obj, prop, val) {
if (typeof obj !== 'object' && typeof obj !== 'function') {
@@ -66481,7 +66469,7 @@ module.exports = function defineProperty(obj, prop, val) {
/***/ }),
-/* 596 */
+/* 595 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -66494,9 +66482,9 @@ module.exports = function defineProperty(obj, prop, val) {
-var typeOf = __webpack_require__(540);
-var isAccessor = __webpack_require__(597);
-var isData = __webpack_require__(598);
+var typeOf = __webpack_require__(539);
+var isAccessor = __webpack_require__(596);
+var isData = __webpack_require__(597);
module.exports = function isDescriptor(obj, key) {
if (typeOf(obj) !== 'object') {
@@ -66510,7 +66498,7 @@ module.exports = function isDescriptor(obj, key) {
/***/ }),
-/* 597 */
+/* 596 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -66523,7 +66511,7 @@ module.exports = function isDescriptor(obj, key) {
-var typeOf = __webpack_require__(540);
+var typeOf = __webpack_require__(539);
// accessor descriptor properties
var accessor = {
@@ -66586,7 +66574,7 @@ module.exports = isAccessorDescriptor;
/***/ }),
-/* 598 */
+/* 597 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -66599,7 +66587,7 @@ module.exports = isAccessorDescriptor;
-var typeOf = __webpack_require__(540);
+var typeOf = __webpack_require__(539);
// data descriptor properties
var data = {
@@ -66648,7 +66636,7 @@ module.exports = isDataDescriptor;
/***/ }),
-/* 599 */
+/* 598 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -66661,8 +66649,8 @@ module.exports = isDataDescriptor;
-var copy = __webpack_require__(600);
-var define = __webpack_require__(595);
+var copy = __webpack_require__(599);
+var define = __webpack_require__(594);
var util = __webpack_require__(112);
/**
@@ -66745,15 +66733,15 @@ module.exports = extend;
/***/ }),
-/* 600 */
+/* 599 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var typeOf = __webpack_require__(540);
-var copyDescriptor = __webpack_require__(601);
-var define = __webpack_require__(595);
+var typeOf = __webpack_require__(539);
+var copyDescriptor = __webpack_require__(600);
+var define = __webpack_require__(594);
/**
* Copy static properties, prototype properties, and descriptors from one object to another.
@@ -66926,7 +66914,7 @@ module.exports.has = has;
/***/ }),
-/* 601 */
+/* 600 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -67014,16 +67002,16 @@ function isObject(val) {
/***/ }),
-/* 602 */
+/* 601 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var use = __webpack_require__(603);
-var define = __webpack_require__(595);
-var debug = __webpack_require__(604)('snapdragon:compiler');
-var utils = __webpack_require__(610);
+var use = __webpack_require__(602);
+var define = __webpack_require__(594);
+var debug = __webpack_require__(603)('snapdragon:compiler');
+var utils = __webpack_require__(609);
/**
* Create a new `Compiler` with the given `options`.
@@ -67177,7 +67165,7 @@ Compiler.prototype = {
// source map support
if (opts.sourcemap) {
- var sourcemaps = __webpack_require__(629);
+ var sourcemaps = __webpack_require__(628);
sourcemaps(this);
this.mapVisit(this.ast.nodes);
this.applySourceMaps();
@@ -67198,7 +67186,7 @@ module.exports = Compiler;
/***/ }),
-/* 603 */
+/* 602 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -67360,7 +67348,7 @@ function define(obj, key, val) {
/***/ }),
-/* 604 */
+/* 603 */
/***/ (function(module, exports, __webpack_require__) {
/**
@@ -67369,14 +67357,14 @@ function define(obj, key, val) {
*/
if (typeof process !== 'undefined' && process.type === 'renderer') {
- module.exports = __webpack_require__(605);
+ module.exports = __webpack_require__(604);
} else {
- module.exports = __webpack_require__(608);
+ module.exports = __webpack_require__(607);
}
/***/ }),
-/* 605 */
+/* 604 */
/***/ (function(module, exports, __webpack_require__) {
/**
@@ -67385,7 +67373,7 @@ if (typeof process !== 'undefined' && process.type === 'renderer') {
* Expose `debug()` as the module.
*/
-exports = module.exports = __webpack_require__(606);
+exports = module.exports = __webpack_require__(605);
exports.log = log;
exports.formatArgs = formatArgs;
exports.save = save;
@@ -67567,7 +67555,7 @@ function localstorage() {
/***/ }),
-/* 606 */
+/* 605 */
/***/ (function(module, exports, __webpack_require__) {
@@ -67583,7 +67571,7 @@ exports.coerce = coerce;
exports.disable = disable;
exports.enable = enable;
exports.enabled = enabled;
-exports.humanize = __webpack_require__(607);
+exports.humanize = __webpack_require__(606);
/**
* The currently active debug mode names, and names to skip.
@@ -67775,7 +67763,7 @@ function coerce(val) {
/***/ }),
-/* 607 */
+/* 606 */
/***/ (function(module, exports) {
/**
@@ -67933,7 +67921,7 @@ function plural(ms, n, name) {
/***/ }),
-/* 608 */
+/* 607 */
/***/ (function(module, exports, __webpack_require__) {
/**
@@ -67949,7 +67937,7 @@ var util = __webpack_require__(112);
* Expose `debug()` as the module.
*/
-exports = module.exports = __webpack_require__(606);
+exports = module.exports = __webpack_require__(605);
exports.init = init;
exports.log = log;
exports.formatArgs = formatArgs;
@@ -68128,7 +68116,7 @@ function createWritableStdioStream (fd) {
case 'PIPE':
case 'TCP':
- var net = __webpack_require__(609);
+ var net = __webpack_require__(608);
stream = new net.Socket({
fd: fd,
readable: false,
@@ -68187,13 +68175,13 @@ exports.enable(load());
/***/ }),
-/* 609 */
+/* 608 */
/***/ (function(module, exports) {
module.exports = require("net");
/***/ }),
-/* 610 */
+/* 609 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -68203,9 +68191,9 @@ module.exports = require("net");
* Module dependencies
*/
-exports.extend = __webpack_require__(551);
-exports.SourceMap = __webpack_require__(611);
-exports.sourceMapResolve = __webpack_require__(622);
+exports.extend = __webpack_require__(550);
+exports.SourceMap = __webpack_require__(610);
+exports.sourceMapResolve = __webpack_require__(621);
/**
* Convert backslash in the given string to forward slashes
@@ -68248,7 +68236,7 @@ exports.last = function(arr, n) {
/***/ }),
-/* 611 */
+/* 610 */
/***/ (function(module, exports, __webpack_require__) {
/*
@@ -68256,13 +68244,13 @@ exports.last = function(arr, n) {
* Licensed under the New BSD license. See LICENSE.txt or:
* http://opensource.org/licenses/BSD-3-Clause
*/
-exports.SourceMapGenerator = __webpack_require__(612).SourceMapGenerator;
-exports.SourceMapConsumer = __webpack_require__(618).SourceMapConsumer;
-exports.SourceNode = __webpack_require__(621).SourceNode;
+exports.SourceMapGenerator = __webpack_require__(611).SourceMapGenerator;
+exports.SourceMapConsumer = __webpack_require__(617).SourceMapConsumer;
+exports.SourceNode = __webpack_require__(620).SourceNode;
/***/ }),
-/* 612 */
+/* 611 */
/***/ (function(module, exports, __webpack_require__) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -68272,10 +68260,10 @@ exports.SourceNode = __webpack_require__(621).SourceNode;
* http://opensource.org/licenses/BSD-3-Clause
*/
-var base64VLQ = __webpack_require__(613);
-var util = __webpack_require__(615);
-var ArraySet = __webpack_require__(616).ArraySet;
-var MappingList = __webpack_require__(617).MappingList;
+var base64VLQ = __webpack_require__(612);
+var util = __webpack_require__(614);
+var ArraySet = __webpack_require__(615).ArraySet;
+var MappingList = __webpack_require__(616).MappingList;
/**
* An instance of the SourceMapGenerator represents a source map which is
@@ -68684,7 +68672,7 @@ exports.SourceMapGenerator = SourceMapGenerator;
/***/ }),
-/* 613 */
+/* 612 */
/***/ (function(module, exports, __webpack_require__) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -68724,7 +68712,7 @@ exports.SourceMapGenerator = SourceMapGenerator;
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-var base64 = __webpack_require__(614);
+var base64 = __webpack_require__(613);
// A single base 64 digit can contain 6 bits of data. For the base 64 variable
// length quantities we use in the source map spec, the first bit is the sign,
@@ -68830,7 +68818,7 @@ exports.decode = function base64VLQ_decode(aStr, aIndex, aOutParam) {
/***/ }),
-/* 614 */
+/* 613 */
/***/ (function(module, exports) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -68903,7 +68891,7 @@ exports.decode = function (charCode) {
/***/ }),
-/* 615 */
+/* 614 */
/***/ (function(module, exports) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -69326,7 +69314,7 @@ exports.compareByGeneratedPositionsInflated = compareByGeneratedPositionsInflate
/***/ }),
-/* 616 */
+/* 615 */
/***/ (function(module, exports, __webpack_require__) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -69336,7 +69324,7 @@ exports.compareByGeneratedPositionsInflated = compareByGeneratedPositionsInflate
* http://opensource.org/licenses/BSD-3-Clause
*/
-var util = __webpack_require__(615);
+var util = __webpack_require__(614);
var has = Object.prototype.hasOwnProperty;
var hasNativeMap = typeof Map !== "undefined";
@@ -69453,7 +69441,7 @@ exports.ArraySet = ArraySet;
/***/ }),
-/* 617 */
+/* 616 */
/***/ (function(module, exports, __webpack_require__) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -69463,7 +69451,7 @@ exports.ArraySet = ArraySet;
* http://opensource.org/licenses/BSD-3-Clause
*/
-var util = __webpack_require__(615);
+var util = __webpack_require__(614);
/**
* Determine whether mappingB is after mappingA with respect to generated
@@ -69538,7 +69526,7 @@ exports.MappingList = MappingList;
/***/ }),
-/* 618 */
+/* 617 */
/***/ (function(module, exports, __webpack_require__) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -69548,11 +69536,11 @@ exports.MappingList = MappingList;
* http://opensource.org/licenses/BSD-3-Clause
*/
-var util = __webpack_require__(615);
-var binarySearch = __webpack_require__(619);
-var ArraySet = __webpack_require__(616).ArraySet;
-var base64VLQ = __webpack_require__(613);
-var quickSort = __webpack_require__(620).quickSort;
+var util = __webpack_require__(614);
+var binarySearch = __webpack_require__(618);
+var ArraySet = __webpack_require__(615).ArraySet;
+var base64VLQ = __webpack_require__(612);
+var quickSort = __webpack_require__(619).quickSort;
function SourceMapConsumer(aSourceMap) {
var sourceMap = aSourceMap;
@@ -70626,7 +70614,7 @@ exports.IndexedSourceMapConsumer = IndexedSourceMapConsumer;
/***/ }),
-/* 619 */
+/* 618 */
/***/ (function(module, exports) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -70743,7 +70731,7 @@ exports.search = function search(aNeedle, aHaystack, aCompare, aBias) {
/***/ }),
-/* 620 */
+/* 619 */
/***/ (function(module, exports) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -70863,7 +70851,7 @@ exports.quickSort = function (ary, comparator) {
/***/ }),
-/* 621 */
+/* 620 */
/***/ (function(module, exports, __webpack_require__) {
/* -*- Mode: js; js-indent-level: 2; -*- */
@@ -70873,8 +70861,8 @@ exports.quickSort = function (ary, comparator) {
* http://opensource.org/licenses/BSD-3-Clause
*/
-var SourceMapGenerator = __webpack_require__(612).SourceMapGenerator;
-var util = __webpack_require__(615);
+var SourceMapGenerator = __webpack_require__(611).SourceMapGenerator;
+var util = __webpack_require__(614);
// Matches a Windows-style `\r\n` newline or a `\n` newline used by all other
// operating systems these days (capturing the result).
@@ -71282,15 +71270,15 @@ exports.SourceNode = SourceNode;
/***/ }),
-/* 622 */
+/* 621 */
/***/ (function(module, exports, __webpack_require__) {
-var sourceMappingURL = __webpack_require__(623)
+var sourceMappingURL = __webpack_require__(622)
-var resolveUrl = __webpack_require__(624)
-var decodeUriComponent = __webpack_require__(625)
-var urix = __webpack_require__(627)
-var atob = __webpack_require__(628)
+var resolveUrl = __webpack_require__(623)
+var decodeUriComponent = __webpack_require__(624)
+var urix = __webpack_require__(626)
+var atob = __webpack_require__(627)
@@ -71630,7 +71618,7 @@ module.exports = {
/***/ }),
-/* 623 */
+/* 622 */
/***/ (function(module, exports, __webpack_require__) {
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_RESULT__;// Copyright 2014 Simon Lydell
@@ -71693,7 +71681,7 @@ void (function(root, factory) {
/***/ }),
-/* 624 */
+/* 623 */
/***/ (function(module, exports, __webpack_require__) {
var url = __webpack_require__(200)
@@ -71708,10 +71696,10 @@ module.exports = resolveUrl
/***/ }),
-/* 625 */
+/* 624 */
/***/ (function(module, exports, __webpack_require__) {
-var decodeUriComponent = __webpack_require__(626)
+var decodeUriComponent = __webpack_require__(625)
function customDecodeUriComponent(string) {
// `decodeUriComponent` turns `+` into ` `, but that's not wanted.
@@ -71722,7 +71710,7 @@ module.exports = customDecodeUriComponent
/***/ }),
-/* 626 */
+/* 625 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -71823,30 +71811,30 @@ module.exports = function (encodedURI) {
/***/ }),
-/* 627 */
+/* 626 */
/***/ (function(module, exports, __webpack_require__) {
-// Copyright 2014 Simon Lydell
-// X11 (βMITβ) Licensed. (See LICENSE.)
-
-var path = __webpack_require__(4)
-
-"use strict"
-
-function urix(aPath) {
- if (path.sep === "\\") {
- return aPath
- .replace(/\\/g, "/")
- .replace(/^[a-z]:\/?/i, "/")
- }
- return aPath
-}
-
-module.exports = urix
+// Copyright 2014 Simon Lydell
+// X11 (βMITβ) Licensed. (See LICENSE.)
+
+var path = __webpack_require__(4)
+
+"use strict"
+
+function urix(aPath) {
+ if (path.sep === "\\") {
+ return aPath
+ .replace(/\\/g, "/")
+ .replace(/^[a-z]:\/?/i, "/")
+ }
+ return aPath
+}
+
+module.exports = urix
/***/ }),
-/* 628 */
+/* 627 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -71860,7 +71848,7 @@ module.exports = atob.atob = atob;
/***/ }),
-/* 629 */
+/* 628 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -71868,8 +71856,8 @@ module.exports = atob.atob = atob;
var fs = __webpack_require__(134);
var path = __webpack_require__(4);
-var define = __webpack_require__(595);
-var utils = __webpack_require__(610);
+var define = __webpack_require__(594);
+var utils = __webpack_require__(609);
/**
* Expose `mixin()`.
@@ -72012,19 +72000,19 @@ exports.comment = function(node) {
/***/ }),
-/* 630 */
+/* 629 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var use = __webpack_require__(603);
+var use = __webpack_require__(602);
var util = __webpack_require__(112);
-var Cache = __webpack_require__(631);
-var define = __webpack_require__(595);
-var debug = __webpack_require__(604)('snapdragon:parser');
-var Position = __webpack_require__(632);
-var utils = __webpack_require__(610);
+var Cache = __webpack_require__(630);
+var define = __webpack_require__(594);
+var debug = __webpack_require__(603)('snapdragon:parser');
+var Position = __webpack_require__(631);
+var utils = __webpack_require__(609);
/**
* Create a new `Parser` with the given `input` and `options`.
@@ -72552,7 +72540,7 @@ module.exports = Parser;
/***/ }),
-/* 631 */
+/* 630 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -72659,13 +72647,13 @@ MapCache.prototype.del = function mapDelete(key) {
/***/ }),
-/* 632 */
+/* 631 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var define = __webpack_require__(595);
+var define = __webpack_require__(594);
/**
* Store position for a node
@@ -72680,14 +72668,14 @@ module.exports = function Position(start, parser) {
/***/ }),
-/* 633 */
+/* 632 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isExtendable = __webpack_require__(634);
-var assignSymbols = __webpack_require__(546);
+var isExtendable = __webpack_require__(633);
+var assignSymbols = __webpack_require__(545);
module.exports = Object.assign || function(obj/*, objects*/) {
if (obj === null || typeof obj === 'undefined') {
@@ -72747,7 +72735,7 @@ function isEnum(obj, key) {
/***/ }),
-/* 634 */
+/* 633 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -72760,7 +72748,7 @@ function isEnum(obj, key) {
-var isPlainObject = __webpack_require__(545);
+var isPlainObject = __webpack_require__(544);
module.exports = function isExtendable(val) {
return isPlainObject(val) || typeof val === 'function' || Array.isArray(val);
@@ -72768,14 +72756,14 @@ module.exports = function isExtendable(val) {
/***/ }),
-/* 635 */
+/* 634 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var nanomatch = __webpack_require__(636);
-var extglob = __webpack_require__(648);
+var nanomatch = __webpack_require__(635);
+var extglob = __webpack_require__(647);
module.exports = function(snapdragon) {
var compilers = snapdragon.compiler.compilers;
@@ -72852,7 +72840,7 @@ function escapeExtglobs(compiler) {
/***/ }),
-/* 636 */
+/* 635 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -72863,17 +72851,17 @@ function escapeExtglobs(compiler) {
*/
var util = __webpack_require__(112);
-var toRegex = __webpack_require__(530);
-var extend = __webpack_require__(637);
+var toRegex = __webpack_require__(529);
+var extend = __webpack_require__(636);
/**
* Local dependencies
*/
-var compilers = __webpack_require__(639);
-var parsers = __webpack_require__(640);
-var cache = __webpack_require__(641);
-var utils = __webpack_require__(643);
+var compilers = __webpack_require__(638);
+var parsers = __webpack_require__(639);
+var cache = __webpack_require__(640);
+var utils = __webpack_require__(642);
var MAX_LENGTH = 1024 * 64;
/**
@@ -73697,14 +73685,14 @@ module.exports = nanomatch;
/***/ }),
-/* 637 */
+/* 636 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var isExtendable = __webpack_require__(638);
-var assignSymbols = __webpack_require__(546);
+var isExtendable = __webpack_require__(637);
+var assignSymbols = __webpack_require__(545);
module.exports = Object.assign || function(obj/*, objects*/) {
if (obj === null || typeof obj === 'undefined') {
@@ -73764,7 +73752,7 @@ function isEnum(obj, key) {
/***/ }),
-/* 638 */
+/* 637 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -73777,7 +73765,7 @@ function isEnum(obj, key) {
-var isPlainObject = __webpack_require__(545);
+var isPlainObject = __webpack_require__(544);
module.exports = function isExtendable(val) {
return isPlainObject(val) || typeof val === 'function' || Array.isArray(val);
@@ -73785,7 +73773,7 @@ module.exports = function isExtendable(val) {
/***/ }),
-/* 639 */
+/* 638 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -74131,14 +74119,14 @@ module.exports = function(nanomatch, options) {
/***/ }),
-/* 640 */
+/* 639 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var regexNot = __webpack_require__(547);
-var toRegex = __webpack_require__(530);
+var regexNot = __webpack_require__(546);
+var toRegex = __webpack_require__(529);
/**
* Characters to use in negation regex (we want to "not" match
@@ -74524,14 +74512,14 @@ module.exports.not = NOT_REGEX;
/***/ }),
-/* 641 */
+/* 640 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = new (__webpack_require__(642))();
+module.exports = new (__webpack_require__(641))();
/***/ }),
-/* 642 */
+/* 641 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -74544,7 +74532,7 @@ module.exports = new (__webpack_require__(642))();
-var MapCache = __webpack_require__(631);
+var MapCache = __webpack_require__(630);
/**
* Create a new `FragmentCache` with an optional object to use for `caches`.
@@ -74666,7 +74654,7 @@ exports = module.exports = FragmentCache;
/***/ }),
-/* 643 */
+/* 642 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -74679,14 +74667,14 @@ var path = __webpack_require__(4);
* Module dependencies
*/
-var isWindows = __webpack_require__(644)();
-var Snapdragon = __webpack_require__(569);
-utils.define = __webpack_require__(645);
-utils.diff = __webpack_require__(646);
-utils.extend = __webpack_require__(637);
-utils.pick = __webpack_require__(647);
-utils.typeOf = __webpack_require__(540);
-utils.unique = __webpack_require__(550);
+var isWindows = __webpack_require__(643)();
+var Snapdragon = __webpack_require__(568);
+utils.define = __webpack_require__(644);
+utils.diff = __webpack_require__(645);
+utils.extend = __webpack_require__(636);
+utils.pick = __webpack_require__(646);
+utils.typeOf = __webpack_require__(539);
+utils.unique = __webpack_require__(549);
/**
* Returns true if the given value is effectively an empty string
@@ -75052,7 +75040,7 @@ utils.unixify = function(options) {
/***/ }),
-/* 644 */
+/* 643 */
/***/ (function(module, exports, __webpack_require__) {
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
@@ -75080,7 +75068,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
/***/ }),
-/* 645 */
+/* 644 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -75093,8 +75081,8 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
-var isobject = __webpack_require__(538);
-var isDescriptor = __webpack_require__(539);
+var isobject = __webpack_require__(537);
+var isDescriptor = __webpack_require__(538);
var define = (typeof Reflect !== 'undefined' && Reflect.defineProperty)
? Reflect.defineProperty
: Object.defineProperty;
@@ -75125,7 +75113,7 @@ module.exports = function defineProperty(obj, key, val) {
/***/ }),
-/* 646 */
+/* 645 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -75179,7 +75167,7 @@ function diffArray(one, two) {
/***/ }),
-/* 647 */
+/* 646 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -75192,7 +75180,7 @@ function diffArray(one, two) {
-var isObject = __webpack_require__(538);
+var isObject = __webpack_require__(537);
module.exports = function pick(obj, keys) {
if (!isObject(obj) && typeof obj !== 'function') {
@@ -75221,7 +75209,7 @@ module.exports = function pick(obj, keys) {
/***/ }),
-/* 648 */
+/* 647 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -75231,18 +75219,18 @@ module.exports = function pick(obj, keys) {
* Module dependencies
*/
-var extend = __webpack_require__(551);
-var unique = __webpack_require__(550);
-var toRegex = __webpack_require__(530);
+var extend = __webpack_require__(550);
+var unique = __webpack_require__(549);
+var toRegex = __webpack_require__(529);
/**
* Local dependencies
*/
-var compilers = __webpack_require__(649);
-var parsers = __webpack_require__(660);
-var Extglob = __webpack_require__(663);
-var utils = __webpack_require__(662);
+var compilers = __webpack_require__(648);
+var parsers = __webpack_require__(659);
+var Extglob = __webpack_require__(662);
+var utils = __webpack_require__(661);
var MAX_LENGTH = 1024 * 64;
/**
@@ -75559,13 +75547,13 @@ module.exports = extglob;
/***/ }),
-/* 649 */
+/* 648 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var brackets = __webpack_require__(650);
+var brackets = __webpack_require__(649);
/**
* Extglob compilers
@@ -75735,7 +75723,7 @@ module.exports = function(extglob) {
/***/ }),
-/* 650 */
+/* 649 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -75745,17 +75733,17 @@ module.exports = function(extglob) {
* Local dependencies
*/
-var compilers = __webpack_require__(651);
-var parsers = __webpack_require__(653);
+var compilers = __webpack_require__(650);
+var parsers = __webpack_require__(652);
/**
* Module dependencies
*/
-var debug = __webpack_require__(655)('expand-brackets');
-var extend = __webpack_require__(551);
-var Snapdragon = __webpack_require__(569);
-var toRegex = __webpack_require__(530);
+var debug = __webpack_require__(654)('expand-brackets');
+var extend = __webpack_require__(550);
+var Snapdragon = __webpack_require__(568);
+var toRegex = __webpack_require__(529);
/**
* Parses the given POSIX character class `pattern` and returns a
@@ -75953,13 +75941,13 @@ module.exports = brackets;
/***/ }),
-/* 651 */
+/* 650 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var posix = __webpack_require__(652);
+var posix = __webpack_require__(651);
module.exports = function(brackets) {
brackets.compiler
@@ -76047,7 +76035,7 @@ module.exports = function(brackets) {
/***/ }),
-/* 652 */
+/* 651 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -76076,14 +76064,14 @@ module.exports = {
/***/ }),
-/* 653 */
+/* 652 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var utils = __webpack_require__(654);
-var define = __webpack_require__(595);
+var utils = __webpack_require__(653);
+var define = __webpack_require__(594);
/**
* Text regex
@@ -76302,14 +76290,14 @@ module.exports.TEXT_REGEX = TEXT_REGEX;
/***/ }),
-/* 654 */
+/* 653 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var toRegex = __webpack_require__(530);
-var regexNot = __webpack_require__(547);
+var toRegex = __webpack_require__(529);
+var regexNot = __webpack_require__(546);
var cached;
/**
@@ -76343,7 +76331,7 @@ exports.createRegex = function(pattern, include) {
/***/ }),
-/* 655 */
+/* 654 */
/***/ (function(module, exports, __webpack_require__) {
/**
@@ -76352,14 +76340,14 @@ exports.createRegex = function(pattern, include) {
*/
if (typeof process !== 'undefined' && process.type === 'renderer') {
- module.exports = __webpack_require__(656);
+ module.exports = __webpack_require__(655);
} else {
- module.exports = __webpack_require__(659);
+ module.exports = __webpack_require__(658);
}
/***/ }),
-/* 656 */
+/* 655 */
/***/ (function(module, exports, __webpack_require__) {
/**
@@ -76368,7 +76356,7 @@ if (typeof process !== 'undefined' && process.type === 'renderer') {
* Expose `debug()` as the module.
*/
-exports = module.exports = __webpack_require__(657);
+exports = module.exports = __webpack_require__(656);
exports.log = log;
exports.formatArgs = formatArgs;
exports.save = save;
@@ -76550,7 +76538,7 @@ function localstorage() {
/***/ }),
-/* 657 */
+/* 656 */
/***/ (function(module, exports, __webpack_require__) {
@@ -76566,7 +76554,7 @@ exports.coerce = coerce;
exports.disable = disable;
exports.enable = enable;
exports.enabled = enabled;
-exports.humanize = __webpack_require__(658);
+exports.humanize = __webpack_require__(657);
/**
* The currently active debug mode names, and names to skip.
@@ -76758,7 +76746,7 @@ function coerce(val) {
/***/ }),
-/* 658 */
+/* 657 */
/***/ (function(module, exports) {
/**
@@ -76916,7 +76904,7 @@ function plural(ms, n, name) {
/***/ }),
-/* 659 */
+/* 658 */
/***/ (function(module, exports, __webpack_require__) {
/**
@@ -76932,7 +76920,7 @@ var util = __webpack_require__(112);
* Expose `debug()` as the module.
*/
-exports = module.exports = __webpack_require__(657);
+exports = module.exports = __webpack_require__(656);
exports.init = init;
exports.log = log;
exports.formatArgs = formatArgs;
@@ -77111,7 +77099,7 @@ function createWritableStdioStream (fd) {
case 'PIPE':
case 'TCP':
- var net = __webpack_require__(609);
+ var net = __webpack_require__(608);
stream = new net.Socket({
fd: fd,
readable: false,
@@ -77170,15 +77158,15 @@ exports.enable(load());
/***/ }),
-/* 660 */
+/* 659 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var brackets = __webpack_require__(650);
-var define = __webpack_require__(661);
-var utils = __webpack_require__(662);
+var brackets = __webpack_require__(649);
+var define = __webpack_require__(660);
+var utils = __webpack_require__(661);
/**
* Characters to use in text regex (we want to "not" match
@@ -77333,7 +77321,7 @@ module.exports = parsers;
/***/ }),
-/* 661 */
+/* 660 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -77346,7 +77334,7 @@ module.exports = parsers;
-var isDescriptor = __webpack_require__(539);
+var isDescriptor = __webpack_require__(538);
module.exports = function defineProperty(obj, prop, val) {
if (typeof obj !== 'object' && typeof obj !== 'function') {
@@ -77371,14 +77359,14 @@ module.exports = function defineProperty(obj, prop, val) {
/***/ }),
-/* 662 */
+/* 661 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var regex = __webpack_require__(547);
-var Cache = __webpack_require__(642);
+var regex = __webpack_require__(546);
+var Cache = __webpack_require__(641);
/**
* Utils
@@ -77447,7 +77435,7 @@ utils.createRegex = function(str) {
/***/ }),
-/* 663 */
+/* 662 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -77457,16 +77445,16 @@ utils.createRegex = function(str) {
* Module dependencies
*/
-var Snapdragon = __webpack_require__(569);
-var define = __webpack_require__(661);
-var extend = __webpack_require__(551);
+var Snapdragon = __webpack_require__(568);
+var define = __webpack_require__(660);
+var extend = __webpack_require__(550);
/**
* Local dependencies
*/
-var compilers = __webpack_require__(649);
-var parsers = __webpack_require__(660);
+var compilers = __webpack_require__(648);
+var parsers = __webpack_require__(659);
/**
* Customize Snapdragon parser and renderer
@@ -77532,16 +77520,16 @@ module.exports = Extglob;
/***/ }),
-/* 664 */
+/* 663 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-var extglob = __webpack_require__(648);
-var nanomatch = __webpack_require__(636);
-var regexNot = __webpack_require__(547);
-var toRegex = __webpack_require__(530);
+var extglob = __webpack_require__(647);
+var nanomatch = __webpack_require__(635);
+var regexNot = __webpack_require__(546);
+var toRegex = __webpack_require__(529);
var not;
/**
@@ -77622,14 +77610,14 @@ function textRegex(pattern) {
/***/ }),
-/* 665 */
+/* 664 */
/***/ (function(module, exports, __webpack_require__) {
-module.exports = new (__webpack_require__(642))();
+module.exports = new (__webpack_require__(641))();
/***/ }),
-/* 666 */
+/* 665 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -77642,13 +77630,13 @@ var path = __webpack_require__(4);
* Module dependencies
*/
-var Snapdragon = __webpack_require__(569);
-utils.define = __webpack_require__(667);
-utils.diff = __webpack_require__(646);
-utils.extend = __webpack_require__(633);
-utils.pick = __webpack_require__(647);
-utils.typeOf = __webpack_require__(540);
-utils.unique = __webpack_require__(550);
+var Snapdragon = __webpack_require__(568);
+utils.define = __webpack_require__(666);
+utils.diff = __webpack_require__(645);
+utils.extend = __webpack_require__(632);
+utils.pick = __webpack_require__(646);
+utils.typeOf = __webpack_require__(539);
+utils.unique = __webpack_require__(549);
/**
* Returns true if the platform is windows, or `path.sep` is `\\`.
@@ -77945,7 +77933,7 @@ utils.unixify = function(options) {
/***/ }),
-/* 667 */
+/* 666 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -77958,8 +77946,8 @@ utils.unixify = function(options) {
-var isobject = __webpack_require__(538);
-var isDescriptor = __webpack_require__(539);
+var isobject = __webpack_require__(537);
+var isDescriptor = __webpack_require__(538);
var define = (typeof Reflect !== 'undefined' && Reflect.defineProperty)
? Reflect.defineProperty
: Object.defineProperty;
@@ -77990,97 +77978,97 @@ module.exports = function defineProperty(obj, key, val) {
/***/ }),
-/* 668 */
+/* 667 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-var __extends = (this && this.__extends) || (function () {
- var extendStatics = function (d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
- return extendStatics(d, b);
- };
- return function (d, b) {
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
- };
-})();
-Object.defineProperty(exports, "__esModule", { value: true });
-var readdir = __webpack_require__(669);
-var reader_1 = __webpack_require__(682);
-var fs_stream_1 = __webpack_require__(686);
-var ReaderAsync = /** @class */ (function (_super) {
- __extends(ReaderAsync, _super);
- function ReaderAsync() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- Object.defineProperty(ReaderAsync.prototype, "fsAdapter", {
- /**
- * Returns FileSystem adapter.
- */
- get: function () {
- return new fs_stream_1.default(this.options);
- },
- enumerable: true,
- configurable: true
- });
- /**
- * Use async API to read entries for Task.
- */
- ReaderAsync.prototype.read = function (task) {
- var _this = this;
- var root = this.getRootDirectory(task);
- var options = this.getReaderOptions(task);
- var entries = [];
- return new Promise(function (resolve, reject) {
- var stream = _this.api(root, task, options);
- stream.on('error', function (err) {
- _this.isEnoentCodeError(err) ? resolve([]) : reject(err);
- stream.pause();
- });
- stream.on('data', function (entry) { return entries.push(_this.transform(entry)); });
- stream.on('end', function () { return resolve(entries); });
- });
- };
- /**
- * Returns founded paths.
- */
- ReaderAsync.prototype.api = function (root, task, options) {
- if (task.dynamic) {
- return this.dynamicApi(root, options);
- }
- return this.staticApi(task, options);
- };
- /**
- * Api for dynamic tasks.
- */
- ReaderAsync.prototype.dynamicApi = function (root, options) {
- return readdir.readdirStreamStat(root, options);
- };
- /**
- * Api for static tasks.
- */
- ReaderAsync.prototype.staticApi = function (task, options) {
- return this.fsAdapter.read(task.patterns, options.filter);
- };
- return ReaderAsync;
-}(reader_1.default));
-exports.default = ReaderAsync;
+
+var __extends = (this && this.__extends) || (function () {
+ var extendStatics = function (d, b) {
+ extendStatics = Object.setPrototypeOf ||
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
+ return extendStatics(d, b);
+ };
+ return function (d, b) {
+ extendStatics(d, b);
+ function __() { this.constructor = d; }
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+var readdir = __webpack_require__(668);
+var reader_1 = __webpack_require__(681);
+var fs_stream_1 = __webpack_require__(685);
+var ReaderAsync = /** @class */ (function (_super) {
+ __extends(ReaderAsync, _super);
+ function ReaderAsync() {
+ return _super !== null && _super.apply(this, arguments) || this;
+ }
+ Object.defineProperty(ReaderAsync.prototype, "fsAdapter", {
+ /**
+ * Returns FileSystem adapter.
+ */
+ get: function () {
+ return new fs_stream_1.default(this.options);
+ },
+ enumerable: true,
+ configurable: true
+ });
+ /**
+ * Use async API to read entries for Task.
+ */
+ ReaderAsync.prototype.read = function (task) {
+ var _this = this;
+ var root = this.getRootDirectory(task);
+ var options = this.getReaderOptions(task);
+ var entries = [];
+ return new Promise(function (resolve, reject) {
+ var stream = _this.api(root, task, options);
+ stream.on('error', function (err) {
+ _this.isEnoentCodeError(err) ? resolve([]) : reject(err);
+ stream.pause();
+ });
+ stream.on('data', function (entry) { return entries.push(_this.transform(entry)); });
+ stream.on('end', function () { return resolve(entries); });
+ });
+ };
+ /**
+ * Returns founded paths.
+ */
+ ReaderAsync.prototype.api = function (root, task, options) {
+ if (task.dynamic) {
+ return this.dynamicApi(root, options);
+ }
+ return this.staticApi(task, options);
+ };
+ /**
+ * Api for dynamic tasks.
+ */
+ ReaderAsync.prototype.dynamicApi = function (root, options) {
+ return readdir.readdirStreamStat(root, options);
+ };
+ /**
+ * Api for static tasks.
+ */
+ ReaderAsync.prototype.staticApi = function (task, options) {
+ return this.fsAdapter.read(task.patterns, options.filter);
+ };
+ return ReaderAsync;
+}(reader_1.default));
+exports.default = ReaderAsync;
/***/ }),
-/* 669 */
+/* 668 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-const readdirSync = __webpack_require__(670);
-const readdirAsync = __webpack_require__(678);
-const readdirStream = __webpack_require__(681);
+const readdirSync = __webpack_require__(669);
+const readdirAsync = __webpack_require__(677);
+const readdirStream = __webpack_require__(680);
module.exports = exports = readdirAsyncPath;
exports.readdir = exports.readdirAsync = exports.async = readdirAsyncPath;
@@ -78164,7 +78152,7 @@ function readdirStreamStat (dir, options) {
/***/ }),
-/* 670 */
+/* 669 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -78172,11 +78160,11 @@ function readdirStreamStat (dir, options) {
module.exports = readdirSync;
-const DirectoryReader = __webpack_require__(671);
+const DirectoryReader = __webpack_require__(670);
let syncFacade = {
- fs: __webpack_require__(676),
- forEach: __webpack_require__(677),
+ fs: __webpack_require__(675),
+ forEach: __webpack_require__(676),
sync: true
};
@@ -78205,7 +78193,7 @@ function readdirSync (dir, options, internalOptions) {
/***/ }),
-/* 671 */
+/* 670 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -78214,9 +78202,9 @@ function readdirSync (dir, options, internalOptions) {
const Readable = __webpack_require__(138).Readable;
const EventEmitter = __webpack_require__(156).EventEmitter;
const path = __webpack_require__(4);
-const normalizeOptions = __webpack_require__(672);
-const stat = __webpack_require__(674);
-const call = __webpack_require__(675);
+const normalizeOptions = __webpack_require__(671);
+const stat = __webpack_require__(673);
+const call = __webpack_require__(674);
/**
* Asynchronously reads the contents of a directory and streams the results
@@ -78592,14 +78580,14 @@ module.exports = DirectoryReader;
/***/ }),
-/* 672 */
+/* 671 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const path = __webpack_require__(4);
-const globToRegExp = __webpack_require__(673);
+const globToRegExp = __webpack_require__(672);
module.exports = normalizeOptions;
@@ -78776,7 +78764,7 @@ function normalizeOptions (options, internalOptions) {
/***/ }),
-/* 673 */
+/* 672 */
/***/ (function(module, exports) {
module.exports = function (glob, opts) {
@@ -78913,13 +78901,13 @@ module.exports = function (glob, opts) {
/***/ }),
-/* 674 */
+/* 673 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-const call = __webpack_require__(675);
+const call = __webpack_require__(674);
module.exports = stat;
@@ -78994,7 +78982,7 @@ function symlinkStat (fs, path, lstats, callback) {
/***/ }),
-/* 675 */
+/* 674 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79055,14 +79043,14 @@ function callOnce (fn) {
/***/ }),
-/* 676 */
+/* 675 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const fs = __webpack_require__(134);
-const call = __webpack_require__(675);
+const call = __webpack_require__(674);
/**
* A facade around {@link fs.readdirSync} that allows it to be called
@@ -79126,7 +79114,7 @@ exports.lstat = function (path, callback) {
/***/ }),
-/* 677 */
+/* 676 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79155,7 +79143,7 @@ function syncForEach (array, iterator, done) {
/***/ }),
-/* 678 */
+/* 677 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79163,12 +79151,12 @@ function syncForEach (array, iterator, done) {
module.exports = readdirAsync;
-const maybe = __webpack_require__(679);
-const DirectoryReader = __webpack_require__(671);
+const maybe = __webpack_require__(678);
+const DirectoryReader = __webpack_require__(670);
let asyncFacade = {
fs: __webpack_require__(134),
- forEach: __webpack_require__(680),
+ forEach: __webpack_require__(679),
async: true
};
@@ -79210,7 +79198,7 @@ function readdirAsync (dir, options, callback, internalOptions) {
/***/ }),
-/* 679 */
+/* 678 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79237,7 +79225,7 @@ module.exports = function maybe (cb, promise) {
/***/ }),
-/* 680 */
+/* 679 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79273,7 +79261,7 @@ function asyncForEach (array, iterator, done) {
/***/ }),
-/* 681 */
+/* 680 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79281,11 +79269,11 @@ function asyncForEach (array, iterator, done) {
module.exports = readdirStream;
-const DirectoryReader = __webpack_require__(671);
+const DirectoryReader = __webpack_require__(670);
let streamFacade = {
fs: __webpack_require__(134),
- forEach: __webpack_require__(680),
+ forEach: __webpack_require__(679),
async: true
};
@@ -79305,373 +79293,373 @@ function readdirStream (dir, options, internalOptions) {
/***/ }),
-/* 682 */
+/* 681 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var path = __webpack_require__(4);
-var deep_1 = __webpack_require__(683);
-var entry_1 = __webpack_require__(685);
-var pathUtil = __webpack_require__(684);
-var Reader = /** @class */ (function () {
- function Reader(options) {
- this.options = options;
- this.micromatchOptions = this.getMicromatchOptions();
- this.entryFilter = new entry_1.default(options, this.micromatchOptions);
- this.deepFilter = new deep_1.default(options, this.micromatchOptions);
- }
- /**
- * Returns root path to scanner.
- */
- Reader.prototype.getRootDirectory = function (task) {
- return path.resolve(this.options.cwd, task.base);
- };
- /**
- * Returns options for reader.
- */
- Reader.prototype.getReaderOptions = function (task) {
- return {
- basePath: task.base === '.' ? '' : task.base,
- filter: this.entryFilter.getFilter(task.positive, task.negative),
- deep: this.deepFilter.getFilter(task.positive, task.negative),
- sep: '/'
- };
- };
- /**
- * Returns options for micromatch.
- */
- Reader.prototype.getMicromatchOptions = function () {
- return {
- dot: this.options.dot,
- nobrace: !this.options.brace,
- noglobstar: !this.options.globstar,
- noext: !this.options.extension,
- nocase: !this.options.case,
- matchBase: this.options.matchBase
- };
- };
- /**
- * Returns transformed entry.
- */
- Reader.prototype.transform = function (entry) {
- if (this.options.absolute) {
- entry.path = pathUtil.makeAbsolute(this.options.cwd, entry.path);
- }
- if (this.options.markDirectories && entry.isDirectory()) {
- entry.path += '/';
- }
- var item = this.options.stats ? entry : entry.path;
- if (this.options.transform === null) {
- return item;
- }
- return this.options.transform(item);
- };
- /**
- * Returns true if error has ENOENT code.
- */
- Reader.prototype.isEnoentCodeError = function (err) {
- return err.code === 'ENOENT';
- };
- return Reader;
-}());
-exports.default = Reader;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var path = __webpack_require__(4);
+var deep_1 = __webpack_require__(682);
+var entry_1 = __webpack_require__(684);
+var pathUtil = __webpack_require__(683);
+var Reader = /** @class */ (function () {
+ function Reader(options) {
+ this.options = options;
+ this.micromatchOptions = this.getMicromatchOptions();
+ this.entryFilter = new entry_1.default(options, this.micromatchOptions);
+ this.deepFilter = new deep_1.default(options, this.micromatchOptions);
+ }
+ /**
+ * Returns root path to scanner.
+ */
+ Reader.prototype.getRootDirectory = function (task) {
+ return path.resolve(this.options.cwd, task.base);
+ };
+ /**
+ * Returns options for reader.
+ */
+ Reader.prototype.getReaderOptions = function (task) {
+ return {
+ basePath: task.base === '.' ? '' : task.base,
+ filter: this.entryFilter.getFilter(task.positive, task.negative),
+ deep: this.deepFilter.getFilter(task.positive, task.negative),
+ sep: '/'
+ };
+ };
+ /**
+ * Returns options for micromatch.
+ */
+ Reader.prototype.getMicromatchOptions = function () {
+ return {
+ dot: this.options.dot,
+ nobrace: !this.options.brace,
+ noglobstar: !this.options.globstar,
+ noext: !this.options.extension,
+ nocase: !this.options.case,
+ matchBase: this.options.matchBase
+ };
+ };
+ /**
+ * Returns transformed entry.
+ */
+ Reader.prototype.transform = function (entry) {
+ if (this.options.absolute) {
+ entry.path = pathUtil.makeAbsolute(this.options.cwd, entry.path);
+ }
+ if (this.options.markDirectories && entry.isDirectory()) {
+ entry.path += '/';
+ }
+ var item = this.options.stats ? entry : entry.path;
+ if (this.options.transform === null) {
+ return item;
+ }
+ return this.options.transform(item);
+ };
+ /**
+ * Returns true if error has ENOENT code.
+ */
+ Reader.prototype.isEnoentCodeError = function (err) {
+ return err.code === 'ENOENT';
+ };
+ return Reader;
+}());
+exports.default = Reader;
/***/ }),
-/* 683 */
+/* 682 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var pathUtils = __webpack_require__(684);
-var patternUtils = __webpack_require__(527);
-var DeepFilter = /** @class */ (function () {
- function DeepFilter(options, micromatchOptions) {
- this.options = options;
- this.micromatchOptions = micromatchOptions;
- }
- /**
- * Returns filter for directories.
- */
- DeepFilter.prototype.getFilter = function (positive, negative) {
- var _this = this;
- var maxPatternDepth = this.getMaxPatternDepth(positive);
- var negativeRe = this.getNegativePatternsRe(negative);
- return function (entry) { return _this.filter(entry, negativeRe, maxPatternDepth); };
- };
- /**
- * Returns max depth of the provided patterns.
- */
- DeepFilter.prototype.getMaxPatternDepth = function (patterns) {
- var globstar = patterns.some(patternUtils.hasGlobStar);
- return globstar ? Infinity : patternUtils.getMaxNaivePatternsDepth(patterns);
- };
- /**
- * Returns RegExp's for patterns that can affect the depth of reading.
- */
- DeepFilter.prototype.getNegativePatternsRe = function (patterns) {
- var affectDepthOfReadingPatterns = patterns.filter(patternUtils.isAffectDepthOfReadingPattern);
- return patternUtils.convertPatternsToRe(affectDepthOfReadingPatterns, this.micromatchOptions);
- };
- /**
- * Returns Β«trueΒ» for directory that should be read.
- */
- DeepFilter.prototype.filter = function (entry, negativeRe, maxPatternDepth) {
- if (this.isSkippedByDeepOption(entry.depth)) {
- return false;
- }
- if (this.isSkippedByMaxPatternDepth(entry.depth, maxPatternDepth)) {
- return false;
- }
- if (this.isSkippedSymlinkedDirectory(entry)) {
- return false;
- }
- if (this.isSkippedDotDirectory(entry)) {
- return false;
- }
- return this.isSkippedByNegativePatterns(entry, negativeRe);
- };
- /**
- * Returns Β«trueΒ» when the Β«deepΒ» option is disabled or number and depth of the entry is greater that the option value.
- */
- DeepFilter.prototype.isSkippedByDeepOption = function (entryDepth) {
- return !this.options.deep || (typeof this.options.deep === 'number' && entryDepth >= this.options.deep);
- };
- /**
- * Returns Β«trueΒ» when depth parameter is not an Infinity and entry depth greater that the parameter value.
- */
- DeepFilter.prototype.isSkippedByMaxPatternDepth = function (entryDepth, maxPatternDepth) {
- return maxPatternDepth !== Infinity && entryDepth >= maxPatternDepth;
- };
- /**
- * Returns Β«trueΒ» for symlinked directory if the Β«followSymlinkedDirectoriesΒ» option is disabled.
- */
- DeepFilter.prototype.isSkippedSymlinkedDirectory = function (entry) {
- return !this.options.followSymlinkedDirectories && entry.isSymbolicLink();
- };
- /**
- * Returns Β«trueΒ» for a directory whose name starts with a period if Β«dotΒ» option is disabled.
- */
- DeepFilter.prototype.isSkippedDotDirectory = function (entry) {
- return !this.options.dot && pathUtils.isDotDirectory(entry.path);
- };
- /**
- * Returns Β«trueΒ» for a directory whose path math to any negative pattern.
- */
- DeepFilter.prototype.isSkippedByNegativePatterns = function (entry, negativeRe) {
- return !patternUtils.matchAny(entry.path, negativeRe);
- };
- return DeepFilter;
-}());
-exports.default = DeepFilter;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var pathUtils = __webpack_require__(683);
+var patternUtils = __webpack_require__(526);
+var DeepFilter = /** @class */ (function () {
+ function DeepFilter(options, micromatchOptions) {
+ this.options = options;
+ this.micromatchOptions = micromatchOptions;
+ }
+ /**
+ * Returns filter for directories.
+ */
+ DeepFilter.prototype.getFilter = function (positive, negative) {
+ var _this = this;
+ var maxPatternDepth = this.getMaxPatternDepth(positive);
+ var negativeRe = this.getNegativePatternsRe(negative);
+ return function (entry) { return _this.filter(entry, negativeRe, maxPatternDepth); };
+ };
+ /**
+ * Returns max depth of the provided patterns.
+ */
+ DeepFilter.prototype.getMaxPatternDepth = function (patterns) {
+ var globstar = patterns.some(patternUtils.hasGlobStar);
+ return globstar ? Infinity : patternUtils.getMaxNaivePatternsDepth(patterns);
+ };
+ /**
+ * Returns RegExp's for patterns that can affect the depth of reading.
+ */
+ DeepFilter.prototype.getNegativePatternsRe = function (patterns) {
+ var affectDepthOfReadingPatterns = patterns.filter(patternUtils.isAffectDepthOfReadingPattern);
+ return patternUtils.convertPatternsToRe(affectDepthOfReadingPatterns, this.micromatchOptions);
+ };
+ /**
+ * Returns Β«trueΒ» for directory that should be read.
+ */
+ DeepFilter.prototype.filter = function (entry, negativeRe, maxPatternDepth) {
+ if (this.isSkippedByDeepOption(entry.depth)) {
+ return false;
+ }
+ if (this.isSkippedByMaxPatternDepth(entry.depth, maxPatternDepth)) {
+ return false;
+ }
+ if (this.isSkippedSymlinkedDirectory(entry)) {
+ return false;
+ }
+ if (this.isSkippedDotDirectory(entry)) {
+ return false;
+ }
+ return this.isSkippedByNegativePatterns(entry, negativeRe);
+ };
+ /**
+ * Returns Β«trueΒ» when the Β«deepΒ» option is disabled or number and depth of the entry is greater that the option value.
+ */
+ DeepFilter.prototype.isSkippedByDeepOption = function (entryDepth) {
+ return !this.options.deep || (typeof this.options.deep === 'number' && entryDepth >= this.options.deep);
+ };
+ /**
+ * Returns Β«trueΒ» when depth parameter is not an Infinity and entry depth greater that the parameter value.
+ */
+ DeepFilter.prototype.isSkippedByMaxPatternDepth = function (entryDepth, maxPatternDepth) {
+ return maxPatternDepth !== Infinity && entryDepth >= maxPatternDepth;
+ };
+ /**
+ * Returns Β«trueΒ» for symlinked directory if the Β«followSymlinkedDirectoriesΒ» option is disabled.
+ */
+ DeepFilter.prototype.isSkippedSymlinkedDirectory = function (entry) {
+ return !this.options.followSymlinkedDirectories && entry.isSymbolicLink();
+ };
+ /**
+ * Returns Β«trueΒ» for a directory whose name starts with a period if Β«dotΒ» option is disabled.
+ */
+ DeepFilter.prototype.isSkippedDotDirectory = function (entry) {
+ return !this.options.dot && pathUtils.isDotDirectory(entry.path);
+ };
+ /**
+ * Returns Β«trueΒ» for a directory whose path math to any negative pattern.
+ */
+ DeepFilter.prototype.isSkippedByNegativePatterns = function (entry, negativeRe) {
+ return !patternUtils.matchAny(entry.path, negativeRe);
+ };
+ return DeepFilter;
+}());
+exports.default = DeepFilter;
/***/ }),
-/* 684 */
+/* 683 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var path = __webpack_require__(4);
-/**
- * Returns Β«trueΒ» if the last partial of the path starting with a period.
- */
-function isDotDirectory(filepath) {
- return path.basename(filepath).startsWith('.');
-}
-exports.isDotDirectory = isDotDirectory;
-/**
- * Convert a windows-like path to a unix-style path.
- */
-function normalize(filepath) {
- return filepath.replace(/\\/g, '/');
-}
-exports.normalize = normalize;
-/**
- * Returns normalized absolute path of provided filepath.
- */
-function makeAbsolute(cwd, filepath) {
- return normalize(path.resolve(cwd, filepath));
-}
-exports.makeAbsolute = makeAbsolute;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var path = __webpack_require__(4);
+/**
+ * Returns Β«trueΒ» if the last partial of the path starting with a period.
+ */
+function isDotDirectory(filepath) {
+ return path.basename(filepath).startsWith('.');
+}
+exports.isDotDirectory = isDotDirectory;
+/**
+ * Convert a windows-like path to a unix-style path.
+ */
+function normalize(filepath) {
+ return filepath.replace(/\\/g, '/');
+}
+exports.normalize = normalize;
+/**
+ * Returns normalized absolute path of provided filepath.
+ */
+function makeAbsolute(cwd, filepath) {
+ return normalize(path.resolve(cwd, filepath));
+}
+exports.makeAbsolute = makeAbsolute;
/***/ }),
-/* 685 */
+/* 684 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var pathUtils = __webpack_require__(684);
-var patternUtils = __webpack_require__(527);
-var EntryFilter = /** @class */ (function () {
- function EntryFilter(options, micromatchOptions) {
- this.options = options;
- this.micromatchOptions = micromatchOptions;
- this.index = new Map();
- }
- /**
- * Returns filter for directories.
- */
- EntryFilter.prototype.getFilter = function (positive, negative) {
- var _this = this;
- var positiveRe = patternUtils.convertPatternsToRe(positive, this.micromatchOptions);
- var negativeRe = patternUtils.convertPatternsToRe(negative, this.micromatchOptions);
- return function (entry) { return _this.filter(entry, positiveRe, negativeRe); };
- };
- /**
- * Returns true if entry must be added to result.
- */
- EntryFilter.prototype.filter = function (entry, positiveRe, negativeRe) {
- // Exclude duplicate results
- if (this.options.unique) {
- if (this.isDuplicateEntry(entry)) {
- return false;
- }
- this.createIndexRecord(entry);
- }
- // Filter files and directories by options
- if (this.onlyFileFilter(entry) || this.onlyDirectoryFilter(entry)) {
- return false;
- }
- if (this.isSkippedByAbsoluteNegativePatterns(entry, negativeRe)) {
- return false;
- }
- return this.isMatchToPatterns(entry.path, positiveRe) && !this.isMatchToPatterns(entry.path, negativeRe);
- };
- /**
- * Return true if the entry already has in the cross reader index.
- */
- EntryFilter.prototype.isDuplicateEntry = function (entry) {
- return this.index.has(entry.path);
- };
- /**
- * Create record in the cross reader index.
- */
- EntryFilter.prototype.createIndexRecord = function (entry) {
- this.index.set(entry.path, undefined);
- };
- /**
- * Returns true for non-files if the Β«onlyFilesΒ» option is enabled.
- */
- EntryFilter.prototype.onlyFileFilter = function (entry) {
- return this.options.onlyFiles && !entry.isFile();
- };
- /**
- * Returns true for non-directories if the Β«onlyDirectoriesΒ» option is enabled.
- */
- EntryFilter.prototype.onlyDirectoryFilter = function (entry) {
- return this.options.onlyDirectories && !entry.isDirectory();
- };
- /**
- * Return true when `absolute` option is enabled and matched to the negative patterns.
- */
- EntryFilter.prototype.isSkippedByAbsoluteNegativePatterns = function (entry, negativeRe) {
- if (!this.options.absolute) {
- return false;
- }
- var fullpath = pathUtils.makeAbsolute(this.options.cwd, entry.path);
- return this.isMatchToPatterns(fullpath, negativeRe);
- };
- /**
- * Return true when entry match to provided patterns.
- *
- * First, just trying to apply patterns to the path.
- * Second, trying to apply patterns to the path with final slash (need to micromatch to support Β«directory/**Β» patterns).
- */
- EntryFilter.prototype.isMatchToPatterns = function (filepath, patternsRe) {
- return patternUtils.matchAny(filepath, patternsRe) || patternUtils.matchAny(filepath + '/', patternsRe);
- };
- return EntryFilter;
-}());
-exports.default = EntryFilter;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var pathUtils = __webpack_require__(683);
+var patternUtils = __webpack_require__(526);
+var EntryFilter = /** @class */ (function () {
+ function EntryFilter(options, micromatchOptions) {
+ this.options = options;
+ this.micromatchOptions = micromatchOptions;
+ this.index = new Map();
+ }
+ /**
+ * Returns filter for directories.
+ */
+ EntryFilter.prototype.getFilter = function (positive, negative) {
+ var _this = this;
+ var positiveRe = patternUtils.convertPatternsToRe(positive, this.micromatchOptions);
+ var negativeRe = patternUtils.convertPatternsToRe(negative, this.micromatchOptions);
+ return function (entry) { return _this.filter(entry, positiveRe, negativeRe); };
+ };
+ /**
+ * Returns true if entry must be added to result.
+ */
+ EntryFilter.prototype.filter = function (entry, positiveRe, negativeRe) {
+ // Exclude duplicate results
+ if (this.options.unique) {
+ if (this.isDuplicateEntry(entry)) {
+ return false;
+ }
+ this.createIndexRecord(entry);
+ }
+ // Filter files and directories by options
+ if (this.onlyFileFilter(entry) || this.onlyDirectoryFilter(entry)) {
+ return false;
+ }
+ if (this.isSkippedByAbsoluteNegativePatterns(entry, negativeRe)) {
+ return false;
+ }
+ return this.isMatchToPatterns(entry.path, positiveRe) && !this.isMatchToPatterns(entry.path, negativeRe);
+ };
+ /**
+ * Return true if the entry already has in the cross reader index.
+ */
+ EntryFilter.prototype.isDuplicateEntry = function (entry) {
+ return this.index.has(entry.path);
+ };
+ /**
+ * Create record in the cross reader index.
+ */
+ EntryFilter.prototype.createIndexRecord = function (entry) {
+ this.index.set(entry.path, undefined);
+ };
+ /**
+ * Returns true for non-files if the Β«onlyFilesΒ» option is enabled.
+ */
+ EntryFilter.prototype.onlyFileFilter = function (entry) {
+ return this.options.onlyFiles && !entry.isFile();
+ };
+ /**
+ * Returns true for non-directories if the Β«onlyDirectoriesΒ» option is enabled.
+ */
+ EntryFilter.prototype.onlyDirectoryFilter = function (entry) {
+ return this.options.onlyDirectories && !entry.isDirectory();
+ };
+ /**
+ * Return true when `absolute` option is enabled and matched to the negative patterns.
+ */
+ EntryFilter.prototype.isSkippedByAbsoluteNegativePatterns = function (entry, negativeRe) {
+ if (!this.options.absolute) {
+ return false;
+ }
+ var fullpath = pathUtils.makeAbsolute(this.options.cwd, entry.path);
+ return this.isMatchToPatterns(fullpath, negativeRe);
+ };
+ /**
+ * Return true when entry match to provided patterns.
+ *
+ * First, just trying to apply patterns to the path.
+ * Second, trying to apply patterns to the path with final slash (need to micromatch to support Β«directory/**Β» patterns).
+ */
+ EntryFilter.prototype.isMatchToPatterns = function (filepath, patternsRe) {
+ return patternUtils.matchAny(filepath, patternsRe) || patternUtils.matchAny(filepath + '/', patternsRe);
+ };
+ return EntryFilter;
+}());
+exports.default = EntryFilter;
/***/ }),
-/* 686 */
+/* 685 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-var __extends = (this && this.__extends) || (function () {
- var extendStatics = function (d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
- return extendStatics(d, b);
- };
- return function (d, b) {
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
- };
-})();
-Object.defineProperty(exports, "__esModule", { value: true });
-var stream = __webpack_require__(138);
-var fsStat = __webpack_require__(687);
-var fs_1 = __webpack_require__(691);
-var FileSystemStream = /** @class */ (function (_super) {
- __extends(FileSystemStream, _super);
- function FileSystemStream() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- /**
- * Use stream API to read entries for Task.
- */
- FileSystemStream.prototype.read = function (patterns, filter) {
- var _this = this;
- var filepaths = patterns.map(this.getFullEntryPath, this);
- var transform = new stream.Transform({ objectMode: true });
- transform._transform = function (index, _enc, done) {
- return _this.getEntry(filepaths[index], patterns[index]).then(function (entry) {
- if (entry !== null && filter(entry)) {
- transform.push(entry);
- }
- if (index === filepaths.length - 1) {
- transform.end();
- }
- done();
- });
- };
- for (var i = 0; i < filepaths.length; i++) {
- transform.write(i);
- }
- return transform;
- };
- /**
- * Return entry for the provided path.
- */
- FileSystemStream.prototype.getEntry = function (filepath, pattern) {
- var _this = this;
- return this.getStat(filepath)
- .then(function (stat) { return _this.makeEntry(stat, pattern); })
- .catch(function () { return null; });
- };
- /**
- * Return fs.Stats for the provided path.
- */
- FileSystemStream.prototype.getStat = function (filepath) {
- return fsStat.stat(filepath, { throwErrorOnBrokenSymlinks: false });
- };
- return FileSystemStream;
-}(fs_1.default));
-exports.default = FileSystemStream;
+
+var __extends = (this && this.__extends) || (function () {
+ var extendStatics = function (d, b) {
+ extendStatics = Object.setPrototypeOf ||
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
+ return extendStatics(d, b);
+ };
+ return function (d, b) {
+ extendStatics(d, b);
+ function __() { this.constructor = d; }
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+var stream = __webpack_require__(138);
+var fsStat = __webpack_require__(686);
+var fs_1 = __webpack_require__(690);
+var FileSystemStream = /** @class */ (function (_super) {
+ __extends(FileSystemStream, _super);
+ function FileSystemStream() {
+ return _super !== null && _super.apply(this, arguments) || this;
+ }
+ /**
+ * Use stream API to read entries for Task.
+ */
+ FileSystemStream.prototype.read = function (patterns, filter) {
+ var _this = this;
+ var filepaths = patterns.map(this.getFullEntryPath, this);
+ var transform = new stream.Transform({ objectMode: true });
+ transform._transform = function (index, _enc, done) {
+ return _this.getEntry(filepaths[index], patterns[index]).then(function (entry) {
+ if (entry !== null && filter(entry)) {
+ transform.push(entry);
+ }
+ if (index === filepaths.length - 1) {
+ transform.end();
+ }
+ done();
+ });
+ };
+ for (var i = 0; i < filepaths.length; i++) {
+ transform.write(i);
+ }
+ return transform;
+ };
+ /**
+ * Return entry for the provided path.
+ */
+ FileSystemStream.prototype.getEntry = function (filepath, pattern) {
+ var _this = this;
+ return this.getStat(filepath)
+ .then(function (stat) { return _this.makeEntry(stat, pattern); })
+ .catch(function () { return null; });
+ };
+ /**
+ * Return fs.Stats for the provided path.
+ */
+ FileSystemStream.prototype.getStat = function (filepath) {
+ return fsStat.stat(filepath, { throwErrorOnBrokenSymlinks: false });
+ };
+ return FileSystemStream;
+}(fs_1.default));
+exports.default = FileSystemStream;
/***/ }),
-/* 687 */
+/* 686 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
-const optionsManager = __webpack_require__(688);
-const statProvider = __webpack_require__(690);
+const optionsManager = __webpack_require__(687);
+const statProvider = __webpack_require__(689);
/**
* Asynchronous API.
*/
@@ -79702,13 +79690,13 @@ exports.statSync = statSync;
/***/ }),
-/* 688 */
+/* 687 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
-const fsAdapter = __webpack_require__(689);
+const fsAdapter = __webpack_require__(688);
function prepare(opts) {
const options = Object.assign({
fs: fsAdapter.getFileSystemAdapter(opts ? opts.fs : undefined),
@@ -79721,7 +79709,7 @@ exports.prepare = prepare;
/***/ }),
-/* 689 */
+/* 688 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79744,7 +79732,7 @@ exports.getFileSystemAdapter = getFileSystemAdapter;
/***/ }),
-/* 690 */
+/* 689 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -79796,318 +79784,318 @@ exports.isFollowedSymlink = isFollowedSymlink;
/***/ }),
-/* 691 */
+/* 690 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var path = __webpack_require__(4);
-var FileSystem = /** @class */ (function () {
- function FileSystem(options) {
- this.options = options;
- }
- /**
- * Return full path to entry.
- */
- FileSystem.prototype.getFullEntryPath = function (filepath) {
- return path.resolve(this.options.cwd, filepath);
- };
- /**
- * Return an implementation of the Entry interface.
- */
- FileSystem.prototype.makeEntry = function (stat, pattern) {
- stat.path = pattern;
- stat.depth = pattern.split('/').length;
- return stat;
- };
- return FileSystem;
-}());
-exports.default = FileSystem;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var path = __webpack_require__(4);
+var FileSystem = /** @class */ (function () {
+ function FileSystem(options) {
+ this.options = options;
+ }
+ /**
+ * Return full path to entry.
+ */
+ FileSystem.prototype.getFullEntryPath = function (filepath) {
+ return path.resolve(this.options.cwd, filepath);
+ };
+ /**
+ * Return an implementation of the Entry interface.
+ */
+ FileSystem.prototype.makeEntry = function (stat, pattern) {
+ stat.path = pattern;
+ stat.depth = pattern.split('/').length;
+ return stat;
+ };
+ return FileSystem;
+}());
+exports.default = FileSystem;
/***/ }),
-/* 692 */
+/* 691 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-var __extends = (this && this.__extends) || (function () {
- var extendStatics = function (d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
- return extendStatics(d, b);
- };
- return function (d, b) {
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
- };
-})();
-Object.defineProperty(exports, "__esModule", { value: true });
-var stream = __webpack_require__(138);
-var readdir = __webpack_require__(669);
-var reader_1 = __webpack_require__(682);
-var fs_stream_1 = __webpack_require__(686);
-var TransformStream = /** @class */ (function (_super) {
- __extends(TransformStream, _super);
- function TransformStream(reader) {
- var _this = _super.call(this, { objectMode: true }) || this;
- _this.reader = reader;
- return _this;
- }
- TransformStream.prototype._transform = function (entry, _encoding, callback) {
- callback(null, this.reader.transform(entry));
- };
- return TransformStream;
-}(stream.Transform));
-var ReaderStream = /** @class */ (function (_super) {
- __extends(ReaderStream, _super);
- function ReaderStream() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- Object.defineProperty(ReaderStream.prototype, "fsAdapter", {
- /**
- * Returns FileSystem adapter.
- */
- get: function () {
- return new fs_stream_1.default(this.options);
- },
- enumerable: true,
- configurable: true
- });
- /**
- * Use stream API to read entries for Task.
- */
- ReaderStream.prototype.read = function (task) {
- var _this = this;
- var root = this.getRootDirectory(task);
- var options = this.getReaderOptions(task);
- var transform = new TransformStream(this);
- var readable = this.api(root, task, options);
- return readable
- .on('error', function (err) { return _this.isEnoentCodeError(err) ? null : transform.emit('error', err); })
- .pipe(transform);
- };
- /**
- * Returns founded paths.
- */
- ReaderStream.prototype.api = function (root, task, options) {
- if (task.dynamic) {
- return this.dynamicApi(root, options);
- }
- return this.staticApi(task, options);
- };
- /**
- * Api for dynamic tasks.
- */
- ReaderStream.prototype.dynamicApi = function (root, options) {
- return readdir.readdirStreamStat(root, options);
- };
- /**
- * Api for static tasks.
- */
- ReaderStream.prototype.staticApi = function (task, options) {
- return this.fsAdapter.read(task.patterns, options.filter);
- };
- return ReaderStream;
-}(reader_1.default));
-exports.default = ReaderStream;
+
+var __extends = (this && this.__extends) || (function () {
+ var extendStatics = function (d, b) {
+ extendStatics = Object.setPrototypeOf ||
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
+ return extendStatics(d, b);
+ };
+ return function (d, b) {
+ extendStatics(d, b);
+ function __() { this.constructor = d; }
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+var stream = __webpack_require__(138);
+var readdir = __webpack_require__(668);
+var reader_1 = __webpack_require__(681);
+var fs_stream_1 = __webpack_require__(685);
+var TransformStream = /** @class */ (function (_super) {
+ __extends(TransformStream, _super);
+ function TransformStream(reader) {
+ var _this = _super.call(this, { objectMode: true }) || this;
+ _this.reader = reader;
+ return _this;
+ }
+ TransformStream.prototype._transform = function (entry, _encoding, callback) {
+ callback(null, this.reader.transform(entry));
+ };
+ return TransformStream;
+}(stream.Transform));
+var ReaderStream = /** @class */ (function (_super) {
+ __extends(ReaderStream, _super);
+ function ReaderStream() {
+ return _super !== null && _super.apply(this, arguments) || this;
+ }
+ Object.defineProperty(ReaderStream.prototype, "fsAdapter", {
+ /**
+ * Returns FileSystem adapter.
+ */
+ get: function () {
+ return new fs_stream_1.default(this.options);
+ },
+ enumerable: true,
+ configurable: true
+ });
+ /**
+ * Use stream API to read entries for Task.
+ */
+ ReaderStream.prototype.read = function (task) {
+ var _this = this;
+ var root = this.getRootDirectory(task);
+ var options = this.getReaderOptions(task);
+ var transform = new TransformStream(this);
+ var readable = this.api(root, task, options);
+ return readable
+ .on('error', function (err) { return _this.isEnoentCodeError(err) ? null : transform.emit('error', err); })
+ .pipe(transform);
+ };
+ /**
+ * Returns founded paths.
+ */
+ ReaderStream.prototype.api = function (root, task, options) {
+ if (task.dynamic) {
+ return this.dynamicApi(root, options);
+ }
+ return this.staticApi(task, options);
+ };
+ /**
+ * Api for dynamic tasks.
+ */
+ ReaderStream.prototype.dynamicApi = function (root, options) {
+ return readdir.readdirStreamStat(root, options);
+ };
+ /**
+ * Api for static tasks.
+ */
+ ReaderStream.prototype.staticApi = function (task, options) {
+ return this.fsAdapter.read(task.patterns, options.filter);
+ };
+ return ReaderStream;
+}(reader_1.default));
+exports.default = ReaderStream;
/***/ }),
-/* 693 */
+/* 692 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-var __extends = (this && this.__extends) || (function () {
- var extendStatics = function (d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
- return extendStatics(d, b);
- };
- return function (d, b) {
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
- };
-})();
-Object.defineProperty(exports, "__esModule", { value: true });
-var readdir = __webpack_require__(669);
-var reader_1 = __webpack_require__(682);
-var fs_sync_1 = __webpack_require__(694);
-var ReaderSync = /** @class */ (function (_super) {
- __extends(ReaderSync, _super);
- function ReaderSync() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- Object.defineProperty(ReaderSync.prototype, "fsAdapter", {
- /**
- * Returns FileSystem adapter.
- */
- get: function () {
- return new fs_sync_1.default(this.options);
- },
- enumerable: true,
- configurable: true
- });
- /**
- * Use sync API to read entries for Task.
- */
- ReaderSync.prototype.read = function (task) {
- var root = this.getRootDirectory(task);
- var options = this.getReaderOptions(task);
- try {
- var entries = this.api(root, task, options);
- return entries.map(this.transform, this);
- }
- catch (err) {
- if (this.isEnoentCodeError(err)) {
- return [];
- }
- throw err;
- }
- };
- /**
- * Returns founded paths.
- */
- ReaderSync.prototype.api = function (root, task, options) {
- if (task.dynamic) {
- return this.dynamicApi(root, options);
- }
- return this.staticApi(task, options);
- };
- /**
- * Api for dynamic tasks.
- */
- ReaderSync.prototype.dynamicApi = function (root, options) {
- return readdir.readdirSyncStat(root, options);
- };
- /**
- * Api for static tasks.
- */
- ReaderSync.prototype.staticApi = function (task, options) {
- return this.fsAdapter.read(task.patterns, options.filter);
- };
- return ReaderSync;
-}(reader_1.default));
-exports.default = ReaderSync;
+
+var __extends = (this && this.__extends) || (function () {
+ var extendStatics = function (d, b) {
+ extendStatics = Object.setPrototypeOf ||
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
+ return extendStatics(d, b);
+ };
+ return function (d, b) {
+ extendStatics(d, b);
+ function __() { this.constructor = d; }
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+var readdir = __webpack_require__(668);
+var reader_1 = __webpack_require__(681);
+var fs_sync_1 = __webpack_require__(693);
+var ReaderSync = /** @class */ (function (_super) {
+ __extends(ReaderSync, _super);
+ function ReaderSync() {
+ return _super !== null && _super.apply(this, arguments) || this;
+ }
+ Object.defineProperty(ReaderSync.prototype, "fsAdapter", {
+ /**
+ * Returns FileSystem adapter.
+ */
+ get: function () {
+ return new fs_sync_1.default(this.options);
+ },
+ enumerable: true,
+ configurable: true
+ });
+ /**
+ * Use sync API to read entries for Task.
+ */
+ ReaderSync.prototype.read = function (task) {
+ var root = this.getRootDirectory(task);
+ var options = this.getReaderOptions(task);
+ try {
+ var entries = this.api(root, task, options);
+ return entries.map(this.transform, this);
+ }
+ catch (err) {
+ if (this.isEnoentCodeError(err)) {
+ return [];
+ }
+ throw err;
+ }
+ };
+ /**
+ * Returns founded paths.
+ */
+ ReaderSync.prototype.api = function (root, task, options) {
+ if (task.dynamic) {
+ return this.dynamicApi(root, options);
+ }
+ return this.staticApi(task, options);
+ };
+ /**
+ * Api for dynamic tasks.
+ */
+ ReaderSync.prototype.dynamicApi = function (root, options) {
+ return readdir.readdirSyncStat(root, options);
+ };
+ /**
+ * Api for static tasks.
+ */
+ ReaderSync.prototype.staticApi = function (task, options) {
+ return this.fsAdapter.read(task.patterns, options.filter);
+ };
+ return ReaderSync;
+}(reader_1.default));
+exports.default = ReaderSync;
/***/ }),
-/* 694 */
+/* 693 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-var __extends = (this && this.__extends) || (function () {
- var extendStatics = function (d, b) {
- extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
- return extendStatics(d, b);
- };
- return function (d, b) {
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
- };
-})();
-Object.defineProperty(exports, "__esModule", { value: true });
-var fsStat = __webpack_require__(687);
-var fs_1 = __webpack_require__(691);
-var FileSystemSync = /** @class */ (function (_super) {
- __extends(FileSystemSync, _super);
- function FileSystemSync() {
- return _super !== null && _super.apply(this, arguments) || this;
- }
- /**
- * Use sync API to read entries for Task.
- */
- FileSystemSync.prototype.read = function (patterns, filter) {
- var _this = this;
- var entries = [];
- patterns.forEach(function (pattern) {
- var filepath = _this.getFullEntryPath(pattern);
- var entry = _this.getEntry(filepath, pattern);
- if (entry === null || !filter(entry)) {
- return;
- }
- entries.push(entry);
- });
- return entries;
- };
- /**
- * Return entry for the provided path.
- */
- FileSystemSync.prototype.getEntry = function (filepath, pattern) {
- try {
- var stat = this.getStat(filepath);
- return this.makeEntry(stat, pattern);
- }
- catch (err) {
- return null;
- }
- };
- /**
- * Return fs.Stats for the provided path.
- */
- FileSystemSync.prototype.getStat = function (filepath) {
- return fsStat.statSync(filepath, { throwErrorOnBrokenSymlinks: false });
- };
- return FileSystemSync;
-}(fs_1.default));
-exports.default = FileSystemSync;
+
+var __extends = (this && this.__extends) || (function () {
+ var extendStatics = function (d, b) {
+ extendStatics = Object.setPrototypeOf ||
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
+ return extendStatics(d, b);
+ };
+ return function (d, b) {
+ extendStatics(d, b);
+ function __() { this.constructor = d; }
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+ };
+})();
+Object.defineProperty(exports, "__esModule", { value: true });
+var fsStat = __webpack_require__(686);
+var fs_1 = __webpack_require__(690);
+var FileSystemSync = /** @class */ (function (_super) {
+ __extends(FileSystemSync, _super);
+ function FileSystemSync() {
+ return _super !== null && _super.apply(this, arguments) || this;
+ }
+ /**
+ * Use sync API to read entries for Task.
+ */
+ FileSystemSync.prototype.read = function (patterns, filter) {
+ var _this = this;
+ var entries = [];
+ patterns.forEach(function (pattern) {
+ var filepath = _this.getFullEntryPath(pattern);
+ var entry = _this.getEntry(filepath, pattern);
+ if (entry === null || !filter(entry)) {
+ return;
+ }
+ entries.push(entry);
+ });
+ return entries;
+ };
+ /**
+ * Return entry for the provided path.
+ */
+ FileSystemSync.prototype.getEntry = function (filepath, pattern) {
+ try {
+ var stat = this.getStat(filepath);
+ return this.makeEntry(stat, pattern);
+ }
+ catch (err) {
+ return null;
+ }
+ };
+ /**
+ * Return fs.Stats for the provided path.
+ */
+ FileSystemSync.prototype.getStat = function (filepath) {
+ return fsStat.statSync(filepath, { throwErrorOnBrokenSymlinks: false });
+ };
+ return FileSystemSync;
+}(fs_1.default));
+exports.default = FileSystemSync;
/***/ }),
-/* 695 */
+/* 694 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-/**
- * Flatten nested arrays (max depth is 2) into a non-nested array of non-array items.
- */
-function flatten(items) {
- return items.reduce(function (collection, item) { return [].concat(collection, item); }, []);
-}
-exports.flatten = flatten;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+/**
+ * Flatten nested arrays (max depth is 2) into a non-nested array of non-array items.
+ */
+function flatten(items) {
+ return items.reduce(function (collection, item) { return [].concat(collection, item); }, []);
+}
+exports.flatten = flatten;
/***/ }),
-/* 696 */
+/* 695 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-
-Object.defineProperty(exports, "__esModule", { value: true });
-var merge2 = __webpack_require__(300);
-/**
- * Merge multiple streams and propagate their errors into one stream in parallel.
- */
-function merge(streams) {
- var mergedStream = merge2(streams);
- streams.forEach(function (stream) {
- stream.on('error', function (err) { return mergedStream.emit('error', err); });
- });
- return mergedStream;
-}
-exports.merge = merge;
+
+Object.defineProperty(exports, "__esModule", { value: true });
+var merge2 = __webpack_require__(300);
+/**
+ * Merge multiple streams and propagate their errors into one stream in parallel.
+ */
+function merge(streams) {
+ var mergedStream = merge2(streams);
+ streams.forEach(function (stream) {
+ stream.on('error', function (err) { return mergedStream.emit('error', err); });
+ });
+ return mergedStream;
+}
+exports.merge = merge;
/***/ }),
-/* 697 */
+/* 696 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const path = __webpack_require__(4);
-const pathType = __webpack_require__(698);
+const pathType = __webpack_require__(697);
const getExtensions = extensions => extensions.length > 1 ? `{${extensions.join(',')}}` : extensions[0];
@@ -80173,13 +80161,13 @@ module.exports.sync = (input, opts) => {
/***/ }),
-/* 698 */
+/* 697 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const fs = __webpack_require__(134);
-const pify = __webpack_require__(699);
+const pify = __webpack_require__(698);
function type(fn, fn2, fp) {
if (typeof fp !== 'string') {
@@ -80222,7 +80210,7 @@ exports.symlinkSync = typeSync.bind(null, 'lstatSync', 'isSymbolicLink');
/***/ }),
-/* 699 */
+/* 698 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -80313,17 +80301,17 @@ module.exports = (obj, opts) => {
/***/ }),
-/* 700 */
+/* 699 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const fs = __webpack_require__(134);
const path = __webpack_require__(4);
-const fastGlob = __webpack_require__(523);
-const gitIgnore = __webpack_require__(701);
+const fastGlob = __webpack_require__(522);
+const gitIgnore = __webpack_require__(700);
const pify = __webpack_require__(233);
-const slash = __webpack_require__(702);
+const slash = __webpack_require__(701);
const DEFAULT_IGNORE = [
'**/node_modules/**',
@@ -80421,7 +80409,7 @@ module.exports.sync = options => {
/***/ }),
-/* 701 */
+/* 700 */
/***/ (function(module, exports) {
// A simple implementation of make-array
@@ -80890,7 +80878,7 @@ module.exports = options => new IgnoreBase(options)
/***/ }),
-/* 702 */
+/* 701 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -80908,7 +80896,7 @@ module.exports = input => {
/***/ }),
-/* 703 */
+/* 702 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -80921,7 +80909,7 @@ module.exports = input => {
-var isGlob = __webpack_require__(704);
+var isGlob = __webpack_require__(703);
module.exports = function hasGlob(val) {
if (val == null) return false;
@@ -80941,7 +80929,7 @@ module.exports = function hasGlob(val) {
/***/ }),
-/* 704 */
+/* 703 */
/***/ (function(module, exports, __webpack_require__) {
/*!
@@ -80972,17 +80960,17 @@ module.exports = function isGlob(str) {
/***/ }),
-/* 705 */
+/* 704 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const path = __webpack_require__(4);
const {constants: fsConstants} = __webpack_require__(134);
-const pEvent = __webpack_require__(706);
-const CpFileError = __webpack_require__(709);
-const fs = __webpack_require__(711);
-const ProgressEmitter = __webpack_require__(714);
+const pEvent = __webpack_require__(705);
+const CpFileError = __webpack_require__(708);
+const fs = __webpack_require__(710);
+const ProgressEmitter = __webpack_require__(713);
const cpFileAsync = async (source, destination, options, progressEmitter) => {
let readError;
@@ -81096,12 +81084,12 @@ module.exports.sync = (source, destination, options) => {
/***/ }),
-/* 706 */
+/* 705 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-const pTimeout = __webpack_require__(707);
+const pTimeout = __webpack_require__(706);
const symbolAsyncIterator = Symbol.asyncIterator || '@@asyncIterator';
@@ -81394,13 +81382,13 @@ module.exports.TimeoutError = pTimeout.TimeoutError;
/***/ }),
-/* 707 */
+/* 706 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-const pFinally = __webpack_require__(708);
+const pFinally = __webpack_require__(707);
class TimeoutError extends Error {
constructor(message) {
@@ -81458,7 +81446,7 @@ module.exports.TimeoutError = TimeoutError;
/***/ }),
-/* 708 */
+/* 707 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -81480,12 +81468,12 @@ module.exports = (promise, onFinally) => {
/***/ }),
-/* 709 */
+/* 708 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-const NestedError = __webpack_require__(710);
+const NestedError = __webpack_require__(709);
class CpFileError extends NestedError {
constructor(message, nested) {
@@ -81499,7 +81487,7 @@ module.exports = CpFileError;
/***/ }),
-/* 710 */
+/* 709 */
/***/ (function(module, exports, __webpack_require__) {
var inherits = __webpack_require__(112).inherits;
@@ -81555,16 +81543,16 @@ module.exports = NestedError;
/***/ }),
-/* 711 */
+/* 710 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
const {promisify} = __webpack_require__(112);
const fs = __webpack_require__(133);
-const makeDir = __webpack_require__(712);
-const pEvent = __webpack_require__(706);
-const CpFileError = __webpack_require__(709);
+const makeDir = __webpack_require__(711);
+const pEvent = __webpack_require__(705);
+const CpFileError = __webpack_require__(708);
const stat = promisify(fs.stat);
const lstat = promisify(fs.lstat);
@@ -81661,7 +81649,7 @@ exports.copyFileSync = (source, destination, flags) => {
/***/ }),
-/* 712 */
+/* 711 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -81669,7 +81657,7 @@ exports.copyFileSync = (source, destination, flags) => {
const fs = __webpack_require__(134);
const path = __webpack_require__(4);
const {promisify} = __webpack_require__(112);
-const semver = __webpack_require__(713);
+const semver = __webpack_require__(712);
const useNativeRecursiveOption = semver.satisfies(process.version, '>=10.12.0');
@@ -81824,7 +81812,7 @@ module.exports.sync = (input, options) => {
/***/ }),
-/* 713 */
+/* 712 */
/***/ (function(module, exports) {
exports = module.exports = SemVer
@@ -83426,7 +83414,7 @@ function coerce (version, options) {
/***/ }),
-/* 714 */
+/* 713 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -83467,7 +83455,7 @@ module.exports = ProgressEmitter;
/***/ }),
-/* 715 */
+/* 714 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -83513,12 +83501,12 @@ exports.default = module.exports;
/***/ }),
-/* 716 */
+/* 715 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-const pMap = __webpack_require__(717);
+const pMap = __webpack_require__(716);
const pFilter = async (iterable, filterer, options) => {
const values = await pMap(
@@ -83535,7 +83523,7 @@ module.exports.default = pFilter;
/***/ }),
-/* 717 */
+/* 716 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
@@ -83614,12 +83602,12 @@ module.exports.default = pMap;
/***/ }),
-/* 718 */
+/* 717 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
-const NestedError = __webpack_require__(710);
+const NestedError = __webpack_require__(709);
class CpyError extends NestedError {
constructor(message, nested) {
diff --git a/packages/osd-pm/package.json b/packages/osd-pm/package.json
index 74261eb778e0..5f50dc858b13 100644
--- a/packages/osd-pm/package.json
+++ b/packages/osd-pm/package.json
@@ -18,6 +18,7 @@
"@babel/plugin-proposal-object-rest-spread": "^7.16.5",
"@babel/preset-env": "^7.16.5",
"@babel/preset-typescript": "^7.16.5",
+ "@node-rs/xxhash": "^1.3.0",
"@types/cmd-shim": "^2.0.0",
"@types/cpy": "^5.1.0",
"@types/dedent": "^0.7.0",
@@ -28,7 +29,7 @@
"@types/lodash": "^4.14.170",
"@types/log-symbols": "^2.0.0",
"@types/ncp": "^2.0.1",
- "@types/node": "^14.17.32",
+ "@types/node": "~18.7.0",
"@types/ora": "^1.3.5",
"@types/read-pkg": "^4.0.0",
"@types/strip-ansi": "^5.2.1",
@@ -46,7 +47,7 @@
"execa": "^4.0.2",
"getopts": "^2.2.5",
"glob": "^7.1.7",
- "globby": "^8.0.1",
+ "globby": "^11.1.0",
"has-ansi": "^3.0.0",
"is-path-inside": "^3.0.2",
"lodash": "^4.17.21",
@@ -62,7 +63,7 @@
"tempy": "^0.3.0",
"typescript": "4.0.2",
"unlazy-loader": "^0.1.3",
- "webpack": "^4.41.5",
+ "webpack": "npm:@amoo-miki/webpack@4.46.0-rc.2",
"webpack-cli": "^4.9.2",
"write-pkg": "^4.0.0"
},
diff --git a/packages/osd-pm/src/utils/fs.ts b/packages/osd-pm/src/utils/fs.ts
index c29aacb2a901..cf9b1f3a8542 100644
--- a/packages/osd-pm/src/utils/fs.ts
+++ b/packages/osd-pm/src/utils/fs.ts
@@ -30,19 +30,15 @@
import cmdShimCb from 'cmd-shim';
import fs from 'fs';
+import { lstat, symlink, mkdir, unlink } from 'fs/promises';
import { ncp } from 'ncp';
import { dirname, relative } from 'path';
import { promisify } from 'util';
-const lstat = promisify(fs.lstat);
-export const readFile = promisify(fs.readFile);
-export const writeFile = promisify(fs.writeFile);
-const symlink = promisify(fs.symlink);
-export const chmod = promisify(fs.chmod);
+export { readFile, writeFile, chmod, unlink } from 'fs/promises';
+
const cmdShim = promisify(cmdShimCb);
-const mkdir = promisify(fs.mkdir);
export const mkdirp = async (path: string) => await mkdir(path, { recursive: true });
-export const unlink = promisify(fs.unlink);
export const copyDirectory = promisify(ncp);
async function statTest(path: string, block: (stats: fs.Stats) => boolean) {
diff --git a/packages/osd-pm/src/utils/project_checksums.ts b/packages/osd-pm/src/utils/project_checksums.ts
index e7d928ce3f73..e60590ee91ee 100644
--- a/packages/osd-pm/src/utils/project_checksums.ts
+++ b/packages/osd-pm/src/utils/project_checksums.ts
@@ -28,11 +28,9 @@
* under the License.
*/
-import Fs from 'fs';
+import { stat } from 'fs/promises';
import Crypto from 'crypto';
-import { promisify } from 'util';
-
import execa from 'execa';
import { YarnLock, resolveDepsForProject } from './yarn_lock';
@@ -45,7 +43,6 @@ export type ChecksumMap = Map;
/** map of [repo relative path to changed file, type of change] */
type Changes = Map;
-const statAsync = promisify(Fs.stat);
const projectBySpecificitySorter = (a: Project, b: Project) => b.path.length - a.path.length;
/** Get the changed files for a set of projects */
@@ -184,7 +181,7 @@ async function getChecksum(
return `${path}:deleted`;
}
- const stats = await statAsync(osd.getAbsolute(path));
+ const stats = await stat(osd.getAbsolute(path));
log.verbose(`[${project.name}] modified time ${stats.mtimeMs} for ${path}`);
return `${path}:${stats.mtimeMs}`;
})
diff --git a/packages/osd-pm/webpack.config.js b/packages/osd-pm/webpack.config.js
index 66b9e0a81ee4..fd8cdcbfde27 100644
--- a/packages/osd-pm/webpack.config.js
+++ b/packages/osd-pm/webpack.config.js
@@ -41,6 +41,7 @@ module.exports = {
path: path.resolve(__dirname, 'dist'),
filename: '[name].js',
libraryTarget: 'commonjs2',
+ hashFunction: 'Xxh64',
},
resolve: {
diff --git a/packages/osd-test/package.json b/packages/osd-test/package.json
index 69fa50828fc0..c1ee4f1687cd 100644
--- a/packages/osd-test/package.json
+++ b/packages/osd-test/package.json
@@ -31,7 +31,7 @@
"exit-hook": "^2.2.0",
"getopts": "^2.2.5",
"glob": "^7.1.7",
- "joi": "^13.5.2",
+ "joi": "^14.3.1",
"lodash": "^4.17.21",
"parse-link-header": "^2.0.0",
"rxjs": "^6.5.5",
diff --git a/packages/osd-test/src/functional_test_runner/lib/suite_tracker.test.ts b/packages/osd-test/src/functional_test_runner/lib/suite_tracker.test.ts
index cc628b9de811..9ba16ca6407c 100644
--- a/packages/osd-test/src/functional_test_runner/lib/suite_tracker.test.ts
+++ b/packages/osd-test/src/functional_test_runner/lib/suite_tracker.test.ts
@@ -31,7 +31,19 @@
import fs from 'fs';
import { join, resolve } from 'path';
-jest.mock('fs');
+jest.mock('fs', () => {
+ const mockedFs: object = jest.createMockFromModule('fs');
+ const realFs = jest.requireActual('fs');
+
+ return {
+ __esModules: true,
+ ...mockedFs,
+ // Both needed by @osd/cross-platform
+ realpathSync: realFs.realpathSync,
+ readFileSync: realFs.readFileSync,
+ };
+});
+
jest.mock('@osd/utils', () => {
return { REPO_ROOT: '/dev/null/root' };
});
diff --git a/packages/osd-ui-framework/Gruntfile.js b/packages/osd-ui-framework/Gruntfile.js
index b52e1430f56e..9ad26b578e08 100644
--- a/packages/osd-ui-framework/Gruntfile.js
+++ b/packages/osd-ui-framework/Gruntfile.js
@@ -28,7 +28,7 @@
* under the License.
*/
-const sass = require('sass');
+const sass = require('node-sass');
const postcss = require('postcss');
const postcssConfig = require('@osd/optimizer/postcss.config.js');
diff --git a/packages/osd-ui-framework/package.json b/packages/osd-ui-framework/package.json
index 3ebc09f4a8ad..ffd624757392 100644
--- a/packages/osd-ui-framework/package.json
+++ b/packages/osd-ui-framework/package.json
@@ -30,7 +30,7 @@
"grunt-babel": "^8.0.0",
"grunt-contrib-clean": "^2.0.0",
"grunt-contrib-copy": "^1.0.0",
- "sass": "~1.26.11",
+ "node-sass": "^8.0.0",
"postcss": "^8.4.5",
"sinon": "^7.4.2"
}
diff --git a/packages/osd-ui-shared-deps/package.json b/packages/osd-ui-shared-deps/package.json
index 61f7008fbc0f..a4924657cb1e 100644
--- a/packages/osd-ui-shared-deps/package.json
+++ b/packages/osd-ui-shared-deps/package.json
@@ -17,7 +17,7 @@
"abortcontroller-polyfill": "^1.4.0",
"angular": "^1.8.2",
"axios": "^0.27.2",
- "compression-webpack-plugin": "^4.0.0",
+ "compression-webpack-plugin": "npm:@amoo-miki/compression-webpack-plugin@4.0.1-rc.1",
"core-js": "^3.6.5",
"custom-event-polyfill": "^0.3.0",
"jquery": "^3.5.0",
@@ -38,6 +38,7 @@
"whatwg-fetch": "^3.0.0"
},
"devDependencies": {
+ "@node-rs/xxhash": "^1.3.0",
"@osd/babel-preset": "1.0.0",
"@osd/dev-utils": "1.0.0",
"babel-plugin-transform-react-remove-prop-types": "^0.4.24",
@@ -45,6 +46,6 @@
"del": "^6.1.1",
"loader-utils": "^2.0.4",
"val-loader": "^2.1.2",
- "webpack": "^4.41.5"
+ "webpack": "npm:@amoo-miki/webpack@4.46.0-rc.2"
}
}
diff --git a/packages/osd-ui-shared-deps/webpack.config.js b/packages/osd-ui-shared-deps/webpack.config.js
index 5cd48010215d..397fbe12cd4b 100644
--- a/packages/osd-ui-shared-deps/webpack.config.js
+++ b/packages/osd-ui-shared-deps/webpack.config.js
@@ -57,6 +57,7 @@ exports.getWebpackConfig = ({ dev = false } = {}) => ({
devtoolModuleFilenameTemplate: (info) =>
`osd-ui-shared-deps/${Path.relative(REPO_ROOT, info.absoluteResourcePath)}`,
library: '__osdSharedDeps__',
+ hashFunction: 'Xxh64',
},
module: {
diff --git a/release-notes/opensearch-dashboards.release-notes-1.3.10.md b/release-notes/opensearch-dashboards.release-notes-1.3.10.md
new file mode 100644
index 000000000000..be08d46aac93
--- /dev/null
+++ b/release-notes/opensearch-dashboards.release-notes-1.3.10.md
@@ -0,0 +1,33 @@
+# Version 1.3.10 Release Notes
+
+### π‘ Security
+
+- [CVE-2020-15366][1.x] Bump ajv from 4.11.8 to 6.12.6 ([#4035](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4035))
+- [CVE-2022-48285][1.x] Bump jszip from 3.7.1 to 3.10.1 ([#4011](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4011))
+- [CVE-2021-35065][1.x] Bump glob-parent from 6.0.0 to 6.0.2 ([#4005](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4005))
+- [CVE-2022-25851][1.x] Bump jpeg-js from 0.4.1 to 0.4.4 ([#3860](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3860))
+- [CVE-2022-25858][1.x] Bump terser from 4.8.0 to 4.8.1 ([#3786](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3786))
+- [CVE-2021-23490][1.x] Bump parse-link-header from 1.0.1 to 2.0.0 ([#3820](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3820))
+- [CVE-2021-3765][1.x] Bump validator from 8.2.0 to 13.9.0 ([#3753](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3753))
+- [CVE-2022-25758][1.x] Bump scss-tokenizer from 0.3.0 to 0.4.3 ([#3789](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3789))
+- [CVE-2021-3803][1.x] Bump nth-check from 1.0.2 to 2.0.1 ([#3745](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3745))
+- Bump highlight.js from 9.18.5 to 10.7.3 to solve security concerns οΌ[#4062](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4062))
+
+### π Features/Enhancements
+
+- Add tooltip to help icon ([#3872](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3872))
+
+### π Bug Fixes
+
+- [TSVB] Fix the link to "serial differencing aggregation" documentation ([#3503](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3503))
+
+### π Documentation
+
+- Update jest documentation links ([#3939](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3939))
+
+### π Maintenance
+
+- Add threshold to code coverage changes for project ([#4050](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/4050))
+- Temporarily hardcode chromedriver to 112.0.0 to enable all ftr tests ([#4039]())
+- Update MAINTAINERS.md and CODEOWNERS ([#3938](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3938))
+- Add opensearch-dashboards-docker-dev to .gitignore ([#3781](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3781))
diff --git a/release-notes/opensearch-dashboards.release-notes-2.7.0.md b/release-notes/opensearch-dashboards.release-notes-2.7.0.md
index 3ad55fe4d807..60eda3832436 100644
--- a/release-notes/opensearch-dashboards.release-notes-2.7.0.md
+++ b/release-notes/opensearch-dashboards.release-notes-2.7.0.md
@@ -76,7 +76,6 @@
### πͺ Refactoring
- Remove automatic addition of `osd-version` header to requests outside of OpenSearch Dashboards ([#3643](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3643))
-- [Console] Replace jQuery usage in console plugin with native methods ([#3733](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3733))
- [Doc Links] Clean up docs_link_service organization so that strings are in the right categories. ([#3685](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3685))
- [I18n] Fix Listr type errors and error handlers ([#3629](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3629))
- [Multiple DataSource] Refactor dev tool console to use opensearch-js client to send requests ([#3544](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/3544))
diff --git a/scripts/bwc/opensearch_dashboards_service.sh b/scripts/bwc/opensearch_dashboards_service.sh
index 79f1c56708b4..784fbcaa594b 100755
--- a/scripts/bwc/opensearch_dashboards_service.sh
+++ b/scripts/bwc/opensearch_dashboards_service.sh
@@ -29,4 +29,4 @@ function check_dashboards_status {
cd "$DIR"
check_status $DASHBOARDS_PATH "$DASHBOARDS_MSG" $DASHBOARDS_URL "$OPENSEARCH_ARGS" >> /dev/null 2>&1
echo "OpenSearch Dashboards is up!"
-}
+}
diff --git a/scripts/bwc/utils.sh b/scripts/bwc/utils.sh
index fea47b14759a..c6a4ef739307 100755
--- a/scripts/bwc/utils.sh
+++ b/scripts/bwc/utils.sh
@@ -9,11 +9,12 @@ function open_artifact() {
artifact_dir=$1
artifact=$2
cd $artifact_dir
-
+
# check if artifact provided is URL or attempt if passing by absolute path
if curl -I -L $artifact; then
curl -L $artifact | tar -xz --strip-components=1
else
+ echo "Artifact is not a URL; attempting to unarchive a local file..."
tar -xf $artifact --strip-components=1
fi
}
@@ -45,14 +46,25 @@ function print_txt() {
}
# this function is used to check the running status of OpenSearch or OpenSearch Dashboards
-# $1 is the path to the tmp file which saves the running status
+# $1 is the path to the tmp file which saves the running status
# $2 is the error msg to check
# $3 is the url to curl
# $4 contains arguments that need to be passed to the curl command
function check_status() {
- while [ ! -f $1 ] || ! grep -q "$2" $1; do
- if [ -f $1 ]; then rm $1; fi
- curl $3 $4 > $1 || true
+ # Calculate end time as 180s from now
+ check_status_end_time=$(expr 180 + "$(date '+%s')")
+
+ rm -rf $1
+
+ while [ ! -f $1 ] || ! grep -q "$2" $1; do
+ if [ -f $1 ]; then rm $1; fi
+ curl $3 $4 > $1 || true
+
+ # Stop checking after $check_status_end_time
+ if [ $check_status_end_time -lt $(date '+%s') ]; then
+ echo "Error: Status check has timed out"
+ exit 1
+ fi
done
rm $1
}
@@ -62,7 +74,7 @@ function check_status() {
function upload_data() {
rm -rf "$OPENSEARCH_DIR/data"
cd $OPENSEARCH_DIR
- cp "$CWD/cypress/test-data/$DASHBOARDS_TYPE/$1.tar.gz" .
+ cp "$CWD/cypress/test-data/$DASHBOARDS_TYPE/$1.tar.gz" .
tar -xvf "$OPENSEARCH_DIR/$1.tar.gz" >> /dev/null 2>&1
rm "$1.tar.gz"
echo "Data has been uploaded and ready to test"
@@ -75,6 +87,6 @@ function get_dashboards_package_version() {
| awk -F: '{ print $2 }' \
| sed 's/[",]//g' \
| tr -d [:space:])
-
+
echo "$DASHBOARDS_PACKAGE_VERSION"
}
diff --git a/scripts/jest.js b/scripts/jest.js
index 53c687e51a84..80f269c72498 100755
--- a/scripts/jest.js
+++ b/scripts/jest.js
@@ -38,7 +38,7 @@
//
// node scripts/jest --coverage
//
-// See all cli options in https://facebook.github.io/jest/docs/cli.html
+// See all cli options in https://jestjs.io/docs/cli
var resolve = require('path').resolve;
process.argv.push('--config', resolve(__dirname, '../src/dev/jest/config.js'));
diff --git a/scripts/jest_integration.js b/scripts/jest_integration.js
index f5bc937c4d79..e0614aef7a11 100755
--- a/scripts/jest_integration.js
+++ b/scripts/jest_integration.js
@@ -38,7 +38,12 @@
//
// node scripts/jest_integration --coverage
//
-// See all cli options in https://facebook.github.io/jest/docs/cli.html
+// See all cli options in https://jestjs.io/docs/cli
+
+/* Increase the max listeners
+ * Numerous listeners are added by `root.start()` that are never removed.
+ */
+process.setMaxListeners(Infinity);
var resolve = require('path').resolve;
process.argv.push('--config', resolve(__dirname, '../src/dev/jest/config.integration.js'));
diff --git a/scripts/use_node b/scripts/use_node
index f39a39434db1..48e7e2858200 100755
--- a/scripts/use_node
+++ b/scripts/use_node
@@ -57,11 +57,17 @@ elif [ ! -z "$NODE_HOME" ]; then
NODE_ERROR_MSG="in NODE_HOME"
NODE_ERROR_SHOW=true
else
+ # Set these variables outside, as catchalls, to show meaningful errors if needed
NODE="$OSD_HOME/node/bin/node"
NODE_ERROR_MSG="bundled with OpenSearch Dashboards"
# A bin folder at the root is only present in release builds that have a bundled Node.js binary
- if [ -x "OSD_HOME/bin" ]; then
+ if [ -d "${OSD_HOME}/bin" ]; then
NODE_ERROR_SHOW=true
+ # Not all operating systems can run the latest Node.js and the fallback is for them
+ "${NODE}" -v 2> /dev/null
+ if [ $? -ne 0 ] && [ -d "${OSD_HOME}/node/fallback" ]; then
+ NODE="$OSD_HOME/node/fallback/bin/node"
+ fi
fi
fi
@@ -75,7 +81,7 @@ else
fi
if [ ! -x "$NODE" ]; then
- # Irrespective of NODE_ERROR_SHOW, show the error
+ # Irrespective of NODE_ERROR_SHOW, if NODE is not found or executable, show the error
echo "Could not find a Node.js runtime binary $NODE_ERROR_MSG or on the system" >&2
exit 1
fi
@@ -91,7 +97,7 @@ fi
# If a file path was provided for execution, prefix with OSD_HOME; use relative paths to avoid the need for this.
if [ ! -z "$OSD_USE_NODE_JS_FILE_PATH" ]; then
- NODE_OPTIONS="$OSD_NODE_OPTS_PREFIX $OSD_NODE_OPTS $NODE_OPTIONS" "${NODE}" "${OSD_HOME}${OSD_USE_NODE_JS_FILE_PATH}" "${@}"
+ NODE_OPTIONS="$OSD_NODE_OPTS_PREFIX $OSD_NODE_OPTS $NODE_OPTIONS" exec "${NODE}" "${OSD_HOME}${OSD_USE_NODE_JS_FILE_PATH}" "${@}"
elif [ $# -ne 0 ]; then
- NODE_OPTIONS="$OSD_NODE_OPTS_PREFIX $OSD_NODE_OPTS $NODE_OPTIONS" "${NODE}" "${@}"
+ NODE_OPTIONS="$OSD_NODE_OPTS_PREFIX $OSD_NODE_OPTS $NODE_OPTIONS" exec "${NODE}" "${@}"
fi
diff --git a/src/cli/cluster/cluster_manager.test.ts b/src/cli/cluster/cluster_manager.test.ts
index 350d863c9892..7c83d9194501 100644
--- a/src/cli/cluster/cluster_manager.test.ts
+++ b/src/cli/cluster/cluster_manager.test.ts
@@ -31,6 +31,7 @@
import * as Rx from 'rxjs';
import { mockCluster } from './cluster_manager.test.mocks';
+import '@osd/optimizer/target/__mocks__/lmdb';
jest.mock('readline', () => ({
createInterface: jest.fn(() => ({
diff --git a/src/cli/serve/integration_tests/invalid_config.test.ts b/src/cli/serve/integration_tests/invalid_config.test.ts
index 87ffd37d038e..4fe27ccd39ef 100644
--- a/src/cli/serve/integration_tests/invalid_config.test.ts
+++ b/src/cli/serve/integration_tests/invalid_config.test.ts
@@ -64,7 +64,7 @@ describe('cli invalid config support', function () {
.split('\n')
.filter(Boolean)
.map((line) => JSON.parse(line) as LogEntry)
- .filter((line) => line.tags.includes('fatal'))
+ .filter((line) => line.tags?.includes?.('fatal'))
.map((obj) => ({
...obj,
pid: '## PID ##',
diff --git a/src/cli/serve/integration_tests/reload_logging_config.test.ts b/src/cli/serve/integration_tests/reload_logging_config.test.ts
index fb3c63ffc71d..5950cb1fdfb0 100644
--- a/src/cli/serve/integration_tests/reload_logging_config.test.ts
+++ b/src/cli/serve/integration_tests/reload_logging_config.test.ts
@@ -36,7 +36,7 @@ import Del from 'del';
import * as Rx from 'rxjs';
import { map, filter, take } from 'rxjs/operators';
-import { safeDump } from 'js-yaml';
+import { dump } from 'js-yaml';
import { getConfigFromFiles } from '@osd/config';
const legacyConfig = follow('__fixtures__/reload_logging_config/opensearch_dashboards.test.yml');
@@ -89,7 +89,7 @@ function createConfigManager(configPath: string) {
return {
modify(fn: (input: Record) => Record) {
const oldContent = getConfigFromFiles([configPath]);
- const yaml = safeDump(fn(oldContent));
+ const yaml = dump(fn(oldContent));
Fs.writeFileSync(configPath, yaml);
},
};
diff --git a/src/cli_plugin/install/cleanup.js b/src/cli_plugin/install/cleanup.js
index b23b28fc5295..c93cad047f6d 100644
--- a/src/cli_plugin/install/cleanup.js
+++ b/src/cli_plugin/install/cleanup.js
@@ -28,33 +28,29 @@
* under the License.
*/
-import del from 'del';
-import fs from 'fs';
+import { rm, access } from 'fs/promises';
+import { rmSync, constants } from 'fs';
-export function cleanPrevious(settings, logger) {
- return new Promise(function (resolve, reject) {
- try {
- fs.statSync(settings.workingPath);
-
- logger.log('Found previous install attempt. Deleting...');
- try {
- del.sync(settings.workingPath, { force: true });
- } catch (e) {
- reject(e);
- }
- resolve();
- } catch (e) {
- if (e.code !== 'ENOENT') reject(e);
+const exists = async (loc) => {
+ try {
+ await access(loc, constants.W_OK);
+ return true;
+ } catch (e) {
+ if (e.code !== 'ENOENT') throw e;
+ }
+};
+export const cleanPrevious = async (settings, logger) => {
+ const workingPathExists = await exists(settings.workingPath);
- resolve();
- }
- });
-}
+ if (workingPathExists) {
+ logger.log('Found previous install attempt. Deleting...');
+ return await rm(settings.workingPath, { recursive: true });
+ }
+};
export function cleanArtifacts(settings) {
- // delete the working directory.
- // At this point we're bailing, so swallow any errors on delete.
+ // Delete the working directory; at this point we're bailing, so swallow any errors on delete.
try {
- del.sync(settings.workingPath);
+ rmSync(settings.workingPath, { recursive: true, force: true });
} catch (e) {} // eslint-disable-line no-empty
}
diff --git a/src/cli_plugin/install/cleanup.test.js b/src/cli_plugin/install/cleanup.test.js
index f05d69d1621b..f1453d0ff129 100644
--- a/src/cli_plugin/install/cleanup.test.js
+++ b/src/cli_plugin/install/cleanup.test.js
@@ -28,9 +28,11 @@
* under the License.
*/
-import sinon from 'sinon';
-import fs from 'fs';
-import del from 'del';
+import fs from 'fs/promises';
+import { rmSync } from 'fs';
+
+jest.mock('fs');
+jest.mock('fs/promises');
import { cleanPrevious, cleanArtifacts } from './cleanup';
import { Logger } from '../lib/logger';
@@ -41,105 +43,116 @@ describe('opensearchDashboards cli', function () {
const settings = {
workingPath: 'dummy',
};
+ const logger = new Logger(settings);
describe('cleanPrevious', function () {
- let errorStub;
- let logger;
-
- beforeEach(function () {
- errorStub = sinon.stub();
- logger = new Logger(settings);
- sinon.stub(logger, 'log');
- sinon.stub(logger, 'error');
- });
-
afterEach(function () {
- logger.log.restore();
- logger.error.restore();
- fs.statSync.restore();
- del.sync.restore();
+ jest.resetAllMocks();
});
- it('should resolve if the working path does not exist', function () {
- sinon.stub(del, 'sync');
- sinon.stub(fs, 'statSync').callsFake(() => {
- const error = new Error('ENOENT');
- error.code = 'ENOENT';
- throw error;
+ it('should resolve if the working path does not exist', async () => {
+ fs.access.mockImplementation(() => {
+ const notFoundError = new Error('ENOENT');
+ notFoundError.code = 'ENOENT';
+ throw notFoundError;
});
- return cleanPrevious(settings, logger)
- .catch(errorStub)
- .then(function () {
- expect(errorStub.called).toBe(false);
- });
+ const exceptionCatcher = jest.fn();
+
+ try {
+ await cleanPrevious(settings, logger);
+ } catch (e) {
+ exceptionCatcher();
+ }
+
+ expect(fs.rm).not.toHaveBeenCalled();
+ expect(exceptionCatcher).not.toHaveBeenCalled();
});
- it('should rethrow any exception except ENOENT from fs.statSync', function () {
- sinon.stub(del, 'sync');
- sinon.stub(fs, 'statSync').throws(new Error('An Unhandled Error'));
+ it('should rethrow any exceptions from accessing the folders except ENOENT', async () => {
+ fs.access.mockImplementation(() => {
+ const noAccessError = new Error('EACCES');
+ noAccessError.code = 'EACCES';
+ throw noAccessError;
+ });
+
+ const exceptionCatcher = jest.fn();
- errorStub = sinon.stub();
- return cleanPrevious(settings, logger)
- .catch(errorStub)
- .then(function () {
- expect(errorStub.called).toBe(true);
- });
+ try {
+ await cleanPrevious(settings, logger);
+ } catch (e) {
+ exceptionCatcher();
+ }
+
+ expect(fs.rm).not.toHaveBeenCalled();
+ expect(exceptionCatcher).toHaveBeenCalled();
});
- it('should log a message if there was a working directory', function () {
- sinon.stub(del, 'sync');
- sinon.stub(fs, 'statSync');
-
- return cleanPrevious(settings, logger)
- .catch(errorStub)
- .then(function () {
- expect(logger.log.calledWith('Found previous install attempt. Deleting...')).toBe(
- true
- );
- });
+ it('should log a message if there was a working directory', async () => {
+ jest.spyOn(logger, 'log');
+ const exceptionCatcher = jest.fn();
+
+ try {
+ await cleanPrevious(settings, logger);
+ } catch (e) {
+ exceptionCatcher();
+ }
+
+ expect(logger.log).toHaveBeenCalledWith('Found previous install attempt. Deleting...');
+ expect(fs.rm).toHaveBeenCalled();
+ expect(exceptionCatcher).not.toHaveBeenCalled();
});
- it('should rethrow any exception from del.sync', function () {
- sinon.stub(fs, 'statSync');
- sinon.stub(del, 'sync').throws(new Error('I am an error thrown by del'));
+ it('should rethrow any exception from deleting the folder', async () => {
+ fs.rm.mockImplementation(() => {
+ const dummyError = new Error('EDUMMY');
+ dummyError.code = 'EDUMMY';
+ throw dummyError;
+ });
+
+ const exceptionCatcher = jest.fn();
- errorStub = sinon.stub();
- return cleanPrevious(settings, logger)
- .catch(errorStub)
- .then(function () {
- expect(errorStub.called).toBe(true);
- });
+ try {
+ await cleanPrevious(settings, logger);
+ } catch (e) {
+ exceptionCatcher();
+ }
+
+ expect(fs.rm).toHaveBeenCalled();
+ expect(exceptionCatcher).toHaveBeenCalled();
});
- it('should resolve if the working path is deleted', function () {
- sinon.stub(del, 'sync');
- sinon.stub(fs, 'statSync');
+ it('should resolve if the working path is deleted', async () => {
+ const exceptionCatcher = jest.fn();
+
+ try {
+ await cleanPrevious(settings, logger);
+ } catch (e) {
+ exceptionCatcher();
+ }
- return cleanPrevious(settings, logger)
- .catch(errorStub)
- .then(function () {
- expect(errorStub.called).toBe(false);
- });
+ expect(fs.rm).toHaveBeenCalled();
+ expect(exceptionCatcher).not.toHaveBeenCalled();
});
});
describe('cleanArtifacts', function () {
- beforeEach(function () {});
-
afterEach(function () {
- del.sync.restore();
+ jest.resetAllMocks();
});
- it('should attempt to delete the working directory', function () {
- sinon.stub(del, 'sync');
-
+ it('should attempt to delete the working directory', () => {
cleanArtifacts(settings);
- expect(del.sync.calledWith(settings.workingPath)).toBe(true);
+
+ expect(rmSync).toHaveBeenCalledWith(settings.workingPath, expect.anything());
});
- it('should swallow any errors thrown by del.sync', function () {
- sinon.stub(del, 'sync').throws(new Error('Something bad happened.'));
+ it('should swallow any errors thrown by del.sync', () => {
+ rmSync.mockImplementation(() => {
+ const dummyError = new Error('EDUMMY');
+ dummyError.code = 'EDUMMY';
+ throw dummyError;
+ });
expect(() => cleanArtifacts(settings)).not.toThrow();
});
diff --git a/src/core/public/chrome/chrome_service.test.ts b/src/core/public/chrome/chrome_service.test.ts
index 6ef1f30605a3..b8635f5a070f 100644
--- a/src/core/public/chrome/chrome_service.test.ts
+++ b/src/core/public/chrome/chrome_service.test.ts
@@ -50,6 +50,9 @@ class FakeApp implements App {
const store = new Map();
const originalLocalStorage = window.localStorage;
+// @ts-expect-error to allow redeclaring a readonly prop
+delete window.localStorage;
+
(window as any).localStorage = {
setItem: (key: string, value: string) => store.set(String(key), String(value)),
getItem: (key: string) => store.get(String(key)),
diff --git a/src/core/public/chrome/recently_accessed/recently_accessed_service.test.ts b/src/core/public/chrome/recently_accessed/recently_accessed_service.test.ts
index 1a0772174af1..7046d5efc236 100644
--- a/src/core/public/chrome/recently_accessed/recently_accessed_service.test.ts
+++ b/src/core/public/chrome/recently_accessed/recently_accessed_service.test.ts
@@ -66,6 +66,9 @@ describe('RecentlyAccessed#start()', () => {
let originalLocalStorage: Storage;
beforeAll(() => {
originalLocalStorage = window.localStorage;
+
+ // @ts-expect-error to allow redeclaring a readonly prop
+ delete window.localStorage;
// @ts-expect-error
window.localStorage = new LocalStorageMock();
});
diff --git a/src/core/public/chrome/ui/header/__snapshots__/header.test.tsx.snap b/src/core/public/chrome/ui/header/__snapshots__/header.test.tsx.snap
index 6486e207ed37..4c2beb329a98 100644
--- a/src/core/public/chrome/ui/header/__snapshots__/header.test.tsx.snap
+++ b/src/core/public/chrome/ui/header/__snapshots__/header.test.tsx.snap
@@ -5415,14 +5415,10 @@ exports[`Header handles visibility and lock changes 1`] = `
aria-label="Help menu"
onClick={[Function]}
>
-
}
@@ -5474,9 +5470,6 @@ exports[`Header handles visibility and lock changes 1`] = `
>
-
@@ -5519,21 +5512,12 @@ exports[`Header handles visibility and lock changes 1`] = `
>
-
-
-
@@ -10674,14 +10658,10 @@ exports[`Header renders condensed header 1`] = `
aria-label="Help menu"
onClick={[Function]}
>
-
}
@@ -10733,9 +10713,6 @@ exports[`Header renders condensed header 1`] = `
>
-
@@ -10778,21 +10755,12 @@ exports[`Header renders condensed header 1`] = `
>
-
-
-
diff --git a/src/core/public/chrome/ui/header/__snapshots__/header_help_menu.test.tsx.snap b/src/core/public/chrome/ui/header/__snapshots__/header_help_menu.test.tsx.snap
index 5406fbf6abaa..036e2b4ee0ce 100644
--- a/src/core/public/chrome/ui/header/__snapshots__/header_help_menu.test.tsx.snap
+++ b/src/core/public/chrome/ui/header/__snapshots__/header_help_menu.test.tsx.snap
@@ -1622,14 +1622,10 @@ exports[`Header help menu hides survey link 1`] = `
aria-label="Help menu"
onClick={[Function]}
>
-
}
@@ -1681,9 +1677,6 @@ exports[`Header help menu hides survey link 1`] = `
>
-
@@ -1726,21 +1719,12 @@ exports[`Header help menu hides survey link 1`] = `
>
-
-
-
@@ -3798,14 +3782,10 @@ exports[`Header help menu renders survey link 1`] = `
aria-label="Help menu"
onClick={[Function]}
>
-
}
@@ -3857,9 +3837,6 @@ exports[`Header help menu renders survey link 1`] = `
>
-
@@ -3902,21 +3879,12 @@ exports[`Header help menu renders survey link 1`] = `
>
-
-
-
diff --git a/src/core/public/chrome/ui/header/header_help_menu.tsx b/src/core/public/chrome/ui/header/header_help_menu.tsx
index f0be769937f5..0eba4c0c2673 100644
--- a/src/core/public/chrome/ui/header/header_help_menu.tsx
+++ b/src/core/public/chrome/ui/header/header_help_menu.tsx
@@ -330,9 +330,8 @@ class HeaderHelpMenuUI extends Component {
})}
onClick={this.onMenuButtonClick}
>
-
{
+ private _isMounted: boolean = false;
+
constructor(props: StatusAppProps) {
super(props);
this.state = {
@@ -68,15 +70,25 @@ export class StatusApp extends Component {
}
async componentDidMount() {
+ this._isMounted = true;
const { http, notifications } = this.props;
try {
const data = await loadStatus({ http, notifications });
+
+ if (!this._isMounted) return;
+
this.setState({ loading: false, fetchError: false, data });
} catch (e) {
+ if (!this._isMounted) return;
+
this.setState({ fetchError: true, loading: false, data: null });
}
}
+ componentWillUnmount() {
+ this._isMounted = false;
+ }
+
render() {
const { loading, fetchError, data } = this.state;
diff --git a/src/core/public/doc_links/doc_links_service.ts b/src/core/public/doc_links/doc_links_service.ts
index 2faf70d54e82..7dd8c6561ade 100644
--- a/src/core/public/doc_links/doc_links_service.ts
+++ b/src/core/public/doc_links/doc_links_service.ts
@@ -421,7 +421,6 @@ export class DocLinksService {
visualize: {
// https://opensearch.org/docs/latest/dashboards/visualize/viz-index/
guide: `${OPENSEARCH_WEBSITE_DOCS}visualize/viz-index/`,
- timelineDeprecation: `${OPENSEARCH_WEBSITE_DOCS}`,
},
},
noDocumentation: {
@@ -571,7 +570,6 @@ export class DocLinksService {
reIndex: {
rethrottle: `${OPENSEARCH_WEBSITE_DOCS}`,
},
- timelineDeprecation: `${OPENSEARCH_WEBSITE_DOCS}`,
apmServer: `${OPENSEARCH_WEBSITE_DOCS}`,
tutorial: {
loadDataTutorial: `${OPENSEARCH_WEBSITE_DOCS}`,
@@ -919,7 +917,6 @@ export interface DocLinksStart {
readonly reIndex: {
readonly rethrottle: string;
};
- readonly timelineDeprecation: string;
readonly apmServer: string;
readonly tutorial: {
readonly loadDataTutorial: string;
diff --git a/src/core/public/rendering/_base.scss b/src/core/public/rendering/_base.scss
index e59008f08259..1333e48f6ca5 100644
--- a/src/core/public/rendering/_base.scss
+++ b/src/core/public/rendering/_base.scss
@@ -5,7 +5,6 @@
*/
// SASSTODO: Naming here is too embedded and high up that changing them could cause major breaks
#opensearch-dashboards-body {
- overflow-x: hidden;
min-height: 100%;
}
diff --git a/src/core/public/rendering/app_containers.test.tsx b/src/core/public/rendering/app_containers.test.tsx
index fd43c79514c1..157253f5f757 100644
--- a/src/core/public/rendering/app_containers.test.tsx
+++ b/src/core/public/rendering/app_containers.test.tsx
@@ -43,6 +43,7 @@ describe('AppWrapper', () => {
expect(component.getDOMNode()).toMatchInlineSnapshot(`
app-content
@@ -53,6 +54,7 @@ describe('AppWrapper', () => {
expect(component.getDOMNode()).toMatchInlineSnapshot(`
app-content
@@ -63,6 +65,7 @@ describe('AppWrapper', () => {
expect(component.getDOMNode()).toMatchInlineSnapshot(`
app-content
diff --git a/src/core/public/rendering/app_containers.tsx b/src/core/public/rendering/app_containers.tsx
index dab85769bd0b..8ccf795f8dcf 100644
--- a/src/core/public/rendering/app_containers.tsx
+++ b/src/core/public/rendering/app_containers.tsx
@@ -37,7 +37,11 @@ export const AppWrapper: React.FunctionComponent<{
chromeVisible$: Observable;
}> = ({ chromeVisible$, children }) => {
const visible = useObservable(chromeVisible$);
- return {children}
;
+ return (
+
+ {children}
+
+ );
};
export const AppContainer: React.FunctionComponent<{
diff --git a/src/core/server/bootstrap.ts b/src/core/server/bootstrap.ts
index 8defb17d2030..b36caa518bb0 100644
--- a/src/core/server/bootstrap.ts
+++ b/src/core/server/bootstrap.ts
@@ -29,11 +29,14 @@
*/
import chalk from 'chalk';
-import { isMaster as isClusterManager } from 'cluster';
+import cluster from 'cluster';
import { CliArgs, Env, RawConfigService } from './config';
import { Root } from './root';
import { CriticalError } from './errors';
+// ToDo: `isMaster` is a Node 14- prop; remove it when Node 18+ is the only engine supported
+const isClusterManager = cluster.isPrimary ?? cluster.isMaster;
+
interface OpenSearchDashboardsFeatures {
// Indicates whether we can run OpenSearch Dashboards in a so called cluster mode in which
// OpenSearch Dashboards is run as a "worker" process together with optimizer "worker" process
@@ -63,7 +66,7 @@ export async function bootstrap({
features,
}: BootstrapArgs) {
if (cliArgs.repl && !features.isReplModeSupported) {
- onRootShutdown('OpenSearch Dashboards REPL mode can only be run in development mode.');
+ terminate('OpenSearch Dashboards REPL mode can only be run in development mode.');
}
if (cliArgs.optimize) {
@@ -96,8 +99,8 @@ export async function bootstrap({
// This is only used by the LogRotator service
// in order to be able to reload the log configuration
// under the cluster mode
- process.on('message', (msg) => {
- if (!msg || msg.reloadLoggingConfig !== true) {
+ process.on('message', (msg: any) => {
+ if (msg?.reloadLoggingConfig !== true) {
return;
}
@@ -133,16 +136,27 @@ export async function bootstrap({
}
}
+/* `onRootShutdown` is called multiple times due to catching and rethrowing of exceptions
+ * in Root and bootstrap. The debouncer below is to make sure every catch and rethrow is
+ * executed before calling `terminate`.
+ */
+let shutdownTimer: NodeJS.Timeout;
function onRootShutdown(reason?: any) {
+ clearTimeout(shutdownTimer);
+ shutdownTimer = setTimeout(() => terminate(reason), 300);
+}
+
+function terminate(reason?: any) {
+ const exitCode =
+ reason === undefined ? 0 : reason instanceof CriticalError ? reason.processExitCode : 1;
+
if (reason !== undefined) {
// There is a chance that logger wasn't configured properly and error that
// that forced root to shut down could go unnoticed. To prevent this we always
// mirror such fatal errors in standard output with `console.error`.
// eslint-disable-next-line
console.error(`\n${chalk.white.bgRed(' FATAL ')} ${reason}\n`);
-
- process.exit(reason instanceof CriticalError ? reason.processExitCode : 1);
}
- process.exit(0);
+ process.exit(exitCode);
}
diff --git a/src/core/server/http/router/request.ts b/src/core/server/http/router/request.ts
index 0091a320bd63..f31b658890a4 100644
--- a/src/core/server/http/router/request.ts
+++ b/src/core/server/http/router/request.ts
@@ -242,11 +242,7 @@ export class OpenSearchDashboardsRequest<
}
private getEvents(request: Request): OpenSearchDashboardsRequestEvents {
- const finish$ = merge(
- fromEvent(request.raw.res, 'finish'), // Response has been sent
- fromEvent(request.raw.req, 'close') // connection was closed
- ).pipe(shareReplay(1), first());
-
+ const finish$ = fromEvent(request.raw.res, 'finish').pipe(shareReplay(1), first());
const aborted$ = fromEvent(request.raw.req, 'aborted').pipe(first(), takeUntil(finish$));
const completed$ = merge(finish$, aborted$).pipe(shareReplay(1), first());
diff --git a/src/core/server/http/router/validator/validator.test.ts b/src/core/server/http/router/validator/validator.test.ts
index bda6da118efd..4c0dd2009daf 100644
--- a/src/core/server/http/router/validator/validator.test.ts
+++ b/src/core/server/http/router/validator/validator.test.ts
@@ -31,6 +31,9 @@
import { RouteValidationError, RouteValidator } from './';
import { schema, Type } from '@osd/config-schema';
+// ToDo: Remove this logic when Node 14 support is removed
+const isNode14 = process.version.startsWith('v14.');
+
describe('Router validator', () => {
it('should validate and infer the type from a function', () => {
const validator = RouteValidator.from({
@@ -70,7 +73,9 @@ describe('Router validator', () => {
expect(() => validator.getParams({})).toThrowError('[foo]: Not a string');
expect(() => validator.getParams(undefined)).toThrowError(
- `Cannot read property 'foo' of undefined`
+ isNode14
+ ? `Cannot read property 'foo' of undefined`
+ : `Cannot read properties of undefined (reading 'foo')`
);
expect(() => validator.getParams({}, 'myField')).toThrowError('[myField.foo]: Not a string');
diff --git a/src/core/server/legacy/legacy_service.test.ts b/src/core/server/legacy/legacy_service.test.ts
index 9c1412541a66..8ad4c738df44 100644
--- a/src/core/server/legacy/legacy_service.test.ts
+++ b/src/core/server/legacy/legacy_service.test.ts
@@ -31,6 +31,8 @@
jest.mock('../../../legacy/server/osd_server');
jest.mock('./cluster_manager');
+import '@osd/optimizer/target/__mocks__/lmdb';
+
import { BehaviorSubject, throwError } from 'rxjs';
import { REPO_ROOT } from '@osd/dev-utils';
diff --git a/src/core/server/plugins/discovery/plugin_manifest_parser.test.mocks.ts b/src/core/server/plugins/discovery/plugin_manifest_parser.test.mocks.ts
index cce7a4ff4b49..1a0fd8a6d364 100644
--- a/src/core/server/plugins/discovery/plugin_manifest_parser.test.mocks.ts
+++ b/src/core/server/plugins/discovery/plugin_manifest_parser.test.mocks.ts
@@ -29,6 +29,7 @@
*/
const realFs = jest.requireActual('fs');
+const realFsPromises = jest.requireActual('fs/promises');
export const mockReadFile = jest.fn();
const mockStat = jest.fn();
@@ -37,3 +38,11 @@ jest.doMock('fs', () => ({
readFile: mockReadFile,
stat: mockStat,
}));
+
+export const mockReadFilePromise = jest.fn();
+const mockStatPromise = jest.fn();
+jest.doMock('fs/promises', () => ({
+ ...realFsPromises,
+ readFile: mockReadFilePromise,
+ stat: mockStatPromise,
+}));
diff --git a/src/core/server/plugins/discovery/plugin_manifest_parser.test.ts b/src/core/server/plugins/discovery/plugin_manifest_parser.test.ts
index 6103b2d748b6..18b715d95050 100644
--- a/src/core/server/plugins/discovery/plugin_manifest_parser.test.ts
+++ b/src/core/server/plugins/discovery/plugin_manifest_parser.test.ts
@@ -28,7 +28,7 @@
* under the License.
*/
-import { mockReadFile } from './plugin_manifest_parser.test.mocks';
+import { mockReadFilePromise } from './plugin_manifest_parser.test.mocks';
import { PluginDiscoveryErrorType } from './plugin_discovery_error';
import { loggingSystemMock } from '../../logging/logging_system.mock';
@@ -52,9 +52,7 @@ afterEach(() => {
});
test('return error when manifest is empty', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(''));
- });
+ mockReadFilePromise.mockResolvedValue(Buffer.from(''));
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Unexpected end of JSON input (invalid-manifest, ${pluginManifestPath})`,
@@ -64,9 +62,7 @@ test('return error when manifest is empty', async () => {
});
test('return error when manifest content is null', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from('null'));
- });
+ mockReadFilePromise.mockResolvedValue(Buffer.from('null'));
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Plugin manifest must contain a JSON encoded object. (invalid-manifest, ${pluginManifestPath})`,
@@ -76,9 +72,7 @@ test('return error when manifest content is null', async () => {
});
test('return error when manifest content is not a valid JSON', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from('not-json'));
- });
+ mockReadFilePromise.mockResolvedValue(Buffer.from('not-json'));
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Unexpected token o in JSON at position 1 (invalid-manifest, ${pluginManifestPath})`,
@@ -88,9 +82,7 @@ test('return error when manifest content is not a valid JSON', async () => {
});
test('return error when plugin id is missing', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ version: 'some-version' })));
- });
+ mockReadFilePromise.mockResolvedValue(Buffer.from(JSON.stringify({ version: 'some-version' })));
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Plugin manifest must contain an "id" property. (invalid-manifest, ${pluginManifestPath})`,
@@ -100,9 +92,9 @@ test('return error when plugin id is missing', async () => {
});
test('return error when plugin id includes `.` characters', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'some.name', version: 'some-version' })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'some.name', version: 'some-version' }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Plugin "id" must not include \`.\` characters. (invalid-manifest, ${pluginManifestPath})`,
@@ -112,14 +104,9 @@ test('return error when plugin id includes `.` characters', async () => {
});
test('logs warning if pluginId is not in camelCase format', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({ id: 'some_name', version: 'opensearchDashboards', server: true })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'some_name', version: 'opensearchDashboards', server: true }))
+ );
expect(loggingSystemMock.collect(logger).warn).toHaveLength(0);
await parseManifest(pluginPath, packageInfo, logger);
@@ -133,14 +120,9 @@ test('logs warning if pluginId is not in camelCase format', async () => {
});
test('does not log pluginId format warning in dist mode', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({ id: 'some_name', version: 'opensearchDashboards', server: true })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'some_name', version: 'opensearchDashboards', server: true }))
+ );
expect(loggingSystemMock.collect(logger).warn).toHaveLength(0);
await parseManifest(pluginPath, { ...packageInfo, dist: true }, logger);
@@ -148,9 +130,7 @@ test('does not log pluginId format warning in dist mode', async () => {
});
test('return error when plugin version is missing', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'someId' })));
- });
+ mockReadFilePromise.mockResolvedValue(Buffer.from(JSON.stringify({ id: 'someId' })));
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Plugin manifest for "someId" must contain a "version" property. (invalid-manifest, ${pluginManifestPath})`,
@@ -160,9 +140,9 @@ test('return error when plugin version is missing', async () => {
});
test('return error when plugin expected OpenSearch Dashboards version is lower than actual version', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'someId', version: '6.4.2' })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'someId', version: '6.4.2' }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Plugin "someId" is only compatible with OpenSearch Dashboards version "6.4.2", but used OpenSearch Dashboards version is "7.0.0-alpha1". (incompatible-version, ${pluginManifestPath})`,
@@ -172,18 +152,15 @@ test('return error when plugin expected OpenSearch Dashboards version is lower t
});
test('return error when plugin expected OpenSearch Dashboards version cannot be interpreted as semver', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({
- id: 'someId',
- version: '1.0.0',
- opensearchDashboardsVersion: 'non-sem-ver',
- })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(
+ JSON.stringify({
+ id: 'someId',
+ version: '1.0.0',
+ opensearchDashboardsVersion: 'non-sem-ver',
+ })
+ )
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Plugin "someId" is only compatible with OpenSearch Dashboards version "non-sem-ver", but used OpenSearch Dashboards version is "7.0.0-alpha1". (incompatible-version, ${pluginManifestPath})`,
@@ -193,9 +170,9 @@ test('return error when plugin expected OpenSearch Dashboards version cannot be
});
test('return error when plugin config path is not a string', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', configPath: 2 })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', configPath: 2 }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `The "configPath" in plugin manifest for "someId" should either be a string or an array of strings. (invalid-manifest, ${pluginManifestPath})`,
@@ -205,12 +182,9 @@ test('return error when plugin config path is not a string', async () => {
});
test('return error when plugin config path is an array that contains non-string values', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', configPath: ['config', 2] }))
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', configPath: ['config', 2] }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `The "configPath" in plugin manifest for "someId" should either be a string or an array of strings. (invalid-manifest, ${pluginManifestPath})`,
@@ -220,9 +194,9 @@ test('return error when plugin config path is an array that contains non-string
});
test('return error when plugin expected OpenSearch Dashboards version is higher than actual version', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.1' })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.1' }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Plugin "someId" is only compatible with OpenSearch Dashboards version "7.0.1", but used OpenSearch Dashboards version is "7.0.0-alpha1". (incompatible-version, ${pluginManifestPath})`,
@@ -232,9 +206,9 @@ test('return error when plugin expected OpenSearch Dashboards version is higher
});
test('return error when both `server` and `ui` are set to `false` or missing', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0' })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0' }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Both "server" and "ui" are missing or set to "false" in plugin manifest for "someId", but at least one of these must be set to "true". (invalid-manifest, ${pluginManifestPath})`,
@@ -242,12 +216,9 @@ test('return error when both `server` and `ui` are set to `false` or missing', a
path: pluginManifestPath,
});
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', server: false, ui: false }))
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', server: false, ui: false }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Both "server" and "ui" are missing or set to "false" in plugin manifest for "someId", but at least one of these must be set to "true". (invalid-manifest, ${pluginManifestPath})`,
@@ -257,20 +228,17 @@ test('return error when both `server` and `ui` are set to `false` or missing', a
});
test('return error when manifest contains unrecognized properties', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({
- id: 'someId',
- version: '7.0.0',
- server: true,
- unknownOne: 'one',
- unknownTwo: true,
- })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(
+ JSON.stringify({
+ id: 'someId',
+ version: '7.0.0',
+ server: true,
+ unknownOne: 'one',
+ unknownTwo: true,
+ })
+ )
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).rejects.toMatchObject({
message: `Manifest for plugin "someId" contains the following unrecognized properties: unknownOne,unknownTwo. (invalid-manifest, ${pluginManifestPath})`,
@@ -281,46 +249,40 @@ test('return error when manifest contains unrecognized properties', async () =>
describe('configPath', () => {
test('falls back to plugin id if not specified', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'plugin', version: '7.0.0', server: true })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'plugin', version: '7.0.0', server: true }))
+ );
const manifest = await parseManifest(pluginPath, packageInfo, logger);
expect(manifest.configPath).toBe(manifest.id);
});
test('falls back to plugin id in snakeCase format', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'SomeId', version: '7.0.0', server: true })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'SomeId', version: '7.0.0', server: true }))
+ );
const manifest = await parseManifest(pluginPath, packageInfo, logger);
expect(manifest.configPath).toBe('some_id');
});
test('not formated to snakeCase if defined explicitly as string', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({ id: 'someId', configPath: 'somePath', version: '7.0.0', server: true })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(
+ JSON.stringify({ id: 'someId', configPath: 'somePath', version: '7.0.0', server: true })
+ )
+ );
const manifest = await parseManifest(pluginPath, packageInfo, logger);
expect(manifest.configPath).toBe('somePath');
});
test('not formated to snakeCase if defined explicitly as an array of strings', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({ id: 'someId', configPath: ['somePath'], version: '7.0.0', server: true })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(
+ JSON.stringify({ id: 'someId', configPath: ['somePath'], version: '7.0.0', server: true })
+ )
+ );
const manifest = await parseManifest(pluginPath, packageInfo, logger);
expect(manifest.configPath).toEqual(['somePath']);
@@ -328,9 +290,9 @@ describe('configPath', () => {
});
test('set defaults for all missing optional fields', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(null, Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', server: true })));
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(JSON.stringify({ id: 'someId', version: '7.0.0', server: true }))
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).resolves.toEqual({
id: 'someId',
@@ -346,22 +308,19 @@ test('set defaults for all missing optional fields', async () => {
});
test('return all set optional fields as they are in manifest', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({
- id: 'someId',
- configPath: ['some', 'path'],
- version: 'some-version',
- opensearchDashboardsVersion: '7.0.0',
- requiredPlugins: ['some-required-plugin', 'some-required-plugin-2'],
- optionalPlugins: ['some-optional-plugin'],
- ui: true,
- })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(
+ JSON.stringify({
+ id: 'someId',
+ configPath: ['some', 'path'],
+ version: 'some-version',
+ opensearchDashboardsVersion: '7.0.0',
+ requiredPlugins: ['some-required-plugin', 'some-required-plugin-2'],
+ optionalPlugins: ['some-optional-plugin'],
+ ui: true,
+ })
+ )
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).resolves.toEqual({
id: 'someId',
@@ -377,21 +336,18 @@ test('return all set optional fields as they are in manifest', async () => {
});
test('return manifest when plugin expected OpenSearch Dashboards version matches actual version', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({
- id: 'someId',
- configPath: 'some-path',
- version: 'some-version',
- opensearchDashboardsVersion: '7.0.0-alpha2',
- requiredPlugins: ['some-required-plugin'],
- server: true,
- })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(
+ JSON.stringify({
+ id: 'someId',
+ configPath: 'some-path',
+ version: 'some-version',
+ opensearchDashboardsVersion: '7.0.0-alpha2',
+ requiredPlugins: ['some-required-plugin'],
+ server: true,
+ })
+ )
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).resolves.toEqual({
id: 'someId',
@@ -407,21 +363,18 @@ test('return manifest when plugin expected OpenSearch Dashboards version matches
});
test('return manifest when plugin expected OpenSearch Dashboards version is `opensearchDashboards`', async () => {
- mockReadFile.mockImplementation((path, cb) => {
- cb(
- null,
- Buffer.from(
- JSON.stringify({
- id: 'someId',
- version: 'some-version',
- opensearchDashboardsVersion: 'opensearchDashboards',
- requiredPlugins: ['some-required-plugin'],
- server: true,
- ui: true,
- })
- )
- );
- });
+ mockReadFilePromise.mockResolvedValue(
+ Buffer.from(
+ JSON.stringify({
+ id: 'someId',
+ version: 'some-version',
+ opensearchDashboardsVersion: 'opensearchDashboards',
+ requiredPlugins: ['some-required-plugin'],
+ server: true,
+ ui: true,
+ })
+ )
+ );
await expect(parseManifest(pluginPath, packageInfo, logger)).resolves.toEqual({
id: 'someId',
diff --git a/src/core/server/plugins/discovery/plugin_manifest_parser.ts b/src/core/server/plugins/discovery/plugin_manifest_parser.ts
index 0f39f14b0ce5..2a5ccf611f0c 100644
--- a/src/core/server/plugins/discovery/plugin_manifest_parser.ts
+++ b/src/core/server/plugins/discovery/plugin_manifest_parser.ts
@@ -28,10 +28,9 @@
* under the License.
*/
-import { readFile, stat } from 'fs';
+import { readFile, stat } from 'fs/promises';
import { resolve } from 'path';
import { coerce } from 'semver';
-import { promisify } from 'util';
import { snakeCase } from 'lodash';
import { isConfigPath, PackageInfo } from '../../config';
import { Logger } from '../../logging';
@@ -39,9 +38,6 @@ import { PluginManifest } from '../types';
import { PluginDiscoveryError } from './plugin_discovery_error';
import { isCamelCase } from './is_camel_case';
-const fsReadFileAsync = promisify(readFile);
-const fsStatAsync = promisify(stat);
-
/**
* Name of the JSON manifest file that should be located in the plugin directory.
*/
@@ -92,7 +88,7 @@ export async function parseManifest(
let manifestContent;
try {
- manifestContent = await fsReadFileAsync(manifestPath);
+ manifestContent = await readFile(manifestPath);
} catch (err) {
throw PluginDiscoveryError.missingManifest(manifestPath, err);
}
@@ -219,7 +215,7 @@ export async function parseManifest(
*/
export async function isNewPlatformPlugin(pluginPath: string) {
try {
- return (await fsStatAsync(resolve(pluginPath, MANIFEST_FILE_NAME))).isFile();
+ return (await stat(resolve(pluginPath, MANIFEST_FILE_NAME))).isFile();
} catch (err) {
return false;
}
diff --git a/src/core/server/saved_objects/export/get_sorted_objects_for_export.test.ts b/src/core/server/saved_objects/export/get_sorted_objects_for_export.test.ts
index ac2806748207..cf7e1d8246a7 100644
--- a/src/core/server/saved_objects/export/get_sorted_objects_for_export.test.ts
+++ b/src/core/server/saved_objects/export/get_sorted_objects_for_export.test.ts
@@ -32,6 +32,9 @@ import { exportSavedObjectsToStream } from './get_sorted_objects_for_export';
import { savedObjectsClientMock } from '../service/saved_objects_client.mock';
import { Readable } from 'stream';
import { createPromiseFromStreams, createConcatStream } from '../../utils/streams';
+import { createStripPromisesSerializer } from '@osd/dev-utils';
+
+expect.addSnapshotSerializer(createStripPromisesSerializer());
async function readStreamToCompletion(stream: Readable) {
return createPromiseFromStreams([stream, createConcatStream([])]);
@@ -89,27 +92,27 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "name",
- "type": "index-pattern",
+ id: 1,
+ name: name,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "exportedCount": 2,
- "missingRefCount": 0,
- "missingReferences": Array [],
+ exportedCount: 2,
+ missingRefCount: 0,
+ missingReferences: Array [],
},
]
`);
@@ -118,20 +121,20 @@ describe('getSortedObjectsForExport()', () => {
"calls": Array [
Array [
Object {
- "namespaces": undefined,
- "perPage": 500,
- "search": undefined,
- "type": Array [
- "index-pattern",
- "search",
+ namespaces: undefined,
+ perPage: 500,
+ search: undefined,
+ type: Array [
+ index-pattern,
+ search,
],
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -179,27 +182,27 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "name",
- "type": "index-pattern",
+ id: 1,
+ name: name,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "exportedCount": 2,
- "missingRefCount": 0,
- "missingReferences": Array [],
+ exportedCount: 2,
+ missingRefCount: 0,
+ missingReferences: Array [],
},
]
`);
@@ -208,20 +211,20 @@ describe('getSortedObjectsForExport()', () => {
"calls": Array [
Array [
Object {
- "namespaces": undefined,
- "perPage": 500,
- "search": undefined,
- "type": Array [
- "index-pattern",
- "search",
+ namespaces: undefined,
+ perPage: 500,
+ search: undefined,
+ type: Array [
+ index-pattern,
+ search,
],
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -268,22 +271,22 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "name",
- "type": "index-pattern",
+ id: 1,
+ name: name,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
]
`);
@@ -329,27 +332,27 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "name",
- "type": "index-pattern",
+ id: 1,
+ name: name,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "exportedCount": 2,
- "missingRefCount": 0,
- "missingReferences": Array [],
+ exportedCount: 2,
+ missingRefCount: 0,
+ missingReferences: Array [],
},
]
`);
@@ -358,20 +361,20 @@ describe('getSortedObjectsForExport()', () => {
"calls": Array [
Array [
Object {
- "namespaces": undefined,
- "perPage": 500,
- "search": "foo",
- "type": Array [
- "index-pattern",
- "search",
+ namespaces: undefined,
+ perPage: 500,
+ search: foo,
+ type: Array [
+ index-pattern,
+ search,
],
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -418,27 +421,27 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "name",
- "type": "index-pattern",
+ id: 1,
+ name: name,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "exportedCount": 2,
- "missingRefCount": 0,
- "missingReferences": Array [],
+ exportedCount: 2,
+ missingRefCount: 0,
+ missingReferences: Array [],
},
]
`);
@@ -447,22 +450,22 @@ describe('getSortedObjectsForExport()', () => {
"calls": Array [
Array [
Object {
- "namespaces": Array [
- "foo",
+ namespaces: Array [
+ foo,
],
- "perPage": 500,
- "search": undefined,
- "type": Array [
- "index-pattern",
- "search",
+ perPage: 500,
+ search: undefined,
+ type: Array [
+ index-pattern,
+ search,
],
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -503,7 +506,7 @@ describe('getSortedObjectsForExport()', () => {
exportSizeLimit: 1,
types: ['index-pattern', 'search'],
})
- ).rejects.toThrowErrorMatchingInlineSnapshot(`"Can't export more than 1 objects"`);
+ ).rejects.toThrowErrorMatchingInlineSnapshot(`Can't export more than 1 objects`);
});
test('sorts objects within type', async () => {
@@ -550,33 +553,33 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {
- "name": "foo",
+ attributes: Object {
+ name: foo,
},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {
- "name": "bar",
+ attributes: Object {
+ name: bar,
},
- "id": "2",
- "references": Array [],
- "type": "index-pattern",
+ id: 2,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {
- "name": "baz",
+ attributes: Object {
+ name: baz,
},
- "id": "3",
- "references": Array [],
- "type": "index-pattern",
+ id: 3,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "exportedCount": 3,
- "missingRefCount": 0,
- "missingReferences": Array [],
+ exportedCount: 3,
+ missingRefCount: 0,
+ missingReferences: Array [],
},
]
`);
@@ -623,57 +626,57 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "name",
- "type": "index-pattern",
+ id: 1,
+ name: name,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "exportedCount": 2,
- "missingRefCount": 0,
- "missingReferences": Array [],
+ exportedCount: 2,
+ missingRefCount: 0,
+ missingReferences: Array [],
},
]
`);
expect(savedObjectsClient.bulkGet).toMatchInlineSnapshot(`
- [MockFunction] {
- "calls": Array [
- Array [
- Array [
- Object {
- "id": "1",
- "type": "index-pattern",
- },
- Object {
- "id": "2",
- "type": "search",
- },
- ],
- Object {
- "namespace": undefined,
- },
- ],
- ],
- "results": Array [
- Object {
- "type": "return",
- "value": Promise {},
- },
- ],
- }
- `);
+ [MockFunction] {
+ "calls": Array [
+ Array [
+ Array [
+ Object {
+ id: 1,
+ type: index-pattern,
+ },
+ Object {
+ id: 2,
+ type: search,
+ },
+ ],
+ Object {
+ namespace: undefined,
+ },
+ ],
+ ],
+ "results": Array [
+ Object {
+ type: return,
+ value: Promise {},
+ },
+ ],
+ }
+ `);
});
test('modifies return results to redact `namespaces` attribute', async () => {
@@ -745,68 +748,68 @@ describe('getSortedObjectsForExport()', () => {
expect(response).toMatchInlineSnapshot(`
Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "name",
- "type": "index-pattern",
+ id: 1,
+ name: name,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "exportedCount": 2,
- "missingRefCount": 0,
- "missingReferences": Array [],
+ exportedCount: 2,
+ missingRefCount: 0,
+ missingReferences: Array [],
},
]
`);
expect(savedObjectsClient.bulkGet).toMatchInlineSnapshot(`
- [MockFunction] {
- "calls": Array [
- Array [
- Array [
- Object {
- "id": "2",
- "type": "search",
- },
- ],
- Object {
- "namespace": undefined,
- },
- ],
- Array [
- Array [
- Object {
- "id": "1",
- "type": "index-pattern",
- },
- ],
- Object {
- "namespace": undefined,
- },
- ],
- ],
- "results": Array [
- Object {
- "type": "return",
- "value": Promise {},
- },
- Object {
- "type": "return",
- "value": Promise {},
- },
- ],
- }
- `);
+ [MockFunction] {
+ "calls": Array [
+ Array [
+ Array [
+ Object {
+ id: 2,
+ type: search,
+ },
+ ],
+ Object {
+ namespace: undefined,
+ },
+ ],
+ Array [
+ Array [
+ Object {
+ id: 1,
+ type: index-pattern,
+ },
+ ],
+ Object {
+ namespace: undefined,
+ },
+ ],
+ ],
+ "results": Array [
+ Object {
+ type: return,
+ value: Promise {},
+ },
+ Object {
+ type: return,
+ value: Promise {},
+ },
+ ],
+ }
+ `);
});
test('export selected objects throws error when exceeding exportSizeLimit', async () => {
@@ -825,7 +828,7 @@ describe('getSortedObjectsForExport()', () => {
],
};
await expect(exportSavedObjectsToStream(exportOpts)).rejects.toThrowErrorMatchingInlineSnapshot(
- `"Can't export more than 1 objects"`
+ `Can't export more than 1 objects`
);
});
@@ -838,7 +841,7 @@ describe('getSortedObjectsForExport()', () => {
};
expect(exportSavedObjectsToStream(exportOpts)).rejects.toThrowErrorMatchingInlineSnapshot(
- `"Either \`type\` or \`objects\` are required."`
+ `Either \`type\` or \`objects\` are required.`
);
});
@@ -851,7 +854,7 @@ describe('getSortedObjectsForExport()', () => {
};
expect(exportSavedObjectsToStream(exportOpts)).rejects.toThrowErrorMatchingInlineSnapshot(
- `"Can't specify both \\"search\\" and \\"objects\\" properties when exporting"`
+ `Can't specify both "search" and "objects" properties when exporting`
);
});
});
diff --git a/src/core/server/saved_objects/export/inject_nested_depdendencies.test.ts b/src/core/server/saved_objects/export/inject_nested_depdendencies.test.ts
index 587491280285..00c81e55244e 100644
--- a/src/core/server/saved_objects/export/inject_nested_depdendencies.test.ts
+++ b/src/core/server/saved_objects/export/inject_nested_depdendencies.test.ts
@@ -32,6 +32,10 @@ import { SavedObject } from '../types';
import { savedObjectsClientMock } from '../../mocks';
import { getObjectReferencesToFetch, fetchNestedDependencies } from './inject_nested_depdendencies';
import { SavedObjectsErrorHelpers } from '..';
+import { createStripPromisesSerializer } from '@osd/dev-utils';
+
+// This is to clean Promises
+expect.addSnapshotSerializer(createStripPromisesSerializer());
describe('getObjectReferencesToFetch()', () => {
test('works with no saved objects', () => {
@@ -82,8 +86,8 @@ describe('getObjectReferencesToFetch()', () => {
expect(result).toMatchInlineSnapshot(`
Array [
Object {
- "id": "1",
- "type": "index-pattern",
+ id: 1,
+ type: index-pattern,
},
]
`);
@@ -139,13 +143,13 @@ describe('injectNestedDependencies', () => {
const result = await fetchNestedDependencies(savedObjects, savedObjectsClient);
expect(result).toMatchInlineSnapshot(`
Object {
- "missingRefs": Array [],
- "objects": Array [
+ missingRefs: Array [],
+ objects: Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
],
}
@@ -176,25 +180,25 @@ describe('injectNestedDependencies', () => {
const result = await fetchNestedDependencies(savedObjects, savedObjectsClient);
expect(result).toMatchInlineSnapshot(`
Object {
- "missingRefs": Array [],
- "objects": Array [
+ missingRefs: Array [],
+ objects: Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "ref_0",
- "type": "index-pattern",
+ id: 1,
+ name: ref_0,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
],
}
@@ -229,25 +233,25 @@ describe('injectNestedDependencies', () => {
const result = await fetchNestedDependencies(savedObjects, savedObjectsClient);
expect(result).toMatchInlineSnapshot(`
Object {
- "missingRefs": Array [],
- "objects": Array [
+ missingRefs: Array [],
+ objects: Array [
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "ref_0",
- "type": "index-pattern",
+ id: 1,
+ name: ref_0,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
],
}
@@ -258,19 +262,19 @@ describe('injectNestedDependencies', () => {
Array [
Array [
Object {
- "id": "1",
- "type": "index-pattern",
+ id: 1,
+ type: index-pattern,
},
],
Object {
- "namespace": undefined,
+ namespace: undefined,
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -350,66 +354,66 @@ describe('injectNestedDependencies', () => {
const result = await fetchNestedDependencies(savedObjects, savedObjectsClient);
expect(result).toMatchInlineSnapshot(`
Object {
- "missingRefs": Array [],
- "objects": Array [
+ missingRefs: Array [],
+ objects: Array [
Object {
- "attributes": Object {},
- "id": "5",
- "references": Array [
+ attributes: Object {},
+ id: 5,
+ references: Array [
Object {
- "id": "4",
- "name": "panel_0",
- "type": "visualization",
+ id: 4,
+ name: panel_0,
+ type: visualization,
},
Object {
- "id": "3",
- "name": "panel_1",
- "type": "visualization",
+ id: 3,
+ name: panel_1,
+ type: visualization,
},
],
- "type": "dashboard",
+ type: dashboard,
},
Object {
- "attributes": Object {},
- "id": "4",
- "references": Array [
+ attributes: Object {},
+ id: 4,
+ references: Array [
Object {
- "id": "2",
- "name": "ref_0",
- "type": "search",
+ id: 2,
+ name: ref_0,
+ type: search,
},
],
- "type": "visualization",
+ type: visualization,
},
Object {
- "attributes": Object {},
- "id": "3",
- "references": Array [
+ attributes: Object {},
+ id: 3,
+ references: Array [
Object {
- "id": "1",
- "name": "ref_0",
- "type": "index-pattern",
+ id: 1,
+ name: ref_0,
+ type: index-pattern,
},
],
- "type": "visualization",
+ type: visualization,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "ref_0",
- "type": "index-pattern",
+ id: 1,
+ name: ref_0,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 1,
+ references: Array [],
+ type: index-pattern,
},
],
}
@@ -420,42 +424,42 @@ describe('injectNestedDependencies', () => {
Array [
Array [
Object {
- "id": "4",
- "type": "visualization",
+ id: 4,
+ type: visualization,
},
Object {
- "id": "3",
- "type": "visualization",
+ id: 3,
+ type: visualization,
},
],
Object {
- "namespace": undefined,
+ namespace: undefined,
},
],
Array [
Array [
Object {
- "id": "2",
- "type": "search",
+ id: 2,
+ type: search,
},
Object {
- "id": "1",
- "type": "index-pattern",
+ id: 1,
+ type: index-pattern,
},
],
Object {
- "namespace": undefined,
+ namespace: undefined,
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -503,35 +507,35 @@ describe('injectNestedDependencies', () => {
const result = await fetchNestedDependencies(savedObjects, savedObjectsClient);
expect(result).toMatchInlineSnapshot(`
Object {
- "missingRefs": Array [
+ missingRefs: Array [
Object {
- "id": "1",
- "type": "index-pattern",
+ id: 1,
+ type: index-pattern,
},
],
- "objects": Array [
+ objects: Array [
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [
+ attributes: Object {},
+ id: 1,
+ references: Array [
Object {
- "id": "1",
- "name": "ref_0",
- "type": "index-pattern",
+ id: 1,
+ name: ref_0,
+ type: index-pattern,
},
Object {
- "id": "2",
- "name": "ref_1",
- "type": "index-pattern",
+ id: 2,
+ name: ref_1,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [],
- "type": "index-pattern",
+ attributes: Object {},
+ id: 2,
+ references: Array [],
+ type: index-pattern,
},
],
}
@@ -572,31 +576,31 @@ describe('injectNestedDependencies', () => {
const result = await fetchNestedDependencies(savedObjects, savedObjectsClient);
expect(result).toMatchInlineSnapshot(`
Object {
- "missingRefs": Array [],
- "objects": Array [
+ missingRefs: Array [],
+ objects: Array [
Object {
- "attributes": Object {},
- "id": "2",
- "references": Array [
+ attributes: Object {},
+ id: 2,
+ references: Array [
Object {
- "id": "1",
- "name": "ref_0",
- "type": "index-pattern",
+ id: 1,
+ name: ref_0,
+ type: index-pattern,
},
],
- "type": "search",
+ type: search,
},
Object {
- "attributes": Object {},
- "id": "1",
- "references": Array [
+ attributes: Object {},
+ id: 1,
+ references: Array [
Object {
- "id": "2",
- "name": "ref_0",
- "type": "search",
+ id: 2,
+ name: ref_0,
+ type: search,
},
],
- "type": "index-pattern",
+ type: index-pattern,
},
],
}
@@ -607,19 +611,19 @@ describe('injectNestedDependencies', () => {
Array [
Array [
Object {
- "id": "1",
- "type": "index-pattern",
+ id: 1,
+ type: index-pattern,
},
],
Object {
- "namespace": undefined,
+ namespace: undefined,
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
diff --git a/src/core/server/saved_objects/import/validate_references.test.ts b/src/core/server/saved_objects/import/validate_references.test.ts
index 8b9a4ebee4c1..df9a4e216bbb 100644
--- a/src/core/server/saved_objects/import/validate_references.test.ts
+++ b/src/core/server/saved_objects/import/validate_references.test.ts
@@ -31,7 +31,9 @@
import { getNonExistingReferenceAsKeys, validateReferences } from './validate_references';
import { savedObjectsClientMock } from '../../mocks';
import { SavedObjectsErrorHelpers } from '..';
+import { createStripPromisesSerializer } from '@osd/dev-utils';
+expect.addSnapshotSerializer(createStripPromisesSerializer());
describe('getNonExistingReferenceAsKeys()', () => {
const savedObjectsClient = savedObjectsClientMock.create();
@@ -132,22 +134,22 @@ describe('getNonExistingReferenceAsKeys()', () => {
Array [
Array [
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "1",
- "type": "index-pattern",
+ id: 1,
+ type: index-pattern,
},
],
Object {
- "namespace": undefined,
+ namespace: undefined,
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -226,29 +228,29 @@ describe('getNonExistingReferenceAsKeys()', () => {
Array [
Array [
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "1",
- "type": "index-pattern",
+ id: 1,
+ type: index-pattern,
},
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "3",
- "type": "search",
+ id: 3,
+ type: search,
},
],
Object {
- "namespace": undefined,
+ namespace: undefined,
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -366,46 +368,46 @@ describe('validateReferences()', () => {
expect(result).toMatchInlineSnapshot(`
Array [
Object {
- "error": Object {
- "references": Array [
+ error: Object {
+ references: Array [
Object {
- "id": "3",
- "type": "index-pattern",
+ id: 3,
+ type: index-pattern,
},
],
- "type": "missing_references",
+ type: missing_references,
},
- "id": "2",
- "meta": Object {
- "title": "My Visualization 2",
+ id: 2,
+ meta: Object {
+ title: My Visualization 2,
},
- "title": "My Visualization 2",
- "type": "visualization",
+ title: My Visualization 2,
+ type: visualization,
},
Object {
- "error": Object {
- "references": Array [
+ error: Object {
+ references: Array [
Object {
- "id": "5",
- "type": "index-pattern",
+ id: 5,
+ type: index-pattern,
},
Object {
- "id": "6",
- "type": "index-pattern",
+ id: 6,
+ type: index-pattern,
},
Object {
- "id": "7",
- "type": "search",
+ id: 7,
+ type: search,
},
],
- "type": "missing_references",
+ type: missing_references,
},
- "id": "4",
- "meta": Object {
- "title": "My Visualization 4",
+ id: 4,
+ meta: Object {
+ title: My Visualization 4,
},
- "title": "My Visualization 4",
- "type": "visualization",
+ title: My Visualization 4,
+ type: visualization,
},
]
`);
@@ -415,50 +417,50 @@ describe('validateReferences()', () => {
Array [
Array [
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "3",
- "type": "index-pattern",
+ id: 3,
+ type: index-pattern,
},
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "5",
- "type": "index-pattern",
+ id: 5,
+ type: index-pattern,
},
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "6",
- "type": "index-pattern",
+ id: 6,
+ type: index-pattern,
},
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "7",
- "type": "search",
+ id: 7,
+ type: search,
},
Object {
- "fields": Array [
- "id",
+ fields: Array [
+ id,
],
- "id": "8",
- "type": "search",
+ id: 8,
+ type: search,
},
],
Object {
- "namespace": undefined,
+ namespace: undefined,
},
],
],
"results": Array [
Object {
- "type": "return",
- "value": Promise {},
+ type: return,
+ value: Promise {},
},
],
}
@@ -597,6 +599,6 @@ describe('validateReferences()', () => {
];
await expect(
validateReferences(savedObjects, savedObjectsClient)
- ).rejects.toThrowErrorMatchingInlineSnapshot(`"Bad Request"`);
+ ).rejects.toThrowErrorMatchingInlineSnapshot(`Bad Request`);
});
});
diff --git a/src/core/server/status/plugins_status.ts b/src/core/server/status/plugins_status.ts
index 52ba85459658..b4fe9bcd0835 100644
--- a/src/core/server/status/plugins_status.ts
+++ b/src/core/server/status/plugins_status.ts
@@ -43,7 +43,7 @@ interface Deps {
export class PluginsStatusService {
private readonly pluginStatuses = new Map>();
- private readonly update$ = new BehaviorSubject(true);
+ private readonly update$ = new BehaviorSubject(true);
private readonly defaultInheritedStatus$: Observable;
constructor(private readonly deps: Deps) {
@@ -121,7 +121,7 @@ export class PluginsStatusService {
return combineLatest(pluginStatuses).pipe(
map((statuses) => Object.fromEntries(statuses)),
- distinctUntilChanged(isDeepStrictEqual)
+ distinctUntilChanged>(isDeepStrictEqual)
);
})
);
diff --git a/src/core/server/status/status_service.ts b/src/core/server/status/status_service.ts
index b128bfb7218c..10547e510fa6 100644
--- a/src/core/server/status/status_service.ts
+++ b/src/core/server/status/status_service.ts
@@ -95,7 +95,7 @@ export class StatusService implements CoreService {
this.logger.debug(`Recalculated overall status`, { status: summary });
return summary;
}),
- distinctUntilChanged(isDeepStrictEqual),
+ distinctUntilChanged>(isDeepStrictEqual),
shareReplay(1)
);
@@ -149,7 +149,7 @@ export class StatusService implements CoreService {
opensearch: opensearchStatus,
savedObjects: savedObjectsStatus,
})),
- distinctUntilChanged(isDeepStrictEqual),
+ distinctUntilChanged(isDeepStrictEqual),
shareReplay(1)
);
}
diff --git a/src/core/server/ui_settings/ui_settings_client.test.ts b/src/core/server/ui_settings/ui_settings_client.test.ts
index a7aa95ebab91..9108467fd04c 100644
--- a/src/core/server/ui_settings/ui_settings_client.test.ts
+++ b/src/core/server/ui_settings/ui_settings_client.test.ts
@@ -168,7 +168,7 @@ describe('ui settings', () => {
foo: 1,
})
).rejects.toMatchInlineSnapshot(
- `[Error: [validation [foo]]: expected value of type [string] but got [number]]`
+ `[ValidationError: [validation [foo]]: expected value of type [string] but got [number]]`
);
expect(savedObjectsClient.update).toHaveBeenCalledTimes(0);
@@ -196,7 +196,7 @@ describe('ui settings', () => {
const { uiSettings, savedObjectsClient } = setup({ defaults });
await expect(uiSettings.set('foo', 1)).rejects.toMatchInlineSnapshot(
- `[Error: [validation [foo]]: expected value of type [string] but got [number]]`
+ `[ValidationError: [validation [foo]]: expected value of type [string] but got [number]]`
);
expect(savedObjectsClient.update).toHaveBeenCalledTimes(0);
@@ -389,7 +389,7 @@ describe('ui settings', () => {
expect(loggingSystemMock.collect(logger).warn).toMatchInlineSnapshot(`
Array [
Array [
- "Ignore invalid UiSettings value. Error: [validation [id]]: expected value of type [number] but got [string].",
+ "Ignore invalid UiSettings value. ValidationError: [validation [id]]: expected value of type [number] but got [string].",
],
]
`);
@@ -531,7 +531,7 @@ describe('ui settings', () => {
expect(loggingSystemMock.collect(logger).warn).toMatchInlineSnapshot(`
Array [
Array [
- "Ignore invalid UiSettings value. Error: [validation [id]]: expected value of type [number] but got [string].",
+ "Ignore invalid UiSettings value. ValidationError: [validation [id]]: expected value of type [number] but got [string].",
],
]
`);
@@ -682,7 +682,7 @@ describe('ui settings', () => {
expect(loggingSystemMock.collect(logger).warn).toMatchInlineSnapshot(`
Array [
Array [
- "Ignore invalid UiSettings value. Error: [validation [id]]: expected value of type [number] but got [string].",
+ "Ignore invalid UiSettings value. ValidationError: [validation [id]]: expected value of type [number] but got [string].",
],
]
`);
diff --git a/src/core/server/ui_settings/ui_settings_service.test.ts b/src/core/server/ui_settings/ui_settings_service.test.ts
index ae881363e63f..e32429de7abe 100644
--- a/src/core/server/ui_settings/ui_settings_service.test.ts
+++ b/src/core/server/ui_settings/ui_settings_service.test.ts
@@ -111,7 +111,7 @@ describe('uiSettings', () => {
});
await expect(service.start()).rejects.toMatchInlineSnapshot(
- `[Error: [ui settings defaults [custom]]: expected value of type [string] but got [number]]`
+ `[ValidationError: [ui settings defaults [custom]]: expected value of type [string] but got [number]]`
);
});
@@ -134,7 +134,7 @@ describe('uiSettings', () => {
});
await expect(customizedService.start()).rejects.toMatchInlineSnapshot(
- `[Error: [ui settings overrides [custom]]: expected value of type [string] but got [number]]`
+ `[ValidationError: [ui settings overrides [custom]]: expected value of type [string] but got [number]]`
);
});
});
diff --git a/src/core/test_helpers/osd_server.ts b/src/core/test_helpers/osd_server.ts
index 5c062d76dcac..8f03ac949842 100644
--- a/src/core/test_helpers/osd_server.ts
+++ b/src/core/test_helpers/osd_server.ts
@@ -52,6 +52,7 @@ export type HttpMethod = 'delete' | 'get' | 'head' | 'post' | 'put';
const DEFAULTS_SETTINGS = {
server: {
autoListen: true,
+ host: '0.0.0.0',
// Use the ephemeral port to make sure that tests use the first available
// port and aren't affected by the timing issues in test environment.
port: 0,
diff --git a/src/dev/build/lib/build.test.ts b/src/dev/build/lib/build.test.ts
index 140237437ad1..96509df78aed 100644
--- a/src/dev/build/lib/build.test.ts
+++ b/src/dev/build/lib/build.test.ts
@@ -42,6 +42,7 @@ const config = new Config(
darwin: false,
linux: false,
linuxArm: false,
+ windows: false,
},
{
version: '1.0.0',
@@ -53,6 +54,7 @@ const config = new Config(
},
},
'1.2.3',
+ '1.2.3',
REPO_ROOT,
{
buildNumber: 1234,
diff --git a/src/dev/build/lib/config.ts b/src/dev/build/lib/config.ts
index 03fdd14b05c0..6af5b8e6901a 100644
--- a/src/dev/build/lib/config.ts
+++ b/src/dev/build/lib/config.ts
@@ -31,6 +31,7 @@
import { dirname, resolve, relative } from 'path';
import os from 'os';
import loadJsonFile from 'load-json-file';
+import { readFile } from 'fs/promises';
import { getVersionInfo, VersionInfo } from './version_info';
import {
@@ -67,11 +68,15 @@ export class Config {
const pkgPath = resolve(__dirname, '../../../../package.json');
const pkg: Package = loadJsonFile.sync(pkgPath);
+ const nvmrcPath = resolve(__dirname, '../../../../.nvmrc');
+ const nvmrcContent = (await readFile(nvmrcPath, 'utf8'))?.trim?.();
+
return new Config(
targetAllPlatforms,
targetPlatforms,
pkg,
pkg.engines.node,
+ nvmrcContent,
dirname(pkgPath),
await getVersionInfo({
isRelease,
@@ -87,6 +92,7 @@ export class Config {
private readonly targetPlatforms: TargetPlatforms,
private readonly pkg: Package,
private readonly nodeRange: string,
+ private readonly nodeVersion: string,
private readonly repoRoot: string,
private readonly versionInfo: VersionInfo,
public readonly isRelease: boolean
@@ -100,12 +106,19 @@ export class Config {
}
/**
- * Get the node version required by OpenSearch Dashboards
+ * Get the node version range compatible with OpenSearch Dashboards
*/
getNodeRange() {
return this.nodeRange;
}
+ /**
+ * Get the node version required by OpenSearch Dashboards
+ */
+ getNodeVersion() {
+ return this.nodeVersion;
+ }
+
/**
* Convert an absolute path to a relative path, based from the repo
*/
diff --git a/src/dev/build/tasks/bin/scripts/opensearch-dashboards b/src/dev/build/tasks/bin/scripts/opensearch-dashboards
index 49c41011da7d..c7eae94b4996 100755
--- a/src/dev/build/tasks/bin/scripts/opensearch-dashboards
+++ b/src/dev/build/tasks/bin/scripts/opensearch-dashboards
@@ -28,4 +28,4 @@ done
# Get an absolute path for OSD_HOME
OSD_HOME="$(cd "$(dirname "${SCRIPT}")/.."; pwd)"
-OSD_NODE_OPTS_PREFIX="--no-warnings --max-http-header-size=65536" OSD_USE_NODE_JS_FILE_PATH=/src/cli/dist NODE_ENV=production ${OSD_HOME}/bin/use_node "${@}"
+OSD_NODE_OPTS_PREFIX="--no-warnings --max-http-header-size=65536" OSD_USE_NODE_JS_FILE_PATH=/src/cli/dist NODE_ENV=production exec ${OSD_HOME}/bin/use_node "${@}"
diff --git a/src/dev/build/tasks/bin/scripts/opensearch-dashboards-plugin b/src/dev/build/tasks/bin/scripts/opensearch-dashboards-plugin
index 6af40438d13b..a8d9829cc3c1 100755
--- a/src/dev/build/tasks/bin/scripts/opensearch-dashboards-plugin
+++ b/src/dev/build/tasks/bin/scripts/opensearch-dashboards-plugin
@@ -28,4 +28,4 @@ done
# Get an absolute path for OSD_HOME
OSD_HOME="$(cd "$(dirname "${SCRIPT}")/.."; pwd)"
-OSD_NODE_OPTS_PREFIX="--no-warnings" OSD_USE_NODE_JS_FILE_PATH=/src/cli_plugin/dist NODE_ENV=production ${OSD_HOME}/bin/use_node "${@}"
+OSD_NODE_OPTS_PREFIX="--no-warnings" OSD_USE_NODE_JS_FILE_PATH=/src/cli_plugin/dist NODE_ENV=production exec ${OSD_HOME}/bin/use_node "${@}"
diff --git a/src/dev/build/tasks/create_archives_sources_task.ts b/src/dev/build/tasks/create_archives_sources_task.ts
index bf53c2915560..55d9b5313f12 100644
--- a/src/dev/build/tasks/create_archives_sources_task.ts
+++ b/src/dev/build/tasks/create_archives_sources_task.ts
@@ -29,7 +29,7 @@
*/
import { scanCopy, Task } from '../lib';
-import { getNodeDownloadInfo } from './nodejs';
+import { getNodeDownloadInfo, getNodeVersionDownloadInfo, NODE14_FALLBACK_VERSION } from './nodejs';
export const CreateArchivesSources: Task = {
description: 'Creating platform-specific archive source directories',
@@ -54,6 +54,20 @@ export const CreateArchivesSources: Task = {
destination: build.resolvePathForPlatform(platform, 'node'),
});
+ // ToDo [NODE14]: Remove this Node.js 14 fallback download
+ // Copy the Node.js 14 binaries into node/fallback to be used by `use_node`
+ await scanCopy({
+ source: (
+ await getNodeVersionDownloadInfo(
+ NODE14_FALLBACK_VERSION,
+ platform.getNodeArch(),
+ platform.isWindows(),
+ config.resolveFromRepo()
+ )
+ ).extractDir,
+ destination: build.resolvePathForPlatform(platform, 'node', 'fallback'),
+ });
+
log.debug('Node.js copied into', platform.getNodeArch(), 'specific build directory');
})
);
diff --git a/src/dev/build/tasks/nodejs/download_node_builds_task.test.ts b/src/dev/build/tasks/nodejs/download_node_builds_task.test.ts
index 3aff61e7cf4f..f5905534e121 100644
--- a/src/dev/build/tasks/nodejs/download_node_builds_task.test.ts
+++ b/src/dev/build/tasks/nodejs/download_node_builds_task.test.ts
@@ -44,7 +44,9 @@ jest.mock('../../lib/get_build_number');
expect.addSnapshotSerializer(createAnyInstanceSerializer(ToolingLog));
-const { getNodeDownloadInfo } = jest.requireMock('./node_download_info');
+const { getNodeDownloadInfo, getNodeVersionDownloadInfo } = jest.requireMock(
+ './node_download_info'
+);
const { getNodeShasums } = jest.requireMock('./node_shasums');
const { download } = jest.requireMock('../../lib/download');
@@ -76,6 +78,16 @@ async function setup({ failOnUrl }: { failOnUrl?: string } = {}) {
};
});
+ getNodeVersionDownloadInfo.mockImplementation((version, architecture, isWindows, repoRoot) => {
+ return {
+ url: `https://mirrors.nodejs.org/dist/v${version}/node-v${version}-${architecture}.tar.gz`,
+ downloadName: `node-v${version}-${architecture}.tar.gz`,
+ downloadPath: `/mocked/path/.node_binaries/${version}/node-v${version}-${architecture}.tar.gz`,
+ extractDir: `/mocked/path/.node_binaries/${version}/${architecture}`,
+ version,
+ };
+ });
+
getNodeShasums.mockReturnValue({
'linux:downloadName': 'linux:sha256',
'darwin:downloadName': 'darwin:sha256',
@@ -134,6 +146,42 @@ it('downloads node builds for each platform', async () => {
"url": "win32:url",
},
],
+ Array [
+ Object {
+ "destination": "/mocked/path/.node_binaries/14.21.3/node-v14.21.3-linux-x64.tar.gz",
+ "log": ,
+ "retries": 3,
+ "sha256": undefined,
+ "url": "https://mirrors.nodejs.org/dist/v14.21.3/node-v14.21.3-linux-x64.tar.gz",
+ },
+ ],
+ Array [
+ Object {
+ "destination": "/mocked/path/.node_binaries/14.21.3/node-v14.21.3-linux-arm64.tar.gz",
+ "log": ,
+ "retries": 3,
+ "sha256": undefined,
+ "url": "https://mirrors.nodejs.org/dist/v14.21.3/node-v14.21.3-linux-arm64.tar.gz",
+ },
+ ],
+ Array [
+ Object {
+ "destination": "/mocked/path/.node_binaries/14.21.3/node-v14.21.3-darwin-x64.tar.gz",
+ "log": ,
+ "retries": 3,
+ "sha256": undefined,
+ "url": "https://mirrors.nodejs.org/dist/v14.21.3/node-v14.21.3-darwin-x64.tar.gz",
+ },
+ ],
+ Array [
+ Object {
+ "destination": "/mocked/path/.node_binaries/14.21.3/node-v14.21.3-win32-x64.tar.gz",
+ "log": ,
+ "retries": 3,
+ "sha256": undefined,
+ "url": "https://mirrors.nodejs.org/dist/v14.21.3/node-v14.21.3-win32-x64.tar.gz",
+ },
+ ],
]
`);
expect(testWriter.messages).toMatchInlineSnapshot(`Array []`);
diff --git a/src/dev/build/tasks/nodejs/download_node_builds_task.ts b/src/dev/build/tasks/nodejs/download_node_builds_task.ts
index 9771e92e209f..393a02176e17 100644
--- a/src/dev/build/tasks/nodejs/download_node_builds_task.ts
+++ b/src/dev/build/tasks/nodejs/download_node_builds_task.ts
@@ -30,16 +30,25 @@
import { download, GlobalTask } from '../../lib';
import { getNodeShasums } from './node_shasums';
-import { getLatestNodeVersion, getNodeDownloadInfo } from './node_download_info';
+import {
+ getNodeDownloadInfo,
+ getNodeVersionDownloadInfo,
+ getRequiredVersion,
+ NODE14_FALLBACK_VERSION,
+} from './node_download_info';
export const DownloadNodeBuilds: GlobalTask = {
global: true,
description: 'Downloading node.js builds for all platforms',
async run(config, log) {
- const latestNodeVersion = await getLatestNodeVersion(config);
- const shasums = await getNodeShasums(log, latestNodeVersion);
- await Promise.all(
- config.getTargetPlatforms().map(async (platform) => {
+ const requiredNodeVersion = getRequiredVersion(config);
+ const shasums = await getNodeShasums(log, requiredNodeVersion);
+
+ // ToDo [NODE14]: Remove this Node.js 14 fallback download
+ const node14ShaSums = await getNodeShasums(log, NODE14_FALLBACK_VERSION);
+
+ await Promise.all([
+ ...config.getTargetPlatforms().map(async (platform) => {
const { url, downloadPath, downloadName } = await getNodeDownloadInfo(config, platform);
await download({
log,
@@ -48,7 +57,23 @@ export const DownloadNodeBuilds: GlobalTask = {
destination: downloadPath,
retries: 3,
});
- })
- );
+ }),
+ // ToDo [NODE14]: Remove this Node.js 14 fallback download
+ ...config.getTargetPlatforms().map(async (platform) => {
+ const { url, downloadPath, downloadName } = await getNodeVersionDownloadInfo(
+ NODE14_FALLBACK_VERSION,
+ platform.getNodeArch(),
+ platform.isWindows(),
+ config.resolveFromRepo()
+ );
+ await download({
+ log,
+ url,
+ sha256: node14ShaSums[downloadName],
+ destination: downloadPath,
+ retries: 3,
+ });
+ }),
+ ]);
},
};
diff --git a/src/dev/build/tasks/nodejs/extract_node_builds_task.test.ts b/src/dev/build/tasks/nodejs/extract_node_builds_task.test.ts
index 02a6a7bfa723..e68539310903 100644
--- a/src/dev/build/tasks/nodejs/extract_node_builds_task.test.ts
+++ b/src/dev/build/tasks/nodejs/extract_node_builds_task.test.ts
@@ -37,7 +37,7 @@ import {
import { Config } from '../../lib';
import { ExtractNodeBuilds } from './extract_node_builds_task';
-import { getLatestNodeVersion } from './node_download_info';
+import { getRequiredVersion } from './node_download_info';
jest.mock('../../lib/fs');
jest.mock('../../lib/get_build_number');
@@ -62,7 +62,7 @@ async function setup() {
},
});
- const realNodeVersion = await getLatestNodeVersion(config);
+ const realNodeVersion = getRequiredVersion(config);
if (realNodeVersion) {
expect.addSnapshotSerializer(
createRecursiveSerializer(
@@ -123,6 +123,27 @@ it('runs expected fs operations', async () => {
"strip": 1,
},
],
+ Array [
+ /.node_binaries/14.21.3/node-v14.21.3-linux-x64.tar.gz,
+ /.node_binaries/14.21.3/linux-x64,
+ Object {
+ "strip": 1,
+ },
+ ],
+ Array [
+ /.node_binaries/14.21.3/node-v14.21.3-linux-arm64.tar.gz,
+ /.node_binaries/14.21.3/linux-arm64,
+ Object {
+ "strip": 1,
+ },
+ ],
+ Array [
+ /.node_binaries/14.21.3/node-v14.21.3-darwin-x64.tar.gz,
+ /.node_binaries/14.21.3/darwin-x64,
+ Object {
+ "strip": 1,
+ },
+ ],
],
"unzip": Array [
Array [
@@ -132,6 +153,13 @@ it('runs expected fs operations', async () => {
"strip": 1,
},
],
+ Array [
+ /.node_binaries/14.21.3/node-v14.21.3-win-x64.zip,
+ /.node_binaries/14.21.3/win32-x64,
+ Object {
+ "strip": 1,
+ },
+ ],
],
}
`);
diff --git a/src/dev/build/tasks/nodejs/extract_node_builds_task.ts b/src/dev/build/tasks/nodejs/extract_node_builds_task.ts
index 28b2ebe24d4b..7934718c0bce 100644
--- a/src/dev/build/tasks/nodejs/extract_node_builds_task.ts
+++ b/src/dev/build/tasks/nodejs/extract_node_builds_task.ts
@@ -29,21 +29,39 @@
*/
import { untar, unzip, GlobalTask } from '../../lib';
-import { getNodeDownloadInfo } from './node_download_info';
+import {
+ getNodeDownloadInfo,
+ getNodeVersionDownloadInfo,
+ NODE14_FALLBACK_VERSION,
+} from './node_download_info';
export const ExtractNodeBuilds: GlobalTask = {
global: true,
description: 'Extracting node.js builds for all platforms',
async run(config) {
- await Promise.all(
- config.getTargetPlatforms().map(async (platform) => {
+ await Promise.all([
+ ...config.getTargetPlatforms().map(async (platform) => {
const { downloadPath, extractDir } = await getNodeDownloadInfo(config, platform);
if (platform.isWindows()) {
await unzip(downloadPath, extractDir, { strip: 1 });
} else {
await untar(downloadPath, extractDir, { strip: 1 });
}
- })
- );
+ }),
+ // ToDo [NODE14]: Remove this Node.js 14 fallback download
+ ...config.getTargetPlatforms().map(async (platform) => {
+ const { downloadPath, extractDir } = await getNodeVersionDownloadInfo(
+ NODE14_FALLBACK_VERSION,
+ platform.getNodeArch(),
+ platform.isWindows(),
+ config.resolveFromRepo()
+ );
+ if (platform.isWindows()) {
+ await unzip(downloadPath, extractDir, { strip: 1 });
+ } else {
+ await untar(downloadPath, extractDir, { strip: 1 });
+ }
+ }),
+ ]);
},
};
diff --git a/src/dev/build/tasks/nodejs/node_download_info.ts b/src/dev/build/tasks/nodejs/node_download_info.ts
index 73163bc3c30a..37eba4c29a58 100644
--- a/src/dev/build/tasks/nodejs/node_download_info.ts
+++ b/src/dev/build/tasks/nodejs/node_download_info.ts
@@ -28,7 +28,7 @@
* under the License.
*/
-import { basename } from 'path';
+import { basename, resolve } from 'path';
import fetch from 'node-fetch';
import semver from 'semver';
@@ -36,8 +36,10 @@ import { Config, Platform } from '../../lib';
const NODE_RANGE_CACHE: { [key: string]: string } = {};
+export const NODE14_FALLBACK_VERSION = '14.21.3';
+
export async function getNodeDownloadInfo(config: Config, platform: Platform) {
- const version = await getLatestNodeVersion(config);
+ const version = getRequiredVersion(config);
const arch = platform.getNodeArch();
const downloadName = platform.isWindows()
@@ -57,6 +59,29 @@ export async function getNodeDownloadInfo(config: Config, platform: Platform) {
};
}
+export async function getNodeVersionDownloadInfo(
+ version: string,
+ architecture: string,
+ isWindows: boolean,
+ repoRoot: string
+) {
+ const downloadName = isWindows
+ ? `node-v${version}-win-x64.zip`
+ : `node-v${version}-${architecture}.tar.gz`;
+
+ const url = `https://mirrors.nodejs.org/dist/v${version}/${downloadName}`;
+ const downloadPath = resolve(repoRoot, '.node_binaries', version, basename(downloadName));
+ const extractDir = resolve(repoRoot, '.node_binaries', version, architecture);
+
+ return {
+ url,
+ downloadName,
+ downloadPath,
+ extractDir,
+ version,
+ };
+}
+
export async function getLatestNodeVersion(config: Config) {
const range = config.getNodeRange();
// Check cache and return if known
@@ -76,3 +101,7 @@ export async function getLatestNodeVersion(config: Config) {
return maxVersion;
}
+
+export const getRequiredVersion = (config: Config) => {
+ return config.getNodeVersion();
+};
diff --git a/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.test.ts b/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.test.ts
index 4724fa73e9f0..1d516ce457ad 100644
--- a/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.test.ts
+++ b/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.test.ts
@@ -43,7 +43,9 @@ jest.mock('../../lib/fs');
jest.mock('../../lib/get_build_number');
const { getNodeShasums } = jest.requireMock('./node_shasums');
-const { getNodeDownloadInfo, getLatestNodeVersion } = jest.requireMock('./node_download_info');
+const { getNodeDownloadInfo, getLatestNodeVersion, getRequiredVersion } = jest.requireMock(
+ './node_download_info'
+);
const { getFileHash } = jest.requireMock('../../lib/fs');
const log = new ToolingLog();
@@ -83,6 +85,8 @@ async function setup(actualShaSums?: Record) {
getLatestNodeVersion.mockReturnValue('');
+ getRequiredVersion.mockReturnValue('');
+
getFileHash.mockImplementation((downloadPath: string) => {
if (actualShaSums?.[downloadPath]) {
return actualShaSums[downloadPath];
diff --git a/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.ts b/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.ts
index 4c64c4bbd25d..9eec2d4af8ce 100644
--- a/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.ts
+++ b/src/dev/build/tasks/nodejs/verify_existing_node_builds_task.ts
@@ -29,15 +29,15 @@
*/
import { getFileHash, GlobalTask } from '../../lib';
-import { getNodeDownloadInfo, getLatestNodeVersion } from './node_download_info';
+import { getNodeDownloadInfo, getRequiredVersion } from './node_download_info';
import { getNodeShasums } from './node_shasums';
export const VerifyExistingNodeBuilds: GlobalTask = {
global: true,
description: 'Verifying previously downloaded node.js build for all platforms',
async run(config, log) {
- const latestNodeVersion = await getLatestNodeVersion(config);
- const shasums = await getNodeShasums(log, latestNodeVersion);
+ const requiredNodeVersion = getRequiredVersion(config);
+ const shasums = await getNodeShasums(log, requiredNodeVersion);
await Promise.all(
config.getTargetPlatforms().map(async (platform) => {
diff --git a/src/dev/build/tasks/os_packages/docker_generator/resources/bin/opensearch-dashboards-docker b/src/dev/build/tasks/os_packages/docker_generator/resources/bin/opensearch-dashboards-docker
index de9ec4e4b5de..124a5e074842 100755
--- a/src/dev/build/tasks/os_packages/docker_generator/resources/bin/opensearch-dashboards-docker
+++ b/src/dev/build/tasks/os_packages/docker_generator/resources/bin/opensearch-dashboards-docker
@@ -135,7 +135,6 @@ opensearch_dashboards_vars=(
tilemap.options.minZoom
tilemap.options.subdomains
tilemap.url
- timeline.enabled
vega.enableExternalUrls
apm_oss.apmAgentConfigurationIndex
apm_oss.indexPattern
diff --git a/src/dev/build/tasks/patch_native_modules_task.test.ts b/src/dev/build/tasks/patch_native_modules_task.test.ts
index f3a3daa432c3..71553d39cd9c 100644
--- a/src/dev/build/tasks/patch_native_modules_task.test.ts
+++ b/src/dev/build/tasks/patch_native_modules_task.test.ts
@@ -9,8 +9,8 @@ import {
createAnyInstanceSerializer,
createAbsolutePathSerializer,
} from '@osd/dev-utils';
-import { Build, Config } from '../lib';
-import { PatchNativeModules } from './patch_native_modules_task';
+import { Build, Config, read, download, untar, gunzip } from '../lib';
+import { createPatchNativeModulesTask } from './patch_native_modules_task';
const log = new ToolingLog();
const testWriter = new ToolingLogCollectingWriter();
@@ -19,16 +19,16 @@ expect.addSnapshotSerializer(createAnyInstanceSerializer(Config));
expect.addSnapshotSerializer(createAnyInstanceSerializer(ToolingLog));
expect.addSnapshotSerializer(createAbsolutePathSerializer());
-jest.mock('../lib/download');
-jest.mock('../lib/fs', () => ({
- ...jest.requireActual('../lib/fs'),
- untar: jest.fn(),
- gunzip: jest.fn(),
-}));
-
-const { untar } = jest.requireMock('../lib/fs');
-const { gunzip } = jest.requireMock('../lib/fs');
-const { download } = jest.requireMock('../lib/download');
+jest.mock('../lib', () => {
+ const originalModule = jest.requireActual('../lib');
+ return {
+ ...originalModule,
+ download: jest.fn(),
+ gunzip: jest.fn(),
+ untar: jest.fn(),
+ read: jest.fn(),
+ };
+});
async function setup() {
const config = await Config.create({
@@ -38,14 +38,15 @@ async function setup() {
linux: false,
linuxArm: false,
darwin: false,
+ windows: false,
},
});
const build = new Build(config);
- download.mockImplementation(() => {});
- untar.mockImplementation(() => {});
- gunzip.mockImplementation(() => {});
+ (read as jest.MockedFunction).mockImplementation(async () => {
+ return JSON.stringify({ version: mockPackage.version });
+ });
return { config, build };
}
@@ -55,38 +56,77 @@ beforeEach(() => {
jest.clearAllMocks();
});
-it('patch native modules task downloads the correct platform package', async () => {
- const { config, build } = await setup();
- config.targetPlatforms.linuxArm = true;
- await PatchNativeModules.run(config, log, build);
- expect(download.mock.calls.length).toBe(1);
- expect(download.mock.calls).toMatchInlineSnapshot(`
+const mockPackage = {
+ name: 'mock-native-module',
+ version: '1.0.0',
+ destinationPath: 'path/to/destination',
+ extractMethod: 'untar',
+ archives: {
+ 'linux-arm64': {
+ url: 'https://example.com/mock-native-module/linux-arm64.tar.gz',
+ sha256: 'mock-sha256',
+ },
+ 'linux-x64': {
+ url: 'https://example.com/mock-native-module/linux-x64.gz',
+ sha256: 'mock-sha256',
+ },
+ },
+};
+
+describe('patch native modules task', () => {
+ it('patch native modules task downloads the correct platform package', async () => {
+ const { config, build } = await setup();
+ config.targetPlatforms.linuxArm = true;
+ const PatchNativeModulesWithMock = createPatchNativeModulesTask([mockPackage]);
+ await PatchNativeModulesWithMock.run(config, log, build);
+ expect((download as jest.MockedFunction).mock.calls.length).toBe(1);
+ expect((download as jest.MockedFunction).mock.calls).toMatchInlineSnapshot(`
Array [
Array [
Object {
- "destination": /.native_modules/re2/linux-arm64-83.tar.gz,
+ "destination": /.native_modules/mock-native-module/linux-arm64.tar.gz,
"log": ,
"retries": 3,
- "sha256": "d86ced75b794fbf518b90908847b3c09a50f3ff5a2815aa30f53080f926a2873",
- "url": "https://d1v1sj258etie.cloudfront.net/node-re2/releases/download/1.17.4/linux-arm64-83.tar.gz",
+ "sha256": "mock-sha256",
+ "url": "https://example.com/mock-native-module/linux-arm64.tar.gz",
},
],
]
`);
-});
+ });
-it('for .tar.gz artifact, patch native modules task unzip it via untar', async () => {
- const { config, build } = await setup();
- config.targetPlatforms.linuxArm = true;
- await PatchNativeModules.run(config, log, build);
- expect(untar.mock.calls.length).toBe(1);
- expect(gunzip.mock.calls.length).toBe(0);
-});
+ it('for .tar.gz artifact, patch native modules task unzip it via untar', async () => {
+ const { config, build } = await setup();
+ config.targetPlatforms.linuxArm = true;
+ const PatchNativeModulesWithMock = createPatchNativeModulesTask([mockPackage]);
+ await PatchNativeModulesWithMock.run(config, log, build);
+ expect(untar).toHaveBeenCalled();
+ expect(gunzip).not.toHaveBeenCalled();
+ });
-it('for .gz artifact, patch native modules task unzip it via gunzip', async () => {
- const { config, build } = await setup();
- config.targetPlatforms.linux = true;
- await PatchNativeModules.run(config, log, build);
- expect(untar.mock.calls.length).toBe(0);
- expect(gunzip.mock.calls.length).toBe(1);
+ it('for .gz artifact, patch native modules task unzip it via gunzip', async () => {
+ const mockPackageGZ = {
+ ...mockPackage,
+ extractMethod: 'gunzip',
+ };
+ const { config, build } = await setup();
+ config.targetPlatforms.linux = true;
+ const PatchNativeModulesWithMock = createPatchNativeModulesTask([mockPackageGZ]);
+ await PatchNativeModulesWithMock.run(config, log, build);
+ expect(gunzip).toHaveBeenCalled();
+ expect(untar).not.toHaveBeenCalled();
+ });
+
+ it('throws error for unsupported extract methods', async () => {
+ const mockPackageUnsupported = {
+ ...mockPackage,
+ extractMethod: 'unsupported',
+ };
+ const { config, build } = await setup();
+ config.targetPlatforms.linux = true;
+ const PatchNativeModulesWithMock = createPatchNativeModulesTask([mockPackageUnsupported]);
+ await expect(PatchNativeModulesWithMock.run(config, log, build)).rejects.toThrow(
+ 'Extract method of unsupported is not supported'
+ );
+ });
});
diff --git a/src/dev/build/tasks/patch_native_modules_task.ts b/src/dev/build/tasks/patch_native_modules_task.ts
index 3bd9fa63c358..b8c8d8a5b9fb 100644
--- a/src/dev/build/tasks/patch_native_modules_task.ts
+++ b/src/dev/build/tasks/patch_native_modules_task.ts
@@ -52,45 +52,7 @@ interface Package {
>;
}
-/* Process for updating URLs and checksums after bumping the version of `re2` or NodeJS:
- * 1. Match the `version` with the version in the yarn.lock file.
- * 2. Match the module version, the digits at the end of the filename, with the output of
- * `node -p process.versions.modules`.
- * 3. Confirm that the URLs exist for each platform-architecture combo on
- * https://github.com/uhop/node-re2/releases/tag/[VERSION]; reach out to maintainers for ARM
- * releases of `re2` as they currently don't have an official ARM release.
- * 4. Generate new checksums for each artifact by downloading each one and calling
- * `shasum -a 256` or `sha256sum` on the downloaded file.
- */
-const packages: Package[] = [
- {
- name: 're2',
- version: '1.17.4',
- destinationPath: 'node_modules/re2/build/Release/re2.node',
- extractMethod: 'gunzip',
- archives: {
- 'darwin-x64': {
- url: 'https://github.com/uhop/node-re2/releases/download/1.17.4/darwin-x64-83.gz',
- sha256: '9112ed93c1544ecc6397f7ff20bd2b28f3b04c7fbb54024e10f9a376a132a87d',
- },
- 'linux-x64': {
- url: 'https://github.com/uhop/node-re2/releases/download/1.17.4/linux-x64-83.gz',
- sha256: '86e03540783a18c41f81df0aec320b1f64aca6cbd3a87fc1b7a9b4109c5f5986',
- },
- 'linux-arm64': {
- url:
- 'https://d1v1sj258etie.cloudfront.net/node-re2/releases/download/1.17.4/linux-arm64-83.tar.gz',
- sha256: 'd86ced75b794fbf518b90908847b3c09a50f3ff5a2815aa30f53080f926a2873',
- overriddenExtractMethod: 'untar',
- overriddenDestinationPath: 'node_modules/re2/build/Release',
- },
- 'win32-x64': {
- url: 'https://github.com/uhop/node-re2/releases/download/1.17.4/win32-x64-83.gz',
- sha256: '2f842d9757288afd4bd5dec0e7b370a4c3e89ac98050598b17abb9e8e00e3294',
- },
- },
- },
-];
+export const packages: Package[] = [];
async function getInstalledVersion(config: Config, packageName: string) {
const packageJSONPath = config.resolveFromRepo(
@@ -145,15 +107,20 @@ async function patchModule(
}
}
-export const PatchNativeModules: Task = {
- description: 'Patching platform-specific native modules',
- async run(config, log, build) {
- for (const pkg of packages) {
- await Promise.all(
- config.getTargetPlatforms().map(async (platform) => {
- await patchModule(config, log, build, platform, pkg);
- })
- );
- }
- },
-};
+export function createPatchNativeModulesTask(customPackages?: Package[]): Task {
+ return {
+ description: 'Patching platform-specific native modules',
+ async run(config, log, build) {
+ const targetPackages = customPackages || packages;
+ for (const pkg of targetPackages) {
+ await Promise.all(
+ config.getTargetPlatforms().map(async (platform) => {
+ await patchModule(config, log, build, platform, pkg);
+ })
+ );
+ }
+ },
+ };
+}
+
+export const PatchNativeModules = createPatchNativeModulesTask();
diff --git a/src/dev/jest/junit_reporter.js b/src/dev/jest/junit_reporter.js
index 65f244042a12..1add8e722a5a 100644
--- a/src/dev/jest/junit_reporter.js
+++ b/src/dev/jest/junit_reporter.js
@@ -53,7 +53,7 @@ export default class JestJUnitReporter {
/**
* Called by jest when all tests complete
* @param {Object} contexts
- * @param {JestResults} results see https://facebook.github.io/jest/docs/en/configuration.html#testresultsprocessor-string
+ * @param {JestResults} results see https://jestjs.io/docs/configuration/#testresultsprocessor-string
* @return {undefined}
*/
onRunComplete(contexts, results) {
diff --git a/src/dev/stylelint/lint_files.js b/src/dev/stylelint/lint_files.js
index ead1fde5bb23..2d94f98b396c 100644
--- a/src/dev/stylelint/lint_files.js
+++ b/src/dev/stylelint/lint_files.js
@@ -30,13 +30,13 @@
import stylelint from 'stylelint';
import path from 'path';
-import { safeLoad } from 'js-yaml';
+import { load } from 'js-yaml';
import fs from 'fs';
import { createFailError } from '@osd/dev-utils';
// load the include globs from .stylelintrc.yml and convert them to regular expressions for filtering files
const stylelintPath = path.resolve(__dirname, '..', '..', '..', '.stylelintrc.yml');
-const styleLintConfig = safeLoad(fs.readFileSync(stylelintPath));
+const styleLintConfig = load(fs.readFileSync(stylelintPath));
/**
* Lints a list of files with eslint. eslint reports are written to the log
diff --git a/src/legacy/server/logging/rotate/log_rotator.test.ts b/src/legacy/server/logging/rotate/log_rotator.test.ts
index 9dbe960d405d..efb499352635 100644
--- a/src/legacy/server/logging/rotate/log_rotator.test.ts
+++ b/src/legacy/server/logging/rotate/log_rotator.test.ts
@@ -72,9 +72,12 @@ describe('LogRotator', () => {
writeFileSync(testFilePath, '');
});
- afterEach(() => {
+ afterEach((done) => {
del.sync(dirname(testFilePath), { force: true });
mockOn.mockClear();
+
+ // Tests occasionally fail complaining that `testFilePath` doesn't exist; this tries to help
+ setTimeout(done, 500);
});
it('rotates log file when bigger than set limit on start', async () => {
diff --git a/src/legacy/server/logging/rotate/log_rotator.ts b/src/legacy/server/logging/rotate/log_rotator.ts
index 7502631d22dd..ac2123036b44 100644
--- a/src/legacy/server/logging/rotate/log_rotator.ts
+++ b/src/legacy/server/logging/rotate/log_rotator.ts
@@ -97,7 +97,7 @@ export class LogRotator {
await this._startLogFileSizeMonitor();
}
- stop = () => {
+ async stop() {
if (!this.running) {
return;
}
@@ -106,10 +106,10 @@ export class LogRotator {
this._deleteExitListener();
// stop log file size monitor
- this._stopLogFileSizeMonitor();
+ await this._stopLogFileSizeMonitor();
this.running = false;
- };
+ }
async _shouldUsePolling() {
try {
@@ -202,12 +202,12 @@ export class LogRotator {
await this.throttledRotate();
};
- _stopLogFileSizeMonitor() {
+ async _stopLogFileSizeMonitor() {
if (!this.stalker) {
return;
}
- this.stalker.close();
+ await this.stalker.close();
if (this.stalkerUsePollingPolicyTestTimeout) {
clearTimeout(this.stalkerUsePollingPolicyTestTimeout);
diff --git a/src/plugins/advanced_settings/public/management_app/_advanced_settings.scss b/src/plugins/advanced_settings/public/management_app/_advanced_settings.scss
index 82704fc93062..a33082c3ef64 100644
--- a/src/plugins/advanced_settings/public/management_app/_advanced_settings.scss
+++ b/src/plugins/advanced_settings/public/management_app/_advanced_settings.scss
@@ -76,7 +76,3 @@
.mgtAdvancedSettingsForm__button {
width: 100%;
}
-
-.osdBody--mgtAdvancedSettingsHasBottomBar .mgtPage__body {
- padding-bottom: $euiSizeXL * 2;
-}
diff --git a/src/plugins/advanced_settings/public/management_app/components/field/field.test.tsx b/src/plugins/advanced_settings/public/management_app/components/field/field.test.tsx
index c5a8a89157fe..4f17ab378d3c 100644
--- a/src/plugins/advanced_settings/public/management_app/components/field/field.test.tsx
+++ b/src/plugins/advanced_settings/public/management_app/components/field/field.test.tsx
@@ -36,7 +36,7 @@ import { FieldSetting } from '../../types';
import { UiSettingsType, StringValidation } from '../../../../../../core/public';
import { notificationServiceMock, docLinksServiceMock } from '../../../../../../core/public/mocks';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { Field, getEditableValue } from './field';
jest.mock('brace/theme/textmate', () => 'brace/theme/textmate');
diff --git a/src/plugins/advanced_settings/public/management_app/components/form/form.test.tsx b/src/plugins/advanced_settings/public/management_app/components/form/form.test.tsx
index 650d8b259f0c..a0edaa5ab602 100644
--- a/src/plugins/advanced_settings/public/management_app/components/form/form.test.tsx
+++ b/src/plugins/advanced_settings/public/management_app/components/form/form.test.tsx
@@ -29,15 +29,21 @@
*/
import React from 'react';
+import ReactDOM from 'react-dom';
import { shallowWithI18nProvider, mountWithI18nProvider } from 'test_utils/enzyme_helpers';
import { UiSettingsType } from '../../../../../../core/public';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { notificationServiceMock } from '../../../../../../core/public/mocks';
import { SettingsChanges } from '../../types';
import { Form } from './form';
+jest.mock('react-dom', () => ({
+ ...jest.requireActual('react-dom'),
+ createPortal: jest.fn((element) => element),
+}));
+
jest.mock('../field', () => ({
Field: () => {
return 'field';
@@ -45,6 +51,8 @@ jest.mock('../field', () => ({
}));
beforeAll(() => {
+ ReactDOM.createPortal = jest.fn((children: any) => children);
+
const localStorage: Record = {
'core.chrome.isLocked': true,
};
@@ -60,6 +68,7 @@ beforeAll(() => {
});
afterAll(() => {
+ (ReactDOM.createPortal as jest.Mock).mockClear();
delete (window as any).localStorage;
});
diff --git a/src/plugins/advanced_settings/public/management_app/components/form/form.tsx b/src/plugins/advanced_settings/public/management_app/components/form/form.tsx
index 92b7a792d2d2..a74199771d2a 100644
--- a/src/plugins/advanced_settings/public/management_app/components/form/form.tsx
+++ b/src/plugins/advanced_settings/public/management_app/components/form/form.tsx
@@ -47,8 +47,9 @@ import {
import { FormattedMessage } from '@osd/i18n/react';
import { isEmpty } from 'lodash';
import { i18n } from '@osd/i18n';
+import { DocLinksStart, ToastsStart } from 'opensearch-dashboards/public';
+import { createPortal } from 'react-dom';
import { toMountPoint } from '../../../../../opensearch_dashboards_react/public';
-import { DocLinksStart, ToastsStart } from '../../../../../../core/public';
import { getCategoryName } from '../../lib';
import { Field, getEditableValue } from '../field';
@@ -336,63 +337,69 @@ export class Form extends PureComponent {
};
renderBottomBar = () => {
- const areChangesInvalid = this.areChangesInvalid();
- return (
-
-
-
- {this.renderCountOfUnsaved()}
-
-
-
-
- {i18n.translate('advancedSettings.form.cancelButtonLabel', {
- defaultMessage: 'Cancel changes',
- })}
-
-
-
-
-
+
+
+ {this.renderCountOfUnsaved()}
+
+
+
+
- {i18n.translate('advancedSettings.form.saveButtonLabel', {
- defaultMessage: 'Save changes',
+ {i18n.translate('advancedSettings.form.cancelButtonLabel', {
+ defaultMessage: 'Cancel changes',
})}
-
-
-
-
-
- );
+
+
+
+
+
+ {i18n.translate('advancedSettings.form.saveButtonLabel', {
+ defaultMessage: 'Save changes',
+ })}
+
+
+
+
+
+ );
+
+ return createPortal(bottomBar, document.getElementById('app-wrapper')!);
+ } catch (e) {
+ return null;
+ }
};
render() {
@@ -401,12 +408,6 @@ export class Form extends PureComponent {
const currentCategories: Category[] = [];
const hasUnsavedChanges = !isEmpty(unsavedChanges);
- if (hasUnsavedChanges) {
- document.body.classList.add('osdBody--mgtAdvancedSettingsHasBottomBar');
- } else {
- document.body.classList.remove('osdBody--mgtAdvancedSettingsHasBottomBar');
- }
-
categories.forEach((category) => {
if (visibleSettings[category] && visibleSettings[category].length) {
currentCategories.push(category);
diff --git a/src/plugins/advanced_settings/public/management_app/components/search/search.test.tsx b/src/plugins/advanced_settings/public/management_app/components/search/search.test.tsx
index 34b69888b3be..f362af408e0c 100644
--- a/src/plugins/advanced_settings/public/management_app/components/search/search.test.tsx
+++ b/src/plugins/advanced_settings/public/management_app/components/search/search.test.tsx
@@ -31,7 +31,7 @@
import React from 'react';
import { shallowWithI18nProvider, mountWithI18nProvider } from 'test_utils/enzyme_helpers';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { Query } from '@elastic/eui';
import { Search } from './search';
diff --git a/src/plugins/advanced_settings/public/management_app/components/search/search.tsx b/src/plugins/advanced_settings/public/management_app/components/search/search.tsx
index a957fa793f8f..0b1de3bbfb24 100644
--- a/src/plugins/advanced_settings/public/management_app/components/search/search.tsx
+++ b/src/plugins/advanced_settings/public/management_app/components/search/search.tsx
@@ -31,7 +31,6 @@
import React, { Fragment, PureComponent } from 'react';
import { i18n } from '@osd/i18n';
import { EuiSearchBar, EuiFormErrorText, Query } from '@elastic/eui';
-
import { getCategoryName } from '../../lib';
interface SearchProps {
@@ -111,6 +110,7 @@ export class Search extends PureComponent {
return (
+ {/* @ts-ignore The Query types that typescript complains about here are identical and is a false flag. Once OUI migration is complete, this ignore can be removed */}
{queryParseError}
diff --git a/src/plugins/console/public/application/containers/editor/legacy/console_editor/editor.tsx b/src/plugins/console/public/application/containers/editor/legacy/console_editor/editor.tsx
index 876e94d4cbcb..1c47cc41e920 100644
--- a/src/plugins/console/public/application/containers/editor/legacy/console_editor/editor.tsx
+++ b/src/plugins/console/public/application/containers/editor/legacy/console_editor/editor.tsx
@@ -231,7 +231,6 @@ function EditorUI({ initialTextValue, dataSourceId }: EditorProps) {
return (
-
{
@@ -45,10 +46,10 @@ describe('Input', () => {
coreEditor = create(document.querySelector('#ConAppEditor'));
- coreEditor.getContainer().style.display = '';
+ $(coreEditor.getContainer()).show();
});
afterEach(() => {
- coreEditor.getContainer().style.display = 'none';
+ $(coreEditor.getContainer()).hide();
});
describe('.getLineCount', () => {
diff --git a/src/plugins/console/public/application/models/legacy_core_editor/__tests__/output_tokenization.test.js b/src/plugins/console/public/application/models/legacy_core_editor/__tests__/output_tokenization.test.js
index d143d72e15c2..4973011a2aaa 100644
--- a/src/plugins/console/public/application/models/legacy_core_editor/__tests__/output_tokenization.test.js
+++ b/src/plugins/console/public/application/models/legacy_core_editor/__tests__/output_tokenization.test.js
@@ -29,6 +29,7 @@
*/
import '../legacy_core_editor.test.mocks';
+import $ from 'jquery';
import RowParser from '../../../../lib/row_parser';
import ace from 'brace';
import { createReadOnlyAceEditor } from '../create_readonly';
@@ -38,11 +39,11 @@ const tokenIterator = ace.acequire('ace/token_iterator');
describe('Output Tokenization', () => {
beforeEach(() => {
output = createReadOnlyAceEditor(document.querySelector('#ConAppOutput'));
- output.container.style.display = '';
+ $(output.container).show();
});
afterEach(() => {
- output.container.style.display = 'none';
+ $(output.container).hide();
});
function tokensAsList() {
diff --git a/src/plugins/console/public/application/models/legacy_core_editor/legacy_core_editor.ts b/src/plugins/console/public/application/models/legacy_core_editor/legacy_core_editor.ts
index 5fe93ca4e094..55ee5fe2a343 100644
--- a/src/plugins/console/public/application/models/legacy_core_editor/legacy_core_editor.ts
+++ b/src/plugins/console/public/application/models/legacy_core_editor/legacy_core_editor.ts
@@ -30,6 +30,7 @@
import ace from 'brace';
import { Editor as IAceEditor, IEditSession as IAceEditSession } from 'brace';
+import $ from 'jquery';
import {
CoreEditor,
Position,
@@ -53,11 +54,11 @@ const rangeToAceRange = ({ start, end }: Range) =>
export class LegacyCoreEditor implements CoreEditor {
private _aceOnPaste: any;
- actions: any;
+ $actions: any;
resize: () => void;
constructor(private readonly editor: IAceEditor, actions: HTMLElement) {
- this.actions = actions;
+ this.$actions = $(actions);
this.editor.setShowPrintMargin(false);
const session = this.editor.getSession();
@@ -273,16 +274,20 @@ export class LegacyCoreEditor implements CoreEditor {
private setActionsBar = (value?: any, topOrBottom: 'top' | 'bottom' = 'top') => {
if (value === null) {
- this.actions.style.visibility = 'hidden';
+ this.$actions.css('visibility', 'hidden');
} else {
if (topOrBottom === 'top') {
- this.actions.style.bottom = 'auto';
- this.actions.style.top = value;
- this.actions.style.visibility = 'visible';
+ this.$actions.css({
+ bottom: 'auto',
+ top: value,
+ visibility: 'visible',
+ });
} else {
- this.actions.style.top = 'auto';
- this.actions.style.bottom = value;
- this.actions.style.visibility = 'visible';
+ this.$actions.css({
+ top: 'auto',
+ bottom: value,
+ visibility: 'visible',
+ });
}
}
};
@@ -313,14 +318,14 @@ export class LegacyCoreEditor implements CoreEditor {
}
legacyUpdateUI(range: any) {
- if (!this.actions) {
+ if (!this.$actions) {
return;
}
if (range) {
// elements are positioned relative to the editor's container
// pageY is relative to page, so subtract the offset
// from pageY to get the new top value
- const offsetFromPage = this.editor.container.offsetTop;
+ const offsetFromPage = $(this.editor.container).offset()!.top;
const startLine = range.start.lineNumber;
const startColumn = range.start.column;
const firstLine = this.getLineValue(startLine);
@@ -340,11 +345,11 @@ export class LegacyCoreEditor implements CoreEditor {
let offset = 0;
if (isWrapping) {
// Try get the line height of the text area in pixels.
- const textArea = this.editor.container.querySelector('textArea');
+ const textArea = $(this.editor.container.querySelector('textArea')!);
const hasRoomOnNextLine = this.getLineValue(startLine).length < maxLineLength;
if (textArea && hasRoomOnNextLine) {
// Line height + the number of wraps we have on a line.
- offset += this.getLineValue(startLine).length * textArea.getBoundingClientRect().height;
+ offset += this.getLineValue(startLine).length * textArea.height()!;
} else {
if (startLine > 1) {
this.setActionsBar(getScreenCoords(startLine - 1));
diff --git a/src/plugins/console/public/application/models/sense_editor/__tests__/integration.test.js b/src/plugins/console/public/application/models/sense_editor/__tests__/integration.test.js
index 88f9acc27e7f..cf6df4d31b06 100644
--- a/src/plugins/console/public/application/models/sense_editor/__tests__/integration.test.js
+++ b/src/plugins/console/public/application/models/sense_editor/__tests__/integration.test.js
@@ -44,11 +44,11 @@ describe('Integration', () => {
'';
senseEditor = create(document.querySelector('#ConAppEditor'));
- senseEditor.getCoreEditor().getContainer().style.display = '';
+ $(senseEditor.getCoreEditor().getContainer()).show();
senseEditor.autocomplete._test.removeChangeListener();
});
afterEach(() => {
- senseEditor.getCoreEditor().getContainer().style.display = 'none';
+ $(senseEditor.getCoreEditor().getContainer()).hide();
senseEditor.autocomplete._test.addChangeListener();
});
diff --git a/src/plugins/console/public/application/models/sense_editor/__tests__/sense_editor.test.js b/src/plugins/console/public/application/models/sense_editor/__tests__/sense_editor.test.js
index de67ae1a8908..18d798c28c94 100644
--- a/src/plugins/console/public/application/models/sense_editor/__tests__/sense_editor.test.js
+++ b/src/plugins/console/public/application/models/sense_editor/__tests__/sense_editor.test.js
@@ -30,6 +30,7 @@
import '../sense_editor.test.mocks';
+import $ from 'jquery';
import _ from 'lodash';
import { create } from '../create';
@@ -50,11 +51,11 @@ describe('Editor', () => {
`;
input = create(document.querySelector('#ConAppEditor'));
- input.getCoreEditor().getContainer().style.display = '';
+ $(input.getCoreEditor().getContainer()).show();
input.autocomplete._test.removeChangeListener();
});
afterEach(function () {
- input.getCoreEditor().getContainer().style.display = 'none';
+ $(input.getCoreEditor().getContainer()).hide();
input.autocomplete._test.addChangeListener();
});
diff --git a/src/plugins/console/public/application/models/sense_editor/sense_editor.test.mocks.ts b/src/plugins/console/public/application/models/sense_editor/sense_editor.test.mocks.ts
index 92e86d60104c..183878e7a582 100644
--- a/src/plugins/console/public/application/models/sense_editor/sense_editor.test.mocks.ts
+++ b/src/plugins/console/public/application/models/sense_editor/sense_editor.test.mocks.ts
@@ -31,3 +31,9 @@
/* eslint no-undef: 0 */
import '../legacy_core_editor/legacy_core_editor.test.mocks';
+
+global.fetch = jest.fn(() =>
+ Promise.resolve({
+ json: () => Promise.resolve({}),
+ })
+);
diff --git a/src/plugins/console/public/lib/ace_token_provider/token_provider.test.ts b/src/plugins/console/public/lib/ace_token_provider/token_provider.test.ts
index a933fdeb8010..55c18381cb9c 100644
--- a/src/plugins/console/public/lib/ace_token_provider/token_provider.test.ts
+++ b/src/plugins/console/public/lib/ace_token_provider/token_provider.test.ts
@@ -30,6 +30,8 @@
import '../../application/models/sense_editor/sense_editor.test.mocks';
+import $ from 'jquery';
+
// TODO:
// We import from application models as a convenient way to bootstrap loading up of an editor using
// this lib. We also need to import application specific mocks which is not ideal.
@@ -57,14 +59,14 @@ describe('Ace (legacy) token provider', () => {
senseEditor = create(document.querySelector
('#ConAppEditor')!);
- senseEditor.getCoreEditor().getContainer().style.display = '';
+ $(senseEditor.getCoreEditor().getContainer())!.show();
(senseEditor as any).autocomplete._test.removeChangeListener();
tokenProvider = senseEditor.getCoreEditor().getTokenProvider();
});
afterEach(async () => {
- senseEditor.getCoreEditor().getContainer().style.display = 'none';
+ $(senseEditor.getCoreEditor().getContainer())!.hide();
(senseEditor as any).autocomplete._test.addChangeListener();
await senseEditor.update('', true);
});
diff --git a/src/plugins/console/public/lib/osd/osd.js b/src/plugins/console/public/lib/osd/osd.js
index cf8126271072..529fba754a93 100644
--- a/src/plugins/console/public/lib/osd/osd.js
+++ b/src/plugins/console/public/lib/osd/osd.js
@@ -38,6 +38,7 @@ import {
UsernameAutocompleteComponent,
} from '../autocomplete/components';
+import $ from 'jquery';
import _ from 'lodash';
import Api from './api';
@@ -173,19 +174,20 @@ function loadApisFromJson(
// like this, it looks like a minor security issue.
export function setActiveApi(api) {
if (!api) {
- fetch('../api/console/api_server', {
- method: 'GET',
+ $.ajax({
+ url: '../api/console/api_server',
+ dataType: 'json', // disable automatic guessing
headers: {
'osd-xsrf': 'opensearch-dashboards',
},
- })
- .then(function (response) {
- response.json();
- })
- .then(function (data) {
+ }).then(
+ function (data) {
setActiveApi(loadApisFromJson(data));
- })
- .catch((error) => console.log(`failed to load API '${api}': ${error}`));
+ },
+ function (jqXHR) {
+ console.log("failed to load API '" + api + "': " + jqXHR.responseText);
+ }
+ );
return;
}
diff --git a/src/plugins/console/public/styles/_app.scss b/src/plugins/console/public/styles/_app.scss
index c149832ec1db..161d1f200afd 100644
--- a/src/plugins/console/public/styles/_app.scss
+++ b/src/plugins/console/public/styles/_app.scss
@@ -77,18 +77,6 @@
z-index: $euiZLevel1;
}
-// SASSTODO: This component seems to not be used anymore?
-// Possibly replaced by the Ace version
-.conApp__autoComplete {
- position: absolute;
- left: -1000px;
- visibility: hidden;
-
- /* by pass any other element in ace and resize bar, but not modal popups */
- z-index: $euiZLevel1 + 2;
- margin-top: 22px;
-}
-
.conApp__settingsModal {
min-width: 460px;
}
diff --git a/src/plugins/dashboard/public/application/dashboard_empty_screen.test.tsx b/src/plugins/dashboard/public/application/dashboard_empty_screen.test.tsx
index fd4291b29455..ac22b069135c 100644
--- a/src/plugins/dashboard/public/application/dashboard_empty_screen.test.tsx
+++ b/src/plugins/dashboard/public/application/dashboard_empty_screen.test.tsx
@@ -31,7 +31,7 @@
import React from 'react';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
import { DashboardEmptyScreen, DashboardEmptyScreenProps } from './dashboard_empty_screen';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { coreMock } from '../../../../core/public/mocks';
describe('DashboardEmptyScreen', () => {
diff --git a/src/plugins/dashboard/public/application/legacy_app.js b/src/plugins/dashboard/public/application/legacy_app.js
index 3ed961e54049..0c10653d7f41 100644
--- a/src/plugins/dashboard/public/application/legacy_app.js
+++ b/src/plugins/dashboard/public/application/legacy_app.js
@@ -150,7 +150,7 @@ export function initDashboardApp(app, deps) {
type: $scope.dashboardListTypes,
search: search ? `${search}*` : undefined,
fields: ['title', 'type', 'description', 'updated_at'],
- perPage: $scope.initialPageSize,
+ perPage: $scope.listingLimit,
page: 1,
searchFields: ['title^3', 'type', 'description'],
defaultSearchOperator: 'AND',
@@ -163,11 +163,19 @@ export function initDashboardApp(app, deps) {
};
};
- $scope.editItem = ({ editUrl }) => {
- history.push(editUrl);
+ $scope.editItem = ({ appId, editUrl }) => {
+ if (appId === 'dashboard') {
+ history.push(editUrl);
+ } else {
+ deps.core.application.navigateToUrl(editUrl);
+ }
};
- $scope.viewItem = ({ viewUrl }) => {
- history.push(deps.addBasePath(viewUrl));
+ $scope.viewItem = ({ appId, viewUrl }) => {
+ if (appId === 'dashboard') {
+ history.push(viewUrl);
+ } else {
+ deps.core.application.navigateToUrl(viewUrl);
+ }
};
$scope.delete = (dashboards) => {
const ids = dashboards.map((d) => ({ id: d.id, appId: d.appId }));
diff --git a/src/plugins/dashboard/public/application/listing/create_button.test.tsx b/src/plugins/dashboard/public/application/listing/create_button.test.tsx
index 5d2a200f55df..9521df8590e6 100644
--- a/src/plugins/dashboard/public/application/listing/create_button.test.tsx
+++ b/src/plugins/dashboard/public/application/listing/create_button.test.tsx
@@ -57,7 +57,7 @@ describe('create button with props', () => {
expect(createButtons.length).toBe(0);
const createDropdown = findTestSubject(component, 'createMenuDropdown');
createDropdown.simulate('click');
- const contextMenus = findTestSubject(component, 'contextMenuItem');
+ const contextMenus = findTestSubject(component, 'contextMenuItem-test');
expect(contextMenus.length).toBe(2);
expect(contextMenus.at(0).prop('href')).toBe('test1');
});
diff --git a/src/plugins/dashboard/public/application/listing/create_button.tsx b/src/plugins/dashboard/public/application/listing/create_button.tsx
index 04e6df883779..4959603fa271 100644
--- a/src/plugins/dashboard/public/application/listing/create_button.tsx
+++ b/src/plugins/dashboard/public/application/listing/create_button.tsx
@@ -38,7 +38,7 @@ const CreateButton = (props: CreateButtonProps) => {
{provider.createLinkText}
diff --git a/src/plugins/dashboard/public/application/tests/dashboard_container.test.tsx b/src/plugins/dashboard/public/application/tests/dashboard_container.test.tsx
index d3198f6e1e31..2746997947c9 100644
--- a/src/plugins/dashboard/public/application/tests/dashboard_container.test.tsx
+++ b/src/plugins/dashboard/public/application/tests/dashboard_container.test.tsx
@@ -28,7 +28,7 @@
* under the License.
*/
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import React from 'react';
import { mount } from 'enzyme';
import { nextTick } from 'test_utils/enzyme_helpers';
diff --git a/src/plugins/data/public/ui/shard_failure_modal/shard_failure_open_modal_button.test.tsx b/src/plugins/data/public/ui/shard_failure_modal/shard_failure_open_modal_button.test.tsx
index 1ff83cf474c2..9a6b71ae6459 100644
--- a/src/plugins/data/public/ui/shard_failure_modal/shard_failure_open_modal_button.test.tsx
+++ b/src/plugins/data/public/ui/shard_failure_modal/shard_failure_open_modal_button.test.tsx
@@ -34,7 +34,7 @@ import { mountWithIntl } from 'test_utils/enzyme_helpers';
import ShardFailureOpenModalButton from './shard_failure_open_modal_button';
import { shardFailureRequest } from './__mocks__/shard_failure_request';
import { shardFailureResponse } from './__mocks__/shard_failure_response';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
describe('ShardFailureOpenModalButton', () => {
it('triggers the openModal function when "Show details" button is clicked', () => {
diff --git a/src/plugins/data_source/common/data_sources/types.ts b/src/plugins/data_source/common/data_sources/types.ts
index 366e5a0f3f55..8763c5306c15 100644
--- a/src/plugins/data_source/common/data_sources/types.ts
+++ b/src/plugins/data_source/common/data_sources/types.ts
@@ -25,6 +25,7 @@ export interface SigV4Content extends SavedObjectAttributes {
accessKey: string;
secretKey: string;
region: string;
+ service?: SigV4ServiceName;
}
export interface UsernamePasswordTypedContent extends SavedObjectAttributes {
@@ -37,3 +38,8 @@ export enum AuthType {
UsernamePasswordType = 'username_password',
SigV4 = 'sigv4',
}
+
+export enum SigV4ServiceName {
+ OpenSearch = 'es',
+ OpenSearchServerless = 'aoss',
+}
diff --git a/src/plugins/data_source/config.ts b/src/plugins/data_source/config.ts
index 1fc4e00c3e23..09ce35978921 100644
--- a/src/plugins/data_source/config.ts
+++ b/src/plugins/data_source/config.ts
@@ -37,6 +37,7 @@ export const configSchema = schema.object({
enabled: schema.boolean({ defaultValue: false }),
appender: fileAppenderSchema,
}),
+ endpointDeniedIPs: schema.maybe(schema.arrayOf(schema.string())),
});
export type DataSourcePluginConfigType = TypeOf;
diff --git a/src/plugins/data_source/opensearch_dashboards.json b/src/plugins/data_source/opensearch_dashboards.json
index 71183a411c79..871858403cf3 100644
--- a/src/plugins/data_source/opensearch_dashboards.json
+++ b/src/plugins/data_source/opensearch_dashboards.json
@@ -5,5 +5,6 @@
"server": true,
"ui": true,
"requiredPlugins": [],
- "optionalPlugins": []
+ "optionalPlugins": [],
+ "extraPublicDirs": ["common/data_sources"]
}
diff --git a/src/plugins/data_source/server/client/configure_client.test.ts b/src/plugins/data_source/server/client/configure_client.test.ts
index 1499ccd411c2..aa367f0a6f89 100644
--- a/src/plugins/data_source/server/client/configure_client.test.ts
+++ b/src/plugins/data_source/server/client/configure_client.test.ts
@@ -167,6 +167,30 @@ describe('configureClient', () => {
expect(decodeAndDecryptSpy).toHaveBeenCalledTimes(2);
});
+ test('configure client with auth.type == sigv4, service == aoss, should successfully call new Client()', async () => {
+ savedObjectsMock.get.mockReset().mockResolvedValueOnce({
+ id: DATA_SOURCE_ID,
+ type: DATA_SOURCE_SAVED_OBJECT_TYPE,
+ attributes: {
+ ...dataSourceAttr,
+ auth: {
+ type: AuthType.SigV4,
+ credentials: { ...sigV4AuthContent, service: 'aoss' },
+ },
+ },
+ references: [],
+ });
+
+ jest.spyOn(cryptographyMock, 'decodeAndDecrypt').mockResolvedValue({
+ decryptedText: 'accessKey',
+ encryptionContext: { endpoint: 'http://localhost' },
+ });
+
+ await configureClient(dataSourceClientParams, clientPoolSetup, config, logger);
+
+ expect(ClientMock).toHaveBeenCalledTimes(1);
+ });
+
test('configure test client for non-exist datasource should not call saved object api, nor decode any credential', async () => {
const decodeAndDecryptSpy = jest.spyOn(cryptographyMock, 'decodeAndDecrypt').mockResolvedValue({
decryptedText: 'password',
diff --git a/src/plugins/data_source/server/client/configure_client.ts b/src/plugins/data_source/server/client/configure_client.ts
index 8b43ffa80b23..77a0e067bbc0 100644
--- a/src/plugins/data_source/server/client/configure_client.ts
+++ b/src/plugins/data_source/server/client/configure_client.ts
@@ -160,7 +160,7 @@ const getBasicAuthClient = (
};
const getAWSClient = (credential: SigV4Content, clientOptions: ClientOptions): Client => {
- const { accessKey, secretKey, region } = credential;
+ const { accessKey, secretKey, region, service } = credential;
const credentialProvider = (): Promise => {
return new Promise((resolve) => {
@@ -172,6 +172,7 @@ const getAWSClient = (credential: SigV4Content, clientOptions: ClientOptions): C
...AwsSigv4Signer({
region,
getCredentials: credentialProvider,
+ service,
}),
...clientOptions,
});
diff --git a/src/plugins/data_source/server/client/configure_client_utils.ts b/src/plugins/data_source/server/client/configure_client_utils.ts
index 3ef8acc97b58..2ca6c6f2a83f 100644
--- a/src/plugins/data_source/server/client/configure_client_utils.ts
+++ b/src/plugins/data_source/server/client/configure_client_utils.ts
@@ -91,7 +91,7 @@ export const getAWSCredential = async (
cryptography: CryptographyServiceSetup
): Promise => {
const { endpoint } = dataSource;
- const { accessKey, secretKey, region } = dataSource.auth.credentials! as SigV4Content;
+ const { accessKey, secretKey, region, service } = dataSource.auth.credentials! as SigV4Content;
const {
decryptedText: accessKeyText,
@@ -122,6 +122,7 @@ export const getAWSCredential = async (
region,
accessKey: accessKeyText,
secretKey: secretKeyText,
+ service,
};
return credential;
diff --git a/src/plugins/data_source/server/legacy/configure_legacy_client.test.ts b/src/plugins/data_source/server/legacy/configure_legacy_client.test.ts
index c047da70b285..59c110d06dc5 100644
--- a/src/plugins/data_source/server/legacy/configure_legacy_client.test.ts
+++ b/src/plugins/data_source/server/legacy/configure_legacy_client.test.ts
@@ -6,7 +6,7 @@
import { SavedObjectsClientContract } from '../../../../core/server';
import { loggingSystemMock, savedObjectsClientMock } from '../../../../core/server/mocks';
import { DATA_SOURCE_SAVED_OBJECT_TYPE } from '../../common';
-import { AuthType, DataSourceAttributes } from '../../common/data_sources';
+import { AuthType, DataSourceAttributes, SigV4Content } from '../../common/data_sources';
import { DataSourcePluginConfigType } from '../../config';
import { cryptographyServiceSetupMock } from '../cryptography_service.mocks';
import { CryptographyServiceSetup } from '../cryptography_service';
@@ -27,6 +27,7 @@ describe('configureLegacyClient', () => {
let clientPoolSetup: OpenSearchClientPoolSetup;
let configOptions: ConfigOptions;
let dataSourceAttr: DataSourceAttributes;
+ let sigV4AuthContent: SigV4Content;
let mockOpenSearchClientInstance: {
close: jest.Mock;
@@ -71,6 +72,12 @@ describe('configureLegacyClient', () => {
},
} as DataSourceAttributes;
+ sigV4AuthContent = {
+ region: 'us-east-1',
+ accessKey: 'accessKey',
+ secretKey: 'secretKey',
+ };
+
clientPoolSetup = {
getClientFromPool: jest.fn(),
addClientToPool: jest.fn(),
@@ -157,6 +164,42 @@ describe('configureLegacyClient', () => {
expect(mockResult).toBeDefined();
});
+ test('configure client with auth.type == sigv4 and service param, should call new Client() with service param', async () => {
+ savedObjectsMock.get.mockReset().mockResolvedValueOnce({
+ id: DATA_SOURCE_ID,
+ type: DATA_SOURCE_SAVED_OBJECT_TYPE,
+ attributes: {
+ ...dataSourceAttr,
+ auth: {
+ type: AuthType.SigV4,
+ credentials: { ...sigV4AuthContent, service: 'aoss' },
+ },
+ },
+ references: [],
+ });
+
+ parseClientOptionsMock.mockReturnValue(configOptions);
+
+ jest.spyOn(cryptographyMock, 'decodeAndDecrypt').mockResolvedValue({
+ decryptedText: 'accessKey',
+ encryptionContext: { endpoint: 'http://localhost' },
+ });
+
+ await configureLegacyClient(
+ dataSourceClientParams,
+ callApiParams,
+ clientPoolSetup,
+ config,
+ logger
+ );
+
+ expect(parseClientOptionsMock).toHaveBeenCalled();
+ expect(ClientMock).toHaveBeenCalledTimes(1);
+ expect(ClientMock).toHaveBeenCalledWith(expect.objectContaining({ service: 'aoss' }));
+
+ expect(savedObjectsMock.get).toHaveBeenCalledTimes(1);
+ });
+
test('configure client with auth.type == username_password and password contaminated', async () => {
const decodeAndDecryptSpy = jest
.spyOn(cryptographyMock, 'decodeAndDecrypt')
diff --git a/src/plugins/data_source/server/legacy/configure_legacy_client.ts b/src/plugins/data_source/server/legacy/configure_legacy_client.ts
index 3a9b65634a28..0d074cf77d4a 100644
--- a/src/plugins/data_source/server/legacy/configure_legacy_client.ts
+++ b/src/plugins/data_source/server/legacy/configure_legacy_client.ts
@@ -5,10 +5,9 @@
import { Client } from '@opensearch-project/opensearch';
import { Client as LegacyClient, ConfigOptions } from 'elasticsearch';
-import { Credentials } from 'aws-sdk';
+import { Credentials, Config } from 'aws-sdk';
import { get } from 'lodash';
import HttpAmazonESConnector from 'http-aws-es';
-import { Config } from 'aws-sdk';
import {
Headers,
LegacyAPICaller,
@@ -27,7 +26,7 @@ import { CryptographyServiceSetup } from '../cryptography_service';
import { DataSourceClientParams, LegacyClientCallAPIParams } from '../types';
import { OpenSearchClientPoolSetup } from '../client';
import { parseClientOptions } from './client_config';
-import { createDataSourceError, DataSourceError } from '../lib/error';
+import { createDataSourceError } from '../lib/error';
import {
getRootClient,
getAWSCredential,
@@ -195,13 +194,14 @@ const getBasicAuthClient = async (
};
const getAWSClient = (credential: SigV4Content, clientOptions: ConfigOptions): LegacyClient => {
- const { accessKey, secretKey, region } = credential;
+ const { accessKey, secretKey, region, service } = credential;
const client = new LegacyClient({
connectionClass: HttpAmazonESConnector,
awsConfig: new Config({
region,
credentials: new Credentials({ accessKeyId: accessKey, secretAccessKey: secretKey }),
}),
+ service,
...clientOptions,
});
return client;
diff --git a/src/plugins/data_source/server/plugin.ts b/src/plugins/data_source/server/plugin.ts
index e038a0f7685e..0f3c47be4b4c 100644
--- a/src/plugins/data_source/server/plugin.ts
+++ b/src/plugins/data_source/server/plugin.ts
@@ -58,7 +58,8 @@ export class DataSourcePlugin implements Plugin();
+ // Amazon OpenSearch Serverless does not support .info() API
+ if (this.dataSourceAttr.auth?.credentials?.service === SigV4ServiceName.OpenSearchServerless)
+ return await this.callDataCluster.cat.indices();
+ return await this.callDataCluster.info();
} catch (e) {
throw createDataSourceError(e);
}
diff --git a/src/plugins/data_source/server/routes/test_connection.ts b/src/plugins/data_source/server/routes/test_connection.ts
index c15bb8945015..33f588b5a5ff 100644
--- a/src/plugins/data_source/server/routes/test_connection.ts
+++ b/src/plugins/data_source/server/routes/test_connection.ts
@@ -5,6 +5,9 @@
import { schema } from '@osd/config-schema';
import { IRouter, OpenSearchClient } from 'opensearch-dashboards/server';
+import { AuthType, DataSourceAttributes, SigV4ServiceName } from '../../common/data_sources';
+import { DataSourceConnectionValidator } from './data_source_connection_validator';
+import { DataSourceServiceSetup } from '../data_source_service';
import { CryptographyServiceSetup } from '../cryptography_service';
export const registerTestConnectionRoute = (
router: IRouter,
@@ -36,6 +39,10 @@ export const registerTestConnectionRoute = (
region: schema.string(),
accessKey: schema.string(),
secretKey: schema.string(),
+ service: schema.oneOf([
+ schema.literal(SigV4ServiceName.OpenSearch),
+ schema.literal(SigV4ServiceName.OpenSearchServerless),
+ ]),
}),
])
),
@@ -57,9 +64,13 @@ export const registerTestConnectionRoute = (
testClientDataSourceAttr: dataSourceAttr as DataSourceAttributes,
}
);
- const dsValidator = new DataSourceConnectionValidator(dataSourceClient);
- await dsValidator.validate();
+ const dataSourceValidator = new DataSourceConnectionValidator(
+ dataSourceClient,
+ dataSourceAttr
+ );
+
+ await dataSourceValidator.validate();
return response.ok({
body: {
diff --git a/src/plugins/data_source/server/saved_objects/data_source_saved_objects_client_wrapper.ts b/src/plugins/data_source/server/saved_objects/data_source_saved_objects_client_wrapper.ts
index 6b79248d1a94..12d60b8da51e 100644
--- a/src/plugins/data_source/server/saved_objects/data_source_saved_objects_client_wrapper.ts
+++ b/src/plugins/data_source/server/saved_objects/data_source_saved_objects_client_wrapper.ts
@@ -24,14 +24,13 @@ import {
UsernamePasswordTypedContent,
} from '../../common/data_sources';
import { EncryptionContext, CryptographyServiceSetup } from '../cryptography_service';
+import { isValidURL } from '../util/endpoint_validator';
/**
* Describes the Credential Saved Objects Client Wrapper class,
* which contains the factory used to create Saved Objects Client Wrapper instances
*/
export class DataSourceSavedObjectsClientWrapper {
- constructor(private cryptography: CryptographyServiceSetup, private logger: Logger) {}
-
/**
* Describes the factory used to create instances of Saved Objects Client Wrappers
* for data source specific operations such as credentials encryption
@@ -138,14 +137,11 @@ export class DataSourceSavedObjectsClientWrapper {
};
};
- private isValidUrl(endpoint: string) {
- try {
- const url = new URL(endpoint);
- return Boolean(url) && (url.protocol === 'http:' || url.protocol === 'https:');
- } catch (e) {
- return false;
- }
- }
+ constructor(
+ private cryptography: CryptographyServiceSetup,
+ private logger: Logger,
+ private endpointBlockedIps?: string[]
+ ) {}
private async validateAndEncryptAttributes(attributes: T) {
this.validateAttributes(attributes);
@@ -254,8 +250,10 @@ export class DataSourceSavedObjectsClientWrapper {
);
}
- if (!this.isValidUrl(endpoint)) {
- throw SavedObjectsErrorHelpers.createBadRequestError('"endpoint" attribute is not valid');
+ if (!isValidURL(endpoint, this.endpointBlockedIps)) {
+ throw SavedObjectsErrorHelpers.createBadRequestError(
+ '"endpoint" attribute is not valid or allowed'
+ );
}
if (!auth) {
@@ -303,7 +301,7 @@ export class DataSourceSavedObjectsClientWrapper {
);
}
- const { accessKey, secretKey, region } = credentials as SigV4Content;
+ const { accessKey, secretKey, region, service } = credentials as SigV4Content;
if (!accessKey) {
throw SavedObjectsErrorHelpers.createBadRequestError(
@@ -322,6 +320,12 @@ export class DataSourceSavedObjectsClientWrapper {
'"auth.credentials.region" attribute is required'
);
}
+
+ if (!service) {
+ throw SavedObjectsErrorHelpers.createBadRequestError(
+ '"auth.credentials.service" attribute is required'
+ );
+ }
break;
default:
throw SavedObjectsErrorHelpers.createBadRequestError(`Invalid auth type: '${type}'`);
@@ -459,7 +463,7 @@ export class DataSourceSavedObjectsClientWrapper {
private async encryptSigV4Credential(auth: T, encryptionContext: EncryptionContext) {
const {
- credentials: { accessKey, secretKey, region },
+ credentials: { accessKey, secretKey, region, service },
} = auth;
return {
@@ -468,6 +472,7 @@ export class DataSourceSavedObjectsClientWrapper {
region,
accessKey: await this.cryptography.encryptAndEncode(accessKey, encryptionContext),
secretKey: await this.cryptography.encryptAndEncode(secretKey, encryptionContext),
+ service,
},
};
}
diff --git a/src/plugins/data_source/server/util/endpoint_validator.test.js b/src/plugins/data_source/server/util/endpoint_validator.test.js
new file mode 100644
index 000000000000..618bf52d4d95
--- /dev/null
+++ b/src/plugins/data_source/server/util/endpoint_validator.test.js
@@ -0,0 +1,34 @@
+/*
+ * Copyright OpenSearch Contributors
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import * as validator from './endpoint_validator';
+
+describe('endpoint_validator', function () {
+ it('Url1 that should be blocked should return false', function () {
+ expect(validator.isValidURL('http://127.0.0.1', ['127.0.0.0/8'])).toEqual(false);
+ });
+
+ it('Url2 that is invalid should return false', function () {
+ expect(validator.isValidURL('www.test.com', [])).toEqual(false);
+ });
+
+ it('Url3 that is invalid should return false', function () {
+ expect(validator.isValidURL('ftp://www.test.com', [])).toEqual(false);
+ });
+
+ it('Url4 that should be blocked should return false', function () {
+ expect(
+ validator.isValidURL('http://169.254.169.254/latest/meta-data/', ['169.254.0.0/16'])
+ ).toEqual(false);
+ });
+
+ it('Url5 that should not be blocked should return true', function () {
+ expect(validator.isValidURL('https://www.opensearch.org', ['127.0.0.0/8'])).toEqual(true);
+ });
+
+ it('Url6 that should not be blocked should return true when null IPs', function () {
+ expect(validator.isValidURL('https://www.opensearch.org')).toEqual(true);
+ });
+});
diff --git a/src/plugins/data_source/server/util/endpoint_validator.ts b/src/plugins/data_source/server/util/endpoint_validator.ts
new file mode 100644
index 000000000000..1c032037d2f5
--- /dev/null
+++ b/src/plugins/data_source/server/util/endpoint_validator.ts
@@ -0,0 +1,59 @@
+/*
+ * Copyright OpenSearch Contributors
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+import dns from 'dns-sync';
+import IPCIDR from 'ip-cidr';
+
+export function isValidURL(endpoint: string, deniedIPs?: string[]) {
+ // Check the format of URL, URL has be in the format as
+ // scheme://server/path/resource otherwise an TypeError
+ // would be thrown.
+ let url;
+ try {
+ url = new URL(endpoint);
+ } catch (err) {
+ return false;
+ }
+
+ if (!(Boolean(url) && (url.protocol === 'http:' || url.protocol === 'https:'))) {
+ return false;
+ }
+
+ const ip = getIpAddress(url);
+ if (!ip) {
+ return false;
+ }
+
+ // IP CIDR check if a specific IP address fall in the
+ // range of an IP address block
+ for (const deniedIP of deniedIPs ?? []) {
+ const cidr = new IPCIDR(deniedIP);
+ if (cidr.contains(ip)) {
+ return false;
+ }
+ }
+ return true;
+}
+
+/**
+ * Resolve hostname to IP address
+ * @param {object} urlObject
+ * @returns {string} configuredIP
+ * or null if it cannot be resolve
+ * According to RFC, all IPv6 IP address needs to be in []
+ * such as [::1].
+ * So if we detect a IPv6 address, we remove brackets.
+ */
+function getIpAddress(urlObject: URL) {
+ const hostname = urlObject.hostname;
+ const configuredIP = dns.resolve(hostname);
+ if (configuredIP) {
+ return configuredIP;
+ }
+ if (hostname.startsWith('[') && hostname.endsWith(']')) {
+ return hostname.substr(1).slice(0, -1);
+ }
+ return null;
+}
diff --git a/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.test.tsx b/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.test.tsx
index efb3453b6f35..ad1d02c87db4 100644
--- a/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.test.tsx
+++ b/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.test.tsx
@@ -27,6 +27,7 @@ describe('Datasource Management: Create Datasource form', () => {
let component: ReactWrapper, React.Component<{}, {}, any>>;
const mockSubmitHandler = jest.fn();
const mockTestConnectionHandler = jest.fn();
+ const mockCancelHandler = jest.fn();
const getFields = (comp: ReactWrapper, React.Component<{}, {}, any>>) => {
return {
@@ -65,6 +66,7 @@ describe('Datasource Management: Create Datasource form', () => {
),
diff --git a/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.tsx b/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.tsx
index 1c08da5d6371..3107ee84006a 100644
--- a/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.tsx
+++ b/src/plugins/data_source_management/public/components/create_data_source_wizard/components/create_form/create_data_source_form.tsx
@@ -5,7 +5,9 @@
import React from 'react';
import {
+ EuiBottomBar,
EuiButton,
+ EuiButtonEmpty,
EuiFieldPassword,
EuiFieldText,
EuiFlexGroup,
@@ -19,13 +21,14 @@ import {
} from '@elastic/eui';
import { i18n } from '@osd/i18n';
import { FormattedMessage } from '@osd/i18n/react';
+import { SigV4Content, SigV4ServiceName } from '../../../../../../data_source/common/data_sources';
import {
AuthType,
credentialSourceOptions,
DataSourceAttributes,
DataSourceManagementContextValue,
UsernamePasswordTypedContent,
- SigV4Content,
+ sigV4ServiceOptions,
} from '../../../../types';
import { Header } from '../header';
import { context as contextType } from '../../../../../../opensearch_dashboards_react/public';
@@ -41,6 +44,7 @@ export interface CreateDataSourceProps {
existingDatasourceNamesList: string[];
handleSubmit: (formValues: DataSourceAttributes) => void;
handleTestConnection: (formValues: DataSourceAttributes) => void;
+ handleCancel: () => void;
}
export interface CreateDataSourceState {
/* Validation */
@@ -121,7 +125,31 @@ export class CreateDataSourceForm extends React.Component<
};
onChangeAuthType = (e: React.ChangeEvent) => {
- this.setState({ auth: { ...this.state.auth, type: e.target.value as AuthType } });
+ const authType = e.target.value as AuthType;
+ this.setState({
+ auth: {
+ ...this.state.auth,
+ type: authType,
+ credentials: {
+ ...this.state.auth.credentials,
+ service:
+ (this.state.auth.credentials.service as SigV4ServiceName) ||
+ SigV4ServiceName.OpenSearch,
+ },
+ },
+ });
+ };
+
+ onChangeSigV4ServiceName = (e: React.ChangeEvent) => {
+ this.setState({
+ auth: {
+ ...this.state.auth,
+ credentials: {
+ ...this.state.auth.credentials,
+ service: e.target.value as SigV4ServiceName,
+ },
+ },
+ });
};
onChangeUsername = (e: { target: { value: any } }) => {
@@ -267,6 +295,7 @@ export class CreateDataSourceForm extends React.Component<
region: this.state.auth.credentials.region,
accessKey: this.state.auth.credentials.accessKey,
secretKey: this.state.auth.credentials.secretKey,
+ service: this.state.auth.credentials.service || SigV4ServiceName.OpenSearch,
} as SigV4Content;
}
@@ -391,6 +420,19 @@ export class CreateDataSourceForm extends React.Component<
data-test-subj="createDataSourceFormRegionField"
/>
+
+ this.onChangeSigV4ServiceName(e)}
+ name="ServiceName"
+ data-test-subj="createDataSourceFormSigV4ServiceTypeSelect"
+ />
+
{
return (
-
- {this.renderHeader()}
-
-
- {/* Endpoint section */}
- {this.renderSectionHeader(
- 'dataSourceManagement.connectToDataSource.connectionDetails',
- 'Connection Details'
- )}
-
-
- {/* Title */}
-
-
+
+ {this.renderHeader()}
+
+
+ {/* Endpoint section */}
+ {this.renderSectionHeader(
+ 'dataSourceManagement.connectToDataSource.connectionDetails',
+ 'Connection Details'
+ )}
+
+
+ {/* Title */}
+
-
+ error={this.state.formErrorsByField.title}
+ >
+
+
- {/* Description */}
-
-
-
-
- {/* Endpoint URL */}
-
-
+
+
+
+ {/* Endpoint URL */}
+
-
+ error={this.state.formErrorsByField.endpoint}
+ >
+
+
- {/* Authentication Section: */}
+ {/* Authentication Section: */}
-
+
- {this.renderSectionHeader(
- 'dataSourceManagement.connectToDataSource.authenticationHeader',
- 'Authentication Method'
- )}
-
+ {this.renderSectionHeader(
+ 'dataSourceManagement.connectToDataSource.authenticationHeader',
+ 'Authentication Method'
+ )}
+
-
-
-
-
+
+
-
-
-
-
- {/* Credential source */}
-
-
- this.onChangeAuthType(e)}
- name="Credential"
- data-test-subj="createDataSourceFormAuthTypeSelect"
- />
-
-
- {/* Create New credentials */}
- {this.state.auth.type === AuthType.UsernamePasswordType
- ? this.renderCreateNewCredentialsForm(this.state.auth.type)
- : null}
-
- {this.state.auth.type === AuthType.SigV4
- ? this.renderCreateNewCredentialsForm(this.state.auth.type)
- : null}
-
-
-
-
-
- {/* Test Connection button*/}
-
-
-
-
- {/* Create Data Source button*/}
-
-
+
-
-
-
-
-
-
+
+
+
+
+ {/* Credential source */}
+
+
+ this.onChangeAuthType(e)}
+ name="Credential"
+ data-test-subj="createDataSourceFormAuthTypeSelect"
+ />
+
+
+ {/* Create New credentials */}
+ {this.state.auth.type === AuthType.UsernamePasswordType
+ ? this.renderCreateNewCredentialsForm(this.state.auth.type)
+ : null}
+
+ {this.state.auth.type === AuthType.SigV4
+ ? this.renderCreateNewCredentialsForm(this.state.auth.type)
+ : null}
+
+
+
+
+
+ {/* Test Connection button*/}
+
+
+
+
+
+
+
+
+
+
+ {this.renderBottomBar()}
+ >
+ );
+ };
+
+ renderBottomBar = () => {
+ return (
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
);
};
diff --git a/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.test.tsx b/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.test.tsx
index 162af4c891f7..adfbe8808637 100644
--- a/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.test.tsx
+++ b/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.test.tsx
@@ -46,6 +46,7 @@ describe('Datasource Management: Create Datasource Wizard', () => {
});
component.update();
});
+
test('should create datasource successfully', async () => {
spyOn(utils, 'createSingleDataSource').and.returnValue({});
@@ -58,6 +59,7 @@ describe('Datasource Management: Create Datasource Wizard', () => {
expect(utils.createSingleDataSource).toHaveBeenCalled();
expect(history.push).toBeCalledWith('');
});
+
test('should fail to create datasource', async () => {
spyOn(utils, 'createSingleDataSource').and.throwError('error');
await act(async () => {
@@ -93,7 +95,17 @@ describe('Datasource Management: Create Datasource Wizard', () => {
component.update();
expect(utils.testConnection).toHaveBeenCalled();
});
+
+ test('should go back to listing page if clicked on cancel button', async () => {
+ await act(async () => {
+ // @ts-ignore
+ await component.find(formIdentifier).first().prop('handleCancel')();
+ });
+
+ expect(history.push).toBeCalledWith('');
+ });
});
+
describe('case2: should fail to load resources', () => {
beforeEach(async () => {
spyOn(utils, 'getDataSources').and.throwError('');
@@ -116,6 +128,7 @@ describe('Datasource Management: Create Datasource Wizard', () => {
});
component.update();
});
+
test('should not render component and go back to listing page', () => {
expect(history.push).toBeCalledWith('');
});
diff --git a/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.tsx b/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.tsx
index 83477b7a2426..05489ca6258a 100644
--- a/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.tsx
+++ b/src/plugins/data_source_management/public/components/create_data_source_wizard/create_data_source_wizard.tsx
@@ -116,6 +116,7 @@ export const CreateDataSourceWizard: React.FunctionComponent props.history.push('')}
existingDatasourceNamesList={existingDatasourceNamesList}
/>
{isLoading ? : null}
diff --git a/src/plugins/data_source_management/public/components/edit_data_source/components/edit_form/edit_data_source_form.tsx b/src/plugins/data_source_management/public/components/edit_data_source/components/edit_form/edit_data_source_form.tsx
index 8e3128c7e987..e05813ca6f04 100644
--- a/src/plugins/data_source_management/public/components/edit_data_source/components/edit_form/edit_data_source_form.tsx
+++ b/src/plugins/data_source_management/public/components/edit_data_source/components/edit_form/edit_data_source_form.tsx
@@ -23,13 +23,14 @@ import {
} from '@elastic/eui';
import { i18n } from '@osd/i18n';
import { FormattedMessage } from '@osd/i18n/react';
+import { SigV4Content, SigV4ServiceName } from '../../../../../../data_source/common/data_sources';
import { Header } from '../header';
import {
AuthType,
credentialSourceOptions,
DataSourceAttributes,
DataSourceManagementContextValue,
- SigV4Content,
+ sigV4ServiceOptions,
ToastMessageItem,
UsernamePasswordTypedContent,
} from '../../../../types';
@@ -46,9 +47,9 @@ import { UpdateAwsCredentialModal } from '../update_aws_credential_modal';
export interface EditDataSourceProps {
existingDataSource: DataSourceAttributes;
existingDatasourceNamesList: string[];
- handleSubmit: (formValues: DataSourceAttributes) => void;
- handleTestConnection: (formValues: DataSourceAttributes) => void;
- onDeleteDataSource?: () => void;
+ handleSubmit: (formValues: DataSourceAttributes) => Promise;
+ handleTestConnection: (formValues: DataSourceAttributes) => Promise;
+ onDeleteDataSource?: () => Promise;
displayToastMessage: (info: ToastMessageItem) => void;
}
export interface EditDataSourceState {
@@ -58,7 +59,7 @@ export interface EditDataSourceState {
endpoint: string;
auth: {
type: AuthType;
- credentials: UsernamePasswordTypedContent | SigV4Content | undefined;
+ credentials: UsernamePasswordTypedContent | SigV4Content;
};
showUpdatePasswordModal: boolean;
showUpdateAwsCredentialModal: boolean;
@@ -123,7 +124,10 @@ export class EditDataSourceForm extends React.Component) => {
- this.setState({ auth: { ...this.state.auth, type: e.target.value as AuthType } }, () => {
- this.onChangeFormValues();
- });
+ const authType = e.target.value as AuthType;
+ this.setState(
+ {
+ auth: {
+ ...this.state.auth,
+ type: authType,
+ credentials: {
+ ...this.state.auth.credentials,
+ service:
+ (this.state.auth.credentials?.service as SigV4ServiceName) ||
+ SigV4ServiceName.OpenSearch,
+ },
+ },
+ },
+ () => {
+ this.onChangeFormValues();
+ }
+ );
};
onChangeDescription = (e: { target: { value: any } }) => {
@@ -183,6 +202,7 @@ export class EditDataSourceForm extends React.Component {
const isValid = !!this.state.auth.credentials.username?.trim().length;
this.setState({
@@ -221,6 +241,18 @@ export class EditDataSourceForm extends React.Component) => {
+ this.setState({
+ auth: {
+ ...this.state.auth,
+ credentials: {
+ ...this.state.auth.credentials,
+ service: e.target.value as SigV4ServiceName,
+ } as SigV4Content,
+ },
+ });
+ };
+
onChangeRegion = (e: { target: { value: any } }) => {
this.setState({
auth: {
@@ -253,7 +285,7 @@ export class EditDataSourceForm extends React.Component {
- const isValid = !!this.state.auth.credentials.accessKey;
+ const isValid = !!this.state.auth.credentials?.accessKey;
this.setState({
formErrorsByField: {
...this.state.formErrorsByField,
@@ -275,7 +307,7 @@ export class EditDataSourceForm extends React.Component {
- const isValid = !!this.state.auth.credentials.secretKey;
+ const isValid = !!this.state.auth.credentials?.secretKey;
this.setState({
formErrorsByField: {
...this.state.formErrorsByField,
@@ -338,9 +370,9 @@ export class EditDataSourceForm extends React.Component {
+ onClickDeleteDataSource = async () => {
if (this.props.onDeleteDataSource) {
- this.props.onDeleteDataSource();
+ await this.props.onDeleteDataSource();
}
};
@@ -359,6 +391,7 @@ export class EditDataSourceForm extends React.Component
@@ -785,7 +819,20 @@ export class EditDataSourceForm extends React.Component
+
+
+ this.onChangeSigV4ServiceName(e)}
+ name="ServiceName"
+ data-test-subj="editDataSourceFormSigV4ServiceTypeSelect"
/>
@@ -930,17 +977,21 @@ export class EditDataSourceForm extends React.Component void;
closeUpdateAwsCredentialModal: () => void;
}
export const UpdateAwsCredentialModal = ({
region,
+ service,
handleUpdateAwsCredential,
closeUpdateAwsCredentialModal,
}: UpdateAwsCredentialModalProps) => {
@@ -87,6 +91,16 @@ export const UpdateAwsCredentialModal = ({
+ {/* Service Name */}
+
+
+ {sigV4ServiceOptions.find((option) => option.value === service)?.text}
+
+
{/* Region */}
{
defaultMessage: 'Dev Tools',
}),
updater$: this.appStateUpdater,
- euiIconType: '/plugins/home/assets/logos/opensearch_mark_default.svg',
+ icon: '/plugins/home/public/assets/logos/opensearch_mark_default.svg',
order: 9010,
category: DEFAULT_APP_CATEGORIES.management,
mount: async (params: AppMountParameters) => {
diff --git a/src/plugins/discover/public/application/angular/context/components/action_bar/action_bar.test.tsx b/src/plugins/discover/public/application/angular/context/components/action_bar/action_bar.test.tsx
index db5abf3dbed4..2f7cc40b7d9a 100644
--- a/src/plugins/discover/public/application/angular/context/components/action_bar/action_bar.test.tsx
+++ b/src/plugins/discover/public/application/angular/context/components/action_bar/action_bar.test.tsx
@@ -31,7 +31,7 @@
import React from 'react';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
import { ActionBar, ActionBarProps } from './action_bar';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { MAX_CONTEXT_SIZE, MIN_CONTEXT_SIZE } from '../../query_parameters/constants';
describe('Test Discover Context ActionBar for successor | predecessor records', () => {
diff --git a/src/plugins/discover/public/application/angular/doc_table/components/pager/tool_bar_pager_buttons.test.tsx b/src/plugins/discover/public/application/angular/doc_table/components/pager/tool_bar_pager_buttons.test.tsx
index 204d0b161c68..2ac06b2b6ebf 100644
--- a/src/plugins/discover/public/application/angular/doc_table/components/pager/tool_bar_pager_buttons.test.tsx
+++ b/src/plugins/discover/public/application/angular/doc_table/components/pager/tool_bar_pager_buttons.test.tsx
@@ -31,7 +31,7 @@
import React from 'react';
import { mountWithIntl, shallowWithIntl } from 'test_utils/enzyme_helpers';
import { ToolBarPagerButtons } from './tool_bar_pager_buttons';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
test('it renders ToolBarPagerButtons', () => {
const props = {
diff --git a/src/plugins/discover/public/application/angular/doc_table/components/table_header/table_header.test.tsx b/src/plugins/discover/public/application/angular/doc_table/components/table_header/table_header.test.tsx
index 2e486976bbdf..0e8efc18efd5 100644
--- a/src/plugins/discover/public/application/angular/doc_table/components/table_header/table_header.test.tsx
+++ b/src/plugins/discover/public/application/angular/doc_table/components/table_header/table_header.test.tsx
@@ -31,7 +31,7 @@
import React from 'react';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
import { TableHeader } from './table_header';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { SortOrder } from './helpers';
import { IndexPattern, IFieldType } from '../../../../../opensearch_dashboards_services';
diff --git a/src/plugins/discover/public/application/components/context_error_message/context_error_message.test.tsx b/src/plugins/discover/public/application/components/context_error_message/context_error_message.test.tsx
index 30b57eaf0dc5..a1ef06b81cf2 100644
--- a/src/plugins/discover/public/application/components/context_error_message/context_error_message.test.tsx
+++ b/src/plugins/discover/public/application/components/context_error_message/context_error_message.test.tsx
@@ -34,7 +34,7 @@ import { ReactWrapper } from 'enzyme';
import { ContextErrorMessage } from './context_error_message';
// @ts-ignore
import { FAILURE_REASONS, LOADING_STATUS } from '../../angular/context/query';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
describe('loading spinner', function () {
let component: ReactWrapper;
diff --git a/src/plugins/discover/public/application/components/doc/doc.test.tsx b/src/plugins/discover/public/application/components/doc/doc.test.tsx
index 7385f0d360a1..4a3fb740492a 100644
--- a/src/plugins/discover/public/application/components/doc/doc.test.tsx
+++ b/src/plugins/discover/public/application/components/doc/doc.test.tsx
@@ -33,7 +33,7 @@ import React from 'react';
import { act } from 'react-dom/test-utils';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
import { ReactWrapper } from 'enzyme';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { Doc, DocProps } from './doc';
const mockSearchApi = jest.fn();
diff --git a/src/plugins/discover/public/application/components/doc_viewer/doc_viewer.test.tsx b/src/plugins/discover/public/application/components/doc_viewer/doc_viewer.test.tsx
index 843ad5788253..ccab0be41ed2 100644
--- a/src/plugins/discover/public/application/components/doc_viewer/doc_viewer.test.tsx
+++ b/src/plugins/discover/public/application/components/doc_viewer/doc_viewer.test.tsx
@@ -31,7 +31,7 @@
import React from 'react';
import { mount, shallow } from 'enzyme';
import { DocViewer } from './doc_viewer';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { getDocViewsRegistry } from '../../../opensearch_dashboards_services';
import { DocViewRenderProps } from '../../doc_views/doc_views_types';
diff --git a/src/plugins/discover/public/application/components/hits_counter/hits_counter.test.tsx b/src/plugins/discover/public/application/components/hits_counter/hits_counter.test.tsx
index 05435ccae99e..998ababbc47f 100644
--- a/src/plugins/discover/public/application/components/hits_counter/hits_counter.test.tsx
+++ b/src/plugins/discover/public/application/components/hits_counter/hits_counter.test.tsx
@@ -32,7 +32,7 @@ import React from 'react';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
import { ReactWrapper } from 'enzyme';
import { HitsCounter, HitsCounterProps } from './hits_counter';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
describe('hits counter', function () {
let props: HitsCounterProps;
diff --git a/src/plugins/discover/public/application/components/loading_spinner/loading_spinner.test.tsx b/src/plugins/discover/public/application/components/loading_spinner/loading_spinner.test.tsx
index 5bc6aa29136b..fbc98e2550e0 100644
--- a/src/plugins/discover/public/application/components/loading_spinner/loading_spinner.test.tsx
+++ b/src/plugins/discover/public/application/components/loading_spinner/loading_spinner.test.tsx
@@ -32,7 +32,7 @@ import React from 'react';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
import { ReactWrapper } from 'enzyme';
import { LoadingSpinner } from './loading_spinner';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
describe('loading spinner', function () {
let component: ReactWrapper;
diff --git a/src/plugins/discover/public/application/components/sidebar/discover_field_search.test.tsx b/src/plugins/discover/public/application/components/sidebar/discover_field_search.test.tsx
index 9170adccc7e7..f78505e11f1e 100644
--- a/src/plugins/discover/public/application/components/sidebar/discover_field_search.test.tsx
+++ b/src/plugins/discover/public/application/components/sidebar/discover_field_search.test.tsx
@@ -31,7 +31,7 @@
import React from 'react';
import { act } from 'react-dom/test-utils';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { DiscoverFieldSearch, Props } from './discover_field_search';
import { EuiButtonGroupProps, EuiPopover } from '@elastic/eui';
import { ReactWrapper } from 'enzyme';
diff --git a/src/plugins/discover/public/application/components/sidebar/discover_sidebar.test.tsx b/src/plugins/discover/public/application/components/sidebar/discover_sidebar.test.tsx
index dbc8c8962466..fa692ca22b5b 100644
--- a/src/plugins/discover/public/application/components/sidebar/discover_sidebar.test.tsx
+++ b/src/plugins/discover/public/application/components/sidebar/discover_sidebar.test.tsx
@@ -30,7 +30,7 @@
import _ from 'lodash';
import { ReactWrapper } from 'enzyme';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
// @ts-ignore
import realHits from 'fixtures/real_hits.js';
// @ts-ignore
diff --git a/src/plugins/discover/public/application/components/table/table.test.tsx b/src/plugins/discover/public/application/components/table/table.test.tsx
index bb10fc137bcb..220ac57feae2 100644
--- a/src/plugins/discover/public/application/components/table/table.test.tsx
+++ b/src/plugins/discover/public/application/components/table/table.test.tsx
@@ -30,7 +30,7 @@
import React from 'react';
import { mount } from 'enzyme';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { DocViewTable } from './table';
import { indexPatterns, IndexPattern } from '../../../../../data/public';
diff --git a/src/plugins/discover/public/application/components/timechart_header/timechart_header.test.tsx b/src/plugins/discover/public/application/components/timechart_header/timechart_header.test.tsx
index 4a88e469a086..9011c38a6acb 100644
--- a/src/plugins/discover/public/application/components/timechart_header/timechart_header.test.tsx
+++ b/src/plugins/discover/public/application/components/timechart_header/timechart_header.test.tsx
@@ -33,7 +33,7 @@ import { mountWithIntl } from 'test_utils/enzyme_helpers';
import { ReactWrapper } from 'enzyme';
import { TimechartHeader, TimechartHeaderProps } from './timechart_header';
import { EuiIconTip } from '@elastic/eui';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
describe('timechart header', function () {
let props: TimechartHeaderProps;
diff --git a/src/plugins/embeddable/docs/input_and_output_state.md b/src/plugins/embeddable/docs/input_and_output_state.md
index 2fd8799099b6..a0cd4cc5c0ef 100644
--- a/src/plugins/embeddable/docs/input_and_output_state.md
+++ b/src/plugins/embeddable/docs/input_and_output_state.md
@@ -274,9 +274,6 @@ There are no real life examples showcasing this, it may not even be really neede
the thinking being that it would support any type of rendering of child embeddables - whether in a "snap to grid" style like dashboard,
or in a free form layout like canvas.
-The only real implementation of a container in production code at the time this is written is Dashboard however, with no plans to migrate
-Canvas over to use it (this was the original impetus for an abstraction). The container code is quite complicated with child management,
-so it makes creating a new container very easy, as you can see in the developer examples of containers. But, it's possible this layer was
- an over abstraction without a real prod use case (I can say that because I wrote it, I'm only insulting myself!) :).
+The only real implementation of a container in production code at the time is written in the Dashboard plugin, however, with no plans to migrate over to Canvas (this was the original impetus for an abstraction). The container code is quite complicated with child management, so it makes creating a new container very easy, as you can see in the developer examples of containers. But, it's possible this layer was an over abstraction without a real prod use case (I can say that because I wrote it, I'm only insulting myself!) :).
Be sure to read [Common mistakes with embeddable containers and inherited input state](./containers_and_inherited_state.md) next!
\ No newline at end of file
diff --git a/src/plugins/embeddable/public/lib/embeddables/embeddable_root.test.tsx b/src/plugins/embeddable/public/lib/embeddables/embeddable_root.test.tsx
index badeda5d4aef..486e99b1c281 100644
--- a/src/plugins/embeddable/public/lib/embeddables/embeddable_root.test.tsx
+++ b/src/plugins/embeddable/public/lib/embeddables/embeddable_root.test.tsx
@@ -32,7 +32,7 @@ import React from 'react';
import { HelloWorldEmbeddable } from '../../../../../../examples/embeddable_examples/public';
import { EmbeddableRoot } from './embeddable_root';
import { mount } from 'enzyme';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
test('EmbeddableRoot renders an embeddable', async () => {
const embeddable = new HelloWorldEmbeddable({ id: 'hello' });
diff --git a/src/plugins/embeddable/public/lib/panel/embeddable_panel.test.tsx b/src/plugins/embeddable/public/lib/panel/embeddable_panel.test.tsx
index 072bcd93d32f..4db6b30c9b57 100644
--- a/src/plugins/embeddable/public/lib/panel/embeddable_panel.test.tsx
+++ b/src/plugins/embeddable/public/lib/panel/embeddable_panel.test.tsx
@@ -32,7 +32,7 @@ import React from 'react';
import { mount } from 'enzyme';
import { nextTick } from 'test_utils/enzyme_helpers';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { I18nProvider } from '@osd/i18n/react';
import { CONTEXT_MENU_TRIGGER } from '../triggers';
import { Action, UiActionsStart, ActionType } from '../../../../ui_actions/public';
diff --git a/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.test.tsx b/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.test.tsx
index 232c2ca82d15..ac7d6e7aa082 100644
--- a/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.test.tsx
+++ b/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.test.tsx
@@ -41,7 +41,7 @@ import { ContainerInput } from '../../../../containers';
import { mountWithIntl as mount } from 'test_utils/enzyme_helpers';
import { ReactWrapper } from 'enzyme';
import { coreMock } from '../../../../../../../../core/public/mocks';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { embeddablePluginMock } from '../../../../../mocks';
function DummySavedObjectFinder(props: { children: React.ReactNode }) {
diff --git a/src/plugins/input_control_vis/public/components/editor/controls_tab.test.tsx b/src/plugins/input_control_vis/public/components/editor/controls_tab.test.tsx
index e2355799d72d..06ed4a66606c 100644
--- a/src/plugins/input_control_vis/public/components/editor/controls_tab.test.tsx
+++ b/src/plugins/input_control_vis/public/components/editor/controls_tab.test.tsx
@@ -30,7 +30,7 @@
import React from 'react';
import { shallowWithIntl, mountWithIntl } from 'test_utils/enzyme_helpers';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { getDepsMock, getIndexPatternMock } from '../../test_utils';
import { ControlsTab, ControlsTabUiProps } from './controls_tab';
import { Vis } from '../../../../visualizations/public';
diff --git a/src/plugins/input_control_vis/public/components/editor/list_control_editor.test.tsx b/src/plugins/input_control_vis/public/components/editor/list_control_editor.test.tsx
index d8a36ac9b6c9..6837c14fafd2 100644
--- a/src/plugins/input_control_vis/public/components/editor/list_control_editor.test.tsx
+++ b/src/plugins/input_control_vis/public/components/editor/list_control_editor.test.tsx
@@ -32,7 +32,7 @@ import React from 'react';
import sinon from 'sinon';
import { shallow } from 'enzyme';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { mountWithIntl, shallowWithIntl } from 'test_utils/enzyme_helpers';
import { getIndexPatternMock } from '../../test_utils/get_index_pattern_mock';
diff --git a/src/plugins/input_control_vis/public/components/editor/range_control_editor.test.tsx b/src/plugins/input_control_vis/public/components/editor/range_control_editor.test.tsx
index a8dcc0761f2c..76b1e15a9df7 100644
--- a/src/plugins/input_control_vis/public/components/editor/range_control_editor.test.tsx
+++ b/src/plugins/input_control_vis/public/components/editor/range_control_editor.test.tsx
@@ -33,7 +33,7 @@ import { shallow } from 'enzyme';
import { SinonSpy, spy, assert } from 'sinon';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { RangeControlEditor } from './range_control_editor';
import { ControlParams } from '../../editor_utils';
diff --git a/src/plugins/input_control_vis/public/components/vis/input_control_vis.test.tsx b/src/plugins/input_control_vis/public/components/vis/input_control_vis.test.tsx
index 1e931c084a55..ea1ef17d79f4 100644
--- a/src/plugins/input_control_vis/public/components/vis/input_control_vis.test.tsx
+++ b/src/plugins/input_control_vis/public/components/vis/input_control_vis.test.tsx
@@ -32,7 +32,7 @@ import React from 'react';
import sinon from 'sinon';
import { shallow } from 'enzyme';
import { mountWithIntl } from 'test_utils/enzyme_helpers';
-import { findTestSubject } from '@elastic/eui/lib/test';
+import { findTestSubject } from 'test_utils/helpers';
import { InputControlVis } from './input_control_vis';
import { ListControl } from '../../control/list_control_factory';
diff --git a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/application_usage/schema.ts b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/application_usage/schema.ts
index 2c221aa6a0b5..2e0a76c56cd0 100644
--- a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/application_usage/schema.ts
+++ b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/application_usage/schema.ts
@@ -69,6 +69,5 @@ export const applicationUsageSchema = {
opensearch_dashboards: commonSchema, // It's a forward app so we'll likely never report it
management: commonSchema,
short_url_redirect: commonSchema, // It's a forward app so we'll likely never report it
- timelion: commonSchema,
visualize: commonSchema,
};
diff --git a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/management/schema.ts b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/management/schema.ts
index 45fbc7aaaa87..5be224b85204 100644
--- a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/management/schema.ts
+++ b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/management/schema.ts
@@ -49,11 +49,8 @@ export const stackManagementSchema: MakeSchemaFrom = {
'timelion:max_buckets': { type: 'long' },
'timelion:es.timefield': { type: 'keyword' },
'timelion:min_interval': { type: 'keyword' },
- 'timelion:default_rows': { type: 'long' },
- 'timelion:default_columns': { type: 'long' },
'timelion:quandl.key': { type: 'keyword' },
'timelion:es.default_index': { type: 'keyword' },
- 'timelion:showTutorial': { type: 'boolean' },
'securitySolution:timeDefaults': { type: 'keyword' },
'securitySolution:defaultAnomalyScore': { type: 'long' },
'securitySolution:defaultIndex': { type: 'keyword' }, // it's an array
diff --git a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.test.ts b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.test.ts
index cdfb918a1618..12b8d978fcbe 100644
--- a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.test.ts
+++ b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.test.ts
@@ -41,7 +41,6 @@ describe('getSavedObjectsCounts', () => {
search: { total: 0 },
index_pattern: { total: 0 },
graph_workspace: { total: 0 },
- timelion_sheet: { total: 0 },
});
});
@@ -51,7 +50,6 @@ describe('getSavedObjectsCounts', () => {
types: {
buckets: [
{ key: 'dashboard', doc_count: 1 },
- { key: 'timelion-sheet', doc_count: 2 },
{ key: 'index-pattern', value: 2 }, // Malformed on purpose
{ key: 'graph_workspace', doc_count: 3 }, // already snake_cased
],
@@ -66,7 +64,6 @@ describe('getSavedObjectsCounts', () => {
search: { total: 0 },
index_pattern: { total: 0 },
graph_workspace: { total: 3 },
- timelion_sheet: { total: 2 },
});
});
});
diff --git a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.ts b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.ts
index e987af3bfc3c..040257cb7e78 100644
--- a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.ts
+++ b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/get_saved_object_counts.ts
@@ -40,14 +40,7 @@
import { snakeCase } from 'lodash';
import { LegacyAPICaller } from 'opensearch-dashboards/server';
-const TYPES = [
- 'dashboard',
- 'visualization',
- 'search',
- 'index-pattern',
- 'graph-workspace',
- 'timelion-sheet',
-];
+const TYPES = ['dashboard', 'visualization', 'search', 'index-pattern', 'graph-workspace'];
export interface OpenSearchDashboardsSavedObjectCounts {
dashboard: { total: number };
@@ -55,7 +48,6 @@ export interface OpenSearchDashboardsSavedObjectCounts {
search: { total: number };
index_pattern: { total: number };
graph_workspace: { total: number };
- timelion_sheet: { total: number };
}
export async function getSavedObjectsCounts(
diff --git a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/index.test.ts b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/index.test.ts
index 0e20b1cd8111..105487ee5b08 100644
--- a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/index.test.ts
+++ b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/opensearch_dashboards/index.test.ts
@@ -64,7 +64,6 @@ describe('telemetry_opensearch_dashboards', () => {
search: { total: 0 },
index_pattern: { total: 0 },
graph_workspace: { total: 0 },
- timelion_sheet: { total: 0 },
});
});
@@ -76,7 +75,6 @@ describe('telemetry_opensearch_dashboards', () => {
search: { total: 0 },
index_pattern: { total: 0 },
graph_workspace: { total: 0 },
- timelion_sheet: { total: 0 },
};
expect(collector.formatForBulkUpload!(resultFromFetch)).toStrictEqual({
diff --git a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/ui_metric/schema.ts b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/ui_metric/schema.ts
index e542d08d2056..2c398bc23708 100644
--- a/src/plugins/opensearch_dashboards_usage_collection/server/collectors/ui_metric/schema.ts
+++ b/src/plugins/opensearch_dashboards_usage_collection/server/collectors/ui_metric/schema.ts
@@ -50,7 +50,6 @@ const uiMetricFromDataPluginSchema: MakeSchemaFrom = {
opensearch_dashboards: commonSchema, // It's a forward app so we'll likely never report it
management: commonSchema,
short_url_redirect: commonSchema, // It's a forward app so we'll likely never report it
- timelion: commonSchema,
visualize: commonSchema,
};
diff --git a/src/plugins/telemetry/schema/oss_plugins.json b/src/plugins/telemetry/schema/oss_plugins.json
index 1e25048ed03d..c4ff960b62e6 100644
--- a/src/plugins/telemetry/schema/oss_plugins.json
+++ b/src/plugins/telemetry/schema/oss_plugins.json
@@ -252,34 +252,6 @@
}
}
},
- "timeline": {
- "properties": {
- "clicks_total": {
- "type": "long"
- },
- "clicks_7_days": {
- "type": "long"
- },
- "clicks_30_days": {
- "type": "long"
- },
- "clicks_90_days": {
- "type": "long"
- },
- "minutes_on_screen_total": {
- "type": "float"
- },
- "minutes_on_screen_7_days": {
- "type": "float"
- },
- "minutes_on_screen_30_days": {
- "type": "float"
- },
- "minutes_on_screen_90_days": {
- "type": "float"
- }
- }
- },
"visualize": {
"properties": {
"clicks_total": {
@@ -1342,13 +1314,6 @@
"type": "long"
}
}
- },
- "timeline_sheet": {
- "properties": {
- "total": {
- "type": "long"
- }
- }
}
}
},
@@ -1399,21 +1364,12 @@
"timeline:min_interval": {
"type": "keyword"
},
- "timeline:default_rows": {
- "type": "long"
- },
- "timeline:default_columns": {
- "type": "long"
- },
"timeline:quandl.key": {
"type": "keyword"
},
"timeline:es.default_index": {
"type": "keyword"
},
- "timeline:showTutorial": {
- "type": "boolean"
- },
"securitySolution:timeDefaults": {
"type": "keyword"
},
@@ -1943,19 +1899,6 @@
}
}
},
- "timeline": {
- "type": "array",
- "items": {
- "properties": {
- "key": {
- "type": "keyword"
- },
- "value": {
- "type": "long"
- }
- }
- }
- },
"csm": {
"type": "array",
"items": {
diff --git a/src/plugins/telemetry/server/collectors/usage/telemetry_usage_collector.ts b/src/plugins/telemetry/server/collectors/usage/telemetry_usage_collector.ts
index 7347975dbc4a..e15a1921b734 100644
--- a/src/plugins/telemetry/server/collectors/usage/telemetry_usage_collector.ts
+++ b/src/plugins/telemetry/server/collectors/usage/telemetry_usage_collector.ts
@@ -29,7 +29,7 @@
*/
import { accessSync, constants, readFileSync, statSync } from 'fs';
-import { safeLoad } from 'js-yaml';
+import { load } from 'js-yaml';
import { dirname, join } from 'path';
import { Observable } from 'rxjs';
@@ -78,7 +78,7 @@ export async function readTelemetryFile(
try {
if (isFileReadable(configPath)) {
const yaml = readFileSync(configPath);
- const data = safeLoad(yaml.toString());
+ const data = load(yaml.toString());
// don't bother returning empty objects
if (Object.keys(data).length) {
diff --git a/src/plugins/telemetry_management_section/public/components/opt_in_example_flyout.tsx b/src/plugins/telemetry_management_section/public/components/opt_in_example_flyout.tsx
index 56b0fd1e7ee0..d00e5d351c4d 100644
--- a/src/plugins/telemetry_management_section/public/components/opt_in_example_flyout.tsx
+++ b/src/plugins/telemetry_management_section/public/components/opt_in_example_flyout.tsx
@@ -62,6 +62,7 @@ interface State {
* React component for displaying the example data associated with the Telemetry opt-in banner.
*/
export class OptInExampleFlyout extends React.PureComponent {
+ private _isMounted: boolean = false;
public readonly state: State = {
data: null,
isLoading: true,
@@ -69,15 +70,21 @@ export class OptInExampleFlyout extends React.PureComponent {
};
async componentDidMount() {
+ this._isMounted = true;
try {
const { fetchExample } = this.props;
const clusters = await fetchExample();
+
+ if (!this._isMounted) return;
+
this.setState({
data: Array.isArray(clusters) ? clusters : null,
isLoading: false,
hasPrivilegeToRead: true,
});
} catch (err) {
+ if (!this._isMounted) return;
+
this.setState({
isLoading: false,
hasPrivilegeToRead: err.status !== 403,
@@ -85,6 +92,10 @@ export class OptInExampleFlyout extends React.PureComponent {
}
}
+ componentWillUnmount() {
+ this._isMounted = false;
+ }
+
renderBody({ data, isLoading, hasPrivilegeToRead }: State) {
if (isLoading) {
return (
diff --git a/src/plugins/tile_map/public/_tile_map.scss b/src/plugins/tile_map/public/_tile_map.scss
deleted file mode 100644
index 5e4b20f79fed..000000000000
--- a/src/plugins/tile_map/public/_tile_map.scss
+++ /dev/null
@@ -1,15 +0,0 @@
-// SASSTODO: Does this selector exist today?
-.tilemap {
- margin-bottom: 6px;
- border: $euiBorderThin;
- position: relative;
-}
-
-/**
-* 1. Visualizations have some padding by default but tilemaps look nice flush against the edge to maximize viewing
-* space.
-*/
-// SASSTODO: Does this selector exist today?
-.tile_map {
- padding: 0; /* 1. */
-}
diff --git a/src/plugins/tile_map/public/index.scss b/src/plugins/tile_map/public/index.scss
deleted file mode 100644
index aa2117cb0c01..000000000000
--- a/src/plugins/tile_map/public/index.scss
+++ /dev/null
@@ -1,8 +0,0 @@
-// Prefix all styles with "tlm" to avoid conflicts.
-// Examples
-// tlmChart
-// tlmChart__legend
-// tlmChart__legend--small
-// tlmChart__legend-isLoading
-
-@import "tile_map";
diff --git a/src/plugins/timeline/README.md b/src/plugins/timeline/README.md
deleted file mode 100644
index 22ed15ebf5c6..000000000000
--- a/src/plugins/timeline/README.md
+++ /dev/null
@@ -1,2 +0,0 @@
-Contains the deprecated timeline application. For the timeline visualization,
-which also contains the timeline APIs and backend, look at the vis_type_timeline plugin.
diff --git a/src/plugins/timeline/opensearch_dashboards.json b/src/plugins/timeline/opensearch_dashboards.json
deleted file mode 100644
index 73cfbd3ee086..000000000000
--- a/src/plugins/timeline/opensearch_dashboards.json
+++ /dev/null
@@ -1,19 +0,0 @@
-{
- "id": "timeline",
- "version": "opensearchDashboards",
- "ui": true,
- "server": true,
- "requiredBundles": [
- "opensearchDashboardsLegacy",
- "opensearchDashboardsUtils",
- "savedObjects",
- "visTypeTimeline"
- ],
- "requiredPlugins": [
- "visualizations",
- "data",
- "navigation",
- "visTypeTimeline",
- "opensearchDashboardsLegacy"
- ]
-}
diff --git a/src/plugins/timeline/public/_app.scss b/src/plugins/timeline/public/_app.scss
deleted file mode 100644
index 8b9078caba5a..000000000000
--- a/src/plugins/timeline/public/_app.scss
+++ /dev/null
@@ -1,21 +0,0 @@
-.timApp {
- position: relative;
- background: $euiColorEmptyShade;
-
- [ng-click] {
- cursor: pointer;
- }
-}
-
-.timApp__container {
- margin: $euiSizeM;
-}
-
-.timApp__menus {
- margin: $euiSizeM;
-}
-
-.timApp__stats {
- font-weight: $euiFontWeightRegular;
- color: $euiColorMediumShade;
-}
diff --git a/src/plugins/timeline/public/_base.scss b/src/plugins/timeline/public/_base.scss
deleted file mode 100644
index 4e64d237271a..000000000000
--- a/src/plugins/timeline/public/_base.scss
+++ /dev/null
@@ -1,18 +0,0 @@
-// Angular form states
-.ng-invalid {
- &.ng-dirty,
- &.ng-touched {
- border-color: $euiColorDanger;
- }
-}
-
-input[type="radio"],
-input[type="checkbox"],
-.radio,
-.checkbox {
- &[disabled],
- fieldset[disabled] & {
- cursor: default;
- opacity: 0.8;
- }
-}
diff --git a/src/plugins/timeline/public/app.js b/src/plugins/timeline/public/app.js
deleted file mode 100644
index d0e940b9dded..000000000000
--- a/src/plugins/timeline/public/app.js
+++ /dev/null
@@ -1,678 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import _ from 'lodash';
-
-import { i18n } from '@osd/i18n';
-
-import { createHashHistory } from 'history';
-
-import {
- createOsdUrlStateStorage,
- withNotifyOnErrors,
-} from '../../opensearch_dashboards_utils/public';
-import { syncQueryStateWithUrl } from '../../data/public';
-
-import { getSavedSheetBreadcrumbs, getCreateBreadcrumbs } from './breadcrumbs';
-import {
- addFatalError,
- registerListenEventListener,
- watchMultiDecorator,
-} from '../../opensearch_dashboards_legacy/public';
-import { getTimezone } from '../../vis_type_timeline/public';
-import { initCellsDirective } from './directives/cells/cells';
-import { initFullscreenDirective } from './directives/fullscreen/fullscreen';
-import { initFixedElementDirective } from './directives/fixed_element';
-import { initTimelineLoadSheetDirective } from './directives/timeline_load_sheet';
-import { initTimelineHelpDirective } from './directives/timeline_help/timeline_help';
-import { initTimelineSaveSheetDirective } from './directives/timeline_save_sheet';
-import { initTimelineOptionsSheetDirective } from './directives/timeline_options_sheet';
-import { initSavedObjectSaveAsCheckBoxDirective } from './directives/saved_object_save_as_checkbox';
-import { initSavedObjectFinderDirective } from './directives/saved_object_finder';
-import { initTimelineTabsDirective } from './components/timelinehelp_tabs_directive';
-import { initTimelineTDeprecationDirective } from './components/timeline_deprecation_directive';
-import { initInputFocusDirective } from './directives/input_focus';
-import { Chart } from './directives/chart/chart';
-import { TimelineInterval } from './directives/timeline_interval/timeline_interval';
-import { timelineExpInput } from './directives/timeline_expression_input';
-import { TimelineExpressionSuggestions } from './directives/timeline_expression_suggestions/timeline_expression_suggestions';
-import { initSavedSheetService } from './services/saved_sheets';
-import { initTimelineAppState } from './timeline_app_state';
-
-import rootTemplate from './index.html';
-
-export function initTimelineApp(app, deps) {
- app.run(registerListenEventListener);
-
- const savedSheetLoader = initSavedSheetService(app, deps);
-
- app.factory('history', () => createHashHistory());
- app.factory('osdUrlStateStorage', (history) =>
- createOsdUrlStateStorage({
- history,
- useHash: deps.core.uiSettings.get('state:storeInSessionStorage'),
- ...withNotifyOnErrors(deps.core.notifications.toasts),
- })
- );
- app.config(watchMultiDecorator);
-
- app
- .controller('TimelineVisController', function ($scope) {
- $scope.$on('timelineChartRendered', (event) => {
- event.stopPropagation();
- $scope.renderComplete();
- });
- })
- .constant('timelinePanels', deps.timelinePanels)
- .directive('chart', Chart)
- .directive('timelineInterval', TimelineInterval)
- .directive('timelineExpressionSuggestions', TimelineExpressionSuggestions)
- .directive('timelineExpressionInput', timelineExpInput(deps));
-
- initTimelineHelpDirective(app);
- initInputFocusDirective(app);
- initTimelineTabsDirective(app, deps);
- initTimelineTDeprecationDirective(app, deps);
- initSavedObjectFinderDirective(app, savedSheetLoader, deps.core.uiSettings);
- initSavedObjectSaveAsCheckBoxDirective(app);
- initCellsDirective(app);
- initFixedElementDirective(app);
- initFullscreenDirective(app);
- initTimelineSaveSheetDirective(app);
- initTimelineLoadSheetDirective(app);
- initTimelineOptionsSheetDirective(app);
-
- const location = 'Timeline';
-
- app.directive('timelineApp', function () {
- return {
- restrict: 'E',
- controllerAs: 'timelineApp',
- controller: timelineController,
- };
- });
-
- function timelineController(
- $http,
- $route,
- $routeParams,
- $scope,
- $timeout,
- history,
- osdUrlStateStorage
- ) {
- // Keeping this at app scope allows us to keep the current page when the user
- // switches to say, the timepicker.
- $scope.page = deps.core.uiSettings.get('timeline:showTutorial', true) ? 1 : 0;
- $scope.setPage = (page) => ($scope.page = page);
- const timefilter = deps.plugins.data.query.timefilter.timefilter;
-
- timefilter.enableAutoRefreshSelector();
- timefilter.enableTimeRangeSelector();
-
- deps.core.chrome.docTitle.change('Timeline - OpenSearch Dashboards');
-
- // starts syncing `_g` portion of url with query services
- const { stop: stopSyncingQueryServiceStateWithUrl } = syncQueryStateWithUrl(
- deps.plugins.data.query,
- osdUrlStateStorage
- );
-
- const savedSheet = $route.current.locals.savedSheet;
-
- function getStateDefaults() {
- return {
- sheet: savedSheet.timelion_sheet,
- selected: 0,
- columns: savedSheet.timelion_columns,
- rows: savedSheet.timelion_rows,
- interval: savedSheet.timelion_interval,
- };
- }
-
- const { stateContainer, stopStateSync } = initTimelineAppState({
- stateDefaults: getStateDefaults(),
- osdUrlStateStorage,
- });
-
- $scope.state = _.cloneDeep(stateContainer.getState());
- $scope.expression = _.clone($scope.state.sheet[$scope.state.selected]);
- $scope.updatedSheets = [];
-
- const savedVisualizations = deps.plugins.visualizations.savedVisualizationsLoader;
- const timezone = getTimezone(deps.core.uiSettings);
-
- const defaultExpression = '.opensearch(*)';
-
- $scope.topNavMenu = getTopNavMenu();
-
- $timeout(function () {
- if (deps.core.uiSettings.get('timeline:showTutorial', true)) {
- $scope.toggleMenu('showHelp');
- }
- }, 0);
-
- $scope.transient = {};
-
- function getTopNavMenu() {
- const newSheetAction = {
- id: 'new',
- label: i18n.translate('timeline.topNavMenu.newSheetButtonLabel', {
- defaultMessage: 'New',
- }),
- description: i18n.translate('timeline.topNavMenu.newSheetButtonAriaLabel', {
- defaultMessage: 'New Sheet',
- }),
- run: function () {
- history.push('/');
- $route.reload();
- },
- testId: 'timelineNewButton',
- };
-
- const addSheetAction = {
- id: 'add',
- label: i18n.translate('timeline.topNavMenu.addChartButtonLabel', {
- defaultMessage: 'Add',
- }),
- description: i18n.translate('timeline.topNavMenu.addChartButtonAriaLabel', {
- defaultMessage: 'Add a chart',
- }),
- run: function () {
- $scope.$evalAsync(() => $scope.newCell());
- },
- testId: 'timelineAddChartButton',
- };
-
- const saveSheetAction = {
- id: 'save',
- label: i18n.translate('timeline.topNavMenu.saveSheetButtonLabel', {
- defaultMessage: 'Save',
- }),
- description: i18n.translate('timeline.topNavMenu.saveSheetButtonAriaLabel', {
- defaultMessage: 'Save Sheet',
- }),
- run: () => {
- $scope.$evalAsync(() => $scope.toggleMenu('showSave'));
- },
- testId: 'timelineSaveButton',
- };
-
- const deleteSheetAction = {
- id: 'delete',
- label: i18n.translate('timeline.topNavMenu.deleteSheetButtonLabel', {
- defaultMessage: 'Delete',
- }),
- description: i18n.translate('timeline.topNavMenu.deleteSheetButtonAriaLabel', {
- defaultMessage: 'Delete current sheet',
- }),
- disableButton: function () {
- return !savedSheet.id;
- },
- run: function () {
- const title = savedSheet.title;
- function doDelete() {
- savedSheet
- .delete()
- .then(() => {
- deps.core.notifications.toasts.addSuccess(
- i18n.translate('timeline.topNavMenu.delete.modal.successNotificationText', {
- defaultMessage: `Deleted '{title}'`,
- values: { title },
- })
- );
- history.push('/');
- })
- .catch((error) => addFatalError(deps.core.fatalErrors, error, location));
- }
-
- const confirmModalOptions = {
- confirmButtonText: i18n.translate(
- 'timeline.topNavMenu.delete.modal.confirmButtonLabel',
- {
- defaultMessage: 'Delete',
- }
- ),
- title: i18n.translate('timeline.topNavMenu.delete.modalTitle', {
- defaultMessage: `Delete Timeline sheet '{title}'?`,
- values: { title },
- }),
- };
-
- $scope.$evalAsync(() => {
- deps.core.overlays
- .openConfirm(
- i18n.translate('timeline.topNavMenu.delete.modal.warningText', {
- defaultMessage: `You can't recover deleted sheets.`,
- }),
- confirmModalOptions
- )
- .then((isConfirmed) => {
- if (isConfirmed) {
- doDelete();
- }
- });
- });
- },
- testId: 'timelineDeleteButton',
- };
-
- const openSheetAction = {
- id: 'open',
- label: i18n.translate('timeline.topNavMenu.openSheetButtonLabel', {
- defaultMessage: 'Open',
- }),
- description: i18n.translate('timeline.topNavMenu.openSheetButtonAriaLabel', {
- defaultMessage: 'Open Sheet',
- }),
- run: () => {
- $scope.$evalAsync(() => $scope.toggleMenu('showLoad'));
- },
- testId: 'timelineOpenButton',
- };
-
- const optionsAction = {
- id: 'options',
- label: i18n.translate('timeline.topNavMenu.optionsButtonLabel', {
- defaultMessage: 'Options',
- }),
- description: i18n.translate('timeline.topNavMenu.optionsButtonAriaLabel', {
- defaultMessage: 'Options',
- }),
- run: () => {
- $scope.$evalAsync(() => $scope.toggleMenu('showOptions'));
- },
- testId: 'timelineOptionsButton',
- };
-
- const helpAction = {
- id: 'help',
- label: i18n.translate('timeline.topNavMenu.helpButtonLabel', {
- defaultMessage: 'Help',
- }),
- description: i18n.translate('timeline.topNavMenu.helpButtonAriaLabel', {
- defaultMessage: 'Help',
- }),
- run: () => {
- $scope.$evalAsync(() => $scope.toggleMenu('showHelp'));
- },
- testId: 'timelineDocsButton',
- };
-
- if (deps.core.application.capabilities.timelion.save) {
- return [
- newSheetAction,
- addSheetAction,
- saveSheetAction,
- deleteSheetAction,
- openSheetAction,
- optionsAction,
- helpAction,
- ];
- }
- return [newSheetAction, addSheetAction, openSheetAction, optionsAction, helpAction];
- }
-
- let refresher;
- const setRefreshData = function () {
- if (refresher) $timeout.cancel(refresher);
- const interval = timefilter.getRefreshInterval();
- if (interval.value > 0 && !interval.pause) {
- function startRefresh() {
- refresher = $timeout(function () {
- if (!$scope.running) $scope.search();
- startRefresh();
- }, interval.value);
- }
- startRefresh();
- }
- };
-
- const init = function () {
- $scope.running = false;
- $scope.search();
- setRefreshData();
-
- $scope.model = {
- timeRange: timefilter.getTime(),
- refreshInterval: timefilter.getRefreshInterval(),
- };
-
- const unsubscribeStateUpdates = stateContainer.subscribe((state) => {
- const clonedState = _.cloneDeep(state);
- $scope.updatedSheets.forEach((updatedSheet) => {
- clonedState.sheet[updatedSheet.id] = updatedSheet.expression;
- });
- $scope.state = clonedState;
- $scope.opts.state = clonedState;
- $scope.expression = _.clone($scope.state.sheet[$scope.state.selected]);
- $scope.search();
- });
-
- timefilter.getFetch$().subscribe($scope.search);
-
- $scope.opts = {
- saveExpression: saveExpression,
- saveSheet: saveSheet,
- savedSheet: savedSheet,
- state: _.cloneDeep(stateContainer.getState()),
- search: $scope.search,
- dontShowHelp: function () {
- deps.core.uiSettings.set('timeline:showTutorial', false);
- $scope.setPage(0);
- $scope.closeMenus();
- },
- };
-
- $scope.$watch('opts.state.rows', function (newRow) {
- const state = stateContainer.getState();
- if (state.rows !== newRow) {
- stateContainer.transitions.set('rows', newRow);
- }
- });
-
- $scope.$watch('opts.state.columns', function (newColumn) {
- const state = stateContainer.getState();
- if (state.columns !== newColumn) {
- stateContainer.transitions.set('columns', newColumn);
- }
- });
-
- $scope.menus = {
- showHelp: false,
- showSave: false,
- showLoad: false,
- showOptions: false,
- };
-
- $scope.toggleMenu = (menuName) => {
- const curState = $scope.menus[menuName];
- $scope.closeMenus();
- $scope.menus[menuName] = !curState;
- };
-
- $scope.closeMenus = () => {
- _.forOwn($scope.menus, function (value, key) {
- $scope.menus[key] = false;
- });
- };
-
- $scope.$on('$destroy', () => {
- stopSyncingQueryServiceStateWithUrl();
- unsubscribeStateUpdates();
- stopStateSync();
- });
- };
-
- $scope.onTimeUpdate = function ({ dateRange }) {
- $scope.model.timeRange = {
- ...dateRange,
- };
- timefilter.setTime(dateRange);
- if (!$scope.running) $scope.search();
- };
-
- $scope.onRefreshChange = function ({ isPaused, refreshInterval }) {
- $scope.model.refreshInterval = {
- pause: isPaused,
- value: refreshInterval,
- };
- timefilter.setRefreshInterval({
- pause: isPaused,
- value: refreshInterval ? refreshInterval : $scope.refreshInterval.value,
- });
-
- setRefreshData();
- };
-
- $scope.$watch(
- function () {
- return savedSheet.lastSavedTitle;
- },
- function (newTitle) {
- if (savedSheet.id && newTitle) {
- deps.core.chrome.docTitle.change(newTitle);
- }
- }
- );
-
- $scope.$watch('expression', function (newExpression) {
- const state = stateContainer.getState();
- if (state.sheet[state.selected] !== newExpression) {
- const updatedSheet = $scope.updatedSheets.find(
- (updatedSheet) => updatedSheet.id === state.selected
- );
- if (updatedSheet) {
- updatedSheet.expression = newExpression;
- } else {
- $scope.updatedSheets.push({
- id: state.selected,
- expression: newExpression,
- });
- }
- }
- });
-
- $scope.toggle = function (property) {
- $scope[property] = !$scope[property];
- };
-
- $scope.changeInterval = function (interval) {
- $scope.currentInterval = interval;
- };
-
- $scope.updateChart = function () {
- const state = stateContainer.getState();
- const newSheet = _.clone(state.sheet);
- if ($scope.updatedSheets.length) {
- $scope.updatedSheets.forEach((updatedSheet) => {
- newSheet[updatedSheet.id] = updatedSheet.expression;
- });
- $scope.updatedSheets = [];
- }
- stateContainer.transitions.updateState({
- interval: $scope.currentInterval ? $scope.currentInterval : state.interval,
- sheet: newSheet,
- });
- };
-
- $scope.newSheet = function () {
- history.push('/');
- };
-
- $scope.removeSheet = function (removedIndex) {
- const state = stateContainer.getState();
- const newSheet = state.sheet.filter((el, index) => index !== removedIndex);
- $scope.updatedSheets = $scope.updatedSheets.filter((el) => el.id !== removedIndex);
- stateContainer.transitions.updateState({
- sheet: newSheet,
- selected: removedIndex ? removedIndex - 1 : removedIndex,
- });
- };
-
- $scope.newCell = function () {
- const state = stateContainer.getState();
- const newSheet = [...state.sheet, defaultExpression];
- stateContainer.transitions.updateState({ sheet: newSheet, selected: newSheet.length - 1 });
- };
-
- $scope.setActiveCell = function (cell) {
- const state = stateContainer.getState();
- if (state.selected !== cell) {
- stateContainer.transitions.updateState({ sheet: $scope.state.sheet, selected: cell });
- }
- };
-
- $scope.search = function () {
- $scope.running = true;
- const state = stateContainer.getState();
-
- // parse the time range client side to make sure it behaves like other charts
- const timeRangeBounds = timefilter.getBounds();
-
- const httpResult = $http
- .post('../api/timeline/run', {
- sheet: state.sheet,
- time: _.assignIn(
- {
- from: timeRangeBounds.min,
- to: timeRangeBounds.max,
- },
- {
- interval: state.interval,
- timezone: timezone,
- }
- ),
- })
- .then((resp) => resp.data)
- .catch((resp) => {
- throw resp.data;
- });
-
- httpResult
- .then(function (resp) {
- $scope.stats = resp.stats;
- $scope.sheet = resp.sheet;
- _.forEach(resp.sheet, function (cell) {
- if (cell.exception && cell.plot !== state.selected) {
- stateContainer.transitions.set('selected', cell.plot);
- }
- });
- $scope.running = false;
- })
- .catch(function (resp) {
- $scope.sheet = [];
- $scope.running = false;
-
- const err = new Error(resp.message);
- err.stack = resp.stack;
- deps.core.notifications.toasts.addError(err, {
- title: i18n.translate('timeline.searchErrorTitle', {
- defaultMessage: 'Timeline request error',
- }),
- });
- });
- };
-
- $scope.safeSearch = _.debounce($scope.search, 500);
-
- function saveSheet() {
- const state = stateContainer.getState();
- savedSheet.timeline_sheet = state.sheet;
- savedSheet.timeline_interval = state.interval;
- savedSheet.timeline_columns = state.columns;
- savedSheet.timeline_rows = state.rows;
- savedSheet.save().then(function (id) {
- if (id) {
- deps.core.notifications.toasts.addSuccess({
- title: i18n.translate('timeline.saveSheet.successNotificationText', {
- defaultMessage: `Saved sheet '{title}'`,
- values: { title: savedSheet.title },
- }),
- 'data-test-subj': 'timelineSaveSuccessToast',
- });
-
- if (savedSheet.id !== $routeParams.id) {
- history.push(`/${savedSheet.id}`);
- }
- }
- });
- }
-
- async function saveExpression(title) {
- const vis = await deps.plugins.visualizations.createVis('timelion', {
- title,
- params: {
- expression: $scope.state.sheet[$scope.state.selected],
- interval: $scope.state.interval,
- },
- });
- const state = deps.plugins.visualizations.convertFromSerializedVis(vis.serialize());
- const visSavedObject = await savedVisualizations.get();
- Object.assign(visSavedObject, state);
- const id = await visSavedObject.save();
- if (id) {
- deps.core.notifications.toasts.addSuccess(
- i18n.translate('timeline.saveExpression.successNotificationText', {
- defaultMessage: `Saved expression '{title}'`,
- values: { title: state.title },
- })
- );
- }
- }
-
- init();
- }
-
- app.config(function ($routeProvider) {
- $routeProvider
- .when('/:id?', {
- template: rootTemplate,
- reloadOnSearch: false,
- k7Breadcrumbs: ($injector, $route) =>
- $injector.invoke(
- $route.current.params.id ? getSavedSheetBreadcrumbs : getCreateBreadcrumbs
- ),
- badge: () => {
- if (deps.core.application.capabilities.timelion.save) {
- return undefined;
- }
-
- return {
- text: i18n.translate('timeline.badge.readOnly.text', {
- defaultMessage: 'Read only',
- }),
- tooltip: i18n.translate('timeline.badge.readOnly.tooltip', {
- defaultMessage: 'Unable to save Timeline sheets',
- }),
- iconType: 'glasses',
- };
- },
- resolve: {
- savedSheet: function (savedSheets, $route) {
- return savedSheets
- .get($route.current.params.id)
- .then((savedSheet) => {
- if ($route.current.params.id) {
- deps.core.chrome.recentlyAccessed.add(
- savedSheet.getFullPath(),
- savedSheet.title,
- savedSheet.id
- );
- }
- return savedSheet;
- })
- .catch();
- },
- },
- })
- .otherwise('/');
- });
-}
diff --git a/src/plugins/timeline/public/application.ts b/src/plugins/timeline/public/application.ts
deleted file mode 100644
index 5eb5d2fcb31c..000000000000
--- a/src/plugins/timeline/public/application.ts
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import './index.scss';
-
-import { EuiIcon } from '@elastic/eui';
-import angular, { IModule } from 'angular';
-// required for `ngSanitize` angular module
-import 'angular-sanitize';
-// required for ngRoute
-import 'angular-route';
-import 'angular-sortable-view';
-import { i18nDirective, i18nFilter, I18nProvider } from '@osd/i18n/angular';
-import {
- IUiSettingsClient,
- CoreStart,
- PluginInitializerContext,
- AppMountParameters,
-} from 'opensearch-dashboards/public';
-import { getTimeChart } from './panels/timechart/timechart';
-import { Panel } from './panels/panel';
-
-import {
- configureAppAngularModule,
- createTopNavDirective,
- createTopNavHelper,
-} from '../../opensearch_dashboards_legacy/public';
-import { TimelinePluginDependencies } from './plugin';
-import { DataPublicPluginStart } from '../../data/public';
-// @ts-ignore
-import { initTimelineApp } from './app';
-
-export interface RenderDeps {
- pluginInitializerContext: PluginInitializerContext;
- mountParams: AppMountParameters;
- core: CoreStart;
- plugins: TimelinePluginDependencies;
- timelinePanels: Map;
-}
-
-export interface TimelineVisualizationDependencies {
- uiSettings: IUiSettingsClient;
- timelinePanels: Map;
- data: DataPublicPluginStart;
- $rootScope: any;
- $compile: any;
-}
-
-let angularModuleInstance: IModule | null = null;
-
-export const renderApp = (deps: RenderDeps) => {
- if (!angularModuleInstance) {
- angularModuleInstance = createLocalAngularModule(deps);
- // global routing stuff
- configureAppAngularModule(
- angularModuleInstance,
- { core: deps.core, env: deps.pluginInitializerContext.env },
- true
- );
- initTimelineApp(angularModuleInstance, deps);
- }
-
- const $injector = mountTimelineApp(deps.mountParams.appBasePath, deps.mountParams.element, deps);
-
- return () => {
- $injector.get('$rootScope').$destroy();
- };
-};
-
-function registerPanels(dependencies: TimelineVisualizationDependencies) {
- const timeChartPanel: Panel = getTimeChart(dependencies);
-
- dependencies.timelinePanels.set(timeChartPanel.name, timeChartPanel);
-}
-
-const mainTemplate = (basePath: string) => `
-
-
`;
-
-const moduleName = 'app/timeline';
-
-const thirdPartyAngularDependencies = ['ngSanitize', 'ngRoute', 'react', 'angular-sortable-view'];
-
-function mountTimelineApp(appBasePath: string, element: HTMLElement, deps: RenderDeps) {
- const mountpoint = document.createElement('div');
- mountpoint.setAttribute('class', 'timelineAppContainer');
- // eslint-disable-next-line no-unsanitized/property
- mountpoint.innerHTML = mainTemplate(appBasePath);
- // bootstrap angular into detached element and attach it later to
- // make angular-within-angular possible
- const $injector = angular.bootstrap(mountpoint, [moduleName]);
-
- registerPanels({
- uiSettings: deps.core.uiSettings,
- timelinePanels: deps.timelinePanels,
- data: deps.plugins.data,
- $rootScope: $injector.get('$rootScope'),
- $compile: $injector.get('$compile'),
- });
- element.appendChild(mountpoint);
- return $injector;
-}
-
-function createLocalAngularModule(deps: RenderDeps) {
- createLocalI18nModule();
- createLocalIconModule();
- createLocalTopNavModule(deps.plugins.navigation);
-
- const dashboardAngularModule = angular.module(moduleName, [
- ...thirdPartyAngularDependencies,
- 'app/timeline/TopNav',
- 'app/timeline/I18n',
- 'app/timeline/icon',
- ]);
- return dashboardAngularModule;
-}
-
-function createLocalIconModule() {
- angular
- .module('app/timeline/icon', ['react'])
- .directive('icon', (reactDirective) => reactDirective(EuiIcon));
-}
-
-function createLocalTopNavModule(navigation: TimelinePluginDependencies['navigation']) {
- angular
- .module('app/timeline/TopNav', ['react'])
- .directive('osdTopNav', createTopNavDirective)
- .directive('osdTopNavHelper', createTopNavHelper(navigation.ui));
-}
-
-function createLocalI18nModule() {
- angular
- .module('app/timeline/I18n', [])
- .provider('i18n', I18nProvider)
- .filter('i18n', i18nFilter)
- .directive('i18nId', i18nDirective);
-}
diff --git a/src/plugins/timeline/public/breadcrumbs.js b/src/plugins/timeline/public/breadcrumbs.js
deleted file mode 100644
index dfee1407cef3..000000000000
--- a/src/plugins/timeline/public/breadcrumbs.js
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { i18n } from '@osd/i18n';
-
-const ROOT_BREADCRUMB = {
- text: i18n.translate('timeline.breadcrumbs.root', {
- defaultMessage: 'Timeline',
- }),
- href: '#',
-};
-
-export function getCreateBreadcrumbs() {
- return [
- ROOT_BREADCRUMB,
- {
- text: i18n.translate('timeline.breadcrumbs.create', {
- defaultMessage: 'Create',
- }),
- },
- ];
-}
-
-export function getSavedSheetBreadcrumbs($route) {
- const { savedSheet } = $route.current.locals;
- return [
- ROOT_BREADCRUMB,
- {
- text: savedSheet.title,
- },
- ];
-}
diff --git a/src/plugins/timeline/public/components/timeline_deprecation.tsx b/src/plugins/timeline/public/components/timeline_deprecation.tsx
deleted file mode 100644
index e97e325b22f8..000000000000
--- a/src/plugins/timeline/public/components/timeline_deprecation.tsx
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { FormattedMessage } from '@osd/i18n/react';
-import { EuiSpacer, EuiCallOut, EuiLink } from '@elastic/eui';
-import React from 'react';
-import { DocLinksStart } from '../../../../core/public';
-
-export const TimelineDeprecation = ({ links }: DocLinksStart) => {
- const timelineDeprecationLink = links.opensearchDashboards.visualize.timelineDeprecation;
- return (
- <>
-
-
-
- ),
- }}
- />
- }
- color="warning"
- iconType="alert"
- size="s"
- />
-
- >
- );
-};
diff --git a/src/plugins/timeline/public/components/timeline_deprecation_directive.js b/src/plugins/timeline/public/components/timeline_deprecation_directive.js
deleted file mode 100644
index d45800db24b5..000000000000
--- a/src/plugins/timeline/public/components/timeline_deprecation_directive.js
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import React from 'react';
-import { TimelineDeprecation } from './timeline_deprecation';
-
-export function initTimelineTDeprecationDirective(app, deps) {
- app.directive('timelineDeprecation', function (reactDirective) {
- return reactDirective(
- () => {
- return (
-
-
-
- );
- },
- [],
- {
- restrict: 'E',
- scope: {
- docLinks: '=',
- },
- }
- );
- });
-}
diff --git a/src/plugins/timeline/public/components/timelinehelp_tabs.js b/src/plugins/timeline/public/components/timelinehelp_tabs.js
deleted file mode 100644
index 1680b4de7ebc..000000000000
--- a/src/plugins/timeline/public/components/timelinehelp_tabs.js
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import PropTypes from 'prop-types';
-import React from 'react';
-
-import { EuiTabs, EuiTab } from '@elastic/eui';
-
-import { FormattedMessage } from '@osd/i18n/react';
-
-function handleClick(activateTab, tabName) {
- activateTab(tabName);
-}
-
-export function TimelineHelpTabs(props) {
- return (
-
- handleClick(props.activateTab, 'funcref')}
- >
-
-
- handleClick(props.activateTab, 'keyboardtips')}
- >
-
-
-
- );
-}
-
-TimelineHelpTabs.propTypes = {
- activeTab: PropTypes.string,
- activateTab: PropTypes.func,
-};
diff --git a/src/plugins/timeline/public/components/timelinehelp_tabs_directive.js b/src/plugins/timeline/public/components/timelinehelp_tabs_directive.js
deleted file mode 100644
index 772580e71bf6..000000000000
--- a/src/plugins/timeline/public/components/timelinehelp_tabs_directive.js
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import React from 'react';
-import { TimelineHelpTabs } from './timelinehelp_tabs';
-
-export function initTimelineTabsDirective(app, deps) {
- app.directive('timelineHelpTabs', function (reactDirective) {
- return reactDirective(
- (props) => {
- return (
-
-
-
- );
- },
- [['activeTab'], ['activateTab', { watchDepth: 'reference' }]],
- {
- restrict: 'E',
- scope: {
- activeTab: '=',
- activateTab: '=',
- },
- }
- );
- });
-}
diff --git a/src/plugins/timeline/public/directives/_form.scss b/src/plugins/timeline/public/directives/_form.scss
deleted file mode 100644
index 2b946ec94791..000000000000
--- a/src/plugins/timeline/public/directives/_form.scss
+++ /dev/null
@@ -1,36 +0,0 @@
-.form-control {
- @include euiFontSizeS;
-
- display: block;
- width: 100%;
- height: $euiFormControlCompressedHeight;
- padding: $euiSizeXS $euiSizeM;
- border: $euiBorderThin;
- background-color: $euiFormBackgroundColor;
- color: $euiTextColor;
- border-radius: $euiBorderRadius;
- cursor: pointer;
-
- &:not([type="range"]) {
- appearance: none;
- }
-
- &:focus {
- border-color: $euiColorPrimary;
- outline: none;
- box-shadow: none;
- }
-}
-
-select.form-control {
- // Makes the select arrow similar to EUI's arrowDown icon
- background-image: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16"%3E%3Cpath fill="#{hexToRGB($euiTextColor)}" d="M13.0688508,5.15725038 L8.38423975,9.76827428 C8.17054415,9.97861308 7.82999214,9.97914095 7.61576025,9.76827428 L2.93114915,5.15725038 C2.7181359,4.94758321 2.37277319,4.94758321 2.15975994,5.15725038 C1.94674669,5.36691756 1.94674669,5.70685522 2.15975994,5.9165224 L6.84437104,10.5275463 C7.48517424,11.1582836 8.51644979,11.1566851 9.15562896,10.5275463 L13.8402401,5.9165224 C14.0532533,5.70685522 14.0532533,5.36691756 13.8402401,5.15725038 C13.6272268,4.94758321 13.2818641,4.94758321 13.0688508,5.15725038 Z"/%3E%3C/svg%3E');
- background-size: $euiSize;
- background-repeat: no-repeat;
- background-position: calc(100% - #{$euiSizeS});
- padding-right: $euiSizeXL;
-}
-
-.fullWidth {
- width: 100%;
-}
diff --git a/src/plugins/timeline/public/directives/_index.scss b/src/plugins/timeline/public/directives/_index.scss
deleted file mode 100644
index 94f0b2286101..000000000000
--- a/src/plugins/timeline/public/directives/_index.scss
+++ /dev/null
@@ -1,7 +0,0 @@
-@import "./timeline_expression_input";
-@import "./cells/index";
-@import "./timeline_expression_suggestions/index";
-@import "./timeline_help/index";
-@import "./timeline_interval/index";
-@import "./saved_object_finder";
-@import "./form";
diff --git a/src/plugins/timeline/public/directives/_saved_object_finder.scss b/src/plugins/timeline/public/directives/_saved_object_finder.scss
deleted file mode 100644
index a225f357949e..000000000000
--- a/src/plugins/timeline/public/directives/_saved_object_finder.scss
+++ /dev/null
@@ -1,95 +0,0 @@
-.list-group-menu {
- &.select-mode a {
- outline: none;
- color: tintOrShade($euiColorPrimary, 10%, 10%);
- }
-
- .list-group-menu-item {
- list-style: none;
- color: tintOrShade($euiColorPrimary, 10%, 10%);
-
- &.active {
- font-weight: bold;
- background-color: $euiColorLightShade;
- }
-
- &:hover {
- background-color: tintOrShade($euiColorPrimary, 90%, 90%);
- }
-
- li {
- list-style: none;
- color: tintOrShade($euiColorPrimary, 10%, 10%);
- }
- }
-}
-
-saved-object-finder {
- .list-sort-button {
- border-top-left-radius: 0;
- border-top-right-radius: 0;
- border: none;
- padding: $euiSizeS $euiSize;
- font-weight: $euiFontWeightRegular;
- background-color: $euiColorLightestShade;
- }
-
- .li-striped {
- li {
- border: none;
- }
-
- li:nth-child(even) {
- background-color: $euiColorLightestShade;
- }
-
- li:nth-child(odd) {
- background-color: $euiColorEmptyShade;
- }
-
- .paginate-heading {
- font-weight: $euiFontWeightRegular;
- color: $euiColorDarkestShade;
- }
-
- .list-group-item {
- padding: $euiSizeS $euiSize;
-
- ul {
- padding: 0;
- display: flex;
- flex-direction: row;
-
- .finder-type {
- margin-right: $euiSizeS;
- }
- }
-
- a {
- display: block;
- color: $euiColorPrimary;
-
- i {
- color: shade($euiColorPrimary, 10%);
- margin-right: $euiSizeS;
- }
- }
-
- &:first-child {
- border-top-left-radius: 0;
- border-top-right-radius: 0;
- }
-
- &.list-group-no-results p {
- margin-bottom: 0;
- }
- }
- }
-
- /* stylelint-disable-next-line selector-type-no-unknown */
- paginate {
- paginate-controls {
- margin: $euiSize;
- }
- }
-}
diff --git a/src/plugins/timeline/public/directives/_timeline_expression_input.scss b/src/plugins/timeline/public/directives/_timeline_expression_input.scss
deleted file mode 100644
index e4294d8454c7..000000000000
--- a/src/plugins/timeline/public/directives/_timeline_expression_input.scss
+++ /dev/null
@@ -1,15 +0,0 @@
-/**
- * 1. Anchor suggestions beneath input.
- * 2. Allow for option of positioning suggestions absolutely.
- */
-
-.timExpressionInput__container {
- flex: 1 1 auto;
- display: flex;
- flex-direction: column; /* 1 */
- position: relative; /* 2 */
-}
-
-.timExpressionInput {
- min-height: 70px; // Matches buttons on the right with new vertical rhythm sizing
-}
diff --git a/src/plugins/timeline/public/directives/cells/_cells.scss b/src/plugins/timeline/public/directives/cells/_cells.scss
deleted file mode 100644
index 61634a710260..000000000000
--- a/src/plugins/timeline/public/directives/cells/_cells.scss
+++ /dev/null
@@ -1,62 +0,0 @@
-.timCell {
- display: inline-block;
- cursor: pointer;
- position: relative;
- box-sizing: border-box;
- border: 2px dashed transparent;
- padding-left: 0 !important;
- padding-right: 0 !important;
- margin-bottom: $euiSizeM;
-
- &.active {
- border-color: $euiColorLightShade;
- }
-}
-
-.timCell.running {
- opacity: 0.5;
-}
-
-.timCell__actions {
- position: absolute;
- bottom: $euiSizeXS;
- left: $euiSizeXS;
-
- > .timCell__action,
- > .timCell__id {
- @include euiFontSizeXS;
-
- font-weight: $euiFontWeightBold;
- color: $euiColorMediumShade;
- display: inline-block;
- text-align: center;
- width: $euiSizeL;
- height: $euiSizeL;
- line-height: $euiSizeL;
- border-radius: $euiSizeL / 2;
- border: $euiBorderThin;
- background-color: $euiColorLightestShade;
- z-index: $euiZLevel1;
- }
-
- > .timCell__action {
- opacity: 0;
-
- &:focus {
- opacity: 1;
- }
-
- &:hover,
- &:focus {
- color: $euiTextColor;
- border-color: $euiColorMediumShade;
- background-color: $euiColorLightShade;
- }
- }
-}
-
-.timCell:hover {
- .timCell__action {
- opacity: 1;
- }
-}
diff --git a/src/plugins/timeline/public/directives/cells/_index.scss b/src/plugins/timeline/public/directives/cells/_index.scss
deleted file mode 100644
index c537dd49d304..000000000000
--- a/src/plugins/timeline/public/directives/cells/_index.scss
+++ /dev/null
@@ -1 +0,0 @@
-@import "./cells";
diff --git a/src/plugins/timeline/public/directives/cells/cells.html b/src/plugins/timeline/public/directives/cells/cells.html
deleted file mode 100644
index de30655b620f..000000000000
--- a/src/plugins/timeline/public/directives/cells/cells.html
+++ /dev/null
@@ -1,52 +0,0 @@
-
-
-
-
-
-
-
{{$index + 1}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/plugins/timeline/public/directives/cells/cells.js b/src/plugins/timeline/public/directives/cells/cells.js
deleted file mode 100644
index 3e10d92a5349..000000000000
--- a/src/plugins/timeline/public/directives/cells/cells.js
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { move } from './collection';
-import { initTimelineGridDirective } from '../timeline_grid';
-
-import html from './cells.html';
-
-export function initCellsDirective(app) {
- initTimelineGridDirective(app);
-
- app.directive('timelineCells', function () {
- return {
- restrict: 'E',
- scope: {
- sheet: '=',
- state: '=',
- transient: '=',
- onSearch: '=',
- onSelect: '=',
- onRemoveSheet: '=',
- },
- template: html,
- link: function ($scope) {
- $scope.removeCell = function (index) {
- $scope.onRemoveSheet(index);
- };
-
- $scope.dropCell = function (item, partFrom, partTo, indexFrom, indexTo) {
- move($scope.sheet, indexFrom, indexTo);
- $scope.onSelect(indexTo);
- };
- },
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/cells/collection.ts b/src/plugins/timeline/public/directives/cells/collection.ts
deleted file mode 100644
index aeb4f83a75ca..000000000000
--- a/src/plugins/timeline/public/directives/cells/collection.ts
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import _ from 'lodash';
-
-/**
- * move an obj either up or down in the collection by
- * injecting it either before/after the prev/next obj that
- * satisfied the qualifier
- *
- * or, just from one index to another...
- *
- * @param {array} objs - the list to move the object within
- * @param {number|any} obj - the object that should be moved, or the index that the object is currently at
- * @param {number|boolean} below - the index to move the object to, or whether it should be moved up or down
- * @param {function} qualifier - a lodash-y callback, object = _.where, string = _.pluck
- * @return {array} - the objs argument
- */
-export function move(
- objs: any[],
- obj: object | number,
- below: number | boolean,
- qualifier?: ((object: object, index: number) => any) | Record | string
-): object[] {
- const origI = _.isNumber(obj) ? obj : objs.indexOf(obj);
- if (origI === -1) {
- return objs;
- }
-
- if (_.isNumber(below)) {
- // move to a specific index
- objs.splice(below, 0, objs.splice(origI, 1)[0]);
- return objs;
- }
-
- below = !!below;
- qualifier = qualifier && _.iteratee(qualifier);
-
- const above = !below;
- const finder = below ? _.findIndex : _.findLastIndex;
-
- // find the index of the next/previous obj that meets the qualifications
- const targetI = finder(objs, (otherAgg, otherI) => {
- if (below && otherI <= origI) {
- return;
- }
- if (above && otherI >= origI) {
- return;
- }
- return Boolean(_.isFunction(qualifier) && qualifier(otherAgg, otherI));
- });
-
- if (targetI === -1) {
- return objs;
- }
-
- // place the obj at it's new index
- objs.splice(targetI, 0, objs.splice(origI, 1)[0]);
- return objs;
-}
diff --git a/src/plugins/timeline/public/directives/chart/chart.js b/src/plugins/timeline/public/directives/chart/chart.js
deleted file mode 100644
index 0f26c92c2e17..000000000000
--- a/src/plugins/timeline/public/directives/chart/chart.js
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { i18n } from '@osd/i18n';
-
-export function Chart(timelinePanels) {
- return {
- restrict: 'A',
- scope: {
- seriesList: '=chart', // The flot object, data, config and all
- search: '=', // The function to execute to kick off a search
- interval: '=', // Required for formatting x-axis ticks
- rerenderTrigger: '=',
- },
- link: function ($scope, $elem) {
- let panelScope = $scope.$new(true);
-
- function render() {
- panelScope.$destroy();
-
- if (!$scope.seriesList) return;
-
- $scope.seriesList.render = $scope.seriesList.render || {
- type: 'timechart',
- };
-
- const panelSchema = timelinePanels.get($scope.seriesList.render.type);
-
- if (!panelSchema) {
- $elem.text(
- i18n.translate('timeline.chart.seriesList.noSchemaWarning', {
- defaultMessage: 'No such panel type: {renderType}',
- values: { renderType: $scope.seriesList.render.type },
- })
- );
- return;
- }
-
- panelScope = $scope.$new(true);
- panelScope.seriesList = $scope.seriesList;
- panelScope.interval = $scope.interval;
- panelScope.search = $scope.search;
-
- panelSchema.render(panelScope, $elem);
- }
-
- $scope.$watchGroup(['seriesList', 'rerenderTrigger'], render);
- },
- };
-}
diff --git a/src/plugins/timeline/public/directives/fixed_element.js b/src/plugins/timeline/public/directives/fixed_element.js
deleted file mode 100644
index b201b70e26a7..000000000000
--- a/src/plugins/timeline/public/directives/fixed_element.js
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import $ from 'jquery';
-
-export function initFixedElementDirective(app) {
- app.directive('fixedElementRoot', function () {
- return {
- restrict: 'A',
- link: function ($elem) {
- let fixedAt;
- $(window).bind('scroll', function () {
- const fixed = $('[fixed-element]', $elem);
- const body = $('[fixed-element-body]', $elem);
- const top = fixed.offset().top;
-
- if ($(window).scrollTop() > top) {
- // This is a gross hack, but its better than it was. I guess
- fixedAt = $(window).scrollTop();
- fixed.addClass(fixed.attr('fixed-element'));
- body.addClass(fixed.attr('fixed-element-body'));
- body.css({ top: fixed.height() });
- }
-
- if ($(window).scrollTop() < fixedAt) {
- fixed.removeClass(fixed.attr('fixed-element'));
- body.removeClass(fixed.attr('fixed-element-body'));
- body.removeAttr('style');
- }
- });
- },
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/fullscreen/fullscreen.html b/src/plugins/timeline/public/directives/fullscreen/fullscreen.html
deleted file mode 100644
index 9b5332a84a8c..000000000000
--- a/src/plugins/timeline/public/directives/fullscreen/fullscreen.html
+++ /dev/null
@@ -1,14 +0,0 @@
-
diff --git a/src/plugins/timeline/public/directives/fullscreen/fullscreen.js b/src/plugins/timeline/public/directives/fullscreen/fullscreen.js
deleted file mode 100644
index eec336572bef..000000000000
--- a/src/plugins/timeline/public/directives/fullscreen/fullscreen.js
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import html from './fullscreen.html';
-
-export function initFullscreenDirective(app) {
- app.directive('timelineFullscreen', function () {
- return {
- restrict: 'E',
- scope: {
- expression: '=',
- series: '=',
- state: '=',
- transient: '=',
- onSearch: '=',
- },
- template: html,
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/input_focus.js b/src/plugins/timeline/public/directives/input_focus.js
deleted file mode 100644
index 518208c02a2b..000000000000
--- a/src/plugins/timeline/public/directives/input_focus.js
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-export function initInputFocusDirective(app) {
- app.directive('inputFocus', function ($parse, $timeout) {
- return {
- restrict: 'A',
- link: function ($scope, $elem, attrs) {
- const isDisabled = attrs.disableInputFocus && $parse(attrs.disableInputFocus)($scope);
- if (!isDisabled) {
- $timeout(function () {
- $elem.focus();
- if (attrs.inputFocus === 'select') $elem.select();
- });
- }
- },
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/key_map.ts b/src/plugins/timeline/public/directives/key_map.ts
deleted file mode 100644
index e85deb4e2972..000000000000
--- a/src/plugins/timeline/public/directives/key_map.ts
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-export const keyMap: { [key: number]: string } = {
- 8: 'backspace',
- 9: 'tab',
- 13: 'enter',
- 16: 'shift',
- 17: 'ctrl',
- 18: 'alt',
- 19: 'pause',
- 20: 'capsLock',
- 27: 'escape',
- 32: 'space',
- 33: 'pageUp',
- 34: 'pageDown',
- 35: 'end',
- 36: 'home',
- 37: 'left',
- 38: 'up',
- 39: 'right',
- 40: 'down',
- 45: 'insert',
- 46: 'delete',
- 48: '0',
- 49: '1',
- 50: '2',
- 51: '3',
- 52: '4',
- 53: '5',
- 54: '6',
- 55: '7',
- 56: '8',
- 57: '9',
- 65: 'a',
- 66: 'b',
- 67: 'c',
- 68: 'd',
- 69: 'e',
- 70: 'f',
- 71: 'g',
- 72: 'h',
- 73: 'i',
- 74: 'j',
- 75: 'k',
- 76: 'l',
- 77: 'm',
- 78: 'n',
- 79: 'o',
- 80: 'p',
- 81: 'q',
- 82: 'r',
- 83: 's',
- 84: 't',
- 85: 'u',
- 86: 'v',
- 87: 'w',
- 88: 'x',
- 89: 'y',
- 90: 'z',
- 91: 'leftWindowKey',
- 92: 'rightWindowKey',
- 93: 'selectKey',
- 96: '0',
- 97: '1',
- 98: '2',
- 99: '3',
- 100: '4',
- 101: '5',
- 102: '6',
- 103: '7',
- 104: '8',
- 105: '9',
- 106: 'multiply',
- 107: 'add',
- 109: 'subtract',
- 110: 'period',
- 111: 'divide',
- 112: 'f1',
- 113: 'f2',
- 114: 'f3',
- 115: 'f4',
- 116: 'f5',
- 117: 'f6',
- 118: 'f7',
- 119: 'f8',
- 120: 'f9',
- 121: 'f10',
- 122: 'f11',
- 123: 'f12',
- 144: 'numLock',
- 145: 'scrollLock',
- 186: 'semiColon',
- 187: 'equalSign',
- 188: 'comma',
- 189: 'dash',
- 190: 'period',
- 191: 'forwardSlash',
- 192: 'graveAccent',
- 219: 'openBracket',
- 220: 'backSlash',
- 221: 'closeBracket',
- 222: 'singleQuote',
- 224: 'meta',
-};
diff --git a/src/plugins/timeline/public/directives/saved_object_finder.html b/src/plugins/timeline/public/directives/saved_object_finder.html
deleted file mode 100644
index 79e6121f458c..000000000000
--- a/src/plugins/timeline/public/directives/saved_object_finder.html
+++ /dev/null
@@ -1,118 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/plugins/timeline/public/directives/saved_object_finder.js b/src/plugins/timeline/public/directives/saved_object_finder.js
deleted file mode 100644
index 284b4e9d5fbd..000000000000
--- a/src/plugins/timeline/public/directives/saved_object_finder.js
+++ /dev/null
@@ -1,327 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import _ from 'lodash';
-import rison from 'rison-node';
-import savedObjectFinderTemplate from './saved_object_finder.html';
-import { keyMap } from './key_map';
-import {
- PaginateControlsDirectiveProvider,
- PaginateDirectiveProvider,
-} from '../../../opensearch_dashboards_legacy/public';
-import { PER_PAGE_SETTING } from '../../../saved_objects/public';
-import { VISUALIZE_ENABLE_LABS_SETTING } from '../../../visualizations/public';
-
-export function initSavedObjectFinderDirective(app, savedSheetLoader, uiSettings) {
- app
- .directive('paginate', PaginateDirectiveProvider)
- .directive('paginateControls', PaginateControlsDirectiveProvider)
- .directive('savedObjectFinder', function () {
- return {
- restrict: 'E',
- scope: {
- type: '@',
- // optional make-url attr, sets the userMakeUrl in our scope
- userMakeUrl: '=?makeUrl',
- // optional on-choose attr, sets the userOnChoose in our scope
- userOnChoose: '=?onChoose',
- // optional useLocalManagement attr, removes link to management section
- useLocalManagement: '=?useLocalManagement',
- /**
- * @type {function} - an optional function. If supplied an `Add new X` button is shown
- * and this function is called when clicked.
- */
- onAddNew: '=',
- /**
- * @{type} boolean - set this to true, if you don't want the search box above the
- * table to automatically gain focus once loaded
- */
- disableAutoFocus: '=',
- },
- template: savedObjectFinderTemplate,
- controllerAs: 'finder',
- controller: function ($scope, $element, $location, history) {
- const self = this;
-
- // the text input element
- const $input = $element.find('input[ng-model=filter]');
-
- // The number of items to show in the list
- $scope.perPage = uiSettings.get(PER_PAGE_SETTING);
-
- // the list that will hold the suggestions
- const $list = $element.find('ul');
-
- // the current filter string, used to check that returned results are still useful
- let currentFilter = $scope.filter;
-
- // the most recently entered search/filter
- let prevSearch;
-
- // the list of hits, used to render display
- self.hits = [];
-
- self.service = savedSheetLoader;
- self.properties = self.service.loaderProperties;
-
- filterResults();
-
- /**
- * Boolean that keeps track of whether hits are sorted ascending (true)
- * or descending (false) by title
- * @type {Boolean}
- */
- self.isAscending = true;
-
- /**
- * Sorts saved object finder hits either ascending or descending
- * @param {Array} hits Array of saved finder object hits
- * @return {Array} Array sorted either ascending or descending
- */
- self.sortHits = function (hits) {
- self.isAscending = !self.isAscending;
- self.hits = self.isAscending
- ? _.sortBy(hits, ['title'])
- : _.sortBy(hits, ['title']).reverse();
- };
-
- /**
- * Passed the hit objects and will determine if the
- * hit should have a url in the UI, returns it if so
- * @return {string|null} - the url or nothing
- */
- self.makeUrl = function (hit) {
- if ($scope.userMakeUrl) {
- return $scope.userMakeUrl(hit);
- }
-
- if (!$scope.userOnChoose) {
- return hit.url;
- }
-
- return '#';
- };
-
- self.preventClick = function ($event) {
- $event.preventDefault();
- };
-
- /**
- * Called when a hit object is clicked, can override the
- * url behavior if necessary.
- */
- self.onChoose = function (hit, $event) {
- if ($scope.userOnChoose) {
- $scope.userOnChoose(hit, $event);
- }
-
- const url = self.makeUrl(hit);
- if (!url || url === '#' || url.charAt(0) !== '#') return;
-
- $event.preventDefault();
-
- history.push(url.substr(1));
- };
-
- $scope.$watch('filter', function (newFilter) {
- // ensure that the currentFilter changes from undefined to ''
- // which triggers
- currentFilter = newFilter || '';
- filterResults();
- });
-
- $scope.pageFirstItem = 0;
- $scope.pageLastItem = 0;
- $scope.onPageChanged = (page) => {
- $scope.pageFirstItem = page.firstItem;
- $scope.pageLastItem = page.lastItem;
- };
-
- //manages the state of the keyboard selector
- self.selector = {
- enabled: false,
- index: -1,
- };
-
- self.getLabel = function () {
- return _.words(self.properties.nouns).map(_.capitalize).join(' ');
- };
-
- //key handler for the filter text box
- self.filterKeyDown = function ($event) {
- switch (keyMap[$event.keyCode]) {
- case 'enter':
- if (self.hitCount !== 1) return;
-
- const hit = self.hits[0];
- if (!hit) return;
-
- self.onChoose(hit, $event);
- $event.preventDefault();
- break;
- }
- };
-
- //key handler for the list items
- self.hitKeyDown = function ($event, page, paginate) {
- switch (keyMap[$event.keyCode]) {
- case 'tab':
- if (!self.selector.enabled) break;
-
- self.selector.index = -1;
- self.selector.enabled = false;
-
- //if the user types shift-tab return to the textbox
- //if the user types tab, set the focus to the currently selected hit.
- if ($event.shiftKey) {
- $input.focus();
- } else {
- $list.find('li.active a').focus();
- }
-
- $event.preventDefault();
- break;
- case 'down':
- if (!self.selector.enabled) break;
-
- if (self.selector.index + 1 < page.length) {
- self.selector.index += 1;
- }
- $event.preventDefault();
- break;
- case 'up':
- if (!self.selector.enabled) break;
-
- if (self.selector.index > 0) {
- self.selector.index -= 1;
- }
- $event.preventDefault();
- break;
- case 'right':
- if (!self.selector.enabled) break;
-
- if (page.number < page.count) {
- paginate.goToPage(page.number + 1);
- self.selector.index = 0;
- selectTopHit();
- }
- $event.preventDefault();
- break;
- case 'left':
- if (!self.selector.enabled) break;
-
- if (page.number > 1) {
- paginate.goToPage(page.number - 1);
- self.selector.index = 0;
- selectTopHit();
- }
- $event.preventDefault();
- break;
- case 'escape':
- if (!self.selector.enabled) break;
-
- $input.focus();
- $event.preventDefault();
- break;
- case 'enter':
- if (!self.selector.enabled) break;
-
- const hitIndex = (page.number - 1) * paginate.perPage + self.selector.index;
- const hit = self.hits[hitIndex];
- if (!hit) break;
-
- self.onChoose(hit, $event);
- $event.preventDefault();
- break;
- case 'shift':
- break;
- default:
- $input.focus();
- break;
- }
- };
-
- self.hitBlur = function () {
- self.selector.index = -1;
- self.selector.enabled = false;
- };
-
- self.manageObjects = function (type) {
- $location.url(
- '/management/opensearch-dashboards/objects?_a=' + rison.encode({ tab: type })
- );
- };
-
- self.hitCountNoun = function () {
- return (self.hitCount === 1
- ? self.properties.noun
- : self.properties.nouns
- ).toLowerCase();
- };
-
- function selectTopHit() {
- setTimeout(function () {
- //triggering a focus event kicks off a new angular digest cycle.
- $list.find('a:first').focus();
- }, 0);
- }
-
- function filterResults() {
- if (!self.service) return;
- if (!self.properties) return;
-
- // track the filter that we use for this search,
- // but ensure that we don't search for the same
- // thing twice. This is called from multiple places
- // and needs to be smart about when it actually searches
- const filter = currentFilter;
- if (prevSearch === filter) return;
-
- prevSearch = filter;
-
- const isLabsEnabled = uiSettings.get(VISUALIZE_ENABLE_LABS_SETTING);
- self.service.find(filter).then(function (hits) {
- hits.hits = hits.hits.filter(
- (hit) => isLabsEnabled || _.get(hit, 'type.stage') !== 'experimental'
- );
- hits.total = hits.hits.length;
-
- // ensure that we don't display old results
- // as we can't really cancel requests
- if (currentFilter === filter) {
- self.hitCount = hits.total;
- self.hits = _.sortBy(hits.hits, ['title']);
- }
- });
- }
- },
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/saved_object_save_as_checkbox.html b/src/plugins/timeline/public/directives/saved_object_save_as_checkbox.html
deleted file mode 100644
index da16aafdf7af..000000000000
--- a/src/plugins/timeline/public/directives/saved_object_save_as_checkbox.html
+++ /dev/null
@@ -1,28 +0,0 @@
-
-
diff --git a/src/plugins/timeline/public/directives/saved_object_save_as_checkbox.js b/src/plugins/timeline/public/directives/saved_object_save_as_checkbox.js
deleted file mode 100644
index 794ecb01f0a6..000000000000
--- a/src/plugins/timeline/public/directives/saved_object_save_as_checkbox.js
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import saveObjectSaveAsCheckboxTemplate from './saved_object_save_as_checkbox.html';
-
-export function initSavedObjectSaveAsCheckBoxDirective(app) {
- app.directive('savedObjectSaveAsCheckBox', function () {
- return {
- restrict: 'E',
- template: saveObjectSaveAsCheckboxTemplate,
- replace: true,
- scope: {
- savedObject: '=',
- },
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/timeline_expression_input.html b/src/plugins/timeline/public/directives/timeline_expression_input.html
deleted file mode 100644
index b565e6643fc6..000000000000
--- a/src/plugins/timeline/public/directives/timeline_expression_input.html
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
-
-
-
-
diff --git a/src/plugins/timeline/public/directives/timeline_expression_input.js b/src/plugins/timeline/public/directives/timeline_expression_input.js
deleted file mode 100644
index 0c4150c952a6..000000000000
--- a/src/plugins/timeline/public/directives/timeline_expression_input.js
+++ /dev/null
@@ -1,293 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-/**
- * Timeline Expression Autocompleter
- *
- * This directive allows users to enter multiline timeline expressions. If the user has entered
- * a valid expression and then types a ".", this directive will display a list of suggestions.
- *
- * Users can navigate suggestions using the arrow keys. When a user selects a suggestion, it's
- * inserted into the expression and the caret position is updated to be inside of the newly-
- * added function's parentheses.
- *
- * Beneath the hood, we use a PEG grammar to validate the Timeline expression and detect if
- * the caret is in a position within the expression that allows functions to be suggested.
- *
- * NOTE: This directive doesn't work well with contenteditable divs. Challenges include:
- * - You have to replace markup with newline characters and spaces when passing the expression
- * to the grammar.
- * - You have to do the opposite when loading a saved expression, so that it appears correctly
- * within the contenteditable (i.e. replace newlines with markup).
- * - The Range and Selection APIs ignore newlines when providing caret position, so there is
- * literally no way to insert suggestions into the correct place in a multiline expression
- * that has more than a single consecutive newline.
- */
-
-import _ from 'lodash';
-import $ from 'jquery';
-import PEG from 'pegjs';
-import grammar from 'raw-loader!../../../vis_type_timeline/common/chain.peg';
-import timelineExpressionInputTemplate from './timeline_expression_input.html';
-import {
- SUGGESTION_TYPE,
- Suggestions,
- suggest,
- insertAtLocation,
-} from './timeline_expression_input_helpers';
-import { comboBoxKeyCodes } from '@elastic/eui';
-
-const Parser = PEG.generate(grammar);
-
-export function timelineExpInput(deps) {
- return ($http, $timeout) => {
- return {
- restrict: 'E',
- scope: {
- rows: '=',
- sheet: '=',
- updateChart: '&',
- shouldPopoverSuggestions: '@',
- },
- replace: true,
- template: timelineExpressionInputTemplate,
- link: function (scope, elem) {
- const argValueSuggestions = deps.plugins.visTypeTimeline.getArgValueSuggestions();
- const expressionInput = elem.find('[data-expression-input]');
- const functionReference = {};
- let suggestibleFunctionLocation = {};
-
- scope.suggestions = new Suggestions();
-
- function init() {
- $http.get('../api/timeline/functions').then(function (resp) {
- Object.assign(functionReference, {
- byName: _.keyBy(resp.data, 'name'),
- list: resp.data,
- });
- });
- }
-
- function setCaretOffset(caretOffset) {
- // Wait for Angular to update the input with the new expression and *then* we can set
- // the caret position.
- $timeout(() => {
- expressionInput.focus();
- expressionInput[0].selectionStart = expressionInput[0].selectionEnd = caretOffset;
- scope.$apply();
- }, 0);
- }
-
- function insertSuggestionIntoExpression(suggestionIndex) {
- if (scope.suggestions.isEmpty()) {
- return;
- }
-
- const { min, max } = suggestibleFunctionLocation;
- let insertedValue;
- let insertPositionMinOffset = 0;
-
- switch (scope.suggestions.type) {
- case SUGGESTION_TYPE.FUNCTIONS: {
- // Position the caret inside of the function parentheses.
- insertedValue = `${scope.suggestions.list[suggestionIndex].name}()`;
-
- // min advanced one to not replace function '.'
- insertPositionMinOffset = 1;
- break;
- }
- case SUGGESTION_TYPE.ARGUMENTS: {
- // Position the caret after the '='
- insertedValue = `${scope.suggestions.list[suggestionIndex].name}=`;
- break;
- }
- case SUGGESTION_TYPE.ARGUMENT_VALUE: {
- // Position the caret after the argument value
- insertedValue = `${scope.suggestions.list[suggestionIndex].name}`;
- break;
- }
- }
-
- const updatedExpression = insertAtLocation(
- insertedValue,
- scope.sheet,
- min + insertPositionMinOffset,
- max
- );
- scope.sheet = updatedExpression;
-
- const newCaretOffset = min + insertedValue.length;
- setCaretOffset(newCaretOffset);
- }
-
- function scrollToSuggestionAt(index) {
- // We don't cache these because the list changes based on user input.
- const suggestionsList = $('[data-suggestions-list]');
- const suggestionListItem = $('[data-suggestion-list-item]')[index];
- // Scroll to the position of the item relative to the list, not to the window.
- suggestionsList.scrollTop(suggestionListItem.offsetTop - suggestionsList[0].offsetTop);
- }
-
- function getCursorPosition() {
- if (expressionInput.length) {
- return expressionInput[0].selectionStart;
- }
- return null;
- }
-
- async function getSuggestions() {
- const suggestions = await suggest(
- scope.sheet,
- functionReference.list,
- Parser,
- getCursorPosition(),
- argValueSuggestions
- );
-
- // We're using ES6 Promises, not $q, so we have to wrap this in $apply.
- scope.$apply(() => {
- if (suggestions) {
- scope.suggestions.setList(suggestions.list, suggestions.type);
- scope.suggestions.show();
- suggestibleFunctionLocation = suggestions.location;
- $timeout(() => {
- const suggestionsList = $('[data-suggestions-list]');
- suggestionsList.scrollTop(0);
- }, 0);
- return;
- }
-
- suggestibleFunctionLocation = undefined;
- scope.suggestions.reset();
- });
- }
-
- function isNavigationalKey(keyCode) {
- const keyCodes = _.values(comboBoxKeyCodes);
- return keyCodes.includes(keyCode);
- }
-
- scope.onFocusInput = () => {
- // Wait for the caret position of the input to update and then we can get suggestions
- // (which depends on the caret position).
- $timeout(getSuggestions, 0);
- };
-
- scope.onBlurInput = () => {
- scope.suggestions.hide();
- };
-
- scope.onKeyDownInput = (e) => {
- // If we've pressed any non-navigational keys, then the user has typed something and we
- // can exit early without doing any navigation. The keyup handler will pull up suggestions.
- if (!isNavigationalKey(e.keyCode)) {
- return;
- }
-
- switch (e.keyCode) {
- case comboBoxKeyCodes.UP:
- if (scope.suggestions.isVisible) {
- // Up and down keys navigate through suggestions.
- e.preventDefault();
- scope.suggestions.stepForward();
- scrollToSuggestionAt(scope.suggestions.index);
- }
- break;
-
- case comboBoxKeyCodes.DOWN:
- if (scope.suggestions.isVisible) {
- // Up and down keys navigate through suggestions.
- e.preventDefault();
- scope.suggestions.stepBackward();
- scrollToSuggestionAt(scope.suggestions.index);
- }
- break;
-
- case comboBoxKeyCodes.TAB:
- // If there are no suggestions or none is selected, the user tabs to the next input.
- if (scope.suggestions.isEmpty() || scope.suggestions.index < 0) {
- // Before letting the tab be handled to focus the next element
- // we need to hide the suggestions, otherwise it will focus these
- // instead of the time interval select.
- scope.suggestions.hide();
- return;
- }
-
- // If we have suggestions, complete the selected one.
- e.preventDefault();
- insertSuggestionIntoExpression(scope.suggestions.index);
- break;
-
- case comboBoxKeyCodes.ENTER:
- if (e.metaKey || e.ctrlKey) {
- // Re-render the chart when the user hits CMD+ENTER.
- e.preventDefault();
- scope.updateChart();
- } else if (!scope.suggestions.isEmpty()) {
- // If the suggestions are open, complete the expression with the suggestion.
- e.preventDefault();
- insertSuggestionIntoExpression(scope.suggestions.index);
- }
- break;
-
- case comboBoxKeyCodes.ESCAPE:
- e.preventDefault();
- scope.suggestions.hide();
- break;
- }
- };
-
- scope.onKeyUpInput = (e) => {
- // If the user isn't navigating, then we should update the suggestions based on their input.
- if (!isNavigationalKey(e.keyCode)) {
- getSuggestions();
- }
- };
-
- scope.onClickExpression = () => {
- getSuggestions();
- };
-
- scope.onClickSuggestion = (index) => {
- insertSuggestionIntoExpression(index);
- };
-
- scope.getActiveSuggestionId = () => {
- if (scope.suggestions.isVisible && scope.suggestions.index > -1) {
- return `timelineSuggestion${scope.suggestions.index}`;
- }
- return '';
- };
-
- init();
- },
- };
- };
-}
diff --git a/src/plugins/timeline/public/directives/timeline_expression_input_helpers.js b/src/plugins/timeline/public/directives/timeline_expression_input_helpers.js
deleted file mode 100644
index 62f496d0f6f0..000000000000
--- a/src/plugins/timeline/public/directives/timeline_expression_input_helpers.js
+++ /dev/null
@@ -1,291 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import _ from 'lodash';
-
-export const SUGGESTION_TYPE = {
- ARGUMENTS: 'arguments',
- ARGUMENT_VALUE: 'argument_value',
- FUNCTIONS: 'functions',
-};
-
-export class Suggestions {
- constructor() {
- this.reset();
- }
-
- reset() {
- this.index = -1;
- this.list = [];
- this.type = null;
- this.isVisible = false;
- }
-
- setList(list, type) {
- this.list = list.sort((a, b) => {
- if (a.name < b.name) {
- return -1;
- }
- if (a.name > b.name) {
- return 1;
- }
- // names must be equal
- return 0;
- });
- this.type = type;
-
- // Only try to position index inside of list range, when it was already focused
- // beforehand (i.e. not -1)
- if (this.index > -1) {
- // We may get a shorter list than the one we have now, so we need to make sure our index doesn't
- // fall outside of the new list's range.
- this.index = Math.max(0, Math.min(this.index, this.list.length - 1));
- }
- }
-
- getCount() {
- return this.list.length;
- }
-
- isEmpty() {
- return this.list.length === 0;
- }
-
- show() {
- this.isVisible = true;
- }
-
- hide() {
- this.isVisible = false;
- }
-
- stepForward() {
- if (this.index > 0) {
- this.index -= 1;
- }
- }
-
- stepBackward() {
- if (this.index < this.list.length - 1) {
- this.index += 1;
- }
- }
-}
-
-function inLocation(cursorPosition, location) {
- return cursorPosition >= location.min && cursorPosition <= location.max;
-}
-
-function getArgumentsHelp(functionHelp, functionArgs = []) {
- if (!functionHelp) {
- return [];
- }
-
- // Do not provide 'inputSeries' as argument suggestion for chainable functions
- const argsHelp = functionHelp.chainable ? functionHelp.args.slice(1) : functionHelp.args.slice(0);
-
- // ignore arguments that are already provided in function declaration
- const functionArgNames = functionArgs.map((arg) => {
- return arg.name;
- });
- return argsHelp.filter((arg) => {
- return !functionArgNames.includes(arg.name);
- });
-}
-
-async function extractSuggestionsFromParsedResult(
- result,
- cursorPosition,
- functionList,
- argValueSuggestions
-) {
- const activeFunc = result.functions.find((func) => {
- return cursorPosition >= func.location.min && cursorPosition < func.location.max;
- });
-
- if (!activeFunc) {
- return;
- }
-
- const functionHelp = functionList.find((func) => {
- return func.name === activeFunc.function;
- });
-
- // return function suggestion when cursor is outside of parentheses
- // location range includes '.', function name, and '('.
- const openParen = activeFunc.location.min + activeFunc.function.length + 2;
- if (cursorPosition < openParen) {
- return { list: [functionHelp], location: activeFunc.location, type: SUGGESTION_TYPE.FUNCTIONS };
- }
-
- // return argument value suggestions when cursor is inside argument value
- const activeArg = activeFunc.arguments.find((argument) => {
- return inLocation(cursorPosition, argument.location);
- });
- if (
- activeArg &&
- activeArg.type === 'namedArg' &&
- inLocation(cursorPosition, activeArg.value.location)
- ) {
- const { function: functionName, arguments: functionArgs } = activeFunc;
-
- const {
- name: argName,
- value: { text: partialInput },
- } = activeArg;
-
- let valueSuggestions;
- if (argValueSuggestions.hasDynamicSuggestionsForArgument(functionName, argName)) {
- valueSuggestions = await argValueSuggestions.getDynamicSuggestionsForArgument(
- functionName,
- argName,
- functionArgs,
- partialInput
- );
- } else {
- const { suggestions: staticSuggestions } = functionHelp.args.find((arg) => {
- return arg.name === activeArg.name;
- });
- valueSuggestions = argValueSuggestions.getStaticSuggestionsForInput(
- partialInput,
- staticSuggestions
- );
- }
- return {
- list: valueSuggestions,
- location: activeArg.value.location,
- type: SUGGESTION_TYPE.ARGUMENT_VALUE,
- };
- }
-
- // return argument suggestions
- const argsHelp = getArgumentsHelp(functionHelp, activeFunc.arguments);
- const argumentSuggestions = argsHelp.filter((arg) => {
- if (_.get(activeArg, 'type') === 'namedArg') {
- return _.startsWith(arg.name, activeArg.name);
- } else if (activeArg) {
- return _.startsWith(arg.name, activeArg.text);
- }
- return true;
- });
- const location = activeArg ? activeArg.location : { min: cursorPosition, max: cursorPosition };
- return { list: argumentSuggestions, location: location, type: SUGGESTION_TYPE.ARGUMENTS };
-}
-
-export async function suggest(
- expression,
- functionList,
- Parser,
- cursorPosition,
- argValueSuggestions
-) {
- try {
- const result = await Parser.parse(expression);
- return await extractSuggestionsFromParsedResult(
- result,
- cursorPosition,
- functionList,
- argValueSuggestions
- );
- } catch (e) {
- let message;
- try {
- // The grammar will throw an error containing a message if the expression is formatted
- // correctly and is prepared to accept suggestions. If the expression is not formatted
- // correctly the grammar will just throw a regular PEG SyntaxError, and this JSON.parse
- // attempt will throw an error.
- message = JSON.parse(e.message);
- } catch (e) {
- // The expression isn't correctly formatted, so JSON.parse threw an error.
- return;
- }
-
- switch (message.type) {
- case 'incompleteFunction': {
- let list;
- if (message.function) {
- // The user has start typing a function name, so we'll filter the list down to only
- // possible matches.
- list = functionList.filter((func) => _.startsWith(func.name, message.function));
- } else {
- // The user hasn't typed anything yet, so we'll just return the entire list.
- list = functionList;
- }
- return { list, location: message.location, type: SUGGESTION_TYPE.FUNCTIONS };
- }
- case 'incompleteArgument': {
- const { currentFunction: functionName, currentArgs: functionArgs } = message;
- const functionHelp = functionList.find((func) => func.name === functionName);
- return {
- list: getArgumentsHelp(functionHelp, functionArgs),
- location: message.location,
- type: SUGGESTION_TYPE.ARGUMENTS,
- };
- }
- case 'incompleteArgumentValue': {
- const { name: argName, currentFunction: functionName, currentArgs: functionArgs } = message;
- let valueSuggestions = [];
- if (argValueSuggestions.hasDynamicSuggestionsForArgument(functionName, argName)) {
- valueSuggestions = await argValueSuggestions.getDynamicSuggestionsForArgument(
- functionName,
- argName,
- functionArgs
- );
- } else {
- const functionHelp = functionList.find((func) => func.name === functionName);
- if (functionHelp) {
- const argHelp = functionHelp.args.find((arg) => arg.name === argName);
- if (argHelp && argHelp.suggestions) {
- valueSuggestions = argHelp.suggestions;
- }
- }
- }
- return {
- list: valueSuggestions,
- location: { min: cursorPosition, max: cursorPosition },
- type: SUGGESTION_TYPE.ARGUMENT_VALUE,
- };
- }
- }
- }
-}
-
-export function insertAtLocation(
- valueToInsert,
- destination,
- replacementRangeStart,
- replacementRangeEnd
-) {
- // Insert the value at a location caret within the destination.
- const prefix = destination.slice(0, replacementRangeStart);
- const suffix = destination.slice(replacementRangeEnd, destination.length);
- const result = `${prefix}${valueToInsert}${suffix}`;
- return result;
-}
diff --git a/src/plugins/timeline/public/directives/timeline_expression_suggestions/_index.scss b/src/plugins/timeline/public/directives/timeline_expression_suggestions/_index.scss
deleted file mode 100644
index e49c9151ff73..000000000000
--- a/src/plugins/timeline/public/directives/timeline_expression_suggestions/_index.scss
+++ /dev/null
@@ -1 +0,0 @@
-@import "./timeline_expression_suggestions";
diff --git a/src/plugins/timeline/public/directives/timeline_expression_suggestions/_timeline_expression_suggestions.scss b/src/plugins/timeline/public/directives/timeline_expression_suggestions/_timeline_expression_suggestions.scss
deleted file mode 100644
index 89b96d11c6fd..000000000000
--- a/src/plugins/timeline/public/directives/timeline_expression_suggestions/_timeline_expression_suggestions.scss
+++ /dev/null
@@ -1,36 +0,0 @@
-.timSuggestions {
- @include euiBottomShadowMedium;
-
- background-color: $euiColorLightestShade;
- color: $euiTextColor;
- border: $euiBorderThin;
- border-radius: 0 0 $euiBorderRadius $euiBorderRadius !important;
- z-index: $euiZLevel9;
- max-height: $euiSizeXL * 10;
- overflow-y: auto;
-
- &.timSuggestions-isPopover {
- position: absolute;
- top: 100%;
- }
-}
-
-.timSuggestions__item {
- border-bottom: $euiBorderThin;
- padding: $euiSizeXS $euiSizeL;
-
- &:hover,
- &.active {
- background-color: $euiColorLightShade;
- }
-}
-
-.timSuggestions__details {
- background-color: $euiColorLightestShade;
- padding: $euiSizeM;
- border-radius: $euiBorderRadius;
-
- > table {
- margin-bottom: 0;
- }
-}
diff --git a/src/plugins/timeline/public/directives/timeline_expression_suggestions/timeline_expression_suggestions.html b/src/plugins/timeline/public/directives/timeline_expression_suggestions/timeline_expression_suggestions.html
deleted file mode 100644
index f2469b99815a..000000000000
--- a/src/plugins/timeline/public/directives/timeline_expression_suggestions/timeline_expression_suggestions.html
+++ /dev/null
@@ -1,109 +0,0 @@
-
-
-
-
-
-
-
- .{{suggestion.name}}()
-
-
-
-
-
-
-
-
-
-
- {{arg.name}} =({{arg.types.join(' | ')}} )
- ,
-
-
-
-
-
-
-
-
-
-
-
- {{arg.name}}
- {{arg.types.join(', ')}}
- {{arg.help}}
-
-
-
-
-
-
-
-
- {{suggestion.name}}=
-
- {{suggestion.help}}
-
-
-
- Accepts:
- {{suggestion.types.join(', ')}}
-
-
-
-
-
- {{suggestion.name}}
-
- {{suggestion.help}}
-
-
-
-
-
-
-
diff --git a/src/plugins/timeline/public/directives/timeline_expression_suggestions/timeline_expression_suggestions.js b/src/plugins/timeline/public/directives/timeline_expression_suggestions/timeline_expression_suggestions.js
deleted file mode 100644
index a2c24e57f756..000000000000
--- a/src/plugins/timeline/public/directives/timeline_expression_suggestions/timeline_expression_suggestions.js
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import template from './timeline_expression_suggestions.html';
-
-export function TimelineExpressionSuggestions() {
- return {
- restrict: 'E',
- scope: {
- suggestions: '=',
- suggestionsType: '=',
- selectedIndex: '=',
- onClickSuggestion: '&',
- shouldPopover: '=',
- },
- replace: true,
- template,
- link: function (scope) {
- // This will prevent the expression input from losing focus.
- scope.onMouseDown = (e) => e.preventDefault();
- },
- };
-}
diff --git a/src/plugins/timeline/public/directives/timeline_grid.js b/src/plugins/timeline/public/directives/timeline_grid.js
deleted file mode 100644
index 48db69aa4a0e..000000000000
--- a/src/plugins/timeline/public/directives/timeline_grid.js
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import $ from 'jquery';
-
-export function initTimelineGridDirective(app) {
- app.directive('timelineGrid', function () {
- return {
- restrict: 'A',
- scope: {
- timelineGridRows: '=',
- timelineGridColumns: '=',
- },
- link: function ($scope, $elem) {
- function init() {
- setDimensions();
- }
-
- $scope.$on('$destroy', function () {
- $(window).off('resize'); //remove the handler added earlier
- });
-
- $(window).resize(function () {
- setDimensions();
- });
-
- $scope.$watchMulti(['timelineGridColumns', 'timelineGridRows'], function () {
- setDimensions();
- });
-
- function setDimensions() {
- const borderSize = 2;
- const headerSize = 45 + 35 + 28 + 20 * 2; // chrome + subnav + buttons + (container padding)
- const verticalPadding = 10;
-
- if ($scope.timelineGridColumns != null) {
- $elem.width($elem.parent().width() / $scope.timelineGridColumns - borderSize * 2);
- }
-
- if ($scope.timelineGridRows != null) {
- $elem.height(
- ($(window).height() - headerSize) / $scope.timelineGridRows -
- (verticalPadding + borderSize * 2)
- );
- }
- }
-
- init();
- },
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/timeline_help/_index.scss b/src/plugins/timeline/public/directives/timeline_help/_index.scss
deleted file mode 100644
index 763746e95a10..000000000000
--- a/src/plugins/timeline/public/directives/timeline_help/_index.scss
+++ /dev/null
@@ -1 +0,0 @@
-@import "./timeline_help";
diff --git a/src/plugins/timeline/public/directives/timeline_help/_timeline_help.scss b/src/plugins/timeline/public/directives/timeline_help/_timeline_help.scss
deleted file mode 100644
index c114f831adcb..000000000000
--- a/src/plugins/timeline/public/directives/timeline_help/_timeline_help.scss
+++ /dev/null
@@ -1,24 +0,0 @@
-.timHelp {
- // EUITODO: Make .euiText > code background transparent
- code {
- background-color: transparentize($euiTextColor, 0.9);
- }
-}
-
-.timHelp__buttons {
- display: flex;
- justify-content: space-between;
-}
-
-.timHelp__functions {
- height: $euiSizeXL * 10;
- overflow-y: auto;
-}
-
-/**
- * 1. Override bootstrap .table styles.
- */
-.timHelp__functionsTableRow:hover,
-.timHelp__functionDetailsTable {
- background-color: $euiColorLightestShade !important; /* 1 */
-}
diff --git a/src/plugins/timeline/public/directives/timeline_help/timeline_help.html b/src/plugins/timeline/public/directives/timeline_help/timeline_help.html
deleted file mode 100644
index a241405b3c44..000000000000
--- a/src/plugins/timeline/public/directives/timeline_help/timeline_help.html
+++ /dev/null
@@ -1,507 +0,0 @@
-
-
-
-
-
- {{translations.dontShowHelpButtonLabel}}
-
-
-
- {{translations.nextButtonLabel}}
-
-
-
-
-
-
-
-
- {{translations.previousButtonLabel}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{translations.previousButtonLabel}}
-
-
-
- {{translations.nextButtonLabel}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{translations.previousButtonLabel}}
-
-
-
- {{translations.nextButtonLabel}}
-
-
-
-
-
-
-
-
-
-
-
-
- .opensearch(*), .opensearch(US)
-
-
-
- .opensearch(*).color(#f66), .opensearch(US).bars(1)
-
-
-
-
- .opensearch(*).color(#f66).lines(fill=3), .opensearch(US).bars(1).points(radius=3,
- weight=1)
-
-
-
-
- (.opensearch(*), .opensearch(GB)).points()
-
-
-
-
-
- .
-
-
-
-
- {{translations.previousButtonLabel}}
-
-
-
- {{translations.nextButtonLabel}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{translations.previousButtonLabel}}
-
-
-
- {{translations.dontShowHelpButtonLabel}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- .{{function.name}}()
- {{function.help}}
-
-
-
-
-
-
-
-
-
-
-
- {{arg.name}}
- {{arg.types.join(', ')}}
- {{arg.help}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Ctrl/Cmd + Enter
-
-
-
-
-
-
-
-
-
-
-
-
- Enter/Tab
-
- Esc
-
-
-
-
diff --git a/src/plugins/timeline/public/directives/timeline_help/timeline_help.js b/src/plugins/timeline/public/directives/timeline_help/timeline_help.js
deleted file mode 100644
index 86ba02c6c87b..000000000000
--- a/src/plugins/timeline/public/directives/timeline_help/timeline_help.js
+++ /dev/null
@@ -1,177 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import template from './timeline_help.html';
-import { i18n } from '@osd/i18n';
-import _ from 'lodash';
-import moment from 'moment';
-
-export function initTimelineHelpDirective(app) {
- app.directive('timelineHelp', function ($http) {
- return {
- restrict: 'E',
- template,
- controller: function ($scope) {
- $scope.functions = {
- list: [],
- details: null,
- };
-
- $scope.activeTab = 'funcref';
- $scope.activateTab = function (tabName) {
- $scope.activeTab = tabName;
- };
-
- function init() {
- $scope.opensearch = {
- invalidCount: 0,
- };
-
- $scope.translations = {
- nextButtonLabel: i18n.translate('timeline.help.nextPageButtonLabel', {
- defaultMessage: 'Next',
- }),
- previousButtonLabel: i18n.translate('timeline.help.previousPageButtonLabel', {
- defaultMessage: 'Previous',
- }),
- dontShowHelpButtonLabel: i18n.translate('timeline.help.dontShowHelpButtonLabel', {
- defaultMessage: `Don't show this again`,
- }),
- strongNextText: i18n.translate('timeline.help.welcome.content.strongNextText', {
- defaultMessage: 'Next',
- }),
- emphasizedEverythingText: i18n.translate(
- 'timeline.help.welcome.content.emphasizedEverythingText',
- {
- defaultMessage: 'everything',
- }
- ),
- notValidAdvancedSettingsPath: i18n.translate(
- 'timeline.help.configuration.notValid.advancedSettingsPathText',
- {
- defaultMessage: 'Management / OpenSearch Dashboards / Advanced Settings',
- }
- ),
- validAdvancedSettingsPath: i18n.translate(
- 'timeline.help.configuration.valid.advancedSettingsPathText',
- {
- defaultMessage: 'Management/OpenSearch Dashboards/Advanced Settings',
- }
- ),
- opensearchAsteriskQueryDescription: i18n.translate(
- 'timeline.help.querying.opensearchAsteriskQueryDescriptionText',
- {
- defaultMessage: 'hey OpenSearch, find everything in my default index',
- }
- ),
- opensearchIndexQueryDescription: i18n.translate(
- 'timeline.help.querying.opensearchIndexQueryDescriptionText',
- {
- defaultMessage: 'use * as the q (query) for the logstash-* index',
- }
- ),
- strongAddText: i18n.translate('timeline.help.expressions.strongAddText', {
- defaultMessage: 'Add',
- }),
- twoExpressionsDescriptionTitle: i18n.translate(
- 'timeline.help.expressions.examples.twoExpressionsDescriptionTitle',
- {
- defaultMessage: 'Double the fun.',
- }
- ),
- customStylingDescriptionTitle: i18n.translate(
- 'timeline.help.expressions.examples.customStylingDescriptionTitle',
- {
- defaultMessage: 'Custom styling.',
- }
- ),
- namedArgumentsDescriptionTitle: i18n.translate(
- 'timeline.help.expressions.examples.namedArgumentsDescriptionTitle',
- {
- defaultMessage: 'Named arguments.',
- }
- ),
- groupedExpressionsDescriptionTitle: i18n.translate(
- 'timeline.help.expressions.examples.groupedExpressionsDescriptionTitle',
- {
- defaultMessage: 'Grouped expressions.',
- }
- ),
- };
-
- getFunctions();
- checkOpenSearch();
- }
-
- function getFunctions() {
- return $http.get('../api/timeline/functions').then(function (resp) {
- $scope.functions.list = resp.data;
- });
- }
- $scope.recheckOpenSearch = function () {
- $scope.opensearch.valid = null;
- checkOpenSearch().then(function (valid) {
- if (!valid) $scope.opensearch.invalidCount++;
- });
- };
-
- function checkOpenSearch() {
- return $http.get('../api/timeline/validate/opensearch').then(function (resp) {
- if (resp.data.ok) {
- $scope.opensearch.valid = true;
- $scope.opensearch.stats = {
- min: moment(resp.data.min).format('LLL'),
- max: moment(resp.data.max).format('LLL'),
- field: resp.data.field,
- };
- } else {
- $scope.opensearch.valid = false;
- $scope.opensearch.invalidReason = (function () {
- try {
- const opensearchResp = JSON.parse(resp.data.resp.response);
- return _.get(opensearchResp, 'error.root_cause[0].reason');
- } catch (e) {
- if (_.get(resp, 'data.resp.message')) return _.get(resp, 'data.resp.message');
- if (_.get(resp, 'data.resp.output.payload.message'))
- return _.get(resp, 'data.resp.output.payload.message');
- return i18n.translate('timeline.help.unknownErrorMessage', {
- defaultMessage: 'Unknown error',
- });
- }
- })();
- }
- return $scope.opensearch.valid;
- });
- }
- init();
- },
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/timeline_interval/_index.scss b/src/plugins/timeline/public/directives/timeline_interval/_index.scss
deleted file mode 100644
index fb597657a0a7..000000000000
--- a/src/plugins/timeline/public/directives/timeline_interval/_index.scss
+++ /dev/null
@@ -1 +0,0 @@
-@import "./timeline_interval";
diff --git a/src/plugins/timeline/public/directives/timeline_interval/_timeline_interval.scss b/src/plugins/timeline/public/directives/timeline_interval/_timeline_interval.scss
deleted file mode 100644
index 6117bbff13eb..000000000000
--- a/src/plugins/timeline/public/directives/timeline_interval/_timeline_interval.scss
+++ /dev/null
@@ -1,24 +0,0 @@
-timeline-interval {
- display: flex;
-}
-
-.timInterval__input {
- width: $euiSizeXL * 2;
-}
-
-.timInterval__input--compact {
- border-top-right-radius: 0;
- border-bottom-right-radius: 0;
-}
-
-.timInterval__presets {
- width: $euiSizeXL * 3;
-}
-
-.timInterval__presets--compact {
- width: $euiSizeXL * 1;
- padding-left: 0;
- border-left: none;
- border-top-left-radius: 0;
- border-bottom-left-radius: 0;
-}
diff --git a/src/plugins/timeline/public/directives/timeline_interval/timeline_interval.html b/src/plugins/timeline/public/directives/timeline_interval/timeline_interval.html
deleted file mode 100644
index 7eb1b72e46fd..000000000000
--- a/src/plugins/timeline/public/directives/timeline_interval/timeline_interval.html
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
- {{::intervalOption}}
-
-
diff --git a/src/plugins/timeline/public/directives/timeline_interval/timeline_interval.js b/src/plugins/timeline/public/directives/timeline_interval/timeline_interval.js
deleted file mode 100644
index 66869155916a..000000000000
--- a/src/plugins/timeline/public/directives/timeline_interval/timeline_interval.js
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import _ from 'lodash';
-import $ from 'jquery';
-import template from './timeline_interval.html';
-
-export function TimelineInterval($timeout) {
- return {
- restrict: 'E',
- scope: {
- // The interval model
- model: '=',
- changeInterval: '=',
- },
- template,
- link: function ($scope, $elem) {
- $scope.intervalOptions = ['auto', '1s', '1m', '1h', '1d', '1w', '1M', '1y', 'other'];
- $scope.intervalLabels = {
- auto: 'auto',
- '1s': '1 second',
- '1m': '1 minute',
- '1h': '1 hour',
- '1d': '1 day',
- '1w': '1 week',
- '1M': '1 month',
- '1y': '1 year',
- other: 'other',
- };
-
- $scope.$watch('model', function (newVal, oldVal) {
- // Only run this on initialization
- if (newVal !== oldVal || oldVal == null) return;
-
- if (_.includes($scope.intervalOptions, newVal)) {
- $scope.interval = newVal;
- } else {
- $scope.interval = 'other';
- }
-
- if (newVal !== 'other') {
- $scope.otherInterval = newVal;
- }
- });
-
- $scope.$watch('interval', function (newVal, oldVal) {
- if (newVal === oldVal || $scope.model === newVal) return;
-
- if (newVal === 'other') {
- $scope.otherInterval = oldVal;
- $scope.changeInterval($scope.otherInterval);
- $timeout(function () {
- $('input', $elem).select();
- }, 0);
- } else {
- $scope.otherInterval = $scope.interval;
- $scope.changeInterval($scope.interval);
- }
- });
-
- $scope.$watch('otherInterval', function (newVal, oldVal) {
- if (newVal === oldVal || $scope.model === newVal) return;
- $scope.changeInterval(newVal);
- });
- },
- };
-}
diff --git a/src/plugins/timeline/public/directives/timeline_load_sheet.js b/src/plugins/timeline/public/directives/timeline_load_sheet.js
deleted file mode 100644
index 718d090133e7..000000000000
--- a/src/plugins/timeline/public/directives/timeline_load_sheet.js
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import template from '../partials/load_sheet.html';
-
-export function initTimelineLoadSheetDirective(app) {
- app.directive('timelineLoad', function () {
- return {
- replace: true,
- restrict: 'E',
- template,
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/timeline_options_sheet.js b/src/plugins/timeline/public/directives/timeline_options_sheet.js
deleted file mode 100644
index 485869f5fcf8..000000000000
--- a/src/plugins/timeline/public/directives/timeline_options_sheet.js
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import template from '../partials/sheet_options.html';
-
-export function initTimelineOptionsSheetDirective(app) {
- app.directive('timelineOptions', function () {
- return {
- replace: true,
- restrict: 'E',
- template,
- };
- });
-}
diff --git a/src/plugins/timeline/public/directives/timeline_save_sheet.js b/src/plugins/timeline/public/directives/timeline_save_sheet.js
deleted file mode 100644
index 80ffe3c4e294..000000000000
--- a/src/plugins/timeline/public/directives/timeline_save_sheet.js
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import saveTemplate from '../partials/save_sheet.html';
-
-export function initTimelineSaveSheetDirective(app) {
- app.directive('timelineSave', function () {
- return {
- replace: true,
- restrict: 'E',
- template: saveTemplate,
- };
- });
-}
diff --git a/src/plugins/timeline/public/index.html b/src/plugins/timeline/public/index.html
deleted file mode 100644
index 1b116e54479b..000000000000
--- a/src/plugins/timeline/public/index.html
+++ /dev/null
@@ -1,95 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/plugins/timeline/public/index.scss b/src/plugins/timeline/public/index.scss
deleted file mode 100644
index 8c2a25c383a6..000000000000
--- a/src/plugins/timeline/public/index.scss
+++ /dev/null
@@ -1,18 +0,0 @@
-/* Timeline plugin styles */
-
-// Prefix all styles with "tim" to avoid conflicts.
-// Examples
-// timChart
-// timChart__legend
-// timChart__legend--small
-// timChart__legend-isLoading
-
-@import "./app";
-@import "./base";
-@import "./directives/index";
-
-// these styles is needed to be loaded here explicitly if the timeline visualization was not opened in browser
-// styles for timeline visualization are lazy loaded only while a vis is opened
-// this will duplicate styles only if both Timeline app and timeline visualization are loaded
-// could be left here as it is since the Timeline app is deprecated
-@import "../../vis_type_timeline/public/components/timeline_vis";
diff --git a/src/plugins/timeline/public/index.ts b/src/plugins/timeline/public/index.ts
deleted file mode 100644
index f4b35580b7d1..000000000000
--- a/src/plugins/timeline/public/index.ts
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { PluginInitializerContext } from 'opensearch-dashboards/public';
-import { TimelinePlugin as Plugin } from './plugin';
-
-export function plugin(initializerContext: PluginInitializerContext) {
- return new Plugin(initializerContext);
-}
diff --git a/src/plugins/timeline/public/lib/observe_resize.js b/src/plugins/timeline/public/lib/observe_resize.js
deleted file mode 100644
index 32a582b19be8..000000000000
--- a/src/plugins/timeline/public/lib/observe_resize.js
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-export default function ($elem, fn, frequency) {
- frequency = frequency || 500;
- let currentHeight = $elem.height();
- let currentWidth = $elem.width();
-
- let timeout;
-
- function checkLoop() {
- timeout = setTimeout(function () {
- if (currentHeight !== $elem.height() || currentWidth !== $elem.width()) {
- currentHeight = $elem.height();
- currentWidth = $elem.width();
-
- if (currentWidth > 0 && currentWidth > 0) fn();
- }
- checkLoop();
- }, frequency);
- }
-
- checkLoop();
-
- return function () {
- clearTimeout(timeout);
- };
-}
diff --git a/src/plugins/timeline/public/panels/panel.ts b/src/plugins/timeline/public/panels/panel.ts
deleted file mode 100644
index bff7b49ab9f9..000000000000
--- a/src/plugins/timeline/public/panels/panel.ts
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { i18n } from '@osd/i18n';
-
-interface PanelConfig {
- help?: string;
- render?: Function;
-}
-
-export class Panel {
- name: string;
- help: string;
- render: Function | undefined;
-
- constructor(name: string, config: PanelConfig) {
- this.name = name;
- this.help = config.help || '';
- this.render = config.render;
-
- if (!config.render) {
- throw new Error(
- i18n.translate('timeline.panels.noRenderFunctionErrorMessage', {
- defaultMessage: 'Panel must have a rendering function',
- })
- );
- }
- }
-}
diff --git a/src/plugins/timeline/public/panels/timechart/schema.ts b/src/plugins/timeline/public/panels/timechart/schema.ts
deleted file mode 100644
index d18c5337440d..000000000000
--- a/src/plugins/timeline/public/panels/timechart/schema.ts
+++ /dev/null
@@ -1,414 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import _ from 'lodash';
-import $ from 'jquery';
-import moment from 'moment-timezone';
-// @ts-ignore
-import observeResize from '../../lib/observe_resize';
-import {
- calculateInterval,
- DEFAULT_TIME_FORMAT,
- tickFormatters,
- xaxisFormatterProvider,
- generateTicksProvider,
-} from '../../../../vis_type_timeline/public';
-import { TimelineVisualizationDependencies } from '../../application';
-
-const DEBOUNCE_DELAY = 50;
-
-export function timechartFn(dependencies: TimelineVisualizationDependencies) {
- const {
- $rootScope,
- $compile,
- uiSettings,
- data: {
- query: { timefilter },
- },
- } = dependencies;
-
- return function () {
- return {
- help: 'Draw a timeseries chart',
- render($scope: any, $elem: any) {
- const template = '
';
- const formatters = tickFormatters() as any;
- const getxAxisFormatter = xaxisFormatterProvider(uiSettings);
- const generateTicks = generateTicksProvider();
-
- // TODO: I wonder if we should supply our own moment that sets this every time?
- // could just use angular's injection to provide a moment service?
- moment.tz.setDefault(uiSettings.get('dateFormat:tz'));
-
- const render = $scope.seriesList.render || {};
-
- $scope.chart = $scope.seriesList.list;
- $scope.interval = $scope.interval;
- $scope.search = $scope.search || _.noop;
-
- let legendValueNumbers: any;
- let legendCaption: any;
- const debouncedSetLegendNumbers = _.debounce(setLegendNumbers, DEBOUNCE_DELAY, {
- maxWait: DEBOUNCE_DELAY,
- leading: true,
- trailing: false,
- });
- // ensure legend is the same height with or without a caption so legend items do not move around
- const emptyCaption = ' ';
-
- const defaultOptions = {
- xaxis: {
- mode: 'time',
- tickLength: 5,
- timezone: 'browser',
- },
- selection: {
- mode: 'x',
- color: '#ccc',
- },
- crosshair: {
- mode: 'x',
- color: '#C66',
- lineWidth: 2,
- },
- grid: {
- show: render.grid,
- borderWidth: 0,
- borderColor: null,
- margin: 10,
- hoverable: true,
- autoHighlight: false,
- },
- legend: {
- backgroundColor: 'rgb(255,255,255,0)',
- position: 'nw',
- labelBoxBorderColor: 'rgb(255,255,255,0)',
- labelFormatter(label: any, series: any) {
- const wrapperSpan = document.createElement('span');
- const labelSpan = document.createElement('span');
- const numberSpan = document.createElement('span');
-
- wrapperSpan.setAttribute('class', 'ngLegendValue');
- wrapperSpan.setAttribute('osd-accessible-click', '');
- wrapperSpan.setAttribute('ng-click', `toggleSeries(${series._id})`);
- wrapperSpan.setAttribute('ng-focus', `focusSeries(${series._id})`);
- wrapperSpan.setAttribute('ng-mouseover', `highlightSeries(${series._id})`);
-
- labelSpan.setAttribute('ng-non-bindable', '');
- labelSpan.appendChild(document.createTextNode(label));
- numberSpan.setAttribute('class', 'ngLegendValueNumber');
-
- wrapperSpan.appendChild(labelSpan);
- wrapperSpan.appendChild(numberSpan);
-
- return wrapperSpan.outerHTML;
- },
- },
- colors: [
- '#01A4A4',
- '#C66',
- '#D0D102',
- '#616161',
- '#00A1CB',
- '#32742C',
- '#F18D05',
- '#113F8C',
- '#61AE24',
- '#D70060',
- ],
- };
-
- const originalColorMap = new Map();
- $scope.chart.forEach((series: any, seriesIndex: any) => {
- if (!series.color) {
- const colorIndex = seriesIndex % defaultOptions.colors.length;
- series.color = defaultOptions.colors[colorIndex];
- }
- originalColorMap.set(series, series.color);
- });
-
- let highlightedSeries: any;
- let focusedSeries: any;
- function unhighlightSeries() {
- if (highlightedSeries === null) {
- return;
- }
-
- highlightedSeries = null;
- focusedSeries = null;
- $scope.chart.forEach((series: any) => {
- series.color = originalColorMap.get(series); // reset the colors
- });
- drawPlot($scope.chart);
- }
- $scope.highlightSeries = _.debounce(function (id: any) {
- if (highlightedSeries === id) {
- return;
- }
-
- highlightedSeries = id;
- $scope.chart.forEach((series: any, seriesIndex: any) => {
- if (seriesIndex !== id) {
- series.color = 'rgba(128,128,128,0.1)'; // mark as grey
- } else {
- series.color = originalColorMap.get(series); // color it like it was
- }
- });
- drawPlot($scope.chart);
- }, DEBOUNCE_DELAY);
- $scope.focusSeries = function (id: any) {
- focusedSeries = id;
- $scope.highlightSeries(id);
- };
-
- $scope.toggleSeries = function (id: any) {
- const series = $scope.chart[id];
- series._hide = !series._hide;
- drawPlot($scope.chart);
- };
-
- const cancelResize = observeResize($elem, function () {
- drawPlot($scope.chart);
- });
-
- $scope.$on('$destroy', function () {
- cancelResize();
- $elem.off('plothover');
- $elem.off('plotselected');
- $elem.off('mouseleave');
- });
-
- $elem.on('plothover', function (event: any, pos: any, item: any) {
- $rootScope.$broadcast('timelinePlotHover', event, pos, item);
- });
-
- $elem.on('plotselected', function (event: any, ranges: any) {
- timefilter.timefilter.setTime({
- from: moment(ranges.xaxis.from),
- to: moment(ranges.xaxis.to),
- });
- });
-
- $elem.on('mouseleave', function () {
- $rootScope.$broadcast('timelinePlotLeave');
- });
-
- $scope.$on('timelinePlotHover', function (angularEvent: any, flotEvent: any, pos: any) {
- if (!$scope.plot) return;
- $scope.plot.setCrosshair(pos);
- debouncedSetLegendNumbers(pos);
- });
-
- $scope.$on('timelinePlotLeave', function () {
- if (!$scope.plot) return;
- $scope.plot.clearCrosshair();
- clearLegendNumbers();
- });
-
- // Shamelessly borrowed from the flotCrosshairs example
- function setLegendNumbers(pos: any) {
- unhighlightSeries();
-
- const plot = $scope.plot;
-
- const axes = plot.getAxes();
- if (pos.x < axes.xaxis.min || pos.x > axes.xaxis.max) {
- return;
- }
-
- let i;
- const dataset = plot.getData();
- if (legendCaption) {
- legendCaption.text(
- moment(pos.x).format(
- _.get(dataset, '[0]._global.legend.timeFormat', DEFAULT_TIME_FORMAT)
- )
- );
- }
- for (i = 0; i < dataset.length; ++i) {
- const series = dataset[i];
- const useNearestPoint = series.lines.show && !series.lines.steps;
- const precision = _.get(series, '_meta.precision', 2);
-
- if (series._hide) continue;
-
- const currentPoint = series.data.find((point: any, index: number) => {
- if (index + 1 === series.data.length) {
- return true;
- }
- if (useNearestPoint) {
- return pos.x - point[0] < series.data[index + 1][0] - pos.x;
- } else {
- return pos.x < series.data[index + 1][0];
- }
- });
-
- const y = currentPoint[1];
-
- if (y != null) {
- let label = y.toFixed(precision);
- if (series.yaxis.tickFormatter) {
- label = series.yaxis.tickFormatter(label, series.yaxis);
- }
- legendValueNumbers.eq(i).text(`(${label})`);
- } else {
- legendValueNumbers.eq(i).empty();
- }
- }
- }
-
- function clearLegendNumbers() {
- if (legendCaption) {
- legendCaption.html(emptyCaption);
- }
- _.each(legendValueNumbers, function (num) {
- $(num).empty();
- });
- }
-
- let legendScope = $scope.$new();
- function drawPlot(plotConfig: any) {
- if (!$('.chart-canvas', $elem).length) $elem.html(template);
- const canvasElem = $('.chart-canvas', $elem);
-
- // we can't use `$.plot` to draw the chart when the height or width is 0
- // so, we'll need another event to trigger drawPlot to actually draw it
- if (canvasElem.height() === 0 || canvasElem.width() === 0) {
- return;
- }
-
- const title = _(plotConfig).map('_title').compact().last() as any;
- $('.chart-top-title', $elem).text(title == null ? '' : title);
-
- const options = _.cloneDeep(defaultOptions) as any;
-
- // Get the X-axis tick format
- const time = timefilter.timefilter.getBounds() as any;
- const interval = calculateInterval(
- time.min.valueOf(),
- time.max.valueOf(),
- uiSettings.get('timeline:target_buckets') || 200,
- $scope.interval,
- uiSettings.get('timeline:min_interval') || '1ms'
- );
- const format = getxAxisFormatter(interval);
-
- // Use moment to format ticks so we get timezone correction
- options.xaxis.tickFormatter = function (val: any) {
- return moment(val).format(format);
- };
-
- // Calculate how many ticks can fit on the axis
- const tickLetterWidth = 7;
- const tickPadding = 45;
- options.xaxis.ticks = Math.floor(
- $elem.width() / (format.length * tickLetterWidth + tickPadding)
- );
-
- const series = _.map(plotConfig, function (serie: any, index) {
- serie = _.cloneDeep(
- _.defaults(serie, {
- shadowSize: 0,
- lines: {
- lineWidth: 3,
- },
- })
- );
- serie._id = index;
-
- if (serie.color) {
- const span = document.createElement('span');
- span.style.color = serie.color;
- serie.color = span.style.color;
- }
-
- if (serie._hide) {
- serie.data = [];
- serie.stack = false;
- // serie.color = "#ddd";
- serie.label = '(hidden) ' + serie.label;
- }
-
- if (serie._global) {
- _.mergeWith(options, serie._global, function (objVal, srcVal) {
- // This is kind of gross, it means that you can't replace a global value with a null
- // best you can do is an empty string. Deal with it.
- if (objVal == null) return srcVal;
- if (srcVal == null) return objVal;
- });
- }
-
- return serie;
- });
-
- if (options.yaxes) {
- options.yaxes.forEach((yaxis: any) => {
- if (yaxis && yaxis.units) {
- yaxis.tickFormatter = formatters[yaxis.units.type];
- const byteModes = ['bytes', 'bytes/s'];
- if (byteModes.includes(yaxis.units.type)) {
- yaxis.tickGenerator = generateTicks;
- }
- }
- });
- }
-
- // @ts-ignore
- $scope.plot = $.plot(canvasElem, _.compact(series), options);
-
- if ($scope.plot) {
- $scope.$emit('timelineChartRendered');
- }
-
- legendScope.$destroy();
- legendScope = $scope.$new();
- // Used to toggle the series, and for displaying values on hover
- legendValueNumbers = canvasElem.find('.ngLegendValueNumber');
- _.each(canvasElem.find('.ngLegendValue'), function (elem) {
- $compile(elem)(legendScope);
- });
-
- if (_.get($scope.plot.getData(), '[0]._global.legend.showTime', true)) {
- legendCaption = $(' ');
- legendCaption.html(emptyCaption);
- canvasElem.find('div.legend table').append(legendCaption);
-
- // legend has been re-created. Apply focus on legend element when previously set
- if (focusedSeries || focusedSeries === 0) {
- const $legendLabels = canvasElem.find('div.legend table .legendLabel>span');
- $legendLabels.get(focusedSeries).focus();
- }
- }
- }
- $scope.$watch('chart', drawPlot);
- },
- };
- };
-}
diff --git a/src/plugins/timeline/public/panels/timechart/timechart.ts b/src/plugins/timeline/public/panels/timechart/timechart.ts
deleted file mode 100644
index 176d22e1016e..000000000000
--- a/src/plugins/timeline/public/panels/timechart/timechart.ts
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { timechartFn } from './schema';
-import { Panel } from '../panel';
-import { TimelineVisualizationDependencies } from '../../application';
-
-export function getTimeChart(dependencies: TimelineVisualizationDependencies) {
- // Schema is broken out so that it may be extended for use in other plugins
- // Its also easier to test.
- return new Panel('timechart', timechartFn(dependencies)());
-}
diff --git a/src/plugins/timeline/public/partials/load_sheet.html b/src/plugins/timeline/public/partials/load_sheet.html
deleted file mode 100644
index 5e2c91e7627f..000000000000
--- a/src/plugins/timeline/public/partials/load_sheet.html
+++ /dev/null
@@ -1,12 +0,0 @@
-
diff --git a/src/plugins/timeline/public/partials/save_sheet.html b/src/plugins/timeline/public/partials/save_sheet.html
deleted file mode 100644
index f2a5035a9c53..000000000000
--- a/src/plugins/timeline/public/partials/save_sheet.html
+++ /dev/null
@@ -1,106 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/plugins/timeline/public/partials/sheet_options.html b/src/plugins/timeline/public/partials/sheet_options.html
deleted file mode 100644
index 83f0a122a987..000000000000
--- a/src/plugins/timeline/public/partials/sheet_options.html
+++ /dev/null
@@ -1,36 +0,0 @@
-
diff --git a/src/plugins/timeline/public/plugin.ts b/src/plugins/timeline/public/plugin.ts
deleted file mode 100644
index b6141d2c23e2..000000000000
--- a/src/plugins/timeline/public/plugin.ts
+++ /dev/null
@@ -1,162 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { BehaviorSubject } from 'rxjs';
-import { filter, map } from 'rxjs/operators';
-import {
- CoreSetup,
- CoreStart,
- Plugin,
- PluginInitializerContext,
- DEFAULT_APP_CATEGORIES,
- AppMountParameters,
- AppUpdater,
- ScopedHistory,
- AppNavLinkStatus,
-} from '../../../core/public';
-import { Panel } from './panels/panel';
-import {
- initAngularBootstrap,
- OpenSearchDashboardsLegacyStart,
-} from '../../opensearch_dashboards_legacy/public';
-import { createOsdUrlTracker } from '../../opensearch_dashboards_utils/public';
-import { DataPublicPluginStart, opensearchFilters, DataPublicPluginSetup } from '../../data/public';
-import { NavigationPublicPluginStart } from '../../navigation/public';
-import { VisualizationsStart } from '../../visualizations/public';
-import {
- VisTypeTimelinePluginStart,
- VisTypeTimelinePluginSetup,
-} from '../../vis_type_timeline/public';
-
-export interface TimelinePluginDependencies {
- data: DataPublicPluginStart;
- navigation: NavigationPublicPluginStart;
- visualizations: VisualizationsStart;
- visTypeTimeline: VisTypeTimelinePluginStart;
-}
-
-/** @internal */
-export class TimelinePlugin implements Plugin {
- initializerContext: PluginInitializerContext;
- private appStateUpdater = new BehaviorSubject(() => ({}));
- private stopUrlTracking: (() => void) | undefined = undefined;
- private currentHistory: ScopedHistory | undefined = undefined;
-
- constructor(initializerContext: PluginInitializerContext) {
- this.initializerContext = initializerContext;
- }
-
- public setup(
- core: CoreSetup,
- {
- data,
- visTypeTimeline,
- }: { data: DataPublicPluginSetup; visTypeTimeline: VisTypeTimelinePluginSetup }
- ) {
- const timelinePanels: Map = new Map();
-
- const { appMounted, appUnMounted, stop: stopUrlTracker } = createOsdUrlTracker({
- baseUrl: core.http.basePath.prepend('/app/timeline'),
- defaultSubUrl: '#/',
- storageKey: `lastUrl:${core.http.basePath.get()}:timeline`,
- navLinkUpdater$: this.appStateUpdater,
- toastNotifications: core.notifications.toasts,
- stateParams: [
- {
- osdUrlKey: '_g',
- stateUpdate$: data.query.state$.pipe(
- filter(
- ({ changes }) => !!(changes.globalFilters || changes.time || changes.refreshInterval)
- ),
- map(({ state }) => ({
- ...state,
- filters: state.filters?.filter(opensearchFilters.isFilterPinned),
- }))
- ),
- },
- ],
- getHistory: () => this.currentHistory!,
- });
-
- this.stopUrlTracking = () => {
- stopUrlTracker();
- };
-
- initAngularBootstrap();
- core.application.register({
- id: 'timelion',
- title: 'Timeline',
- order: 8000,
- defaultPath: '#/',
- euiIconType: 'inputOutput',
- category: DEFAULT_APP_CATEGORIES.opensearchDashboards,
- navLinkStatus:
- visTypeTimeline.isUiEnabled === false ? AppNavLinkStatus.hidden : AppNavLinkStatus.default,
- mount: async (params: AppMountParameters) => {
- const [coreStart, pluginsStart] = await core.getStartServices();
- this.currentHistory = params.history;
-
- appMounted();
-
- const unlistenParentHistory = params.history.listen(() => {
- window.dispatchEvent(new HashChangeEvent('hashchange'));
- });
-
- const { renderApp } = await import('./application');
- params.element.classList.add('timelineAppContainer');
- const unmount = renderApp({
- mountParams: params,
- pluginInitializerContext: this.initializerContext,
- timelinePanels,
- core: coreStart,
- plugins: pluginsStart as TimelinePluginDependencies,
- });
- return () => {
- unlistenParentHistory();
- unmount();
- appUnMounted();
- };
- },
- });
- }
-
- public start(
- core: CoreStart,
- { opensearchDashboardsLegacy }: { opensearchDashboardsLegacy: OpenSearchDashboardsLegacyStart }
- ) {
- opensearchDashboardsLegacy.loadFontAwesome();
- }
-
- public stop(): void {
- if (this.stopUrlTracking) {
- this.stopUrlTracking();
- }
- }
-}
diff --git a/src/plugins/timeline/public/services/_saved_sheet.ts b/src/plugins/timeline/public/services/_saved_sheet.ts
deleted file mode 100644
index 06353b63388d..000000000000
--- a/src/plugins/timeline/public/services/_saved_sheet.ts
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { IUiSettingsClient } from 'opensearch-dashboards/public';
-import {
- createSavedObjectClass,
- SavedObjectOpenSearchDashboardsServices,
-} from '../../../saved_objects/public';
-
-// Used only by the savedSheets service, usually no reason to change this
-export function createSavedSheetClass(
- services: SavedObjectOpenSearchDashboardsServices,
- config: IUiSettingsClient
-) {
- const SavedObjectClass = createSavedObjectClass(services);
-
- class SavedSheet extends SavedObjectClass {
- static type = 'timelion-sheet';
-
- // if type:sheet has no mapping, we push this mapping into OpenSearch
- static mapping = {
- title: 'text',
- hits: 'integer',
- description: 'text',
- timelion_sheet: 'text',
- timelion_interval: 'keyword',
- timelion_other_interval: 'keyword',
- timelion_chart_height: 'integer',
- timelion_columns: 'integer',
- timelion_rows: 'integer',
- version: 'integer',
- };
-
- // Order these fields to the top, the rest are alphabetical
- static fieldOrder = ['title', 'description'];
- // SavedSheet constructor. Usually you'd interact with an instance of this.
- // ID is option, without it one will be generated on save.
- constructor(id: string) {
- super({
- type: SavedSheet.type,
- mapping: SavedSheet.mapping,
-
- // if this is null/undefined then the SavedObject will be assigned the defaults
- id,
-
- // default values that will get assigned if the doc is new
- defaults: {
- title: 'New Timeline Sheet',
- hits: 0,
- description: '',
- timelion_sheet: ['.opensearch(*)'],
- timelion_interval: 'auto',
- timelion_chart_height: 275,
- timelion_columns: config.get('timeline:default_columns') || 2,
- timelion_rows: config.get('timeline:default_rows') || 2,
- version: 1,
- },
- });
- this.showInRecentlyAccessed = true;
- this.getFullPath = () => `/app/timeline#/${this.id}`;
- }
- }
-
- return SavedSheet;
-}
diff --git a/src/plugins/timeline/public/services/saved_sheets.ts b/src/plugins/timeline/public/services/saved_sheets.ts
deleted file mode 100644
index 4da4d7b9ed94..000000000000
--- a/src/plugins/timeline/public/services/saved_sheets.ts
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { SavedObjectLoader } from '../../../saved_objects/public';
-import { createSavedSheetClass } from './_saved_sheet';
-import { RenderDeps } from '../application';
-
-export function initSavedSheetService(app: angular.IModule, deps: RenderDeps) {
- const savedObjectsClient = deps.core.savedObjects.client;
- const services = {
- savedObjectsClient,
- indexPatterns: deps.plugins.data.indexPatterns,
- search: deps.plugins.data.search,
- chrome: deps.core.chrome,
- overlays: deps.core.overlays,
- };
-
- const SavedSheet = createSavedSheetClass(services, deps.core.uiSettings);
-
- const savedSheetLoader = new SavedObjectLoader(SavedSheet, savedObjectsClient);
- savedSheetLoader.urlFor = (id) => `#/${encodeURIComponent(id)}`;
- // Customize loader properties since adding an 's' on type doesn't work for type 'timelion-sheet'.
- savedSheetLoader.loaderProperties = {
- name: 'timelion-sheet',
- noun: 'Saved Sheets',
- nouns: 'saved sheets',
- };
- // This is the only thing that gets injected into controllers
- app.service('savedSheets', function () {
- return savedSheetLoader;
- });
-
- return savedSheetLoader;
-}
diff --git a/src/plugins/timeline/public/timeline_app_state.ts b/src/plugins/timeline/public/timeline_app_state.ts
deleted file mode 100644
index 62487c2eba03..000000000000
--- a/src/plugins/timeline/public/timeline_app_state.ts
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import {
- createStateContainer,
- syncState,
- IOsdUrlStateStorage,
-} from '../../opensearch_dashboards_utils/public';
-
-import { TimelineAppState, TimelineAppStateTransitions } from './types';
-
-const STATE_STORAGE_KEY = '_a';
-
-interface Arguments {
- osdUrlStateStorage: IOsdUrlStateStorage;
- stateDefaults: TimelineAppState;
-}
-
-export function initTimelineAppState({ stateDefaults, osdUrlStateStorage }: Arguments) {
- const urlState = osdUrlStateStorage.get(STATE_STORAGE_KEY);
- const initialState = {
- ...stateDefaults,
- ...urlState,
- };
-
- /*
- make sure url ('_a') matches initial state
- Initializing appState does two things - first it translates the defaults into AppState,
- second it updates appState based on the url (the url trumps the defaults). This means if
- we update the state format at all and want to handle BWC, we must not only migrate the
- data stored with saved vis, but also any old state in the url.
- */
- osdUrlStateStorage.set(STATE_STORAGE_KEY, initialState, { replace: true });
-
- const stateContainer = createStateContainer(
- initialState,
- {
- set: (state) => (prop, value) => ({ ...state, [prop]: value }),
- updateState: (state) => (newValues) => ({ ...state, ...newValues }),
- }
- );
-
- const { start: startStateSync, stop: stopStateSync } = syncState({
- storageKey: STATE_STORAGE_KEY,
- stateContainer: {
- ...stateContainer,
- set: (state) => {
- if (state) {
- // syncState utils requires to handle incoming "null" value
- stateContainer.set(state);
- }
- },
- },
- stateStorage: osdUrlStateStorage,
- });
-
- // start syncing the appState with the ('_a') url
- startStateSync();
-
- return { stateContainer, stopStateSync };
-}
diff --git a/src/plugins/timeline/public/types.ts b/src/plugins/timeline/public/types.ts
deleted file mode 100644
index c94fef3cff51..000000000000
--- a/src/plugins/timeline/public/types.ts
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-export interface TimelineAppState {
- sheet: string[];
- selected: number;
- columns: number;
- rows: number;
- interval: string;
-}
-
-export interface TimelineAppStateTransitions {
- set: (
- state: TimelineAppState
- ) => (prop: T, value: TimelineAppState[T]) => TimelineAppState;
- updateState: (
- state: TimelineAppState
- ) => (newValues: Partial) => TimelineAppState;
-}
diff --git a/src/plugins/timeline/server/config.ts b/src/plugins/timeline/server/config.ts
deleted file mode 100644
index b98585aaa695..000000000000
--- a/src/plugins/timeline/server/config.ts
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { schema, TypeOf } from '@osd/config-schema';
-
-export const configSchema = {
- schema: schema.object({
- graphiteUrls: schema.maybe(schema.arrayOf(schema.string())),
- enabled: schema.boolean({ defaultValue: true }),
- ui: schema.object({
- enabled: schema.boolean({ defaultValue: true }),
- }),
- }),
-};
-
-export type TimelineConfigType = TypeOf;
diff --git a/src/plugins/timeline/server/index.ts b/src/plugins/timeline/server/index.ts
deleted file mode 100644
index 9b26a79d3a11..000000000000
--- a/src/plugins/timeline/server/index.ts
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { PluginInitializerContext, PluginConfigDescriptor } from 'src/core/server';
-import { TimelinePlugin } from './plugin';
-import { configSchema, TimelineConfigType } from './config';
-
-export const config: PluginConfigDescriptor = {
- schema: configSchema.schema,
-};
-
-export const plugin = (context: PluginInitializerContext) =>
- new TimelinePlugin(context);
diff --git a/src/plugins/timeline/server/plugin.ts b/src/plugins/timeline/server/plugin.ts
deleted file mode 100644
index 2aa14e7dab57..000000000000
--- a/src/plugins/timeline/server/plugin.ts
+++ /dev/null
@@ -1,114 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { CoreSetup, CoreStart, Plugin, PluginInitializerContext, Logger } from 'src/core/server';
-import { i18n } from '@osd/i18n';
-import { schema } from '@osd/config-schema';
-import { TimelineConfigType } from './config';
-import { timelineSheetSavedObjectType } from './saved_objects';
-
-/**
- * Deprecated since 7.0, the Timeline app will be removed in 8.0.
- * To continue using your Timeline worksheets, migrate them to a dashboard.
- **/
-const showWarningMessageIfTimelineSheetWasFound = (core: CoreStart, logger: Logger) => {
- const { savedObjects } = core;
- const savedObjectsClient = savedObjects.createInternalRepository();
-
- savedObjectsClient
- .find({
- type: 'timelion-sheet',
- perPage: 1,
- })
- .then(
- ({ total }) =>
- total &&
- logger.warn(
- 'Deprecated since 7.0, the Timeline app will be removed in 8.0. To continue using your Timeline worksheets, migrate them to a dashboard.'
- )
- );
-};
-
-export class TimelinePlugin implements Plugin {
- private logger: Logger;
-
- constructor(context: PluginInitializerContext) {
- this.logger = context.logger.get();
- }
-
- public setup(core: CoreSetup) {
- core.capabilities.registerProvider(() => ({
- timelion: {
- save: true,
- },
- }));
- core.savedObjects.registerType(timelineSheetSavedObjectType);
-
- core.uiSettings.register({
- 'timeline:showTutorial': {
- name: i18n.translate('timeline.uiSettings.showTutorialLabel', {
- defaultMessage: 'Show tutorial',
- }),
- value: false,
- description: i18n.translate('timeline.uiSettings.showTutorialDescription', {
- defaultMessage: 'Should I show the tutorial by default when entering the timeline app?',
- }),
- category: ['timeline'],
- schema: schema.boolean(),
- },
- 'timeline:default_columns': {
- name: i18n.translate('timeline.uiSettings.defaultColumnsLabel', {
- defaultMessage: 'Default columns',
- }),
- value: 2,
- description: i18n.translate('timeline.uiSettings.defaultColumnsDescription', {
- defaultMessage: 'Number of columns on a timeline sheet by default',
- }),
- category: ['timeline'],
- schema: schema.number(),
- },
- 'timeline:default_rows': {
- name: i18n.translate('timeline.uiSettings.defaultRowsLabel', {
- defaultMessage: 'Default rows',
- }),
- value: 2,
- description: i18n.translate('timeline.uiSettings.defaultRowsDescription', {
- defaultMessage: 'Number of rows on a timeline sheet by default',
- }),
- category: ['timeline'],
- schema: schema.number(),
- },
- });
- }
- start(core: CoreStart) {
- showWarningMessageIfTimelineSheetWasFound(core, this.logger);
- }
- stop() {}
-}
diff --git a/src/plugins/timeline/server/saved_objects/index.ts b/src/plugins/timeline/server/saved_objects/index.ts
deleted file mode 100644
index f0546d981aff..000000000000
--- a/src/plugins/timeline/server/saved_objects/index.ts
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-export { timelineSheetSavedObjectType } from './timeline_sheet';
diff --git a/src/plugins/timeline/server/saved_objects/timeline_sheet.ts b/src/plugins/timeline/server/saved_objects/timeline_sheet.ts
deleted file mode 100644
index 878a4d542db5..000000000000
--- a/src/plugins/timeline/server/saved_objects/timeline_sheet.ts
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { SavedObjectsType } from 'opensearch-dashboards/server';
-
-export const timelineSheetSavedObjectType: SavedObjectsType = {
- name: 'timelion-sheet',
- hidden: false,
- namespaceType: 'single',
- mappings: {
- properties: {
- description: { type: 'text' },
- hits: { type: 'integer' },
- kibanaSavedObjectMeta: {
- properties: {
- searchSourceJSON: { type: 'text' },
- },
- },
- timelion_chart_height: { type: 'integer' },
- timelion_columns: { type: 'integer' },
- timelion_interval: { type: 'keyword' },
- timelion_other_interval: { type: 'keyword' },
- timelion_rows: { type: 'integer' },
- timelion_sheet: { type: 'text' },
- title: { type: 'text' },
- version: { type: 'integer' },
- },
- },
-};
diff --git a/src/plugins/ui_actions/public/actions/action.ts b/src/plugins/ui_actions/public/actions/action.ts
index b38e2bd4e40f..76fc2ddb3bed 100644
--- a/src/plugins/ui_actions/public/actions/action.ts
+++ b/src/plugins/ui_actions/public/actions/action.ts
@@ -92,7 +92,7 @@ export interface Action
* Returns a title to be displayed to the user.
* @param context
*/
- getDisplayName(context: ActionExecutionContext): string;
+ getDisplayName(context: ActionExecutionContext): JSX.Element | string;
/**
* `UiComponent` to render when displaying this action as a context menu item.
diff --git a/src/plugins/ui_actions/public/actions/action_internal.ts b/src/plugins/ui_actions/public/actions/action_internal.ts
index fb39a01ed698..5610051dc3f7 100644
--- a/src/plugins/ui_actions/public/actions/action_internal.ts
+++ b/src/plugins/ui_actions/public/actions/action_internal.ts
@@ -59,7 +59,7 @@ export class ActionInternal
return this.definition.getIconType(context);
}
- public getDisplayName(context: Context ): string {
+ public getDisplayName(context: Context ): JSX.Element | string {
if (!this.definition.getDisplayName) return `Action: ${this.id}`;
return this.definition.getDisplayName(context);
}
diff --git a/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts b/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts
index 949595d60939..b9afca9fb99c 100644
--- a/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts
+++ b/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts
@@ -36,20 +36,28 @@ const createTestAction = ({
type,
dispayName,
order,
+ grouping,
}: {
type?: string;
dispayName: string;
order?: number;
+ grouping?: any[];
}) =>
createAction({
type: type as any, // mapping doesn't matter for this test
getDisplayName: () => dispayName,
order,
execute: async () => {},
+ grouping,
});
const resultMapper = (panel: EuiContextMenuPanelDescriptor) => ({
- items: panel.items ? panel.items.map((item) => ({ name: item.name })) : [],
+ items: panel.items
+ ? panel.items.map((item) => ({
+ ...(item.name ? { name: item.name } : {}),
+ ...(item.isSeparator ? { isSeparator: true } : {}),
+ }))
+ : [],
});
test('sorts items in DESC order by "order" field first, then by display name', async () => {
@@ -248,3 +256,195 @@ test('hides items behind in "More" submenu if there are more than 4 actions', as
]
`);
});
+
+test('flattening of group with only one action', async () => {
+ const grouping1 = [
+ {
+ id: 'test-group',
+ getDisplayName: () => 'Test group',
+ getIconType: () => 'bell',
+ },
+ ];
+ const actions = [
+ createTestAction({
+ dispayName: 'Foo 1',
+ }),
+ createTestAction({
+ dispayName: 'Bar 1',
+ grouping: grouping1,
+ }),
+ ];
+ const menu = await buildContextMenuForActions({
+ actions: actions.map((action) => ({ action, context: {}, trigger: 'TEST' as any })),
+ });
+
+ expect(menu.map(resultMapper)).toMatchInlineSnapshot(`
+ Array [
+ Object {
+ "items": Array [
+ Object {
+ "name": "Foo 1",
+ },
+ Object {
+ "isSeparator": true,
+ },
+ Object {
+ "name": "Bar 1",
+ },
+ ],
+ },
+ Object {
+ "items": Array [
+ Object {
+ "name": "Bar 1",
+ },
+ ],
+ },
+ ]
+ `);
+});
+
+test('grouping with only two actions', async () => {
+ const grouping1 = [
+ {
+ id: 'test-group',
+ getDisplayName: () => 'Test group',
+ getIconType: () => 'bell',
+ },
+ ];
+ const actions = [
+ createTestAction({
+ dispayName: 'Foo 1',
+ }),
+ createTestAction({
+ dispayName: 'Bar 1',
+ grouping: grouping1,
+ }),
+ createTestAction({
+ dispayName: 'Bar 2',
+ grouping: grouping1,
+ }),
+ ];
+ const menu = await buildContextMenuForActions({
+ actions: actions.map((action) => ({ action, context: {}, trigger: 'TEST' as any })),
+ });
+
+ expect(menu.map(resultMapper)).toMatchInlineSnapshot(`
+ Array [
+ Object {
+ "items": Array [
+ Object {
+ "name": "Foo 1",
+ },
+ Object {
+ "isSeparator": true,
+ },
+ Object {
+ "name": "Test group",
+ },
+ ],
+ },
+ Object {
+ "items": Array [
+ Object {
+ "name": "Bar 1",
+ },
+ Object {
+ "name": "Bar 2",
+ },
+ ],
+ },
+ ]
+ `);
+});
+
+test('groups with deep nesting', async () => {
+ const grouping1 = [
+ {
+ id: 'test-group',
+ getDisplayName: () => 'Test group',
+ getIconType: () => 'bell',
+ },
+ ];
+ const grouping2 = [
+ {
+ id: 'test-group-2',
+ getDisplayName: () => 'Test group 2',
+ getIconType: () => 'bell',
+ },
+ {
+ id: 'test-group-3',
+ getDisplayName: () => 'Test group 3',
+ getIconType: () => 'bell',
+ },
+ ];
+
+ const actions = [
+ createTestAction({
+ dispayName: 'Foo 1',
+ }),
+ createTestAction({
+ dispayName: 'Bar 1',
+ grouping: grouping1,
+ }),
+ createTestAction({
+ dispayName: 'Bar 2',
+ grouping: grouping1,
+ }),
+ createTestAction({
+ dispayName: 'Qux 1',
+ grouping: grouping2,
+ }),
+ ];
+ const menu = await buildContextMenuForActions({
+ actions: actions.map((action) => ({ action, context: {}, trigger: 'TEST' as any })),
+ });
+
+ expect(menu.map(resultMapper)).toMatchInlineSnapshot(`
+ Array [
+ Object {
+ "items": Array [
+ Object {
+ "name": "Foo 1",
+ },
+ Object {
+ "isSeparator": true,
+ },
+ Object {
+ "name": "Test group",
+ },
+ Object {
+ "isSeparator": true,
+ },
+ Object {
+ "name": "Test group 3",
+ },
+ ],
+ },
+ Object {
+ "items": Array [
+ Object {
+ "name": "Bar 1",
+ },
+ Object {
+ "name": "Bar 2",
+ },
+ ],
+ },
+ Object {
+ "items": Array [
+ Object {
+ "name": "Test group 3",
+ },
+ ],
+ },
+ Object {
+ "items": Array [
+ Object {
+ "name": "Qux 1",
+ },
+ ],
+ },
+ ]
+ `);
+});
diff --git a/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.tsx b/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.tsx
index 054900f52b77..6d69be1f3faa 100644
--- a/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.tsx
+++ b/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.tsx
@@ -146,6 +146,7 @@ export async function buildContextMenuForActions({
closeMenu = () => {},
}: BuildContextMenuParams): Promise {
const panels: Record = {
+ // This is the first panel which links out to all others via items property
mainMenu: {
id: 'mainMenu',
title,
@@ -157,35 +158,51 @@ export async function buildContextMenuForActions({
const context: ActionExecutionContext = { ...item.context, trigger: item.trigger };
const isCompatible = await item.action.isCompatible(context);
if (!isCompatible) return;
- let parentPanel = '';
- let currentPanel = '';
+
+ // Reference to the last/parent/upper group.
+ // Groups are provided in order of parent to children.
+ let parentGroupId = '';
+
if (action.grouping) {
for (let i = 0; i < action.grouping.length; i++) {
const group = action.grouping[i];
- currentPanel = group.id;
- if (!panels[currentPanel]) {
+ const groupId = group.id;
+
+ // If a panel does not exist for the current group, then create it
+ if (!panels[groupId]) {
const name = group.getDisplayName ? group.getDisplayName(context) : group.id;
- panels[currentPanel] = {
- id: currentPanel,
+
+ // Create panel for group
+ panels[groupId] = {
+ id: groupId,
title: name,
items: [],
_level: i,
_icon: group.getIconType ? group.getIconType(context) : 'empty',
};
- if (parentPanel) {
- panels[parentPanel].items!.push({
+
+ // If there are multiple groups and this is not the first group,
+ // then add an item to the parent group relating to this group
+ if (parentGroupId) {
+ panels[parentGroupId].items!.push({
name,
- panel: currentPanel,
+ panel: groupId,
icon: group.getIconType ? group.getIconType(context) : 'empty',
_order: group.order || 0,
_title: group.getDisplayName ? group.getDisplayName(context) : '',
});
}
}
- parentPanel = currentPanel;
+
+ // Save the current group, because it will be used as the parent group
+ // for adding items to it for any additional groups in the array
+ parentGroupId = groupId;
}
}
- panels[parentPanel || 'mainMenu'].items!.push({
+
+ // Add a context menu item for this action so it shows up on a context menu panel.
+ // We add this within the parent group or default to the mainMenu panel.
+ panels[parentGroupId || 'mainMenu'].items!.push({
name: action.MenuItem
? React.createElement(uiToReactComponent(action.MenuItem), { context })
: action.getDisplayName(context),
@@ -197,8 +214,10 @@ export async function buildContextMenuForActions({
_title: action.getDisplayName(context),
});
});
+
await Promise.all(promises);
+ // For each panel, sort items by order and title
for (const panel of Object.values(panels)) {
const items = panel.items.filter(Boolean) as ItemDescriptor[];
panel.items = _.sortBy(
@@ -208,13 +227,23 @@ export async function buildContextMenuForActions({
);
}
+ // On the mainMenu, before adding in items for other groups, the first 4 items are shown.
+ // Any additional items are hidden behind a "more" item
wrapMainPanelItemsIntoSubmenu(panels, 'mainMenu');
for (const panel of Object.values(panels)) {
+ // If the panel is a root-level panel, such as the parent of a group,
+ // then create mainMenu item for this panel
if (panel._level === 0) {
- // TODO: Add separator line here once it is available in EUI.
- // See https://github.com/elastic/eui/pull/4018
- if (panel.items.length > 3) {
+ // Add separator with unique key if needed
+ if (panels.mainMenu.items.length) {
+ panels.mainMenu.items.push({ isSeparator: true, key: `${panel.id}separator` });
+ }
+
+ // If a panel has more than one child, then allow items to be grouped
+ // and link to it in the mainMenu. Otherwise, flatten the group.
+ // Note: this only happens on the root level panels, not for inner groups.
+ if (panel.items.length > 1) {
panels.mainMenu.items.push({
name: panel.title || panel.id,
icon: panel._icon || 'empty',
diff --git a/src/plugins/vis_type_timeline/config.ts b/src/plugins/vis_type_timeline/config.ts
index 2d566ed390bd..07c0df4953dc 100644
--- a/src/plugins/vis_type_timeline/config.ts
+++ b/src/plugins/vis_type_timeline/config.ts
@@ -30,15 +30,10 @@
import { schema, TypeOf } from '@osd/config-schema';
-export const configSchema = schema.object(
- {
- enabled: schema.boolean({ defaultValue: true }),
- ui: schema.object({ enabled: schema.boolean({ defaultValue: false }) }),
- graphiteAllowedUrls: schema.maybe(schema.arrayOf(schema.string())),
- graphiteBlockedIPs: schema.maybe(schema.arrayOf(schema.string())),
- },
- // This option should be removed as soon as we entirely migrate config from legacy Timeline plugin.
- { unknowns: 'allow' }
-);
+export const configSchema = schema.object({
+ enabled: schema.boolean({ defaultValue: true }),
+ graphiteAllowedUrls: schema.maybe(schema.arrayOf(schema.string())),
+ graphiteBlockedIPs: schema.maybe(schema.arrayOf(schema.string())),
+});
export type ConfigSchema = TypeOf;
diff --git a/src/plugins/vis_type_timeline/public/plugin.ts b/src/plugins/vis_type_timeline/public/plugin.ts
index a27c9bc783ea..92d466da56a5 100644
--- a/src/plugins/vis_type_timeline/public/plugin.ts
+++ b/src/plugins/vis_type_timeline/public/plugin.ts
@@ -77,16 +77,11 @@ export interface VisTypeTimelinePluginStart {
getArgValueSuggestions: typeof getArgValueSuggestions;
}
-/** @public */
-export interface VisTypeTimelinePluginSetup {
- isUiEnabled: boolean;
-}
-
/** @internal */
export class TimelineVisPlugin
implements
Plugin<
- VisTypeTimelinePluginSetup,
+ void,
VisTypeTimelinePluginStart,
TimelineVisSetupDependencies,
TimelineVisStartDependencies
@@ -106,10 +101,6 @@ export class TimelineVisPlugin
expressions.registerFunction(() => getTimelineVisualizationConfig(dependencies));
expressions.registerRenderer(getTimelineVisRenderer(dependencies));
visualizations.createBaseVisualization(getTimelineVisDefinition(dependencies));
-
- return {
- isUiEnabled: this.initializerContext.config.get().ui.enabled,
- };
}
public start(core: CoreStart, plugins: TimelineVisStartDependencies) {
diff --git a/src/plugins/vis_type_timeline/server/index.ts b/src/plugins/vis_type_timeline/server/index.ts
index 9be2c2083414..3e41475bb8bb 100644
--- a/src/plugins/vis_type_timeline/server/index.ts
+++ b/src/plugins/vis_type_timeline/server/index.ts
@@ -32,13 +32,8 @@ import { PluginConfigDescriptor, PluginInitializerContext } from '../../../core/
import { configSchema, ConfigSchema } from '../config';
import { Plugin } from './plugin';
-export { PluginSetupContract } from './plugin';
-
export const config: PluginConfigDescriptor = {
schema: configSchema,
- exposeToBrowser: {
- ui: true,
- },
deprecations: ({ renameFromRoot, renameFromRootWithoutMap }) => [
// timelion.enabled and timelion_vis.enabled deprecation
renameFromRoot('timelion.enabled', 'vis_type_timeline.enabled'),
diff --git a/src/plugins/vis_type_timeline/server/plugin.ts b/src/plugins/vis_type_timeline/server/plugin.ts
index 88b33536bd99..d2c7097ac419 100644
--- a/src/plugins/vis_type_timeline/server/plugin.ts
+++ b/src/plugins/vis_type_timeline/server/plugin.ts
@@ -47,13 +47,6 @@ const experimentalLabel = i18n.translate('timeline.uiSettings.experimentalLabel'
defaultMessage: 'experimental',
});
-/**
- * Describes public Timeline plugin contract returned at the `setup` stage.
- */
-export interface PluginSetupContract {
- uiEnabled: boolean;
-}
-
export interface TimelinePluginStartDeps {
data: PluginStart;
}
@@ -64,7 +57,7 @@ export interface TimelinePluginStartDeps {
export class Plugin {
constructor(private readonly initializerContext: PluginInitializerContext) {}
- public async setup(core: CoreSetup): Promise> {
+ public async setup(core: CoreSetup): void {
const config = await this.initializerContext.config
.create>()
.pipe(first())
@@ -193,8 +186,6 @@ export class Plugin {
schema: schema.string(),
},
});
-
- return deepFreeze({ uiEnabled: config.ui.enabled });
}
public start() {
diff --git a/src/plugins/vis_type_timeline/server/series_functions/label.js b/src/plugins/vis_type_timeline/server/series_functions/label.js
index c935d537081f..4649ee6cf53f 100644
--- a/src/plugins/vis_type_timeline/server/series_functions/label.js
+++ b/src/plugins/vis_type_timeline/server/series_functions/label.js
@@ -62,10 +62,8 @@ export default new Chainable('label', {
const config = args.byName;
return alter(args, function (eachSeries) {
if (config.regex) {
- // not using a standard `import` so that if there's an issue with the re2 native module
- // that it doesn't prevent OpenSearch Dashboards from starting up and we only have an issue using Timeline labels
- const RE2 = require('re2');
- eachSeries.label = eachSeries.label.replace(new RE2(config.regex), config.label);
+ const regex = new RegExp(config.regex);
+ eachSeries.label = eachSeries.label.replace(regex, config.label);
} else {
eachSeries.label = config.label;
}
diff --git a/src/plugins/vis_type_timeline/server/series_functions/label.test.js b/src/plugins/vis_type_timeline/server/series_functions/label.test.js
index c6dc832914a3..69268b385b07 100644
--- a/src/plugins/vis_type_timeline/server/series_functions/label.test.js
+++ b/src/plugins/vis_type_timeline/server/series_functions/label.test.js
@@ -51,4 +51,24 @@ describe('label.js', () => {
expect(r.output.list[0].label).to.equal('beerative');
});
});
+
+ it('can use a regex to capture groups to modify series label', () => {
+ return invoke(fn, [seriesList, 'beer$2', '(N)(egative)']).then((r) => {
+ expect(r.output.list[0].label).to.equal('beeregative');
+ });
+ });
+
+ it('can handle different regex patterns', () => {
+ const seriesListCopy1 = JSON.parse(JSON.stringify(seriesList));
+ const seriesListCopy2 = JSON.parse(JSON.stringify(seriesList));
+
+ return Promise.all([
+ invoke(fn, [seriesListCopy1, 'beer$1 - $2', '(N)(egative)']).then((r) => {
+ expect(r.output.list[0].label).to.equal('beerN - egative');
+ }),
+ invoke(fn, [seriesListCopy2, 'beer$1_$2', '(N)(eg.*)']).then((r) => {
+ expect(r.output.list[0].label).to.equal('beerN_egative');
+ }),
+ ]);
+ });
});
diff --git a/src/plugins/vis_type_vega/public/__snapshots__/vega_visualization.test.js.snap b/src/plugins/vis_type_vega/public/__snapshots__/vega_visualization.test.js.snap
index 973d539e4751..08a3b99be5ea 100644
--- a/src/plugins/vis_type_vega/public/__snapshots__/vega_visualization.test.js.snap
+++ b/src/plugins/vis_type_vega/public/__snapshots__/vega_visualization.test.js.snap
@@ -1,9 +1,9 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
-exports[`VegaVisualizations VegaVisualization - basics should show vega blank rectangle on top of a map (vegamap) 1`] = `"
"`;
+exports[`VegaVisualizations VegaVisualization - basics should show vega blank rectangle on top of a map (vegamap) 1`] = `
`;
-exports[`VegaVisualizations VegaVisualization - basics should show vega graph (may fail in dev env) 1`] = `""`;
+exports[`VegaVisualizations VegaVisualization - basics should show vega graph (may fail in dev env) 1`] = ``;
-exports[`VegaVisualizations VegaVisualization - basics should show vegalite graph and update on resize (may fail in dev env) 1`] = `""`;
+exports[`VegaVisualizations VegaVisualization - basics should show vegalite graph and update on resize (may fail in dev env) 1`] = ``;
-exports[`VegaVisualizations VegaVisualization - basics should show vegalite graph and update on resize (may fail in dev env) 2`] = `""`;
+exports[`VegaVisualizations VegaVisualization - basics should show vegalite graph and update on resize (may fail in dev env) 2`] = ``;
diff --git a/src/plugins/vis_type_vega/public/vega_visualization.test.js b/src/plugins/vis_type_vega/public/vega_visualization.test.js
index 2d4d648828b0..59ee90108502 100644
--- a/src/plugins/vis_type_vega/public/vega_visualization.test.js
+++ b/src/plugins/vis_type_vega/public/vega_visualization.test.js
@@ -56,6 +56,12 @@ jest.mock('./lib/vega', () => ({
vegaLite: jest.requireActual('vega-lite/src'),
}));
+// This is to remove the time-zone dependent `aria-label` key of "Dec 10/11, 2017" from the snapshot
+expect.addSnapshotSerializer({
+ serialize: (value) => value.replace(/key:\sDec 1[01], 2017;/g, 'key: ;'),
+ test: (value) => typeof value === 'string',
+});
+
// FLAKY: https://github.com/elastic/kibana/issues/71713
describe('VegaVisualizations', () => {
let domNode;
diff --git a/src/plugins/visualizations/server/saved_objects/visualization_migrations.test.ts b/src/plugins/visualizations/server/saved_objects/visualization_migrations.test.ts
index a981ce578c09..570d61ec3b75 100644
--- a/src/plugins/visualizations/server/saved_objects/visualization_migrations.test.ts
+++ b/src/plugins/visualizations/server/saved_objects/visualization_migrations.test.ts
@@ -30,9 +30,20 @@
import { visualizationSavedObjectTypeMigrations } from './visualization_migrations';
import { SavedObjectMigrationContext, SavedObjectMigrationFn } from 'opensearch-dashboards/server';
+import { createReplaceSerializer } from '@osd/dev-utils';
const savedObjectMigrationContext = (null as unknown) as SavedObjectMigrationContext;
+// ToDo: Remove this logic when Node 14 support is removed
+if (process.version.startsWith('v14.')) {
+ expect.addSnapshotSerializer(
+ createReplaceSerializer(
+ /Cannot read property '([^ ]+?)' of undefined/g,
+ "Cannot read properties of undefined (reading '$1')"
+ )
+ );
+}
+
const testMigrateMatchAllQuery = (migrate: Function) => {
it('should migrate obsolete match_all query', () => {
const migratedDoc = migrate({
@@ -1003,7 +1014,7 @@ describe('migration visualization', () => {
`);
expect(logMsgArr).toMatchInlineSnapshot(`
Array [
- "Exception @ migrateGaugeVerticalSplitToAlignment! TypeError: Cannot read property 'gauge' of undefined",
+ "Exception @ migrateGaugeVerticalSplitToAlignment! TypeError: Cannot read properties of undefined (reading 'gauge')",
"Exception @ migrateGaugeVerticalSplitToAlignment! Payload: {\\"type\\":\\"gauge\\"}",
]
`);
diff --git a/tasks/function_test_groups.js b/tasks/function_test_groups.js
index 91f017a437c3..d6df1573a661 100644
--- a/tasks/function_test_groups.js
+++ b/tasks/function_test_groups.js
@@ -33,10 +33,10 @@ import { resolve } from 'path';
import execa from 'execa';
import grunt from 'grunt';
-import { safeLoad } from 'js-yaml';
+import { load } from 'js-yaml';
const JOBS_YAML = readFileSync(resolve(__dirname, '../.ci/jobs.yml'), 'utf8');
-const TEST_TAGS = safeLoad(JOBS_YAML)
+const TEST_TAGS = load(JOBS_YAML)
.JOB.filter((id) => id.startsWith('opensearch-dashboards-ciGroup'))
.map((id) => id.replace(/^opensearch-dashboards-/, ''));
diff --git a/test/api_integration/fixtures/opensearch_archiver/index_patterns/basic_opensearch_dashboards/mappings.json b/test/api_integration/fixtures/opensearch_archiver/index_patterns/basic_opensearch_dashboards/mappings.json
index c357464ef7ad..df28b3f143eb 100644
--- a/test/api_integration/fixtures/opensearch_archiver/index_patterns/basic_opensearch_dashboards/mappings.json
+++ b/test/api_integration/fixtures/opensearch_archiver/index_patterns/basic_opensearch_dashboards/mappings.json
@@ -146,47 +146,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"namespace": {
"type": "keyword"
},
diff --git a/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/relationships/mappings.json b/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/relationships/mappings.json
index f12e6a07b7e1..0f850ee15352 100644
--- a/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/relationships/mappings.json
+++ b/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/relationships/mappings.json
@@ -179,47 +179,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -280,4 +239,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/search/mappings.json b/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/search/mappings.json
index f12e6a07b7e1..0f850ee15352 100644
--- a/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/search/mappings.json
+++ b/test/api_integration/fixtures/opensearch_archiver/management/saved_objects/search/mappings.json
@@ -179,47 +179,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -280,4 +239,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/api_integration/fixtures/opensearch_archiver/saved_objects/10k/mappings.json b/test/api_integration/fixtures/opensearch_archiver/saved_objects/10k/mappings.json
index c357464ef7ad..df28b3f143eb 100644
--- a/test/api_integration/fixtures/opensearch_archiver/saved_objects/10k/mappings.json
+++ b/test/api_integration/fixtures/opensearch_archiver/saved_objects/10k/mappings.json
@@ -146,47 +146,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"namespace": {
"type": "keyword"
},
diff --git a/test/api_integration/fixtures/opensearch_archiver/saved_objects/basic/mappings.json b/test/api_integration/fixtures/opensearch_archiver/saved_objects/basic/mappings.json
index 5777475bbfc4..df28b3f143eb 100644
--- a/test/api_integration/fixtures/opensearch_archiver/saved_objects/basic/mappings.json
+++ b/test/api_integration/fixtures/opensearch_archiver/saved_objects/basic/mappings.json
@@ -146,47 +146,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"namespace": {
"type": "keyword"
},
@@ -250,4 +209,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/api_integration/fixtures/opensearch_archiver/saved_objects/find_edgecases/mappings.json b/test/api_integration/fixtures/opensearch_archiver/saved_objects/find_edgecases/mappings.json
index 5bfb286b5ea6..7ff2743fc4a6 100644
--- a/test/api_integration/fixtures/opensearch_archiver/saved_objects/find_edgecases/mappings.json
+++ b/test/api_integration/fixtures/opensearch_archiver/saved_objects/find_edgecases/mappings.json
@@ -146,47 +146,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"namespace": {
"type": "keyword"
},
diff --git a/test/api_integration/fixtures/opensearch_archiver/search/count/mappings.json b/test/api_integration/fixtures/opensearch_archiver/search/count/mappings.json
index da1e59e86d90..d9638ae749a4 100644
--- a/test/api_integration/fixtures/opensearch_archiver/search/count/mappings.json
+++ b/test/api_integration/fixtures/opensearch_archiver/search/count/mappings.json
@@ -36,48 +36,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"visualization": {
"dynamic": "strict",
"properties": {
@@ -293,4 +251,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/apps/dashboard/dashboard_filtering.js b/test/functional/apps/dashboard/dashboard_filtering.js
index deb2ae399240..b3ff62c8b9da 100644
--- a/test/functional/apps/dashboard/dashboard_filtering.js
+++ b/test/functional/apps/dashboard/dashboard_filtering.js
@@ -126,11 +126,6 @@ export default function ({ getService, getPageObjects }) {
await dashboardExpect.savedSearchRowCount(0);
});
- // TODO: Uncomment once https://github.com/elastic/kibana/issues/22561 is fixed
- // it('timeline is filtered', async () => {
- // await dashboardExpect.timelineLegendCount(0);
- // });
-
it('vega is filtered', async () => {
await dashboardExpect.vegaTextsDoNotExist(['5,000']);
});
@@ -179,11 +174,6 @@ export default function ({ getService, getPageObjects }) {
await dashboardExpect.savedSearchRowCount(0);
});
- // TODO: Uncomment once https://github.com/elastic/kibana/issues/22561 is fixed
- // it('timeline is filtered', async () => {
- // await dashboardExpect.timelineLegendCount(0);
- // });
-
it('vega is filtered', async () => {
await dashboardExpect.vegaTextsDoNotExist(['5,000']);
});
diff --git a/test/functional/apps/timeline/_expression_typeahead.js b/test/functional/apps/timeline/_expression_typeahead.js
deleted file mode 100644
index 5e395ec28a71..000000000000
--- a/test/functional/apps/timeline/_expression_typeahead.js
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import expect from '@osd/expect';
-
-export default function ({ getPageObjects }) {
- const PageObjects = getPageObjects(['common', 'timeline', 'settings', 'timePicker']);
-
- describe('expression typeahead', () => {
- before(async () => {
- await PageObjects.timeline.initTests();
- await PageObjects.timePicker.setDefaultAbsoluteRange();
- });
-
- it('should display function suggestions filtered by function name', async () => {
- await PageObjects.timeline.setExpression('.opensearch');
- const suggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(suggestions.length).to.eql(1);
- expect(suggestions[0].includes('.opensearch()')).to.eql(true);
- });
-
- it('should show argument suggestions when function suggestion is selected', async () => {
- await PageObjects.timeline.setExpression('.opensearch');
- await PageObjects.timeline.clickSuggestion();
- const suggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(suggestions.length).to.eql(10);
- expect(suggestions[0].includes('fit=')).to.eql(true);
- });
-
- it('should show argument value suggestions when argument is selected', async () => {
- await PageObjects.timeline.setExpression('.legend');
- await PageObjects.timeline.clickSuggestion();
- const argumentSuggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(argumentSuggestions.length).to.eql(4);
- expect(argumentSuggestions[1].includes('position=')).to.eql(true);
- await PageObjects.timeline.clickSuggestion(1);
- const valueSuggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(valueSuggestions.length).to.eql(5);
- expect(valueSuggestions[0].includes('disable legend')).to.eql(true);
- expect(valueSuggestions[1].includes('place legend in north east corner')).to.eql(true);
- });
-
- // TODO: [RENAMEME] the index is not being loaded with the default data.
- // While navigating creating an index pattern this would works.
- // Need to fix why it's not loading prior to text run.
- xdescribe('dynamic suggestions for argument values', () => {
- describe('.opensearch()', () => {
- before(async () => {
- await PageObjects.timeline.setExpression('.opensearch');
- await PageObjects.timeline.clickSuggestion();
- });
-
- it('should show index pattern suggestions for index argument', async () => {
- await PageObjects.timeline.updateExpression('index');
- await PageObjects.timeline.clickSuggestion();
- const suggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(suggestions.length).to.eql(1);
- expect(suggestions[0].includes('logstash-*')).to.eql(true);
- await PageObjects.timeline.clickSuggestion();
- });
-
- it('should show field suggestions for timefield argument when index pattern set', async () => {
- await PageObjects.timeline.updateExpression(',timefield');
- await PageObjects.timeline.clickSuggestion();
- const suggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(suggestions.length).to.eql(4);
- expect(suggestions[0].includes('@timestamp')).to.eql(true);
- await PageObjects.timeline.clickSuggestion();
- });
-
- it('should show field suggestions for split argument when index pattern set', async () => {
- await PageObjects.timeline.updateExpression(',split');
- await PageObjects.timeline.clickSuggestion();
- const suggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(suggestions.length).to.eql(52);
- expect(suggestions[0].includes('@message.raw')).to.eql(true);
- await PageObjects.timeline.clickSuggestion(10);
- });
-
- it('should show field suggestions for metric argument when index pattern set', async () => {
- await PageObjects.timeline.updateExpression(',metric');
- await PageObjects.timeline.clickSuggestion();
- await PageObjects.timeline.updateExpression('avg:');
- await PageObjects.timeline.clickSuggestion();
- const suggestions = await PageObjects.timeline.getSuggestionItemsText();
- expect(suggestions.length).to.eql(2);
- expect(suggestions[0].includes('avg:bytes')).to.eql(true);
- });
- });
- });
- });
-}
diff --git a/test/functional/apps/timeline/index.js b/test/functional/apps/timeline/index.js
deleted file mode 100644
index d89ffce2eda7..000000000000
--- a/test/functional/apps/timeline/index.js
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-export default function ({ getService, loadTestFile }) {
- const browser = getService('browser');
- const log = getService('log');
- const opensearchArchiver = getService('opensearchArchiver');
- const opensearchDashboardsServer = getService('opensearchDashboardsServer');
-
- describe('timeline app', function () {
- this.tags('ciGroup1');
-
- before(async function () {
- log.debug('Starting timeline before method');
- await browser.setWindowSize(1280, 800);
- await opensearchArchiver.loadIfNeeded('logstash_functional');
- await opensearchDashboardsServer.uiSettings.replace({ defaultIndex: 'logstash-*' });
- });
-
- loadTestFile(require.resolve('./_expression_typeahead'));
- });
-}
diff --git a/test/functional/config.js b/test/functional/config.js
index 9485225dc8ca..d927aea2966f 100644
--- a/test/functional/config.js
+++ b/test/functional/config.js
@@ -46,7 +46,6 @@ export default async function ({ readConfigFile }) {
require.resolve('./apps/management'),
require.resolve('./apps/saved_objects_management'),
require.resolve('./apps/status_page'),
- require.resolve('./apps/timeline'),
require.resolve('./apps/visualize'),
require.resolve('./apps/vis_builder'),
],
@@ -107,9 +106,6 @@ export default async function ({ readConfigFile }) {
settings: {
pathname: '/app/management',
},
- timeline: {
- pathname: '/app/timeline',
- },
console: {
pathname: '/app/dev_tools',
hash: '/console',
diff --git a/test/functional/fixtures/opensearch_archiver/dashboard/current/opensearch_dashboards/mappings.json b/test/functional/fixtures/opensearch_archiver/dashboard/current/opensearch_dashboards/mappings.json
index 8ba03cf35876..c7fb3a03d629 100644
--- a/test/functional/fixtures/opensearch_archiver/dashboard/current/opensearch_dashboards/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/dashboard/current/opensearch_dashboards/mappings.json
@@ -23,7 +23,6 @@
"sample-data-telemetry": "7d3cfeb915303c9641c59681967ffeb4",
"search": "181661168bbadd1eff5902361e2a0d5c",
"telemetry": "36a616f7026dfa617d6655df850fe16d",
- "timelion-sheet": "9a2a2748877c7a7b582fef201ab1d4cf",
"tsvb-validation-telemetry": "3a37ef6c8700ae6fc97d5c7da00e9215",
"type": "2f4316de49999235636386fe51dc06c1",
"ui-metric": "0d409297dc5ebe1e3a1da691c6ee32e3",
@@ -366,47 +365,6 @@
}
}
},
- "timelion-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timelion_chart_height": {
- "type": "integer"
- },
- "timelion_columns": {
- "type": "integer"
- },
- "timelion_interval": {
- "type": "keyword"
- },
- "timelion_other_interval": {
- "type": "keyword"
- },
- "timelion_rows": {
- "type": "integer"
- },
- "timelion_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"tsvb-validation-telemetry": {
"properties": {
"failedRequests": {
@@ -487,4 +445,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/dashboard/legacy/mappings.json b/test/functional/fixtures/opensearch_archiver/dashboard/legacy/mappings.json
index 9ca92fc2b55d..afeb0422eb97 100644
--- a/test/functional/fixtures/opensearch_archiver/dashboard/legacy/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/dashboard/legacy/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -241,4 +199,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/discover/mappings.json b/test/functional/fixtures/opensearch_archiver/discover/mappings.json
index 2f24917b04fc..df2768093b7e 100644
--- a/test/functional/fixtures/opensearch_archiver/discover/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/discover/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
diff --git a/test/functional/fixtures/opensearch_archiver/empty_opensearch_dashboards/mappings.json b/test/functional/fixtures/opensearch_archiver/empty_opensearch_dashboards/mappings.json
index a3a005fe8075..ad23c9028344 100644
--- a/test/functional/fixtures/opensearch_archiver/empty_opensearch_dashboards/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/empty_opensearch_dashboards/mappings.json
@@ -143,48 +143,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
diff --git a/test/functional/fixtures/opensearch_archiver/hamlet/mappings.json b/test/functional/fixtures/opensearch_archiver/hamlet/mappings.json
index 396bbadc30ba..d50b6c58bf99 100644
--- a/test/functional/fixtures/opensearch_archiver/hamlet/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/hamlet/mappings.json
@@ -19,7 +19,6 @@
"sample-data-telemetry": "7d3cfeb915303c9641c59681967ffeb4",
"search": "181661168bbadd1eff5902361e2a0d5c",
"server": "ec97f1c5da1a19609a60874e5af1100c",
- "timeline-sheet": "9a2a2748877c7a7b582fef201ab1d4cf",
"type": "2f4316de49999235636386fe51dc06c1",
"ui-metric": "0d409297dc5ebe1e3a1da691c6ee32e3",
"updated_at": "00da57df13e94e9d98437d13ace4bfe0",
@@ -230,47 +229,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -373,4 +331,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/invalid_scripted_field/mappings.json b/test/functional/fixtures/opensearch_archiver/invalid_scripted_field/mappings.json
index 592b4cde4751..19c0d074f96d 100644
--- a/test/functional/fixtures/opensearch_archiver/invalid_scripted_field/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/invalid_scripted_field/mappings.json
@@ -140,47 +140,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -247,4 +206,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/management/mappings.json b/test/functional/fixtures/opensearch_archiver/management/mappings.json
index 9ca92fc2b55d..afeb0422eb97 100644
--- a/test/functional/fixtures/opensearch_archiver/management/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/management/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -241,4 +199,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/mgmt/mappings.json b/test/functional/fixtures/opensearch_archiver/mgmt/mappings.json
index c7c440ac42e8..35948f59d0e8 100644
--- a/test/functional/fixtures/opensearch_archiver/mgmt/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/mgmt/mappings.json
@@ -171,47 +171,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -279,4 +238,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/opensearch_dashboards_sample_data_flights_index_pattern/mappings.json b/test/functional/fixtures/opensearch_archiver/opensearch_dashboards_sample_data_flights_index_pattern/mappings.json
index e404d68391c8..2f7eaf05472c 100644
--- a/test/functional/fixtures/opensearch_archiver/opensearch_dashboards_sample_data_flights_index_pattern/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/opensearch_dashboards_sample_data_flights_index_pattern/mappings.json
@@ -19,7 +19,6 @@
"sample-data-telemetry": "7d3cfeb915303c9641c59681967ffeb4",
"search": "181661168bbadd1eff5902361e2a0d5c",
"server": "ec97f1c5da1a19609a60874e5af1100c",
- "timeline-sheet": "9a2a2748877c7a7b582fef201ab1d4cf",
"type": "2f4316de49999235636386fe51dc06c1",
"ui-metric": "0d409297dc5ebe1e3a1da691c6ee32e3",
"updated_at": "00da57df13e94e9d98437d13ace4bfe0",
@@ -245,47 +244,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -461,4 +419,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/saved_objects_imports/mappings.json b/test/functional/fixtures/opensearch_archiver/saved_objects_imports/mappings.json
index 9ca92fc2b55d..afeb0422eb97 100644
--- a/test/functional/fixtures/opensearch_archiver/saved_objects_imports/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/saved_objects_imports/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -241,4 +199,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/saved_objects_management/edit_saved_object/mappings.json b/test/functional/fixtures/opensearch_archiver/saved_objects_management/edit_saved_object/mappings.json
index 3c2fcb67bd57..b2a66e47c403 100644
--- a/test/functional/fixtures/opensearch_archiver/saved_objects_management/edit_saved_object/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/saved_objects_management/edit_saved_object/mappings.json
@@ -355,47 +355,6 @@
}
}
},
- "timeline-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -456,4 +415,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/timeline/mappings.json b/test/functional/fixtures/opensearch_archiver/timeline/mappings.json
index 561ed8b85848..afeb0422eb97 100644
--- a/test/functional/fixtures/opensearch_archiver/timeline/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/timeline/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timelion-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timelion_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timelion_interval": {
- "type": "keyword"
- },
- "timelion_other_interval": {
- "type": "keyword"
- },
- "timelion_rows": {
- "type": "integer"
- },
- "timelion_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -241,4 +199,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/visualize/mappings.json b/test/functional/fixtures/opensearch_archiver/visualize/mappings.json
index f93bab96c263..4046784ca4be 100644
--- a/test/functional/fixtures/opensearch_archiver/visualize/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/visualize/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
diff --git a/test/functional/fixtures/opensearch_archiver/visualize_embedding/mappings.json b/test/functional/fixtures/opensearch_archiver/visualize_embedding/mappings.json
index 9ca92fc2b55d..afeb0422eb97 100644
--- a/test/functional/fixtures/opensearch_archiver/visualize_embedding/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/visualize_embedding/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timeline-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timeline_chart_height": {
- "type": "integer"
- },
- "timeline_columns": {
- "type": "integer"
- },
- "timeline_interval": {
- "type": "keyword"
- },
- "timeline_other_interval": {
- "type": "keyword"
- },
- "timeline_rows": {
- "type": "integer"
- },
- "timeline_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -241,4 +199,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/visualize_source-filters/mappings.json b/test/functional/fixtures/opensearch_archiver/visualize_source-filters/mappings.json
index a89fe1dfacfc..afeb0422eb97 100644
--- a/test/functional/fixtures/opensearch_archiver/visualize_source-filters/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/visualize_source-filters/mappings.json
@@ -134,48 +134,6 @@
}
}
},
- "timelion-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timelion_chart_height": {
- "type": "integer"
- },
- "timelion_columns": {
- "type": "integer"
- },
- "timelion_interval": {
- "type": "keyword"
- },
- "timelion_other_interval": {
- "type": "keyword"
- },
- "timelion_rows": {
- "type": "integer"
- },
- "timelion_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -241,4 +199,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/fixtures/opensearch_archiver/visualize_source_filters/mappings.json b/test/functional/fixtures/opensearch_archiver/visualize_source_filters/mappings.json
index 0f17621dbf52..b85e54477f8e 100644
--- a/test/functional/fixtures/opensearch_archiver/visualize_source_filters/mappings.json
+++ b/test/functional/fixtures/opensearch_archiver/visualize_source_filters/mappings.json
@@ -152,48 +152,6 @@
}
}
},
- "timelion-sheet": {
- "dynamic": "strict",
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timelion_chart_height": {
- "type": "integer"
- },
- "timelion_columns": {
- "type": "integer"
- },
- "timelion_interval": {
- "type": "keyword"
- },
- "timelion_other_interval": {
- "type": "keyword"
- },
- "timelion_rows": {
- "type": "integer"
- },
- "timelion_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"type": {
"type": "keyword"
},
@@ -259,4 +217,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/functional/page_objects/index.ts b/test/functional/page_objects/index.ts
index 63cd990c445b..2820f33a226f 100644
--- a/test/functional/page_objects/index.ts
+++ b/test/functional/page_objects/index.ts
@@ -41,7 +41,6 @@ import { SettingsPageProvider } from './settings_page';
import { SharePageProvider } from './share_page';
import { LoginPageProvider } from './login_page';
import { TimePickerProvider } from './time_picker';
-import { TimelinePageProvider } from './timeline_page';
import { VisualBuilderPageProvider } from './visual_builder_page';
import { VisualizePageProvider } from './visualize_page';
import { VisBuilderPageProvider } from './vis_builder_page';
@@ -65,7 +64,6 @@ export const pageObjects = {
settings: SettingsPageProvider,
share: SharePageProvider,
login: LoginPageProvider,
- timeline: TimelinePageProvider,
timePicker: TimePickerProvider,
visualBuilder: VisualBuilderPageProvider,
visualize: VisualizePageProvider,
diff --git a/test/functional/page_objects/timeline_page.ts b/test/functional/page_objects/timeline_page.ts
deleted file mode 100644
index ee89665e4c01..000000000000
--- a/test/functional/page_objects/timeline_page.ts
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- *
- * The OpenSearch Contributors require contributions made to
- * this file be licensed under the Apache-2.0 license or a
- * compatible open source license.
- *
- * Any modifications Copyright OpenSearch Contributors. See
- * GitHub history for details.
- */
-
-/*
- * Licensed to Elasticsearch B.V. under one or more contributor
- * license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright
- * ownership. Elasticsearch B.V. licenses this file to you under
- * the Apache License, Version 2.0 (the "License"); you may
- * not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-import { FtrProviderContext } from '../ftr_provider_context';
-
-export function TimelinePageProvider({ getService, getPageObjects }: FtrProviderContext) {
- const testSubjects = getService('testSubjects');
- const log = getService('log');
- const PageObjects = getPageObjects(['common', 'header']);
- const opensearchArchiver = getService('opensearchArchiver');
- const opensearchDashboardsServer = getService('opensearchDashboardsServer');
-
- class TimelinePage {
- public async initTests() {
- await opensearchDashboardsServer.uiSettings.replace({
- defaultIndex: 'logstash-*',
- });
-
- log.debug('load opensearch-dashboards index');
- await opensearchArchiver.load('timeline');
-
- await PageObjects.common.navigateToApp('timelion');
- }
-
- public async setExpression(expression: string) {
- const input = await testSubjects.find('timelineExpressionTextArea');
- await input.clearValue();
- await input.type(expression);
- }
-
- public async updateExpression(updates: string) {
- const input = await testSubjects.find('timelineExpressionTextArea');
- await input.type(updates);
- await PageObjects.common.sleep(1000);
- }
-
- public async getExpression() {
- const input = await testSubjects.find('timelineExpressionTextArea');
- return input.getVisibleText();
- }
-
- public async getSuggestionItemsText() {
- const elements = await testSubjects.findAll('timelineSuggestionListItem');
- return await Promise.all(elements.map(async (element) => await element.getVisibleText()));
- }
-
- public async clickSuggestion(suggestionIndex = 0, waitTime = 1000) {
- const elements = await testSubjects.findAll('timelineSuggestionListItem');
- if (suggestionIndex > elements.length) {
- throw new Error(
- `Unable to select suggestion ${suggestionIndex}, only ${elements.length} suggestions available.`
- );
- }
- await elements[suggestionIndex].click();
- // Wait for timeline expression to be updated after clicking suggestions
- await PageObjects.common.sleep(waitTime);
- }
-
- public async saveTimelineSheet() {
- await testSubjects.click('timelineSaveButton');
- await testSubjects.click('timelineSaveAsSheetButton');
- await testSubjects.click('timelineFinishSaveButton');
- await testSubjects.existOrFail('timelineSaveSuccessToast');
- await testSubjects.waitForDeleted('timelineSaveSuccessToast');
- }
-
- public async expectWriteControls() {
- await testSubjects.existOrFail('timelineSaveButton');
- await testSubjects.existOrFail('timelineDeleteButton');
- }
-
- public async expectMissingWriteControls() {
- await testSubjects.missingOrFail('timelineSaveButton');
- await testSubjects.missingOrFail('timelineDeleteButton');
- }
- }
-
- return new TimelinePage();
-}
diff --git a/test/new_visualize_flow/fixtures/opensearch_archiver/opensearch_dashboards/mappings.json b/test/new_visualize_flow/fixtures/opensearch_archiver/opensearch_dashboards/mappings.json
index 8ba03cf35876..c7fb3a03d629 100644
--- a/test/new_visualize_flow/fixtures/opensearch_archiver/opensearch_dashboards/mappings.json
+++ b/test/new_visualize_flow/fixtures/opensearch_archiver/opensearch_dashboards/mappings.json
@@ -23,7 +23,6 @@
"sample-data-telemetry": "7d3cfeb915303c9641c59681967ffeb4",
"search": "181661168bbadd1eff5902361e2a0d5c",
"telemetry": "36a616f7026dfa617d6655df850fe16d",
- "timelion-sheet": "9a2a2748877c7a7b582fef201ab1d4cf",
"tsvb-validation-telemetry": "3a37ef6c8700ae6fc97d5c7da00e9215",
"type": "2f4316de49999235636386fe51dc06c1",
"ui-metric": "0d409297dc5ebe1e3a1da691c6ee32e3",
@@ -366,47 +365,6 @@
}
}
},
- "timelion-sheet": {
- "properties": {
- "description": {
- "type": "text"
- },
- "hits": {
- "type": "integer"
- },
- "kibanaSavedObjectMeta": {
- "properties": {
- "searchSourceJSON": {
- "type": "text"
- }
- }
- },
- "timelion_chart_height": {
- "type": "integer"
- },
- "timelion_columns": {
- "type": "integer"
- },
- "timelion_interval": {
- "type": "keyword"
- },
- "timelion_other_interval": {
- "type": "keyword"
- },
- "timelion_rows": {
- "type": "integer"
- },
- "timelion_sheet": {
- "type": "text"
- },
- "title": {
- "type": "text"
- },
- "version": {
- "type": "integer"
- }
- }
- },
"tsvb-validation-telemetry": {
"properties": {
"failedRequests": {
@@ -487,4 +445,4 @@
}
}
}
-}
\ No newline at end of file
+}
diff --git a/test/plugin_functional/config.ts b/test/plugin_functional/config.ts
index e733a4e36368..ce027815a57f 100644
--- a/test/plugin_functional/config.ts
+++ b/test/plugin_functional/config.ts
@@ -52,6 +52,7 @@ export default async function ({ readConfigFile }: FtrConfigProviderContext) {
require.resolve('./test_suites/doc_views_links'),
require.resolve('./test_suites/application_links'),
require.resolve('./test_suites/data_plugin'),
+ require.resolve('./test_suites/dashboard_listing_plugin'),
],
services: {
...functionalConfig.get('services'),
diff --git a/test/plugin_functional/plugins/dashboard_listing_test_plugin/opensearch_dashboards.json b/test/plugin_functional/plugins/dashboard_listing_test_plugin/opensearch_dashboards.json
new file mode 100644
index 000000000000..454d9ea58471
--- /dev/null
+++ b/test/plugin_functional/plugins/dashboard_listing_test_plugin/opensearch_dashboards.json
@@ -0,0 +1,9 @@
+{
+ "id": "dashboard_listing_test_plugin",
+ "version": "0.0.1",
+ "opensearchDashboardsVersion": "opensearchDashboards",
+ "configPath": ["dashboard_listing_test_plugin"],
+ "server": false,
+ "ui": true,
+ "requiredPlugins": ["dashboard"]
+}
diff --git a/test/plugin_functional/plugins/dashboard_listing_test_plugin/package.json b/test/plugin_functional/plugins/dashboard_listing_test_plugin/package.json
new file mode 100644
index 000000000000..0b593604a2ad
--- /dev/null
+++ b/test/plugin_functional/plugins/dashboard_listing_test_plugin/package.json
@@ -0,0 +1,17 @@
+{
+ "name": "dashboard_listing_test_plugin",
+ "version": "1.0.0",
+ "main": "target/test/plugin_functional/plugins/dashboard_listing_test_plugin",
+ "opensearchDashboards": {
+ "version": "opensearchDashboards",
+ "templateVersion": "1.0.0"
+ },
+ "license": "Apache-2.0",
+ "scripts": {
+ "osd": "../../../../scripts/use_node ../../../../scripts/osd.js",
+ "build": "../../../../scripts/use_node ../../../../scripts/remove.js './target' && tsc"
+ },
+ "devDependencies": {
+ "typescript": "4.0.2"
+ }
+}
diff --git a/test/plugin_functional/plugins/dashboard_listing_test_plugin/public/index.ts b/test/plugin_functional/plugins/dashboard_listing_test_plugin/public/index.ts
new file mode 100644
index 000000000000..80ddbf8a3382
--- /dev/null
+++ b/test/plugin_functional/plugins/dashboard_listing_test_plugin/public/index.ts
@@ -0,0 +1,22 @@
+/*
+ * SPDX-License-Identifier: Apache-2.0
+ *
+ * The OpenSearch Contributors require contributions made to
+ * this file be licensed under the Apache-2.0 license or a
+ * compatible open source license.
+ *
+ * Any modifications Copyright OpenSearch Contributors. See
+ * GitHub history for details.
+ */
+
+import { PluginInitializer } from 'opensearch-dashboards/public';
+import {
+ DashboardListingTestPlugin,
+ DashboardListingTestPluginSetup,
+ DashboardListingTestPluginStart,
+} from './plugin';
+
+export const plugin: PluginInitializer<
+ DashboardListingTestPluginSetup,
+ DashboardListingTestPluginStart
+> = () => new DashboardListingTestPlugin();
diff --git a/test/plugin_functional/plugins/dashboard_listing_test_plugin/public/plugin.tsx b/test/plugin_functional/plugins/dashboard_listing_test_plugin/public/plugin.tsx
new file mode 100644
index 000000000000..76a407f7c0d2
--- /dev/null
+++ b/test/plugin_functional/plugins/dashboard_listing_test_plugin/public/plugin.tsx
@@ -0,0 +1,53 @@
+/*
+ * SPDX-License-Identifier: Apache-2.0
+ *
+ * The OpenSearch Contributors require contributions made to
+ * this file be licensed under the Apache-2.0 license or a
+ * compatible open source license.
+ *
+ * Any modifications Copyright OpenSearch Contributors. See
+ * GitHub history for details.
+ */
+
+import * as React from 'react';
+import { render, unmountComponentAtNode } from 'react-dom';
+import { Router, Switch, Route, Link } from 'react-router-dom';
+import { CoreSetup, Plugin } from 'opensearch-dashboards/public';
+
+export class DashboardListingTestPlugin
+ implements Plugin {
+ public setup(core: CoreSetup, setupDeps: SetupDependencies) {
+ const ID = 'dashboard_listing_test_plugin';
+ const BASE_URL = core.http.basePath.prepend(`/app/${ID}#`);
+ setupDeps.dashboard.registerDashboardProvider({
+ appId: ID,
+ savedObjectsType: 'dashboardTest',
+ savedObjectsName: 'Dashboard Test',
+ editUrlPathFn: (obj: SavedObject) => `${BASE_URL}/${obj.id}/edit`,
+ viewUrlPathFn: (obj: SavedObject) => `${BASE_URL}/${obj.id}`,
+ createLinkText: 'Test Dashboard',
+ createSortText: 'Test Dashboard',
+ createUrl: `${BASE_URL}/create`,
+ });
+
+ core.application.register({
+ id: ID,
+ title: 'Dashboard Listing Test Plugin',
+ appRoute: `app/${ID}`,
+ async mount(context, { element }) {
+ render(
+ Dashboard Listing Test Header ,
+ element
+ );
+
+ return () => unmountComponentAtNode(element);
+ },
+ });
+ }
+
+ public start() {}
+ public stop() {}
+}
+
+export type DashboardListingTestPluginSetup = ReturnType;
+export type DashboardListingTestPluginStart = ReturnType;
diff --git a/test/plugin_functional/plugins/dashboard_listing_test_plugin/tsconfig.json b/test/plugin_functional/plugins/dashboard_listing_test_plugin/tsconfig.json
new file mode 100644
index 000000000000..f77a5eaffc30
--- /dev/null
+++ b/test/plugin_functional/plugins/dashboard_listing_test_plugin/tsconfig.json
@@ -0,0 +1,17 @@
+{
+ "extends": "../../../../tsconfig.base.json",
+ "compilerOptions": {
+ "outDir": "./target",
+ "skipLibCheck": true
+ },
+ "include": [
+ "index.ts",
+ "public/**/*.ts",
+ "public/**/*.tsx",
+ "../../../../typings/**/*",
+ ],
+ "exclude": [],
+ "references": [
+ { "path": "../../../../src/core/tsconfig.json" }
+ ]
+}
diff --git a/test/plugin_functional/test_suites/dashboard_listing_plugin/dashboard_listing_plugin.ts b/test/plugin_functional/test_suites/dashboard_listing_plugin/dashboard_listing_plugin.ts
new file mode 100644
index 000000000000..354cfac4fa87
--- /dev/null
+++ b/test/plugin_functional/test_suites/dashboard_listing_plugin/dashboard_listing_plugin.ts
@@ -0,0 +1,71 @@
+/*
+ * SPDX-License-Identifier: Apache-2.0
+ *
+ * The OpenSearch Contributors require contributions made to
+ * this file be licensed under the Apache-2.0 license or a
+ * compatible open source license.
+ *
+ * Any modifications Copyright OpenSearch Contributors. See
+ * GitHub history for details.
+ */
+
+import url from 'url';
+import expect from '@osd/expect';
+
+const getPathWithHash = (absoluteUrl: string) => {
+ const parsed = url.parse(absoluteUrl);
+ return `${parsed.path}${parsed.hash ?? ''}`;
+};
+
+export default function ({ getService, getPageObjects }) {
+ const testSubjects = getService('testSubjects');
+ const PageObjects = getPageObjects(['common', 'dashboard', 'header']);
+ const browser = getService('browser');
+ const listingTable = getService('listingTable');
+ const find = getService('find');
+
+ describe('dashboard listing plugin', function describeIndexTests() {
+ const dashboardName = 'Dashboard Test';
+
+ before(async () => {
+ await PageObjects.dashboard.initTests({
+ opensearchDashboardsIndex: '../functional/fixtures/opensearch_archiver/dashboard/legacy',
+ });
+ await PageObjects.dashboard.clickCreateDashboardPrompt();
+ await PageObjects.dashboard.saveDashboard('default');
+ await PageObjects.dashboard.gotoDashboardLandingPage();
+ });
+
+ it('should be able to navigate to create a dashboard', async () => {
+ await testSubjects.click('createMenuDropdown');
+ await testSubjects.click('contextMenuItem-dashboard');
+ await PageObjects.dashboard.saveDashboard(dashboardName);
+
+ await PageObjects.dashboard.gotoDashboardLandingPage();
+ await listingTable.searchAndExpectItemsCount('dashboard', dashboardName, 1);
+ });
+
+ it('should be able to navigate to view dashboard', async () => {
+ await listingTable.clickItemLink('dashboard', dashboardName);
+ await PageObjects.header.awaitGlobalLoadingIndicatorHidden();
+ await PageObjects.dashboard.getIsInViewMode();
+ await PageObjects.dashboard.gotoDashboardLandingPage();
+ });
+
+ it('should be able to navigate to edit dashboard', async () => {
+ await listingTable.searchForItemWithName(dashboardName);
+ const editBttn = await find.allByCssSelector('.euiToolTipAnchor');
+ await editBttn[0].click();
+ await PageObjects.dashboard.clickCancelOutOfEditMode();
+ await PageObjects.dashboard.gotoDashboardLandingPage();
+ });
+
+ it('should be able to navigate to create a test dashboard', async () => {
+ await testSubjects.click('createMenuDropdown');
+ await testSubjects.click('contextMenuItem-dashboard_listing_test_plugin');
+ expect(getPathWithHash(await browser.getCurrentUrl())).to.eql(
+ '/app/dashboard_listing_test_plugin#/create'
+ );
+ });
+ });
+}
diff --git a/test/plugin_functional/test_suites/dashboard_listing_plugin/index.ts b/test/plugin_functional/test_suites/dashboard_listing_plugin/index.ts
new file mode 100644
index 000000000000..a84790824f64
--- /dev/null
+++ b/test/plugin_functional/test_suites/dashboard_listing_plugin/index.ts
@@ -0,0 +1,35 @@
+/*
+ * SPDX-License-Identifier: Apache-2.0
+ *
+ * The OpenSearch Contributors require contributions made to
+ * this file be licensed under the Apache-2.0 license or a
+ * compatible open source license.
+ *
+ * Any modifications Copyright OpenSearch Contributors. See
+ * GitHub history for details.
+ */
+
+export default function ({ getService, loadTestFile }) {
+ const browser = getService('browser');
+ const opensearchArchiver = getService('opensearchArchiver');
+
+ async function loadLogstash() {
+ await browser.setWindowSize(1200, 900);
+ await opensearchArchiver.loadIfNeeded(
+ '../functional/fixtures/opensearch_archiver/logstash_functional'
+ );
+ }
+
+ async function unloadLogstash() {
+ await opensearchArchiver.unload(
+ '../functional/fixtures/opensearch_archiver/logstash_functional'
+ );
+ }
+
+ describe('dashboard listing plugin', () => {
+ before(loadLogstash);
+ after(unloadLogstash);
+
+ loadTestFile(require.resolve('./dashboard_listing_plugin'));
+ });
+}
diff --git a/yarn.lock b/yarn.lock
index 33ca05a2f2c1..e1985b3cd645 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -1385,7 +1385,7 @@
resolved "https://registry.yarnpkg.com/@emotion/unitless/-/unitless-0.7.5.tgz#77211291c1900a700b8a78cfafda3160d76949ed"
integrity sha512-OWORNpfjMsSSUBVrRBVGECkhWcULOAJz9ZW8uK9qgxD+87M7jHRcvh/A96XXNhXTLmKcoYSQtBEX7lHMO7YRwg==
-"@gar/promisify@^1.0.1":
+"@gar/promisify@^1.0.1", "@gar/promisify@^1.1.3":
version "1.1.3"
resolved "https://registry.yarnpkg.com/@gar/promisify/-/promisify-1.1.3.tgz#555193ab2e3bb3b6adc3d551c9c030d9e860daf6"
integrity sha512-k2Ty1JcVojjJFwrg/ThKi2ujJ7XNLYaFGNB/bWT9wGR+oSMJHMa5w+CUq6p/pVrKeNNgA7pCqEcjSnHVoqJQFw==
@@ -2221,6 +2221,36 @@
resolved "https://registry.yarnpkg.com/@kwsites/promise-deferred/-/promise-deferred-1.1.1.tgz#8ace5259254426ccef57f3175bc64ed7095ed919"
integrity sha512-GaHYm+c0O9MjZRu0ongGBRbinu8gVAMd2UZjji6jVmqKtZluZnptXGWhz1E8j8D2HJ3f/yMxKAUC0b+57wncIw==
+"@lmdb/lmdb-darwin-arm64@2.8.0":
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/@lmdb/lmdb-darwin-arm64/-/lmdb-darwin-arm64-2.8.0.tgz#20c8c2b81cde5c35fcbe81714448493db93d3e62"
+ integrity sha512-SadxUdQvGDa+gfZr6uX8kiXbyVUzulhhvieco12K/c5oaNY00MQAm5C00eP2ht959zVus6cQyD09LmoP0OBIqg==
+
+"@lmdb/lmdb-darwin-x64@2.8.0":
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/@lmdb/lmdb-darwin-x64/-/lmdb-darwin-x64-2.8.0.tgz#b78c20328725daefce846bf7480a8d3d5b789e19"
+ integrity sha512-woNqmHXTX7cLu9Mbyj/c1wHQFSoCC/n1CwL2xw2tLVQTXFFJrX0RJQd5XBtvr5kC6Rqf51dk3ScLHU/Bl6v7wg==
+
+"@lmdb/lmdb-linux-arm64@2.8.0":
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/@lmdb/lmdb-linux-arm64/-/lmdb-linux-arm64-2.8.0.tgz#1b343dfc91c13c3633b9237dce4c454c4a7d576f"
+ integrity sha512-XQtJs4xOQ9uNKuuxSkJfsUdQJ1a/gyKwbxBGQw5VUo/RhzwxOdVM8deIBv8UfdjfBId1JIDn/8FXuPmDVfnKQg==
+
+"@lmdb/lmdb-linux-arm@2.8.0":
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/@lmdb/lmdb-linux-arm/-/lmdb-linux-arm-2.8.0.tgz#26e079de966e9d68b640810593fdb14f1b5958f2"
+ integrity sha512-uog9KOYrK0uIafyIg7wddB3h0s6qA9qoDZVfACEW3LvYCmw5iLOAsKuh/c+7CUeCYyAJVaWGK2YSDFXRlHdcUw==
+
+"@lmdb/lmdb-linux-x64@2.8.0":
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/@lmdb/lmdb-linux-x64/-/lmdb-linux-x64-2.8.0.tgz#ab84bb9591f73e194ee5d8c7aeecddbe953112ea"
+ integrity sha512-I5OuHnZYoGtIlq6Wmga3qHb0yefNgMrvsb+XbXfoDuQNa/KVBUb9UZgNJ65707egwHNGCFaMwXcKoGNTaJof6A==
+
+"@lmdb/lmdb-win32-x64@2.8.0":
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/@lmdb/lmdb-win32-x64/-/lmdb-win32-x64-2.8.0.tgz#5fa3c9453820d474ffcf7a5c1d71d7b3775621fe"
+ integrity sha512-RWUSEdHh+MbqmshbsyAHA1kInR7F0MEphWh4HzWlP+3bjUVy36Fn6L1xVbLPfndcAwlbv/x5XuyKaiKK2hEzrw==
+
"@mapbox/hast-util-table-cell-style@^0.2.0":
version "0.2.0"
resolved "https://registry.yarnpkg.com/@mapbox/hast-util-table-cell-style/-/hast-util-table-cell-style-0.2.0.tgz#1003f59d54fae6f638cb5646f52110fb3da95b4d"
@@ -2291,11 +2321,125 @@
call-me-maybe "^1.0.1"
glob-to-regexp "^0.3.0"
+"@msgpackr-extract/msgpackr-extract-darwin-arm64@3.0.2":
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/@msgpackr-extract/msgpackr-extract-darwin-arm64/-/msgpackr-extract-darwin-arm64-3.0.2.tgz#44d752c1a2dc113f15f781b7cc4f53a307e3fa38"
+ integrity sha512-9bfjwDxIDWmmOKusUcqdS4Rw+SETlp9Dy39Xui9BEGEk19dDwH0jhipwFzEff/pFg95NKymc6TOTbRKcWeRqyQ==
+
+"@msgpackr-extract/msgpackr-extract-darwin-x64@3.0.2":
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/@msgpackr-extract/msgpackr-extract-darwin-x64/-/msgpackr-extract-darwin-x64-3.0.2.tgz#f954f34355712212a8e06c465bc06c40852c6bb3"
+ integrity sha512-lwriRAHm1Yg4iDf23Oxm9n/t5Zpw1lVnxYU3HnJPTi2lJRkKTrps1KVgvL6m7WvmhYVt/FIsssWay+k45QHeuw==
+
+"@msgpackr-extract/msgpackr-extract-linux-arm64@3.0.2":
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/@msgpackr-extract/msgpackr-extract-linux-arm64/-/msgpackr-extract-linux-arm64-3.0.2.tgz#45c63037f045c2b15c44f80f0393fa24f9655367"
+ integrity sha512-FU20Bo66/f7He9Fp9sP2zaJ1Q8L9uLPZQDub/WlUip78JlPeMbVL8546HbZfcW9LNciEXc8d+tThSJjSC+tmsg==
+
+"@msgpackr-extract/msgpackr-extract-linux-arm@3.0.2":
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/@msgpackr-extract/msgpackr-extract-linux-arm/-/msgpackr-extract-linux-arm-3.0.2.tgz#35707efeafe6d22b3f373caf9e8775e8920d1399"
+ integrity sha512-MOI9Dlfrpi2Cuc7i5dXdxPbFIgbDBGgKR5F2yWEa6FVEtSWncfVNKW5AKjImAQ6CZlBK9tympdsZJ2xThBiWWA==
+
+"@msgpackr-extract/msgpackr-extract-linux-x64@3.0.2":
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/@msgpackr-extract/msgpackr-extract-linux-x64/-/msgpackr-extract-linux-x64-3.0.2.tgz#091b1218b66c341f532611477ef89e83f25fae4f"
+ integrity sha512-gsWNDCklNy7Ajk0vBBf9jEx04RUxuDQfBse918Ww+Qb9HCPoGzS+XJTLe96iN3BVK7grnLiYghP/M4L8VsaHeA==
+
+"@msgpackr-extract/msgpackr-extract-win32-x64@3.0.2":
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/@msgpackr-extract/msgpackr-extract-win32-x64/-/msgpackr-extract-win32-x64-3.0.2.tgz#0f164b726869f71da3c594171df5ebc1c4b0a407"
+ integrity sha512-O+6Gs8UeDbyFpbSh2CPEz/UOrrdWPTBYNblZK5CxxLisYt4kGX3Sc+czffFonyjiGSq3jWLwJS/CCJc7tBr4sQ==
+
"@nicolo-ribaudo/chokidar-2@2.1.8-no-fsevents.3":
version "2.1.8-no-fsevents.3"
resolved "https://registry.yarnpkg.com/@nicolo-ribaudo/chokidar-2/-/chokidar-2-2.1.8-no-fsevents.3.tgz#323d72dd25103d0c4fbdce89dadf574a787b1f9b"
integrity sha512-s88O1aVtXftvp5bCPB7WnmXc5IwOZZ7YPuwNPt+GtOOXpPvad1LfbmjYv+qII7zP6RU2QGnqve27dnLycEnyEQ==
+"@node-rs/xxhash-android-arm-eabi@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-android-arm-eabi/-/xxhash-android-arm-eabi-1.4.0.tgz#55ace4d3882686d1e379aaf613e1338d78f13fc8"
+ integrity sha512-JuZNqt5/znWkIGteikQdS+HT9S0JsMYi06S4yzU/sMKLCIPvD0MnCTXlYtuDcgRIKScCaepAsSQVomnAyLFNNA==
+
+"@node-rs/xxhash-android-arm64@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-android-arm64/-/xxhash-android-arm64-1.4.0.tgz#2290c53ceabda804afb4c45679613d833a6385a0"
+ integrity sha512-BZzQO5jlgsIr9HhiqTwZjYqlfVeZiu+7PaoAdNEOq+i/SjyAqv1jGSkyek4rBSAiodyNkXcbE0eQtomeN6a55w==
+
+"@node-rs/xxhash-darwin-arm64@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-darwin-arm64/-/xxhash-darwin-arm64-1.4.0.tgz#96df4f48b13deb6899e84ed0882bdbd0a4856f13"
+ integrity sha512-JlEAzTsQaqJaWVse/JP//6QKBIhzqzTlvNY4uEbi8TaZMfvDDhW//ClXM6CkSV799GJxAYPu1LXa4+OeBQpa7Q==
+
+"@node-rs/xxhash-darwin-x64@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-darwin-x64/-/xxhash-darwin-x64-1.4.0.tgz#9df3ca3a87354dd5386aadfa20ad032a299c2b8f"
+ integrity sha512-9ycVJfzLvw1wc6Tgq0giLkMn5nGOBawTeOA17t27dQFdY/scZPz583DO7w+eznMnlzUXwoLiloanUebRhy+piQ==
+
+"@node-rs/xxhash-freebsd-x64@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-freebsd-x64/-/xxhash-freebsd-x64-1.4.0.tgz#24b0c0bfd33429303688b4af78f9d323daa0fb5b"
+ integrity sha512-vFRDr6qA0gHWQDjuSxXcdzM4Ppk+5VebEhc76zkWrRVc6RG60fxLo5B4j6QwMwXGTYaG8HMv/nQhAgbnOCWWxQ==
+
+"@node-rs/xxhash-linux-arm-gnueabihf@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-linux-arm-gnueabihf/-/xxhash-linux-arm-gnueabihf-1.4.0.tgz#4c09f70cd39429fb1a52f3567085e949603d4817"
+ integrity sha512-0KS6y1caqbtPanos9XNMekWpozCHA6QSlQzaZyn9Hn+Z+mYpR5+NoWixefhp06jt59qF9+LkkF3C9fSEHYmq/w==
+
+"@node-rs/xxhash-linux-arm64-gnu@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-linux-arm64-gnu/-/xxhash-linux-arm64-gnu-1.4.0.tgz#e92d7026614506fb4db309977127fd8589fabd7c"
+ integrity sha512-QI97JK2qiQhVgRtUBMgA1ZjPLpwnz11SE2Mw1jryejmyH9EXKKiCyt2FweO6MVP7bEuMxcdajBho4pEL7s/QsA==
+
+"@node-rs/xxhash-linux-arm64-musl@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-linux-arm64-musl/-/xxhash-linux-arm64-musl-1.4.0.tgz#a8b16233a86c116e6af32a69278248d17b2d09e7"
+ integrity sha512-dtMid4OMkNBYGJkjoT1jdkENpV8m8MGp3lliDN8C+2znZUQM8KFRTXRkfaq4lgzu3Y2XeYzsLOoBsBd3Hgf7gA==
+
+"@node-rs/xxhash-linux-x64-gnu@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-linux-x64-gnu/-/xxhash-linux-x64-gnu-1.4.0.tgz#385ec91396ebaa2b73abf419be3971ec893dcbd1"
+ integrity sha512-OeOQL10cG62wL1IVoeC74xESmefHU7r3xiZMTP2hK5Dh3FdF2sa3x/Db9BcGXlaokg/lMGDxuTuzOLC2Rv/wlQ==
+
+"@node-rs/xxhash-linux-x64-musl@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-linux-x64-musl/-/xxhash-linux-x64-musl-1.4.0.tgz#715bb962502b0ec69e1fc19db22ac035c63d30c7"
+ integrity sha512-kZ8wNi5bH9b+ZpuPlSbFd6JXk8CKbfCvCPZ0Vk0IqLkzB6PihQflnZPM9r0QZ2jtFgyfWmpbFK4YxwX9YcyLog==
+
+"@node-rs/xxhash-win32-arm64-msvc@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-win32-arm64-msvc/-/xxhash-win32-arm64-msvc-1.4.0.tgz#4a3a4ebcb50c73e4309e429b28eb44dbf8f7f71f"
+ integrity sha512-Ggv66jlhQvj4XgQqNgl2JKQ7My/97PvPZi5jKbcS7t65wJC36J6XERQwRPdupO8UH63XfPqb7HJqrgmiz8tmlA==
+
+"@node-rs/xxhash-win32-ia32-msvc@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-win32-ia32-msvc/-/xxhash-win32-ia32-msvc-1.4.0.tgz#fdfdb43e41113a8baf15779ca53bb637d2e1bc8f"
+ integrity sha512-mYpF1+7unqKKGsPn7Y8X6SqP2Bc5BU5dsHBKhAGAuvrMg9W63zM+YWM8/fpNGfFlOrjiKRvXHZ96nrZyzoxeBw==
+
+"@node-rs/xxhash-win32-x64-msvc@1.4.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash-win32-x64-msvc/-/xxhash-win32-x64-msvc-1.4.0.tgz#aee714a4ae0121f3947f94139adf13f5b6d93d12"
+ integrity sha512-rKuqWHuQNlrfjIOkQW3oCBta/GUlyVoUkKB13aVr8uixOs/eneuDaYJx2h02FAAWlWCKADFnMxgDl0LVFBy53w==
+
+"@node-rs/xxhash@^1.3.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@node-rs/xxhash/-/xxhash-1.4.0.tgz#1e75850e0e530c9224e8e5ba4056d52e8868291b"
+ integrity sha512-UpSOParhMqbQ7hsYovN2e+uqvWqHJiCDvFl8gDzMcXgBY/PkI2zo2zhdRAZdz48c6/dke+0WjCKy90wDVQxS6g==
+ optionalDependencies:
+ "@node-rs/xxhash-android-arm-eabi" "1.4.0"
+ "@node-rs/xxhash-android-arm64" "1.4.0"
+ "@node-rs/xxhash-darwin-arm64" "1.4.0"
+ "@node-rs/xxhash-darwin-x64" "1.4.0"
+ "@node-rs/xxhash-freebsd-x64" "1.4.0"
+ "@node-rs/xxhash-linux-arm-gnueabihf" "1.4.0"
+ "@node-rs/xxhash-linux-arm64-gnu" "1.4.0"
+ "@node-rs/xxhash-linux-arm64-musl" "1.4.0"
+ "@node-rs/xxhash-linux-x64-gnu" "1.4.0"
+ "@node-rs/xxhash-linux-x64-musl" "1.4.0"
+ "@node-rs/xxhash-win32-arm64-msvc" "1.4.0"
+ "@node-rs/xxhash-win32-ia32-msvc" "1.4.0"
+ "@node-rs/xxhash-win32-x64-msvc" "1.4.0"
+
"@nodelib/fs.scandir@2.1.5":
version "2.1.5"
resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5"
@@ -2330,6 +2474,14 @@
"@gar/promisify" "^1.0.1"
semver "^7.3.5"
+"@npmcli/fs@^2.1.0":
+ version "2.1.2"
+ resolved "https://registry.yarnpkg.com/@npmcli/fs/-/fs-2.1.2.tgz#a9e2541a4a2fec2e69c29b35e6060973da79b865"
+ integrity sha512-yOJKRvohFOaLqipNtwYB9WugyZKhC/DZC4VYPmpaCzDBrA8YpK3qHZ8/HGscMnE4GqbkLNuVcCnxkeQEdGt6LQ==
+ dependencies:
+ "@gar/promisify" "^1.1.3"
+ semver "^7.3.5"
+
"@npmcli/move-file@^1.0.1":
version "1.1.2"
resolved "https://registry.yarnpkg.com/@npmcli/move-file/-/move-file-1.1.2.tgz#1a82c3e372f7cae9253eb66d72543d6b8685c674"
@@ -2338,17 +2490,30 @@
mkdirp "^1.0.4"
rimraf "^3.0.2"
-"@opensearch-project/opensearch@^2.1.0":
- version "2.1.0"
- resolved "https://registry.yarnpkg.com/@opensearch-project/opensearch/-/opensearch-2.1.0.tgz#d79ab4ae643493512099673e117faffe40b4fe56"
- integrity sha512-iM2u63j2IlUOuMSbcw1TZFpRqjK6qMwVhb3jLLa/x4aATxdKOiO1i17mgzfkeepqj85efNzXBZzN+jkq1/EXhQ==
+"@npmcli/move-file@^2.0.0":
+ version "2.0.1"
+ resolved "https://registry.yarnpkg.com/@npmcli/move-file/-/move-file-2.0.1.tgz#26f6bdc379d87f75e55739bab89db525b06100e4"
+ integrity sha512-mJd2Z5TjYWq/ttPLLGqArdtnC74J6bOzg4rMDnN+p1xTacZ2yPRCk2y0oSWQtygLR9YVQXgOcONrwtnk3JupxQ==
+ dependencies:
+ mkdirp "^1.0.4"
+ rimraf "^3.0.2"
+
+"@opensearch-project/opensearch@^2.2.0":
+ version "2.2.1"
+ resolved "https://registry.yarnpkg.com/@opensearch-project/opensearch/-/opensearch-2.2.1.tgz#a400203afa6512ef73945663163a404763a10f5a"
+ integrity sha512-8zfQX1acL9eWG+ohIc9nJVT9LSqXCdbVEJs0rCPRtji3XF6ahzsiKmGNTeWLxCPDxWCjAIWq9t95xP3Y5Egi6Q==
dependencies:
aws4 "^1.11.0"
debug "^4.3.1"
- hpagent "^0.1.1"
+ hpagent "^1.2.0"
ms "^2.1.3"
secure-json-parse "^2.4.0"
+"@opentelemetry/api@^1.1.0":
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/@opentelemetry/api/-/api-1.4.0.tgz#2c91791a9ba6ca0a0f4aaac5e45d58df13639ac8"
+ integrity sha512-IgMK9i3sFGNUqPMbjABm0G26g0QCKCUBfglhQ7rQq6WcxbKfEHRcmwsoER4hZcuYqJgkYn2OeuoJIv7Jsftp7g==
+
"@percy/cli-app@1.10.4":
version "1.10.4"
resolved "https://registry.yarnpkg.com/@percy/cli-app/-/cli-app-1.10.4.tgz#3c27b71269d41ca3bd5af6d69ec5493cf5a16d1a"
@@ -2657,6 +2822,11 @@
resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-1.1.2.tgz#ccb91445360179a04e7fe6aff78c00ffc1eeaf82"
integrity sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==
+"@tootallnate/once@2":
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-2.0.0.tgz#f544a148d3ab35801c1f633a7441fd87c2e484bf"
+ integrity sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==
+
"@tsd/typescript@~4.7.3":
version "4.7.4"
resolved "https://registry.yarnpkg.com/@tsd/typescript/-/typescript-4.7.4.tgz#f1e4e6c3099a174a0cb7aa51cf53f34f6494e528"
@@ -2785,10 +2955,10 @@
dependencies:
"@types/color-convert" "*"
-"@types/compression-webpack-plugin@^2.0.2":
- version "2.0.5"
- resolved "https://registry.yarnpkg.com/@types/compression-webpack-plugin/-/compression-webpack-plugin-2.0.5.tgz#2cb870888da56db7c9f096e6b2bb31419fb51c2d"
- integrity sha512-yv0M9wZ/9GSJewznsJERr4BhFhnjlrwUoe0fpQw2AkLgpbOKabzsN6EexgytKGnkGiKWYR00w1YwqeGfo4/nUw==
+"@types/compression-webpack-plugin@^6.0.6":
+ version "6.0.6"
+ resolved "https://registry.yarnpkg.com/@types/compression-webpack-plugin/-/compression-webpack-plugin-6.0.6.tgz#0af843e445b5b6531432a8f521cc2c34c4a82276"
+ integrity sha512-UuSUiWmgg4zfzTaGwyo4XCY4MBfgPuvvwAHujQZyu1beGDiJKXU3YMg0Pl6zcLMYV6tDqZJWyYG1QkT5yt28EA==
dependencies:
"@types/webpack" "^4"
@@ -3126,10 +3296,10 @@
resolved "https://registry.yarnpkg.com/@types/js-cookie/-/js-cookie-2.2.5.tgz#38dfaacae8623b37cc0b0d27398e574e3fc28b1e"
integrity sha512-cpmwBRcHJmmZx0OGU7aPVwGWGbs4iKwVYchk9iuMtxNCA2zorwdaTz4GkLgs2WGxiRZRFKnV1k6tRUHX7tBMxg==
-"@types/js-yaml@^3.11.1":
- version "3.12.7"
- resolved "https://registry.yarnpkg.com/@types/js-yaml/-/js-yaml-3.12.7.tgz#330c5d97a3500e9c903210d6e49f02964af04a0e"
- integrity sha512-S6+8JAYTE1qdsc9HMVsfY7+SgSuUU/Tp6TYTmITW0PZxiyIMvol3Gy//y69Wkhs0ti4py5qgR3uZH6uz/DNzJQ==
+"@types/js-yaml@^4.0.5":
+ version "4.0.5"
+ resolved "https://registry.yarnpkg.com/@types/js-yaml/-/js-yaml-4.0.5.tgz#738dd390a6ecc5442f35e7f03fa1431353f7e138"
+ integrity sha512-FhpRzf927MNQdRZP0J5DLIdTXhjLYzeUTmLAu69mnVksLH9CJY3IuSeEgbKUki7GQZm0WqDkGzyxju2EZGD2wA==
"@types/json-schema@*", "@types/json-schema@^7.0.3", "@types/json-schema@^7.0.5", "@types/json-schema@^7.0.8", "@types/json-schema@^7.0.9":
version "7.0.11"
@@ -3285,10 +3455,10 @@
dependencies:
"@types/node" "*"
-"@types/node@*", "@types/node@12.20.24", "@types/node@16.9.1", "@types/node@^14.17.32":
- version "14.18.12"
- resolved "https://registry.yarnpkg.com/@types/node/-/node-14.18.12.tgz#0d4557fd3b94497d793efd4e7d92df2f83b4ef24"
- integrity sha512-q4jlIR71hUpWTnGhXWcakgkZeHa3CCjcQcnuzU8M891BAWA2jHiziiWEPEkdS5pFsz7H9HJiy8BrK7tBRNrY7A==
+"@types/node@*", "@types/node@12.20.24", "@types/node@16.9.1", "@types/node@~18.7.0":
+ version "18.7.23"
+ resolved "https://registry.yarnpkg.com/@types/node/-/node-18.7.23.tgz#75c580983846181ebe5f4abc40fe9dfb2d65665f"
+ integrity sha512-DWNcCHolDq0ZKGizjx2DZjR/PqsYwAcYUJmfMWqtVU2MBMG5Mo+xFZrhGId5r/O5HOuMPyQEcM6KUBp5lBZZBg==
"@types/normalize-package-data@*", "@types/normalize-package-data@^2.4.0":
version "2.4.1"
@@ -4155,7 +4325,16 @@ agentkeepalive@^3.4.1:
dependencies:
humanize-ms "^1.2.1"
-agentkeepalive@^4.1.3, agentkeepalive@^4.2.1:
+agentkeepalive@^4.1.3:
+ version "4.3.0"
+ resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.3.0.tgz#bb999ff07412653c1803b3ced35e50729830a255"
+ integrity sha512-7Epl1Blf4Sy37j4v9f9FjICCh4+KAQOyXgHEwlyBiAQLbhKdq/i2QQU3amQalS/wPhdPzDXPL5DMR5bkn+YeWg==
+ dependencies:
+ debug "^4.1.0"
+ depd "^2.0.0"
+ humanize-ms "^1.2.1"
+
+agentkeepalive@^4.2.1:
version "4.2.1"
resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.2.1.tgz#a7975cbb9f83b367f06c90cc51ff28fe7d499717"
integrity sha512-Zn4cw2NEqd+9fiSVWMscnjyQ1a8Yfoc5oBajLeo5w+YBHgDUcEBY2hS4YpTz6iN5f/2zQiktcuM6tS8x1p9dpA==
@@ -4249,11 +4428,6 @@ angular-sanitize@^1.8.0:
resolved "https://registry.yarnpkg.com/angular-sanitize/-/angular-sanitize-1.8.2.tgz#ae78040f00c5e2ce1c63780bcc47fa14a1698296"
integrity sha512-OB6Goa+QN3byf5asQ7XRl7DKZejm/F/ZOqa9z1skqYVOWA2hoBxoCmt9E7+i7T/TbxZP5zYzKxNZVVJNu860Hg==
-angular-sortable-view@^0.0.17:
- version "0.0.17"
- resolved "https://registry.yarnpkg.com/angular-sortable-view/-/angular-sortable-view-0.0.17.tgz#99e2679951a86b6ee6ff27b099022943c683fb4f"
- integrity sha512-2WkhM0Lt/wyMyrX/+7ve9ejSegBd7A4eRBNHEIJz8XMBIOjt+3oM1WpcAm+qNThkmNmmQaDeaYv0TQZw/WDMBw==
-
angular@>=1.0.6, angular@^1.8.2:
version "1.8.2"
resolved "https://registry.yarnpkg.com/angular/-/angular-1.8.2.tgz#5983bbb5a9fa63e213cb7749199e0d352de3a2f1"
@@ -4644,6 +4818,11 @@ async-each@^1.0.1:
resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.3.tgz#b727dbf87d7651602f06f4d4ac387f47d91b0cbf"
integrity sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ==
+async-foreach@^0.1.3:
+ version "0.1.3"
+ resolved "https://registry.yarnpkg.com/async-foreach/-/async-foreach-0.1.3.tgz#36121f845c0578172de419a97dbeb1d16ec34542"
+ integrity sha512-VUeSMD8nEGBWaZK4lizI1sf3yEC7pnAQ/mrI7pC2fBz2s/tq5jWWEngTwaf0Gruu/OoXRGLGg1XFqpYBiGTYJA==
+
async-value-promise@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/async-value-promise/-/async-value-promise-1.1.1.tgz#68957819e3eace804f3b4b69477e2bd276c15378"
@@ -5308,6 +5487,30 @@ cacache@^15.0.5, cacache@^15.2.0:
tar "^6.0.2"
unique-filename "^1.1.1"
+cacache@^16.1.0:
+ version "16.1.3"
+ resolved "https://registry.yarnpkg.com/cacache/-/cacache-16.1.3.tgz#a02b9f34ecfaf9a78c9f4bc16fceb94d5d67a38e"
+ integrity sha512-/+Emcj9DAXxX4cwlLmRI9c166RuL3w30zp4R7Joiv2cQTtTtA+jeuCAjH3ZlGnYS3tKENSrKhAzVVP9GVyzeYQ==
+ dependencies:
+ "@npmcli/fs" "^2.1.0"
+ "@npmcli/move-file" "^2.0.0"
+ chownr "^2.0.0"
+ fs-minipass "^2.1.0"
+ glob "^8.0.1"
+ infer-owner "^1.0.4"
+ lru-cache "^7.7.1"
+ minipass "^3.1.6"
+ minipass-collect "^1.0.2"
+ minipass-flush "^1.0.5"
+ minipass-pipeline "^1.2.4"
+ mkdirp "^1.0.4"
+ p-map "^4.0.0"
+ promise-inflight "^1.0.1"
+ rimraf "^3.0.2"
+ ssri "^9.0.0"
+ tar "^6.1.11"
+ unique-filename "^2.0.0"
+
cache-base@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2"
@@ -5440,7 +5643,7 @@ chalk@^3.0.0:
ansi-styles "^4.1.0"
supports-color "^7.1.0"
-chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.0, chalk@~4.1.0:
+chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.0, chalk@^4.1.2, chalk@~4.1.0:
version "4.1.2"
resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01"
integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==
@@ -5540,7 +5743,7 @@ cheerio@^1.0.0-rc.3:
parse5-htmlparser2-tree-adapter "^6.0.1"
tslib "^2.2.0"
-chokidar@3.5.3, "chokidar@>=2.0.0 <4.0.0", chokidar@^3.4.0, chokidar@^3.4.1, chokidar@^3.4.2:
+chokidar@3.5.3, chokidar@^3.4.0, chokidar@^3.4.1, chokidar@^3.4.2:
version "3.5.3"
resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.3.tgz#1cf37c8707b932bd1af1ae22c0432e2acd1903bd"
integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==
@@ -5942,11 +6145,12 @@ compress-commons@^4.1.0:
normalize-path "^3.0.0"
readable-stream "^3.6.0"
-compression-webpack-plugin@^4.0.0:
- version "4.0.1"
- resolved "https://registry.yarnpkg.com/compression-webpack-plugin/-/compression-webpack-plugin-4.0.1.tgz#33eda97f1170dd38c5556771de10f34245aa0274"
- integrity sha512-0mg6PgwTsUe5LEcUrOu3ob32vraDx2VdbMGAT1PARcOV+UJWDYZFdkSo6RbHoGQ061mmmkC7XpRKOlvwm/gzJQ==
+"compression-webpack-plugin@npm:@amoo-miki/compression-webpack-plugin@4.0.1-rc.1":
+ version "4.0.1-rc.1"
+ resolved "https://registry.yarnpkg.com/@amoo-miki/compression-webpack-plugin/-/compression-webpack-plugin-4.0.1-rc.1.tgz#a9736c353bca6b8f0f35c0cccdedb7070b3459db"
+ integrity sha512-cwh4PPeqhN1AZUB2t5LX7599rcN+/mbLneAz7EFe6oZIeip0t91jr0dQS7J7NouF43olmIfHTTcnXOskd6N9sQ==
dependencies:
+ "@node-rs/xxhash" "^1.3.0"
cacache "^15.0.5"
find-cache-dir "^3.3.1"
schema-utils "^2.7.0"
@@ -5988,11 +6192,6 @@ constants-browserify@^1.0.0:
resolved "https://registry.yarnpkg.com/constants-browserify/-/constants-browserify-1.0.0.tgz#c20b96d8c617748aaf1c16021760cd27fcb8cb75"
integrity sha1-wguW2MYXdIqvHBYCF2DNJ/y4y3U=
-container-info@^1.0.1:
- version "1.1.0"
- resolved "https://registry.yarnpkg.com/container-info/-/container-info-1.1.0.tgz#6fcb94e93eacd397c6316ca2834491ede44e55ee"
- integrity sha512-eD2zLAmxGS2kmL4f1jY8BdOqnmpL6X70kvzTBW/9FIQnxoxiBJ4htMsTmtPLPWRs7NHYFvqKQ1VtppV08mdsQA==
-
content-disposition@^0.5.4:
version "0.5.4"
resolved "https://registry.yarnpkg.com/content-disposition/-/content-disposition-0.5.4.tgz#8b82b4efac82512a02bb0b1dcec9d2c5e8eb5bfe"
@@ -6007,10 +6206,10 @@ convert-source-map@1.X, convert-source-map@^1.1.0, convert-source-map@^1.4.0, co
dependencies:
safe-buffer "~5.1.1"
-cookie@^0.4.0:
- version "0.4.2"
- resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.2.tgz#0e41f24de5ecf317947c82fc789e06a884824432"
- integrity sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA==
+cookie@^0.5.0:
+ version "0.5.0"
+ resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.5.0.tgz#d1f5d71adec6558c58f389987c366aa47e994f8b"
+ integrity sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==
cookiejar@^2.1.4:
version "2.1.4"
@@ -6889,7 +7088,7 @@ delayed-stream@~1.0.0:
delegates@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a"
- integrity sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=
+ integrity sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ==
delete-empty@^2.0.0:
version "2.0.0"
@@ -6905,6 +7104,11 @@ depd@^1.1.2:
resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9"
integrity sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=
+depd@^2.0.0:
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df"
+ integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==
+
dependency-check@^4.1.0:
version "4.1.0"
resolved "https://registry.yarnpkg.com/dependency-check/-/dependency-check-4.1.0.tgz#d45405cabb50298f8674fe28ab594c8a5530edff"
@@ -6938,10 +7142,10 @@ detect-indent@^5.0.0:
resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-5.0.0.tgz#3871cc0a6a002e8c3e5b3cf7f336264675f06b9d"
integrity sha1-OHHMCmoALow+Wzz38zYmRnXwa50=
-detect-libc@^1.0.3:
- version "1.0.3"
- resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b"
- integrity sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==
+detect-libc@^2.0.1:
+ version "2.0.1"
+ resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-2.0.1.tgz#e1897aa88fa6ad197862937fbc0441ef352ee0cd"
+ integrity sha512-463v3ZeIrcWtdgIg6vI6XUncguvr2TnGl4SzDXinkt9mSLpBJKXT3mW6xT3VQdDN11+WVs29pgvivTc4Lp8v+w==
detect-newline@2.X:
version "2.1.0"
@@ -7017,14 +7221,6 @@ diffie-hellman@^5.0.0:
miller-rabin "^4.0.0"
randombytes "^2.0.0"
-dir-glob@2.0.0:
- version "2.0.0"
- resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-2.0.0.tgz#0b205d2b6aef98238ca286598a8204d29d0a0034"
- integrity sha512-37qirFDz8cA5fimp9feo43fSuRo2gHwaIn6dXL8Ber1dGwUosDrGZeCCXq57WnIqE4aQ+u3eQZzsk1yOzhdwag==
- dependencies:
- arrify "^1.0.1"
- path-type "^3.0.0"
-
dir-glob@^2.2.2:
version "2.2.2"
resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-2.2.2.tgz#fa09f0694153c8918b18ba0deafae94769fc50c4"
@@ -7213,14 +7409,13 @@ ejs@^3.1.7:
dependencies:
jake "^10.8.5"
-elastic-apm-http-client@11.0.1:
- version "11.0.1"
- resolved "https://registry.yarnpkg.com/elastic-apm-http-client/-/elastic-apm-http-client-11.0.1.tgz#15dbe99d56d62b3f732d1bd2b51bef6094b78801"
- integrity sha512-5AOWlhs2WlZpI+DfgGqY/8Rk7KF8WeevaO8R961eBylavU6GWhLRNiJncohn5jsvrqhmeT19azBvy/oYRN7bJw==
+elastic-apm-http-client@11.2.0:
+ version "11.2.0"
+ resolved "https://registry.yarnpkg.com/elastic-apm-http-client/-/elastic-apm-http-client-11.2.0.tgz#4da8b975ca326c1e5beb59746ab1124c4feddad3"
+ integrity sha512-XHXK+gQmd34eRN/ffrml7AN4h1VwujB79WEO2C/J59ufvEk+mT1OGBhl6pntHPUWn4Um52C5m84O6jIXzaQwfw==
dependencies:
agentkeepalive "^4.2.1"
breadth-filter "^2.0.0"
- container-info "^1.0.1"
end-of-stream "^1.4.4"
fast-safe-stringify "^2.0.7"
fast-stream-to-buffer "^1.0.0"
@@ -7229,19 +7424,21 @@ elastic-apm-http-client@11.0.1:
semver "^6.3.0"
stream-chopper "^3.0.1"
-elastic-apm-node@^3.7.0:
- version "3.31.0"
- resolved "https://registry.yarnpkg.com/elastic-apm-node/-/elastic-apm-node-3.31.0.tgz#6e0bf622d922c95ff0127a263babcdeaeea71457"
- integrity sha512-0OulazfhkXYbOaGkHncqjwOfxtcvzsDyzUKr6Y1k95HwKrjf1Vi+xPutZv4p/WfDdO+JadphI0U2Uu5ncGB2iA==
+elastic-apm-node@^3.43.0:
+ version "3.43.0"
+ resolved "https://registry.yarnpkg.com/elastic-apm-node/-/elastic-apm-node-3.43.0.tgz#3d644cdb403c8230f5db7b6a3796d19e38faa2b7"
+ integrity sha512-iFuP8pXkfQst1LOFq6F86EjHhkvUL+pigpmbw2KL8rs+9i7Fn5pkxf8RP1G3oqwqydwUSdvw5+DPhO0lDO+LtA==
dependencies:
"@elastic/ecs-pino-format" "^1.2.0"
+ "@opentelemetry/api" "^1.1.0"
after-all-results "^2.0.0"
async-cache "^1.1.0"
async-value-promise "^1.1.1"
basic-auth "^2.0.1"
- cookie "^0.4.0"
+ cookie "^0.5.0"
core-util-is "^1.0.2"
- elastic-apm-http-client "11.0.1"
+ debug "^4.1.1"
+ elastic-apm-http-client "11.2.0"
end-of-stream "^1.4.4"
error-callsites "^2.0.4"
error-stack-parser "^2.0.6"
@@ -7251,20 +7448,19 @@ elastic-apm-node@^3.7.0:
is-native "^1.0.1"
lru-cache "^6.0.0"
measured-reporting "^1.51.1"
+ module-details-from-path "^1.0.3"
monitor-event-loop-delay "^1.0.0"
object-filter-sequence "^1.0.0"
object-identity-map "^1.0.2"
original-url "^1.2.3"
pino "^6.11.2"
- read-pkg-up "^7.0.1"
relative-microtime "^2.0.0"
- require-in-the-middle "^5.0.3"
+ resolve "^1.22.1"
semver "^6.3.0"
set-cookie-serde "^1.0.0"
shallow-clone-shim "^2.0.0"
source-map "^0.8.0-beta.0"
sql-summary "^1.0.1"
- traceparent "^1.0.0"
traverse "^0.6.6"
unicode-byte-truncate "^1.0.0"
@@ -7337,7 +7533,7 @@ emoticon@^3.2.0:
resolved "https://registry.yarnpkg.com/emoticon/-/emoticon-3.2.0.tgz#c008ca7d7620fac742fe1bf4af8ff8fed154ae7f"
integrity sha512-SNujglcLTTg+lDAcApPNgEdudaqQFiAbJCqzjNxJkvN9vAwCGi0uu8IUVvx+f16h+V44KCY6Y2yboroc9pilHg==
-encoding@^0.1.12:
+encoding@^0.1.12, encoding@^0.1.13:
version "0.1.13"
resolved "https://registry.yarnpkg.com/encoding/-/encoding-0.1.13.tgz#56574afdd791f54a8e9b2785c0582a2d26210fa9"
integrity sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==
@@ -8353,13 +8549,6 @@ fetch-mock@^7.3.9:
path-to-regexp "^2.2.1"
whatwg-url "^6.5.0"
-fibers@^5.0.3:
- version "5.0.3"
- resolved "https://registry.yarnpkg.com/fibers/-/fibers-5.0.3.tgz#2fd03acb255db66fe693d15beafbf5ae92193fd7"
- integrity sha512-/qYTSoZydQkM21qZpGLDLuCq8c+B8KhuCQ1kLPvnRNhxhVbvrpmH9l2+Lblf5neDuEsY4bfT7LeO553TXQDvJw==
- dependencies:
- detect-libc "^1.0.3"
-
figgy-pudding@^3.5.1:
version "3.5.2"
resolved "https://registry.yarnpkg.com/figgy-pudding/-/figgy-pudding-3.5.2.tgz#b4eee8148abb01dcf1d1ac34367d59e12fa61d6e"
@@ -8722,7 +8911,7 @@ fs-extra@~7.0.1:
jsonfile "^4.0.0"
universalify "^0.1.0"
-fs-minipass@^2.0.0:
+fs-minipass@^2.0.0, fs-minipass@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-2.1.0.tgz#7f5036fdbf12c63c169190cbe4199c852271f9fb"
integrity sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==
@@ -8809,6 +8998,13 @@ gauge@^4.0.3:
strip-ansi "^6.0.1"
wide-align "^1.1.5"
+gaze@^1.0.0:
+ version "1.1.3"
+ resolved "https://registry.yarnpkg.com/gaze/-/gaze-1.1.3.tgz#c441733e13b927ac8c0ff0b4c3b033f28812924a"
+ integrity sha512-BRdNm8hbWzFzWHERTrejLqwHDfS4GibPoq5wjTPIoJHoBtKGPg3xAFfxmM+9ztbXelxcf2hwQcaz1PtmFeue8g==
+ dependencies:
+ globule "^1.0.0"
+
geckodriver@^3.0.2:
version "3.2.0"
resolved "https://registry.yarnpkg.com/geckodriver/-/geckodriver-3.2.0.tgz#6b0a85e2aafbce209bca30e2d53af857707b1034"
@@ -8858,6 +9054,11 @@ get-package-type@^0.1.0:
resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a"
integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==
+get-stdin@^4.0.1:
+ version "4.0.1"
+ resolved "https://registry.yarnpkg.com/get-stdin/-/get-stdin-4.0.1.tgz#b968c6b0a04384324902e8bf1a5df32579a450fe"
+ integrity sha512-F5aQMywwJ2n85s4hJPTT9RPxGmubonuB10MNYo17/xph174n2MIR33HRguhzVag10O/npM7SPk73LMZNP+FaWw==
+
get-stdin@^6.0.0:
version "6.0.0"
resolved "https://registry.yarnpkg.com/get-stdin/-/get-stdin-6.0.0.tgz#9e09bf712b360ab9225e812048f71fde9c89657b"
@@ -8966,7 +9167,7 @@ glob-to-regexp@^0.4.0, glob-to-regexp@^0.4.1:
resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz#c75297087c851b9a578bd217dd59a92f59fe546e"
integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==
-glob@7.1.7, glob@~7.1.6:
+glob@7.1.7, glob@~7.1.1, glob@~7.1.6:
version "7.1.7"
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.7.tgz#3b193e9233f01d42d0b3f78294bbeeb418f94a90"
integrity sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==
@@ -8990,6 +9191,17 @@ glob@7.2.0, glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glo
once "^1.3.0"
path-is-absolute "^1.0.0"
+glob@^8.0.1:
+ version "8.1.0"
+ resolved "https://registry.yarnpkg.com/glob/-/glob-8.1.0.tgz#d388f656593ef708ee3e34640fdfb99a9fd1c33e"
+ integrity sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==
+ dependencies:
+ fs.realpath "^1.0.0"
+ inflight "^1.0.4"
+ inherits "2"
+ minimatch "^5.0.1"
+ once "^1.3.0"
+
glob@~5.0.0:
version "5.0.15"
resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1"
@@ -9094,19 +9306,6 @@ globby@^6.1.0:
pify "^2.0.0"
pinkie-promise "^2.0.0"
-globby@^8.0.1:
- version "8.0.2"
- resolved "https://registry.yarnpkg.com/globby/-/globby-8.0.2.tgz#5697619ccd95c5275dbb2d6faa42087c1a941d8d"
- integrity sha512-yTzMmKygLp8RUpG1Ymu2VXPSJQZjNAZPD4ywgYEaG7e4tBJeUQBO8OpXrf1RCNcEs5alsoJYPAMiIHP0cmeC7w==
- 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"
-
globby@^9.2.0:
version "9.2.0"
resolved "https://registry.yarnpkg.com/globby/-/globby-9.2.0.tgz#fd029a706c703d29bdd170f4b6db3a3f7a7cb63d"
@@ -9126,6 +9325,15 @@ globjoin@^0.1.4:
resolved "https://registry.yarnpkg.com/globjoin/-/globjoin-0.1.4.tgz#2f4494ac8919e3767c5cbb691e9f463324285d43"
integrity sha1-L0SUrIkZ43Z8XLtpHp9GMyQoXUM=
+globule@^1.0.0:
+ version "1.3.4"
+ resolved "https://registry.yarnpkg.com/globule/-/globule-1.3.4.tgz#7c11c43056055a75a6e68294453c17f2796170fb"
+ integrity sha512-OPTIfhMBh7JbBYDpa5b+Q5ptmMWKwcNcFSR/0c6t8V4f3ZAVBEsKNY37QdVqmLRYSMhOUGYrY0QhSoEpzGr/Eg==
+ dependencies:
+ glob "~7.1.1"
+ lodash "^4.17.21"
+ minimatch "~3.0.2"
+
got@11.8.5, got@^11.8.2:
version "11.8.5"
resolved "https://registry.yarnpkg.com/got/-/got-11.8.5.tgz#ce77d045136de56e8f024bebb82ea349bc730046"
@@ -9589,11 +9797,6 @@ hmac-drbg@^1.0.1:
minimalistic-assert "^1.0.0"
minimalistic-crypto-utils "^1.0.1"
-hoek@5.x.x:
- version "5.0.4"
- resolved "https://registry.yarnpkg.com/hoek/-/hoek-5.0.4.tgz#0f7fa270a1cafeb364a4b2ddfaa33f864e4157da"
- integrity sha512-Alr4ZQgoMlnere5FZJsIyfIjORBqZll5POhDsF4q64dPuJR6rNxXdDxtHSQq8OXRurhmx+PWYEE8bXRROY8h0w==
-
hoek@6.x.x:
version "6.1.3"
resolved "https://registry.yarnpkg.com/hoek/-/hoek-6.1.3.tgz#73b7d33952e01fe27a38b0457294b79dd8da242c"
@@ -9630,10 +9833,10 @@ hosted-git-info@^4.0.1:
dependencies:
lru-cache "^6.0.0"
-hpagent@^0.1.1:
- version "0.1.2"
- resolved "https://registry.yarnpkg.com/hpagent/-/hpagent-0.1.2.tgz#cab39c66d4df2d4377dbd212295d878deb9bdaa9"
- integrity sha512-ePqFXHtSQWAFXYmj+JtOTHr84iNrII4/QRlAAPPE+zqnKy4xJo7Ie1Y4kC7AdB+LxLxSTTzBMASsEcy0q8YyvQ==
+hpagent@^1.2.0:
+ version "1.2.0"
+ resolved "https://registry.yarnpkg.com/hpagent/-/hpagent-1.2.0.tgz#0ae417895430eb3770c03443456b8d90ca464903"
+ integrity sha512-A91dYTeIB6NoXG+PxTQpCCDDnfHsW9kc06Lvpu1TEe9gnd6ZFeiBoRO9JvzEv6xK7EX97/dUE8g/vBMTqTS3CA==
html-element-map@^1.2.0:
version "1.3.1"
@@ -9707,10 +9910,10 @@ htmlparser2@^7.0:
domutils "^2.8.0"
entities "^3.0.1"
-http-aws-es@6.0.0:
- version "6.0.0"
- resolved "https://registry.yarnpkg.com/http-aws-es/-/http-aws-es-6.0.0.tgz#1528978d2bee718b8732dcdced0856efa747aeff"
- integrity sha512-g+qp7J110/m4aHrR3iit4akAlnW0UljZ6oTq/rCcbsI8KP9x+95vqUtx49M2XQ2JMpwJio3B6gDYx+E8WDxqiA==
+"http-aws-es@npm:@zhongnansu/http-aws-es@6.0.1":
+ version "6.0.1"
+ resolved "https://registry.yarnpkg.com/@zhongnansu/http-aws-es/-/http-aws-es-6.0.1.tgz#1ab929eb7faa78ac5386c84069fb2e885fe1661c"
+ integrity sha512-uhe3FUtgT+sDyW2VA0hxQ44HUfeI8tf4nUo83mc3jtQPAIO57ZpRFKePmCoU+qaqHWfesD9hIQkTkXOJGlW26w==
http-cache-semantics@^4.0.0, http-cache-semantics@^4.1.0:
version "4.1.1"
@@ -9741,6 +9944,15 @@ http-proxy-agent@^4.0.1:
agent-base "6"
debug "4"
+http-proxy-agent@^5.0.0:
+ version "5.0.0"
+ resolved "https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz#5129800203520d434f142bc78ff3c170800f2b43"
+ integrity sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==
+ dependencies:
+ "@tootallnate/once" "2"
+ agent-base "6"
+ debug "4"
+
http2-wrapper@^1.0.0-beta.5.2:
version "1.0.3"
resolved "https://registry.yarnpkg.com/http2-wrapper/-/http2-wrapper-1.0.3.tgz#b8f55e0c1f25d4ebd08b3b0c2c079f9590800b3d"
@@ -9823,11 +10035,6 @@ iferr@^0.1.5:
resolved "https://registry.yarnpkg.com/iferr/-/iferr-0.1.5.tgz#c60eed69e6d8fdb6b3104a1fcbca1c192dc5b501"
integrity sha1-xg7taebY/bazEEofy8ocGS3FtQE=
-ignore@^3.3.5:
- version "3.3.10"
- resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043"
- integrity sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug==
-
ignore@^4.0.3, ignore@^4.0.6:
version "4.0.6"
resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc"
@@ -9979,11 +10186,6 @@ inquirer@^7.0.0, inquirer@^7.3.3:
strip-ansi "^6.0.0"
through "^2.3.6"
-install-artifact-from-github@^1.3.0:
- version "1.3.1"
- resolved "https://registry.yarnpkg.com/install-artifact-from-github/-/install-artifact-from-github-1.3.1.tgz#eefaad9af35d632e5d912ad1569c1de38c3c2462"
- integrity sha512-3l3Bymg2eKDsN5wQuMfgGEj2x6l5MCAv0zPL6rxHESufFVlEAKW/6oY9F1aGgvY/EgWm5+eWGRjINveL4X7Hgg==
-
internal-slot@^1.0.3:
version "1.0.3"
resolved "https://registry.yarnpkg.com/internal-slot/-/internal-slot-1.0.3.tgz#7347e307deeea2faac2ac6205d4bc7d34967f59c"
@@ -10182,10 +10384,10 @@ is-callable@^1.1.3, is-callable@^1.1.4, is-callable@^1.1.5, is-callable@^1.2.4:
resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.4.tgz#47301d58dd0259407865547853df6d61fe471945"
integrity sha512-nsuwtxZfMX67Oryl9LCQ+upnC0Z0BgpwntpS89m1H/TLF0zNfzfLMV/9Wa/6MZsj0acpEjAO0KF1xT6ZdLl95w==
-is-core-module@^2.1.0, is-core-module@^2.2.0, is-core-module@^2.5.0, is-core-module@^2.8.0, is-core-module@^2.8.1:
- version "2.8.1"
- resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.8.1.tgz#f59fdfca701d5879d0a6b100a40aa1560ce27211"
- integrity sha512-SdNCUs284hr40hFTFP6l0IfZ/RSrMXF3qgoRHd3/79unUTvrFO/JoXwkGm+5J/Oe3E/b5GsnG330uUNgRpu1PA==
+is-core-module@^2.1.0, is-core-module@^2.2.0, is-core-module@^2.5.0, is-core-module@^2.8.0, is-core-module@^2.9.0:
+ version "2.11.0"
+ resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.11.0.tgz#ad4cb3e3863e814523c96f3f58d26cc570ff0144"
+ integrity sha512-RRjxlvLDkD1YJwDbroBHMb+cukurkDWNyHx7D3oNB5x9rb5ogcksMC5wHCadcXoo67gVr/+3GFySh3134zi6rw==
dependencies:
has "^1.0.3"
@@ -10430,6 +10632,11 @@ is-potential-custom-element-name@^1.0.1:
resolved "https://registry.yarnpkg.com/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz#171ed6f19e3ac554394edf78caa05784a45bebb5"
integrity sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==
+is-primitive@^3.0.1:
+ version "3.0.1"
+ resolved "https://registry.yarnpkg.com/is-primitive/-/is-primitive-3.0.1.tgz#98c4db1abff185485a657fc2905052b940524d05"
+ integrity sha512-GljRxhWvlCNRfZyORiH77FwdFwGcMO620o37EOYC0ORWdq+WYNVqW0w2Juzew4M+L81l6/QS3t5gkkihyRqv9w==
+
is-promise@^2.1.0, is-promise@^2.2.2:
version "2.2.2"
resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1"
@@ -10735,10 +10942,10 @@ jake@^10.8.5:
filelist "^1.0.1"
minimatch "^3.0.4"
-jest-canvas-mock@^2.3.1:
- version "2.3.1"
- resolved "https://registry.yarnpkg.com/jest-canvas-mock/-/jest-canvas-mock-2.3.1.tgz#9535d14bc18ccf1493be36ac37dd349928387826"
- integrity sha512-5FnSZPrX3Q2ZfsbYNE3wqKR3+XorN8qFzDzB5o0golWgt6EOX1+emBnpOc9IAQ+NXFj8Nzm3h7ZdE/9H0ylBcg==
+jest-canvas-mock@^2.5.1:
+ version "2.5.1"
+ resolved "https://registry.yarnpkg.com/jest-canvas-mock/-/jest-canvas-mock-2.5.1.tgz#81509af658ef485e9a1bf39c64e06761517bdbcb"
+ integrity sha512-IVnRiz+v4EYn3ydM/pBo8GW/J+nU/Hg5gHBQQOUQhdRyNfvHnabB8ReqARLO0p+kvQghqr4V0tA92CF3JcUSRg==
dependencies:
cssfontparser "^1.2.1"
moo-color "^1.0.2"
@@ -11187,12 +11394,12 @@ jmespath@0.16.0:
resolved "https://registry.yarnpkg.com/jmespath/-/jmespath-0.16.0.tgz#b15b0a85dfd4d930d43e69ed605943c802785076"
integrity sha512-9FzQjJ7MATs1tSpnco1K6ayiYE3figslrXA72G2HQ/n76RzvYlofyi5QM+iX4YRs/pu3yzxlVQSST23+dMDknw==
-joi@^13.5.2:
- version "13.7.0"
- resolved "https://registry.yarnpkg.com/joi/-/joi-13.7.0.tgz#cfd85ebfe67e8a1900432400b4d03bbd93fb879f"
- integrity sha512-xuY5VkHfeOYK3Hdi91ulocfuFopwgbSORmIwzcwHKESQhC7w1kD5jaVSPnqDxS2I8t3RZ9omCKAxNwXN5zG1/Q==
+joi@^14.3.1:
+ version "14.3.1"
+ resolved "https://registry.yarnpkg.com/joi/-/joi-14.3.1.tgz#164a262ec0b855466e0c35eea2a885ae8b6c703c"
+ integrity sha512-LQDdM+pkOrpAn4Lp+neNIFV3axv1Vna3j38bisbQhETPMANYRbFJFUyOZcOClYvM/hppMhGWuKSFEK9vjrB+bQ==
dependencies:
- hoek "5.x.x"
+ hoek "6.x.x"
isemail "3.x.x"
topo "3.x.x"
@@ -11217,6 +11424,11 @@ jquery@^3.5.0:
resolved "https://registry.yarnpkg.com/jquery/-/jquery-3.6.0.tgz#c72a09f15c1bdce142f49dbf1170bdf8adac2470"
integrity sha512-JVzAR/AjBvVt2BmYhxRCSYysDsPcssdmTFnzyLEts9qNwmjmu4JTAMYubEfwVOSwpQ1I1sKKFcxhZCI2buerfw==
+js-base64@^2.4.9:
+ version "2.6.4"
+ resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.6.4.tgz#f4e686c5de1ea1f867dbcad3d46d969428df98c4"
+ integrity sha512-pZe//GGmwJndub7ZghVHz7vjb2LgC1m8B07Au3eYqeqv9emhESByMXxaEgkUkEqJe87oBbSniGYoQNIBklc7IQ==
+
js-cookie@^2.2.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/js-cookie/-/js-cookie-2.2.1.tgz#69e106dc5d5806894562902aa5baec3744e9b2b8"
@@ -11234,14 +11446,14 @@ js-yaml-js-types@1.0.0:
dependencies:
esprima "^4.0.1"
-js-yaml@4.1.0:
+js-yaml@4.1.0, js-yaml@^4.1.0:
version "4.1.0"
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-4.1.0.tgz#c1fb65f8f5017901cdd2c951864ba18458a10602"
integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==
dependencies:
argparse "^2.0.1"
-js-yaml@^3.13.1, js-yaml@^3.14.0, js-yaml@~3.14.0:
+js-yaml@^3.13.1, js-yaml@~3.14.0:
version "3.14.1"
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537"
integrity sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==
@@ -11622,16 +11834,24 @@ listr@^0.14.1:
p-map "^2.0.0"
rxjs "^6.3.3"
-lmdb-store@^1.6.11:
- version "1.6.14"
- resolved "https://registry.yarnpkg.com/lmdb-store/-/lmdb-store-1.6.14.tgz#8aa5f36fb04195f8639a3b01b32f6696867f2bc9"
- integrity sha512-4woZfvfgolMEngjoMJrwePjdLotr3QKGJsDWURlJmKBed5JtE00IfAKo7ryPowl4ksGcs21pcdLkwrPnKomIuA==
- dependencies:
- msgpackr "^1.5.0"
- nan "^2.14.2"
- node-gyp-build "^4.2.3"
- ordered-binary "^1.0.0"
- weak-lru-cache "^1.0.0"
+lmdb@^2.8.0:
+ version "2.8.0"
+ resolved "https://registry.yarnpkg.com/lmdb/-/lmdb-2.8.0.tgz#0f0aee59e35e6f890d75c02d0860e260bc95955a"
+ integrity sha512-KMBd90xia9x289LlwDtZkqvyXDFM1cZATxKm965uo3Nq2eaBTy+fmJsHf7+d6xXtFDANxKzWVvrbkThAAI2lfg==
+ dependencies:
+ msgpackr "1.9.1"
+ node-addon-api "^6.1.0"
+ node-gyp-build-optional-packages "5.1.0"
+ ordered-binary "^1.4.0"
+ weak-lru-cache "^1.2.2"
+ yarn "^1.22.19"
+ optionalDependencies:
+ "@lmdb/lmdb-darwin-arm64" "2.8.0"
+ "@lmdb/lmdb-darwin-x64" "2.8.0"
+ "@lmdb/lmdb-linux-arm" "2.8.0"
+ "@lmdb/lmdb-linux-arm64" "2.8.0"
+ "@lmdb/lmdb-linux-x64" "2.8.0"
+ "@lmdb/lmdb-win32-x64" "2.8.0"
load-bmfont@^1.3.1, load-bmfont@^1.4.0:
version "1.4.1"
@@ -11966,6 +12186,11 @@ lru-cache@^6.0.0:
dependencies:
yallist "^4.0.0"
+lru-cache@^7.7.1:
+ version "7.18.3"
+ resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-7.18.3.tgz#f793896e0fd0e954a59dfdd82f0773808df6aa89"
+ integrity sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA==
+
lru-queue@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/lru-queue/-/lru-queue-0.1.0.tgz#2738bd9f0d3cf4f84490c5736c48699ac632cda3"
@@ -11993,6 +12218,28 @@ make-dir@^3.0.0, make-dir@^3.0.2, make-dir@^3.1.0:
dependencies:
semver "^6.0.0"
+make-fetch-happen@^10.0.4:
+ version "10.2.1"
+ resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-10.2.1.tgz#f5e3835c5e9817b617f2770870d9492d28678164"
+ integrity sha512-NgOPbRiaQM10DYXvN3/hhGVI2M5MtITFryzBGxHM5p4wnFxsVCbxkrBrDsk+EZ5OB4jEOT7AjDxtdF+KVEFT7w==
+ dependencies:
+ agentkeepalive "^4.2.1"
+ cacache "^16.1.0"
+ http-cache-semantics "^4.1.0"
+ http-proxy-agent "^5.0.0"
+ https-proxy-agent "^5.0.0"
+ is-lambda "^1.0.1"
+ lru-cache "^7.7.1"
+ minipass "^3.1.6"
+ minipass-collect "^1.0.2"
+ minipass-fetch "^2.0.3"
+ minipass-flush "^1.0.5"
+ minipass-pipeline "^1.2.4"
+ negotiator "^0.6.3"
+ promise-retry "^2.0.1"
+ socks-proxy-agent "^7.0.0"
+ ssri "^9.0.0"
+
make-fetch-happen@^9.1.0:
version "9.1.0"
resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-9.1.0.tgz#53085a09e7971433e6765f7971bf63f4e05cb968"
@@ -12362,7 +12609,14 @@ minimatch@5.0.1:
dependencies:
brace-expansion "^2.0.1"
-minimatch@~3.0.4:
+minimatch@^5.0.1:
+ version "5.1.6"
+ resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.6.tgz#1cfcb8cf5522ea69952cd2af95ae09477f122a96"
+ integrity sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==
+ dependencies:
+ brace-expansion "^2.0.1"
+
+minimatch@~3.0.2, minimatch@~3.0.4:
version "3.0.8"
resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.8.tgz#5e6a59bd11e2ab0de1cfb843eb2d82e546c321c1"
integrity sha512-6FsRAQsxQ61mw+qP1ZzbL9Bc78x2p5OqNgNpnoAFLTrX8n5Kxph0CsnhmKKNXTWjXqU5L0pGPR7hYk+XWZr60Q==
@@ -12401,6 +12655,17 @@ minipass-fetch@^1.3.2:
optionalDependencies:
encoding "^0.1.12"
+minipass-fetch@^2.0.3:
+ version "2.1.2"
+ resolved "https://registry.yarnpkg.com/minipass-fetch/-/minipass-fetch-2.1.2.tgz#95560b50c472d81a3bc76f20ede80eaed76d8add"
+ integrity sha512-LT49Zi2/WMROHYoqGgdlQIZh8mLPZmOrN2NdJjMXxYe4nkN6FUyuPuOAOedNJDrx0IRGg9+4guZewtp8hE6TxA==
+ dependencies:
+ minipass "^3.1.6"
+ minipass-sized "^1.0.3"
+ minizlib "^2.1.2"
+ optionalDependencies:
+ encoding "^0.1.13"
+
minipass-flush@^1.0.5:
version "1.0.5"
resolved "https://registry.yarnpkg.com/minipass-flush/-/minipass-flush-1.0.5.tgz#82e7135d7e89a50ffe64610a787953c4c4cbb373"
@@ -12429,7 +12694,7 @@ minipass@^3.0.0, minipass@^3.1.1:
dependencies:
yallist "^4.0.0"
-minipass@^3.1.0, minipass@^3.1.3:
+minipass@^3.1.0, minipass@^3.1.3, minipass@^3.1.6:
version "3.3.6"
resolved "https://registry.yarnpkg.com/minipass/-/minipass-3.3.6.tgz#7bba384db3a1520d18c9c0e5251c3444e95dd94a"
integrity sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==
@@ -12443,7 +12708,12 @@ minipass@^4.0.0:
dependencies:
yallist "^4.0.0"
-minizlib@^2.0.0, minizlib@^2.1.1:
+minipass@^5.0.0:
+ version "5.0.0"
+ resolved "https://registry.yarnpkg.com/minipass/-/minipass-5.0.0.tgz#3e9788ffb90b694a5d0ec94479a45b5d8738133d"
+ integrity sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==
+
+minizlib@^2.0.0, minizlib@^2.1.1, minizlib@^2.1.2:
version "2.1.2"
resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-2.1.2.tgz#e90d3466ba209b932451508a11ce3d3632145931"
integrity sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==
@@ -12610,20 +12880,26 @@ ms@2.1.3, ms@^2.0.0, ms@^2.1.1, ms@^2.1.3:
resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2"
integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==
-msgpackr-extract@^1.0.14:
- version "1.0.16"
- resolved "https://registry.yarnpkg.com/msgpackr-extract/-/msgpackr-extract-1.0.16.tgz#701c4f6e6f25c100ae84557092274e8fffeefe45"
- integrity sha512-fxdRfQUxPrL/TizyfYfMn09dK58e+d65bRD/fcaVH4052vj30QOzzqxcQIS7B0NsqlypEQ/6Du3QmP2DhWFfCA==
+msgpackr-extract@^3.0.2:
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/msgpackr-extract/-/msgpackr-extract-3.0.2.tgz#e05ec1bb4453ddf020551bcd5daaf0092a2c279d"
+ integrity sha512-SdzXp4kD/Qf8agZ9+iTu6eql0m3kWm1A2y1hkpTeVNENutaB0BwHlSvAIaMxwntmRUAUjon2V4L8Z/njd0Ct8A==
dependencies:
- nan "^2.14.2"
- node-gyp-build "^4.2.3"
-
-msgpackr@^1.5.0:
- version "1.5.5"
- resolved "https://registry.yarnpkg.com/msgpackr/-/msgpackr-1.5.5.tgz#c0562abc2951d7e29f75d77a8656b01f103a042c"
- integrity sha512-JG0V47xRIQ9pyUnx6Hb4+3TrQoia2nA3UIdmyTldhxaxtKFkekkKpUW/N6fwHwod9o4BGuJGtouxOk+yCP5PEA==
+ node-gyp-build-optional-packages "5.0.7"
+ optionalDependencies:
+ "@msgpackr-extract/msgpackr-extract-darwin-arm64" "3.0.2"
+ "@msgpackr-extract/msgpackr-extract-darwin-x64" "3.0.2"
+ "@msgpackr-extract/msgpackr-extract-linux-arm" "3.0.2"
+ "@msgpackr-extract/msgpackr-extract-linux-arm64" "3.0.2"
+ "@msgpackr-extract/msgpackr-extract-linux-x64" "3.0.2"
+ "@msgpackr-extract/msgpackr-extract-win32-x64" "3.0.2"
+
+msgpackr@1.9.1:
+ version "1.9.1"
+ resolved "https://registry.yarnpkg.com/msgpackr/-/msgpackr-1.9.1.tgz#4375d705232b721bedb44a3993e7aa8a6f959502"
+ integrity sha512-jJdrNH8tzfCtT0rjPFryBXjRDQE7rqfLkah4/8B4gYa7NNZYFBcGxqWBtfQpGC+oYyBwlkj3fARk4aooKNPHxg==
optionalDependencies:
- msgpackr-extract "^1.0.14"
+ msgpackr-extract "^3.0.2"
multimatch@^4.0.0:
version "4.0.0"
@@ -12656,12 +12932,12 @@ mute-stream@0.0.8:
resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.8.tgz#1630c42b2251ff81e2a283de96a5497ea92e5e0d"
integrity sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==
-nan@^2.12.1, nan@^2.14.2:
+nan@^2.12.1:
version "2.15.0"
resolved "https://registry.yarnpkg.com/nan/-/nan-2.15.0.tgz#3f34a473ff18e15c1b5626b62903b5ad6e665fee"
integrity sha512-8ZtvEnA2c5aYCZYd1cvgdnU6cqwixRoYg70xPLWUws5ORTa/lnw+u4amixRS/Ac5U5mQVgp9pnlSUnbNWFaWZQ==
-nan@^2.15.0:
+nan@^2.17.0:
version "2.17.0"
resolved "https://registry.yarnpkg.com/nan/-/nan-2.17.0.tgz#c0150a2368a182f033e9aa5195ec76ea41a199cb"
integrity sha512-2ZTgtl0nJsO0KQCjEpxcIr5D+Yv90plTitZt9JBfQvVJDS5seMl3FOvsh3+9CoYWXf/1l5OaZzzF6nDm4cagaQ==
@@ -12736,7 +13012,7 @@ needle@^2.5.2:
iconv-lite "^0.4.4"
sax "^1.2.4"
-negotiator@^0.6.2:
+negotiator@^0.6.2, negotiator@^0.6.3:
version "0.6.3"
resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.3.tgz#58e323a72fedc0d6f9cd4d31fe49f51479590ccd"
integrity sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==
@@ -12800,6 +13076,11 @@ nock@12.0.3:
lodash "^4.17.13"
propagate "^2.0.0"
+node-addon-api@^6.1.0:
+ version "6.1.0"
+ resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-6.1.0.tgz#ac8470034e58e67d0c6f1204a18ae6995d9c0d76"
+ integrity sha512-+eawOlIgy680F0kBzPUNFhMZGtJ1YmqM6l4+Crf4IkImjYrO/mqPwRMh352g23uIaQKFItcQ64I7KMaJxHgAVA==
+
node-emoji@^1.10.0:
version "1.11.0"
resolved "https://registry.yarnpkg.com/node-emoji/-/node-emoji-1.11.0.tgz#69a0150e6946e2f115e9d7ea4df7971e2628301c"
@@ -12819,10 +13100,17 @@ node-forge@^1.2.1, node-forge@^1.3.0:
resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-1.3.1.tgz#be8da2af243b2417d5f646a770663a92b7e9ded3"
integrity sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==
-node-gyp-build@^4.2.3:
- version "4.3.0"
- resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.3.0.tgz#9f256b03e5826150be39c764bf51e993946d71a3"
- integrity sha512-iWjXZvmboq0ja1pUGULQBexmxq8CV4xBhX7VDOTbL7ZR4FOowwY/VOtRxBN/yKxmdGoIp4j5ysNT4u3S2pDQ3Q==
+node-gyp-build-optional-packages@5.0.7:
+ version "5.0.7"
+ resolved "https://registry.yarnpkg.com/node-gyp-build-optional-packages/-/node-gyp-build-optional-packages-5.0.7.tgz#5d2632bbde0ab2f6e22f1bbac2199b07244ae0b3"
+ integrity sha512-YlCCc6Wffkx0kHkmam79GKvDQ6x+QZkMjFGrIMxgFNILFvGSbCp2fCBC55pGTT9gVaz8Na5CLmxt/urtzRv36w==
+
+node-gyp-build-optional-packages@5.1.0:
+ version "5.1.0"
+ resolved "https://registry.yarnpkg.com/node-gyp-build-optional-packages/-/node-gyp-build-optional-packages-5.1.0.tgz#25f59b09bee310dd1b14d7ce539aa7c6093109b7"
+ integrity sha512-Jy0ZKyeFh3QwhJT2augyHuhn0WZ15osYBKNw4U6WAp8nadAgcB60uKJ80Y7HG2OkKnTNOtiUwqNZbSKW/nkvKg==
+ dependencies:
+ detect-libc "^2.0.1"
node-gyp@^8.4.1:
version "8.4.1"
@@ -12901,6 +13189,26 @@ node-releases@^2.0.2:
resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.2.tgz#7139fe71e2f4f11b47d4d2986aaf8c48699e0c01"
integrity sha512-XxYDdcQ6eKqp/YjI+tb2C5WM2LgjnZrfYg4vgQt49EK268b6gYCHsBLrK2qvJo4FmCtqmKezb0WZFK4fkrZNsg==
+node-sass@^8.0.0:
+ version "8.0.0"
+ resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-8.0.0.tgz#c80d52148db0ce88610bcf1e1d112027393c13e1"
+ integrity sha512-jPzqCF2/e6JXw6r3VxfIqYc8tKQdkj5Z/BDATYyG6FL6b/LuYBNFGFVhus0mthcWifHm/JzBpKAd+3eXsWeK/A==
+ dependencies:
+ async-foreach "^0.1.3"
+ chalk "^4.1.2"
+ cross-spawn "^7.0.3"
+ gaze "^1.0.0"
+ get-stdin "^4.0.1"
+ glob "^7.0.3"
+ lodash "^4.17.15"
+ make-fetch-happen "^10.0.4"
+ meow "^9.0.0"
+ nan "^2.17.0"
+ node-gyp "^8.4.1"
+ sass-graph "^4.0.1"
+ stdout-stream "^1.4.0"
+ "true-case-path" "^2.2.1"
+
node-stream-zip@^1.15.0:
version "1.15.0"
resolved "https://registry.yarnpkg.com/node-stream-zip/-/node-stream-zip-1.15.0.tgz#158adb88ed8004c6c49a396b50a6a5de3bca33ea"
@@ -13264,10 +13572,10 @@ ora@^4.0.4:
strip-ansi "^6.0.0"
wcwidth "^1.0.1"
-ordered-binary@^1.0.0:
- version "1.2.4"
- resolved "https://registry.yarnpkg.com/ordered-binary/-/ordered-binary-1.2.4.tgz#51d3a03af078a0bdba6c7bc8f4fedd1f5d45d83e"
- integrity sha512-A/csN0d3n+igxBPfUrjbV5GC69LWj2pjZzAAeeHXLukQ4+fytfP4T1Lg0ju7MSPSwq7KtHkGaiwO8URZN5IpLg==
+ordered-binary@^1.4.0:
+ version "1.4.0"
+ resolved "https://registry.yarnpkg.com/ordered-binary/-/ordered-binary-1.4.0.tgz#6bb53d44925f3b8afc33d1eed0fa15693b211389"
+ integrity sha512-EHQ/jk4/a9hLupIKxTfUsQRej1Yd/0QLQs3vGvIqg5ZtCYSzNhkzHoZc7Zf4e4kUlDaC3Uw8Q/1opOLNN2OKRQ==
ordered-read-streams@^1.0.0:
version "1.0.1"
@@ -14191,11 +14499,6 @@ randexp@0.4.6:
discontinuous-range "1.0.0"
ret "~0.1.10"
-random-poly-fill@^1.0.1:
- version "1.0.1"
- resolved "https://registry.yarnpkg.com/random-poly-fill/-/random-poly-fill-1.0.1.tgz#13634dc0255a31ecf85d4a182d92c40f9bbcf5ed"
- integrity sha512-bMOL0hLfrNs52+EHtIPIXxn2PxYwXb0qjnKruTjXiM/sKfYqj506aB2plFwWW1HN+ri724bAVVGparh4AtlJKw==
-
randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.5, randombytes@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a"
@@ -14224,15 +14527,6 @@ re-reselect@^3.4.0:
resolved "https://registry.yarnpkg.com/re-reselect/-/re-reselect-3.4.0.tgz#0f2303f3c84394f57f0cd31fea08a1ca4840a7cd"
integrity sha512-JsecfN+JlckncVXTWFWjn0Vk6uInl8GSf4eEd9tTk5qXHlgqkPdILpnYpgZcISXNYAzvfvsCZviaDk8AxyS5sg==
-re2@1.17.4:
- version "1.17.4"
- resolved "https://registry.yarnpkg.com/re2/-/re2-1.17.4.tgz#7bf29290bdde963014e77bd2c2e799a6d788386e"
- integrity sha512-xyZ4h5PqE8I9tAxTh3G0UttcK5ufrcUxReFjGzfX61vtanNbS1XZHjnwRSyPcLgChI4KLxVgOT/ioZXnUAdoTA==
- dependencies:
- install-artifact-from-github "^1.3.0"
- nan "^2.15.0"
- node-gyp "^8.4.1"
-
react-ace@^7.0.5:
version "7.0.5"
resolved "https://registry.yarnpkg.com/react-ace/-/react-ace-7.0.5.tgz#798299fd52ddf3a3dcc92afc5865538463544f01"
@@ -14979,7 +15273,7 @@ require-from-string@^2.0.2:
resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909"
integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==
-require-in-the-middle@^5.0.2, require-in-the-middle@^5.0.3:
+require-in-the-middle@^5.0.2:
version "5.1.0"
resolved "https://registry.yarnpkg.com/require-in-the-middle/-/require-in-the-middle-5.1.0.tgz#b768f800377b47526d026bbf5a7f727f16eb412f"
integrity sha512-M2rLKVupQfJ5lf9OvqFGIT+9iVLnTmjgbOmpil12hiSQNn5zJTKGPoIisETNjfK+09vP3rpm1zJajmErpr2sEQ==
@@ -15087,12 +15381,12 @@ resolve.exports@^1.1.0:
resolved "https://registry.yarnpkg.com/resolve.exports/-/resolve.exports-1.1.0.tgz#5ce842b94b05146c0e03076985d1d0e7e48c90c9"
integrity sha512-J1l+Zxxp4XK3LUDZ9m60LRJF/mAe4z6a4xyabPHk7pvK5t35dACV32iIjJDFeWZFfZlO29w6SZ67knR0tHzJtQ==
-resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.10.1, resolve@^1.12.0, resolve@^1.14.2, resolve@^1.19.0, resolve@^1.20.0, resolve@^1.5.0, resolve@^1.7.1, resolve@^1.9.0:
- version "1.22.0"
- resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.0.tgz#5e0b8c67c15df57a89bdbabe603a002f21731198"
- integrity sha512-Hhtrw0nLeSrFQ7phPp4OOcVjLPIeMnRlr5mcnVuMe7M/7eBn98A3hmFRLoFo3DLZkivSYwhRUJTyPyWAk56WLw==
+resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.10.1, resolve@^1.12.0, resolve@^1.14.2, resolve@^1.19.0, resolve@^1.20.0, resolve@^1.22.1, resolve@^1.5.0, resolve@^1.7.1, resolve@^1.9.0:
+ version "1.22.1"
+ resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.1.tgz#27cb2ebb53f91abb49470a928bba7558066ac177"
+ integrity sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw==
dependencies:
- is-core-module "^2.8.1"
+ is-core-module "^2.9.0"
path-parse "^1.0.7"
supports-preserve-symlinks-flag "^1.0.0"
@@ -15283,10 +15577,20 @@ safefs@^6.12.0:
resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a"
integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==
-sass-loader@^10.2.0:
- version "10.2.1"
- resolved "https://registry.yarnpkg.com/sass-loader/-/sass-loader-10.2.1.tgz#17e51df313f1a7a203889ce8ff91be362651276e"
- integrity sha512-RRvWl+3K2LSMezIsd008ErK4rk6CulIMSwrcc2aZvjymUgKo/vjXGp1rSWmfTUX7bblEOz8tst4wBwWtCGBqKA==
+sass-graph@^4.0.1:
+ version "4.0.1"
+ resolved "https://registry.yarnpkg.com/sass-graph/-/sass-graph-4.0.1.tgz#2ff8ca477224d694055bf4093f414cf6cfad1d2e"
+ integrity sha512-5YCfmGBmxoIRYHnKK2AKzrAkCoQ8ozO+iumT8K4tXJXRVCPf+7s1/9KxTSW3Rbvf+7Y7b4FR3mWyLnQr3PHocA==
+ dependencies:
+ glob "^7.0.0"
+ lodash "^4.17.11"
+ scss-tokenizer "^0.4.3"
+ yargs "^17.2.1"
+
+sass-loader@^10.4.1:
+ version "10.4.1"
+ resolved "https://registry.yarnpkg.com/sass-loader/-/sass-loader-10.4.1.tgz#bea4e173ddf512c9d7f53e9ec686186146807cbf"
+ integrity sha512-aX/iJZTTpNUNx/OSYzo2KsjIUQHqvWsAhhUijFjAPdZTEhstjZI9zTNvkTTwsx+uNUJqUwOw5gacxQMx4hJxGQ==
dependencies:
klona "^2.0.4"
loader-utils "^2.0.0"
@@ -15294,13 +15598,6 @@ sass-loader@^10.2.0:
schema-utils "^3.0.0"
semver "^7.3.2"
-sass@~1.26.11:
- version "1.26.12"
- resolved "https://registry.yarnpkg.com/sass/-/sass-1.26.12.tgz#79eddaa1773fff32ccf19e00d1ce380fc2afc7d0"
- integrity sha512-hmSwtBOWoS9zwe0yAS+QmaseVCUELiGV22gXHDR7+9stEsVuEuxfY1GhC8XmUpC+Ir3Hwq7NxSUNbnmkznnF7g==
- dependencies:
- chokidar ">=2.0.0 <4.0.0"
-
sax@1.2.1:
version "1.2.1"
resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.1.tgz#7b8e656190b228e81a66aea748480d828cd2d37a"
@@ -15358,6 +15655,14 @@ screenfull@^5.0.0:
resolved "https://registry.yarnpkg.com/screenfull/-/screenfull-5.2.0.tgz#6533d524d30621fc1283b9692146f3f13a93d1ba"
integrity sha512-9BakfsO2aUQN2K9Fdbj87RJIEZ82Q9IGim7FqM5OsebfoFC6ZHXgDq/KvniuLTPdeM8wY2o6Dj3WQ7KeQCj3cA==
+scss-tokenizer@^0.4.3:
+ version "0.4.3"
+ resolved "https://registry.yarnpkg.com/scss-tokenizer/-/scss-tokenizer-0.4.3.tgz#1058400ee7d814d71049c29923d2b25e61dc026c"
+ integrity sha512-raKLgf1LI5QMQnG+RxHz6oK0sL3x3I4FN2UDLqgLOGO8hodECNnNh5BXn7fAyBxrA8zVzdQizQ6XjNJQ+uBwMw==
+ dependencies:
+ js-base64 "^2.4.9"
+ source-map "^0.7.3"
+
secure-json-parse@^2.4.0:
version "2.4.0"
resolved "https://registry.yarnpkg.com/secure-json-parse/-/secure-json-parse-2.4.0.tgz#5aaeaaef85c7a417f76271a4f5b0cc3315ddca85"
@@ -15440,15 +15745,13 @@ set-immediate-shim@~1.0.1:
resolved "https://registry.yarnpkg.com/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz#4b2b1b27eb808a9f8dcc481a58e5e56f599f3f61"
integrity sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E=
-set-value@^2.0.0, set-value@^2.0.1:
- version "2.0.1"
- resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.1.tgz#a18d40530e6f07de4228c7defe4227af8cad005b"
- integrity sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw==
+set-value@^2.0.0, set-value@^2.0.1, set-value@^4.1.0:
+ version "4.1.0"
+ resolved "https://registry.yarnpkg.com/set-value/-/set-value-4.1.0.tgz#aa433662d87081b75ad88a4743bd450f044e7d09"
+ integrity sha512-zTEg4HL0RwVrqcWs3ztF+x1vkxfm0lP+MQQFPiMJTKVceBwEV0A569Ou8l9IYQG8jOZdMVI1hGsc0tmeD2o/Lw==
dependencies:
- extend-shallow "^2.0.1"
- is-extendable "^0.1.1"
- is-plain-object "^2.0.3"
- split-string "^3.0.1"
+ is-plain-object "^2.0.4"
+ is-primitive "^3.0.1"
setimmediate@^1.0.4:
version "1.0.5"
@@ -15561,11 +15864,6 @@ sisteransi@^1.0.5:
resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.5.tgz#134d681297756437cc05ca01370d3a7a571075ed"
integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==
-slash@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55"
- integrity sha512-3TYDR7xWt4dIqV2JauJr+EJeW356RXijHeUlO+8djJ+uBXPn8/2dpzBc8yQhh583sVvc9CvFAeQVgijsH+PNNg==
-
slash@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/slash/-/slash-2.0.0.tgz#de552851a1759df3a8f206535442f5ec4ddeab44"
@@ -15648,6 +15946,15 @@ socks-proxy-agent@^6.0.0:
debug "^4.3.3"
socks "^2.6.2"
+socks-proxy-agent@^7.0.0:
+ version "7.0.0"
+ resolved "https://registry.yarnpkg.com/socks-proxy-agent/-/socks-proxy-agent-7.0.0.tgz#dc069ecf34436621acb41e3efa66ca1b5fed15b6"
+ integrity sha512-Fgl0YPZ902wEsAyiQ+idGd1A7rSFx/ayC1CQVMw5P+EQx2V0SgpGtf6OKFhVjPflPUl9YMmEOnmfjCdMUsygww==
+ dependencies:
+ agent-base "^6.0.2"
+ debug "^4.3.3"
+ socks "^2.6.2"
+
socks@^2.6.2:
version "2.7.1"
resolved "https://registry.yarnpkg.com/socks/-/socks-2.7.1.tgz#d8e651247178fde79c0663043e07240196857d55"
@@ -15863,7 +16170,7 @@ split-on-first@^1.0.0:
resolved "https://registry.yarnpkg.com/split-on-first/-/split-on-first-1.1.0.tgz#f610afeee3b12bce1d0c30425e76398b78249a5f"
integrity sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw==
-split-string@^3.0.1, split-string@^3.0.2:
+split-string@^3.0.2:
version "3.1.0"
resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2"
integrity sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==
@@ -15907,6 +16214,13 @@ ssri@^8.0.0, ssri@^8.0.1:
dependencies:
minipass "^3.1.1"
+ssri@^9.0.0:
+ version "9.0.1"
+ resolved "https://registry.yarnpkg.com/ssri/-/ssri-9.0.1.tgz#544d4c357a8d7b71a19700074b6883fcb4eae057"
+ integrity sha512-o57Wcn66jMQvfHG1FlYbWeZWW/dHZhJXjpIcTfXldXEk5nz5lStPo3mK0OJQfGR3RbZUlbISexbljkJzuEj/8Q==
+ dependencies:
+ minipass "^3.1.1"
+
stack-generator@^2.0.5:
version "2.0.5"
resolved "https://registry.yarnpkg.com/stack-generator/-/stack-generator-2.0.5.tgz#fb00e5b4ee97de603e0773ea78ce944d81596c36"
@@ -15961,6 +16275,13 @@ static-extend@^0.1.1:
define-property "^0.2.5"
object-copy "^0.1.0"
+stdout-stream@^1.4.0:
+ version "1.4.1"
+ resolved "https://registry.yarnpkg.com/stdout-stream/-/stdout-stream-1.4.1.tgz#5ac174cdd5cd726104aa0c0b2bd83815d8d535de"
+ integrity sha512-j4emi03KXqJWcIeF8eIXkjMFN1Cmb8gUlDYGeBALLPo5qdyTfA9bOtl8m33lRoC+vFMkP3gl0WsDr6+gzxbbTA==
+ dependencies:
+ readable-stream "^2.0.1"
+
stream-browserify@^2.0.1:
version "2.0.2"
resolved "https://registry.yarnpkg.com/stream-browserify/-/stream-browserify-2.0.2.tgz#87521d38a44aa7ee91ce1cd2a47df0cb49dd660b"
@@ -16551,7 +16872,7 @@ tar@6.1.11:
mkdirp "^1.0.3"
yallist "^4.0.0"
-tar@^6.0.2, tar@^6.1.11, tar@^6.1.2:
+tar@^6.0.2, tar@^6.1.11:
version "6.1.13"
resolved "https://registry.yarnpkg.com/tar/-/tar-6.1.13.tgz#46e22529000f612180601a6fe0680e7da508847b"
integrity sha512-jdIBIN6LTIe2jqzay/2vtYLlBHa3JF42ot3h1dW8Q0PaAG4v8rm0cvpVePtau5C6OKXGGcgO9q2AMNSWxiLqKw==
@@ -16563,6 +16884,18 @@ tar@^6.0.2, tar@^6.1.11, tar@^6.1.2:
mkdirp "^1.0.3"
yallist "^4.0.0"
+tar@^6.1.2:
+ version "6.1.14"
+ resolved "https://registry.yarnpkg.com/tar/-/tar-6.1.14.tgz#e87926bec1cfe7c9e783a77a79f3e81c1cfa3b66"
+ integrity sha512-piERznXu0U7/pW7cdSn7hjqySIVTYT6F76icmFk7ptU7dDYlXTm5r9A6K04R2vU3olYgoKeo1Cg3eeu5nhftAw==
+ dependencies:
+ chownr "^2.0.0"
+ fs-minipass "^2.0.0"
+ minipass "^5.0.0"
+ minizlib "^2.1.1"
+ mkdirp "^1.0.3"
+ yallist "^4.0.0"
+
tcp-port-used@^1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/tcp-port-used/-/tcp-port-used-1.0.2.tgz#9652b7436eb1f4cfae111c79b558a25769f6faea"
@@ -16593,21 +16926,6 @@ terminal-link@^2.0.0:
ansi-escapes "^4.2.1"
supports-hyperlinks "^2.0.0"
-terser-webpack-plugin@^1.4.3:
- version "1.4.5"
- resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-1.4.5.tgz#a217aefaea330e734ffacb6120ec1fa312d6040b"
- integrity sha512-04Rfe496lN8EYruwi6oPQkG0vo8C+HT49X687FZnpPF0qMAIHONI6HEXYPKDOE8e5HjXTyKfqRd/agHtH0kOtw==
- 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@^2.1.2:
version "2.3.8"
resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-2.3.8.tgz#894764a19b0743f2f704e7c2a848c5283a696724"
@@ -16623,6 +16941,22 @@ terser-webpack-plugin@^2.1.2:
terser "^4.6.12"
webpack-sources "^1.4.3"
+"terser-webpack-plugin@npm:@amoo-miki/terser-webpack-plugin@1.4.5-rc.2":
+ version "1.4.5-rc.2"
+ resolved "https://registry.yarnpkg.com/@amoo-miki/terser-webpack-plugin/-/terser-webpack-plugin-1.4.5-rc.2.tgz#046c062ef22c126c2544718674bc6624e3651b9c"
+ integrity sha512-JFSGSzsWgSHEqQXlnHDh3gw+jdVdVlWM2Irdps9P/yWYNY/5VjuG8sdoW4mbuP8/HM893/k8N+ipbeqsd8/xpA==
+ dependencies:
+ "@node-rs/xxhash" "^1.3.0"
+ 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@^4.1.2, terser@^4.6.12:
version "4.8.1"
resolved "https://registry.yarnpkg.com/terser/-/terser-4.8.1.tgz#a00e5634562de2239fd404c649051bf6fc21144f"
@@ -16888,13 +17222,6 @@ tr46@~0.0.3:
resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a"
integrity sha1-gYT9NH2snNwYWZLzpmIuFLnZq2o=
-traceparent@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/traceparent/-/traceparent-1.0.0.tgz#9b14445cdfe5c19f023f1c04d249c3d8e003a5ce"
- integrity sha512-b/hAbgx57pANQ6cg2eBguY3oxD6FGVLI1CC2qoi01RmHR7AYpQHPXTig9FkzbWohEsVuHENZHP09aXuw3/LM+w==
- dependencies:
- random-poly-fill "^1.0.1"
-
traverse@^0.6.6:
version "0.6.6"
resolved "https://registry.yarnpkg.com/traverse/-/traverse-0.6.6.tgz#cbdf560fd7b9af632502fed40f918c157ea97137"
@@ -16930,6 +17257,11 @@ trough@^1.0.0:
resolved "https://registry.yarnpkg.com/trough/-/trough-1.0.5.tgz#b8b639cefad7d0bb2abd37d433ff8293efa5f406"
integrity sha512-rvuRbTarPXmMb79SmzEp8aqXNKcK+y0XaB298IXueQ8I2PsrATcPBCSPyK/dDNa2iWOhKlfNnOjdAOTBU/nkFA==
+"true-case-path@^2.2.1":
+ version "2.2.1"
+ resolved "https://registry.yarnpkg.com/true-case-path/-/true-case-path-2.2.1.tgz#c5bf04a5bbec3fd118be4084461b3a27c4d796bf"
+ integrity sha512-0z3j8R7MCjy10kc/g+qg7Ln3alJTodw9aDuVWZa3uiWqfuBMKeAeP2ocWcxoyM3D73yz3Jt/Pu4qPr4wHSdB/Q==
+
ts-debounce@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/ts-debounce/-/ts-debounce-3.0.0.tgz#9beedf59c04de3b5bef8ff28bd6885624df357be"
@@ -17211,6 +17543,13 @@ unique-filename@^1.1.1:
dependencies:
unique-slug "^2.0.0"
+unique-filename@^2.0.0:
+ version "2.0.1"
+ resolved "https://registry.yarnpkg.com/unique-filename/-/unique-filename-2.0.1.tgz#e785f8675a9a7589e0ac77e0b5c34d2eaeac6da2"
+ integrity sha512-ODWHtkkdx3IAR+veKxFV+VBkUMcN+FaqzUUd7IZzt+0zhDZFPFxhlqwPF3YQvMHx1TD0tdgYl+kuPnJ8E6ql7A==
+ dependencies:
+ unique-slug "^3.0.0"
+
unique-slug@^2.0.0:
version "2.0.2"
resolved "https://registry.yarnpkg.com/unique-slug/-/unique-slug-2.0.2.tgz#baabce91083fc64e945b0f3ad613e264f7cd4e6c"
@@ -17218,6 +17557,13 @@ unique-slug@^2.0.0:
dependencies:
imurmurhash "^0.1.4"
+unique-slug@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/unique-slug/-/unique-slug-3.0.0.tgz#6d347cf57c8a7a7a6044aabd0e2d74e4d76dc7c9"
+ integrity sha512-8EyMynh679x/0gqE9fT9oilG+qEt+ibFyqjuVTsZn1+CMxH+XLlpvr2UZx4nVcCwTpx81nICr2JQFkM+HPLq4w==
+ dependencies:
+ imurmurhash "^0.1.4"
+
unique-stream@^2.0.2:
version "2.3.1"
resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.3.1.tgz#c65d110e9a4adf9a6c5948b28053d9a8d04cbeac"
@@ -18066,7 +18412,7 @@ wcwidth@^1.0.1:
dependencies:
defaults "^1.0.3"
-weak-lru-cache@^1.0.0:
+weak-lru-cache@^1.2.2:
version "1.2.2"
resolved "https://registry.yarnpkg.com/weak-lru-cache/-/weak-lru-cache-1.2.2.tgz#fdbb6741f36bae9540d12f480ce8254060dccd19"
integrity sha512-DEAoo25RfSYMuTGc9vPJzZcZullwIqRDSI9LOy+fkCJPi6hykCnfKaXTuPBDuXAUcqHXyOgFtHNp/kB2FjYHbw==
@@ -18137,11 +18483,12 @@ webpack-sources@^1.1.0, webpack-sources@^1.4.0, webpack-sources@^1.4.1, webpack-
source-list-map "^2.0.0"
source-map "~0.6.1"
-webpack@^4.41.5:
- version "4.46.0"
- resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.46.0.tgz#bf9b4404ea20a073605e0a011d188d77cb6ad542"
- integrity sha512-6jJuJjg8znb/xRItk7bkT0+Q7AHCYjjFnvKIWQPkNIOyRqoCGvkOs0ipeQzrqz4l5FtN5ZI/ukEHroeX/o1/5Q==
+"webpack@npm:@amoo-miki/webpack@4.46.0-rc.2":
+ version "4.46.0-rc.2"
+ resolved "https://registry.yarnpkg.com/@amoo-miki/webpack/-/webpack-4.46.0-rc.2.tgz#36824597c14557a7bb0a8e13203e30275e7b02bd"
+ integrity sha512-Y/ZqxTHOoDF1kz3SR63Y9SZGTDUpZNNFrisTRHofWhP8QvNX3LMN+TCmEP56UfLaiLVKMcaiFjx8kFb2TgyBaQ==
dependencies:
+ "@node-rs/xxhash" "^1.3.0"
"@webassemblyjs/ast" "1.9.0"
"@webassemblyjs/helper-module-context" "1.9.0"
"@webassemblyjs/wasm-edit" "1.9.0"
@@ -18154,7 +18501,7 @@ webpack@^4.41.5:
eslint-scope "^4.0.3"
json-parse-better-errors "^1.0.2"
loader-runner "^2.4.0"
- loader-utils "^1.2.3"
+ loader-utils "^2.0.4"
memory-fs "^0.4.1"
micromatch "^3.1.10"
mkdirp "^0.5.3"
@@ -18162,7 +18509,7 @@ webpack@^4.41.5:
node-libs-browser "^2.2.1"
schema-utils "^1.0.0"
tapable "^1.1.3"
- terser-webpack-plugin "^1.4.3"
+ terser-webpack-plugin "npm:@amoo-miki/terser-webpack-plugin@1.4.5-rc.2"
watchpack "^1.7.4"
webpack-sources "^1.4.1"
@@ -18478,15 +18825,10 @@ yallist@^4.0.0:
resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72"
integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==
-yaml@^1.10.0:
- version "1.10.2"
- resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.2.tgz#2301c5ffbf12b467de8da2333a459e29e7920e4b"
- integrity sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==
-
-yaml@^2.0.0:
- version "2.1.1"
- resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.1.1.tgz#1e06fb4ca46e60d9da07e4f786ea370ed3c3cfec"
- integrity sha512-o96x3OPo8GjWeSLF+wOAbrPfhFOGY0W00GNaxCDv+9hkcDJEnev1yh8S7pgHF0ik6zc8sQLuL8hjHjJULZp8bw==
+yaml@^1.10.0, yaml@^2.0.0, yaml@^2.2.2:
+ version "2.2.2"
+ resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.2.2.tgz#ec551ef37326e6d42872dad1970300f8eb83a073"
+ integrity sha512-CBKFWExMn46Foo4cldiChEzn7S7SRV+wqiluAb6xmueD/fGyRHIhX8m14vVGgeFWjN540nKCNVj6P21eQjgTuA==
yargs-parser@20.2.4:
version "20.2.4"
@@ -18551,6 +18893,19 @@ yargs@^15.0.2, yargs@^15.3.1:
y18n "^4.0.0"
yargs-parser "^18.1.2"
+yargs@^17.2.1:
+ version "17.7.2"
+ resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269"
+ integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==
+ dependencies:
+ cliui "^8.0.1"
+ escalade "^3.1.1"
+ get-caller-file "^2.0.5"
+ require-directory "^2.1.1"
+ string-width "^4.2.3"
+ y18n "^5.0.5"
+ yargs-parser "^21.1.1"
+
yargs@~17.6.0:
version "17.6.2"
resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.6.2.tgz#2e23f2944e976339a1ee00f18c77fedee8332541"
@@ -18564,6 +18919,11 @@ yargs@~17.6.0:
y18n "^5.0.5"
yargs-parser "^21.1.1"
+yarn@^1.22.19:
+ version "1.22.19"
+ resolved "https://registry.yarnpkg.com/yarn/-/yarn-1.22.19.tgz#4ba7fc5c6e704fce2066ecbfb0b0d8976fe62447"
+ integrity sha512-/0V5q0WbslqnwP91tirOvldvYISzaqhClxzyUKXYxs07yUILIs5jx/k6CFe8bvKSkds5w+eiOqta39Wk3WxdcQ==
+
yauzl@^2.10.0:
version "2.10.0"
resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.10.0.tgz#c7eb17c93e112cb1086fa6d8e51fb0667b79a5f9"